/* ----- General ----- */
:root {
  /* Earthy Palette */
  --bg-beige: #B8A99A;      /* The main header/footer background */
  --text-dark: #3D3630;     /* Deep brown/charcoal for text */
  --overlay-dark: rgba(0, 0, 0, 0.4);
  --white: #ECE4D9;
  
  /* Spacing & Transitions */
  --header-height: 80px;
  --transition-smooth: all 0.3s ease-in-out;

  /* Prevents header from covering the title when clicking nav links */
  scroll-padding-top: var(--header-height);
}

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

/* ----- Header ----- */

.header {
    background-color: var(--bg-beige);
    height: var(--header-height);
    padding: 0 5%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    transition: var(--transition-smooth);
}

.logo img {
    height: 70px;
    width: auto;
}

.desktop-nav {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.desktop-nav a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    text-transform: uppercase;
    font-size: 1.5rem;
}

#lang-switch {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
}

.hamburger {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* ----- Main content ----- */

body {
  font-family: 'Serif', 'Libre Baskerville', serif;
  background-color: var(--white);
  color: var(--text-dark);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { 
    flex: 1; 
    padding-top: var(--header-height);
}

/* ----- Footer ----- */

.main-footer {
    border-top: 3px solid var(--text-dark);
    background-color: var(--bg-beige);
    padding: 1rem 5%;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: start;
    gap: 2rem;
    margin-top: auto;
}

.footer-section h3 {
    text-transform: uppercase;
    font-size: 1.1rem;
}

.footer-logo img {
    height: 75px;
}

.footer-section:last-child {
    text-align: right;
}

.footer-section a {
    color: var(--text-dark);
    text-decoration: underline;
}

/* ----- For thinner screens ----- */

@media (max-width: 780px) {
    /* --- Header & Nav --- */
    .hamburger {
        display: block; /* Show hamburger */
        z-index: 1001;

        /* iOS styling */
        color: var(--text-dark); /* Force custom dark brown */
        -webkit-appearance: none; /* Strip Apple's default button styling */
        appearance: none;
        -webkit-tap-highlight-color: transparent;
    }

    .desktop-nav {
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 2rem;
        
        position: fixed;
        top: 0;
        right: -100%; 
        width: 80%;
        height: 100vh;
        
        /* --- Transparency Logic --- */
        background-color: rgba(184, 169, 154, 0.8); 
        
        backdrop-filter: blur(8px); 
        -webkit-backdrop-filter: blur(8px); /* Safari support */
        
        transition: var(--transition-smooth);
        box-shadow: -5px 0 15px rgba(0,0,0,0.1);
        z-index: 1000;
    }

    .desktop-nav.active {
        right: 0;
    }

    /* --- Footer (Vertical Stack) --- */
    .main-footer {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }

    /* Reordering the footer: Logo first, then Info, then Autres */
    .footer-logo {
        grid-row: 1; 
    }
    .footer-section:first-child {
        grid-row: 2;
    }
    .footer-section:last-child {
        grid-row: 3;
        text-align: center;
    }
}