/* Utility CSS - Replaces inline styles for better maintainability */

/* Layout utilities */
.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.flex-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.flex-gap {
    display: flex;
    gap: 1.2rem;
}

.flex-column {
    display: flex;
    flex-direction: column;
}

.inline-form {
    display: inline;
    margin: 0;
    padding: 0;
}

/* Text utilities */
.text-muted {
    color: #64748b;
}

.dark .text-muted {
    color: #cbd5e1;
}

.text-center {
    text-align: center;
}

.text-sm {
    font-size: 0.9rem;
}

.text-xs {
    font-size: 0.8rem;
}

.fw-semibold {
    font-weight: 600;
}

/* Button utilities */
.btn-unstyled {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    font: inherit;
}

.btn-logout {
    background: none;
    border: none;
    color: #2d7ff9;
    cursor: pointer;
    font: inherit;
    padding: 0;
}

.dark .btn-logout {
    color: #60a5fa;
}

/* Message styles */
.msg-system {
    background: #f3f4f6;
    color: #64748b;
    border-left: 4px solid #64748b;
    font-style: italic;
}

.dark .msg-system {
    background: #334155;
    color: #cbd5e1;
    border-left-color: #94a3b8;
}

.msg-empty {
    text-align: center;
    color: #9ca3af;
    margin-top: 2rem;
}

.dark .msg-empty {
    color: #64748b;
}

/* Form utilities */
.form-row-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.form-row-gap {
    display: flex;
    gap: 0.5em;
}

.form-table {
    width: 100%;
    table-layout: fixed;
}

/* No results */
.no-results {
    text-align: center;
    padding: 3rem;
    color: #64748b;
}

.dark .no-results {
    color: #94a3b8;
}

/* Link styles */
.link-primary {
    color: #2563eb;
    text-decoration: none;
    font-weight: 600;
}

.dark .link-primary {
    color: #60a5fa;
}

.link-primary:hover {
    text-decoration: underline;
}

/* Divider */
.divider {
    margin: 2rem 0;
    border: none;
    border-top: 1px solid #e2e8f0;
}

.dark .divider {
    border-top-color: #334155;
}

/* Section footer */
.section-footer {
    text-align: center;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e2e8f0;
}

.dark .section-footer {
    border-top-color: #334155;
}

/* Broadcast message */
.broadcast-notice {
    padding: 1rem;
    background: #f1f5f9;
    text-align: center;
    color: #64748b;
    font-size: 0.9rem;
}

.dark .broadcast-notice {
    background: #334155;
    color: #cbd5e1;
}

/* Images section */
.images-section {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.drop-box {
    position: relative;
}

.drop-box-label {
    display: block;
}

.preview-img {
    max-height: 72px;
    max-width: 100%;
    margin-top: 4px;
}

.qr-code-img {
    width: 72px;
    height: 72px;
    display: inline-block;
}

/* Quantity input */
.quantity-input {
    width: 5.5ch;
}

/* Inactive status */
.status-inactive {
    color: #ef4444;
}

.dark .status-inactive {
    color: #f87171;
}

/* Responsive adjustments */
@media (max-width: 640px) {
    .flex-gap {
        flex-direction: column;
        gap: 1rem;
    }
}
