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

:root {
    --primary: #6366f1;
    --primary-light: #818cf8;
    --primary-dark: #4f46e5;
    --secondary: #8b5cf6;
    --accent: #f59e0b;
    --accent-light: #fbbf24;
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    --info: #3b82f6;
    --bg: #f8fafc;
    --bg-card: #ffffff;
    --bg-glass: rgba(255, 255, 255, 0.72);
    --bg-glass-dark: rgba(15, 23, 42, 0.75);
    --text: #0f172a;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --border: rgba(148, 163, 184, 0.2);
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.04), 0 1px 2px rgba(0,0,0,0.06);
    --shadow: 0 4px 20px rgba(0,0,0,0.06), 0 1px 3px rgba(0,0,0,0.04);
    --shadow-lg: 0 12px 40px rgba(0,0,0,0.08), 0 4px 12px rgba(0,0,0,0.04);
    --shadow-xl: 0 20px 60px rgba(0,0,0,0.1), 0 8px 20px rgba(0,0,0,0.06);
    --shadow-glow: 0 0 40px rgba(99,102,241,0.15);
    --radius: 20px;
    --radius-sm: 14px;
    --radius-lg: 28px;
    --radius-full: 9999px;
    --blur: blur(20px);
    --transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-fast: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-bounce: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    --font: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --gradient: linear-gradient(135deg, var(--primary), var(--secondary));
    --gradient-warm: linear-gradient(135deg, #f59e0b, #ef4444);
    --gradient-cool: linear-gradient(135deg, #06b6d4, #6366f1);
    --gradient-nature: linear-gradient(135deg, #10b981, #06b6d4);
}

[data-theme="dark"] {
    --bg: #0f172a;
    --bg-card: #1e293b;
    --bg-glass: rgba(30, 41, 59, 0.8);
    --text: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --border: rgba(148, 163, 184, 0.12);
    --shadow: 0 4px 20px rgba(0,0,0,0.2);
    --shadow-lg: 0 12px 40px rgba(0,0,0,0.3);
}

*, *::before, *::after {
    margin: 0; padding: 0; box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--text-muted); border-radius: 20px; }

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes slideInRight {
    from { opacity: 0; transform: translateX(40px); }
    to { opacity: 1; transform: translateX(0); }
}
@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-40px); }
    to { opacity: 1; transform: translateX(0); }
}
@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}
@keyframes pulse-soft {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}
@keyframes spin {
    to { transform: rotate(360deg); }
}
@keyframes cart-bounce {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.25); }
}
@keyframes slide-up-modal {
    from { opacity: 0; transform: translateY(100%); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes blob {
    0%, 100% { border-radius: 60% 40% 30% 70%/60% 30% 70% 40%; }
    50% { border-radius: 30% 60% 70% 40%/50% 60% 30% 60%; }
}

.animate-fade-up { animation: fadeInUp 0.6s ease-out both; }
.animate-fade-in { animation: fadeIn 0.5s ease-out both; }
.animate-slide-right { animation: slideInRight 0.6s ease-out both; }
.animate-slide-left { animation: slideInLeft 0.6s ease-out both; }
.animate-scale { animation: scaleIn 0.5s ease-out both; }
.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }
.delay-5 { animation-delay: 0.5s; }

/* ===== HEADER ===== */
.menu-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--bg-glass);
    backdrop-filter: var(--blur);
    -webkit-backdrop-filter: var(--blur);
    border-bottom: 1px solid var(--border);
    padding: 16px 20px;
    transition: var(--transition);
}

.menu-header.scrolled {
    padding: 10px 20px;
    box-shadow: var(--shadow);
}

.header-inner {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

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

.restaurant-logo {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-sm);
    background: var(--gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: white;
    font-weight: 800;
    box-shadow: 0 4px 15px rgba(99,102,241,0.3);
}

.restaurant-info h1 {
    font-size: 18px;
    font-weight: 800;
    letter-spacing: -0.3px;
    line-height: 1.2;
}

.restaurant-info p {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
}

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

.btn-icon {
    width: 42px;
    height: 42px;
    border-radius: var(--radius-sm);
    border: none;
    background: var(--bg-card);
    color: var(--text);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-fast);
    font-size: 18px;
    box-shadow: var(--shadow-sm);
    position: relative;
}

.btn-icon:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
    background: var(--primary);
    color: white;
}

.btn-icon .badge {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--danger);
    color: white;
    font-size: 11px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--bg);
}

.badge-animate {
    animation: cart-bounce 0.4s ease;
}

/* ===== TABLE INFO BAR ===== */
.table-bar {
    max-width: 600px;
    margin: 16px auto 0;
    padding: 0 20px;
}

.table-info {
    background: var(--gradient);
    border-radius: var(--radius);
    padding: 16px 20px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 8px 30px rgba(99,102,241,0.25);
    animation: fadeInUp 0.5s ease-out;
}

.table-info .table-label {
    font-size: 13px;
    opacity: 0.85;
    font-weight: 500;
}

.table-info .table-number {
    font-size: 22px;
    font-weight: 800;
}

.table-info .order-type {
    background: rgba(255,255,255,0.2);
    padding: 6px 14px;
    border-radius: var(--radius-full);
    font-size: 13px;
    font-weight: 600;
    backdrop-filter: blur(10px);
}

/* ===== CATEGORY TABS ===== */
.category-scroll {
    max-width: 600px;
    margin: 20px auto 0;
    padding: 0 20px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.category-scroll::-webkit-scrollbar { display: none; }

.category-tabs {
    display: flex;
    gap: 10px;
    padding-bottom: 4px;
}

.category-tab {
    flex-shrink: 0;
    padding: 10px 20px;
    border-radius: var(--radius-full);
    border: none;
    background: var(--bg-card);
    color: var(--text-secondary);
    font-family: var(--font);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-fast);
    white-space: nowrap;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: 6px;
}

.category-tab:hover {
    color: var(--primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.category-tab.active {
    background: var(--gradient);
    color: white;
    box-shadow: 0 4px 15px rgba(99,102,241,0.3);
    transform: translateY(-2px);
}

.category-tab .cat-icon {
    font-size: 16px;
}

/* ===== PRODUCT GRID ===== */
.menu-content {
    max-width: 600px;
    margin: 0 auto;
    padding: 20px;
}

.category-section {
    margin-bottom: 32px;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    animation: fadeInUp 0.5s ease-out;
}

.section-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-sm);
    background: var(--gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    box-shadow: 0 4px 15px rgba(99,102,241,0.2);
}

.section-title {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.section-count {
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 500;
}

.products-grid {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

/* ===== PRODUCT CARD ===== */
.product-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: flex;
    position: relative;
    cursor: pointer;
    animation: fadeInUp 0.5s ease-out both;
    border: 1px solid var(--border);
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(99,102,241,0.2);
}

.product-card:active {
    transform: scale(0.98);
}

.product-card.unavailable {
    opacity: 0.5;
    pointer-events: none;
}

.product-image {
    width: 130px;
    min-height: 130px;
    background: linear-gradient(135deg, #e2e8f0, #cbd5e1);
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-image img {
    transform: scale(1.08);
}

.product-image .placeholder-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 40px;
    opacity: 0.4;
}

.product-badges {
    position: absolute;
    top: 8px;
    left: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.product-badge {
    width: 26px;
    height: 26px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    backdrop-filter: blur(10px);
    background: rgba(255,255,255,0.85);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.product-info {
    flex: 1;
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 130px;
}

.product-name {
    font-size: 16px;
    font-weight: 700;
    letter-spacing: -0.2px;
    margin-bottom: 4px;
    line-height: 1.3;
}

.product-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 8px;
}

/* Allergen letter codes (EU standard A-N) */
.allergen-letters {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 4px;
    margin-bottom: 6px;
}

.allergen-code {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    font-size: 10px;
    font-weight: 800;
    color: white;
    background: var(--ac-color, #6b7280);
    line-height: 1;
    flex-shrink: 0;
}

/* Allergen detail section in product modal */
.allergen-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    margin-top: 8px;
}

.allergen-detail-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    border-radius: 10px;
    background: var(--bg, #f8fafc);
    border: 1px solid var(--border, #e2e8f0);
}

.allergen-detail-item .ad-code {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 800;
    color: white;
    background: var(--ac-color, #6b7280);
    flex-shrink: 0;
}

.allergen-detail-item .ad-info {
    flex: 1;
    min-width: 0;
}

.allergen-detail-item .ad-name {
    font-size: 12px;
    font-weight: 700;
    color: var(--text, #1e293b);
    line-height: 1.2;
}

.allergen-detail-item .ad-desc {
    font-size: 10px;
    color: var(--text-secondary, #64748b);
    line-height: 1.2;
}

@media (max-width: 380px) {
    .allergen-detail-grid { grid-template-columns: 1fr; }
}

.product-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
}

.product-price {
    font-size: 20px;
    font-weight: 800;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
}

.btn-add {
    width: 40px;
    height: 40px;
    border-radius: 14px;
    border: none;
    background: var(--gradient);
    color: white;
    font-size: 20px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-bounce);
    box-shadow: 0 4px 15px rgba(99,102,241,0.3);
}

.btn-add:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(99,102,241,0.4);
}

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

.btn-add.added {
    animation: cart-bounce 0.4s ease;
    background: var(--success);
    box-shadow: 0 4px 15px rgba(16,185,129,0.3);
}

/* ===== QUANTITY SELECTOR ===== */
.qty-selector {
    display: flex;
    align-items: center;
    gap: 4px;
    background: var(--bg);
    border-radius: 14px;
    padding: 4px;
}

.qty-btn {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    border: none;
    background: var(--bg-card);
    color: var(--text);
    font-size: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-fast);
    box-shadow: var(--shadow-sm);
}

.qty-btn:hover { background: var(--primary); color: white; }
.qty-btn.minus:hover { background: var(--danger); }

.qty-value {
    width: 28px;
    text-align: center;
    font-weight: 700;
    font-size: 15px;
}

/* ===== CART PANEL (Bottom Sheet) ===== */
.cart-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(8px);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.cart-overlay.open {
    opacity: 1;
    visibility: visible;
}

.cart-panel {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-card);
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    z-index: 1001;
    max-height: 85vh;
    transform: translateY(100%);
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    box-shadow: 0 -10px 40px rgba(0,0,0,0.15);
}

.cart-panel.open {
    transform: translateY(0);
}

.cart-handle {
    width: 40px;
    height: 5px;
    background: var(--text-muted);
    border-radius: 10px;
    margin: 12px auto;
    opacity: 0.3;
}

.cart-header {
    padding: 0 24px 16px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.cart-header h2 {
    font-size: 20px;
    font-weight: 800;
}

.cart-count {
    background: var(--gradient);
    color: white;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 13px;
    font-weight: 700;
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    padding: 16px 24px;
}

.cart-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
    animation: fadeInUp 0.3s ease-out;
}

.cart-item-image {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, #e2e8f0, #cbd5e1);
    overflow: hidden;
    flex-shrink: 0;
}

.cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-info {
    flex: 1;
}

.cart-item-name {
    font-size: 15px;
    font-weight: 700;
}

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

.cart-item-note {
    font-size: 12px;
    color: var(--primary);
    cursor: pointer;
}

.cart-footer {
    padding: 20px 24px;
    border-top: 1px solid var(--border);
    background: var(--bg);
    border-radius: 0 0 0 0;
}

.cart-summary {
    margin-bottom: 16px;
}

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

.cart-summary-row.total {
    font-size: 20px;
    font-weight: 800;
    color: var(--text);
    margin-top: 12px;
    padding-top: 12px;
    border-top: 2px solid var(--border);
}

.cart-note-input {
    width: 100%;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    border: 2px solid var(--border);
    background: var(--bg-card);
    font-family: var(--font);
    font-size: 14px;
    color: var(--text);
    margin-bottom: 12px;
    transition: var(--transition-fast);
    resize: none;
}

.cart-note-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(99,102,241,0.1);
}

/* ===== FLOATING CART BUTTON ===== */
.floating-cart {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 900;
    max-width: 560px;
    width: calc(100% - 40px);
    animation: fadeInUp 0.5s ease-out;
}

.floating-cart-btn {
    width: 100%;
    padding: 16px 24px;
    border-radius: var(--radius);
    border: none;
    background: var(--gradient);
    color: white;
    font-family: var(--font);
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 8px 30px rgba(99,102,241,0.35);
    transition: var(--transition);
}

.floating-cart-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(99,102,241,0.45);
}

.floating-cart-btn:active {
    transform: scale(0.98);
}

.floating-cart-btn .cart-icon-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}

.floating-cart-btn .cart-total {
    font-size: 18px;
    font-weight: 800;
}

/* ===== BUTTONS ===== */
.btn {
    padding: 14px 28px;
    border-radius: var(--radius-sm);
    border: none;
    font-family: var(--font);
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
}

.btn:hover { transform: translateY(-2px); }
.btn:active { transform: scale(0.97); }

.btn-primary {
    background: var(--gradient);
    color: white;
    box-shadow: 0 4px 15px rgba(99,102,241,0.3);
}
.btn-primary:hover { box-shadow: 0 8px 25px rgba(99,102,241,0.4); }

.btn-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    box-shadow: 0 4px 15px rgba(16,185,129,0.3);
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    box-shadow: 0 4px 15px rgba(239,68,68,0.3);
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: white;
}

.btn-full { width: 100%; }

.btn-lg {
    padding: 18px 32px;
    font-size: 17px;
    border-radius: var(--radius);
}

/* ===== PRODUCT DETAIL MODAL ===== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(8px);
    z-index: 2000;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

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

.modal-content {
    background: var(--bg-card);
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    transform: translateY(100%);
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.modal-image {
    width: 100%;
    height: 250px;
    background: linear-gradient(135deg, #e2e8f0, #cbd5e1);
    position: relative;
    overflow: hidden;
}

.modal-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255,255,255,0.9);
    backdrop-filter: blur(10px);
    border: none;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
}

.modal-close:hover { transform: scale(1.1); }

.modal-body {
    padding: 24px;
}

.modal-title {
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-bottom: 8px;
}

.modal-desc {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 16px;
}

.modal-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.modal-badge {
    padding: 6px 14px;
    border-radius: var(--radius-full);
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    background: var(--bg);
    color: var(--text-secondary);
}

.modal-price {
    font-size: 28px;
    font-weight: 800;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
}

.modal-note {
    width: 100%;
    padding: 14px 18px;
    border-radius: var(--radius-sm);
    border: 2px solid var(--border);
    background: var(--bg);
    font-family: var(--font);
    font-size: 14px;
    color: var(--text);
    margin-bottom: 20px;
    transition: var(--transition-fast);
    resize: none;
    min-height: 70px;
}

.modal-note:focus {
    outline: none;
    border-color: var(--primary);
}

.modal-footer {
    display: flex;
    align-items: center;
    gap: 14px;
}

.modal-qty {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--bg);
    border-radius: var(--radius-sm);
    padding: 6px;
}

.modal-qty button {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    border: none;
    background: var(--bg-card);
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-sm);
}

.modal-qty button:hover { background: var(--primary); color: white; }

.modal-qty .qty-val {
    width: 36px;
    text-align: center;
    font-size: 18px;
    font-weight: 800;
}

/* ===== ORDER STATUS PAGE ===== */
.order-status-page {
    max-width: 600px;
    margin: 0 auto;
    padding: 20px;
}

.status-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    padding: 28px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
    text-align: center;
    animation: fadeInUp 0.5s ease-out;
}

.status-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--gradient);
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    animation: pulse-soft 2s ease-in-out infinite;
}

.status-title {
    font-size: 22px;
    font-weight: 800;
    margin-bottom: 4px;
}

.status-subtitle {
    color: var(--text-secondary);
    font-size: 14px;
}

/* Progress Steps */
.progress-steps {
    display: flex;
    justify-content: space-between;
    position: relative;
    padding: 20px 0;
}

.progress-steps::before {
    content: '';
    position: absolute;
    top: 36px;
    left: 10%;
    right: 10%;
    height: 4px;
    background: var(--border);
    border-radius: 2px;
}

.progress-step {
    text-align: center;
    position: relative;
    z-index: 1;
    flex: 1;
}

.step-dot {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--bg);
    border: 3px solid var(--border);
    margin: 0 auto 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: var(--transition);
}

.progress-step.active .step-dot {
    background: var(--gradient);
    border-color: var(--primary);
    color: white;
    box-shadow: 0 0 20px rgba(99,102,241,0.3);
}

.progress-step.done .step-dot {
    background: var(--success);
    border-color: var(--success);
    color: white;
}

.step-label {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
}

.progress-step.active .step-label,
.progress-step.done .step-label {
    color: var(--text);
}

/* ===== SEARCH ===== */
.search-bar {
    max-width: 600px;
    margin: 16px auto 0;
    padding: 0 20px;
}

.search-input-wrap {
    position: relative;
}

.search-input {
    width: 100%;
    padding: 14px 18px 14px 48px;
    border-radius: var(--radius);
    border: 2px solid var(--border);
    background: var(--bg-card);
    font-family: var(--font);
    font-size: 15px;
    color: var(--text);
    transition: var(--transition-fast);
    box-shadow: var(--shadow-sm);
}

.search-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(99,102,241,0.1), var(--shadow);
}

.search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 18px;
}

/* ===== TOAST ===== */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toast {
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    padding: 14px 20px;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 600;
    animation: slideInRight 0.4s ease-out;
    border-left: 4px solid var(--primary);
    max-width: 360px;
}

.toast.success { border-left-color: var(--success); }
.toast.error { border-left-color: var(--danger); }
.toast.warning { border-left-color: var(--warning); }

.toast-icon { font-size: 20px; }
.toast-close {
    margin-left: auto;
    cursor: pointer;
    opacity: 0.5;
    transition: var(--transition-fast);
}
.toast-close:hover { opacity: 1; }

/* ===== EMPTY STATE ===== */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    animation: fadeIn 0.5s ease-out;
}

.empty-icon {
    font-size: 64px;
    margin-bottom: 16px;
    animation: float 3s ease-in-out infinite;
}

.empty-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 8px;
}

.empty-desc {
    font-size: 14px;
    color: var(--text-secondary);
}

/* ===== LOADING ===== */
.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 40px auto;
}

.skeleton {
    background: linear-gradient(90deg, var(--border) 25%, rgba(148,163,184,0.3) 50%, var(--border) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s ease-in-out infinite;
    border-radius: var(--radius-sm);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 480px) {
    .product-image { width: 110px; min-height: 110px; }
    .product-name { font-size: 14px; }
    .product-price { font-size: 17px; }
    .product-desc { font-size: 12px; }
    .product-info { padding: 12px; min-height: 110px; }
    .section-title { font-size: 19px; }
    .modal-image { height: 200px; }
    .modal-title { font-size: 20px; }
    .modal-price { font-size: 24px; }
}

/* ===== LANG SWITCH ===== */
.lang-switch {
    display: flex;
    background: var(--bg);
    border-radius: var(--radius-full);
    padding: 3px;
}

.lang-btn {
    padding: 6px 14px;
    border-radius: var(--radius-full);
    border: none;
    background: transparent;
    font-family: var(--font);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-fast);
    color: var(--text-secondary);
}

.lang-btn.active {
    background: var(--bg-card);
    color: var(--text);
    box-shadow: var(--shadow-sm);
}

/* ===== CONFETTI / SUCCESS ANIMATION ===== */
.success-checkmark {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #10b981, #059669);
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    color: white;
    animation: scaleIn 0.5s ease-out;
    box-shadow: 0 8px 30px rgba(16,185,129,0.3);
}

/* ===== DECORATIVE BLOBS ===== */
.deco-blob {
    position: fixed;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.15;
    pointer-events: none;
    z-index: -1;
    animation: blob 8s ease-in-out infinite;
}

.blob-1 {
    top: -100px;
    right: -100px;
    background: var(--primary);
}

.blob-2 {
    bottom: -100px;
    left: -100px;
    background: var(--secondary);
    animation-delay: 2s;
}

/* ===== TAKEAWAY / DELIVERY FORM ===== */
.order-form {
    padding: 24px;
}

/* ===== PORTION & EXTRAS OPTIONS ===== */
.option-group-title {
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
    margin-bottom: 10px;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--border);
}
.portion-options {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}
.portion-btn {
    flex: 1;
    min-width: 80px;
    padding: 10px 14px;
    border-radius: 12px;
    border: 2px solid var(--border);
    background: var(--bg);
    font-family: var(--font);
    font-size: 13px;
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
    transition: var(--transition-fast);
    text-align: center;
    -webkit-tap-highlight-color: transparent;
}
.portion-btn:active { transform: scale(0.97); }
.portion-btn.active {
    border-color: var(--primary);
    background: rgba(99,102,241,0.08);
    color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99,102,241,0.1);
}
.portion-btn .portion-name { display: block; font-weight: 700; }
.portion-btn .portion-price { display: block; font-size: 12px; color: var(--text-secondary); margin-top: 2px; }
.portion-btn.active .portion-price { color: var(--primary); }

.extras-group {
    margin-bottom: 16px;
}
.extras-group-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}
.extras-group-title {
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
}
.extras-group-hint {
    font-size: 11px;
    color: var(--text-muted);
    background: var(--bg);
    padding: 2px 8px;
    border-radius: 6px;
}
.extra-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 12px;
    border: 2px solid var(--border);
    background: var(--bg-card);
    margin-bottom: 6px;
    cursor: pointer;
    transition: var(--transition-fast);
    -webkit-tap-highlight-color: transparent;
}
.extra-option:active { transform: scale(0.98); }
.extra-option.selected {
    border-color: var(--primary);
    background: rgba(99,102,241,0.06);
}
.extra-check {
    width: 22px;
    height: 22px;
    border-radius: 6px;
    border: 2px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: transparent;
    transition: var(--transition-fast);
    flex-shrink: 0;
}
.extra-option.selected .extra-check {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}
.extra-name { flex: 1; font-size: 14px; font-weight: 600; color: var(--text); }
.extra-price { font-size: 13px; font-weight: 700; color: var(--primary); }

.modal-portions, .modal-extras {
    margin: 16px 0 8px;
}

.form-group {
    margin-bottom: 16px;
}

.form-label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-input {
    width: 100%;
    padding: 14px 18px;
    border-radius: var(--radius-sm);
    border: 2px solid var(--border);
    background: var(--bg-card);
    font-family: var(--font);
    font-size: 15px;
    color: var(--text);
    transition: var(--transition-fast);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(99,102,241,0.1);
}

.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 18px;
    padding-right: 40px;
}

/* ===== SCROLL TO TOP BUTTON ===== */
.scroll-top-btn {
    position: fixed;
    bottom: 90px;
    right: 16px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background: var(--primary);
    color: white;
    font-size: 20px;
    font-weight: 800;
    cursor: pointer;
    z-index: 90;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity .3s, transform .3s;
    box-shadow: 0 4px 14px rgba(99,102,241,.35);
    -webkit-tap-highlight-color: transparent;
}
.scroll-top-btn.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===== LOADING SPINNER ===== */
.spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2.5px solid rgba(255,255,255,.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin .6s linear infinite;
    vertical-align: middle;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ===== BUTTON DISABLED STATE ===== */
.btn:disabled, button:disabled {
    opacity: .6;
    cursor: not-allowed;
    pointer-events: none;
}

/* ===== PRODUCT CARD TOUCH FEEDBACK ===== */
.product-card {
    -webkit-tap-highlight-color: transparent;
}
.product-card:active {
    transform: scale(0.97);
    transition: transform .1s;
}

/* ===== CUSTOMER FORM TOGGLE ===== */
.customer-form-toggle:hover {
    color: var(--primary);
}

/* ===== EMPTY CART STATE ===== */
.cart-empty {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
}
.cart-empty-icon {
    font-size: 48px;
    display: block;
    margin-bottom: 8px;
}
.cart-empty-text {
    font-size: 15px;
    font-weight: 600;
}

/* ===== ORDER MODE SELECTOR BAR ===== */
.order-mode-bar {
    margin: 0 16px 8px;
    background: linear-gradient(135deg, rgba(99,102,241,.06), rgba(139,92,246,.06));
    border: 1.5px solid rgba(99,102,241,.15);
    border-radius: 20px;
    padding: 16px;
    transition: all .3s ease;
}
.order-mode-bar.mode-selected {
    padding: 10px 16px;
}
.order-mode-bar.mode-selected .order-mode-title {
    display: none;
}
.order-mode-inner {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.order-mode-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 700;
    color: var(--text);
}
.order-mode-buttons {
    display: flex;
    gap: 8px;
}
.order-mode-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 14px 12px;
    border-radius: 16px;
    border: 2px solid var(--border);
    background: var(--bg-card);
    cursor: pointer;
    transition: all .2s ease;
    -webkit-tap-highlight-color: transparent;
}
.order-mode-btn:active {
    transform: scale(0.97);
}
.order-mode-btn .mode-icon {
    font-size: 28px;
}
.order-mode-btn .mode-label {
    font-size: 13px;
    font-weight: 700;
    color: var(--text);
}
.order-mode-btn.active {
    border-color: var(--primary);
    background: linear-gradient(135deg, rgba(99,102,241,.08), rgba(99,102,241,.04));
    box-shadow: 0 0 0 3px rgba(99,102,241,.1);
}
.order-mode-btn.active .mode-label {
    color: var(--primary);
}
.order-mode-bar.mode-selected .order-mode-buttons {
    gap: 6px;
}
.order-mode-bar.mode-selected .order-mode-btn {
    padding: 8px 12px;
    flex-direction: row;
    gap: 6px;
}
.order-mode-bar.mode-selected .order-mode-btn .mode-icon {
    font-size: 18px;
}
.order-mode-bar.mode-selected .order-mode-btn .mode-label {
    font-size: 12px;
}

/* ===== DELIVERY MODAL ===== */
.delivery-modal-content {
    max-height: 92vh;
    display: flex;
    flex-direction: column;
    padding: 0 !important;
    overflow: hidden;
}
.delivery-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px 16px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}
.delivery-modal-header h2 {
    font-size: 18px;
    font-weight: 800;
    margin: 0;
}
.delivery-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px 24px;
    -webkit-overflow-scrolling: touch;
}
.delivery-modal-footer {
    border-top: 1px solid var(--border);
    padding: 16px 24px 24px;
    flex-shrink: 0;
    background: var(--bg-card);
}

/* Delivery Form Groups */
.delivery-form-group {
    margin-bottom: 14px;
}
.delivery-form-group label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}
.delivery-input {
    width: 100%;
    padding: 12px 14px;
    border-radius: 12px;
    border: 2px solid var(--border);
    background: var(--bg-card);
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
    font-family: inherit;
    transition: all .2s ease;
    box-sizing: border-box;
    -webkit-appearance: none;
    appearance: none;
}
.delivery-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99,102,241,.1);
}
.delivery-input.error {
    border-color: var(--danger);
    box-shadow: 0 0 0 3px rgba(239,68,68,.1);
}
.delivery-input-error {
    font-size: 11px;
    color: var(--danger);
    margin-top: 4px;
    display: none;
    font-weight: 600;
}
.delivery-input.city-fixed {
    background: rgba(99,102,241,.05);
    border-color: rgba(99,102,241,.15);
    color: var(--primary);
    font-weight: 700;
    cursor: default;
}
.delivery-select {
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2364748b' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}
.delivery-select:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background-color: rgba(148,163,184,.08);
}

/* Phone Input */
.phone-input-wrap {
    display: flex;
    align-items: stretch;
    border-radius: 12px;
    overflow: hidden;
    border: 2px solid var(--border);
    transition: all .2s ease;
}
.phone-input-wrap:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99,102,241,.1);
}
.phone-prefix {
    display: flex;
    align-items: center;
    padding: 0 12px;
    background: rgba(99,102,241,.06);
    color: var(--primary);
    font-weight: 800;
    font-size: 14px;
    border-right: 2px solid var(--border);
    white-space: nowrap;
    user-select: none;
}
.phone-input {
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    flex: 1;
    min-width: 0;
}
.phone-input:focus {
    box-shadow: none !important;
}
.phone-input-wrap:has(.error) {
    border-color: var(--danger);
    box-shadow: 0 0 0 3px rgba(239,68,68,.1);
}

/* 3-column row for building/floor/apt */
.delivery-form-row {
    display: grid;
    grid-template-columns: 1fr 0.7fr 0.7fr;
    gap: 8px;
    margin-bottom: 14px;
}
.delivery-form-row .delivery-form-group {
    margin-bottom: 0;
}

/* Delivery Info Bar */
.delivery-info-bar {
    display: flex;
    gap: 0;
    background: linear-gradient(135deg, rgba(16,185,129,.06), rgba(59,130,246,.06));
    border: 1.5px solid rgba(16,185,129,.15);
    border-radius: 14px;
    padding: 0;
    margin-bottom: 14px;
    overflow: hidden;
}
.delivery-info-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 10px 8px;
    font-size: 11px;
    color: var(--text-secondary);
    text-align: center;
}
.delivery-info-item:not(:last-child) {
    border-right: 1px solid rgba(16,185,129,.12);
}
.delivery-info-item span:first-child {
    font-size: 18px;
}
.delivery-info-item strong {
    font-size: 13px;
    font-weight: 800;
    color: var(--text);
}

/* Delivery Summary */
.delivery-summary {
    margin-bottom: 12px;
}
.delivery-summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    font-size: 13px;
    color: var(--text-secondary);
}
.delivery-summary-row.total {
    border-top: 2px solid var(--border);
    margin-top: 4px;
    padding-top: 10px;
    font-size: 16px;
    font-weight: 800;
    color: var(--text);
}

/* ===== DELIVERY RESPONSIVE ===== */
@media (max-width: 400px) {
    .delivery-modal-body {
        padding: 12px 16px;
    }
    .delivery-modal-footer {
        padding: 12px 16px 20px;
    }
    .delivery-form-row {
        grid-template-columns: 1fr 0.6fr 0.6fr;
        gap: 6px;
    }
    .delivery-info-item {
        padding: 8px 4px;
        font-size: 10px;
    }
    .delivery-info-item strong {
        font-size: 12px;
    }
}
