/* =========================
   VARIABLES
========================= */

:root {
    --brand-color: #9e8f3d;
    --dark: #111;
    --light-gray: #f5f5f5;
    --max-width: 1300px;
}

/* =========================
   BASE
========================= */

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
    background: white;
    color: var(--dark);
    line-height: 1.6;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 30px;
}

section {
    padding: 120px 0;
    scroll-margin-top: 100px;
}

h1, h2 {
    font-weight: 600;
    letter-spacing: 1px;
}

h2 {
    text-align: center;
    margin-bottom: 50px;
    position: relative;
}

h2::after {
    content: "";
    width: 60px;
    height: 2px;
    background: var(--brand-color);
    display: block;
    margin: 20px auto 0;
}

/* =========================
   HEADER
========================= */

.site-header {
    position: absolute;
    width: 100%;
    top: 0;
    z-index: 50;
    padding: 25px 0;
    transition: all 0.3s ease;
}

.site-header.scrolled {
    background: white;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 60px;
    width: auto;
}

.logo a {
    text-decoration: none;
    color: #111;
}

/* =========================
   Menu
========================= */

.main-nav {
    display: block;
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 35px;
    margin: 0;
    padding: 0;
}

.main-nav a {
    text-decoration: none;
    font-size: 14px;
    color: white;
}

/* Burger icon */

/* =========================
   BURGER SIMPLE FIX
========================= */

.menu-toggle {
    display: none;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    z-index: 200;
    color: white;
}

/* Si header devient blanc au scroll */
.site-header.scrolled .menu-toggle {
    color: #111;
}

/* Overlay */

.menu-overlay {
    display: none;
}

/* =========================
   MOBILE
========================= */

@media (max-width: 992px) {

    .main-nav {
        position: fixed;
        top: 0;
        right: -280px;
        width: 280px;
        height: 100vh;
        background: white;
        padding-top: 120px;
        transition: 0.3s;
        display: block;
        z-index: 100;
    }

    .main-nav ul {
        flex-direction: column;
        gap: 25px;
        padding-left: 40px;
    }

    .main-nav a {
        color: #111;
        font-size: 16px;
    }

    .menu-toggle {
        display: block;
    }

    .menu-overlay {
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,0.4);
        display: block;
        opacity: 0;
        visibility: hidden;
        transition: 0.3s;
        z-index: 90;
    }

    body.menu-open .main-nav {
        right: 0;
    }

    body.menu-open .menu-overlay {
        opacity: 1;
        visibility: visible;
    }
}


/* =========================
   HERO
========================= */

.hero-video::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(20, 20, 20, 0.55); /* sombre mais pas noir pur */
    z-index: 1;
}

.hero-overlay {
    position: relative;
    z-index: 2;
    color: white;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 20px;
}


.hero-video {
    position: relative;
    height: 100vh;
    overflow: hidden;
}

.hero-video video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    transform: translate(-50%, -50%);
    object-fit: cover;
}

.hero-overlay h1 {
    font-size: 48px;
    margin-bottom: 20px;
}

.hero-overlay p {
    font-size: 18px;
    letter-spacing: 2px;
    margin-bottom: 30px;
}

.btn-primary {
    background: var(--brand-color);
    color: white;
    padding: 14px 40px;
    text-decoration: none;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: 0.3s;
}

.btn-primary:hover {
    background: #85772d;
}

/* =========================
   SECTIONS
========================= */

.presentation-section,
.service-section,
.achat-vente-section,
.second-branch {
    max-width: 900px;
    margin: auto;
    text-align: center;
}

.vehicles-section,
.partners-section {
    background: var(--light-gray);
}

.placeholder {
    padding: 100px;
    background: white;
    text-align: center;
    border: 1px solid #eee;
}

/* =========================
   PARTENAIRES
========================= */

.partners-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 50px;
    align-items: center;
    text-align: center;
}

.partners-grid div {
    font-weight: 600;
    opacity: 0.7;
    transition: 0.3s;
}

.partners-grid div:hover {
    opacity: 1;
    color: var(--brand-color);
}


.partners-grid img {
    max-height: 40px;      /* hauteur max uniforme */
    width: auto;           /* conserve proportions */
    max-width: 120px;      /* évite logos trop larges */
    object-fit: contain;   /* sécurité si SVG bizarre */
    display: block;
    margin: 0 auto;
}

/* =========================
   FOOTER
========================= */

.site-footer {
    background: #111;
    color: white;
    padding: 50px 0;
    text-align: center;
    font-size: 14px;
}

/* =========================
   RESPONSIVE
========================= */

@media (max-width: 992px) {

    section {
        padding: 80px 0;
    }

    .hero-overlay h1 {
        font-size: 28px;
    }

    .hero-overlay p {
        font-size: 14px;
    }

    .main-nav {
        position: fixed;
        top: 0;
        right: -100%;
        height: 100vh;
        width: 260px;
        background: white;
        padding-top: 120px;
        transition: 0.3s;
    }

    .main-nav ul {
        flex-direction: column;
        gap: 25px;
        padding-left: 30px;
    }

    .main-nav a {
        color: #111;
        font-size: 16px;
    }

    .main-nav.active {
        right: 0;
    }

    .menu-toggle {
        display: block;
    }

    .partners-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}


.branch-content {
    display:flex;
    align-items:center;
    gap:60px;
    margin-top:40px;
}

.branch-logo img {
    max-width:220px;
    height:auto;
}

.branch-text {
    max-width:600px;
}

.branch-link {
    display:inline-block;
    margin-top:20px;
    padding:12px 30px;
    border:1px solid var(--brand-color);
    color:var(--brand-color);
    text-decoration:none;
    transition:0.3s;
    font-weight:600;
}

.branch-link:hover {
    background:var(--brand-color);
    color:white;
}

/* Mobile */

@media (max-width: 768px) {
    .branch-content {
        flex-direction:column;
        text-align:center;
    }
}
