/*
 * Postani — app.css
 * Design system, layout, sidebar, topbar, and component styles.
 * Uses CSS Custom Properties (variables) for easy theming.
 */

/* ════════════════════════════════════════════════════════════════════════════
   1. DESIGN TOKENS
════════════════════════════════════════════════════════════════════════════ */
:root {
    /* Colour palette */
    --color-primary:         #2E7D32;   /* Forest green */
    --color-primary-light:   #43A047;
    --color-primary-dark:    #1B5E20;
    --color-primary-tint:    #E8F5E9;
    --color-accent:          #FF8F00;   /* Amber — harvest theme */
    --color-accent-light:    #FFF8E1;

    /* Semantics */
    --color-success:         #2E7D32;
    --color-warning:         #F57F17;
    --color-danger:          #C62828;
    --color-info:            #01579B;

    /* Surfaces */
    --color-bg:              #F3F6F4;
    --color-surface:         #FFFFFF;
    --color-surface-raised:  #FFFFFF;
    --color-border:          #E0E7E1;
    --color-border-subtle:   #EEF2EF;

    /* Text */
    --color-text:            #1A2920;
    --color-text-muted:      #6B7C72;
    --color-text-subtle:     #9EADA6;
    --color-text-inverse:    #FFFFFF;

    /* Sidebar */
    --sidebar-width:         260px;
    --sidebar-collapsed:     72px;
    --sidebar-bg:            #1B2E20;   /* Very dark green */
    --sidebar-bg-hover:      rgba(255,255,255,.07);
    --sidebar-bg-active:     rgba(255,255,255,.13);
    --sidebar-text:          rgba(255,255,255,.72);
    --sidebar-text-active:   #FFFFFF;
    --sidebar-accent:        #66BB6A;   /* Light green accent in sidebar */
    --sidebar-border:        rgba(255,255,255,.06);

    /* Topbar */
    --topbar-height:         64px;
    --topbar-bg:             #FFFFFF;
    --topbar-border:         var(--color-border);

    /* Radius */
    --radius-sm:             6px;
    --radius-md:             12px;
    --radius-lg:             16px;
    --radius-xl:             24px;
    --radius-full:           9999px;

    /* Shadows */
    --shadow-sm:    0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
    --shadow-md:    0 4px 12px rgba(0,0,0,.08), 0 2px 4px rgba(0,0,0,.05);
    --shadow-lg:    0 10px 30px rgba(0,0,0,.10), 0 4px 8px rgba(0,0,0,.06);
    --shadow-glow:  0 0 0 3px rgba(46,125,50,.20);

    /* Typography */
    --font-family:   'Inter', system-ui, -apple-system, sans-serif;
    --font-size-xs:  0.70rem;
    --font-size-sm:  0.825rem;
    --font-size-md:  0.925rem;
    --font-size-lg:  1.05rem;

    /* Transitions */
    --transition-fast:   150ms ease;
    --transition-base:   250ms ease;
    --transition-slow:   400ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* ════════════════════════════════════════════════════════════════════════════
   2. GLOBAL RESET & BASE
════════════════════════════════════════════════════════════════════════════ */
*, *::before, *::after { box-sizing: border-box; }

html, body {
    height: 100%;
    overflow-x: hidden;
}

body {
    font-family: var(--font-family);
    font-size:   var(--font-size-md);
    color:       var(--color-text);
    background:  var(--color-bg);
    margin: 0;
    -webkit-font-smoothing: antialiased;
}

/* ════════════════════════════════════════════════════════════════════════════
   3. LAYOUT SHELL
════════════════════════════════════════════════════════════════════════════ */
#sidebar-wrapper {
    position: fixed;
    inset: 0 auto 0 0;
    width: var(--sidebar-width);
    z-index: 1040;
    transition: width var(--transition-slow);
}

#page-content-wrapper {
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: margin-left var(--transition-slow);
}

/* Collapsed state */
body.sidebar-collapsed #sidebar-wrapper        { width: var(--sidebar-collapsed); }
body.sidebar-collapsed #page-content-wrapper   { margin-left: var(--sidebar-collapsed); }
body.sidebar-collapsed .brand-text,
body.sidebar-collapsed .nav-label,
body.sidebar-collapsed .nav-arrow,
body.sidebar-collapsed .user-details           { display: none !important; }
body.sidebar-collapsed .sidebar-brand          { justify-content: center; }
body.sidebar-collapsed .nav-link               { justify-content: center; padding-inline: 0; }
body.sidebar-collapsed .nav-icon               { margin: 0; }
body.sidebar-collapsed .sidebar-footer         { padding: 12px 8px; }
body.sidebar-collapsed .user-avatar            { margin: 0 auto; }
body.sidebar-collapsed .btn-logout             { display: none !important; }

/* ════════════════════════════════════════════════════════════════════════════
   4. SIDEBAR
════════════════════════════════════════════════════════════════════════════ */
#sidebar {
    height: 100%;
    background: var(--sidebar-bg);
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.1) transparent;
}

#sidebar::-webkit-scrollbar { width: 4px; }
#sidebar::-webkit-scrollbar-track { background: transparent; }
#sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,.15); border-radius: 2px; }

/* ── Brand ── */
.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px 20px 16px;
    border-bottom: 1px solid var(--sidebar-border);
    text-decoration: none;
    overflow: hidden;
    white-space: nowrap;
}

.brand-icon {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, var(--color-primary-light), var(--color-primary-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.1rem;
    box-shadow: 0 2px 8px rgba(0,0,0,.3);
}

.brand-text {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--sidebar-text-active);
    letter-spacing: -0.02em;
}

/* ── Nav ── */
.sidebar-nav { padding: 12px 12px 0; }

.sidebar-nav .nav-item { margin-bottom: 2px; }

.sidebar-nav .nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    color: var(--sidebar-text);
    border-radius: var(--radius-md);
    text-decoration: none;
    font-size: var(--font-size-sm);
    font-weight: 500;
    transition: background var(--transition-fast), color var(--transition-fast);
    white-space: nowrap;
    overflow: hidden;
}

.sidebar-nav .nav-link:hover {
    background: var(--sidebar-bg-hover);
    color: var(--sidebar-text-active);
}

.sidebar-nav .nav-link.active {
    background: var(--sidebar-bg-active);
    color: var(--sidebar-text-active);
    font-weight: 600;
}

.sidebar-nav .nav-link.active .nav-icon {
    color: var(--sidebar-accent);
}

.nav-icon {
    font-size: 1rem;
    flex-shrink: 0;
    width: 20px;
    text-align: center;
    transition: color var(--transition-fast);
}

.nav-label { flex: 1; overflow: hidden; text-overflow: ellipsis; }

.nav-arrow {
    font-size: 0.7rem;
    flex-shrink: 0;
    transition: transform var(--transition-base);
}

.has-submenu.open > .nav-link .nav-arrow { transform: rotate(180deg); }

/* ── Submenu ── */
.submenu {
    padding: 4px 0 4px 16px;
    margin: 0;
}

.submenu .nav-link {
    padding: 8px 12px;
    font-size: var(--font-size-xs);
    border-left: 2px solid transparent;
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    gap: 6px;
}

.submenu .nav-link.active {
    background: var(--sidebar-bg-active);
    border-left-color: var(--sidebar-accent);
}

.nav-sub-icon { font-size: 1.2rem; color: var(--sidebar-text); }

/* ── Sidebar Footer ── */
.sidebar-footer {
    border-top: 1px solid var(--sidebar-border);
    padding: 16px 12px;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    overflow: hidden;
}

.user-avatar {
    flex-shrink: 0;
    width: 34px;
    height: 34px;
    border-radius: var(--radius-full);
    background: linear-gradient(135deg, var(--color-accent), var(--color-primary-light));
    color: #fff;
    font-weight: 700;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(0,0,0,.3);
}

.user-details { flex: 1; overflow: hidden; }
.user-name { color: var(--sidebar-text-active); font-size: var(--font-size-xs); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-role { color: var(--sidebar-text); font-size: 0.65rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.btn-logout {
    flex-shrink: 0;
    color: var(--sidebar-text);
    text-decoration: none;
    padding: 4px;
    border-radius: var(--radius-sm);
    transition: color var(--transition-fast), background var(--transition-fast);
    display: flex;
    align-items: center;
}
.btn-logout:hover { color: #ef5350; background: rgba(239,83,80,.12); }

/* ════════════════════════════════════════════════════════════════════════════
   5. TOPBAR
════════════════════════════════════════════════════════════════════════════ */
#topbar {
    height: var(--topbar-height);
    background: var(--topbar-bg);
    border-bottom: 1px solid var(--topbar-border);
    display: flex;
    align-items: center;
    padding: 0 24px;
    gap: 12px;
    position: sticky;
    top: 0;
    z-index: 1030;
    box-shadow: var(--shadow-sm);
}

.page-heading {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-text);
    letter-spacing: -0.02em;
}

.btn-icon {
    width: 38px;
    height: 38px;
    border-radius: var(--radius-md);
    border: none;
    background: transparent;
    color: var(--color-text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background var(--transition-fast), color var(--transition-fast);
    padding: 0;
    flex-shrink: 0;
}
.btn-icon:hover { background: var(--color-border-subtle); color: var(--color-text); }

.topbar-clock { font-family: 'Courier New', monospace; font-size: 0.8rem; }

.notification-dot {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 8px;
    height: 8px;
    background: var(--color-danger);
    border-radius: var(--radius-full);
    border: 2px solid var(--topbar-bg);
}

.notification-dropdown {
    width: 320px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding-top: 0;
    overflow: hidden;
}
.notification-dropdown .dropdown-header {
    padding: 14px 16px;
    background: var(--color-bg);
    font-size: var(--font-size-sm);
    color: var(--color-text);
}

.user-dropdown-btn {
    border: none;
    background: var(--color-bg);
    border-radius: var(--radius-lg);
    padding: 6px 10px;
    transition: background var(--transition-fast);
}
.user-dropdown-btn:hover { background: var(--color-border-subtle); }

.avatar-sm {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-full);
    background: linear-gradient(135deg, var(--color-accent), var(--color-primary-light));
    color: #fff;
    font-weight: 700;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* ════════════════════════════════════════════════════════════════════════════
   6. MAIN CONTENT
════════════════════════════════════════════════════════════════════════════ */
#main-content {
    flex: 1;
    padding: 28px 28px 40px;
    max-width: 100%;
}

/* ════════════════════════════════════════════════════════════════════════════
   7. CARDS & PANELS
════════════════════════════════════════════════════════════════════════════ */
.card {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    background: var(--color-surface);
    overflow: hidden;
}

.card-header {
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border-subtle);
    padding: 16px 20px;
    font-weight: 600;
    font-size: var(--font-size-md);
    color: var(--color-text);
    display: flex;
    align-items: center;
    gap: 8px;
}

.card-body { padding: 20px; }

/* ── Stat Cards ── */
.stat-card {
    border-radius: var(--radius-lg);
    padding: 24px;
    position: relative;
    overflow: hidden;
    border: none;
    box-shadow: var(--shadow-md);
    transition: transform var(--transition-base), box-shadow var(--transition-base);
}
.stat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }

.stat-card .stat-icon {
    width: 52px;
    height: 52px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    margin-bottom: 16px;
}

.stat-card .stat-value {
    font-size: 1.55rem;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.03em;
    margin-bottom: 4px;
}

.stat-card .stat-label {
    font-size: var(--font-size-xs);
    font-weight: 500;
    opacity: .75;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.stat-card .stat-delta {
    font-size: var(--font-size-xs);
    font-weight: 600;
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 4px;
    opacity: .85;
}

/* Colour variants */
.stat-card-green  { background: linear-gradient(135deg, #2E7D32, #43A047); color: #fff; }
.stat-card-amber  { background: linear-gradient(135deg, #E65100, #FF8F00); color: #fff; }
.stat-card-blue   { background: linear-gradient(135deg, #01579B, #0288D1); color: #fff; }
.stat-card-purple { background: linear-gradient(135deg, #4527A0, #7E57C2); color: #fff; }
.stat-card-red    { background: linear-gradient(135deg, #B71C1C, #E53935); color: #fff; }

.stat-card-green  .stat-icon { background: rgba(255,255,255,.2); color: #fff; }
.stat-card-amber  .stat-icon { background: rgba(255,255,255,.2); color: #fff; }
.stat-card-blue   .stat-icon { background: rgba(255,255,255,.2); color: #fff; }
.stat-card-purple .stat-icon { background: rgba(255,255,255,.2); color: #fff; }
.stat-card-red    .stat-icon { background: rgba(255,255,255,.2); color: #fff; }

/* ════════════════════════════════════════════════════════════════════════════
   8. DATATABLES OVERRIDES
════════════════════════════════════════════════════════════════════════════ */
div.dataTables_wrapper {
    font-size: var(--font-size-sm);
    color: var(--color-text);
}

div.dataTables_wrapper div.dataTables_length select,
div.dataTables_wrapper div.dataTables_filter input {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 6px 12px;
    font-size: var(--font-size-sm);
    background: var(--color-surface);
    color: var(--color-text);
    outline: none;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

div.dataTables_wrapper div.dataTables_filter input:focus {
    border-color: var(--color-primary-light);
    box-shadow: var(--shadow-glow);
}

div.dataTables_wrapper div.dataTables_info {
    font-size: var(--font-size-xs);
    color: var(--color-text-muted);
    padding-top: 0.85em;
}

.table > thead > tr > th {
    background: var(--color-bg);
    border-bottom: 2px solid var(--color-border);
    font-size: var(--font-size-xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-muted);
    white-space: nowrap;
    padding: 10px 12px;
}

.table > tbody > tr > td {
    padding: 12px 12px;
    vertical-align: middle;
    border-bottom: 1px solid var(--color-border-subtle);
    font-size: var(--font-size-sm);
}

.table > tbody > tr:last-child > td { border-bottom: none; }
.table > tbody > tr:hover > td { background: var(--color-primary-tint); }

/* Pagination */
.page-item .page-link {
    border-radius: var(--radius-sm) !important;
    margin: 0 2px;
    font-size: var(--font-size-sm);
    color: var(--color-primary);
    border-color: var(--color-border);
}
.page-item.active .page-link {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
}
.page-item .page-link:focus { box-shadow: var(--shadow-glow); }

/* ════════════════════════════════════════════════════════════════════════════
   9. BUTTONS
════════════════════════════════════════════════════════════════════════════ */
.btn {
    border-radius: var(--radius-md);
    font-size: var(--font-size-sm);
    font-weight: 600;
    transition: all var(--transition-fast);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-primary {
    background: var(--color-primary);
    border-color: var(--color-primary);
}
.btn-primary:hover {
    background: var(--color-primary-light);
    border-color: var(--color-primary-light);
    box-shadow: 0 4px 12px rgba(46,125,50,.35);
}

.btn-outline-primary { color: var(--color-primary); border-color: var(--color-primary); }
.btn-outline-primary:hover { background: var(--color-primary); color: #fff; }

.btn-accent {
    background: var(--color-accent);
    border-color: var(--color-accent);
    color: #fff;
}
.btn-accent:hover {
    background: #E65100;
    border-color: #E65100;
    color: #fff;
    box-shadow: 0 4px 12px rgba(255,143,0,.35);
}

/* Action Buttons in Tables */
.btn-action {
    width: 30px;
    height: 30px;
    padding: 0;
    border-radius: var(--radius-sm);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    border: 1px solid transparent;
    transition: all var(--transition-fast);
}

/* ════════════════════════════════════════════════════════════════════════════
   10. FORM CONTROLS
════════════════════════════════════════════════════════════════════════════ */
.form-control, .form-select {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    font-size: var(--font-size-sm);
    color: var(--color-text);
    background: var(--color-surface);
    padding: 9px 14px;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}
.form-control:focus, .form-select:focus {
    border-color: var(--color-primary-light);
    box-shadow: var(--shadow-glow);
    outline: none;
}
.form-label {
    font-size: var(--font-size-xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--color-text-muted);
    margin-bottom: 5px;
}

/* ════════════════════════════════════════════════════════════════════════════
   11. MODALS
════════════════════════════════════════════════════════════════════════════ */
.modal-content {
    border: none;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}
.modal-header {
    background: var(--color-bg);
    border-bottom: 1px solid var(--color-border);
    padding: 18px 24px;
    font-weight: 700;
}
.modal-footer {
    background: var(--color-bg);
    border-top: 1px solid var(--color-border);
    padding: 14px 24px;
}
.modal-body { padding: 24px; }

/* ════════════════════════════════════════════════════════════════════════════
   12. BADGES
════════════════════════════════════════════════════════════════════════════ */
.badge {
    font-size: 0.68rem;
    font-weight: 600;
    padding: 4px 9px;
    border-radius: var(--radius-full);
    letter-spacing: 0.02em;
}

/* ════════════════════════════════════════════════════════════════════════════
   13. ALERTS
════════════════════════════════════════════════════════════════════════════ */
.alert {
    border-radius: var(--radius-md);
    border: none;
    font-size: var(--font-size-sm);
    padding: 12px 16px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

/* ════════════════════════════════════════════════════════════════════════════
   14. PAGE HEADER COMPONENT
════════════════════════════════════════════════════════════════════════════ */
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 12px;
}

.page-header-title {
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    color: var(--color-text);
    margin: 0;
    line-height: 1.2;
}

.page-header-subtitle {
    font-size: var(--font-size-sm);
    color: var(--color-text-muted);
    margin: 2px 0 0;
}

/* ════════════════════════════════════════════════════════════════════════════
   15. LOADING OVERLAY
════════════════════════════════════════════════════════════════════════════ */
.loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.35);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(3px);
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-base);
}
.loading-overlay.active { opacity: 1; pointer-events: all; }

.loading-spinner {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-full);
    background: var(--color-surface);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-primary);
    font-size: 1.3rem;
    animation: spin 1s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ════════════════════════════════════════════════════════════════════════════
   16. AUTH / LOGIN PAGE
════════════════════════════════════════════════════════════════════════════ */
body.auth-page {
    background: linear-gradient(135deg, var(--color-primary-dark) 0%, #2E7D32 50%, #388E3C 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-card {
    width: 100%;
    max-width: 420px;
    background: var(--color-surface);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    padding: 40px 36px;
}

.auth-logo {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-xl);
    background: linear-gradient(135deg, var(--color-primary-light), var(--color-primary-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.6rem;
    margin: 0 auto 20px;
    box-shadow: 0 4px 16px rgba(46,125,50,.4);
}

/* ════════════════════════════════════════════════════════════════════════════
   17. ANIMATIONS
════════════════════════════════════════════════════════════════════════════ */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
}

.animate-fade-in-up {
    animation: fadeInUp var(--transition-slow) both;
}

/* Stagger helpers */
.stagger-1 { animation-delay: 50ms; }
.stagger-2 { animation-delay: 100ms; }
.stagger-3 { animation-delay: 150ms; }
.stagger-4 { animation-delay: 200ms; }

/* ════════════════════════════════════════════════════════════════════════════
   18. RESPONSIVE
════════════════════════════════════════════════════════════════════════════ */
@media (max-width: 991.98px) {
    #sidebar-wrapper {
        transform: translateX(-100%);
        transition: transform var(--transition-slow);
    }
    #sidebar-wrapper.mobile-open {
        transform: translateX(0);
    }
    #page-content-wrapper { margin-left: 0 !important; }

    #main-content { padding: 20px 16px 32px; }

    /* Backdrop */
    .sidebar-backdrop {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,.4);
        z-index: 1035;
        backdrop-filter: blur(2px);
    }
    .sidebar-backdrop.active { display: block; }
}

@media (max-width: 575.98px) {
    .page-header { flex-direction: column; align-items: flex-start; }
    .stat-card { padding: 18px; }
}

/* ════════════════════════════════════════════════════════════════════════════
   19. UTILITIES
════════════════════════════════════════════════════════════════════════════ */
.text-primary-app { color: var(--color-primary) !important; }
.bg-primary-tint  { background: var(--color-primary-tint) !important; }
.rounded-app      { border-radius: var(--radius-lg) !important; }
.shadow-app       { box-shadow: var(--shadow-md) !important; }

.divider-text {
    position: relative;
    text-align: center;
    color: var(--color-text-muted);
    font-size: var(--font-size-xs);
}
.divider-text::before, .divider-text::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 40%;
    height: 1px;
    background: var(--color-border);
}
.divider-text::before { left: 0; }
.divider-text::after  { right: 0; }

/* SweetAlert2 border-radius override */
.swal2-popup { border-radius: var(--radius-xl) !important; }
.swal2-confirm { border-radius: var(--radius-md) !important; background: var(--color-primary) !important; }
.swal2-cancel  { border-radius: var(--radius-md) !important; }

/* ════════════════════════════════════════════════════════════════════════════
   20. PRINT STYLES (Receipt)
════════════════════════════════════════════════════════════════════════════ */
@media print {
    #sidebar-wrapper,
    #topbar,
    .modal-header,
    .modal-footer,
    .pos-products-panel,
    .pos-order-panel .pos-cart-header,
    .pos-order-panel .pos-cart-items,
    .pos-order-panel .pos-payment-section { display: none !important; }

    .modal { position: static !important; }
    .modal-dialog { margin: 0 !important; max-width: 100% !important; }
    .modal-content { border: none !important; box-shadow: none !important; }
    .receipt-box { font-size: 10pt; }
}

