/* ============================================================
   Restaurant Ordering App - Dark Premium Theme
   ============================================================
   Custom property theming system:
   - --rest-*  : component-level tokens
   - Inherits from business color system vars where available
   ============================================================ */

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

/* ==========================================================
   1. ROOT / CUSTOM PROPERTIES
   ========================================================== */
:root {
    /* Core palette - inherits from business color system */
    --rest-bg: var(--main-bg-color, #1a1a2e);
    --rest-bg-rgb: 26, 26, 46;
    --rest-surface: color-mix(in srgb, var(--rest-bg), #fff 6%);
    --rest-surface-light: color-mix(in srgb, var(--rest-bg), #fff 11%);
    --rest-text: #fff;
    --rest-text-muted: rgba(255, 255, 255, 0.6);

    /* Borders/dividers/overlays - auto-adapt via JS */
    --rest-border: rgba(255, 255, 255, 0.06);
    --rest-border-medium: rgba(255, 255, 255, 0.08);
    --rest-border-strong: rgba(255, 255, 255, 0.1);
    --rest-border-light: rgba(255, 255, 255, 0.04);
    --rest-overlay-subtle: rgba(255, 255, 255, 0.06);
    --rest-overlay-medium: rgba(255, 255, 255, 0.08);
    --rest-overlay-hover: rgba(255, 255, 255, 0.12);

    /* Header - from business header colors */
    --rest-header-bg: var(--main-bg-color, #1a1a2e);
    --rest-header-text: var(--main-text-color, #ffffff);

    /* Bottom nav - uses footer colors (no footer in restaurant) */
    --rest-bottom-bg: var(--footer-bg-color, #1a1a2e);
    --rest-bottom-text: var(--footer-text-color, #ffffff);

    /* Accent - from business button colors */
    --rest-accent: var(--outline-bg-color, #f5a623);
    --rest-accent-text: var(--outline-text-color, #1a1a2e);
    --rest-accent-rgb: 245, 166, 35;

    /* Semantic tokens */
    --rest-success: #34d399;
    --rest-warning: #fbbf24;
    --rest-danger: #f87171;
    --rest-info: #60a5fa;

    /* Radii */
    --rest-radius-card: 14px;
    --rest-radius-btn: 10px;
    --rest-radius-pill: 24px;
    --rest-radius-sm: 8px;
    --rest-radius-full: 9999px;

    /* Shadows */
    --rest-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.25);
    --rest-shadow-md: 0 4px 16px rgba(0, 0, 0, 0.35);
    --rest-shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.45);
    --rest-shadow-accent: 0 4px 20px rgba(var(--rest-accent-rgb), 0.25);

    /* Transitions */
    --rest-transition: 0.2s ease;
    --rest-transition-slow: 0.35s ease;

    /* Spacing */
    --rest-header-h: 68px;
    --rest-bottom-nav-h: 64px;
    --rest-gutter: 16px;

    /* Z-index layers */
    --rest-z-base: 1;
    --rest-z-sticky: 100;
    --rest-z-header: 200;
    --rest-z-bottom-nav: 200;
    --rest-z-overlay: 500;
    --rest-z-modal: 600;
}


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

/* ----- Body ----- */
.rest-body {
    margin: 0;
    padding: 0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 15px;
    line-height: 1.5;
    color: var(--rest-text);
    background-color: var(--rest-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    min-height: 100vh;
    padding-top: var(--rest-header-h);
    padding-bottom: calc(var(--rest-bottom-nav-h) + 12px);
}


/* ==========================================================
   3. LAYOUT - HEADER (Premium)
   ========================================================== */
.rest-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: var(--rest-header-bg);
    backdrop-filter: blur(24px) saturate(1.3);
    -webkit-backdrop-filter: blur(24px) saturate(1.3);
    border-bottom: 1px solid var(--rest-border);
    z-index: var(--rest-z-header);
    transition: background var(--rest-transition);
    color: var(--rest-header-text);
}

.rest-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--rest-header-h);
    padding: 0 var(--rest-gutter);
    max-width: 1200px;
    margin: 0 auto;
    gap: 16px;
}

.rest-logo-link {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--rest-header-text);
    flex-shrink: 0;
}

.rest-logo-link:hover {
    color: var(--rest-header-text);
    text-decoration: none;
}

.rest-logo-wrap {
    position: relative;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--rest-accent), rgba(255,255,255,0.1));
    padding: 2px;
    flex-shrink: 0;
}

.rest-logo-wrap .rest-logo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
    display: block;
}

.rest-logo-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.rest-logo-name {
    font-size: 1rem;
    font-weight: 800;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 140px;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.rest-logo-tagline {
    font-size: 0.65rem;
    color: var(--rest-text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 140px;
    font-weight: 500;
    letter-spacing: 0.02em;
}

/* Desktop navigation */
.rest-desktop-nav {
    display: none;
    align-items: center;
    gap: 2px;
    flex: 1;
    justify-content: center;
    background: var(--rest-overlay-medium);
    border: 1px solid var(--rest-border-light);
    border-radius: var(--rest-radius-pill);
    padding: 4px;
}

@media (min-width: 768px) {
    .rest-desktop-nav { display: flex; }
}

.rest-nav-link {
    color: color-mix(in srgb, var(--rest-header-text), transparent 40%);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: var(--rest-radius-pill);
    transition: all var(--rest-transition);
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.rest-nav-link i { font-size: 0.8em; }

.rest-nav-link:hover {
    color: var(--rest-header-text);
    background: color-mix(in srgb, var(--rest-header-text), transparent 92%);
    text-decoration: none;
}

.rest-nav-link.active {
    color: var(--rest-accent-text);
    background: var(--rest-accent);
    box-shadow: 0 2px 12px rgba(var(--rest-accent-rgb), 0.3);
}

.rest-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.rest-header-action {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid color-mix(in srgb, var(--rest-header-text), transparent 88%);
    border-radius: 12px;
    background: color-mix(in srgb, var(--rest-header-text), transparent 92%);
    color: color-mix(in srgb, var(--rest-header-text), transparent 35%);
    font-size: 16px;
    cursor: pointer;
    transition: all var(--rest-transition);
}

.rest-header-action:hover {
    background: color-mix(in srgb, var(--rest-header-text), transparent 85%);
    color: var(--rest-header-text);
    border-color: color-mix(in srgb, var(--rest-header-text), transparent 82%);
    transform: translateY(-1px);
}

.rest-header-action:active {
    transform: scale(0.92);
}

.rest-header-action-accent {
    background: linear-gradient(135deg, var(--rest-accent), color-mix(in srgb, var(--rest-accent), #000 15%));
    color: var(--rest-accent-text);
    border: none;
    box-shadow: 0 2px 12px rgba(var(--rest-accent-rgb), 0.25);
}

.rest-header-action-accent:hover {
    color: var(--rest-accent-text);
    box-shadow: 0 4px 16px rgba(var(--rest-accent-rgb), 0.35);
}

.rest-header-action-user {
    width: 40px;
    height: 40px;
    padding: 0;
    border: 2px solid var(--rest-accent);
    border-radius: 50%;
    background: transparent;
}

.rest-user-avatar {
    font-size: 14px;
    font-weight: 800;
    color: var(--rest-accent);
    line-height: 1;
}

/* User dropdown */
.rest-dropdown-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1;
}

.rest-user-dropdown {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    width: 240px;
    background: var(--rest-surface);
    border: 1px solid var(--rest-border-medium);
    border-radius: 16px;
    box-shadow: var(--rest-shadow-lg);
    z-index: 2;
    overflow: hidden;
    animation: restDropdownIn 0.2s ease;
}

@keyframes restDropdownIn {
    from { opacity: 0; transform: translateY(-8px) scale(0.96); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.rest-dropdown-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
}

.rest-dropdown-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--rest-accent), color-mix(in srgb, var(--rest-accent), #000 20%));
    color: var(--rest-accent-text);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 16px;
    flex-shrink: 0;
}

.rest-dropdown-divider {
    height: 1px;
    background: var(--rest-overlay-subtle);
    margin: 0;
}

.rest-dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    color: var(--rest-text-muted);
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    transition: all var(--rest-transition);
}

.rest-dropdown-item:hover {
    background: var(--rest-border-light);
    color: var(--rest-text);
    text-decoration: none;
}

.rest-dropdown-item i { width: 16px; text-align: center; font-size: 0.85em; }

.rest-dropdown-item-danger:hover {
    color: var(--rest-danger);
}

/* Cart badge */
.rest-cart-count {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 800;
    color: var(--rest-accent-text);
    background: var(--rest-accent);
    border-radius: var(--rest-radius-full);
    line-height: 1;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    animation: restBadgePop 0.3s ease;
}

@keyframes restBadgePop {
    0% { transform: scale(0); }
    60% { transform: scale(1.2); }
    100% { transform: scale(1); }
}


/* ==========================================================
   4. LAYOUT - SEARCH BAR (expandable under header)
   ========================================================== */
.rest-search-bar {
    padding: 8px 0 12px;
    background: color-mix(in srgb, var(--rest-bg), transparent 8%);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--rest-border);
}

.rest-search-form {
    display: flex;
    align-items: center;
    position: relative;
}

.rest-search-form > i {
    position: absolute;
    left: 14px;
    color: var(--rest-text-muted);
    font-size: 14px;
    pointer-events: none;
    z-index: 1;
}

.rest-search-form input {
    width: 100%;
    height: 44px;
    padding: 0 44px 0 40px;
    font-family: inherit;
    font-size: 15px;
    color: var(--rest-text);
    background: var(--rest-surface);
    border: 1px solid var(--rest-border-medium);
    border-radius: var(--rest-radius-pill);
    outline: none;
    transition: border-color var(--rest-transition), box-shadow var(--rest-transition);
}

.rest-search-form input::placeholder {
    color: var(--rest-text-muted);
}

.rest-search-form input:focus {
    border-color: var(--rest-accent);
    box-shadow: 0 0 0 3px rgba(var(--rest-accent-rgb), 0.15);
}

.rest-search-close {
    position: absolute;
    right: 6px;
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    color: var(--rest-text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.rest-search-close:hover {
    color: var(--rest-text);
    background: var(--rest-surface-light);
}


/* ==========================================================
   5. LAYOUT - BOTTOM NAVIGATION
   ========================================================== */
.rest-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--rest-bottom-nav-h);
    display: flex;
    align-items: center;
    justify-content: space-around;
    background: color-mix(in srgb, var(--rest-bottom-bg), transparent 8%);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-top: 1px solid var(--rest-border);
    z-index: var(--rest-z-bottom-nav);
    padding-bottom: env(safe-area-inset-bottom, 0px);
}

.rest-bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    flex: 1;
    padding: 6px 0;
    color: color-mix(in srgb, var(--rest-bottom-text), transparent 40%);
    text-decoration: none;
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0.02em;
    transition: color var(--rest-transition), transform var(--rest-transition);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    position: relative;
    background: none;
    border: none;
}

.rest-bottom-nav-item i,
.rest-bottom-nav-item .nav-icon {
    font-size: 22px;
    transition: transform var(--rest-transition);
}

.rest-bottom-nav-item:active {
    transform: scale(0.9);
}

.rest-bottom-nav-item.active {
    color: var(--rest-accent);
}

.rest-bottom-nav-item.active i,
.rest-bottom-nav-item.active .nav-icon {
    transform: scale(1.1);
}

.rest-bottom-nav-item.active::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 32px;
    height: 3px;
    background: var(--rest-accent);
    border-radius: 0 0 3px 3px;
}

.rest-bottom-badge {
    position: absolute;
    top: 4px;
    right: calc(50% - 20px);
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
    color: var(--rest-accent-text);
    background: var(--rest-accent);
    border-radius: var(--rest-radius-full);
    line-height: 1;
}


/* ==========================================================
   6. HOME - HERO BANNER
   ========================================================== */
.rest-hero-banner {
    position: relative;
    min-height: 200px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 32px var(--rest-gutter) 28px;
    background: linear-gradient(135deg, var(--rest-surface) 0%, var(--rest-bg) 50%, var(--rest-surface-light) 100%);
}

.rest-hero-banner-bg {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.rest-hero-logo-bg {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 280px;
    height: 280px;
    object-fit: contain;
    opacity: 0.04;
    filter: blur(2px);
}

.rest-hero-banner-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at 20% 50%, rgba(var(--rest-accent-rgb), 0.08) 0%, transparent 60%),
        radial-gradient(ellipse at 80% 50%, rgba(96, 165, 250, 0.05) 0%, transparent 60%);
}

.rest-hero-content {
    position: relative;
    z-index: 1;
    animation: restFadeIn 0.5s ease;
}

.rest-hero-logo {
    width: 72px;
    height: 72px;
    border-radius: 18px;
    object-fit: cover;
    margin-bottom: 12px;
    border: 2px solid var(--rest-border-strong);
    box-shadow: 0 4px 24px rgba(0,0,0,0.3);
}

.rest-hero-greeting {
    font-size: 24px;
    font-weight: 800;
    color: var(--rest-text);
    margin: 0 0 6px;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.rest-hero-desc {
    font-size: 0.85rem;
    color: var(--rest-text-muted);
    margin: 0 0 16px;
    max-width: 300px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.4;
}

.rest-hero-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 24px;
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--rest-accent-text);
    background: var(--rest-accent);
    border: none;
    border-radius: var(--rest-radius-pill);
    text-decoration: none;
    cursor: pointer;
    transition: all var(--rest-transition);
    box-shadow: 0 4px 16px rgba(var(--rest-accent-rgb), 0.3);
}

.rest-hero-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(var(--rest-accent-rgb), 0.4);
    text-decoration: none;
    color: var(--rest-accent-text);
}

@media (min-width: 768px) {
    .rest-hero-banner { min-height: 240px; padding: 40px 24px 36px; }
    .rest-hero-greeting { font-size: 30px; }
    .rest-hero-logo { width: 80px; height: 80px; }
}


/* ==========================================================
   7. HOME - PROMO CARD
   ========================================================== */
.rest-promo-card {
    position: relative;
    display: block;
    width: 100%;
    min-height: 160px;
    border-radius: var(--rest-radius-card);
    overflow: hidden;
    margin: 16px 0;
    background: var(--rest-surface);
    box-shadow: var(--rest-shadow-md);
    cursor: pointer;
    transition: transform var(--rest-transition), box-shadow var(--rest-transition);
    text-decoration: none;
}

.rest-promo-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--rest-shadow-lg);
}

.rest-promo-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.rest-promo-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        color-mix(in srgb, var(--rest-bg), transparent 15%) 0%,
        color-mix(in srgb, var(--rest-bg), transparent 70%) 50%,
        transparent 100%
    );
    pointer-events: none;
}

.rest-promo-card .promo-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    z-index: 2;
    color: var(--rest-text);
}

.rest-promo-card .promo-title {
    font-size: 20px;
    font-weight: 700;
    margin: 0 0 6px;
}

.rest-promo-card .promo-subtitle {
    font-size: 13px;
    color: var(--rest-text-muted);
    margin: 0;
}

.rest-promo-card .promo-badge {
    display: inline-block;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 700;
    color: var(--rest-accent-text);
    background: var(--rest-accent);
    border-radius: var(--rest-radius-pill);
    margin-bottom: 8px;
}


/* ==========================================================
   8. HOME - SECTION TITLE
   ========================================================== */
.rest-section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px var(--rest-gutter) 12px;
}

.rest-section-title h2,
.rest-section-title .title-text {
    font-size: 17px;
    font-weight: 800;
    color: var(--rest-text);
    margin: 0;
    display: flex;
    align-items: center;
    letter-spacing: -0.01em;
}

.rest-section-title a,
.rest-section-title .title-link {
    font-size: 12px;
    font-weight: 600;
    color: var(--rest-accent);
    text-decoration: none;
    transition: all var(--rest-transition);
    display: flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: var(--rest-radius-pill);
    background: rgba(var(--rest-accent-rgb), 0.08);
}

.rest-section-title a:hover,
.rest-section-title .title-link:hover {
    background: rgba(var(--rest-accent-rgb), 0.15);
    text-decoration: none;
}


/* ==========================================================
   9. HOME - CATEGORY TABS (horizontal scroll)
   ========================================================== */
.rest-categories-scroll {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 4px var(--rest-gutter) 12px;
    scroll-snap-type: x mandatory;
    scrollbar-width: thin;
    scrollbar-color: var(--rest-border-medium) transparent;
}

.rest-categories-scroll::-webkit-scrollbar {
    height: 4px;
}
.rest-categories-scroll::-webkit-scrollbar-track {
    background: transparent;
}
.rest-categories-scroll::-webkit-scrollbar-thumb {
    background: var(--rest-border-medium);
    border-radius: 2px;
}

.rest-category-tab {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    color: var(--rest-text-muted);
    background: var(--rest-surface);
    border: 1px solid var(--rest-border);
    border-radius: var(--rest-radius-pill);
    white-space: nowrap;
    cursor: pointer;
    scroll-snap-align: start;
    transition: all var(--rest-transition);
    text-decoration: none;
    -webkit-tap-highlight-color: transparent;
}

.rest-category-tab:hover {
    background: var(--rest-surface-light);
    color: var(--rest-text);
}

.rest-category-tab.active {
    color: var(--rest-accent-text);
    background: var(--rest-accent);
    border-color: var(--rest-accent);
    box-shadow: var(--rest-shadow-accent);
}

.rest-category-tab img,
.rest-category-tab .tab-icon {
    width: 22px;
    height: 22px;
    border-radius: var(--rest-radius-full);
    object-fit: cover;
}

.rest-category-featured {
    background: linear-gradient(135deg, #fff8e1, #fff3cd);
    border-color: #f5a623;
    color: #b8860b;
}
.rest-category-featured:hover {
    background: linear-gradient(135deg, #fff3cd, #ffe9a0);
    color: #8b6914;
}
.rest-category-featured.active {
    background: linear-gradient(135deg, #f5a623, #e6951c);
    border-color: #e6951c;
    color: #fff;
    box-shadow: 0 2px 8px rgba(245, 166, 35, 0.35);
}
.rest-category-featured .rest-cat-count {
    color: #b8860b;
}
.rest-category-featured.active .rest-cat-count {
    color: rgba(255,255,255,0.85);
}

.rest-cat-count {
    font-size: 10px;
    font-weight: 700;
    color: var(--rest-text-muted);
    background: var(--rest-overlay-subtle);
    padding: 1px 7px;
    border-radius: var(--rest-radius-full);
    line-height: 1.4;
}


/* ==========================================================
   10. HOME - GRID & FEATURED CARD (vertical)
   ========================================================== */
.rest-home-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 0 var(--rest-gutter) 8px;
}

@media (min-width: 576px) {
    .rest-home-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 992px) {
    .rest-home-grid { grid-template-columns: repeat(4, 1fr); }
}

.rest-featured-card {
    display: flex;
    flex-direction: column;
    background: var(--rest-surface);
    border-radius: var(--rest-radius-card);
    box-shadow: var(--rest-shadow-sm);
    cursor: pointer;
    text-decoration: none;
    color: var(--rest-text);
    overflow: hidden;
    transition: transform var(--rest-transition), box-shadow var(--rest-transition);
    animation: restFadeIn 0.4s ease both;
}

.rest-featured-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--rest-shadow-md);
}

.rest-featured-img-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 1;
    overflow: hidden;
    background: var(--rest-surface-light);
}

.rest-featured-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.rest-featured-card:hover .rest-featured-img-wrap img {
    transform: scale(1.05);
}

.rest-featured-img-wrap .rest-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    z-index: 2;
}

.rest-featured-in-cart {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--rest-success);
    color: #fff;
    border-radius: 50%;
    font-size: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.rest-featured-body {
    padding: 10px 12px 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
}

.rest-featured-card .featured-name {
    font-size: 13px;
    font-weight: 600;
    margin: 0;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.rest-featured-card .featured-desc {
    font-size: 11px;
    color: var(--rest-text-muted);
    margin: 2px 0 0;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.rest-featured-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    margin-top: auto;
}

.rest-featured-card .featured-price {
    display: flex;
    flex-direction: column;
    gap: 0;
    min-width: 0;
}

.rest-featured-card .featured-price .price-old {
    font-size: 11px;
    font-weight: 500;
    color: var(--rest-text-muted);
    text-decoration: line-through;
    line-height: 1;
}

.rest-featured-card .featured-price .price-current {
    font-size: 15px;
    font-weight: 800;
    color: var(--rest-accent);
    line-height: 1.2;
}

.rest-btn-add-sm {
    width: 34px;
    height: 34px;
    min-width: 34px;
    padding: 0;
    border-radius: 10px;
    font-size: 13px;
    flex-shrink: 0;
}

.rest-btn-add-sm i { margin: 0; }

/* Default product image placeholder */
.rest-default-product-img {
    background: linear-gradient(135deg, var(--rest-surface, #1a1a2e) 0%, var(--rest-surface-light, #2d2d4f) 100%) !important;
}

.rest-featured-img-wrap .rest-default-product-img {
    width: 100%;
    height: 100%;
    position: absolute;
    inset: 0;
}


/* ==========================================================
   11. MENU - HEADER
   ========================================================== */
.rest-menu-header {
    position: sticky;
    top: var(--rest-header-h);
    z-index: var(--rest-z-sticky);
    background: var(--rest-bg);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    padding: 12px 0 0;
    border-bottom: 1px solid var(--rest-border-light);
}

.rest-menu-header .rest-categories-scroll {
    padding-bottom: 8px;
}

/* Subcategory tabs bar */
.rest-subcategories-bar {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding: 0 var(--rest-gutter) 10px;
    border-top: 1px solid var(--rest-border-light);
    padding-top: 8px;
    scrollbar-width: thin;
    scrollbar-color: var(--rest-border-medium) transparent;
}

.rest-subcategories-bar::-webkit-scrollbar {
    height: 4px;
}
.rest-subcategories-bar::-webkit-scrollbar-track {
    background: transparent;
}
.rest-subcategories-bar::-webkit-scrollbar-thumb {
    background: var(--rest-border-medium);
    border-radius: 2px;
}

.rest-subcategory-tab {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 14px;
    font-family: inherit;
    font-size: 12px;
    font-weight: 600;
    color: var(--rest-text-muted);
    background: transparent;
    border: 1px solid var(--rest-border-medium);
    border-radius: var(--rest-radius-pill);
    white-space: nowrap;
    cursor: pointer;
    transition: all var(--rest-transition);
    text-decoration: none;
    -webkit-tap-highlight-color: transparent;
}

.rest-subcategory-tab:hover {
    background: var(--rest-border-light);
    color: var(--rest-text);
    text-decoration: none;
}

.rest-subcategory-tab.active {
    color: var(--rest-accent);
    background: rgba(var(--rest-accent-rgb), 0.1);
    border-color: var(--rest-accent);
}

.rest-menu-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px var(--rest-gutter) 4px;
}

.rest-menu-count {
    font-size: 12px;
    font-weight: 600;
    color: var(--rest-text-muted);
}

.rest-menu-sort {
    appearance: none;
    -webkit-appearance: none;
    font-family: inherit;
    font-size: 12px;
    font-weight: 600;
    color: var(--rest-text-muted);
    background: var(--rest-surface);
    border: 1px solid var(--rest-border-medium);
    border-radius: var(--rest-radius-pill);
    padding: 6px 28px 6px 14px;
    outline: none;
    cursor: pointer;
    transition: all var(--rest-transition);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' fill='none'%3E%3Cpath d='M1 1l4 4 4-4' stroke='rgba(255,255,255,0.4)' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
}

.rest-menu-sort:focus {
    border-color: var(--rest-accent);
    color: var(--rest-text);
}

.rest-menu-sort option {
    background: var(--rest-surface);
    color: var(--rest-text);
}

/* Menu pagination */
.rest-pagination {
    display: flex;
    gap: 6px;
    justify-content: center;
    flex-wrap: wrap;
    padding: 16px var(--rest-gutter) 20px;
}

.rest-page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    color: var(--rest-text-muted);
    background: var(--rest-surface);
    border: 1px solid var(--rest-border);
    border-radius: 10px;
    text-decoration: none;
    cursor: pointer;
    transition: all var(--rest-transition);
}

.rest-page-btn:hover {
    background: var(--rest-surface-light);
    color: var(--rest-text);
    text-decoration: none;
}

.rest-page-btn.active {
    background: var(--rest-accent);
    color: var(--rest-accent-text);
    border-color: var(--rest-accent);
    box-shadow: 0 2px 12px rgba(var(--rest-accent-rgb), 0.3);
}


/* ==========================================================
   12. MENU - PRODUCT CARDS
   ========================================================== */
.rest-product-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 12px var(--rest-gutter);
}

@media (min-width: 576px) {
    .rest-product-list { grid-template-columns: repeat(3, 1fr); gap: 14px; }
}

@media (min-width: 992px) {
    .rest-product-list { grid-template-columns: repeat(4, 1fr); gap: 16px; }
}

.rest-product-card {
    display: flex;
    flex-direction: column;
    background: var(--rest-surface);
    border-radius: var(--rest-radius-card);
    box-shadow: var(--rest-shadow-sm);
    transition: transform var(--rest-transition), box-shadow var(--rest-transition);
    animation: restFadeIn 0.35s ease both;
    text-decoration: none;
    color: var(--rest-text);
    cursor: pointer;
    overflow: hidden;
}

.rest-product-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--rest-shadow-md);
}

.rest-product-card-img-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 1;
    overflow: hidden;
    background: var(--rest-surface-light);
}

.rest-product-card-img-wrap .rest-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    z-index: 2;
}

.rest-card-in-cart {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--rest-success);
    color: #fff;
    border-radius: 50%;
    font-size: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    z-index: 2;
}

.rest-card-in-cart-remove {
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}
.rest-card-in-cart-remove:hover {
    background: #e74c3c;
    transform: scale(1.15);
}
.rest-card-in-cart-remove:active {
    transform: scale(0.9);
}

.rest-product-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.rest-product-card:hover .rest-product-card-img {
    transform: scale(1.05);
}

.rest-product-card-img-wrap .rest-default-product-img {
    width: 100%;
    height: 100%;
    position: absolute;
    inset: 0;
}

.rest-product-card-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 10px 12px 12px;
}

.rest-product-card-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--rest-text);
    margin: 0;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.rest-product-card-desc {
    font-size: 11px;
    color: var(--rest-text-muted);
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.4;
}

.rest-product-card-price {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-top: auto;
    min-width: 0;
}

.rest-product-card-price .price-old {
    font-size: 11px;
    font-weight: 500;
    color: var(--rest-text-muted);
    text-decoration: line-through;
    line-height: 1;
}

.rest-product-card-price .price-current {
    font-size: 15px;
    font-weight: 800;
    color: var(--rest-accent);
    line-height: 1.2;
}

.rest-product-card-footer {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 6px;
    margin-top: auto;
    padding-top: 4px;
}

/* Add button */
.rest-btn-add {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 7px 18px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    color: var(--rest-accent-text);
    background: var(--rest-accent);
    border: none;
    border-radius: var(--rest-radius-btn);
    cursor: pointer;
    transition: all var(--rest-transition);
    white-space: nowrap;
    -webkit-tap-highlight-color: transparent;
    box-shadow: var(--rest-shadow-accent);
    text-decoration: none;
}

.rest-btn-add:hover {
    filter: brightness(1.1);
    transform: translateY(-1px);
}

.rest-btn-add:active {
    transform: scale(0.95);
}

.rest-btn-add.added {
    background: var(--rest-success);
    color: #fff;
}


/* ==========================================================
   13. PRODUCT DETAIL MODAL
   ========================================================== */
.rest-product-modal {
    position: fixed;
    inset: 0;
    z-index: var(--rest-z-modal);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--rest-transition), visibility var(--rest-transition);
}

.rest-product-modal.open {
    opacity: 1;
    visibility: visible;
}

.rest-product-modal .modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.rest-product-modal .modal-content {
    position: relative;
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    background: var(--rest-surface);
    border-radius: var(--rest-radius-card) var(--rest-radius-card) 0 0;
    overflow-y: auto;
    transform: translateY(100%);
    transition: transform 0.35s cubic-bezier(0.32, 0.72, 0, 1);
    box-shadow: var(--rest-shadow-lg);
}

.rest-product-modal.open .modal-content {
    transform: translateY(0);
}

.rest-product-modal .modal-handle {
    display: flex;
    justify-content: center;
    padding: 10px 0 6px;
}

.rest-product-modal .modal-handle::after {
    content: '';
    width: 36px;
    height: 4px;
    background: var(--rest-text-muted);
    opacity: 0.3;
    border-radius: 2px;
}

.rest-product-modal .modal-img {
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.rest-product-modal .modal-body {
    padding: 20px;
}

.rest-product-modal .modal-title {
    font-size: 20px;
    font-weight: 700;
    margin: 0 0 8px;
}

.rest-product-modal .modal-desc {
    font-size: 14px;
    color: var(--rest-text-muted);
    margin: 0 0 16px;
    line-height: 1.5;
}

.rest-product-modal .modal-price {
    font-size: 22px;
    font-weight: 800;
    color: var(--rest-accent);
    margin: 0 0 20px;
}

.rest-product-modal .modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.4);
    border: none;
    border-radius: var(--rest-radius-full);
    color: var(--rest-text);
    font-size: 18px;
    cursor: pointer;
    z-index: 2;
    transition: background var(--rest-transition);
}

.rest-product-modal .modal-close:hover {
    background: rgba(0, 0, 0, 0.6);
}


/* ==========================================================
   14. CART - HEADER
   ========================================================== */
.rest-cart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px var(--rest-gutter) 12px;
}

.rest-cart-header .cart-title {
    font-size: 22px;
    font-weight: 700;
    margin: 0;
}

.rest-cart-header .cart-subtotal {
    font-size: 14px;
    color: var(--rest-text-muted);
}

.rest-cart-header .cart-subtotal strong {
    color: var(--rest-text);
    font-weight: 700;
}


/* ==========================================================
   15. CART - ITEM
   ========================================================== */
.rest-cart-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px var(--rest-gutter);
    background: var(--rest-surface);
    margin: 0 var(--rest-gutter) 10px;
    border-radius: var(--rest-radius-card);
    animation: restFadeIn 0.3s ease both;
    transition: transform var(--rest-transition), opacity var(--rest-transition);
}

.rest-cart-item.removing {
    transform: translateX(-100%);
    opacity: 0;
}

.rest-cart-item-img {
    width: 64px;
    height: 64px;
    border-radius: 10px;
    object-fit: cover;
    flex-shrink: 0;
    background: var(--rest-surface-light);
}

.rest-cart-item-info {
    flex: 1;
    min-width: 0;
}

.rest-cart-item-info .item-name {
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.rest-cart-item-info .item-variant {
    font-size: 12px;
    color: var(--rest-text-muted);
    margin: 0;
}

.rest-cart-item-price {
    font-size: 15px;
    font-weight: 700;
    color: var(--rest-text);
    white-space: nowrap;
    text-align: right;
    margin-left: auto;
}

/* Quantity controls */
.rest-cart-item-qty {
    display: flex;
    align-items: center;
    gap: 0;
    background: var(--rest-surface-light);
    border-radius: var(--rest-radius-sm);
    overflow: hidden;
    flex-shrink: 0;
}

.rest-cart-item-qty button {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 600;
    color: var(--rest-text);
    background: transparent;
    border: none;
    cursor: pointer;
    transition: background var(--rest-transition);
    -webkit-tap-highlight-color: transparent;
}

.rest-cart-item-qty button:hover {
    background: var(--rest-overlay-medium);
}

.rest-cart-item-qty button:active {
    background: var(--rest-overlay-hover);
}

.rest-cart-item-qty .qty-value {
    min-width: 28px;
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    color: var(--rest-text);
    padding: 0 2px;
}

/* Empty cart */
.rest-cart-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px var(--rest-gutter);
    text-align: center;
    animation: restFadeIn 0.5s ease;
}

.rest-cart-empty .empty-icon {
    font-size: 64px;
    margin-bottom: 16px;
    opacity: 0.35;
}

.rest-cart-empty .empty-title {
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 8px;
}

.rest-cart-empty .empty-text {
    font-size: 14px;
    color: var(--rest-text-muted);
    margin: 0 0 24px;
    max-width: 260px;
}


/* ==========================================================
   16. CART - SUMMARY & CHECKOUT BUTTON
   ========================================================== */
.rest-cart-summary {
    position: sticky;
    bottom: var(--rest-bottom-nav-h);
    left: 0;
    right: 0;
    padding: 16px var(--rest-gutter);
    background: color-mix(in srgb, var(--rest-bg), transparent 5%);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-top: 1px solid var(--rest-border);
    z-index: var(--rest-z-sticky);
}

.rest-cart-summary .summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    font-size: 14px;
    color: var(--rest-text-muted);
}

.rest-cart-summary .summary-row.total {
    font-size: 17px;
    font-weight: 700;
    color: var(--rest-text);
    margin-bottom: 14px;
    padding-top: 10px;
    border-top: 1px solid var(--rest-border-medium);
}

.rest-btn-checkout {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 15px 24px;
    font-family: inherit;
    font-size: 16px;
    font-weight: 700;
    color: var(--rest-accent-text);
    background: var(--rest-accent);
    border: none;
    border-radius: var(--rest-radius-btn);
    cursor: pointer;
    transition: all var(--rest-transition);
    box-shadow: var(--rest-shadow-accent);
    -webkit-tap-highlight-color: transparent;
    text-decoration: none;
}

.rest-btn-checkout:hover {
    filter: brightness(1.08);
    transform: translateY(-1px);
    box-shadow: 0 6px 24px rgba(var(--rest-accent-rgb), 0.35);
    color: var(--rest-accent-text);
    text-decoration: none;
}

.rest-btn-checkout:active {
    transform: scale(0.98);
}

.rest-btn-checkout:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    filter: none;
}


/* ==========================================================
   17. CHECKOUT - ORDER TYPE SELECTOR
   ========================================================== */
.rest-checkout-types {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    padding: 16px var(--rest-gutter);
}

.rest-checkout-type {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 20px 12px;
    background: var(--rest-surface);
    border: 2px solid var(--rest-border);
    border-radius: var(--rest-radius-card);
    color: var(--rest-text-muted);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--rest-transition);
    text-align: center;
    -webkit-tap-highlight-color: transparent;
}

.rest-checkout-type:hover {
    border-color: var(--rest-border-strong);
    background: var(--rest-surface-light);
}

.rest-checkout-type .type-icon {
    font-size: 28px;
    transition: transform var(--rest-transition);
}

.rest-checkout-type.active {
    border-color: var(--rest-accent);
    background: rgba(var(--rest-accent-rgb), 0.08);
    color: var(--rest-accent);
    box-shadow: 0 0 0 3px rgba(var(--rest-accent-rgb), 0.12);
}

.rest-checkout-type.active .type-icon {
    transform: scale(1.15);
}


/* ==========================================================
   18. CHECKOUT - FORM
   ========================================================== */
.rest-checkout-form {
    padding: 12px var(--rest-gutter) 24px;
}

.rest-form-group {
    margin-bottom: 18px;
}

.rest-form-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--rest-text-muted);
    margin-bottom: 6px;
    letter-spacing: 0.02em;
}

.rest-form-input {
    width: 100%;
    padding: 13px 16px;
    font-family: inherit;
    font-size: 15px;
    color: var(--rest-text);
    background: var(--rest-surface);
    border: 1px solid var(--rest-border-medium);
    border-radius: var(--rest-radius-btn);
    outline: none;
    transition: border-color var(--rest-transition), box-shadow var(--rest-transition);
    -webkit-appearance: none;
}

.rest-form-input::placeholder {
    color: var(--rest-text-muted);
}

.rest-form-input:focus {
    border-color: var(--rest-accent);
    box-shadow: 0 0 0 3px rgba(var(--rest-accent-rgb), 0.12);
}

.rest-form-input.error {
    border-color: var(--rest-danger);
    box-shadow: 0 0 0 3px rgba(248, 113, 113, 0.12);
}

.rest-form-input.error + .rest-form-error {
    display: block;
}

.rest-form-error {
    display: none;
    font-size: 12px;
    color: var(--rest-danger);
    margin-top: 4px;
}

/* Select override */
.rest-form-input select,
select.rest-form-input {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='rgba(255,255,255,0.5)' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
}

/* Textarea override */
textarea.rest-form-input {
    min-height: 90px;
    resize: vertical;
    line-height: 1.5;
}


/* ==========================================================
   19. CHECKOUT - ORDER SUMMARY
   ========================================================== */
.rest-order-summary {
    margin: 0 var(--rest-gutter) 20px;
    padding: 18px;
    background: var(--rest-surface);
    border-radius: var(--rest-radius-card);
    box-shadow: var(--rest-shadow-sm);
}

.rest-order-summary .summary-title {
    font-size: 16px;
    font-weight: 700;
    margin: 0 0 14px;
}

.rest-order-summary .summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    font-size: 14px;
    color: var(--rest-text-muted);
}

.rest-order-summary .summary-item .item-qty {
    color: var(--rest-text-muted);
    margin-right: 4px;
}

.rest-order-summary .summary-item .item-price {
    font-weight: 600;
    color: var(--rest-text);
}

.rest-order-summary .summary-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 12px;
    margin-top: 12px;
    border-top: 1px solid var(--rest-border-medium);
    font-size: 17px;
    font-weight: 700;
}

/* Confirm button */
.rest-btn-confirm {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 15px 24px;
    margin: 20px 0;
    font-family: inherit;
    font-size: 16px;
    font-weight: 700;
    color: var(--rest-accent-text);
    background: var(--rest-accent);
    border: none;
    border-radius: var(--rest-radius-btn);
    cursor: pointer;
    transition: all var(--rest-transition);
    box-shadow: var(--rest-shadow-accent);
    -webkit-tap-highlight-color: transparent;
}

.rest-btn-confirm:hover {
    filter: brightness(1.08);
    transform: translateY(-1px);
}

.rest-btn-confirm:active {
    transform: scale(0.98);
}

.rest-btn-confirm:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    filter: none;
}

.rest-btn-confirm .spinner {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(0, 0, 0, 0.2);
    border-top-color: var(--rest-accent-text);
    border-radius: 50%;
    animation: restSpin 0.6s linear infinite;
}


/* ==========================================================
   20. DETAIL PAGE
   ========================================================== */
.rest-detail-img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    border-radius: 0 0 var(--rest-radius-card) var(--rest-radius-card);
    display: block;
}

.rest-detail-info {
    padding: 20px var(--rest-gutter);
    animation: restFadeIn 0.4s ease;
}

.rest-detail-title {
    font-size: 24px;
    font-weight: 800;
    margin: 0 0 8px;
    line-height: 1.2;
}

.rest-detail-price {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}

.rest-detail-price .current-price {
    font-size: 24px;
    font-weight: 800;
    color: var(--rest-accent);
}

.rest-detail-price .old-price {
    font-size: 16px;
    color: var(--rest-text-muted);
    text-decoration: line-through;
}

.rest-detail-desc {
    font-size: 14px;
    line-height: 1.65;
    color: var(--rest-text-muted);
    margin: 0 0 24px;
}

.rest-detail-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px var(--rest-gutter);
    position: sticky;
    bottom: var(--rest-bottom-nav-h);
    background: color-mix(in srgb, var(--rest-bg), transparent 5%);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-top: 1px solid var(--rest-border);
}

.rest-detail-actions .qty-selector {
    display: flex;
    align-items: center;
    gap: 0;
    background: var(--rest-surface);
    border-radius: var(--rest-radius-btn);
    overflow: hidden;
}

.rest-detail-actions .qty-selector button {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 600;
    color: var(--rest-text);
    background: transparent;
    border: none;
    cursor: pointer;
    transition: background var(--rest-transition);
}

.rest-detail-actions .qty-selector button:hover {
    background: var(--rest-overlay-medium);
}

.rest-detail-actions .qty-selector .qty-value {
    min-width: 36px;
    text-align: center;
    font-size: 16px;
    font-weight: 700;
}

.rest-detail-actions .rest-btn-add {
    flex: 1;
    padding: 13px 20px;
    font-size: 15px;
}

/* Reviews section */
.rest-detail-reviews {
    padding: 20px var(--rest-gutter);
    border-top: 1px solid var(--rest-border);
    margin-top: 8px;
}

.rest-detail-reviews .reviews-title {
    font-size: 16px;
    font-weight: 700;
    margin: 0 0 14px;
}

.rest-detail-reviews .review-item {
    padding: 12px 0;
    border-bottom: 1px solid var(--rest-border-light);
}

.rest-detail-reviews .review-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px;
}

.rest-detail-reviews .review-avatar {
    width: 32px;
    height: 32px;
    border-radius: var(--rest-radius-full);
    object-fit: cover;
    background: var(--rest-surface-light);
}

.rest-detail-reviews .review-name {
    font-size: 13px;
    font-weight: 600;
}

.rest-detail-reviews .review-stars {
    color: var(--rest-accent);
    font-size: 12px;
    margin-left: auto;
}

.rest-detail-reviews .review-text {
    font-size: 13px;
    color: var(--rest-text-muted);
    line-height: 1.5;
    margin: 0;
}


/* ==========================================================
   21. ORDERS
   ========================================================== */
.rest-order-card {
    margin: 0 var(--rest-gutter) 12px;
    padding: 16px;
    background: var(--rest-surface);
    border-radius: var(--rest-radius-card);
    box-shadow: var(--rest-shadow-sm);
    cursor: pointer;
    transition: transform var(--rest-transition), box-shadow var(--rest-transition);
}

.rest-order-card:hover {
    transform: translateY(-1px);
    box-shadow: var(--rest-shadow-md);
}

.rest-order-card .order-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.rest-order-card .order-id {
    font-size: 14px;
    font-weight: 700;
}

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

.rest-order-card .order-items-preview {
    font-size: 13px;
    color: var(--rest-text-muted);
    margin: 0 0 10px;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.rest-order-card .order-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.rest-order-card .order-total {
    font-size: 16px;
    font-weight: 700;
}

/* Status badge */
.rest-order-status {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: var(--rest-radius-pill);
    line-height: 1.4;
    transition: all 0.3s ease;
}

.rest-order-status.status-pending {
    color: #e74c3c;
    background: rgba(231, 76, 60, 0.12);
    animation: rest-pulse-badge 2s ease-in-out infinite;
}

.rest-order-status.status-approved {
    color: #27ae60;
    background: rgba(39, 174, 96, 0.12);
}

.rest-order-status.status-preparing {
    color: #e67e22;
    background: rgba(230, 126, 34, 0.12);
    animation: rest-pulse-badge 2s ease-in-out infinite;
}

.rest-order-status.status-ready {
    color: #2980b9;
    background: rgba(41, 128, 185, 0.12);
    animation: rest-pulse-badge 1.5s ease-in-out infinite;
}

.rest-order-status.status-sending {
    color: #8e44ad;
    background: rgba(142, 68, 173, 0.12);
    animation: rest-pulse-badge 2s ease-in-out infinite;
}

.rest-order-status.status-delivered {
    color: #2c3e50;
    background: rgba(44, 62, 80, 0.12);
}

.rest-order-status.status-cancelled {
    color: #f87171;
    background: rgba(248, 113, 113, 0.12);
}

@keyframes rest-pulse-badge {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Order tracker (progress steps) */
.rest-order-tracker {
    display: flex;
    align-items: flex-start;
    padding: 14px 12px 10px;
    gap: 0;
}

.rest-tracker-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    position: relative;
    flex-shrink: 0;
}

.rest-tracker-dot {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.6rem;
    background: var(--rest-overlay-subtle);
    color: var(--rest-text-muted);
    border: 2px solid var(--rest-border-medium);
    transition: all 0.4s ease;
}

.rest-tracker-step.active .rest-tracker-dot {
    background: rgba(var(--rest-accent-rgb), 0.15);
    color: var(--rest-accent);
    border-color: var(--rest-accent);
}

.rest-tracker-step.current .rest-tracker-dot {
    background: var(--rest-accent);
    color: var(--rest-accent-text);
    border-color: var(--rest-accent);
    box-shadow: 0 0 0 4px rgba(var(--rest-accent-rgb), 0.2);
    animation: rest-pulse-dot 2s ease-in-out infinite;
}

@keyframes rest-pulse-dot {
    0%, 100% { box-shadow: 0 0 0 4px rgba(var(--rest-accent-rgb), 0.2); }
    50% { box-shadow: 0 0 0 8px rgba(var(--rest-accent-rgb), 0.08); }
}

.rest-tracker-label {
    font-size: 0.55rem;
    font-weight: 600;
    color: var(--rest-text-muted);
    text-align: center;
    max-width: 55px;
    line-height: 1.2;
}

.rest-tracker-step.active .rest-tracker-label {
    color: var(--rest-accent);
}

.rest-tracker-step.current .rest-tracker-label {
    color: var(--rest-text);
    font-weight: 700;
}

.rest-tracker-line {
    flex: 1;
    height: 2px;
    background: var(--rest-border-medium);
    margin-top: 14px;
    min-width: 10px;
    transition: background 0.4s ease;
}

.rest-tracker-line.active {
    background: var(--rest-accent);
}

/* Animations */
@keyframes rest-fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes rest-slide-up {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}

.rest-fade-in {
    animation: rest-fade-in 0.4s ease-out both;
}

.rest-slide-up {
    animation: rest-slide-up 0.4s ease-out both;
}

/* Order tracking progress bar */
.rest-order-tracking {
    display: flex;
    align-items: center;
    gap: 0;
    padding: 20px var(--rest-gutter);
    position: relative;
}

.rest-order-tracking .tracking-step {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 1;
}

.rest-order-tracking .tracking-dot {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--rest-surface-light);
    border: 2px solid var(--rest-border-strong);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: var(--rest-text-muted);
    transition: all 0.3s ease;
    margin-bottom: 8px;
}

.rest-order-tracking .tracking-step.completed .tracking-dot {
    background: var(--rest-accent);
    border-color: var(--rest-accent);
    color: var(--rest-accent-text);
}

.rest-order-tracking .tracking-step.active .tracking-dot {
    background: var(--rest-accent);
    border-color: var(--rest-accent);
    color: var(--rest-accent-text);
    box-shadow: 0 0 0 4px rgba(var(--rest-accent-rgb), 0.2);
    animation: restPulse 2s ease infinite;
}

.rest-order-tracking .tracking-label {
    font-size: 11px;
    color: var(--rest-text-muted);
    text-align: center;
    white-space: nowrap;
}

.rest-order-tracking .tracking-step.completed .tracking-label,
.rest-order-tracking .tracking-step.active .tracking-label {
    color: var(--rest-text);
    font-weight: 600;
}

/* Connecting line between steps */
.rest-order-tracking .tracking-line {
    flex: 1;
    height: 2px;
    background: var(--rest-overlay-medium);
    position: relative;
    top: -18px;
    margin: 0 -4px;
}

.rest-order-tracking .tracking-line.completed {
    background: var(--rest-accent);
}


/* ==========================================================
   22. SHARED - DIVIDER
   ========================================================== */
.rest-divider {
    height: 1px;
    background: var(--rest-overlay-subtle);
    border: none;
    margin: 8px 0;
}

.rest-divider.spaced {
    margin: 16px var(--rest-gutter);
}


/* ==========================================================
   23. SHARED - BADGE
   ========================================================== */
.rest-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 3px 10px;
    font-size: 12px;
    font-weight: 600;
    border-radius: var(--rest-radius-pill);
    line-height: 1.4;
    white-space: nowrap;
    color: var(--rest-accent-text);
    background: var(--rest-accent);
}

.rest-badge.badge-success {
    color: #fff;
    background: var(--rest-success);
}

.rest-badge.badge-warning {
    color: #1a1a2e;
    background: var(--rest-warning);
}

.rest-badge.badge-danger {
    color: #fff;
    background: var(--rest-danger);
}

.rest-badge.badge-info {
    color: #fff;
    background: var(--rest-info);
}

.rest-badge.badge-outline {
    color: var(--rest-text);
    background: transparent;
    border: 1px solid var(--rest-border-strong);
}


/* ==========================================================
   24. SHARED - SKELETON LOADING
   ========================================================== */
.rest-skeleton {
    position: relative;
    overflow: hidden;
    background: var(--rest-surface);
    border-radius: var(--rest-radius-sm);
}

.rest-skeleton::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        90deg,
        transparent 0%,
        var(--rest-border-light) 40%,
        var(--rest-overlay-medium) 50%,
        var(--rest-border-light) 60%,
        transparent 100%
    );
    animation: restShimmer 1.5s ease infinite;
}

.rest-skeleton.skeleton-text {
    height: 14px;
    width: 80%;
    margin-bottom: 8px;
    border-radius: 4px;
}

.rest-skeleton.skeleton-text.short {
    width: 50%;
}

.rest-skeleton.skeleton-img {
    width: 100px;
    height: 100px;
    border-radius: 12px;
}

.rest-skeleton.skeleton-card {
    height: 120px;
    border-radius: var(--rest-radius-card);
}

.rest-skeleton.skeleton-circle {
    width: 42px;
    height: 42px;
    border-radius: 50%;
}

@keyframes restShimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}


/* ==========================================================
   25. ANIMATIONS
   ========================================================== */
@keyframes restFadeIn {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes restSlideUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

@keyframes restPulse {
    0%, 100% { box-shadow: 0 0 0 4px rgba(var(--rest-accent-rgb), 0.2); }
    50% { box-shadow: 0 0 0 8px rgba(var(--rest-accent-rgb), 0.08); }
}

/* Staggered entrance for lists */
.rest-product-card:nth-child(1) { animation-delay: 0s; }
.rest-product-card:nth-child(2) { animation-delay: 0.05s; }
.rest-product-card:nth-child(3) { animation-delay: 0.1s; }
.rest-product-card:nth-child(4) { animation-delay: 0.15s; }
.rest-product-card:nth-child(5) { animation-delay: 0.2s; }
.rest-product-card:nth-child(6) { animation-delay: 0.25s; }
.rest-product-card:nth-child(7) { animation-delay: 0.3s; }
.rest-product-card:nth-child(8) { animation-delay: 0.35s; }
.rest-product-card:nth-child(9) { animation-delay: 0.4s; }
.rest-product-card:nth-child(10) { animation-delay: 0.45s; }

.rest-order-card:nth-child(1) { animation-delay: 0s; }
.rest-order-card:nth-child(2) { animation-delay: 0.06s; }
.rest-order-card:nth-child(3) { animation-delay: 0.12s; }
.rest-order-card:nth-child(4) { animation-delay: 0.18s; }
.rest-order-card:nth-child(5) { animation-delay: 0.24s; }


/* ==========================================================
   26. UTILITY CLASSES
   ========================================================== */
.rest-text-accent { color: var(--rest-accent) !important; }
.rest-text-muted { color: var(--rest-text-muted) !important; }
.rest-text-success { color: var(--rest-success) !important; }
.rest-text-danger { color: var(--rest-danger) !important; }
.rest-bg-surface { background: var(--rest-surface) !important; }
.rest-bg-surface-light { background: var(--rest-surface-light) !important; }

.rest-px { padding-left: var(--rest-gutter); padding-right: var(--rest-gutter); }
.rest-mt-sm { margin-top: 8px; }
.rest-mt-md { margin-top: 16px; }
.rest-mt-lg { margin-top: 24px; }
.rest-mb-sm { margin-bottom: 8px; }
.rest-mb-md { margin-bottom: 16px; }
.rest-mb-lg { margin-bottom: 24px; }

.rest-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}


/* ==========================================================
   27. SCROLLBAR STYLING
   ========================================================== */
.rest-body::-webkit-scrollbar {
    width: 6px;
}

.rest-body::-webkit-scrollbar-track {
    background: var(--rest-bg);
}

.rest-body::-webkit-scrollbar-thumb {
    background: var(--rest-surface-light);
    border-radius: 3px;
}

.rest-body::-webkit-scrollbar-thumb:hover {
    background: var(--rest-text-muted);
}


/* ==========================================================
   28. RESPONSIVE - TABLET (>= 768px)
   ========================================================== */
@media (min-width: 768px) {
    :root {
        --rest-gutter: 24px;
    }

    .rest-body {
        padding-bottom: 24px; /* No bottom nav on tablet+ */
    }

    /* Hide bottom nav on desktop */
    .rest-bottom-nav {
        display: none;
    }

    /* Cart summary no longer above bottom nav */
    .rest-cart-summary {
        bottom: 0;
    }

    .rest-detail-actions {
        bottom: 0;
    }

    /* Header widens */
    .rest-header {
        padding: 0 32px;
    }

    /* Hero */
    .rest-hero {
        padding: 28px 32px 16px;
    }

    .rest-hero-greeting {
        font-size: 32px;
    }

    /* Product grid - tablet */
    .rest-product-list {
        gap: 16px;
        padding: 16px 32px;
    }

    /* Promo card */
    .rest-promo-card {
        min-height: 200px;
        margin: 16px 32px;
    }

    /* Section title */
    .rest-section-title {
        padding: 24px 32px 12px;
    }

    /* Categories */
    .rest-categories-scroll {
        padding: 4px 32px 14px;
    }

    /* Cart items */
    .rest-cart-item {
        margin: 0 32px 12px;
    }

    /* Order cards */
    .rest-order-card {
        margin: 0 32px 14px;
    }

    /* Detail image */
    .rest-detail-img {
        height: 360px;
        border-radius: 0 0 20px 20px;
    }

    /* Checkout types */
    .rest-checkout-types {
        padding: 20px 32px;
        gap: 16px;
    }

    /* Forms */
    .rest-checkout-form {
        padding: 16px 32px 28px;
    }

    /* Order summary */
    .rest-order-summary {
        margin: 0 32px 24px;
    }

    /* Modal */
    .rest-product-modal {
        align-items: center;
    }

    .rest-product-modal .modal-content {
        border-radius: var(--rest-radius-card);
        transform: translateY(40px);
        max-height: 85vh;
    }

    .rest-product-modal.open .modal-content {
        transform: translateY(0);
    }
}


/* ==========================================================
   29. RESPONSIVE - DESKTOP (>= 992px)
   ========================================================== */
@media (min-width: 992px) {
    :root {
        --rest-gutter: 32px;
    }

    /* Center content in a max-width container */
    .rest-body {
        max-width: 1200px;
        margin-left: auto;
        margin-right: auto;
    }

    .rest-header {
        max-width: 1200px;
        left: 50%;
        right: auto;
        transform: translateX(-50%);
        border-radius: 0 0 var(--rest-radius-card) var(--rest-radius-card);
        box-shadow: var(--rest-shadow-md);
    }

    /* Product grid - desktop */
    .rest-product-list {
        gap: 18px;
    }

    /* Larger detail image */
    .rest-detail-img {
        height: 420px;
    }

    /* Sidebar-friendly layout */
    .rest-layout-sidebar {
        display: grid;
        grid-template-columns: 280px 1fr;
        gap: 24px;
        padding: 0 var(--rest-gutter);
    }

    .rest-layout-sidebar .rest-sidebar {
        position: sticky;
        top: calc(var(--rest-header-h) + 16px);
        align-self: start;
        background: var(--rest-surface);
        border-radius: var(--rest-radius-card);
        padding: 20px;
        max-height: calc(100vh - var(--rest-header-h) - 32px);
        overflow-y: auto;
    }

    .rest-layout-sidebar .rest-main {
        min-width: 0;
    }

    /* Sidebar nav items */
    .rest-sidebar-nav {
        list-style: none;
        margin: 0;
        padding: 0;
    }

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

    .rest-sidebar-nav a {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 10px 14px;
        font-size: 14px;
        font-weight: 500;
        color: var(--rest-text-muted);
        text-decoration: none;
        border-radius: var(--rest-radius-sm);
        transition: all var(--rest-transition);
    }

    .rest-sidebar-nav a:hover {
        color: var(--rest-text);
        background: var(--rest-border-light);
    }

    .rest-sidebar-nav a.active {
        color: var(--rest-accent);
        background: rgba(var(--rest-accent-rgb), 0.08);
        font-weight: 600;
    }

    /* Checkout 2-column layout */
    .rest-checkout-layout {
        display: grid;
        grid-template-columns: 1fr 380px;
        gap: 24px;
        padding: 0 var(--rest-gutter);
        align-items: start;
    }

    .rest-checkout-layout .rest-order-summary {
        position: sticky;
        top: calc(var(--rest-header-h) + 16px);
        margin: 0;
    }

    /* Detail 2-column */
    .rest-detail-layout {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 32px;
        padding: 24px var(--rest-gutter);
    }

    .rest-detail-layout .rest-detail-img {
        height: 400px;
        border-radius: var(--rest-radius-card);
    }

    .rest-detail-layout .rest-detail-info {
        padding: 0;
    }

    .rest-detail-layout .rest-detail-actions {
        position: static;
        background: transparent;
        backdrop-filter: none;
        border-top: none;
        padding: 16px 0;
    }
}


/* ==========================================================
   30. RESPONSIVE - LARGE DESKTOP (>= 1200px)
   ========================================================== */
@media (min-width: 1200px) {
    .rest-product-list {
        grid-template-columns: repeat(5, 1fr);
    }
}


/* ==========================================================
   31. DARK MODE OVERRIDES FOR SYSTEM VARS
   ========================================================== */

/* When business color system vars are present, map them */
.rest-body[data-theme="custom"] {
    --rest-bg: var(--main-bg-color, #1a1a2e);
    --rest-text: var(--main-text-color, #fff);
    --rest-accent: var(--outline-bg-color, #f5a623);
    --rest-accent-text: var(--outline-text-color, #1a1a2e);
}

/* Footer integration */
.rest-footer {
    background: var(--footer-bg-color, var(--rest-surface));
    color: var(--footer-text-color, var(--rest-text-muted));
    padding: 24px var(--rest-gutter);
    text-align: center;
    font-size: 13px;
    border-top: 1px solid var(--rest-border);
}

.rest-footer a {
    color: var(--rest-accent);
    text-decoration: none;
}

.rest-footer a:hover {
    text-decoration: underline;
}


/* ==========================================================
   MODAL & AUTH
   ========================================================== */
.rest-modal {
    background: var(--rest-surface);
    border: 1px solid var(--rest-border-medium);
    border-radius: var(--rest-radius-card);
    color: var(--rest-text);
}

.rest-modal-close-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: none;
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 2;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    transition: background 0.2s;
}
.rest-modal-close-btn:hover {
    background: rgba(0, 0, 0, 0.7);
}

.rest-modal-description {
    color: var(--rest-text-muted);
    font-size: 0.85rem;
    line-height: 1.5;
    margin-bottom: 12px;
    padding: 8px 12px;
    background: var(--rest-surface-light, rgba(0,0,0,0.03));
    border-radius: 8px;
    border-left: 3px solid var(--rest-accent, #ff4757);
}
.rest-modal-description p {
    margin: 0 0 4px;
}
.rest-modal-description p:last-child {
    margin-bottom: 0;
}
.rest-modal-description ul,
.rest-modal-description ol {
    margin: 0;
    padding-left: 18px;
}
.rest-modal-description strong {
    color: var(--rest-text);
}

.rest-modal .modal-header {
    border-bottom: 1px solid var(--rest-border);
    padding: 16px 20px;
}

.rest-modal .modal-title {
    font-weight: 700;
    font-size: 1.1rem;
}

.rest-modal .modal-body {
    padding: 20px;
}

.rest-auth-tabs {
    gap: 4px;
}

.rest-auth-tabs .nav-link {
    color: var(--rest-text-muted);
    background: transparent;
    border-radius: var(--rest-radius-pill);
    font-size: 0.88rem;
    font-weight: 600;
    padding: 8px 18px;
}

.rest-auth-tabs .nav-link.active {
    color: var(--rest-accent-text);
    background: var(--rest-accent);
}

.rest-btn-accent {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: var(--rest-radius-btn);
    background: var(--rest-accent);
    color: var(--rest-accent-text);
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    transition: opacity var(--rest-transition), transform var(--rest-transition);
}

.rest-btn-accent:hover {
    opacity: 0.9;
}

.rest-btn-accent:active {
    transform: scale(0.97);
}

.rest-user-greeting {
    color: var(--rest-text-muted);
    font-size: 0.85rem;
}


/* ==========================================================
   DETAIL PAGE
   ========================================================== */
.rest-detail-gallery {
    position: relative;
    background: var(--rest-surface);
    overflow: hidden;
}

.rest-detail-gallery .main-image {
    width: 100%;
    height: 280px;
    object-fit: cover;
    display: block;
}

.rest-detail-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 2;
    background: var(--rest-danger);
    color: #fff;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.72rem;
    font-weight: 700;
}

.rest-detail-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.45);
    color: #fff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.75rem;
    transition: background var(--rest-transition);
    z-index: 2;
}

.rest-detail-nav:hover {
    background: rgba(0, 0, 0, 0.7);
}

.rest-detail-nav.prev { left: 10px; }
.rest-detail-nav.next { right: 10px; }

.rest-detail-thumbs {
    display: flex;
    gap: 6px;
    padding-top: 10px;
    padding-bottom: 6px;
    overflow-x: auto;
}

.rest-detail-thumbs::-webkit-scrollbar { height: 0; }

.rest-detail-thumb {
    width: 52px;
    height: 52px;
    min-width: 52px;
    border-radius: var(--rest-radius-sm);
    overflow: hidden;
    border: 2px solid transparent;
    cursor: pointer;
    transition: border-color var(--rest-transition), opacity var(--rest-transition);
    opacity: 0.6;
}

.rest-detail-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.rest-detail-thumb:hover {
    opacity: 0.85;
}

.rest-detail-thumb.active_item_select {
    border-color: var(--rest-accent);
    opacity: 1;
}

.rest-detail-info {
    padding: 16px var(--rest-gutter) 20px;
}

.rest-detail-category {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--rest-accent);
    background: rgba(var(--rest-accent-rgb), 0.12);
    padding: 3px 10px;
    border-radius: var(--rest-radius-pill);
    margin-bottom: 8px;
    text-decoration: none;
}

.rest-detail-category:hover {
    color: var(--rest-accent);
    text-decoration: none;
    background: rgba(var(--rest-accent-rgb), 0.2);
}

.rest-detail-title {
    font-size: 1.3rem;
    font-weight: 800;
    margin-bottom: 6px;
    line-height: 1.3;
}

.rest-detail-rating {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.rest-detail-stars {
    display: flex;
    gap: 2px;
}

.rest-detail-stars i {
    color: #ffc107;
    font-size: 0.8rem;
}

.rest-detail-rating-count {
    font-size: 0.78rem;
    color: var(--rest-text-muted);
}

.rest-detail-price-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.rest-detail-price-wrap .rest-detail-price {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--rest-accent);
}

.rest-detail-price-old {
    font-size: 0.9rem;
    color: var(--rest-text-muted);
    text-decoration: line-through;
}

.rest-detail-discount-tag {
    font-size: 0.72rem;
    font-weight: 700;
    color: #fff;
    background: var(--rest-danger);
    padding: 2px 8px;
    border-radius: 4px;
}

.rest-detail-desc {
    font-size: 0.88rem;
    line-height: 1.6;
    color: var(--rest-text-muted);
    margin-bottom: 12px;
}

.rest-detail-desc img {
    max-width: 100%;
    border-radius: var(--rest-radius-sm);
}

.rest-detail-variants {
    margin-bottom: 14px;
}

.rest-detail-variants label {
    display: block;
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--rest-text-muted);
    margin-bottom: 6px;
}

.rest-variant-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.rest-variant-pill {
    display: inline-block;
    padding: 6px 14px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--rest-text-muted);
    background: var(--rest-surface);
    border: 1px solid var(--rest-border-medium);
    border-radius: var(--rest-radius-pill);
    cursor: pointer;
    transition: all var(--rest-transition);
}

.rest-variant-pill:hover {
    color: var(--rest-text);
    border-color: var(--rest-border-strong);
}

.rest-variant-pill.active {
    color: var(--rest-accent-text);
    background: var(--rest-accent);
    border-color: var(--rest-accent);
}

.rest-detail-divider {
    height: 1px;
    background: var(--rest-overlay-subtle);
    margin: 14px 0;
}

.rest-detail-btn-remove {
    width: 40px;
    height: 40px;
    border-radius: var(--rest-radius-btn);
    border: 1px solid var(--rest-border-strong);
    background: transparent;
    color: var(--rest-text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--rest-transition);
}

.rest-detail-btn-remove:hover {
    color: var(--rest-danger);
    border-color: var(--rest-danger);
    background: rgba(248, 113, 113, 0.1);
}


/* ==========================================================
   REVIEWS
   ========================================================== */
.rest-review-card {
    background: var(--rest-surface);
    border-radius: var(--rest-radius-sm);
    padding: 12px;
    margin-bottom: 8px;
}

.rest-review-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px;
}

.rest-review-avatar {
    width: 34px;
    height: 34px;
    min-width: 34px;
    border-radius: 50%;
    background: var(--rest-surface-light);
    color: var(--rest-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
}

.rest-review-info {
    flex: 1;
    min-width: 0;
}

.rest-review-name {
    font-size: 0.82rem;
    font-weight: 600;
}

.rest-review-date {
    font-size: 0.72rem;
    color: var(--rest-text-muted);
}

.rest-review-stars {
    display: flex;
    gap: 1px;
}

.rest-review-stars i {
    color: #ffc107;
    font-size: 0.7rem;
}

.rest-review-text {
    font-size: 0.82rem;
    color: var(--rest-text-muted);
    margin: 0;
    line-height: 1.5;
}


/* ==========================================================
   PAYMENT STATUS
   ========================================================== */
.rest-pay-status {
    text-align: center;
    padding: 24px var(--rest-gutter);
    margin-bottom: 16px;
}

.rest-pay-status h3 {
    font-weight: 700;
    font-size: 1.1rem;
    margin-bottom: 4px;
}

.rest-pay-status p {
    color: var(--rest-text-muted);
    font-size: 0.85rem;
    margin: 0;
}

.rest-pay-status-icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 12px;
}

.rest-pay-status-icon.success {
    background: rgba(52, 211, 153, 0.15);
    color: var(--rest-success);
}

.rest-pay-status-icon.error {
    background: rgba(248, 113, 113, 0.15);
    color: var(--rest-danger);
}


/* ==========================================================
   WHATSAPP FLOATING BUTTON
   ========================================================== */
.rest-floating-wa {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: #25d366;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    text-decoration: none;
    box-shadow: 0 4px 16px rgba(37, 211, 102, 0.35);
    z-index: var(--rest-z-sticky);
    transition: transform var(--rest-transition), box-shadow var(--rest-transition);
}

.rest-floating-wa:hover {
    color: #fff;
    text-decoration: none;
    transform: scale(1.08);
    box-shadow: 0 6px 24px rgba(37, 211, 102, 0.45);
}

/* ==========================================================
   FLOATING CART BUTTON
   ========================================================== */
.rest-floating-cart {
    position: fixed;
    bottom: 80px;
    right: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 18px;
    background: var(--rest-accent);
    color: var(--rest-accent-text);
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.85rem;
    box-shadow: 0 4px 20px rgba(0,0,0,0.25);
    z-index: 999;
    animation: restFloatingCartIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.rest-floating-cart:hover {
    color: var(--rest-accent-text);
    text-decoration: none;
    transform: scale(1.05);
    box-shadow: 0 6px 28px rgba(0,0,0,0.3);
}
.rest-floating-cart-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    background: var(--rest-accent-text);
    color: var(--rest-accent);
    font-size: 0.7rem;
    font-weight: 800;
    border-radius: 50px;
    line-height: 1;
}
.rest-floating-cart-total {
    font-size: 0.82rem;
    font-weight: 700;
}
@keyframes restFloatingCartIn {
    0%   { opacity: 0; transform: translateY(20px) scale(0.8); }
    100% { opacity: 1; transform: translateY(0) scale(1); }
}
.rest-floating-cart-bounce {
    animation: restFloatingCartBounce 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@keyframes restFloatingCartBounce {
    0%   { transform: scale(1); }
    30%  { transform: scale(1.15); }
    50%  { transform: scale(0.95); }
    70%  { transform: scale(1.05); }
    100% { transform: scale(1); }
}
/* On desktop, move higher since no bottom nav */
@media (min-width: 768px) {
    .rest-floating-cart {
        bottom: 24px;
        right: 90px;
    }
}


/* ==========================================================
   SPINNER
   ========================================================== */
.rest-spinner-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: color-mix(in srgb, var(--rest-bg), transparent 15%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: var(--rest-z-modal);
}

.rest-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--rest-border-strong);
    border-top-color: var(--rest-accent);
    border-radius: 50%;
    animation: restSpin 0.7s linear infinite;
}

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


/* ==========================================================
   CART ITEM REMOVE
   ========================================================== */
.rest-cart-item-remove {
    color: var(--rest-text-muted);
    font-size: 0.75rem;
    text-decoration: none;
    transition: color var(--rest-transition);
}

.rest-cart-item-remove:hover {
    color: var(--rest-danger);
    text-decoration: none;
}

/* ==========================================================
   CART ITEM OBSERVATION
   ========================================================== */
.rest-cart-item-wrap {
    border-bottom: 1px solid var(--rest-border);
}
.rest-cart-item-wrap:last-child {
    border-bottom: none;
}
/* --- Cart item observation strip --- */
.rest-cart-obs-strip {
    padding: 0 16px 10px;
}
.rest-cart-obs-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--rest-overlay-subtle);
    border: 1px dashed var(--rest-border);
    border-radius: 20px;
    padding: 4px 12px;
    font-size: 0.72rem;
    color: var(--rest-text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: inherit;
}
.rest-cart-obs-btn i {
    font-size: 0.6rem;
    flex-shrink: 0;
}
.rest-cart-obs-btn:hover {
    border-color: var(--rest-accent);
    color: var(--rest-accent);
    background: rgba(var(--rest-accent-rgb, 0,0,0), 0.04);
}
.rest-cart-obs-edit {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--rest-overlay-subtle);
    border: 1.5px solid var(--rest-accent);
    border-radius: 20px;
    padding: 5px 12px;
}
.rest-cart-obs-icon {
    color: var(--rest-accent);
    font-size: 0.6rem;
    flex-shrink: 0;
}
.rest-cart-obs-input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    font-size: 0.75rem;
    color: var(--rest-text);
    font-family: inherit;
}
.rest-cart-obs-input::placeholder {
    color: var(--rest-text-muted);
    opacity: 0.7;
}

/* ==========================================================
   ADICIONALES SECTION (cart page)
   ========================================================== */
.rest-adicionales-section {
    padding: 16px 0;
    overflow: hidden;
}
.rest-adicionales-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--rest-text);
    margin: 0 0 10px;
    padding: 0 16px;
}
.rest-adicionales-title i {
    color: var(--rest-accent);
    margin-right: 6px;
    font-size: 0.75rem;
}
.rest-adicionales-scroll {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 4px 16px 8px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    scroll-snap-type: x proximity;
}
.rest-adicionales-scroll::-webkit-scrollbar {
    display: none;
}
.rest-adicional-chip {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--rest-surface);
    border: 1px solid var(--rest-border);
    border-radius: 12px;
    padding: 8px 12px;
    min-width: 190px;
    cursor: pointer;
    transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    flex-shrink: 0;
    scroll-snap-align: start;
}
.rest-adicional-chip:hover {
    border-color: var(--rest-accent);
    background: var(--rest-overlay-subtle);
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.rest-adicional-img-wrap {
    width: 52px;
    height: 52px;
    border-radius: 10px;
    overflow: hidden;
    flex-shrink: 0;
}
.rest-adicional-img-wrap .rest-default-product-img {
    background: var(--rest-overlay-medium);
    border-radius: 10px;
}
.rest-adicional-img {
    width: 52px;
    height: 52px;
    border-radius: 10px;
    object-fit: cover;
}
.rest-adicional-info {
    flex: 1;
    min-width: 0;
}
.rest-adicional-name {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--rest-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 2px;
}
.rest-adicional-price {
    font-size: 0.78rem;
    color: var(--rest-accent);
    font-weight: 700;
}
.rest-adicional-add {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--rest-accent);
    color: var(--rest-accent-text);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    flex-shrink: 0;
}
.rest-adicional-check {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--rest-success);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    flex-shrink: 0;
}


/* ==========================================================
   MESA EXIT BUTTON + DIALOG
   ========================================================== */
.rest-mesa-exit-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1.5px solid var(--main-text-color);
    background: transparent;
    color: var(--main-text-color);
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s ease;
    opacity: 0.6;
}
.rest-mesa-exit-btn:hover {
    background: rgba(220,53,69,0.15);
    border-color: #dc3545;
    color: #dc3545;
    opacity: 1;
}
.rest-bottom-nav-exit {
    color: #dc3545;
    opacity: 0.7;
}
.rest-bottom-nav-exit i {
    color: #dc3545;
}
.rest-bottom-nav-exit:active {
    opacity: 1;
}
.rest-exit-mesa-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: restFadeIn 0.2s ease;
}
.rest-exit-mesa-dialog {
    background: var(--rest-surface, #fff);
    border-radius: 16px;
    padding: 28px 24px 20px;
    max-width: 320px;
    width: 100%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}
.rest-exit-mesa-icon {
    width: 52px;
    height: 52px;
    margin: 0 auto 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(220,53,69,0.1);
    color: #dc3545;
    font-size: 1.2rem;
}
.rest-exit-mesa-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--rest-text);
    margin: 0 0 6px;
}
.rest-exit-mesa-text {
    font-size: 0.78rem;
    color: var(--rest-text-muted);
    margin: 0 0 20px;
    line-height: 1.4;
}
.rest-exit-mesa-actions {
    display: flex;
    gap: 10px;
}
.rest-exit-mesa-cancel {
    flex: 1;
    padding: 10px;
    border: 1.5px solid var(--rest-border);
    border-radius: 10px;
    background: transparent;
    color: var(--rest-text);
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
    font-family: inherit;
}
.rest-exit-mesa-cancel:hover {
    background: var(--rest-overlay-subtle);
}
.rest-exit-mesa-confirm {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 10px;
    background: #dc3545;
    color: #fff;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-family: inherit;
}
.rest-exit-mesa-confirm:hover {
    background: #c82333;
}
.rest-exit-mesa-confirm i {
    font-size: 0.72rem;
}

/* ==========================================================
   QTY SELECTOR (modal)
   ========================================================== */
.rest-qty-selector {
    display: flex;
    align-items: center;
    gap: 0;
    background: var(--rest-surface);
    border-radius: var(--rest-radius-btn);
    border: 1px solid var(--rest-border-medium);
    overflow: hidden;
}

.rest-qty-selector button {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    color: var(--rest-text);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background var(--rest-transition);
}

.rest-qty-selector button:hover {
    background: var(--rest-surface-light);
}

.rest-qty-selector input {
    width: 36px;
    text-align: center;
    border: none;
    background: transparent;
    color: var(--rest-text);
    font-weight: 700;
    font-size: 0.9rem;
    font-family: inherit;
}


/* ==========================================================
   32. PRINT STYLES
   ========================================================== */
@media print {
    .rest-header,
    .rest-bottom-nav,
    .rest-cart-summary,
    .rest-detail-actions,
    .rest-btn-add,
    .rest-btn-checkout,
    .rest-btn-confirm,
    .rest-search-bar {
        display: none !important;
    }

    .rest-body {
        padding: 0;
        background: #fff;
        color: #000;
    }

    .rest-product-card,
    .rest-order-card,
    .rest-cart-item {
        box-shadow: none;
        border: 1px solid #ddd;
        background: #fff;
        color: #000;
    }
}


/* ==========================================================
   33. ADMIN COLOR EDITOR
   ========================================================== */
.rest-admin-fab {
    position: fixed;
    bottom: 90px;
    right: 24px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--rest-accent), color-mix(in srgb, var(--rest-accent), #000 20%));
    color: var(--rest-accent-text);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    cursor: pointer;
    z-index: calc(var(--rest-z-overlay) + 1);
    box-shadow: 0 4px 16px rgba(var(--rest-accent-rgb), 0.35);
    transition: transform var(--rest-transition), box-shadow var(--rest-transition);
}
.rest-admin-fab:hover {
    transform: scale(1.08);
    box-shadow: 0 6px 24px rgba(var(--rest-accent-rgb), 0.45);
}

.rest-admin-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: calc(var(--rest-z-overlay) + 2);
    backdrop-filter: blur(2px);
}

.rest-admin-panel {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: min(380px, 92vw);
    max-height: 85vh;
    background: var(--rest-surface);
    border: 1px solid var(--rest-border-medium);
    border-radius: var(--rest-radius-card);
    z-index: calc(var(--rest-z-overlay) + 3);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: var(--rest-shadow-lg);
    animation: restPanelIn 0.25s ease;
}
@keyframes restPanelIn {
    from { opacity: 0; transform: translate(-50%, -48%); }
    to { opacity: 1; transform: translate(-50%, -50%); }
}

.rest-admin-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--rest-border);
}

.rest-admin-panel-body {
    padding: 16px 20px;
    overflow-y: auto;
    flex: 1;
}

.rest-color-preview-bar {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    padding: 10px 12px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: var(--rest-radius-sm);
}
.rest-color-swatch {
    flex: 1;
    height: 28px;
    border-radius: 6px;
    border: 1px solid var(--rest-border-strong);
    transition: background var(--rest-transition);
}

.rest-color-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid var(--rest-border-light);
}
.rest-color-row:last-child {
    border-bottom: none;
}
.rest-color-row label {
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--rest-text);
    margin: 0;
    display: flex;
    align-items: center;
}

.rest-color-input-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
}
.rest-color-input-wrap input[type="color"] {
    -webkit-appearance: none;
    appearance: none;
    width: 32px;
    height: 32px;
    border: 2px solid var(--rest-border-strong);
    border-radius: 8px;
    cursor: pointer;
    padding: 2px;
    background: transparent;
}
.rest-color-input-wrap input[type="color"]::-webkit-color-swatch-wrapper {
    padding: 0;
}
.rest-color-input-wrap input[type="color"]::-webkit-color-swatch {
    border: none;
    border-radius: 5px;
}
.rest-color-hex {
    font-size: 0.7rem;
    font-family: 'Courier New', monospace;
    color: var(--rest-text-muted);
    min-width: 58px;
    text-transform: uppercase;
}

.rest-admin-panel-footer {
    padding: 12px 20px 16px;
    border-top: 1px solid var(--rest-border);
}
.rest-admin-btn-save {
    width: 100%;
    padding: 10px 16px;
    border: none;
    border-radius: var(--rest-radius-btn);
    background: var(--rest-accent);
    color: var(--rest-accent-text);
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all var(--rest-transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}
.rest-admin-btn-save:hover {
    box-shadow: 0 4px 16px rgba(var(--rest-accent-rgb), 0.35);
}
.rest-admin-btn-save:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

@media (max-width: 575.98px) {
    .rest-admin-fab {
        bottom: calc(var(--rest-bottom-nav-h) + 16px);
        right: 16px;
        width: 42px;
        height: 42px;
        font-size: 1rem;
    }
}


/* ==========================================================
   34. REDUCED MOTION
   ========================================================== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ==========================================================
   MESA (TABLE ORDERING) STYLES
   ========================================================== */
.rest-mesa-account {
    background: var(--rest-surface);
    border: 1px solid var(--rest-border);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 16px;
}
.rest-mesa-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid var(--rest-border-light);
    gap: 12px;
}
.rest-mesa-item:last-of-type {
    border-bottom: none;
}
.rest-mesa-total {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 14px;
    margin-top: 8px;
    border-top: 2px solid var(--rest-border-medium);
}
.rest-mesa-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 12px;
}
.rest-btn-mesa-bill {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 14px 20px;
    border: 2px solid var(--rest-accent);
    background: transparent;
    color: var(--rest-accent);
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}
.rest-btn-mesa-bill:hover {
    background: var(--rest-accent);
    color: #fff;
}
.rest-btn-mesa-bill:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}
.rest-btn-mesa-add {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 14px 20px;
    background: var(--rest-accent);
    color: #fff;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.2s;
}
.rest-btn-mesa-add:hover {
    opacity: 0.9;
    color: #fff;
    text-decoration: none;
}
.rest-btn-mesa-cart {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 12px 20px;
    background: var(--rest-surface-light);
    color: var(--rest-text);
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
}
.rest-btn-mesa-cart:hover {
    background: var(--rest-overlay-hover);
    color: var(--rest-text);
    text-decoration: none;
}
.rest-mesa-bill-requested {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px 20px;
    background: rgba(39, 174, 96, 0.12);
    color: #27ae60;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 700;
    animation: rest-pulse-badge 2s infinite;
}
.rest-mesa-success {
    background: rgba(39, 174, 96, 0.12);
    color: #27ae60;
    text-align: center;
    padding: 12px 16px;
    font-weight: 600;
    font-size: 0.85rem;
    border-radius: 12px;
    margin: 0 16px 12px;
}
.rest-btn-mesa-order {
    background: var(--rest-accent) !important;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}
.rest-btn-mesa-order:hover {
    opacity: 0.9;
}
