/* ===== CSS Variables ===== */
:root {
    --primary: #f59e0b;
    --primary-dark: #d97706;
    --primary-light: #fbbf24;
    --secondary: #1a1a1a;
    --background: #0f0f0f;
    --surface: #1a1a1a;
    --surface-light: #252525;
    --text-primary: #ffffff;
    --text-secondary: #a3a3a3;
    --text-muted: #737373;
    --success: #22c55e;
    --whatsapp: #25d366;
    --border: #333333;
    --shadow: rgba(0, 0, 0, 0.3);
    --gradient: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
}

/* ===== Reset & Base ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Poppins', sans-serif;
    background: var(--background);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    padding-bottom: 80px;
}

/* ===== Header ===== */
.header {
    background: var(--surface);
    padding: 1rem;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 2px 10px var(--shadow);
}

.header-content {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo-icon {
    font-size: 2rem;
}

.logo-text h1 {
    font-family: 'Playfair Display', serif;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary);
    letter-spacing: 0.5px;
}

.tagline {
    font-size: 0.7rem;
    color: var(--text-muted);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.header-actions {
    display: flex;
    gap: 0.5rem;
}

.action-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
}

.action-btn:active {
    transform: scale(0.95);
}

.call-btn {
    background: var(--surface-light);
    border: 1px solid var(--border);
}

.whatsapp-btn {
    background: var(--whatsapp);
}

.btn-icon {
    font-size: 1.2rem;
}

/* ===== Info Bar ===== */
.info-bar {
    background: var(--surface-light);
    padding: 0.75rem 1rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    border-bottom: 1px solid var(--border);
}

.info-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.info-icon {
    font-size: 0.9rem;
}

/* ===== Offer Banner ===== */
.offer-banner {
    background: var(--gradient);
    padding: 0.875rem 1rem;
    text-align: center;
}

.offer-content {
    max-width: 600px;
    margin: 0 auto;
}

.offer-badge {
    display: inline-block;
    background: rgba(0, 0, 0, 0.2);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 1px;
    margin-bottom: 0.25rem;
}

.offer-content p {
    font-size: 0.85rem;
    color: var(--secondary);
}

/* ===== Category Navigation ===== */
.category-nav {
    background: var(--surface);
    padding: 1rem 0;
    position: sticky;
    top: 73px;
    z-index: 90;
    border-bottom: 1px solid var(--border);
}

.category-scroll {
    display: flex;
    gap: 0.5rem;
    padding: 0 1rem;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    max-width: 600px;
    margin: 0 auto;
}

.category-scroll::-webkit-scrollbar {
    display: none;
}

.category-btn {
    flex-shrink: 0;
    padding: 0.6rem 1.2rem;
    border: 1px solid var(--border);
    border-radius: 25px;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-family: 'Poppins', sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.category-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.category-btn.active {
    background: var(--gradient);
    border-color: var(--primary);
    color: var(--secondary);
    font-weight: 500;
}

/* ===== Menu Container ===== */
.menu-container {
    max-width: 600px;
    margin: 0 auto;
    padding: 1rem;
}

/* ===== Menu Section ===== */
.menu-section {
    margin-bottom: 2rem;
}

.menu-section.hidden {
    display: none;
}

.section-header {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.section-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--primary);
    white-space: nowrap;
}

.section-line {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, var(--border) 0%, transparent 100%);
}

/* ===== Menu Items ===== */
.menu-items {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.menu-item {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    transition: border-color 0.2s, transform 0.2s;
}

.menu-item:hover {
    border-color: var(--primary);
}

.menu-item.in-cart {
    border-color: var(--primary);
    background: rgba(245, 158, 11, 0.05);
}

.item-info {
    flex: 1;
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    min-width: 0;
}

.item-name {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--text-primary);
    white-space: nowrap;
}

.item-dots {
    flex: 1;
    border-bottom: 1px dotted var(--text-muted);
    min-width: 20px;
    margin: 0 0.25rem;
    position: relative;
    top: -4px;
}

.item-price {
    font-weight: 600;
    color: var(--primary);
    font-size: 1rem;
    white-space: nowrap;
}

.item-actions {
    flex-shrink: 0;
}

.add-btn {
    background: var(--gradient);
    border: none;
    color: var(--secondary);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    font-family: 'Poppins', sans-serif;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.add-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}

.add-btn:active {
    transform: scale(0.98);
}

.qty-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--surface-light);
    border: 1px solid var(--primary);
    border-radius: 8px;
    padding: 0.25rem;
}

.qty-controls.hidden {
    display: none;
}

.qty-btn {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 6px;
    background: var(--primary);
    color: var(--secondary);
    font-size: 1.2rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.qty-btn:hover {
    background: var(--primary-dark);
}

.qty-btn.minus {
    background: var(--surface);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.qty-value {
    min-width: 24px;
    text-align: center;
    font-weight: 600;
    font-size: 1rem;
}

/* ===== Cart Panel ===== */
.cart-panel {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--surface);
    border-top: 2px solid var(--primary);
    border-radius: 20px 20px 0 0;
    z-index: 200;
    transition: transform 0.3s ease;
    max-height: 70vh;
    display: flex;
    flex-direction: column;
}

.cart-panel.minimized .cart-body {
    display: none;
}

.cart-panel.minimized .toggle-icon {
    transform: rotate(180deg);
}

.cart-header {
    padding: 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    user-select: none;
}

.cart-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    font-size: 1rem;
}

.cart-icon {
    font-size: 1.3rem;
}

.cart-count {
    background: var(--primary);
    color: var(--secondary);
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
}

.cart-total-mini {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--primary);
}

.cart-toggle {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.5rem;
}

.toggle-icon {
    font-size: 0.9rem;
    transition: transform 0.3s;
}

.cart-body {
    padding: 0 1rem 1rem;
    overflow-y: auto;
    flex: 1;
}

.cart-items {
    max-height: 200px;
    overflow-y: auto;
    margin-bottom: 1rem;
}

.empty-cart {
    text-align: center;
    padding: 2rem 1rem;
    color: var(--text-muted);
}

.empty-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 0.5rem;
    opacity: 0.5;
}

.empty-cart p {
    font-weight: 500;
    margin-bottom: 0.25rem;
}

.empty-hint {
    font-size: 0.8rem;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border);
}

.cart-item:last-child {
    border-bottom: none;
}

.cart-item-info {
    flex: 1;
}

.cart-item-name {
    font-weight: 500;
    font-size: 0.9rem;
    margin-bottom: 0.2rem;
}

.cart-item-price {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.cart-item-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.cart-item-qty {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    background: var(--surface-light);
    padding: 0.25rem;
    border-radius: 6px;
}

.cart-qty-btn {
    width: 26px;
    height: 26px;
    border: none;
    border-radius: 4px;
    background: var(--border);
    color: var(--text-primary);
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-qty-btn:hover {
    background: var(--primary);
    color: var(--secondary);
}

.cart-qty-value {
    min-width: 20px;
    text-align: center;
    font-weight: 600;
    font-size: 0.85rem;
}

.cart-item-total {
    font-weight: 600;
    color: var(--primary);
    min-width: 60px;
    text-align: right;
}

.remove-item {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 1.1rem;
    padding: 0.25rem;
    transition: color 0.2s;
}

.remove-item:hover {
    color: #ef4444;
}

.cart-summary {
    background: var(--surface-light);
    padding: 1rem;
    border-radius: 10px;
    margin-bottom: 1rem;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.summary-row:last-child {
    margin-bottom: 0;
}

.total-row {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    padding-top: 0.5rem;
    border-top: 1px solid var(--border);
    margin-top: 0.5rem;
}

.total-row span:last-child {
    color: var(--primary);
}

.checkout-btn {
    width: 100%;
    padding: 1rem;
    background: var(--gradient);
    border: none;
    border-radius: 12px;
    color: var(--secondary);
    font-size: 1rem;
    font-weight: 600;
    font-family: 'Poppins', sans-serif;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.checkout-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.4);
}

.checkout-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ===== Modal ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 300;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
    padding: 1rem;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: var(--surface);
    border-radius: 20px;
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    transform: translateY(30px);
    transition: transform 0.3s;
}

.modal-overlay.active .modal {
    transform: translateY(0);
}

.modal-header {
    padding: 1.25rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    background: var(--surface);
    z-index: 10;
}

.modal-header h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.25rem;
    color: var(--primary);
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.25rem;
    line-height: 1;
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-body {
    padding: 1.25rem;
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.875rem 1rem;
    background: var(--surface-light);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-primary);
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
}

.order-summary-modal {
    background: var(--surface-light);
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 1.25rem;
}

.order-summary-modal h4 {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--text-secondary);
}

#modalOrderItems {
    max-height: 150px;
    overflow-y: auto;
    margin-bottom: 0.75rem;
}

.modal-order-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    padding: 0.4rem 0;
    border-bottom: 1px solid var(--border);
}

.modal-order-item:last-child {
    border-bottom: none;
}

.modal-order-item span:first-child {
    color: var(--text-secondary);
}

.modal-order-item span:last-child {
    font-weight: 500;
}

.modal-total {
    display: flex;
    justify-content: space-between;
    font-weight: 700;
    font-size: 1rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border);
}

.modal-total span:last-child {
    color: var(--primary);
}

.whatsapp-order-btn {
    width: 100%;
    padding: 1rem;
    background: var(--whatsapp);
    border: none;
    border-radius: 12px;
    color: white;
    font-size: 1rem;
    font-weight: 600;
    font-family: 'Poppins', sans-serif;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: transform 0.2s, box-shadow 0.2s;
}

.whatsapp-order-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}

.wa-icon {
    font-size: 1.3rem;
}

/* ===== Footer ===== */
.footer {
    background: var(--surface);
    border-top: 1px solid var(--border);
    padding: 2rem 1rem;
    margin-top: 2rem;
}

.footer-content {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
}

.footer-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 1rem;
}

.footer-info {
    margin-bottom: 1.5rem;
}

.footer-info p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 0.4rem;
}

.footer-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.footer-btn {
    padding: 0.75rem 1.5rem;
    border-radius: 10px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: transform 0.2s;
}

.footer-btn:first-child {
    background: var(--surface-light);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.footer-btn.whatsapp {
    background: var(--whatsapp);
    color: white;
}

.footer-btn:hover {
    transform: scale(1.05);
}

.copyright {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* ===== Responsive ===== */
@media (min-width: 768px) {
    body {
        padding-bottom: 100px;
    }
    
    .cart-panel {
        left: 50%;
        transform: translateX(-50%);
        max-width: 600px;
        border-radius: 20px 20px 0 0;
    }
    
    .header-content,
    .category-scroll {
        max-width: 600px;
    }
}

/* ===== Animations ===== */
@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.cart-count {
    animation: pulse 2s infinite;
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--surface-light);
}

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}
