/* TABARUQ Foods Premium Styling */
:root {
    --primary: #4f46e5;
    --primary-hover: #4338ca;
    --accent-cyan: #22d3ee;
    --accent-magenta: #ec4899;
    --bg: #081429;
    --bg-body: #061023;
    --card-bg: rgba(10, 20, 40, 0.88);
    --text-dark: #f8fafc;
    --text-gray: rgba(255,255,255,0.75);
    --text-white: #ffffff;
    --accent-success: #10b981;
    --accent-danger: #ef4444;
    --accent-warning: #f59e0b;
    --glass: rgba(7, 19, 39, 0.55);
    --border: rgba(99, 102, 241, 0.18);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

html,
body {
    height: 100%;
}

body {
    background: radial-gradient(circle at top left, rgba(34, 100, 167, 0.25), transparent 25%),
                radial-gradient(circle at bottom right, rgba(27, 59, 129, 0.35), transparent 30%),
                linear-gradient(180deg, #081429 0%, #061023 100%);
    color: var(--text-white);
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    background-image: url('../images/watermark.png');
    background-repeat: no-repeat;
    background-position: center;
    background-size: 50%;
    opacity: 0.15;
    pointer-events: none;
    z-index: 0;
    /* CSS Hack to remove white background from the uploaded logo */
    filter: invert(1) grayscale(100%);
    mix-blend-mode: screen;
}

/* Utilities */
.container {
    padding: 2rem;
    position: relative;
    z-index: 1;
}

.glass-card {
    background: rgba(8, 18, 40, 0.95);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 1.5rem;
    padding: 1.75rem;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.16);
    color: var(--text-white);
    position: relative;
    z-index: 1;
}

/* Buttons */
.btn {
    padding: 0.9rem 1.8rem;
    border-radius: 1rem;
    border: none;
    cursor: pointer;
    font-weight: 700;
    letter-spacing: 0.01em;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
    color: white;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--accent-cyan));
    color: white;
    box-shadow: 0 16px 35px rgba(99, 102, 241, 0.25);
}

.btn-primary:hover {
    transform: translateY(-2px);
    background: linear-gradient(135deg, var(--primary-hover), var(--accent-cyan));
}

.print-action {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    min-width: 5.6rem;
    padding: 0.45rem 0.75rem !important;
    border: 1px solid rgba(125, 211, 252, 0.8) !important;
    border-radius: 0.45rem !important;
    background: #0284c7 !important;
    color: #ffffff !important;
    font-weight: 800;
    cursor: pointer;
    white-space: nowrap;
}

.print-action:hover,
.print-action:focus-visible {
    background: #0369a1 !important;
    box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.25);
    transform: translateY(-1px);
}

.btn-success {
    background: linear-gradient(135deg, var(--accent-success), #059669);
    color: white;
    box-shadow: 0 16px 35px rgba(16, 185, 129, 0.25);
}

.btn-success:hover {
    transform: translateY(-2px);
    background: linear-gradient(135deg, #059669, #047857);
}

.btn-danger {
    background: linear-gradient(135deg, var(--accent-danger), #dc2626);
    color: white;
    box-shadow: 0 16px 35px rgba(239, 68, 68, 0.25);
}

.btn-danger:hover {
    transform: translateY(-2px);
    background: linear-gradient(135deg, #dc2626, #b91c1c);
}

/* Forms */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.6rem;
    color: var(--text-white);
    font-weight: 600;
}

.form-control {
    width: 100%;
    padding: 0.95rem 1rem;
    background: #0f172a;
    border: 1px solid rgba(148, 163, 184, 0.24);
    border-radius: 0.85rem;
    color: #f0f9ff;
    font-weight: 500;
    position: relative;
    z-index: 1;
}

.form-control:focus {
    outline: none;
    border-color: rgba(34, 211, 238, 0.8);
    box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.12);
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.form-control option {
    background: #1a202c;
    color: #f0f9ff;
}

.form-control::-webkit-calendar-picker-indicator {
    filter: invert(1);
    cursor: pointer;
}

/* Layout */
.layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    min-height: 100vh;
    height: 100vh;
    position: relative;
    z-index: 1;
}

.sidebar {
    background: rgba(8, 20, 45, 0.96);
    padding: 2.5rem 2rem;
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: inset -2px 0 0 rgba(34, 211, 238, 0.08);
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

main.container {
    overflow-y: auto;
    height: 100vh;
    padding: 2rem;
}

.sidebar h2 {
    margin-bottom: 2rem;
    color: var(--primary);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    font-weight: 800;
}

.nav-links {
    list-style: none;
}

.nav-links li {
    margin-bottom: 1rem;
}

.nav-links a {
    color: var(--text-white);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.9rem;
    padding: 0.95rem 1rem;
    border-radius: 1rem;
    transition: 0.3s ease;
    position: relative;
    font-weight: 600;
}

.nav-links a::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    width: 4px;
    height: 100%;
    border-radius: 0 1rem 1rem 0;
    background: transparent;
    transition: background 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
    background: rgba(34, 100, 180, 0.25);
    color: var(--text-white);
    transform: translateX(6px);
}

.nav-links a:hover::before,
.nav-links a.active::before {
    background: linear-gradient(180deg, var(--primary), var(--accent-cyan));
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    padding: 1.5rem;
    text-align: center;
    background: rgba(12, 24, 48, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 1.5rem;
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.14);
    color: var(--text-white);
}

.stat-value {
    font-size: 2.4rem;
    font-weight: 800;
    margin-top: 0.75rem;
    color: var(--text-white);
}

.dashboard-card,
.notifications-panel,
.top-products-panel,
.account-report-panel,
.product-card,
.section-card {
    border-radius: 1.5rem;
    background: rgba(15, 23, 42, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 30px 80px rgba(15, 23, 42, 0.16);
    color: var(--text-white);
}

.notifications-panel .panel-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.notifications-panel .panel-header h3 {
    margin: 0;
    font-size: 1.1rem;
    color: var(--text-white);
}

.notifications-panel .notifications-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.notification-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.2rem 1.25rem;
    border-radius: 1.25rem;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.notification-card:hover {
    transform: translateY(-2px);
    border-color: rgba(99, 102, 241, 0.28);
}

.notification-card .notice-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 1rem;
    display: grid;
    place-items: center;
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-white);
    font-size: 1.1rem;
}

.notification-card span {
    display: block;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.75);
    margin-bottom: 0.35rem;
}

.notification-card strong {
    display: block;
    font-size: 1.5rem;
    color: var(--text-white);
}

.notification-card.notification-card-warning .notice-icon {
    background: rgba(251, 191, 36, 0.18);
    color: #fbbf24;
}

.notification-card.notification-card-danger .notice-icon {
    background: rgba(239, 68, 68, 0.18);
    color: #ef4444;
}

.notification-card.notification-card-success .notice-icon {
    background: rgba(16, 185, 129, 0.18);
    color: #10b981;
}

.notification-card.notification-card-primary .notice-icon {
    background: rgba(79, 70, 229, 0.18);
    color: #4f46e5;
}

.top-products-panel .panel-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.top-products-panel .panel-header h3 {
    margin: 0;
    font-size: 1.1rem;
    color: var(--text-white);
}

.top-products-panel .products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
}

.top-products-panel .product-card {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1.35rem;
    padding: 1.25rem 1.3rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.top-products-panel .product-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 22px 55px rgba(99, 102, 241, 0.12);
    border-color: rgba(99, 102, 241, 0.28);
}

.top-products-panel .product-card-header {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    flex-wrap: wrap;
}

.top-products-panel .product-rank {
    min-width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.95rem;
    display: grid;
    place-items: center;
    background: rgba(99, 102, 241, 0.15);
    color: var(--text-white);
    font-weight: 700;
}

.top-products-panel .product-card strong {
    font-size: 1rem;
    line-height: 1.4;
}

.top-products-panel .product-meta {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    font-size: 0.92rem;
    color: rgba(255, 255, 255, 0.78);
    font-weight: 500;
}

.top-products-panel .product-meta span:last-child {
    color: var(--text-white);
    font-weight: 700;
}

.badge-info {
    background: rgba(34, 211, 238, 0.16);
    color: var(--text-white);
    border: 1px solid rgba(34, 211, 238, 0.28);
}

.dashboard-card {
    padding: 2rem;
    min-width: 0;
    overflow: hidden;
}

.dashboard-card .card-title {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    min-width: 0;
    color: var(--text-white);
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
}

.dashboard-card .card-value {
    font-size: 1.85rem;
    line-height: 1.15;
    font-weight: 800;
    color: var(--text-white);
    overflow-wrap: anywhere;
    word-break: break-word;
}

.overview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
    border-radius: 1.5rem;
    background: rgba(10, 22, 46, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.quick-action-button {
    flex: 1 1 180px;
    min-width: 160px;
    padding: 1rem 1.2rem;
    border-radius: 1.25rem;
    border: 1px solid rgba(99, 102, 241, 0.18);
    background: rgba(15, 23, 42, 0.90);
    color: var(--text-white);
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.95rem;
    text-align: center;
    justify-content: center;
    font-weight: 600;
}

.quick-action-button:hover {
    transform: translateY(-3px);
    background: rgba(99, 102, 241, 0.22);
    box-shadow: 0 18px 40px rgba(99, 102, 241, 0.14);
}

.notification-item,
.product-item {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
    padding: 1rem;
    border-radius: 1.1rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--text-white);
    font-weight: 600;
}

.notification-item span:first-child,
.product-item span:first-child {
    color: var(--text-white);
    font-weight: 700;
}

.account-report-panel table th,
.account-report-panel table td {
    padding: 0.85rem;
}

.card-small {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.85);
    font-weight: 500;
}

.dashboard-card .card-small,
.notifications-panel .card-small,
.top-products-panel .card-small,
.account-report-panel .card-small,
.product-card .card-small {
    color: rgba(255, 255, 255, 0.78);
}

.category-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.category-pill {
    padding: 0.55rem 0.95rem;
    border-radius: 999px;
    border: 1px solid rgba(99, 102, 241, 0.18);
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-white);
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
    font-weight: 700;
}

.category-pill:hover,
.category-pill.active {
    background: linear-gradient(135deg, var(--primary), var(--accent-cyan));
    transform: translateY(-1px);
    color: var(--text-white);
}

.product-card {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(99, 102, 241, 0.18);
    border-radius: 1.25rem;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    color: var(--text-white);
    text-transform: capitalize;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 24px 70px rgba(99, 102, 241, 0.12);
}

.product-card .product-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    color: var(--text-white);
    font-weight: 500;
}

.sections-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.section-card {
    background: rgba(10, 22, 46, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 1.5rem;
    padding: 1.5rem;
    text-decoration: none;
    color: var(--text-white);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.section-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 50px rgba(34, 100, 180, 0.15);
    border-color: rgba(34, 100, 180, 0.28);
}

.section-card .section-title {
    font-size: 1rem;
    font-weight: 800;
    color: var(--text-white);
}

.section-card .section-desc {
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.92rem;
    font-weight: 500;
}

.table-container {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin-top: 1rem;
    background: rgba(15, 23, 42, 0.4);
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

th {
    text-align: left;
    padding: 1.25rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.75);
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: rgba(255, 255, 255, 0.02);
}

td {
    padding: 1.1rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.95rem;
    transition: background 0.2s ease;
    text-transform: capitalize;
}

tr {
    transition: background 0.2s ease, transform 0.2s ease;
}

tbody tr:hover td {
    background: rgba(99, 102, 241, 0.12);
}

.login-container {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
    isolation: isolate;
    overflow: hidden;
}

.login-container::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    background-image: url('../images/logo-watermark.svg');
    background-repeat: no-repeat;
    background-position: center;
    background-size: min(76vw, 680px);
    opacity: 0.9;
    pointer-events: none;
}

.login-card {
    max-width: 400px;
    width: 90%;
    position: relative;
    z-index: 1;
}

.order-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
}

.item-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
}

.item-card {
    background: rgba(255, 255, 255, 0.12);
    padding: 1rem;
    border-radius: 1rem;
    text-align: center;
    cursor: pointer;
    transition: 0.3s ease, transform 0.3s ease;
    border: 1px solid rgba(99, 102, 241, 0.15);
    color: var(--text-white);
    font-weight: 700;
}

.item-card:hover {
    border-color: var(--accent-cyan);
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-3px);
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
    background: rgba(255, 255, 255, 0.04);
    padding: 1rem;
    border-radius: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.cart-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateX(4px);
    border-color: rgba(99, 102, 241, 0.3);
}

.cart-item-details .cart-item-name {
    font-weight: 700;
    color: var(--text-white);
    margin-bottom: 0.2rem;
}

.cart-item-details .cart-item-price {
    color: rgba(255, 255, 255, 0.65);
    font-size: 0.85rem;
}

.cart-item-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.cart-item-total {
    font-weight: 800;
    color: var(--accent-cyan);
}

.cart-item-remove {
    background: rgba(239, 68, 68, 0.15);
    border: none;
    color: var(--accent-danger);
    cursor: pointer;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: grid;
    place-items: center;
    transition: background 0.2s ease, transform 0.2s ease;
}

.cart-item-remove:hover {
    background: rgba(239, 68, 68, 0.8);
    color: white;
    transform: scale(1.1);
}

.badge {
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 600;
    color: white;
}

.notification-badge {
    background: var(--accent-danger);
    color: white;
    border-radius: 50%;
    padding: 0.2rem 0.5rem;
    font-size: 0.75rem;
    font-weight: bold;
    margin-left: 5px;
    display: none;
    box-shadow: 0 0 8px rgba(239, 68, 68, 0.6);
}

/* Additional visibility enhancements */
.glass-card h2,
.glass-card h3 {
    color: var(--text-white);
    font-weight: 700;
}

.glass-card p {
    color: rgba(255, 255, 255, 0.78);
    font-weight: 500;
}

span[style*="color: var(--text-gray)"] {
    color: rgba(255, 255, 255, 0.75) !important;
}

.badge {
    font-weight: 700;
    letter-spacing: 0.01em;
}

@media (max-width: 1040px) {
    .layout {
        grid-template-columns: 1fr;
        height: auto;
    }
    .sidebar {
        display: none; /* Hide by default on mobile, toggle via JS */
        position: fixed;
        left: -100%;
        width: 280px;
        z-index: 2000;
        transition: left 0.3s ease;
        height: 100vh;
    }
    .sidebar.active {
        display: block;
        left: 0;
    }
    .mobile-header {
        display: flex !important;
        justify-content: space-between;
        align-items: center;
        padding: 1rem 1.5rem;
        background: var(--card-bg);
        border-bottom: 1px solid var(--border);
        position: sticky;
        top: 0;
        z-index: 1500;
        backdrop-filter: blur(10px);
    }
    .container { padding: 1rem; }
    main.container { height: auto; overflow-y: visible; }
    
    .dashboard-grid, .order-grid, .sections-grid {
        grid-template-columns: 1fr !important;
    }
    
    .overview-grid {
        grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    }

    .dashboard-card {
        padding: 1.25rem;
    }
}

@media (max-width: 640px) {
    .quick-actions {
        flex-direction: column;
    }
    .quick-action-button {
        width: 100%;
    }
    .card-value {
        font-size: 1.5rem;
    }
    .stat-value {
        font-size: 1.8rem;
    }
    .btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }
}

.mobile-header {
    display: none;
}

.menu-toggle {
    background: transparent;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); box-shadow: 0 0 10px var(--accent-success); }
    100% { transform: scale(1); }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: rgba(8, 18, 40, 0.5);
}
::-webkit-scrollbar-thumb {
    background: rgba(99, 102, 241, 0.4);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(99, 102, 241, 0.8);
}

/* Premium Modal Styles - Refined */
.premium-modal-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(12px);
    z-index: 2500;
    justify-content: center;
    align-items: center;
    padding: 1.5rem;
}

.premium-modal {
    background: #ffffff;
    width: 100%;
    max-width: 580px;
    border-radius: 2rem;
    overflow: hidden;
    color: #1e293b;
    box-shadow: 0 40px 100px -20px rgba(0, 0, 0, 0.6);
    display: flex;
    flex-direction: column;
    position: relative;
    font-family: 'Inter', sans-serif;
    animation: modalSlideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

@keyframes modalSlideUp {
    from { transform: translateY(30px) scale(0.98); opacity: 0; }
    to { transform: translateY(0) scale(1); opacity: 1; }
}

.premium-modal-header {
    padding: 2.5rem 2.5rem 1.5rem;
    text-align: center;
    position: relative;
    border-bottom: 1px solid #f1f5f9;
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
}

.premium-modal-header h2 {
    color: #0f172a;
    font-size: 1.85rem;
    font-weight: 800;
    margin: 0;
    letter-spacing: -0.03em;
    text-transform: capitalize;
}

.premium-modal-header .ref-no {
    color: #475569;
    font-size: 1.1rem;
    font-weight: 700;
    margin-top: 0.5rem;
    font-family: 'Courier New', Courier, monospace;
    letter-spacing: 0.1em;
    background: #f1f5f9;
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 0.5rem;
}

.premium-modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: #f1f5f9;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 1.25rem;
    color: #64748b;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.premium-modal-close:hover {
    background: #ef4444;
    color: #ffffff;
    transform: rotate(90deg);
}

.premium-modal-body {
    padding: 2.5rem;
    position: relative;
    max-height: 65vh;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 #f8fafc;
}

.premium-modal-body::-webkit-scrollbar {
    width: 6px;
}

.premium-modal-body::-webkit-scrollbar-track {
    background: #f8fafc;
}

.premium-modal-body::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}

.premium-modal-body::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url('../images/watermark.png');
    background-repeat: no-repeat;
    background-position: center;
    background-size: 70%;
    opacity: 0.04;
    pointer-events: none;
    z-index: 0;
    filter: invert(1) grayscale(100%);
    mix-blend-mode: screen;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-bottom: 2.5rem;
    position: relative;
    z-index: 1;
}

.info-item label {
    display: block;
    color: #94a3b8;
    font-size: 0.85rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 0.5rem;
}

.info-item span {
    display: block;
    color: #1e293b;
    font-weight: 700;
    font-size: 1.15rem;
}

.items-table-premium {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 2rem;
    position: relative;
    z-index: 1;
}

.items-table-premium th {
    text-align: left;
    color: #94a3b8;
    font-size: 0.8rem;
    font-weight: 800;
    text-transform: uppercase;
    padding: 1rem 0;
    border-bottom: 2px solid #f1f5f9;
    position: sticky;
    top: 0;
    background: #ffffff;
    z-index: 10;
}

.items-table-premium td {
    padding: 1.5rem 0;
    border-bottom: 1px solid #f8fafc;
    color: #334155;
    vertical-align: top;
}

.items-table-premium td .item-name {
    font-weight: 800;
    color: #0f172a;
    display: block;
    font-size: 1.05rem;
    margin-bottom: 0.25rem;
}

.items-table-premium td .item-ref {
    color: #64748b;
    font-size: 0.85rem;
    font-weight: 600;
    background: #f8fafc;
    padding: 0.1rem 0.4rem;
    border-radius: 0.25rem;
}

.total-section-premium {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 0 1rem;
    border-top: 3px solid #0f172a;
    margin-top: 1.5rem;
    position: relative;
    z-index: 1;
}

.total-label-premium {
    font-size: 1.4rem;
    font-weight: 900;
    color: #0f172a;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.total-amount-premium {
    font-size: 2.2rem;
    font-weight: 900;
    color: #0f172a;
    letter-spacing: -0.02em;
}

.premium-modal-footer {
    padding: 0 2.5rem 3rem;
    position: relative;
    z-index: 1;
}

.btn-close-premium {
    width: 100%;
    padding: 1.5rem;
    background: #ef4444;
    color: #ffffff;
    border: none;
    border-radius: 1.25rem;
    font-weight: 900;
    font-size: 1.25rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 15px 35px rgba(239, 68, 68, 0.35);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.btn-close-premium:hover {
    background: #dc2626;
    transform: translateY(-4px);
    box-shadow: 0 20px 45px rgba(239, 68, 68, 0.45);
}

.btn-close-premium:active {
    transform: translateY(-2px);
}

/* Classic hotel dashboard colour theme
   Appearance only: layout, spacing, behaviour, and component structure remain unchanged. */
:root {
    --primary: #19b8c4;
    --primary-hover: #109aa8;
    --accent-cyan: #20c4c9;
    --accent-magenta: #e85d75;
    --bg: #eef1f4;
    --bg-body: #eef1f4;
    --card-bg: #ffffff;
    --text-dark: #273746;
    --text-gray: #71808d;
    --text-white: #273746;
    --accent-success: #58b86a;
    --accent-danger: #ed6a63;
    --accent-warning: #f5b942;
    --glass: #ffffff;
    --border: #dce3e8;
}

body {
    background: #eef1f4;
    color: #273746;
}

body::before {
    opacity: 0.035;
    filter: grayscale(100%);
    mix-blend-mode: multiply;
}

.sidebar {
    background: #263b50;
    border-right: 1px solid #1d3042;
    box-shadow: inset -2px 0 0 rgba(32, 196, 201, 0.12);
}

.sidebar h2 {
    color: #55c7ca;
}

.nav-links a {
    color: #d8e1e8;
}

.nav-links a:hover,
.nav-links a.active {
    background: #314b63;
    color: #ffffff;
}

.nav-links a:hover::before,
.nav-links a.active::before {
    background: #20c4c9;
}

main.container {
    background: #eef1f4;
}

main.container h1,
main.container h2,
main.container h3,
main.container p,
main.container span,
main.container label {
    color: #273746 !important;
    text-shadow: none !important;
}

.glass-card,
.dashboard-card,
.notifications-panel,
.top-products-panel,
.account-report-panel,
.section-card,
.stat-card,
.quick-actions {
    background: #ffffff;
    border: 1px solid #dce3e8;
    color: #273746;
    box-shadow: 0 3px 12px rgba(39, 55, 70, 0.08);
}

.dashboard-card .card-title,
.dashboard-card .card-value,
.stat-value,
.notification-card strong,
.top-products-panel .panel-header h3,
.notifications-panel .panel-header h3,
.notification-item span:first-child,
.product-item span:first-child,
.section-card .section-title,
.product-card,
.product-card .product-meta,
.category-pill,
.item-card,
.cart-item-details .cart-item-name {
    color: #273746;
}

.card-small,
.dashboard-card .card-small,
.notifications-panel .card-small,
.top-products-panel .card-small,
.account-report-panel .card-small,
.product-card .card-small,
.section-card .section-desc {
    color: #71808d !important;
}

.notification-card,
.notification-item,
.product-item,
.top-products-panel .product-card,
.product-card,
.item-card,
.cart-item {
    background: #f7f9fa;
    border-color: #e0e6ea;
}

.notification-card:hover,
.product-card:hover,
.item-card:hover,
.cart-item:hover {
    background: #eef8f8;
    border-color: #20c4c9;
}

.quick-action-button,
.category-pill {
    background: #f7f9fa;
    border-color: #dce3e8;
    color: #273746;
}

.quick-action-button:hover,
.category-pill:hover,
.category-pill.active {
    background: #20b9bf;
    color: #ffffff;
}

.form-control {
    background: #ffffff;
    border-color: #cbd6dd;
    color: #273746;
}

.form-control::placeholder {
    color: #8a98a3;
}

.form-control option {
    background: #ffffff;
    color: #273746;
}

table {
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(39, 55, 70, 0.06);
}

th {
    background: #f1f4f6;
    border-bottom-color: #dce3e8;
    color: #526371;
}

td {
    border-bottom-color: #e7ecef;
    color: #3e4f5c;
}

tbody tr:hover td {
    background: #eef8f8;
}

.btn-primary {
    background: #20b9bf;
    box-shadow: 0 5px 14px rgba(32, 185, 191, 0.22);
}

.btn-primary:hover {
    background: #109aa8;
}

.btn-success {
    background: #58b86a;
    box-shadow: 0 5px 14px rgba(88, 184, 106, 0.2);
}

.btn-danger {
    background: #ed6a63;
    box-shadow: 0 5px 14px rgba(237, 106, 99, 0.2);
}

.badge,
.notification-badge {
    color: #ffffff !important;
}

/* Some pages contain older inline dark-theme colours. Keep content readable
   against the new light workspace without changing any page behaviour. */
main.container [style*="color: #fff"],
main.container [style*="color:#fff"],
main.container [style*="color: #ffffff"],
main.container [style*="color:#ffffff"],
main.container [style*="color: rgba(255,255,255"],
main.container [style*="color:rgba(255,255,255"] {
    color: #273746 !important;
}

main.container [style*="background: rgba(255,255,255"],
main.container [style*="background:rgba(255,255,255"] {
    background: #f7f9fa !important;
    border-color: #e0e6ea !important;
}

main.container .btn,
main.container .badge,
main.container .notification-badge,
main.container button[style*="color: #fff"],
main.container button[style*="color:#fff"],
main.container button[style*="color: white"] {
    color: #ffffff !important;
}

main.container .form-control[style*="color: #fff"],
main.container .form-control[style*="color:#fff"] {
    color: #273746 !important;
    background: #ffffff !important;
}

.login-container h1,
.login-container p {
    color: #273746 !important;
    text-shadow: none !important;
}

/* Settings page controls use legacy inline dark-theme styles. */
#commissionSettingsCard .form-control,
#receiptSettingsCard .form-control,
#deductionRulesCard .form-control,
#recipesCard .form-control {
    background: #ffffff !important;
    border: 1px solid #b9c8d1 !important;
    color: #273746 !important;
    caret-color: #273746;
}

#commissionSettingsCard .form-control:focus,
#receiptSettingsCard .form-control:focus,
#deductionRulesCard .form-control:focus,
#recipesCard .form-control:focus {
    border-color: #20b9bf !important;
    box-shadow: 0 0 0 3px rgba(32, 185, 191, 0.18);
}

#commissionSettingsCard label,
#receiptSettingsCard label,
#deductionRulesCard label,
#recipesCard label,
#commissionSettingsCard small,
#receiptSettingsCard small,
#deductionRulesCard em,
#recipesCard em {
    color: #526371 !important;
}

#recipeModal > div {
    background: #ffffff !important;
    border: 1px solid #dce3e8;
}

#recipeModal h3,
#recipeModal label {
    color: #273746 !important;
}

#recipeModal .form-control,
#recipeModal input,
#recipeModal select {
    background: #ffffff !important;
    border: 1px solid #b9c8d1 !important;
    color: #273746 !important;
}

#recipeModal button[style*="background:transparent"] {
    color: #526371 !important;
}

/* High-contrast dialog surfaces across admin and cashier pages. */
[id$="Modal"] > div:not(.premium-modal),
.modal-content {
    background: #ffffff !important;
    color: #273746 !important;
    border: 1px solid #dce3e8;
    box-shadow: 0 18px 50px rgba(39, 55, 70, 0.24);
}

[id$="Modal"] > div:not(.premium-modal) h2,
[id$="Modal"] > div:not(.premium-modal) h3,
[id$="Modal"] > div:not(.premium-modal) label,
[id$="Modal"] > div:not(.premium-modal) p,
[id$="Modal"] > div:not(.premium-modal) small,
[id$="Modal"] > div:not(.premium-modal) em,
[id$="Modal"] > div:not(.premium-modal) strong,
[id$="Modal"] > div:not(.premium-modal) span:not(.badge):not(.notification-badge),
.modal-content h2,
.modal-content h3,
.modal-content label,
.modal-content p,
.modal-content small {
    color: #273746 !important;
    text-shadow: none !important;
}

[id$="Modal"] > div:not(.premium-modal) .form-control,
.modal-content .form-control,
[id$="Modal"] > div:not(.premium-modal) input,
[id$="Modal"] > div:not(.premium-modal) select,
[id$="Modal"] > div:not(.premium-modal) textarea {
    background: #ffffff !important;
    border: 1px solid #b9c8d1 !important;
    color: #273746 !important;
}

[id$="Modal"] > div:not(.premium-modal) .form-control:focus,
.modal-content .form-control:focus,
[id$="Modal"] > div:not(.premium-modal) input:focus,
[id$="Modal"] > div:not(.premium-modal) select:focus,
[id$="Modal"] > div:not(.premium-modal) textarea:focus {
    outline: none;
    border-color: #20b9bf !important;
    box-shadow: 0 0 0 3px rgba(32, 185, 191, 0.18);
}

[id$="Modal"] > div:not(.premium-modal) .btn,
[id$="Modal"] > div:not(.premium-modal) .badge,
[id$="Modal"] > div:not(.premium-modal) button {
    color: #ffffff !important;
}

[id$="Modal"] > div:not(.premium-modal) .btn-close-premium,
[id$="Modal"] > div:not(.premium-modal) .badge {
    color: #ffffff !important;
}

@media (max-width: 640px) {
    [id$="Modal"] > div:not(.premium-modal),
    .modal-content {
        width: calc(100% - 2rem) !important;
        max-width: calc(100% - 2rem) !important;
        padding: 1.25rem !important;
    }
}

/* Softer light surfaces: reduce glare while keeping strong contrast. */
body,
main.container {
    background: #edf0f2;
}

.glass-card,
.dashboard-card,
.notifications-panel,
.top-products-panel,
.account-report-panel,
.section-card,
.stat-card,
.quick-actions {
    background: #f7f8f9 !important;
}

table {
    background: #f8fafb !important;
}

/* Checkout dialog readability and alignment. */
#checkoutModal {
    padding: 1rem;
    background: rgba(25, 37, 48, 0.72) !important;
}

#checkoutModal > .glass-card {
    width: min(420px, 100%) !important;
    max-height: calc(100vh - 2rem) !important;
    padding: 1.35rem !important;
    overflow-y: auto;
    background: #ffffff !important;
    border: 1px solid #d2dce2 !important;
    border-radius: 0.7rem;
    color: #273746 !important;
    box-shadow: 0 20px 55px rgba(24, 39, 52, 0.3) !important;
}

#checkoutModal h2 {
    margin-top: 0;
    color: #273746 !important;
    font-size: 1.35rem;
    line-height: 1.25;
    text-shadow: none !important;
}

#checkoutModal label,
#checkoutModal span,
#checkoutModal p,
#checkoutModal .card-small {
    color: #526371 !important;
    text-shadow: none !important;
}

#checkoutModal .form-control,
#checkoutModal input,
#checkoutModal select {
    min-height: 2.55rem;
    background: #ffffff !important;
    border: 1px solid #b9c8d1 !important;
    border-radius: 0.35rem;
    color: #273746 !important;
}

#checkoutModal .form-control::placeholder,
#checkoutModal input::placeholder {
    color: #9aa7af !important;
}

#checkoutModal #paymentMethodSection > div {
    align-items: stretch;
}

#checkoutModal button[id$="Tab"] {
    min-height: 2.45rem;
    padding: 0.55rem 0.65rem;
    background: #edf2f4 !important;
    border: 1px solid #d3dfe4 !important;
    border-radius: 0.35rem;
    color: #526371 !important;
    font-size: 0.78rem;
    line-height: 1.15;
}

#checkoutModal button[id$="Tab"][style*="accent-success"] {
    background: #58b86a !important;
    border-color: #58b86a !important;
    color: #ffffff !important;
}

#checkoutModal #processPaymentBtn,
#checkoutModal button[onclick*="checkoutModal"] {
    min-height: 2.55rem;
    font-weight: 700;
}

@media (max-width: 480px) {
    #checkoutModal > .glass-card {
        padding: 1rem !important;
    }

    #checkoutModal #paymentMethodSection > div {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Scheduled-order state inside the checkout dialog. */
#checkoutModal:has(#isScheduledCheckbox:checked) #scheduledFields {
    display: block !important;
    padding: 0.85rem;
    background: #f1faf8;
    border: 1px solid #c5e8dc;
    border-radius: 0.45rem;
}

#checkoutModal:has(#isScheduledCheckbox:checked) #scheduledFields label {
    color: #35645b !important;
    font-weight: 700;
}

#checkoutModal:has(#isScheduledCheckbox:checked) #scheduledForInput {
    border-color: #58b86a !important;
    background: #ffffff !important;
    box-shadow: 0 0 0 3px rgba(88, 184, 106, 0.12);
}

#checkoutModal:has(#isScheduledCheckbox:checked) #processPaymentBtn {
    background: linear-gradient(135deg, #20b9bf, #1596a2) !important;
    color: #ffffff !important;
    min-width: 11rem;
}

#checkoutModal:has(#isScheduledCheckbox:checked) #savePendingOrderBtn {
    display: none;
}

@media (max-width: 480px) {
    #checkoutModal:has(#isScheduledCheckbox:checked) #processPaymentBtn {
        min-width: 0;
        flex: 1;
    }
}

    /* Order Successful dialog. */
    #postCheckoutModal {
        background: rgba(25, 37, 48, 0.76) !important;
        backdrop-filter: blur(8px);
    }

    #postCheckoutModal .premium-modal {
        max-width: 510px;
        border-radius: 1rem;
        border: 1px solid #d9e5e8;
        box-shadow: 0 24px 65px rgba(24, 39, 52, 0.32);
    }

    #postCheckoutModal .premium-modal-header {
        padding: 2rem 1.5rem 1.25rem;
        background: linear-gradient(180deg, #effbf7 0%, #ffffff 100%);
        border-bottom-color: #e3efec;
    }

    #postCheckoutModal .premium-modal-header > div:first-child {
        width: 4.25rem !important;
        height: 4.25rem !important;
        margin-bottom: 1rem !important;
        background: linear-gradient(135deg, #58b86a, #20b9a1) !important;
        border: 4px solid #ffffff !important;
        box-shadow: 0 8px 20px rgba(45, 166, 118, 0.28) !important;
    }

    #postCheckoutModal .premium-modal-header h2 {
        color: #1f3d3a !important;
        font-size: 1.6rem;
        text-shadow: none !important;
    }

    #postCheckoutModal .premium-modal-body {
        padding: 1.5rem;
        background: #ffffff;
    }

    #postCheckoutModal .premium-modal-footer {
        padding: 1rem 1.5rem 1.5rem;
        background: #ffffff;
        border-top: 1px solid #edf1f2;
    }

    #postCheckoutModal .btn-close-premium {
        width: 100%;
        min-height: 2.8rem;
        border-radius: 0.45rem;
        background: linear-gradient(135deg, #273746, #405565) !important;
        box-shadow: 0 8px 18px rgba(39, 55, 70, 0.2) !important;
    }

    /* Transaction History page contrast. */
    body:has(#transactionHistoryBody) > .layout .container h1,
    body:has(#transactionHistoryBody) > .layout .container h3 {
        color: #273746 !important;
        text-shadow: none !important;
    }

    body:has(#transactionHistoryBody) > .layout .container .glass-card {
        background: #f7f8f9 !important;
        border-color: #dce3e8 !important;
        box-shadow: 0 4px 14px rgba(39, 55, 70, 0.08);
    }

    body:has(#transactionHistoryBody) .form-group label {
        color: #526371 !important;
        text-shadow: none !important;
        font-weight: 700;
    }

    body:has(#transactionHistoryBody) .form-control {
        background: #ffffff !important;
        border-color: #b9c8d1 !important;
        color: #273746 !important;
    }

    body:has(#transactionHistoryBody) .glass-card > div:first-child > .btn {
        color: #273746 !important;
        background: #ffffff !important;
        border-color: #20b9bf !important;
    }

    body:has(#transactionHistoryBody) table thead th {
        color: #526371 !important;
        background: #e8eef1 !important;
        border-bottom-color: #cbd7dc !important;
    }

    body:has(#transactionHistoryBody) table tbody td {
        color: #273746 !important;
        background: #ffffff !important;
        border-bottom-color: #e1e7ea !important;
    }

    body:has(#transactionHistoryBody) table tbody tr:hover td {
        background: #eefafa !important;
    }

    body:has(#transactionHistoryBody) table tbody td .badge {
        color: #ffffff !important;
    }

    @media (max-width: 640px) {
        body:has(#transactionHistoryBody) .info-grid {
            grid-template-columns: 1fr !important;
            gap: 1rem !important;
        }
    }

    /* Shared transaction details readability across the system. */
    #paymentDetailModal .premium-modal,
    #orderDetailModal .premium-modal,
    #postCheckoutModal .premium-modal {
        background: #ffffff !important;
        color: #273746 !important;
        border: 1px solid #d6e0e5 !important;
    }

    #paymentDetailModal .premium-modal-header,
    #orderDetailModal .premium-modal-header,
    #postCheckoutModal .premium-modal-header {
        background: linear-gradient(180deg, #f1f7f8 0%, #ffffff 100%) !important;
        border-bottom-color: #e1e9ec !important;
    }

    #paymentDetailModal .premium-modal-header h2,
    #orderDetailModal .premium-modal-header h2,
    #postCheckoutModal .premium-modal-header h2 {
        color: #273746 !important;
        text-shadow: none !important;
    }

    #paymentDetailModal .info-grid,
    #orderDetailModal .info-grid,
    #postCheckoutModal .info-grid {
        background: #f4f7f8 !important;
        border: 1px solid #dce5e8 !important;
    }

    #paymentDetailModal .info-item label,
    #orderDetailModal .info-item label,
    #postCheckoutModal .info-item label {
        color: #687984 !important;
        text-shadow: none !important;
    }

    #paymentDetailModal .info-item span,
    #orderDetailModal .info-item span,
    #postCheckoutModal .info-item span {
        color: #273746 !important;
        text-shadow: none !important;
    }

    #paymentDetailModal .items-table-premium,
    #orderDetailModal .items-table-premium,
    #postCheckoutModal .items-table-premium {
        background: #ffffff !important;
    }

    #paymentDetailModal .items-table-premium th,
    #orderDetailModal .items-table-premium th,
    #postCheckoutModal .items-table-premium th {
        color: #526371 !important;
        background: #eaf0f2 !important;
        border-bottom-color: #cdd9de !important;
    }

    #paymentDetailModal .items-table-premium td,
    #orderDetailModal .items-table-premium td,
    #postCheckoutModal .items-table-premium td {
        color: #273746 !important;
        background: #ffffff !important;
        border-bottom-color: #e1e7ea !important;
    }

    #paymentDetailModal .items-table-premium .item-name,
    #orderDetailModal .items-table-premium .item-name,
    #postCheckoutModal .items-table-premium .item-name {
        color: #273746 !important;
    }

    #paymentDetailModal .total-section-premium,
    #orderDetailModal .total-section-premium,
    #postCheckoutModal .total-section-premium {
        background: #eefafa !important;
        border-color: #c8e6e7 !important;
        box-shadow: none !important;
    }

    #paymentDetailModal .total-label-premium,
    #orderDetailModal .total-label-premium,
    #postCheckoutModal .total-label-premium {
        color: #35645b !important;
    }

    #paymentDetailModal .total-amount-premium,
    #orderDetailModal .total-amount-premium,
    #postCheckoutModal .total-amount-premium {
        color: #138b93 !important;
        text-shadow: none !important;
    }

    #paymentDetailModal .premium-modal-footer,
    #orderDetailModal .premium-modal-footer,
    #postCheckoutModal .premium-modal-footer {
        background: #f7f9fa !important;
        border-top-color: #e1e7ea !important;
    }

.form-control,
#commissionSettingsCard .form-control,
#receiptSettingsCard .form-control,
#deductionRulesCard .form-control,
#recipesCard .form-control,
#recipeModal .form-control,
#recipeModal input,
#recipeModal select,
[id$="Modal"] > div:not(.premium-modal) input,
[id$="Modal"] > div:not(.premium-modal) select,
[id$="Modal"] > div:not(.premium-modal) textarea {
    background: #fbfcfc !important;
}

[id$="Modal"] > div:not(.premium-modal),
.modal-content,
#recipeModal > div {
    background: #f7f8f9 !important;
}

.premium-modal {
    background: #f8fafb;
}

.premium-modal-header {
    background: linear-gradient(180deg, #f1f4f6 0%, #f8fafb 100%);
}

.items-table-premium th {
    background: #f8fafb;
}

/* Attendance status controls: selected states use strong semantic colours;
   unselected states use a neutral surface with dark text. */
#attendanceBody .btn {
    border: 1px solid #c7d2d9;
    font-weight: 700;
    min-width: 5.5rem;
}

.tabs {
    border-bottom: 1px solid #cbd6dd !important;
}

.tab {
    color: #61727e !important;
}

.tab.active {
    color: #109aa8 !important;
    border-bottom-color: #20b9bf !important;
}

#attendanceBody td,
#weeklyBody td,
#workersBody td,
#paymentsBody td {
    vertical-align: middle;
}

#attendanceBody td:last-child > div {
    flex-wrap: wrap;
    align-items: center;
}

#attendanceBody button[style*="accent-success"] {
    background: #58b86a !important;
    color: #ffffff !important;
    border-color: #469b56 !important;
}

#attendanceBody button[style*="accent-danger"] {
    background: #ed6a63 !important;
    color: #ffffff !important;
    border-color: #d95650 !important;
}

#attendanceBody button[style*="accent-warning"] {
    background: #f5b942 !important;
    color: #273746 !important;
    border-color: #d99f2d !important;
}

#attendanceBody button[style*="rgba(255,255,255"] {
    background: #e3e9ed !important;
    color: #526371 !important;
}

/* POS food and drink display: clean product tiles inspired by the reference. */
.order-grid > .glass-card:first-child {
    background: #f7f8f9 !important;
    border-color: #dce3e8;
    box-shadow: 0 3px 12px rgba(39, 55, 70, 0.08);
}

.order-grid > .glass-card:first-child .form-control {
    background: #ffffff !important;
    border-color: #e0e6ea !important;
    color: #273746 !important;
    box-shadow: none;
}

.order-grid > .glass-card:first-child .form-control::placeholder {
    color: #9aa7af;
}

.item-list {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 0.55rem;
}

.item-list .product-card {
    min-height: 150px;
    padding: 0.8rem;
    gap: 0.55rem;
    background: #ffffff !important;
    border: 1px solid #e5eaed !important;
    border-radius: 0.35rem;
    box-shadow: 0 2px 6px rgba(39, 55, 70, 0.06);
    color: #273746 !important;
}

.item-list .product-card:hover {
    transform: translateY(-2px);
    background: #ffffff !important;
    border-color: #20b9bf !important;
    box-shadow: 0 6px 14px rgba(32, 185, 191, 0.16);
}

.item-list .product-card.selected-highlight {
    background: #eefafa !important;
    border: 2px solid #20b9bf !important;
    box-shadow: 0 6px 16px rgba(32, 185, 191, 0.18) !important;
    transform: none;
}

.item-list .product-card > div:first-child {
    align-items: flex-start !important;
    min-height: 4.5rem;
}

.item-list .product-card > div:first-child > div:first-child {
    align-items: center;
    gap: 0.45rem !important;
    flex-direction: column;
    width: 100%;
    text-align: center;
}

.item-list .product-card > div:first-child i {
    display: grid;
    place-items: center;
    width: 3.25rem;
    height: 3.25rem;
    padding: 0.7rem;
    border-radius: 50%;
    background: #f1f5f6;
    font-size: 1.65rem !important;
}

.item-list .product-card > div:first-child strong {
    color: #273746 !important;
    font-size: 0.86rem;
    line-height: 1.2;
    font-weight: 700;
}

.item-list .product-card .product-meta {
    margin-top: auto !important;
    padding-top: 0.45rem !important;
    border-top: 1px solid #edf0f2 !important;
    align-items: flex-end;
    color: #7b8992 !important;
}

.item-list .product-card .product-meta span {
    color: #7b8992 !important;
    font-size: 0.7rem !important;
}

.item-list .product-card .product-meta strong {
    color: #d9534f !important;
    font-size: 0.86rem !important;
    white-space: nowrap;
}

.order-grid > .glass-card:first-child .category-filters {
    gap: 0.35rem;
}

.order-grid > .glass-card:first-child .category-pill {
    padding: 0.4rem 0.7rem;
    border-radius: 0.25rem;
    background: #ffffff;
    border-color: #e0e6ea;
    color: #61727e !important;
    font-size: 0.78rem;
}

.order-grid > .glass-card:first-child .category-pill:hover,
.order-grid > .glass-card:first-child .category-pill.active {
    background: #20b9bf;
    border-color: #20b9bf;
    color: #ffffff !important;
}

@media (max-width: 640px) {
    .item-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.cart-item-details .cart-item-price {
    color: #71808d;
}

.cart-item-total {
    color: #109aa8;
}

::-webkit-scrollbar-track {
    background: #e7ecef;
}

::-webkit-scrollbar-thumb {
    background: #9aabb7;
}

::-webkit-scrollbar-thumb:hover {
    background: #718896;
}
