@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,700;1,700&family=Poppins:wght@300;400;600&display=swap');

:root {
    --primary: #1a44f2;       /* The deep SonRise Blue from your logo */
    --accent: #f2c94c;        /* Golden crust / Sunrise yellow */
    --bg-cream: #fffdf5;      /* Warm flour/dough background */
    --text-main: #2c3e50;     /* Soft slate for readability */
    --white: #ffffff;
}

body {
    background-color: var(--bg-cream);
    color: var(--text-main);
    font-family: 'Outfit', sans-serif; /* A clean, modern font */
}

h1, h2, h3, .logo {
    font-family: 'Playfair Display', serif;
}

/* Navigation */
header {
    background: var(--white);
    padding: 1.5rem 5%;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 15px rgba(0,0,0,0.05);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1100px;
    margin: auto;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary);
    font-style: italic;
}

#cart-toggle {
    background: var(--primary);
    color: var(--white);
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 50px;
    cursor: pointer;
    font-weight: 600;
    transition: 0.3s;
}

#cart-toggle:hover {
    background: var(--accent-dark);
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 80px 20px;
    background: linear-gradient(rgba(254, 250, 224, 0.8), rgba(254, 250, 224, 0.8)), 
                url('https://images.unsplash.com/photo-1509440159596-0249088772ff?q=80&w=2072&auto=format&fit=crop');
    background-size: cover;
    background-position: center;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 10px;
}

/* Menu Cards */
.menu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    padding: 40px 5%;
    max-width: 1200px;
    margin: auto;
}

.card {
    background: var(--white);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
    transition: transform 0.3s ease;
    border: 1px solid rgba(0,0,0,0.02);
}

.card:hover {
    transform: translateY(-10px);
}

.card img {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.card-content {
    padding: 20px;
    text-align: center;
}

.card h3 {
    margin: 10px 0;
    font-size: 1.5rem;
}

.card p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 20px;
}

.price-tag {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 15px;
}

.sale-badge {
    background: var(--sale-red);
    color: white;
    padding: 4px 10px;
    border-radius: 5px;
    font-size: 0.75rem;
    text-transform: uppercase;
    vertical-align: middle;
}

.add-btn {
    background: transparent;
    border: 2px solid var(--accent);
    color: var(--accent-dark);
    padding: 10px 25px;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
}

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

/* Sidebar Styles */
.sidebar {
    position: fixed;
    right: -450px;
    top: 0;
    width: 400px;
    height: 100%;
    background: var(--white);
    box-shadow: -10px 0 30px rgba(0,0,0,0.1);
    transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 40px;
    z-index: 2000;
    overflow: auto;
}

.sidebar.open { right: 0; }

#close-cart {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    float: right;
}

.category-section {
    width: 100%;
    margin-bottom: 50px;
    clear: both;
}

.category-header {
    font-size: 2.2rem;
    color: var(--primary);
    border-bottom: 2px solid var(--accent);
    margin: 40px 5% 20px 5%;
    padding-bottom: 10px;
    text-transform: capitalize;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
    padding: 0 5%;
}

/* Ensure the main menu-container doesn't mess with our inner grids */
.menu-grid {
    display: block; /* Overriding the previous grid display */
}

/* Cart Items Styling */
#cart-items {
    margin: 20px 0;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px dashed var(--accent);
}

.cart-item-info {
    display: flex;
    flex-direction: column;
}

.cart-item-name {
    font-weight: 600;
    color: var(--primary);
}

.cart-item-meta {
    font-size: 0.8rem;
    color: var(--text-muted);
}

#cart-total {
    font-size: 1.4rem;
    font-weight: 700;
    text-align: right;
    margin: 20px 0;
    color: var(--primary);
    font-family: 'Playfair Display', serif;
}

/* Form Styling */
#order-form h3 {
    margin-top: 30px;
    font-size: 1.2rem;
}

#order-form input, 
#order-form textarea, 
#order-form select {
    width: 100%;
    padding: 12px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-family: 'Poppins', sans-serif;
    box-sizing: border-box; /* Ensures padding doesn't break width */
}

#order-form select {
    background-color: white;
}

#order-form {
    margin-bottom: 50px;
}

.button-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.promo-btn {
    background: #27ae60;
    color: white;
    border: none;
    padding: 10px;
    border-radius: 50px;
    font-weight: bold;
    cursor: pointer;
    font-size: 0.85rem;
    transition: 0.3s;
}

.promo-btn:hover {
    background: #219150;
    transform: scale(1.05);
}

.promo-applied {
    background-color: #f0fff4;
    border-left: 4px solid #27ae60 !important;
    padding-left: 10px !important;
}

.promo-applied .qty-controls {
    background: #e8f5e9; /* Light green to indicate it's a bonus */
    border: 1px solid #27ae60;
}

.tier-info {
    background: #fdf6e3;
    border: 1px dashed var(--accent);
    border-radius: 8px;
    padding: 8px;
    margin: 10px 0;
}

.tier-info ul {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.85rem;
    color: var(--primary);
    font-weight: 600;
}

.tier-info li {
    display: flex;
    justify-content: space-between;
}

.tier-info::before {
    content: "Bulk Savings:";
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.parent-section {
    margin-bottom: 50px;
}

.parent-header {
    font-size: 2.5rem;
    color: var(--primary);
    text-align: center;
    margin-bottom: 5px;
}

.parent-divider {
    border: none;
    border-top: 3px solid var(--accent);
    width: 60px;
    margin: 0 auto 30px;
}

.sub-header {
    font-size: 1.5rem;
    color: var(--text-muted);
    border-left: 5px solid var(--accent);
    padding-left: 15px;
    margin: 20px 0;
}

.min-error {
    border-left: 4px solid #e74c3c !important;
    background-color: #fdf2f2;
}

.error-text {
    color: #e74c3c;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.7rem;
}

#submit-btn:disabled {
    background-color: #bdc3c7;
    cursor: not-allowed;
}

.manual-qty-input {
    width: 50px;
    text-align: center;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 2px;
    font-weight: bold;
}

/* Remove the default arrows in number inputs for a cleaner look */
.manual-qty-input::-webkit-inner-spin-button,
.manual-qty-input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.min-tag {
    font-size: 0.75rem;
    color: #e67e22;
    font-weight: bold;
    margin: 5px 0;
}

.price-display {
    margin: 10px 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

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

.min-price-info {
    font-size: 0.9rem;
    color: #666;
}

.tier-info {
    background: #f9f9f9;
    padding: 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    margin-bottom: 15px;
}

.tier-info p {
    margin: 0 0 5px 0;
    font-weight: bold;
    color: #e67e22;
}

.tier-info ul {
    margin: 0;
    padding-left: 15px;
}

/* Smooth scrolling for the whole page */
html {
    scroll-behavior: smooth;
}

.sticky-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 10px 0;
    margin-bottom: 20px;
}

.nav-links-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    gap: 20px;
    padding: 0 20px;
}

.nav-link {
    text-decoration: none;
    color: var(--primary);
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.9rem;
    padding: 8px 16px;
    border-radius: 20px;
    transition: 0.3s;
    border: 1px solid transparent;
}

.nav-link:hover {
    background: var(--accent);
    color: white;
}

/* Offset for the sticky header so it doesn't cover the title you jump to */
.parent-section {
    scroll-margin-top: 80px; 
}

/* CTA Button */
.cta-button {
    background: linear-gradient(135deg, #e67e22, #d35400);
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 1.1rem;
    font-weight: bold;
    border-radius: 50px;
    cursor: pointer;
    width: 100%;
    box-shadow: 0 4px 15px rgba(211, 84, 0, 0.3);
    transition: transform 0.2s, box-shadow 0.2s;
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(211, 84, 0, 0.4);
}

/* Modal Styling */
.modal {
    display: none;
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.7);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background: white;
    padding: 30px;
    border-radius: 12px;
    max-width: 500px;
    width: 90%;
}

.legal-list {
    font-size: 0.9rem;
    color: #555;
    margin: 20px 0;
}

.grand-total {
    font-size: 1.3rem;
    border-top: 2px solid #333;
    margin-top: 10px;
    padding-top: 5px;
}

/* Modal Overlay - Darkens the background */
.modal {
    display: none; 
    position: fixed;
    top: 0; left: 0; 
    width: 100%; height: 100%;
    background: rgba(44, 62, 80, 0.8); /* Deep slate with transparency */
    backdrop-filter: blur(4px); /* Blurs the menu behind the modal */
    z-index: 2000;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

/* Modal Box */
.modal-content {
    background: white;
    max-width: 550px;
    width: 100%;
    border-radius: 15px;
    padding: 40px;
    position: relative;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
    animation: modalSlideUp 0.3s ease-out;
}

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

.modal-content h3 {
    color: var(--primary);
    font-size: 1.8rem;
    margin-bottom: 15px;
    text-align: center;
}

.modal-content p {
    color: #666;
    line-height: 1.6;
    text-align: center;
    margin-bottom: 25px;
}

/* The Terms List */
.legal-list {
    background: #fdf6e3; /* Soft cream background */
    border-radius: 10px;
    padding: 20px 20px 20px 40px;
    margin-bottom: 30px;
    border-left: 4px solid var(--accent);
}

.legal-list li {
    margin-bottom: 12px;
    color: #444;
    font-size: 0.95rem;
}

.legal-list li strong {
    color: var(--primary);
}

/* Button Container */
.modal-actions {
    display: flex;
    gap: 15px;
}

/* Cancel Button */
.btn-secondary {
    flex: 1;
    background: #ecf0f1;
    color: #7f8c8d;
    border: none;
    padding: 15px;
    border-radius: 50px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.2s;
}

.btn-secondary:hover {
    background: #bdc3c7;
    color: #2c3e50;
}

/* Consent Button */
.btn-primary {
    flex: 2;
    background: linear-gradient(135deg, #27ae60, #2ecc71);
    color: white;
    border: none;
    padding: 15px;
    border-radius: 50px;
    font-weight: bold;
    font-size: 1rem;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(46, 204, 113, 0.3);
    transition: 0.2s;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(46, 204, 113, 0.4);
}

@media (max-width: 480px) {
    .modal-content {
        padding: 25px 20px;
    }
    
    .modal-actions {
        flex-direction: column-reverse; /* Put Consent on top of Cancel */
    }

    .modal-content h3 {
        font-size: 1.4rem;
    }
}

.main-header {
    background: var(--white);
    padding: 20px 0;
    text-align: center;
    border-bottom: 4px solid var(--primary);
}

.brand-logo {
    max-width: 250px;
    height: auto;
}

.heritage-hero {
        background: linear-gradient(rgba(254, 250, 224, 0.8), rgba(254, 250, 224, 0.8)), 
                url('https://images.unsplash.com/photo-1509440159596-0249088772ff?q=80&w=2072&auto=format&fit=crop');
    padding: 60px 20px;
    text-align: center;
    border-bottom: 1px solid #eee;
}

.hero-content h1 {
    color: var(--primary);
    font-size: 2.2rem;
    margin-bottom: 15px;

}

.hero-content p {
    max-width: 800px;
    margin: 0 auto 20px;
    font-style: italic;
    line-height: 1.8;
}

.heritage-badge {
    display: inline-block;
    background: var(--primary);
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 0.9rem;
}

.card {
    background: var(--white);
    border: 1px solid rgba(26, 68, 242, 0.1);
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(26, 68, 242, 0.1);
}

.price-display {
    color: var(--primary);
    font-weight: 800;
}

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

.add-btn:hover {
    background: transparent;
    color: var(--primary);
}

.site-footer {
    background-color: var(--primary);
    color: white;
    padding: 60px 20px 20px;
    margin-top: 50px;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 40px;
}

.footer-section h3 {
    font-size: 1.4rem;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--accent);
    display: inline-block;
    padding-bottom: 5px;
}

.footer-logo {
    max-width: 180px;
    filter: brightness(0) invert(1); /* Turns the logo white for the blue background */
    margin-bottom: 15px;
}

.hours-list {
    list-style: none;
    padding: 0;
}

.hours-list li {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    font-size: 0.95rem;
}

.social-links {
    margin-top: 15px;
    font-size: 1.5rem;
}

.footer-bottom {
    text-align: center;
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 0.8rem;
    opacity: 0.8;
}

.footer-bottom a {
    color: white;
    text-decoration: underline;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .footer-section h3 {
        display: block;
    }
    .hours-list li {
        justify-content: center;
        gap: 20px;
    }
}

/* Hero Badge Flags */
.mini-flag {
    width: 20px;
    height: auto;
    vertical-align: middle;
    margin-right: 5px;
    border-radius: 2px; /* Slight round for a modern look */
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.heritage-badge {
    display: inline-flex;
    align-items: center;
    background: var(--primary);
    color: white;
    padding: 8px 20px;
    border-radius: 50px;
    font-weight: bold;
    gap: 5px; /* Spaces flags and text */
}

/* Footer Flags */
.footer-flag {
    width: 35px;
    height: auto;
    margin: 10px 8px 0 0;
    border-radius: 3px;
    opacity: 0.9;
    transition: opacity 0.3s;
}

.footer-flag:hover {
    opacity: 1;
}