@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Inter:wght@300;400;500;600;700&display=swap');

/* Dynamic Design System Variables */
:root {
    --primary: #f1b827;        /* Crisp Panipuri Amber */
    --primary-rgb: 241, 184, 39;
    --secondary: #16a34a;      /* Fresh Mint Water Green */
    --secondary-rgb: 22, 163, 74;
    
    /* Backgrounds */
    --bg-dark: #0f0f12;
    --bg-card: rgba(22, 22, 29, 0.65);
    --bg-glass: rgba(15, 15, 18, 0.6);
    --border-glass: rgba(255, 255, 255, 0.08);
    
    /* Text */
    --text-primary: #f3f4f6;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;
    
    /* UI States */
    --danger: #ef4444;
    --warning: #f59e0b;
    --success: #10b981;
    
    /* Layouts */
    --sidebar-width: 280px;
    --border-radius: 16px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Custom Theme Background (Dynamically injected) */
    --theme-bg-img: none;
}

/* Light Theme Override */
body.light-mode {
    --bg-dark: #f8f9fa;
    --bg-card: rgba(255, 255, 255, 0.85);
    --bg-glass: rgba(255, 255, 255, 0.7);
    --border-glass: rgba(0, 0, 0, 0.08);
    --text-primary: #111827;
    --text-secondary: #4b5563;
    --text-muted: #9ca3af;
}

/* Reset and Core Styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Prevent ALL horizontal overflow at root level */
html {
    overflow-x: hidden;
    max-width: 100vw;
}

body {
    font-family: 'Outfit', 'Inter', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-primary);
    overflow-x: hidden;
    min-height: 100vh;
    transition: background-color 0.4s ease, color 0.4s ease;
    position: relative;
}

/* Dynamic Brand Background Theme */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: var(--theme-bg-img);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0.15;
    z-index: -1;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-dark);
}
::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* Utility Glassmorphism Classes */
.glass-panel {
    background: var(--bg-glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-glass);
    border-radius: var(--border-radius);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.25);
    transition: var(--transition);
}

.glass-card {
    background: var(--bg-card);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--border-glass);
    border-radius: var(--border-radius);
    padding: 24px;
    box-shadow: 0 4px 20px 0 rgba(0, 0, 0, 0.15);
    transition: var(--transition);
}

.glass-card:hover {
    border-color: rgba(var(--primary-rgb), 0.3);
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(var(--primary-rgb), 0.1);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition);
    border: 1px solid transparent;
    font-family: 'Outfit', sans-serif;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, #d9a01b 100%);
    color: #000;
    box-shadow: 0 4px 15px rgba(var(--primary-rgb), 0.3);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(var(--primary-rgb), 0.5);
}

.btn-secondary {
    background: linear-gradient(135deg, var(--secondary) 0%, #15803d 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(var(--secondary-rgb), 0.3);
}
.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(var(--secondary-rgb), 0.5);
}

.btn-danger {
    background: linear-gradient(135deg, var(--danger) 0%, #b91c1c 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}
.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.5);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-glass);
}
.btn-outline:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--text-secondary);
}

/* Typography and Headings */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.text-gradient {
    background: linear-gradient(135deg, var(--primary) 0%, #fcd34d 50%, var(--secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Main Navigation Bar for Customer Mode */
.nav-header {
    height: 80px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 5%;
    position: sticky;
    top: 0;
    z-index: 100;
    margin-bottom: 30px;
    border-bottom: 1px solid var(--border-glass);
    border-radius: 0 0 20px 20px;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-logo img {
    height: 48px;
    width: 48px;
    object-fit: contain;
    border-radius: 50%;
    border: 2px solid var(--primary);
}

.brand-logo h1 {
    font-size: 24px;
    font-weight: 800;
    color: var(--text-primary);
}

.nav-links {
    display: none; /* Hidden on desktop */
    align-items: center;
    gap: 20px;
    list-style: none;
}

/* Desktop nav (inside nav-header, hidden on mobile) */
.nav-links-desktop {
    display: flex;
    align-items: center;
    gap: 20px;
    list-style: none;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 15px;
    padding: 8px 16px;
    border-radius: 8px;
    transition: var(--transition);
}

.nav-link:hover, .nav-link.active {
    color: var(--primary);
    background: rgba(var(--primary-rgb), 0.08);
}

/* Page Containers */
.page-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px 80px 20px;
}

.page {
    display: none;
    animation: fadeIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.page.active {
    display: block;
}

/* Maintenance Page */
.maintenance-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    min-height: 80vh;
    padding: 40px 20px;
}

.maintenance-illustration {
    font-size: 80px;
    margin-bottom: 24px;
    animation: bounce 2s infinite;
}

.maintenance-container h1 {
    font-size: 42px;
    margin-bottom: 16px;
    color: var(--primary);
}

.maintenance-container p {
    font-size: 18px;
    color: var(--text-secondary);
    max-width: 500px;
    margin-bottom: 30px;
    line-height: 1.6;
}

/* Customer Menu Section */
.menu-header-bar {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 40px;
}

@media(min-width: 768px) {
    .menu-header-bar {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
}

.category-tabs {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 8px;
    scrollbar-width: none;
}
.category-tabs::-webkit-scrollbar {
    display: none;
}

.tab {
    padding: 10px 20px;
    border-radius: 30px;
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    color: var(--text-secondary);
    cursor: pointer;
    font-weight: 500;
    white-space: nowrap;
    transition: var(--transition);
}

.tab:hover, .tab.active {
    background: var(--primary);
    color: #000;
    border-color: var(--primary);
    box-shadow: 0 4px 12px rgba(var(--primary-rgb), 0.2);
}

.menu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.menu-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
    border-radius: var(--border-radius);
    height: 100%;
}

.menu-card-img-container {
    height: 200px;
    overflow: hidden;
    position: relative;
    background: rgba(255, 255, 255, 0.02);
}

.menu-card-img-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.menu-card:hover .menu-card-img-container img {
    transform: scale(1.1);
}

.menu-card-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.7);
    color: var(--primary);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    border: 1px solid rgba(var(--primary-rgb), 0.3);
    backdrop-filter: blur(5px);
}

.menu-card-body {
    padding: 24px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.menu-card-title {
    font-size: 19px;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.menu-card-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 20px;
    flex-grow: 1;
}

.menu-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-glass);
    padding-top: 15px;
    margin-top: auto;
}

.menu-card-price {
    font-size: 22px;
    font-weight: 800;
    color: var(--primary);
}

.menu-card-category {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Reviews Styling */
.reviews-summary {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

@media(min-width: 768px) {
    .reviews-summary {
        grid-template-columns: 1fr 2fr;
    }
}

.rating-big-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    text-align: center;
}

.rating-big-num {
    font-size: 64px;
    font-weight: 800;
    color: var(--primary);
    line-height: 1;
}

.rating-stars {
    display: flex;
    gap: 4px;
    color: var(--primary);
    font-size: 20px;
    margin: 10px 0;
}

.reviews-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    margin-top: 30px;
}

.review-card {
    padding: 24px;
    border-radius: var(--border-radius);
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
}

.review-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.reviewer-name {
    font-weight: 600;
    font-size: 16px;
    color: var(--text-primary);
}

.review-date {
    font-size: 12px;
    color: var(--text-muted);
}

.review-text {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.review-img {
    width: 100%;
    max-height: 200px;
    object-fit: cover;
    border-radius: 8px;
    margin-top: 8px;
    border: 1px solid var(--border-glass);
}

/* Form Styles */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-glass);
    border-radius: 10px;
    color: var(--text-primary);
    font-family: inherit;
    font-size: 15px;
    transition: var(--transition);
}

select.form-control option {
    background-color: #1e1e24;
    color: #f3f4f6;
}

body.light-mode select.form-control option {
    background-color: #ffffff;
    color: #111827;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.06);
    box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.1);
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

/* Star Rating Selector Form */
.star-selector {
    display: flex;
    gap: 8px;
    font-size: 28px;
    color: var(--text-muted);
    cursor: pointer;
    margin: 8px 0;
}

.star-selector i.active {
    color: var(--primary);
    text-shadow: 0 0 10px rgba(var(--primary-rgb), 0.4);
}

/* Admin Dashboard Wrapper Layout */
.admin-layout {
    display: none;
    min-height: 100vh;
    background-color: #0b0b0d;
}

.admin-layout.active {
    display: flex;
}

.admin-sidebar {
    width: var(--sidebar-width);
    background: #0f0f12;
    border-right: 1px solid var(--border-glass);
    padding: 30px 20px;
    display: flex;
    flex-direction: column;
    gap: 30px;
    position: fixed;
    height: 100vh;
    left: 0;
    top: 0;
    z-index: 99;
}

.admin-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.admin-logo h2 {
    font-size: 20px;
    color: var(--text-primary);
    font-weight: 800;
}

.admin-menu {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.admin-menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-secondary);
    text-decoration: none;
    padding: 12px 16px;
    border-radius: 10px;
    font-weight: 500;
    font-size: 15px;
    cursor: pointer;
    transition: var(--transition);
}

.admin-menu-item:hover, .admin-menu-item.active {
    color: var(--primary);
    background: rgba(var(--primary-rgb), 0.1);
}

.admin-menu-item i {
    font-size: 18px;
}

.admin-sidebar-footer {
    margin-top: auto;
    border-top: 1px solid var(--border-glass);
    padding-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.admin-user-info {
    display: flex;
    flex-direction: column;
}

.admin-username {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 15px;
}

.admin-role {
    font-size: 12px;
    color: var(--text-muted);
}

.admin-main {
    margin-left: var(--sidebar-width);
    flex-grow: 1;
    padding: 40px;
    min-height: 100vh;
    overflow-y: auto;
    min-width: 0;
}

.admin-section {
    display: none;
    animation: fadeIn 0.4s ease;
}

.admin-section.active {
    display: block;
}

.admin-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

/* Dashboard Cards / Statistics Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.stat-card {
    padding: 24px;
    border-radius: var(--border-radius);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.stat-card-title {
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 500;
}

.stat-card-value {
    font-size: 28px;
    font-weight: 800;
    color: var(--text-primary);
}

.stat-card-icon {
    font-size: 24px;
    color: var(--primary);
    margin-bottom: 10px;
}

/* Order Entry Area Layout */
.order-entry-layout {
    display: flex;
    flex-direction: row;
    gap: 30px;
    flex-wrap: wrap;
    align-items: stretch;
}
.order-entry-layout > .glass-card:first-of-type {
    flex: 1.3 1 500px;
    display: flex;
    flex-direction: column;
}
.order-entry-layout > .glass-card.cart-panel {
    flex: 1 1 360px;
    display: flex;
    flex-direction: column;
}

@media(max-width: 1024px) {
    .order-entry-layout {
        flex-direction: column;
        gap: 20px;
    }
    .order-entry-layout > .glass-card:first-of-type {
        flex: 1 1 auto;
        width: 100%;
        min-width: 0;
    }
    .order-entry-layout > .glass-card.cart-panel {
        flex: 1 1 auto;
        width: 100%;
        min-width: 0;
        height: auto;
    }
}

.order-catalog {
    max-height: calc(100vh - 220px);
    overflow-y: auto;
    padding-right: 10px;
}

.catalog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.catalog-item-card {
    padding: 16px;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 8px;
    text-align: center;
}

.catalog-item-name {
    font-weight: 600;
    font-size: 15px;
}

.catalog-item-price {
    color: var(--primary);
    font-weight: 700;
}

/* Order Cart */
.cart-panel {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 220px);
}

.cart-items-list {
    flex-grow: 1;
    overflow-y: auto;
    margin: 20px 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding-right: 5px;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.02);
    padding: 12px;
    border-radius: 8px;
    border: 1px solid var(--border-glass);
    gap: 10px;
    flex-wrap: wrap;
}

.cart-item-details {
    flex: 1 1 150px;
    min-width: 120px;
}

.cart-item-name {
    font-weight: 600;
    font-size: 14px;
}

.cart-item-price {
    font-size: 12px;
    color: var(--text-secondary);
}

.cart-item-qty {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-right: 15px;
}

.qty-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    color: var(--text-primary);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.qty-btn:hover {
    background: var(--primary);
    color: #000;
}

.cart-summary {
    border-top: 1px solid var(--border-glass);
    padding-top: 15px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    font-size: 20px;
    font-weight: 800;
}

/* Active Orders Grid */
.orders-list-container {
    margin-top: 30px;
}

.orders-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
}

.order-ticket {
    border-radius: var(--border-radius);
    padding: 24px;
    position: relative;
    border-left: 5px solid var(--text-muted);
}

.order-ticket.status-pending {
    border-left-color: var(--warning);
}
.order-ticket.status-preparing {
    border-left-color: var(--secondary);
}
.order-ticket.status-completed {
    border-left-color: var(--success);
}

.order-ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-glass);
    padding-bottom: 12px;
    margin-bottom: 12px;
}

.order-ticket-title {
    font-size: 16px;
    font-weight: 700;
}

.order-ticket-table {
    background: rgba(255, 255, 255, 0.05);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}

.order-ticket-items {
    font-size: 14px;
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 15px;
}

.order-ticket-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-glass);
    padding-top: 12px;
}

.order-ticket-amount {
    font-weight: 800;
    color: var(--primary);
}

/* Play Area Timer Cards (Trampoline & Bouncy) */
.timers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 30px;
}

.timer-card {
    border-radius: var(--border-radius);
    padding: 24px;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.timer-card::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    height: 4px;
    width: 100%;
    background: var(--success);
    transition: var(--transition);
}

/* Timer State Styling */
.timer-card.timer-warning::after {
    background: var(--warning);
}
.timer-card.timer-expired::after {
    background: var(--danger);
    animation: pulseBorder 1s infinite alternate;
}

.timer-card.timer-expired {
    animation: shakeCard 0.5s ease-in-out;
    border-color: rgba(239, 68, 68, 0.5);
    background: rgba(239, 68, 68, 0.03);
}

.timer-attraction-tag {
    align-self: flex-start;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 15px;
}

.tag-trampoline {
    background: rgba(22, 163, 74, 0.15);
    color: #4ade80;
    border: 1px solid rgba(22, 163, 74, 0.3);
}

.tag-bouncy {
    background: rgba(241, 184, 39, 0.15);
    color: var(--primary);
    border: 1px solid rgba(241, 184, 39, 0.3);
}

.tag-combo {
    background: rgba(124, 58, 237, 0.15);
    color: #a78bfa;
    border: 1px solid rgba(124, 58, 237, 0.3);
}

.timer-child-name {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 4px;
}

.timer-parent-phone {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.countdown-timer-box {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.countdown-clock {
    font-size: 36px;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
}

.countdown-icon {
    font-size: 24px;
    animation: rotateIcon 4s linear infinite;
}

.timer-expired .countdown-clock {
    color: var(--danger);
    animation: flashText 1s infinite;
}
.timer-expired .countdown-icon {
    color: var(--danger);
    animation: wiggleIcon 0.5s infinite;
}

/* Poster Studio & Prompt Engine Layout */
.studio-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

@media(max-width: 1024px) {
    .studio-layout {
        grid-template-columns: 1fr;
    }
}

.prompt-output-box {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-glass);
    border-radius: 8px;
    padding: 16px;
    font-family: 'Consolas', monospace;
    font-size: 14px;
    color: #e0e0e0;
    min-height: 120px;
    position: relative;
    margin-top: 15px;
    white-space: pre-wrap;
    word-break: break-word;
}

/* WYSIWYG Poster Designer Canvas */
.poster-workspace {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.poster-canvas-frame {
    width: 380px;
    height: 530px;
    background: linear-gradient(135deg, #1f1c2c 0%, #928dab 100%);
    position: relative;
    border-radius: 12px;
    box-shadow: 0 15px 45px rgba(0,0,0,0.5);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 30px;
    color: #fff;
    border: 3px solid var(--primary);
    transition: var(--transition);
}

.poster-canvas-bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-size: cover;
    background-position: center;
    opacity: 0.4;
    z-index: 1;
    pointer-events: none;
}

.poster-canvas-content {
    position: relative;
    z-index: 2;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-align: center;
}

.poster-brand-header {
    font-size: 18px;
    font-weight: 800;
    letter-spacing: 0.1em;
    color: var(--primary);
    text-transform: uppercase;
}

.poster-main-title {
    font-size: 36px;
    font-weight: 800;
    line-height: 1.1;
    margin-top: 40px;
    text-shadow: 0 4px 10px rgba(0,0,0,0.7);
}

.poster-subtitle {
    font-size: 16px;
    color: #f3f4f6;
    margin-top: 15px;
    line-height: 1.4;
    text-shadow: 0 2px 5px rgba(0,0,0,0.5);
}

.poster-highlight-badge {
    background: var(--secondary);
    color: white;
    padding: 8px 16px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 700;
    align-self: center;
    margin-top: 20px;
    border: 1px solid rgba(255,255,255,0.2);
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.poster-footer-text {
    font-size: 11px;
    color: #9ca3af;
    letter-spacing: 0.05em;
    margin-top: auto;
}

/* Modals */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(5px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
}

.modal.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    width: 100%;
    max-width: 500px;
    padding: 30px;
    border-radius: var(--border-radius);
    transform: scale(0.9);
    transition: var(--transition);
}

.modal.active .modal-content {
    transform: scale(1);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.modal-close {
    font-size: 24px;
    cursor: pointer;
    color: var(--text-secondary);
    transition: var(--transition);
}
.modal-close:hover {
    color: var(--primary);
}

/* Keyframes and Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@keyframes rotateIcon {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes flashText {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

@keyframes wiggleIcon {
    0%, 100% { transform: rotate(0deg) scale(1); }
    25% { transform: rotate(-8deg) scale(1.1); }
    75% { transform: rotate(8deg) scale(1.1); }
}

@keyframes pulseBorder {
    0% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4); }
    100% { box-shadow: 0 0 0 12px rgba(239, 68, 68, 0); }
}

@keyframes shakeCard {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

/* Shell Toggles */
#customer-shell {
    display: none;
}
#customer-shell.active {
    display: block;
}

/* Redesigned Premium Maintenance Screen */
.maintenance-page-wrapper {
    position: relative;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 60px 20px;
    z-index: 10;
    overflow: hidden;
}

/* Floating animated background elements */
.maintenance-bg-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
}

.maintenance-glow-circle {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.15;
    animation: pulseGlow 8s infinite alternate ease-in-out;
}

.maintenance-glow-circle.primary {
    top: 20%;
    left: 15%;
    width: 400px;
    height: 400px;
    background: var(--primary);
}

.maintenance-glow-circle.secondary {
    bottom: 20%;
    right: 15%;
    width: 450px;
    height: 450px;
    background: var(--secondary);
    animation-delay: -4s;
}

.steam-bubble {
    position: absolute;
    bottom: -80px;
    background: linear-gradient(135deg, rgba(var(--primary-rgb), 0.25), rgba(var(--secondary-rgb), 0.15));
    border-radius: 50%;
    pointer-events: none;
    animation: steamRise 12s infinite linear;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Maintenance Card */
.maintenance-card-container {
    width: 100%;
    max-width: 650px;
    position: relative;
    animation: fadeIn 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.maintenance-card-container::before {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 24px;
    background: linear-gradient(135deg, var(--primary), var(--secondary), var(--primary));
    background-size: 200% 200%;
    z-index: -1;
    animation: borderGlow 6s linear infinite;
    opacity: 0.5;
}

.maintenance-card-premium {
    padding: 50px 40px;
    border-radius: 22px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Logo Frame */
.maintenance-logo-frame {
    position: relative;
    width: 120px;
    height: 120px;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.4);
    padding: 8px;
    animation: floatLogo 4s infinite ease-in-out;
}

.maintenance-logo {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(var(--primary-rgb), 0.8);
    box-shadow: 0 8px 25px rgba(0,0,0,0.5);
    z-index: 2;
}

.maintenance-logo.rotating {
    animation: rotateIcon 20s linear infinite;
}

.maintenance-logo-fallback {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: linear-gradient(135deg, #1f1f2e, #111116);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    border: 3px solid rgba(var(--primary-rgb), 0.8);
    box-shadow: 0 8px 25px rgba(0,0,0,0.5);
    z-index: 2;
}

.maintenance-logo-fallback.rotating {
    animation: rotateIcon 20s linear infinite;
}

.maintenance-logo-fallback i {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: flamePulse 2s infinite alternate ease-in-out;
}

.logo-glow-ring {
    position: absolute;
    inset: -5px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    z-index: 1;
    filter: blur(8px);
    opacity: 0.7;
    animation: rotateIcon 12s linear infinite;
}

.maintenance-desc-simple {
    font-size: 20px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-top: 10px;
    margin-bottom: 0;
    letter-spacing: 0.02em;
    animation: fadeIn 1s ease;
}

/* Under Maintenance Badge */
.maintenance-badge {
    background: rgba(var(--primary-rgb), 0.1);
    border: 1px solid rgba(var(--primary-rgb), 0.3);
    color: var(--primary);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 20px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.maintenance-card-premium h1 {
    font-size: 38px;
    font-weight: 800;
    margin-bottom: 16px;
    line-height: 1.2;
}

.maintenance-desc {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 35px;
    max-width: 500px;
}

/* Spiciness Meter Styles */
.spiciness-meter-container {
    width: 100%;
    margin-top: 10px;
    margin-bottom: 20px;
    border-top: 1px solid rgba(255,255,255,0.06);
    padding-top: 30px;
}

.spiciness-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.spiciness-subtitle {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.spiciness-badges {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-bottom: 25px;
}

.spice-badge {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    color: var(--text-secondary);
    padding: 10px 18px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.spice-badge:hover {
    background: rgba(255,255,255,0.06);
    border-color: rgba(255,255,255,0.15);
    color: var(--text-primary);
    transform: translateY(-2px);
}

.spice-badge.active[data-spice="sweet"] {
    background: rgba(241, 184, 39, 0.15);
    border-color: rgba(241, 184, 39, 0.4);
    color: #f1b827;
    box-shadow: 0 4px 15px rgba(241, 184, 39, 0.1);
}

.spice-badge.active[data-spice="medium"] {
    background: rgba(22, 163, 74, 0.15);
    border-color: rgba(22, 163, 74, 0.4);
    color: #16a34a;
    box-shadow: 0 4px 15px rgba(22, 163, 74, 0.1);
}

.spice-badge.active[data-spice="spicy"] {
    background: rgba(249, 115, 22, 0.15);
    border-color: rgba(249, 115, 22, 0.4);
    color: #f97316;
    box-shadow: 0 4px 15px rgba(249, 115, 22, 0.1);
}

.spice-badge.active[data-spice="volcano"] {
    background: rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.4);
    color: #ef4444;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.1);
}

.spice-message-card {
    background: rgba(0,0,0,0.2) !important;
    border-color: rgba(255,255,255,0.04) !important;
    text-align: left;
    padding: 20px;
    border-radius: 16px;
    min-height: 120px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.spice-message-title {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 6px;
    transition: var(--transition);
}

.spice-message-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 12px;
    min-height: 38px;
}

.spice-progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(255,255,255,0.06);
    border-radius: 10px;
    overflow: hidden;
}

.spice-progress-fill {
    height: 100%;
    border-radius: 10px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1), background 0.5s ease;
}

/* Staff Bypass Button */
.bypass-wrapper {
    margin-top: 25px;
}

.bypass-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    color: var(--text-muted);
    padding: 10px 24px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.bypass-btn:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.15);
    color: var(--text-primary);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.2);
}

/* Additional Animation Keyframes */
@keyframes steamRise {
    0% {
        transform: translateY(0) scale(0.6) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.6;
    }
    90% {
        opacity: 0.2;
    }
    100% {
        transform: translateY(-105vh) scale(1.4) rotate(360deg);
        opacity: 0;
    }
}

@keyframes floatLogo {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

@keyframes borderGlow {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes pulseGlow {
    0% { transform: scale(1) translate(0, 0); opacity: 0.12; }
    50% { transform: scale(1.15) translate(5%, -5%); opacity: 0.2; }
    100% { transform: scale(1) translate(0, 0); opacity: 0.12; }
}

@keyframes flamePulse {
    0% { filter: drop-shadow(0 2px 5px rgba(241, 184, 39, 0.4)); }
    100% { filter: drop-shadow(0 5px 15px rgba(241, 184, 39, 0.8)); }
}

/* ============================================================
   FULLY RESPONSIVE DESIGN SYSTEM
   Breakpoints:
     xs  : ≤ 480px  (narrow phone portrait)
     sm  : 481–767px (wide phone landscape / small phone)
     md  : 768–1023px (tablet)
     lg  : 1024–1279px (desktop / laptop)
     xl  : 1280–1919px (wide desktop / TV 1080p)
     2xl : ≥ 1920px  (4K / ultra-wide TV)
   ============================================================ */
/* ─────────────────────────────────────────────────────────────
   REVIEW IMAGE UPLOAD — Drop Zone, Preview Grid, Approval Notice
───────────────────────────────────────────────────────────── */
#review-img-dropzone {
    border: 2px dashed var(--border-glass);
    border-radius: 12px;
    padding: 22px 16px;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
    background: rgba(255,255,255,0.02);
    margin-bottom: 10px;
}
#review-img-dropzone:hover,
#review-img-dropzone.dz-over {
    border-color: var(--primary);
    background: rgba(var(--primary-rgb), 0.06);
}

#review-img-preview-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 6px;
}

.review-preview-thumb {
    position: relative;
    width: 72px;
    height: 72px;
    border-radius: 10px;
    overflow: hidden;
    border: 2px solid var(--border-glass);
    flex-shrink: 0;
}
.review-preview-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.review-preview-thumb .remove-btn {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(0,0,0,0.75);
    color: #fff;
    border: none;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    line-height: 1;
}

.review-approval-notice {
    background: rgba(241,184,39,0.08);
    border: 1px solid rgba(241,184,39,0.22);
    border-radius: 10px;
    padding: 10px 14px;
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ─────────────────────────────────────────────────────────────
   REVIEW PHOTO STRIP (customer card)
───────────────────────────────────────────────────────────── */
.review-photo-strip {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin-top: 10px;
}
.review-photo-thumb {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    object-fit: cover;
    cursor: pointer;
    border: 2px solid var(--border-glass);
    transition: transform 0.18s, border-color 0.18s;
}
.review-photo-thumb:hover {
    transform: scale(1.08);
    border-color: var(--primary);
}

/* ─────────────────────────────────────────────────────────────
   ADMIN REVIEW CARDS
───────────────────────────────────────────────────────────── */
.admin-review-card {
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: 16px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: border-color 0.2s;
}
.admin-review-card.status-pending  { border-left: 3px solid var(--warning); }
.admin-review-card.status-approved { border-left: 3px solid var(--success); }
.admin-review-card.status-rejected { border-left: 3px solid var(--danger);  }

.review-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.badge-pending  { background: rgba(245,158,11,0.15); color: var(--warning); }
.badge-approved { background: rgba(16,185,129,0.15); color: var(--success); }
.badge-rejected { background: rgba(239,68,68,0.15);  color: var(--danger);  }

.admin-review-photos {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}
.admin-review-photo {
    width: 64px;
    height: 64px;
    object-fit: cover;
    border-radius: 8px;
    border: 2px solid var(--border-glass);
    cursor: pointer;
    transition: transform 0.18s, border-color 0.18s;
}
.admin-review-photo:hover {
    transform: scale(1.08);
    border-color: var(--primary);
}

.admin-review-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* ─────────────────────────────────────────────────────────────
   LIGHTBOX
───────────────────────────────────────────────────────────── */
#review-lightbox {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.93);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}
#review-lightbox.lb-open { display: flex; }

#review-lightbox #lightbox-img {
    max-width: 90vw;
    max-height: 82vh;
    border-radius: 12px;
    object-fit: contain;
    box-shadow: 0 0 80px rgba(0,0,0,0.9);
}
#lightbox-counter {
    color: rgba(255,255,255,0.55);
    font-size: 13px;
    margin-top: 12px;
}
.lb-close {
    position: absolute;
    top: 16px;
    right: 20px;
    background: rgba(255,255,255,0.1);
    border: none;
    color: #fff;
    font-size: 28px;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}
.lb-close:hover { background: rgba(255,255,255,0.2); }
.lb-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.1);
    border: none;
    color: #fff;
    font-size: 32px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}
.lb-nav:hover { background: rgba(255,255,255,0.2); }
.lb-nav-left  { left: 14px;  }
.lb-nav-right { right: 14px; }

/* ─────────────────────────────────────────────────────────────
   RESPONSIVE BREAKPOINTS
───────────────────────────────────────────────────────────── */

/* -------------------------------------------------------
   HAMBURGER MENU TOGGLE (customer nav)
------------------------------------------------------- */
.hamburger-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 8px;
    border: none;
    background: transparent;
    z-index: 200;
}
.hamburger-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: var(--transition);
}
.hamburger-btn.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger-btn.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger-btn.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav overlay */
.nav-links-mobile-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.65);
    /* z-index BELOW nav-header (100) so the drawer stays visible above the blur */
    z-index: 99;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}
.nav-links-mobile-overlay.open { display: block; }

/* Admin sidebar overlay */
.admin-sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
    z-index: 97;
    backdrop-filter: blur(4px);
}
.admin-sidebar-overlay.open { display: block; }

/* Admin sidebar close button (mobile only) */
.admin-sidebar-close-btn {
    display: none;
    position: sticky;
    top: 0;
    z-index: 10;
    align-self: flex-end;
    background: rgba(255,255,255,0.08);
    border: 1px solid var(--border-glass);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 22px;
    line-height: 1;
    width: 36px;
    height: 36px;
    cursor: pointer;
    margin: 10px 10px 0 auto;
    transition: var(--transition);
    flex-shrink: 0;
}
.admin-sidebar-close-btn:hover {
    background: rgba(239,68,68,0.15);
    border-color: #ef4444;
    color: #ef4444;
}

/* Admin mobile toggle */
.admin-mobile-toggle {
    display: none;
    position: fixed;
    top: 16px;
    left: 16px;
    z-index: 200;
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: 10px;
    padding: 10px 12px;
    cursor: pointer;
    color: var(--text-primary);
    font-size: 18px;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    transition: var(--transition);
}
.admin-mobile-toggle:hover {
    background: rgba(var(--primary-rgb), 0.1);
    border-color: var(--primary);
    color: var(--primary);
}

/* -------------------------------------------------------
   ULTRA-WIDE / TV ≥ 1920px (4K, Smart TV)
------------------------------------------------------- */
@media (min-width: 1920px) {
    :root { --sidebar-width: 320px; }

    .page-container {
        max-width: 1800px;
        padding: 0 60px 100px 60px;
    }

    .nav-header { padding: 0 8%; height: 90px; }
    .brand-logo h1 { font-size: 28px; }
    .brand-logo img { height: 56px; width: 56px; }
    .nav-link { font-size: 17px; }

    .menu-grid { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 36px; }
    .menu-card-img-container { height: 240px; }
    .menu-card-title { font-size: 22px; }
    .menu-card-price { font-size: 26px; }

    .stats-grid { grid-template-columns: repeat(4, 1fr); gap: 30px; }
    .stat-card-value { font-size: 36px; }
    .stat-card-icon { font-size: 30px; }

    .admin-main { padding: 50px 60px; }
    .admin-sidebar { width: var(--sidebar-width); padding: 40px 24px; }
    .admin-logo h2 { font-size: 22px; }
    .admin-menu-item { font-size: 16px; padding: 14px 18px; }

    .reviews-grid { grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); }
    .timers-grid { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
    .modal-content { max-width: 620px; }
    .form-control { font-size: 16px; padding: 14px 18px; }
    .btn { font-size: 16px; padding: 12px 24px; }
}

/* -------------------------------------------------------
   WIDE DESKTOP 1280–1919px
------------------------------------------------------- */
@media (min-width: 1280px) and (max-width: 1919px) {
    .page-container { max-width: 1400px; padding: 0 30px 80px 30px; }

    .menu-grid { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
    .stats-grid { grid-template-columns: repeat(4, 1fr); }
}

/* -------------------------------------------------------
   TABLET 768–1023px
------------------------------------------------------- */
@media (max-width: 1023px) {

    /* Admin sidebar becomes a slide-in drawer */
    .admin-mobile-toggle { display: flex; align-items: center; gap: 8px; }

    /* Show the close (×) button inside sidebar on mobile */
    .admin-sidebar-close-btn { display: flex; align-items: center; justify-content: center; }

    .admin-sidebar {
        position: fixed;
        left: -320px;
        top: 0;
        height: 100vh;
        z-index: 98;
        width: var(--sidebar-width);
        transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: none;
        /* Make sidebar fully scrollable so all menu items are reachable */
        display: flex;
        flex-direction: column;
        overflow-y: auto;
        overflow-x: hidden;
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
    }
    .admin-sidebar.sidebar-open {
        left: 0;
        box-shadow: 4px 0 30px rgba(0,0,0,0.4);
    }

    /* Sticky brand header inside drawer */
    .admin-sidebar .admin-logo {
        position: sticky;
        top: 0;
        background: var(--bg-card);
        z-index: 5;
        padding-top: 12px;
        padding-bottom: 12px;
        flex-shrink: 0;
        border-bottom: 1px solid var(--border-glass);
    }

    /* Nav list fills remaining height and scrolls independently */
    .admin-sidebar .admin-menu {
        flex: 1 1 auto;
        overflow-y: auto;
        overflow-x: hidden;
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 40px;
    }

    /* Sidebar footer stays at bottom */
    .admin-sidebar .admin-sidebar-footer {
        flex-shrink: 0;
        position: sticky;
        bottom: 0;
        background: var(--bg-card);
        border-top: 1px solid var(--border-glass);
        padding: 12px 16px;
    }

    .admin-main {
        margin-left: 0 !important;
        padding: 80px 24px 40px 24px;
        min-width: 0;
    }

    /* Dashboard grid tweaks */
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }

    /* Dashboard 2-column sections → 1 column */
    #admin-section-dashboard > div[style*="grid-template-columns: 1.5fr 1fr"] {
        display: flex !important;
        flex-direction: column !important;
    }

    /* Social planner grid */
    #admin-section-social-planner > div[style*="grid-template-columns"] {
        display: flex !important;
        flex-direction: column !important;
    }

    /* Menu manager grid */
    #admin-section-menu-manager > div[style*="grid-template-columns: 1.6fr 1fr"] {
        display: flex !important;
        flex-direction: column !important;
    }

    /* Settings grid */
    #super-admin-settings-container > div[style*="grid-template-columns: 1fr 1fr"] {
        display: flex !important;
        flex-direction: column !important;
    }

    /* Timer section */
    #admin-section-timers > div[style*="grid-template-columns: 1fr 2fr"] {
        display: flex !important;
        flex-direction: column !important;
    }

    /* Order entry layout */
    .order-entry-layout {
        flex-direction: column;
    }
    .cart-panel { height: auto; min-height: 300px; }
    .order-catalog { max-height: 60vh; }

    /* Poster studio */
    .studio-layout { grid-template-columns: 1fr; }
    .poster-canvas-frame { width: 100%; max-width: 380px; }

    /* Reviews */
    .reviews-summary { grid-template-columns: 1fr; }

    /* Admin section header */
    .admin-section-header { flex-direction: column; align-items: flex-start; gap: 12px; }
}

/* -------------------------------------------------------
   TABLET 768–1023px (continued layout adjustments)
------------------------------------------------------- */
@media (min-width: 768px) and (max-width: 1023px) {
    .page-container { padding: 0 24px 80px 24px; }

    .menu-grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 24px; }
    .timers-grid { grid-template-columns: repeat(2, 1fr); }
    .reviews-grid { grid-template-columns: repeat(2, 1fr); }

    .nav-header { padding: 0 4%; }
    .nav-links { gap: 12px; }
    .nav-link { font-size: 14px; padding: 7px 12px; }
}

/* -------------------------------------------------------
   SMALL PHONE / LANDSCAPE PHONE  481–767px
------------------------------------------------------- */
@media (max-width: 767px) {

    /* ── Customer mobile nav drawer ─────────────────────── */

    /* Hamburger always visible on mobile */
    .hamburger-btn { display: flex; }

    /* Hide desktop nav inside nav-header; show hamburger instead */
    .nav-links-desktop { display: none !important; }

    /* nav-links is now the MOBILE DRAWER (outside nav-header, safe from backdrop-filter) */
    .nav-links {
        position: fixed;
        top: 0;
        right: 0;
        height: 100vh;
        width: min(280px, 85vw);
        background: rgba(10, 10, 14, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        align-items: stretch;
        padding: 28px 20px 40px 20px;
        gap: 4px;
        z-index: 200;
        border-left: 1px solid var(--border-glass);
        box-shadow: -8px 0 40px rgba(0,0,0,0.6);
        list-style: none;

        /* Hidden by default */
        display: flex !important;
        visibility: hidden;
        opacity: 0;
        transform: translateX(100%);
        transition:
            transform  0.32s cubic-bezier(0.4, 0, 0.2, 1),
            opacity    0.25s ease,
            visibility 0s   linear 0.32s;
    }

    /* Open state */
    .nav-links.mobile-open {
        visibility: visible;
        opacity: 1;
        transform: translateX(0);
        transition:
            transform  0.32s cubic-bezier(0.4, 0, 0.2, 1),
            opacity    0.25s ease,
            visibility 0s   linear 0s;
    }

    .nav-links li { width: 100%; }

    .nav-links .nav-link {
        display: block;
        width: 100%;
        font-size: 17px;
        padding: 14px 16px;
        border-radius: 12px;
    }

    .nav-links li:last-child { margin-top: 12px; width: 100%; }
    .nav-links li:last-child .btn { width: 100%; justify-content: center; }

    /* Nav header — never clip its children (fixed drawer lives inside it) */
    .nav-header {
        height: 68px;
        padding: 0 16px;
        margin-bottom: 20px;
        /* NO overflow:hidden here — it would trap the fixed drawer */
    }

    .brand-logo h1 { font-size: 20px; }
    .brand-logo img { height: 38px; width: 38px; }

    /* Page container — clamp to viewport */
    .page-container {
        padding: 0 16px 100px 16px;
        max-width: 100vw;
        overflow-x: hidden;
    }

    /* customer-shell — prevent any child from bleeding horizontally */
    #customer-shell {
        overflow-x: hidden;
        max-width: 100vw;
    }

    /* Menu page headings */
    #page-menu h2,
    #page-reviews h2,
    #page-playzone h2 {
        font-size: 26px !important;
    }

    /* Menu grid: 1 column on small phones, 2 on wider */
    .menu-grid { grid-template-columns: 1fr 1fr; gap: 16px; }
    .menu-card-img-container { height: 150px; }
    .menu-card-body { padding: 14px; }
    .menu-card-title { font-size: 15px; }
    .menu-card-price { font-size: 18px; }
    .menu-card-desc { font-size: 13px; margin-bottom: 12px; }

    /* Category tabs */
    .category-tabs { gap: 8px; }
    .tab { padding: 8px 14px; font-size: 13px; }

    /* Reviews */
    .reviews-grid { grid-template-columns: 1fr; gap: 16px; }
    .rating-big-num { font-size: 52px; }

    /* Timers grid */
    .timers-grid { grid-template-columns: 1fr; gap: 16px; }
    .countdown-clock { font-size: 28px; }

    /* Glass cards general */
    .glass-card { padding: 16px; }

    /* Stats grid */
    .stats-grid { grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 24px; }
    .stat-card-value { font-size: 22px; }
    .stat-card-icon { font-size: 20px; }

    /* Order entry */
    .order-entry-layout { flex-direction: column; gap: 20px; }
    .cart-panel { height: auto; }
    .order-catalog { max-height: 50vh; }
    .catalog-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .catalog-item-card { padding: 12px; gap: 6px; }
    .catalog-item-name { font-size: 13px; }
    .catalog-item-price { font-size: 13px; }

    /* Forms */
    .form-control { font-size: 14px; padding: 10px 12px; }

    /* Dashboard report date row */
    #admin-section-dashboard > .glass-card > div[style*="display: flex"] {
        flex-direction: column !important;
    }

    /* Admin section header */
    .admin-section-header { flex-direction: column; align-items: flex-start; gap: 10px; }
    .admin-section-header h1 { font-size: 22px; }

    /* Modal */
    .modal-content { margin: 0 16px; padding: 24px 20px; max-width: calc(100% - 32px); }
    .modal-header h2 { font-size: 18px; }

    /* Maintenance card */
    .maintenance-card-premium { padding: 40px 24px; }
    .maintenance-card-premium h1 { font-size: 28px; }
    .maintenance-desc-simple { font-size: 16px; }
    .maintenance-logo-frame { width: 90px; height: 90px; }

    /* Poster canvas */
    .poster-canvas-frame { width: 100%; max-width: 320px; height: auto; aspect-ratio: 0.72; }
    .poster-main-title { font-size: 24px !important; }

    /* Settings grid */
    #super-admin-settings-container > div[style*="grid-template-columns"] {
        display: flex !important;
        flex-direction: column !important;
    }

    /* Social planner */
    #admin-section-social-planner > div[style*="grid-template-columns"] {
        display: flex !important;
        flex-direction: column !important;
    }

    /* Moderation table — scroll */
    #admin-section-reviews-moderation .glass-card {
        overflow-x: auto;
    }
    #reviews-moderation-table { min-width: 560px; }

    /* Studio layout */
    .studio-layout { grid-template-columns: 1fr; }

    /* Timer form */
    #admin-section-timers > div[style*="grid-template-columns"] {
        display: flex !important;
        flex-direction: column !important;
    }

    /* Dashboard inner 2-col */
    #admin-section-dashboard > div:last-child[style*="grid-template-columns"] {
        display: flex !important;
        flex-direction: column !important;
    }

    /* Menu manager */
    #admin-section-menu-manager > div[style*="grid-template-columns"] {
        display: flex !important;
        flex-direction: column !important;
    }

    /* Active orders modal */
    #active-orders-modal .modal-content { max-width: calc(100% - 32px) !important; max-height: 85vh; }
    .orders-grid { grid-template-columns: 1fr; }
}

/* -------------------------------------------------------
   NARROW PHONE ≤ 480px
------------------------------------------------------- */
@media (max-width: 480px) {
    .menu-grid { grid-template-columns: 1fr; gap: 14px; }
    .menu-card-img-container { height: 180px; }
    .menu-card-title { font-size: 16px; }

    .stats-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
    .stat-card { padding: 16px; }
    .stat-card-value { font-size: 20px; }

    .catalog-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .catalog-item-card { padding: 10px 8px; gap: 4px; }
    .catalog-item-name { font-size: 12px; }
    .catalog-item-price { font-size: 12px; }

    .brand-logo h1 { font-size: 18px; }

    /* Prevent horizontal scroll on very narrow phones */
    #customer-shell, #admin-shell, .admin-layout, .admin-main, .page-container, .nav-header {
        max-width: 100vw;
        overflow-x: hidden;
    }

    /* Admin main padding when very narrow */
    .admin-main { padding: 72px 12px 40px 12px; min-width: 0; }

    .glass-card { padding: 14px; }

    .btn { font-size: 13px; padding: 9px 16px; }

    .rating-big-num { font-size: 44px; }

    .poster-canvas-frame { max-width: 280px; }

    /* order cart inline grids */
    .order-entry-layout div[style*="grid-template-columns: 1fr 1fr"] {
        grid-template-columns: 1fr !important;
    }
}

/* -------------------------------------------------------
   LANDSCAPE ORIENTATION on phones (height ≤ 500px)
------------------------------------------------------- */
@media (max-height: 500px) and (max-width: 900px) {
    .nav-header { height: 56px; margin-bottom: 10px; }
    .nav-links {
        padding-top: 64px;
        overflow-y: auto;
    }
    .page-container { padding-bottom: 60px; }
    .maintenance-page-wrapper { padding: 30px 16px; }
    .maintenance-logo-frame { width: 70px; height: 70px; }
    .maintenance-card-premium h1 { font-size: 24px; }
    .cart-panel { height: auto; }
    .order-catalog { max-height: 45vh; }
}

/* -------------------------------------------------------
   TOUCH DEVICE IMPROVEMENTS
------------------------------------------------------- */
@media (hover: none) and (pointer: coarse) {
    /* Larger tap targets */
    .btn { min-height: 44px; }
    .tab { min-height: 40px; }
    .nav-link { min-height: 44px; display: flex; align-items: center; }
    .admin-menu-item { min-height: 48px; }
    .qty-btn { width: 36px; height: 36px; }
    .form-control { min-height: 44px; }
    .modal-close { min-width: 44px; min-height: 44px; display: flex; align-items: center; justify-content: center; }

    /* Remove hover translate on cards (prevents stuck states on touch) */
    .glass-card:hover { transform: none; }
    .btn-primary:hover,
    .btn-secondary:hover,
    .btn-danger:hover { transform: none; }
}

/* -------------------------------------------------------
   MODAL RESPONSIVE
------------------------------------------------------- */
@media (max-width: 600px) {
    .modal {
        align-items: flex-end;
        padding-bottom: 0;
    }
    .modal-content {
        width: 100%;
        max-width: 100% !important;
        border-radius: var(--border-radius) var(--border-radius) 0 0;
        margin: 0;
        padding: 28px 20px 40px 20px;
        max-height: 90vh;
        overflow-y: auto;
        transform: translateY(100%);
    }
    .modal.active .modal-content {
        transform: translateY(0);
    }
}

/* -------------------------------------------------------
   SCROLLABLE TABLE WRAPPER (all admin tables on mobile)
------------------------------------------------------- */
@media (max-width: 767px) {
    #admin-menu-table,
    #admin-categories-table,
    #reviews-moderation-table,
    #admins-table {
        font-size: 13px;
    }

    #admin-menu-table th,
    #admin-menu-table td,
    #reviews-moderation-table th,
    #reviews-moderation-table td,
    #admins-table th,
    #admins-table td {
        padding: 10px 6px !important;
    }

    /* Hide less important table columns on mobile */
    #reviews-moderation-table th:nth-child(3),
    #reviews-moderation-table td:nth-child(3) {
        display: none;
    }
}

/* -------------------------------------------------------
   UTILITY: hide / show per viewport
------------------------------------------------------- */
.hide-mobile { display: initial; }
.show-mobile { display: none; }

@media (max-width: 767px) {
    .hide-mobile { display: none !important; }
    .show-mobile { display: initial !important; }
}

/* -------------------------------------------------------
   MENU HEADER BAR responsive flex
------------------------------------------------------- */
@media (max-width: 767px) {
    .menu-header-bar {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 14px;
        margin-bottom: 24px;
    }
    .menu-header-bar > div:first-child h2 { font-size: 24px !important; }
}

/* -------------------------------------------------------
   ADMIN SIDEBAR CLOSE BUTTON (mobile)
------------------------------------------------------- */
.admin-sidebar-close-btn {
    display: none;
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border-glass);
    border-radius: 8px;
    color: var(--text-secondary);
    padding: 6px 10px;
    font-size: 18px;
    cursor: pointer;
    transition: var(--transition);
}
.admin-sidebar-close-btn:hover { color: var(--primary); }

@media (max-width: 1023px) {
    .admin-sidebar { position: fixed; }
    .admin-sidebar-close-btn { display: block; }
}

/* -------------------------------------------------------
   PLAY ZONE CUSTOMER PAGE
   ------------------------------------------------------- */
@media (max-width: 767px) {
    #page-playzone .glass-card { padding: 16px; }
    #page-playzone h3 { font-size: 17px; }
    #customer-timers-grid { grid-template-columns: 1fr; }
    .playzone-pricing-grid { grid-template-columns: 1fr !important; gap: 14px !important; }
}

/* -------------------------------------------------------
   BRAND LOGO / NAV MINIMAL padding on very small screens
   ------------------------------------------------------- */
@media (max-width: 360px) {
    .nav-header { padding: 0 12px; }
    .brand-logo h1 { font-size: 16px; }
    .brand-logo img { height: 34px; width: 34px; }
    .page-container { padding: 0 12px 80px 12px; }
}

/* -------------------------------------------------------
   CUSTOMER HERO SECTION STYLES
   ------------------------------------------------------- */
.customer-hero-section {
    transition: var(--transition);
}
.customer-hero-section:hover {
    border-color: rgba(var(--primary-rgb), 0.25) !important;
    box-shadow: 0 15px 45px rgba(var(--primary-rgb), 0.08) !important;
}
.customer-hero-section .btn {
    padding: 12px 24px;
    font-size: 15px;
}
@media (max-width: 767px) {
    .customer-hero-section {
        padding: 30px 20px !important;
        text-align: center;
        flex-direction: column;
    }
    .customer-hero-section .hero-content {
        max-width: 100% !important;
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    .customer-hero-section .hero-actions {
        justify-content: center;
        width: 100%;
    }
    .customer-hero-section .hero-actions .btn {
        width: 100%;
        justify-content: center;
    }
}

/* -------------------------------------------------------
   REPORT GENERATOR ROW responsive
------------------------------------------------------- */
@media (max-width: 767px) {
    #admin-section-dashboard .glass-card > div[style*="display: flex; gap: 20px"] {
        flex-direction: column !important;
    }
}

/* -------------------------------------------------------
   POSTER CANVAS FRAME responsive
------------------------------------------------------- */
@media (max-width: 767px) {
    .poster-workspace { align-items: stretch; }
    .poster-canvas-frame {
        width: 100%;
        height: auto;
        min-height: 300px;
    }
}

/* -------------------------------------------------------
   FORM GRID (Settings color pickers) keep 2-col on narrow
------------------------------------------------------- */
@media (max-width: 360px) {
    #super-admin-settings-container div[style*="grid-template-columns: 1fr 1fr"] {
        grid-template-columns: 1fr !important;
    }
}

/* -------------------------------------------------------
   CATEGORY-TABS SCROLLABLE – always horizontal scroll
------------------------------------------------------- */
.category-tabs {
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
}
.tab { scroll-snap-align: start; flex-shrink: 0; }

/* -------------------------------------------------------
   PLAY ZONE CUSTOMER PAGE
------------------------------------------------------- */
@media (max-width: 767px) {
    #page-playzone .glass-card { padding: 16px; }
    #page-playzone h3 { font-size: 17px; }
    #customer-timers-grid { grid-template-columns: 1fr; }
}

/* -------------------------------------------------------
   BRAND LOGO / NAV MINIMAL padding on very small screens
------------------------------------------------------- */
@media (max-width: 360px) {
    .nav-header { padding: 0 12px; }
    .brand-logo h1 { font-size: 16px; }
    .brand-logo img { height: 34px; width: 34px; }
    .page-container { padding: 0 12px 80px 12px; }
}

