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

body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #fdfaf6; /* Light beige background */
    display: flex; /* Added for sticky footer */
    flex-direction: column; /* Added for sticky footer */
    min-height: 100vh; /* Added for sticky footer */
}

main {
    flex-grow: 1; /* Added for sticky footer */
}

.container {
    width: 90%;
    max-width: 1100px;
    margin: 0 auto;
    padding: 20px 0;
}

/* Header */
header {
    background-color: #8B4513; /* Saddle Brown */
    color: #fff;
    padding: 10px 0;
    border-bottom: 5px solid #D2B48C; /* Tan */
    flex-shrink: 0; /* Prevent header shrinking */
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap; /* Allow wrapping on small screens */
}

header h1 {
    font-family: 'Playfair Display', serif;
    font-size: 2.2rem; /* Slightly reduced size */
    margin-left: 15px;
    margin-right: auto; /* Push nav to the right */
    padding-right: 20px;
}

.header-link { /* Style link wrapping H1 */
    color: #fff;
    text-decoration: none;
}

.logo {
    height: 50px; /* Slightly reduced size */
    width: auto;
    flex-shrink: 0; /* Prevent logo shrinking */
}

header nav ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap; /* Allow nav items to wrap */
}

header nav ul li {
    margin-left: 15px; /* Reduced margin */
    margin-top: 5px; /* Add top margin for wrap */
    margin-bottom: 5px; /* Add bottom margin for wrap */
}

header nav ul li a {
    color: #fff;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
    padding: 5px; /* Add padding for easier clicking */
}

header nav ul li a:hover,
header nav ul li a.active { /* Style for active page */
    color: #FFD700; /* Gold */
}

/* Main Content Sections */
main section {
    padding: 40px 0 60px 0; /* Adjusted padding */
}

/* Style for pages that aren't the homepage hero */
#produits-page, #commander-page, #contact-page {
     background-color: #fff;
     border-top: 1px solid #eee;
}

main section:nth-child(even):not(.hero) { /* Keep alternating for potential future sections */
     background-color: #fdfaf6;
}

h2 {
    font-family: 'Playfair Display', serif;
    font-size: 2.2rem;
    color: #8B4513;
    text-align: center;
    margin-bottom: 40px;
}

/* Hero Section (Homepage specific) */
.hero {
    background: url('bakery-background.png') no-repeat center center/cover;
    color: #333;
    text-align: center;
    padding: 80px 0;
     background-color: #faeecd; /* Fallback if image fails */
}

.hero h2 {
     color: #a0522d; /* Sienna */
     font-size: 2.8rem;
}

.hero p {
    font-size: 1.1rem;
    margin-bottom: 30px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-button {
    display: inline-block;
    background-color: #a0522d; /* Sienna */
    color: #fff !important; /* Ensure text is white */
    padding: 12px 25px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: background-color 0.3s ease;
    border: none; /* Remove default border if it's also a link */
    cursor: pointer; /* Indicate clickable */
}

.cta-button:hover {
    background-color: #8B4513; /* Darker Brown */
    text-decoration: none; /* Remove underline on hover */
}

/* Product Grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.product-item {
    background-color: #fff;
    border: 1px solid #eee;
    padding: 20px;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    border-radius: 8px;
    transition: transform 0.3s ease;
    display: flex; /* Use flexbox for alignment */
    flex-direction: column; /* Stack items vertically */
    justify-content: space-between; /* Push price to bottom */
}

.product-item:hover {
    transform: translateY(-5px);
}

.product-item img {
    max-width: 100%;
    height: 180px;
    object-fit: cover;
    margin-bottom: 15px;
    border-radius: 5px;
}

.product-item h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.4rem;
    margin-bottom: 10px;
    color: #8B4513;
}

.product-item p {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 15px;
    flex-grow: 1; /* Allow description to take available space */
}

.price {
    font-size: 1.2rem;
    font-weight: bold;
    color: #a0522d;
    margin-top: auto; /* Keep price at the bottom */
}

/* Commander Page */
#commander-page .container { /* Target container within commander page */
    text-align: center;
}

#commander-page p {
    margin-bottom: 15px;
    font-size: 1.1rem;
    max-width: 700px; /* Limit text width */
    margin-left: auto;
    margin-right: auto;
}

#commander-page a:not(.cta-button) { /* Style non-button links */
    color: #a0522d;
    font-weight: bold;
    text-decoration: none;
}
#commander-page a:not(.cta-button):hover {
    text-decoration: underline;
}
#commander-page .cta-button {
    margin-top: 20px; /* Add space above button */
}

/* Contact Page */
#contact-page .container { /* Target container within contact page */
    text-align: center; /* Center the heading */
}

.contact-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    text-align: left; /* Align text left within columns */
    margin-top: 30px;
}

.contact-info h3 {
     font-family: 'Playfair Display', serif;
    color: #8B4513;
    margin-bottom: 10px;
    text-align: left; /* Ensure h3 is left-aligned */
}

.contact-info p, .contact-info ul {
    margin-bottom: 15px;
}

.contact-info ul {
    list-style: none;
    padding-left: 0;
}

.contact-info a:not(.cta-button) {
    color: #a0522d;
    text-decoration: none;
}

.contact-info a:not(.cta-button):hover {
    text-decoration: underline;
}

.contact-info iframe {
    margin-top: 15px;
    border-radius: 5px;
    max-width: 100%; /* Ensure map scales */
}

/* Footer */
footer {
    background-color: #333;
    color: #eee;
    text-align: center;
    padding: 20px 0;
    margin-top: auto; /* Pushes footer down */
    flex-shrink: 0; /* Prevent footer shrinking */
}

/* Responsive adjustments */
@media (max-width: 768px) {
    header .container {
        flex-direction: column;
        align-items: center; /* Center items vertically */
        text-align: center;
    }
    header h1 {
        margin: 10px 0; /* Add vertical margin */
        padding-right: 0;
        font-size: 2rem;
    }
    header nav ul {
        justify-content: center; /* Center nav items */
        margin-top: 10px;
    }
     header nav ul li {
        margin-left: 10px; /* Adjust nav spacing */
        margin-right: 10px;
    }

    .hero h2 {
        font-size: 2.4rem;
    }
    .hero p {
        font-size: 1rem;
    }
    h2 {
        font-size: 2rem;
    }
    .product-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); /* Smaller min size */
    }
    .contact-info {
        grid-template-columns: 1fr; /* Stack columns */
        text-align: center; /* Center text in stacked view */
    }
     .contact-info h3 {
        text-align: center;
    }
     .contact-info iframe {
        height: 250px; /* Adjust map height */
    }
}

@media (max-width: 480px) {
     header h1 {
        font-size: 1.8rem;
    }
     .logo {
        height: 40px;
    }
     header nav ul li {
        margin-left: 5px;
        margin-right: 5px;
    }
    header nav ul li a {
        font-size: 0.9rem;
    }
    .cta-button {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
     .product-grid {
        gap: 15px;
    }
    .product-item {
        padding: 15px;
    }
     .product-item h3 {
        font-size: 1.2rem;
    }
     .price {
        font-size: 1.1rem;
    }
}