:root {
    --color-primary: #3d5a46;
    --color-primary-dark: #2c4233;
    --color-accent: #d9b99b;
    --color-accent-light: #e6cfb6;
    --color-text: #333333;
    --color-bg: #fdfdfd;
    --color-white: #ffffff;

    --font-heading: 'Playfair Display', serif;
    --font-body: 'Montserrat', sans-serif;

    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);

    --transition: all 0.3s ease;
}

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

body {
    font-family: var(--font-body);
    background-color: var(--color-bg);
    color: var(--color-text);
    line-height: 1.6;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: var(--color-primary);
}

/* Utilities */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.btn {
    display: inline-block;
    padding: 10px 24px;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-primary {
    background-color: var(--color-primary);
    color: var(--color-accent);
    border: 1px solid var(--color-primary);
}

.btn-primary:hover {
    background-color: var(--color-primary-dark);
    box-shadow: 0 0 15px rgba(217, 185, 155, 0.4);
}

.btn-accent {
    background-color: var(--color-accent);
    color: var(--color-primary);
}

.btn-accent:hover {
    background-color: var(--color-accent-light);
}

/* Loading Screen */
#loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--color-primary);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    transition: opacity 0.8s ease-out, visibility 0.8s;
}

.lamp-container {
    position: relative;
    width: 150px;
}

.loading-lamp {
    animation: spin 3s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Top Ticker */
.promo-ticker {
    background-color: var(--color-primary);
    color: var(--color-accent);
    padding: 8px 0;
    overflow: hidden;
    white-space: nowrap;
    font-size: 0.9rem;
    font-weight: 600;
}

.ticker-content {
    display: inline-block;
    animation: scroll-left 20s linear infinite;
    padding-left: 100%;
}

@keyframes scroll-left {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-100%);
    }
}

/* Navbar */
.main-header {
    background: var(--color-white);
    padding: 15px 0;
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 90px;
    /* Reduced from 150px */
    transition: all 0.3s ease;
    object-fit: contain;
}

.nav-icons {
    display: flex;
    gap: 20px;
}

.cart-icon-wrapper {
    position: relative;
    cursor: pointer;
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: var(--color-primary);
    color: var(--color-accent);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 0.75rem;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
}

/* Hero Section */
.hero {
    position: relative;
    height: 100vh;
    background-image: linear-gradient(rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.3)), url('../img/hero-bg.png');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--color-white);
}

.hero-content h1 {
    font-size: 3.5rem;
    color: var(--color-accent);
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

/* Category Nav */
.category-nav-wrapper {
    background: var(--color-white);
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 110px;
    /* Matched to new desktop header height */
    /* Adjust based on header height */
    z-index: 900;
    padding: 15px 0;
}

.category-list {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
    padding-bottom: 20px;
}

.cat-btn {
    background: none;
    border: 1px solid #eee;
    padding: 8px 20px;
    border-radius: 30px;
    white-space: nowrap;
    cursor: pointer;
    font-family: var(--font-heading);
    color: var(--color-primary);
    transition: var(--transition);
}

.cat-btn.active,
.cat-btn:hover {
    background-color: var(--color-primary);
    color: var(--color-accent);
    border-color: var(--color-primary);
}

/* Order Toggle */
.order-toggle-section {
    padding: 2rem 0;
    text-align: center;
}

.toggle-container {
    display: inline-flex;
    background: #eee;
    padding: 5px;
    border-radius: 50px;
}

.toggle-btn {
    padding: 10px 30px;
    border-radius: 40px;
    border: none;
    background: transparent;
    cursor: pointer;
    font-weight: 600;
    color: #888;
    transition: var(--transition);
}

.toggle-btn.active {
    background: var(--color-white);
    color: var(--color-primary);
    box-shadow: var(--shadow-sm);
}

/* Menu Grid */
.menu-section {
    padding: 2rem 0 4rem;
    background-color: #fafafa;
}

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

.menu-item {
    background: var(--color-white);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    position: relative;
    border: 1px solid transparent;
}

.menu-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--color-accent);
}

.item-img {
    height: 200px;
    background-color: #ddd;
    overflow: hidden;
}

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

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

.item-content {
    padding: 20px;
}

.item-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 10px;
}

.item-title {
    font-size: 1.2rem;
    margin-bottom: 5px;
}

.item-price {
    font-weight: bold;
    color: var(--color-primary);
    font-size: 1.1rem;
}

.item-desc {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 15px;
    min-height: 3rem;
}

.add-btn {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

/* Cart Drawer */
.cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1001;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.cart-drawer {
    position: fixed;
    top: 0;
    right: -400px;
    width: 400px;
    max-width: 90%;
    height: 100%;
    background: var(--color-white);
    z-index: 1002;
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
    transition: right 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    flex-direction: column;
}

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

.cart-open .cart-drawer {
    right: 0;
}

.cart-header {
    padding: 20px;
    background: var(--color-primary);
    color: var(--color-accent);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.close-cart {
    background: none;
    border: none;
    color: var(--color-accent);
    font-size: 1.5rem;
    cursor: pointer;
}

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

.cart-footer {
    padding: 20px;
    border-top: 1px solid #eee;
    background: #f9f9f9;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 15px;
    color: var(--color-primary);
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

/* Animations */
@keyframes smoke-fade {
    0% {
        opacity: 0;
        transform: translateY(20px) scale(0.8);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.magic-in {
    animation: smoke-fade 0.5s ease-out forwards;
}

@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2.5rem;
    }
}

/* Footer */
.main-footer {
    background-color: var(--color-primary);
    color: var(--color-accent);
    padding: 60px 0 20px;
    margin-top: 60px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-col h3 {
    color: var(--color-accent);
    font-size: 1.2rem;
    margin-bottom: 20px;
    font-family: var(--font-heading);
}

.footer-col p {
    color: var(--color-accent-light);
    font-size: 0.9rem;
    margin-bottom: 20px;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-icon {
    width: 35px;
    height: 35px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--color-accent);
    transition: var(--transition);
}

.social-icon:hover {
    background: var(--color-accent);
    color: var(--color-primary);
}

.footer-links,
.footer-contact {
    list-style: none;
}

.footer-links li,
.footer-contact li {
    margin-bottom: 12px;
}

.footer-links a,
.footer-contact li {
    color: var(--color-accent-light);
    text-decoration: none;
    transition: var(--transition);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

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

.footer-links a:hover,
.footer-contact a:hover {
    color: var(--color-white);
    padding-left: 5px;
}

.footer-bottom {
    border-top: 1px solid rgba(217, 185, 155, 0.2);
    padding-top: 20px;
    text-align: center;
    font-size: 0.8rem;
    color: var(--color-accent-light);
}

.btn-sm {
    padding: 8px 16px;
}

/* Reservation Section */
.reservation-section {
    background-color: var(--color-primary);
    padding: 80px 0;
    margin-top: 60px;
    text-align: center;
    background-image: url('https://www.transparenttextures.com/patterns/arabesque.png');
    /* Subtle texture */
}

.res-content {
    max-width: 800px;
    margin: 0 auto;
}

.res-header h2 {
    color: var(--color-accent);
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.res-header p {
    color: var(--color-accent-light);
    margin-bottom: 40px;
}

.res-form-blobs {
    background: rgba(255, 255, 255, 0.05);
    /* Glassmorphism */
    padding: 40px;
    border-radius: 20px;
    border: 1px solid rgba(217, 185, 155, 0.3);
    backdrop-filter: blur(10px);
}

.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.input-group {
    flex: 1;
}

.input-group input,
.input-group select,
.input-group textarea {
    width: 100%;
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(217, 185, 155, 0.2);
    border-radius: 10px;
    color: var(--color-accent);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: var(--transition);
}

.input-group input:focus,
.input-group select:focus,
.input-group textarea:focus {
    outline: none;
    border-color: var(--color-accent);
    background: rgba(255, 255, 255, 0.2);
}

.input-group textarea {
    min-height: 100px;
    resize: vertical;
}

.input-group.full-width {
    width: 100%;
    margin-bottom: 30px;
}

/* Specific styling for Date/Time inputs to handle placeholder color */
input[type="date"],
input[type="time"] {
    color-scheme: dark;
}

/* Placeholder styling */
::placeholder {
    color: rgba(230, 207, 182, 0.6);
}

.btn-block {
    width: 100%;
    border-radius: 10px;
    padding: 15px;
    font-size: 1.1rem;
}

@media (max-width: 768px) {
    .form-row {
        flex-direction: column;
    }

    /* Mobile Header Optimization */
    .main-header {
        padding: 10px 0;
        position: relative;
        /* Unstick on mobile */
    }

    .logo img {
        height: 60px;
        /* Reduced from 150px */
    }

    .nav-icons {
        gap: 10px;
    }

    /* Make Phone Number concise on mobile */
    .nav-icons a[href^="tel"] {
        font-size: 0;
        /* Hide text */
    }

    .nav-icons a[href^="tel"] i {
        font-size: 1.2rem;
        background: var(--color-primary);
        color: var(--color-accent);
        width: 35px;
        height: 35px;
        display: flex;
        justify-content: center;
        align-items: center;
        border-radius: 50%;
    }

    .btn-sm {
        padding: 6px 12px;
        font-size: 0.8rem;
    }

    /* Fix Sticky Nav on Mobile */
    .category-nav-wrapper {
        top: 0;
        /* Sticks to top */
        background: rgba(255, 255, 255, 0.98);
        /* Adjusted for smaller header */
        padding: 10px 0;
        overflow-x: auto;
        /* Allow horizontal scroll if needed */
        -webkit-overflow-scrolling: touch;
    }

    .category-list {
        flex-wrap: nowrap;
        /* Horizontal scroll */
        justify-content: flex-start;
        padding-bottom: 5px;
    }

    .container {
        padding: 0 15px;
    }

    /* Hero Adjustments */
    .hero {
        height: 350px;
    }

    .hero-content h1 {
        font-size: 2rem;
    }
}

/* Premium Aesthetic Enhancements */
.main-header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.menu-item {
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
    /* Softer, deeper shadow */
    border: none;
}

.menu-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(61, 90, 70, 0.15);
    /* Colored shadow match primary */
}

/* Gold Gradient Text for specific accents */
.hero-content h1 {
    background: linear-gradient(45deg, #d9b99b, #e6cfb6, #d9b99b);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    /* Fallback handled by gradient */
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Refined Buttons */
.btn {
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
    border: none;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
    color: var(--color-accent);
    border: none;
    border-radius: 50%;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    z-index: 990;
    /* Below cart overlay but above content */
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: var(--color-accent);
    color: var(--color-primary);
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(217, 185, 155, 0.4);
}

/* Mobile Form Optimization */
@media (max-width: 768px) {
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
    }

    .input-group input,
    .input-group select,
    .input-group textarea {
        font-size: 16px !important;
        /* Prevent iOS zoom */
        padding: 12px 15px;
        /* Comfortable touch area */
        margin-bottom: 5px;
        /* Slight visual separation */
    }

    .form-row {
        gap: 15px;
        /* Reduce gap slightly for mobile vertical stack */
    }
}