/*
 * GoRiders Santiago — Mobile-First Design System
 * ================================================
 * Esquema: Negro absoluto + Plateado metálico + Dorado (#E8D44D)
 * Optimizado para 90% uso móvil
 */

/* ─── GOOGLE FONTS ──────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

/* ─── CSS VARIABLES ─────────────────────────────────── */
:root {
    /* Colores principales */
    --black: #000000;
    --black-soft: #0A0A0A;
    --black-card: #0D0D0D;
    --black-elevated: #111111;
    --black-input: #141414;

    /* Bordes y separadores */
    --border: #1A1A1A;
    --border-light: #222222;
    --border-focus: #333333;

    /* Texto */
    --text-primary: #E5E7EB;
    --text-secondary: #9CA3AF;
    --text-muted: #6B7280;
    --text-disabled: #4B5563;

    /* Acento — Dorado del logo */
    --gold: #E8D44D;
    --gold-hover: #D4C044;
    --gold-muted: rgba(232, 212, 77, 0.15);
    --gold-glow: rgba(232, 212, 77, 0.25);

    /* Silver / Metálico */
    --silver: #C8CDD3;
    --silver-bright: #E0E4E8;

    /* Estados */
    --success: #22C55E;
    --success-bg: rgba(34, 197, 94, 0.1);
    --warning: #EAB308;
    --warning-bg: rgba(234, 179, 8, 0.1);
    --error: #EF4444;
    --error-bg: rgba(239, 68, 68, 0.1);
    --info: #3B82F6;
    --info-bg: rgba(59, 130, 246, 0.1);

    /* Layout */
    --top-bar-h: 56px;
    --bottom-nav-h: 64px;
    --safe-bottom: env(safe-area-inset-bottom, 0px);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.5);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.6);
    --shadow-lg: 0 8px 30px rgba(0,0,0,0.7);
    --shadow-gold: 0 0 20px rgba(232,212,77,0.15);

    /* Transitions */
    --ease: cubic-bezier(0.4, 0, 0.2, 1);
    --duration: 0.3s;
}

/* ─── RESET ─────────────────────────────────────────── */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

/* ─── SVG ICONS ─────────────────────────────────────── */
.ic {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    fill: none;
    stroke: currentColor;
    vertical-align: middle;
    display: inline-block;
}
.ic-sm { width: 16px; height: 16px; }
.ic-lg { width: 28px; height: 28px; }
.ic-xl { width: 40px; height: 40px; }
/* Icons that use `fill:currentColor` (WhatsApp) */
.ic use { pointer-events: none; }

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--black);
    color: var(--text-primary);
    line-height: 1.5;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
    min-height: 100vh;
    min-height: 100dvh;
}

/* Custom scrollbar */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--black); }
::-webkit-scrollbar-thumb { background: var(--border-light); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--border-focus); }

/* ─── TYPOGRAPHY ────────────────────────────────────── */
h1 { font-size: 1.75rem; font-weight: 800; letter-spacing: -0.02em; }
h2 { font-size: 1.375rem; font-weight: 700; letter-spacing: -0.01em; }
h3 { font-size: 1.125rem; font-weight: 600; }
h4 { font-size: 1rem; font-weight: 600; }
p { color: var(--text-secondary); }

.text-gold { color: var(--gold); }
.text-silver { color: var(--silver); }
.text-muted { color: var(--text-muted); }
.text-success { color: var(--success); }
.text-error { color: var(--error); }
.text-center { text-align: center; }
.text-sm { font-size: 0.8125rem; }
.text-xs { font-size: 0.75rem; }

a {
    color: var(--gold);
    text-decoration: none;
    transition: opacity var(--duration) var(--ease);
}
a:active { opacity: 0.7; }

/* ─── APP SHELL ─────────────────────────────────────── */
#app {
    width: 100%;
    min-height: 100vh;
    min-height: 100dvh;
    position: relative;
}

.view {
    display: none;
    width: 100%;
    min-height: 100vh;
    min-height: 100dvh;
}
.view.active {
    display: flex;
    flex-direction: column;
}

/* ─── LOGIN SCREEN ──────────────────────────────────── */
.login-screen {
    background: var(--black);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem 1.5rem;
    position: relative;
    overflow: hidden;
}

.login-screen::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(ellipse at center, rgba(232,212,77,0.04) 0%, transparent 50%);
    animation: loginPulse 8s ease-in-out infinite;
}

@keyframes loginPulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.1); opacity: 1; }
}

.login-logo {
    position: relative;
    z-index: 1;
    margin-bottom: 0.5rem;
    display: flex;
    justify-content: center;
}

.login-logo img {
    height: 140px;
    max-width: 80vw;
    object-fit: contain;
    filter: drop-shadow(0 0 30px rgba(232,212,77,0.3));
    animation: logoFloat 4s ease-in-out infinite;
}

@keyframes logoFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.login-title {
    position: relative;
    z-index: 1;
    color: var(--silver-bright);
    font-size: 2rem;
    font-weight: 900;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 0.25rem;
}

.login-subtitle {
    position: relative;
    z-index: 1;
    color: var(--silver-bright);
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    margin-top: 0.5rem;
    margin-bottom: 0.25rem;
}

.login-tagline {
    position: relative;
    z-index: 1;
    color: var(--gold);
    font-size: 0.8125rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 2.5rem;
    opacity: 0.8;
}

/* Google Sign-In Button */
.btn-google {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.9rem 2rem;
    background: #FFFFFF;
    color: #1F1F1F;
    border: none;
    border-radius: var(--radius-full);
    font-family: 'Inter', sans-serif;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--duration) var(--ease);
    box-shadow: var(--shadow-md);
    min-height: 52px;
    width: 100%;
    max-width: 320px;
    justify-content: center;
}

.btn-google:active {
    transform: scale(0.97);
    box-shadow: var(--shadow-sm);
}

.btn-google svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.login-footer {
    position: absolute;
    bottom: 2rem;
    left: 0;
    right: 0;
    text-align: center;
    color: var(--text-disabled);
    font-size: 0.6875rem;
    z-index: 1;
}

/* ─── PHONE REGISTRATION MODAL ──────────────────────── */
.register-screen {
    background: var(--black);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem 1.5rem;
}

.register-card {
    width: 100%;
    max-width: 400px;
    background: var(--black-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 2rem 1.5rem;
    text-align: center;
}

.register-card .icon-circle {
    width: 64px;
    height: 64px;
    background: var(--gold-muted);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.25rem;
    color: var(--gold);
}

.register-card h2 {
    color: var(--silver-bright);
    margin-bottom: 0.5rem;
}

.register-card p {
    font-size: 0.875rem;
    margin-bottom: 1.5rem;
}

/* ─── TOP BAR ───────────────────────────────────────── */
.top-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--top-bar-h);
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    padding: 0 1rem;
    z-index: 100;
}

.top-bar-logo {
    height: 36px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 0 8px rgba(232,212,77,0.2));
}

.top-bar-title {
    flex: 1;
    text-align: center;
    font-size: 1rem;
    font-weight: 700;
    color: var(--silver-bright);
    letter-spacing: 0.02em;
}

.top-bar-action {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: var(--black-elevated);
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.125rem;
    transition: all var(--duration) var(--ease);
}

.top-bar-action:active { background: var(--border); }

/* ─── BOTTOM NAVIGATION ────────────────────────────── */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: calc(var(--bottom-nav-h) + var(--safe-bottom));
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--border);
    display: flex;
    align-items: flex-start;
    padding-top: 6px;
    padding-bottom: var(--safe-bottom);
    z-index: 100;
}

.nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 6px 0;
    color: var(--text-muted);
    font-size: 0.625rem;
    font-weight: 500;
    cursor: pointer;
    transition: color var(--duration) var(--ease);
    border: none;
    background: none;
    -webkit-tap-highlight-color: transparent;
    position: relative;
}

.nav-item .nav-icon {
    width: 22px;
    height: 22px;
    line-height: 1;
    transition: transform var(--duration) var(--ease);
}

.nav-item.active {
    color: var(--gold);
}

.nav-item.active .nav-icon {
    transform: scale(1.1);
}

.nav-item .badge {
    position: absolute;
    top: 2px;
    right: calc(50% - 16px);
    width: 8px;
    height: 8px;
    background: var(--error);
    border-radius: 50%;
    border: 2px solid var(--black);
}

/* ─── MAIN CONTENT AREA ────────────────────────────── */
.app-shell {
    flex-direction: column;
}

.main-content {
    flex: 1;
    padding-top: var(--top-bar-h);
    padding-bottom: calc(var(--bottom-nav-h) + var(--safe-bottom));
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.view-panel {
    display: none;
    padding: 1rem;
    min-height: calc(100vh - var(--top-bar-h) - var(--bottom-nav-h));
    min-height: calc(100dvh - var(--top-bar-h) - var(--bottom-nav-h));
    animation: fadeIn 0.25s var(--ease);
}

.view-panel.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ─── CARDS ─────────────────────────────────────────── */
.card {
    background: var(--black-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    margin-bottom: 0.75rem;
    transition: border-color var(--duration) var(--ease);
}

.card:active { border-color: var(--border-light); }

.card-glass {
    background: linear-gradient(135deg, rgba(255,255,255,0.03) 0%, rgba(255,255,255,0.01) 100%);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.06);
}

.card-gold {
    border: 1px solid rgba(232,212,77,0.2);
    background: linear-gradient(135deg, rgba(232,212,77,0.05) 0%, transparent 100%);
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.card-label {
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
}

/* ─── BUTTONS ───────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    font-family: 'Inter', sans-serif;
    font-size: 0.875rem;
    font-weight: 600;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--duration) var(--ease);
    min-height: 48px;
    width: 100%;
    text-decoration: none;
}

.btn:active { transform: scale(0.97); }
.btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none !important;
}

.btn-primary {
    background: var(--gold);
    color: #000;
    box-shadow: var(--shadow-gold);
}
.btn-primary:active { background: var(--gold-hover); }

.btn-secondary {
    background: var(--black-elevated);
    color: var(--text-primary);
    border: 1px solid var(--border-light);
}
.btn-secondary:active { background: var(--border); }

.btn-outline {
    background: transparent;
    color: var(--gold);
    border: 1px solid rgba(232,212,77,0.3);
}
.btn-outline:active { background: var(--gold-muted); }

.btn-danger {
    background: var(--error-bg);
    color: var(--error);
    border: 1px solid rgba(239,68,68,0.2);
}
.btn-danger:active { background: rgba(239,68,68,0.2); }

.btn-success {
    background: var(--success);
    color: #000;
}
.btn-success:active { background: #16A34A; }

.btn-whatsapp {
    background: #25D366;
    color: #FFF;
}
.btn-whatsapp:active { background: #1DA851; }

.btn-sm {
    min-height: 40px;
    padding: 0.5rem 1rem;
    font-size: 0.8125rem;
}

.btn-icon {
    width: 44px;
    height: 44px;
    min-height: 44px;
    padding: 0;
    border-radius: 50%;
}

.btn-row {
    display: flex;
    gap: 0.5rem;
}
.btn-row .btn { flex: 1; }

/* ─── FORMS ─────────────────────────────────────────── */
.form-group {
    margin-bottom: 1rem;
}

.form-label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.4rem;
}

.form-input {
    width: 100%;
    padding: 0.8rem 1rem;
    background: var(--black-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    min-height: 48px;
    transition: border-color var(--duration) var(--ease);
    -webkit-appearance: none;
    appearance: none;
}

.form-input:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 0 3px var(--gold-muted);
}

.form-input::placeholder {
    color: var(--text-disabled);
}

textarea.form-input {
    resize: vertical;
    min-height: 80px;
    line-height: 1.5;
}

select.form-input {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%236B7280' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10l-5 5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

.form-hint {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.3rem;
}

.input-phone {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.input-phone .country-code {
    flex-shrink: 0;
    width: 80px;
    text-align: center;
    font-weight: 600;
    color: var(--gold);
    background: var(--gold-muted);
    border-color: rgba(232,212,77,0.2);
}

.input-phone .form-input {
    flex: 1;
}

/* ─── STATUS BADGES ─────────────────────────────────── */
.badge-status {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.25rem 0.6rem;
    border-radius: var(--radius-full);
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.badge-pending { background: var(--warning-bg); color: var(--warning); border: 1px solid rgba(234,179,8,0.2); }
.badge-assigning { background: var(--info-bg); color: var(--info); border: 1px solid rgba(59,130,246,0.2); }
.badge-assigned { background: var(--info-bg); color: var(--info); border: 1px solid rgba(59,130,246,0.2); }
.badge-accepted { background: var(--success-bg); color: var(--success); border: 1px solid rgba(34,197,94,0.2); }
.badge-in_progress { background: rgba(168,85,247,0.1); color: #A855F7; border: 1px solid rgba(168,85,247,0.2); }
.badge-delivered { background: var(--success-bg); color: var(--success); border: 1px solid rgba(34,197,94,0.2); }
.badge-cancelled { background: var(--error-bg); color: var(--error); border: 1px solid rgba(239,68,68,0.2); }

/* ─── ORDER CARDS ───────────────────────────────────── */
.order-card {
    cursor: pointer;
}

.order-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.order-restaurant {
    font-weight: 700;
    font-size: 1rem;
    color: var(--text-primary);
}

.order-id {
    font-size: 0.6875rem;
    color: var(--text-muted);
    font-weight: 500;
}

.order-items {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    line-height: 1.4;
    margin-bottom: 0.75rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.order-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.order-meta .amount {
    font-weight: 700;
    color: var(--gold);
    font-size: 0.875rem;
}

/* ─── ORDER DETAIL ──────────────────────────────────── */
.detail-header {
    text-align: center;
    padding: 1rem 0 1.5rem;
}

.detail-header .order-number {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.detail-header .restaurant {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--silver-bright);
    margin-bottom: 0.5rem;
}

.info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border);
}

.info-row:last-child { border: none; }

.info-row .label {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.info-row .value {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
    text-align: right;
}

.info-row .value.gold {
    color: var(--gold);
    font-size: 1rem;
}

/* ─── YAPPY PAYMENT CARD ───────────────────────────── */
.yappy-card {
    border: 1px solid rgba(232,212,77,0.2);
    background: linear-gradient(145deg, rgba(232,212,77,0.06) 0%, transparent 100%);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    margin-bottom: 0.75rem;
}

.yappy-card .yappy-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.yappy-card .yappy-type {
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--gold);
}

.yappy-card .yappy-name {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.15rem;
}

.yappy-card .yappy-number {
    font-size: 1.375rem;
    font-weight: 800;
    color: var(--gold);
    letter-spacing: 0.05em;
    font-variant-numeric: tabular-nums;
}

.yappy-amount {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(232,212,77,0.15);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.yappy-amount .label { font-size: 0.8125rem; color: var(--text-muted); }
.yappy-amount .amount { font-size: 1.25rem; font-weight: 800; color: var(--gold); }

/* ─── CHAT ──────────────────────────────────────────── */
.chat-container {
    display: flex;
    flex-direction: column;
    height: calc(100vh - var(--top-bar-h) - var(--bottom-nav-h));
    height: calc(100dvh - var(--top-bar-h) - var(--bottom-nav-h));
    padding: 0;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.chat-bubble {
    max-width: 82%;
    padding: 0.7rem 1rem;
    border-radius: var(--radius-lg);
    font-size: 0.875rem;
    line-height: 1.45;
    position: relative;
    word-wrap: break-word;
    animation: bubbleIn 0.2s var(--ease);
}

@keyframes bubbleIn {
    from { opacity: 0; transform: translateY(6px) scale(0.97); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.chat-bubble.sent {
    background: var(--gold);
    color: #000;
    align-self: flex-end;
    border-bottom-right-radius: 4px;
}

.chat-bubble.received {
    background: var(--black-elevated);
    color: var(--text-primary);
    border: 1px solid var(--border);
    align-self: flex-start;
    border-bottom-left-radius: 4px;
}

.chat-bubble.system {
    background: var(--gold-muted);
    border: 1px solid rgba(232,212,77,0.15);
    color: var(--text-secondary);
    align-self: center;
    text-align: center;
    font-size: 0.75rem;
    max-width: 90%;
}

.chat-bubble .time {
    font-size: 0.625rem;
    margin-top: 0.3rem;
    opacity: 0.6;
}

.chat-bubble.sent .time { color: rgba(0,0,0,0.5); text-align: right; }
.chat-bubble.received .time { color: var(--text-muted); }

.chat-bubble .attachment-img {
    width: 100%;
    max-width: 250px;
    border-radius: var(--radius-sm);
    margin-bottom: 0.3rem;
    cursor: pointer;
}

.chat-input-area {
    padding: 0.5rem 0.75rem;
    padding-bottom: calc(0.5rem + var(--safe-bottom));
    background: var(--black-soft);
    border-top: 1px solid var(--border);
    display: flex;
    align-items: flex-end;
    gap: 0.5rem;
}

.chat-input-area .form-input {
    flex: 1;
    min-height: 42px;
    max-height: 120px;
    padding: 0.6rem 0.8rem;
    resize: none;
    border-radius: var(--radius-xl);
    font-size: 0.9375rem;
}

.chat-input-area .btn-icon {
    width: 42px;
    height: 42px;
    min-height: 42px;
    flex-shrink: 0;
}

.chat-input-area .btn-send {
    background: var(--gold);
    color: #000;
}

.chat-input-area .btn-attach {
    background: var(--black-elevated);
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

/* ─── RIDER CARD (in order detail) ──────────────────── */
.rider-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: var(--black-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    margin-bottom: 0.75rem;
}

.rider-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--gold-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
    color: var(--gold);
    font-weight: 700;
}

.rider-info { flex: 1; }
.rider-info .name { font-weight: 700; font-size: 0.9375rem; }
.rider-info .phone { font-size: 0.8125rem; color: var(--text-muted); }

/* ─── PROFILE ───────────────────────────────────────── */
.profile-header {
    text-align: center;
    padding: 1.5rem 0;
}

.profile-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 3px solid var(--gold);
    margin: 0 auto 1rem;
    overflow: hidden;
    box-shadow: 0 0 25px rgba(232,212,77,0.15);
}

.profile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--silver-bright);
}

.profile-email {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.menu-list {
    margin-top: 1rem;
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    transition: background var(--duration) var(--ease);
}

.menu-item:active { background: var(--black-elevated); }

.menu-item .icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.125rem;
    background: var(--black-elevated);
}

.menu-item .label { flex: 1; font-weight: 500; font-size: 0.9375rem; }
.menu-item .arrow { color: var(--text-muted); font-size: 0.875rem; }

/* ─── HOME HERO ─────────────────────────────────────── */
.home-hero {
    text-align: center;
    padding: 1.5rem 0;
}

.home-hero .greeting {
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: 0.25rem;
}

.home-hero .user-name {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--silver-bright);
}

.home-hero .region-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    margin-top: 0.5rem;
    padding: 0.3rem 0.75rem;
    background: var(--gold-muted);
    color: var(--gold);
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 600;
}

/* ─── NEW ORDER SECTION ─────────────────────────────── */
.new-order-btn {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem;
    background: linear-gradient(135deg, rgba(232,212,77,0.08) 0%, rgba(232,212,77,0.02) 100%);
    border: 1px solid rgba(232,212,77,0.2);
    border-radius: var(--radius-xl);
    cursor: pointer;
    transition: all var(--duration) var(--ease);
    width: 100%;
    margin-bottom: 1.5rem;
}

.new-order-btn:active {
    transform: scale(0.98);
    background: rgba(232,212,77,0.12);
}

.new-order-btn .icon-box {
    width: 52px;
    height: 52px;
    background: var(--gold);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.new-order-btn .text h3 {
    color: var(--silver-bright);
    font-size: 1rem;
    text-align: left;
}

.new-order-btn .text p {
    font-size: 0.8125rem;
    color: var(--text-muted);
    text-align: left;
}

/* ─── SECTION TITLE ─────────────────────────────────── */
.section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.section-title h3 {
    color: var(--text-secondary);
    font-size: 0.8125rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.section-title .see-all {
    font-size: 0.8125rem;
    color: var(--gold);
    font-weight: 500;
}

/* ─── MODAL / OVERLAY ───────────────────────────────── */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 200;
    display: none;
    align-items: flex-end;
    justify-content: center;
    animation: overlayIn 0.2s var(--ease);
}

.modal-overlay.active { display: flex; }

@keyframes overlayIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-sheet {
    width: 100%;
    max-width: 500px;
    max-height: 92vh;
    max-height: 92dvh;
    background: var(--black-soft);
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    padding: 1.5rem;
    overflow-y: auto;
    animation: sheetUp 0.35s var(--ease);
}

@keyframes sheetUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

.modal-sheet .handle {
    width: 36px;
    height: 4px;
    background: var(--border-light);
    border-radius: 2px;
    margin: 0 auto 1.25rem;
}

.modal-sheet h2 {
    text-align: center;
    margin-bottom: 1.5rem;
    color: var(--silver-bright);
}

/* ─── IMAGE VIEWER ──────────────────────────────────── */
.image-viewer {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.95);
    z-index: 300;
    display: none;
    align-items: center;
    justify-content: center;
}

.image-viewer.active { display: flex; }

.image-viewer img {
    max-width: 95%;
    max-height: 90vh;
    border-radius: var(--radius-sm);
}

.image-viewer .close-btn {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: rgba(255,255,255,0.1);
    color: #fff;
    font-size: 1.25rem;
    cursor: pointer;
}

/* ─── LOADING / EMPTY STATES ────────────────────────── */
.spinner {
    width: 36px;
    height: 36px;
    border: 3px solid var(--border);
    border-top-color: var(--gold);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 2rem auto;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.8);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 500;
    flex-direction: column;
    gap: 1rem;
}

.loading-overlay.active { display: flex; }

.loading-overlay .spinner {
    width: 44px;
    height: 44px;
    border-width: 4px;
}

.loading-overlay p {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.empty-state {
    text-align: center;
    padding: 3rem 1rem;
}

.empty-state .icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.empty-state h3 {
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.empty-state p {
    font-size: 0.8125rem;
    color: var(--text-muted);
    max-width: 280px;
    margin: 0 auto;
}

/* ─── TOAST NOTIFICATIONS ───────────────────────────── */
.toast-container {
    position: fixed;
    top: calc(var(--top-bar-h) + 0.5rem);
    left: 0.75rem;
    right: 0.75rem;
    z-index: 400;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    pointer-events: none;
}

.toast {
    padding: 0.8rem 1rem;
    border-radius: var(--radius-md);
    font-size: 0.8125rem;
    font-weight: 500;
    animation: toastIn 0.3s var(--ease);
    pointer-events: auto;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: var(--shadow-lg);
}

.toast.success { background: #16A34A; color: #FFF; }
.toast.error { background: #DC2626; color: #FFF; }
.toast.info { background: #2563EB; color: #FFF; }
.toast.warning { background: #D97706; color: #FFF; }

@keyframes toastIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.toast.removing {
    animation: toastOut 0.3s var(--ease) forwards;
}

@keyframes toastOut {
    to { opacity: 0; transform: translateY(-10px); }
}

/* ─── UPLOAD AREA ───────────────────────────────────── */
.upload-area {
    border: 2px dashed var(--border-light);
    border-radius: var(--radius-lg);
    padding: 2rem 1rem;
    text-align: center;
    cursor: pointer;
    transition: all var(--duration) var(--ease);
}

.upload-area:active {
    border-color: var(--gold);
    background: var(--gold-muted);
}

.upload-area.has-file {
    border-color: var(--success);
    border-style: solid;
    background: var(--success-bg);
}

.upload-area .icon { font-size: 2rem; margin-bottom: 0.5rem; }
.upload-area p { font-size: 0.8125rem; color: var(--text-muted); }
.upload-area .filename {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--success);
    margin-top: 0.3rem;
}

.upload-preview {
    margin-top: 0.5rem;
    border-radius: var(--radius-sm);
    max-width: 200px;
    max-height: 150px;
    object-fit: cover;
}

/* ─── STEP INDICATOR ────────────────────────────────── */
.steps {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.step-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--border-light);
    transition: all var(--duration) var(--ease);
}

.step-dot.active {
    width: 24px;
    border-radius: 4px;
    background: var(--gold);
}

.step-dot.completed {
    background: var(--success);
}

/* ─── SUPPORT CHAT WIDGET ───────────────────────────── */
.support-fab {
    position: fixed;
    bottom: calc(var(--bottom-nav-h) + var(--safe-bottom) + 1rem);
    right: 1rem;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: var(--gold);
    color: #000;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: var(--shadow-gold), var(--shadow-lg);
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform var(--duration) var(--ease);
}

.support-fab:active { transform: scale(0.9); }

/* ─── RIDER DASHBOARD SPECIFIC ──────────────────────── */
.rider-page {
    min-height: 100vh;
    min-height: 100dvh;
    background: var(--black);
    padding: 1rem;
}

.rider-page .top-logo {
    text-align: center;
    padding: 1rem 0;
}

.rider-page .top-logo img {
    height: 40px;
    filter: drop-shadow(0 0 15px rgba(232,212,77,0.2));
}

.status-timeline {
    margin: 1rem 0;
}

.timeline-step {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding-bottom: 1.25rem;
    position: relative;
}

.timeline-step::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 32px;
    bottom: 0;
    width: 2px;
    background: var(--border);
}

.timeline-step:last-child::before { display: none; }

.timeline-step .dot {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 0.875rem;
    background: var(--black-elevated);
    border: 2px solid var(--border);
}

.timeline-step.completed .dot {
    background: var(--success-bg);
    border-color: var(--success);
    color: var(--success);
}

.timeline-step.active .dot {
    background: var(--gold-muted);
    border-color: var(--gold);
    color: var(--gold);
    animation: dotPulse 2s ease-in-out infinite;
}

@keyframes dotPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(232,212,77,0.3); }
    50% { box-shadow: 0 0 0 8px rgba(232,212,77,0); }
}

.timeline-step .step-text { padding-top: 4px; }
.timeline-step .step-text .title { font-weight: 600; font-size: 0.9375rem; }
.timeline-step .step-text .desc { font-size: 0.8125rem; color: var(--text-muted); }

/* ─── ADMIN SPECIFIC ────────────────────────────────── */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.stat-card {
    background: var(--black-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1rem;
}

.stat-card .stat-value {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--silver-bright);
    margin-bottom: 0.15rem;
}

.stat-card .stat-label {
    font-size: 0.6875rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.stat-card.gold { border-color: rgba(232,212,77,0.2); }
.stat-card.gold .stat-value { color: var(--gold); }

/* ─── TABS ──────────────────────────────────────────── */
.tabs {
    display: flex;
    gap: 2px;
    background: var(--black-soft);
    padding: 3px;
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
}

.tab {
    flex: 1;
    padding: 0.6rem;
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-family: 'Inter', sans-serif;
    font-size: 0.8125rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--duration) var(--ease);
}

.tab.active {
    background: var(--black-elevated);
    color: var(--gold);
}

/* ─── UTILITIES ─────────────────────────────────────── */
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.p-1 { padding: 0.5rem; }
.p-2 { padding: 1rem; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.hidden { display: none !important; }
.w-full { width: 100%; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.divider { height: 1px; background: var(--border); margin: 1rem 0; }
.separator { height: 8px; background: var(--black); margin: 0 -1rem; }

/* ─── COVERAGE MAP CARD ─────────────────────────────── */
.map-card {
    background: var(--black-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    overflow: hidden;
    margin: 1rem 0 1.25rem;
}

.map-card-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 1rem 1rem 0.75rem;
}

.map-card-head h3 {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--silver-bright);
    letter-spacing: 0.01em;
}

.map-card-head p {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.1rem;
}

.map-legend {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    align-items: flex-end;
    font-size: 0.6875rem;
    color: var(--text-muted);
}

.map-legend .legend-item {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    white-space: nowrap;
}

.map-legend .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 8px currentColor;
}

.map-legend .dot-gold { background: var(--gold); color: var(--gold); }
.map-legend .dot-silver { background: var(--silver); color: var(--silver); }
.map-legend .dot-client { background: #3B82F6; color: #3B82F6; }

.home-map {
    width: 100%;
    height: 260px;
    background: #050505;
    position: relative;
}

/* Force Leaflet dark look */
.home-map .leaflet-container {
    background: #050505;
    font-family: 'Inter', sans-serif;
}

.home-map .leaflet-control-zoom a {
    background: var(--black-elevated);
    color: var(--text-primary);
    border-color: var(--border-light);
}
.home-map .leaflet-control-zoom a:hover { background: var(--border); }

.home-map .leaflet-popup-content-wrapper,
.home-map .leaflet-popup-tip {
    background: var(--black-elevated);
    color: var(--text-primary);
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-lg);
}
.home-map .leaflet-popup-content {
    font-size: 0.8125rem;
    margin: 0.5rem 0.75rem;
}
.home-map .leaflet-popup-close-button { color: var(--text-muted); }

/* Custom map markers */
.map-marker { background: transparent !important; border: none !important; }

.map-pin {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: 2px solid #fff;
    box-shadow: 0 0 0 2px rgba(0,0,0,0.6), 0 2px 6px rgba(0,0,0,0.6);
    position: relative;
}
.map-pin-client {
    background: #3B82F6;
    animation: pinPulse 2s ease-out infinite;
}
.map-pin-rider {
    background: var(--silver);
    width: 14px;
    height: 14px;
    border-width: 2px;
}
.map-pin-rider::after {
    content: '';
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    border: 1px dashed rgba(200, 205, 211, 0.4);
    animation: pinRotate 6s linear infinite;
}
@keyframes pinPulse {
    0% { box-shadow: 0 0 0 0 rgba(59,130,246,0.6), 0 0 0 2px rgba(0,0,0,0.6); }
    100% { box-shadow: 0 0 0 14px rgba(59,130,246,0), 0 0 0 2px rgba(0,0,0,0.6); }
}
@keyframes pinRotate { to { transform: rotate(360deg); } }

.map-card-foot {
    padding: 0.75rem 1rem 1rem;
    display: flex;
    justify-content: center;
}
.map-card-foot .btn { width: auto; min-height: 38px; padding: 0.4rem 1rem; }

/* ─── RESTAURANT CATALOG GRID ───────────────────────── */
.rest-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.rest-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.6rem;
    padding: 1rem;
    background: var(--black-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: transform var(--duration) var(--ease), border-color var(--duration) var(--ease), background var(--duration) var(--ease);
    text-align: left;
    color: inherit;
    font-family: inherit;
    min-height: 130px;
    position: relative;
    overflow: hidden;
}

.rest-card:active {
    transform: scale(0.97);
    border-color: var(--border-focus);
    background: var(--black-elevated);
}

.rest-card-featured {
    grid-column: span 2;
    flex-direction: row;
    align-items: center;
    gap: 1rem;
    min-height: 80px;
    background: linear-gradient(135deg, rgba(232,212,77,0.08) 0%, rgba(232,212,77,0.02) 100%);
    border-color: rgba(232,212,77,0.25);
}
.rest-card-featured .rest-logo { margin-bottom: 0; }

.rest-logo {
    width: 52px;
    height: 52px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 1rem;
    letter-spacing: 0.02em;
    border: 1px solid rgba(255,255,255,0.06);
    color: #fff;
    overflow: hidden;
    flex-shrink: 0;
}
.rest-logo span { font-size: inherit; }
.rest-logo.custom {
    background: var(--gold-muted);
    color: var(--gold);
    border-color: rgba(232,212,77,0.3);
}
.rest-logo svg { width: 22px; height: 22px; }

.rest-info h4 {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.1rem;
}
.rest-info p {
    font-size: 0.75rem;
    color: var(--text-muted);
    line-height: 1.3;
}

.rest-card .rest-badge {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    padding: 0.15rem 0.5rem;
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    background: var(--gold-muted);
    color: var(--gold);
    border-radius: var(--radius-full);
}

/* ─── RESTAURANT MODAL (MENU) ───────────────────────── */
.modal-sheet.modal-lg {
    padding-bottom: 0;
    display: flex;
    flex-direction: column;
    max-height: 92vh;
    max-height: 92dvh;
    overflow: hidden;
}

.rest-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    flex-shrink: 0;
}
.rest-modal-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.rest-logo-xl {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 1.25rem;
    color: #fff;
    border: none;
    flex-shrink: 0;
}
.rest-logo-xl span { font-size: inherit; }

.rest-menu {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding-right: 0.25rem;
    padding-bottom: 0.5rem;
    min-height: 0;
}

.rest-menu-category {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    padding: 0.75rem 0 0.25rem;
}

/* ─── HORIZONTAL MENU ITEM CARD ─────────────────────── */
.menu-item-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 0.75rem;
    background: var(--black-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    transition: border-color 0.2s, background 0.2s;
}

.menu-item-card.has-items {
    border-color: rgba(232,212,77,0.35);
    background: linear-gradient(135deg, rgba(232,212,77,0.04) 0%, transparent 100%);
}

/* Food image / emoji */
.menu-item-card .item-img {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-sm);
    background: var(--black-elevated);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    flex-shrink: 0;
    line-height: 1;
}

.menu-item-card .item-info { flex: 1; min-width: 0; }
.menu-item-card .item-name {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.menu-item-card .item-desc {
    font-size: 0.6875rem;
    color: var(--text-muted);
    line-height: 1.3;
    -webkit-line-clamp: 1;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.menu-item-card .item-price {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--gold);
    margin-top: 0.15rem;
}

.qty-control {
    display: inline-flex;
    align-items: center;
    gap: 0.15rem;
    background: var(--black-elevated);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-full);
    padding: 0.15rem;
    flex-shrink: 0;
}

.qty-control button {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background var(--duration) var(--ease);
}
.qty-control button:active { background: var(--border); }
.qty-control button.qty-plus {
    background: var(--gold);
    color: #000;
}
.qty-control button.qty-plus:active { background: var(--gold-hover); }

.qty-control .qty-val {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--text-primary);
    min-width: 22px;
    text-align: center;
    font-variant-numeric: tabular-nums;
}

.rest-cart {
    flex-shrink: 0;
    background: var(--black-soft);
    border-top: 1px solid var(--border);
    padding: 0.75rem 0 calc(0.75rem + var(--safe-bottom));
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.rest-cart-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 0.75rem;
    background: var(--black-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
}

.rest-cart-summary .label {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.8125rem;
    color: var(--text-secondary);
    font-weight: 500;
}
.rest-cart-summary .amount {
    font-size: 1.125rem;
    font-weight: 800;
    color: var(--gold);
    font-variant-numeric: tabular-nums;
}

/* ─── RESPONSIVE (Tablet+) ──────────────────────────── */
@media (min-width: 768px) {
    .main-content {
        max-width: 500px;
        margin: 0 auto;
    }

    .modal-sheet {
        max-width: 420px;
        margin: auto;
        border-radius: var(--radius-xl);
        max-height: 85vh;
    }

    .bottom-nav {
        max-width: 500px;
        left: 50%;
        transform: translateX(-50%);
        border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    }

    .top-bar {
        max-width: 500px;
        left: 50%;
        transform: translateX(-50%);
    }

    .rest-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

