/* ==========================================================================
   Aguilar Automobiles — feuille de style publique
   Noir profond, typographie large et grasse (comme le logo), couleur d'accent choisie dans l'admin (variables --accent*).
   ========================================================================== */

:root {
    --bg: #0a0a0a;
    --bg-2: #111111;
    --bg-3: #191919;
    --line: #262626;
    --line-2: #353535;
    --text: #f3f2ee;
    --muted: #9b9a95;
    --accent: #ff5b1f;
    --accent-hover: #ff7442;
    --accent-ink: #0a0a0a;
    --success: #39c46e;
    --warning: #f2b33d;
    --danger: #ff4d4d;

    --font: "Saira", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --radius: 4px;
    --container: 1320px;
    --gutter: clamp(16px, 4vw, 40px);
    --header-h: 76px;
    --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 17px;
    line-height: 1.6;
    font-stretch: 100%;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
a:hover { color: var(--accent); }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--accent); color: var(--accent-ink); padding: 8px 14px; }
.skip-link:focus { left: 8px; }
.text-accent { color: var(--accent); }
.text-muted { color: var(--muted); }
.plain-list { list-style: none; margin: 0; padding: 0; }

/* ---------- Typographie « fat » ---------- */

.display, .display-sm, .h-xxl, .h-xl, .h-lg, .h-md, .kicker, .btn, .nav-link, .footer-title,
.vcard-title, .vcard-price, .service-num, .service-title, .vehicle-price, .field-label, .badge {
    font-stretch: 125%;
    font-style: italic;
    text-transform: uppercase;
}

.display {
    font-size: clamp(2.8rem, min(8vw, 11vh), 6.8rem);
    font-weight: 900;
    line-height: .88;
    letter-spacing: -.02em;
    margin: 0;
}
.display-long { font-size: clamp(1.6rem, min(4.2vw, 6vh), 3.6rem); }
.display-sm { font-size: clamp(2.2rem, 6vw, 4.8rem); font-weight: 900; line-height: .92; letter-spacing: -.015em; margin: 0; }
.h-xxl { font-size: clamp(2rem, 5.6vw, 4.4rem); font-weight: 900; line-height: .92; letter-spacing: -.015em; margin: 0; }
.h-xl  { font-size: clamp(1.9rem, 4.4vw, 3.4rem); font-weight: 900; line-height: .95; letter-spacing: -.01em; margin: 0; }
.h-lg  { font-size: clamp(1.25rem, 2.2vw, 1.6rem); font-weight: 800; line-height: 1.1; margin: 0 0 .9em; }
.h-md  { font-size: 1.35rem; font-weight: 800; line-height: 1.15; margin: 0 0 .4em; }

.kicker {
    display: inline-flex;
    align-items: center;
    gap: .6em;
    margin: 0 0 1rem;
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: .22em;
    color: var(--accent);
}
.kicker::before { content: ""; width: 28px; height: 3px; background: currentColor; transform: skewX(-20deg); }

/* ---------- Boutons ---------- */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .55em;
    min-height: 48px;
    padding: .7em 1.5em;
    border: 2px solid transparent;
    border-radius: var(--radius);
    font-size: .92rem;
    font-weight: 800;
    letter-spacing: .06em;
    text-decoration: none;
    line-height: 1.1;
    cursor: pointer;
    transition: background .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease), transform .2s var(--ease);
    white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-sm { min-height: 40px; padding: .5em 1.1em; font-size: .82rem; }
.btn-lg { min-height: 56px; padding: .8em 1.9em; font-size: 1rem; }
.btn-block { width: 100%; }
.btn-accent { background: var(--accent); color: var(--accent-ink); }
.btn-accent:hover { background: var(--accent-hover); color: var(--accent-ink); }
.btn-ghost { border-color: var(--line-2); color: var(--text); background: transparent; }
.btn-ghost:hover { border-color: var(--text); color: var(--text); }
.btn-light { background: var(--text); color: var(--bg); }
.btn-light:hover { background: #fff; color: var(--bg); }
.btn-outline-light { border-color: color-mix(in srgb, var(--accent-ink) 35%, transparent); color: var(--accent-ink); }
.btn-outline-light:hover { border-color: var(--accent-ink); color: var(--accent-ink); }
.btn-count { display: inline-grid; place-items: center; min-width: 1.8em; height: 1.8em; padding: 0 .4em; border-radius: 99px; background: var(--accent-ink); color: var(--accent); font-size: .8em; font-style: normal; }

.link-arrow {
    display: inline-flex; align-items: center; gap: .5em;
    font-weight: 700; font-stretch: 125%; font-style: italic; text-transform: uppercase; letter-spacing: .08em; font-size: .85rem;
    text-decoration: none; color: var(--text);
}
.link-arrow::after { content: "→"; font-style: normal; transition: transform .2s var(--ease); }
.link-arrow:hover::after { transform: translateX(4px); }

/* ---------- En-tête ---------- */

.site-header {
    position: sticky; top: 0; z-index: 50;
    height: var(--header-h);
    background: rgba(10,10,10,.82);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid transparent;
    transition: border-color .3s, background .3s;
}
.site-header.is-scrolled { border-bottom-color: var(--line); background: rgba(10,10,10,.94); }
.page-home .site-header { position: fixed; left: 0; right: 0; background: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; }
.page-home .site-header.is-scrolled { background: rgba(10,10,10,.92); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }

.header-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; flex-shrink: 0; }
.brand-mark { height: 38px; width: auto; }
/* Nom du garage dans l'en-tête, dans la police du logo (Bai Jamjuree, uniquement ici) */
.brand-name {
    font-family: 'Bai Jamjuree', 'Saira', sans-serif; font-weight: 700; font-style: italic;
    font-size: 14px; line-height: 1.15; letter-spacing: .28em; text-transform: uppercase;
    color: #fff; white-space: nowrap;
}
/* petit écran : « AGUILAR » au-dessus d'« AUTOMOBILES » pour ne jamais toucher le bouton menu */
@media (max-width: 599px) {
    .brand-name { font-size: 14px; letter-spacing: .25em; }
    .brand-name > span { display: block; }
}

.site-nav { display: flex; align-items: center; gap: clamp(14px, 2.4vw, 34px); }
.nav-link {
    position: relative; text-decoration: none;
    font-size: .85rem; font-weight: 800; letter-spacing: .08em;
    padding: 6px 0;
}
.nav-link::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px;
    background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .25s var(--ease);
}
.nav-link:hover, .nav-link.is-active { color: var(--text); }
.nav-link:hover::after, .nav-link.is-active::after { transform: scaleX(1); }
.nav-cta svg { flex-shrink: 0; }

/* Sous-menu « Atelier » */
.nav-group { position: relative; }
.nav-group-btn { display: inline-flex; align-items: center; gap: 7px; background: none; border: 0; color: inherit; cursor: pointer; font-family: inherit; }
.nav-group-btn svg { transition: transform .2s var(--ease); }
.nav-sub {
    position: absolute; top: calc(100% + 14px); left: -18px; min-width: 250px;
    display: grid; padding: 8px; background: var(--bg-2); border: 1px solid var(--line-2); border-radius: var(--radius);
    box-shadow: 0 18px 40px rgba(0,0,0,.5);
    opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity .18s, transform .18s var(--ease), visibility .18s;
}
.nav-sub::before { content: ""; position: absolute; left: 0; right: 0; top: -16px; height: 16px; }
.nav-group:hover .nav-sub, .nav-group:focus-within .nav-sub, .nav-group.is-open .nav-sub { opacity: 1; visibility: visible; transform: none; }
.nav-group:hover .nav-group-btn svg, .nav-group.is-open .nav-group-btn svg { transform: rotate(180deg); }
.nav-sub-link { padding: 10px 14px; border-radius: 3px; text-decoration: none; font-weight: 700; font-size: .95rem; color: #d6d5d0; }
.nav-sub-link:hover, .nav-sub-link.is-active { background: var(--bg-3); color: var(--accent); }

.nav-toggle { display: none; }

@media (max-width: 900px) {
    /* logo complet aussi sur mobile et tablette (symbole + « Aguilar Automobiles ») */
    .brand { gap: 10px; min-width: 0; flex-shrink: 1; }
    .brand-mark { height: 34px; }
    .nav-toggle {
        display: grid; gap: 6px; place-content: center;
        width: 46px; height: 46px; background: none; border: 1px solid var(--line-2); border-radius: var(--radius); cursor: pointer;
    }
    .nav-toggle span:not(.sr-only) { display: block; width: 20px; height: 2px; background: var(--text); transition: transform .25s var(--ease); }
    .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(4px) rotate(45deg); }
    .nav-toggle[aria-expanded="true"] span:nth-child(2) { transform: translateY(-4px) rotate(-45deg); }
    /* Menu plein écran : le flou de l'en-tête crée un bloc conteneur pour les éléments fixes,
       on le coupe pendant que le menu est ouvert pour que le menu couvre bien tout l'écran. */
    .site-header.menu-open,
    .page-home .site-header.menu-open { background: var(--bg); backdrop-filter: none; -webkit-backdrop-filter: none; border-bottom-color: transparent; }
    .brand, .nav-toggle { position: relative; z-index: 3; }
    /* bandeau opaque + dégradé derrière le logo : le texte du menu s'y efface en défilant au lieu de passer dessous */
    .site-header.menu-open::before {
        content: ""; position: fixed; top: 0; left: 0; right: 0; z-index: 2; pointer-events: none;
        height: calc(var(--header-h) + 28px);
        background: linear-gradient(to bottom, var(--bg) var(--header-h), rgba(10, 10, 10, 0));
    }
    .site-nav {
        position: fixed; inset: 0; z-index: 1;
        height: 100vh; height: 100dvh;
        flex-direction: column; align-items: stretch; gap: 0;
        padding: calc(var(--header-h) + 16px) var(--gutter) max(28px, env(safe-area-inset-bottom));
        background: var(--bg);
        overflow-y: auto; overscroll-behavior: contain;
        transform: translateY(-12px); opacity: 0; visibility: hidden;
        transition: opacity .25s, transform .25s var(--ease), visibility .25s;
    }
    .site-nav.is-open { opacity: 1; visibility: visible; transform: none; }
    .nav-link { font-size: clamp(1.3rem, 5.6vw, 1.75rem); font-style: italic; letter-spacing: -.01em; padding: 13px 0; border-bottom: 1px solid var(--line); }
    .nav-link::after { display: none; }
    .nav-cta { margin-top: auto; min-height: 58px; font-size: 1.05rem; }
    .nav-group-btn { width: 100%; justify-content: space-between; text-align: left; }
    .nav-group-btn svg { display: none; }
    .nav-sub { position: static; opacity: 1; visibility: visible; transform: none; min-width: 0; padding: 4px 0 10px 14px; background: none; border: 0; box-shadow: none; border-bottom: 1px solid var(--line); border-radius: 0; }
    .nav-sub::before { display: none; }
    .nav-sub-link { padding: 8px 0; font-size: .98rem; }
    .nav-sub-link:hover, .nav-sub-link.is-active { background: none; }
}
/* tablette : logo à la même taille que sur ordinateur */
@media (min-width: 600px) and (max-width: 900px) {
    .brand { gap: 14px; }
    .brand-mark { height: 38px; }
}
@media (min-width: 901px) and (max-width: 1080px) { .nav-cta { font-size: 0; gap: 0; padding-inline: 12px; } .nav-cta svg { width: 18px; height: 18px; } }

/* ---------- Hero ---------- */

.hero {
    position: relative;
    min-height: min(100svh, 980px);
    display: flex; align-items: flex-start;
    padding: calc(var(--header-h) + clamp(32px, 7vh, 80px)) 0 clamp(48px, 8vw, 96px);
    isolation: isolate;
    overflow: hidden;
}
.hero-media { position: absolute; left: 0; right: 0; bottom: 0; height: 72%; z-index: -1; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 100%; transform: scale(1.04); animation: heroZoom 14s var(--ease) forwards; }
.hero::after {
    content: ""; position: absolute; inset: 0; z-index: -1;
    background:
        linear-gradient(180deg, var(--bg) 0%, var(--bg) 28%, rgba(10,10,10,.55) 44%, rgba(10,10,10,0) 62%, rgba(10,10,10,0) 90%, var(--bg) 100%),
        linear-gradient(90deg, rgba(10,10,10,.6) 0%, rgba(10,10,10,0) 50%);
}
@keyframes heroZoom { to { transform: scale(1); } }
.hero-content { max-width: var(--container); }
.hero .display { max-width: 14ch; text-shadow: 0 4px 40px rgba(0,0,0,.35); }
.hero .display-long { max-width: 17ch; }

/* Frise « Notre histoire » */
.timeline { list-style: none; margin: 0; padding: 0; display: grid; }
.timeline-item {
    display: grid; grid-template-columns: minmax(0, 15rem) minmax(0, 1fr); gap: clamp(16px, 4vw, 56px);
    padding: clamp(28px, 4vw, 48px) 0; border-top: 1px solid var(--line);
}
.timeline-item:last-child { border-bottom: 1px solid var(--line); }
.timeline-year {
    font-size: clamp(2.6rem, 6vw, 4.6rem); font-weight: 900; font-style: italic; font-stretch: 125%;
    line-height: .9; letter-spacing: -.02em; color: var(--accent); text-transform: uppercase;
}
.timeline-year-word { font-size: clamp(1.4rem, 2.1vw, 1.9rem); white-space: nowrap; }
.timeline-gen { display: block; margin-top: 10px; font-size: .8rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.timeline-item h2 { margin-bottom: 12px; }
.timeline-item p { margin: 0; max-width: 60ch; color: #c9c8c3; }
@media (max-width: 640px) { .timeline-item { grid-template-columns: 1fr; gap: 10px; } }
.hero-lead { max-width: 560px; margin: 24px 0 30px; font-size: clamp(1.02rem, 1.6vw, 1.2rem); color: #dcdbd6; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-actions .btn-ghost { background: rgba(10,10,10,.55); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }

/* Mobile : plein écran. svh = hauteur avec la barre d'adresse visible, pour que
   l'écran d'accueil ne saute pas quand la barre se replie au défilement. */
@media (max-width: 640px) {
    .hero {
        min-height: 100vh; /* navigateurs anciens */
        min-height: 100svh;
        align-items: stretch;
        padding-bottom: max(28px, env(safe-area-inset-bottom));
    }
    .hero-media { top: 0; height: 100%; }
    .hero-media img { object-position: 30% 75%; }
    .hero::after {
        background: linear-gradient(180deg, var(--bg) 0%, rgba(10,10,10,.92) 30%, rgba(10,10,10,.35) 52%, rgba(10,10,10,.15) 70%, rgba(10,10,10,.85) 100%);
    }
    .hero-content { display: flex; flex-direction: column; width: 100%; }
    .hero-actions { margin-top: auto; }
    .hero-actions .btn { flex: 1 1 100%; }
}
@media (prefers-reduced-motion: reduce) {
    .hero-media img { animation: none; }
}

/* ---------- Sections ---------- */

.section { padding: clamp(64px, 10vw, 128px) 0; }
.section-tight { padding-top: clamp(32px, 5vw, 56px); }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px 48px; flex-wrap: wrap; margin-bottom: clamp(32px, 5vw, 56px); }
.section-intro { max-width: 440px; margin: 0; color: var(--muted); }

.page-hero { padding: clamp(56px, 9vw, 110px) 0 clamp(24px, 4vw, 40px); border-bottom: 1px solid var(--line); background: radial-gradient(1200px 400px at 85% 0%, color-mix(in srgb, var(--accent) 11%, transparent), transparent 60%); }
.page-hero-lead { margin: 20px 0 0; color: var(--muted); font-size: 1.1rem; }
.page-hero-error { min-height: 60vh; }
.page-hero-error .btn { margin: 28px 8px 0 0; }

/* ---------- Cartes véhicules ---------- */

.vgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: clamp(16px, 2vw, 28px); }

.vcard { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: border-color .25s, transform .25s var(--ease); }
.vcard:hover { border-color: var(--line-2); transform: translateY(-4px); }
.vcard-link { display: flex; flex-direction: column; height: 100%; text-decoration: none; color: inherit; }
.vcard-link:hover { color: inherit; }
.vcard-media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--bg-3); }
.vcard-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.vcard:hover .vcard-media img { transform: scale(1.05); }
.vcard-count { position: absolute; right: 12px; bottom: 12px; padding: 3px 9px; border-radius: 3px; background: rgba(10,10,10,.75); font-size: .75rem; font-weight: 600; }
.vcard-body { display: flex; flex-direction: column; flex: 1; padding: 20px 22px 22px; }
.vcard-title { margin: 0; font-size: 1.45rem; font-weight: 900; line-height: 1.02; }
.vcard-brand { display: block; font-size: .72rem; letter-spacing: .2em; color: var(--muted); font-weight: 700; margin-bottom: 4px; }
.vcard-version { margin: 6px 0 0; color: var(--muted); font-size: .92rem; line-height: 1.35; }
.vcard-specs { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 16px 0 0; padding: 0; }
.vcard-specs li { padding: 3px 10px; border: 1px solid var(--line-2); border-radius: 99px; font-size: .8rem; color: #cfcec9; }
.vcard-price { margin: auto 0 0; padding-top: 18px; font-size: 1.6rem; font-weight: 900; color: var(--accent); line-height: 1; }
.vcard.is-reserve .vcard-media img, .vcard.is-vendu .vcard-media img { filter: grayscale(.6) brightness(.75); }

.badge { position: absolute; left: 12px; top: 12px; padding: 5px 11px; border-radius: 3px; font-size: .72rem; font-weight: 800; letter-spacing: .1em; }
.badge-featured { background: var(--accent); color: var(--accent-ink); }
.badge-reserve { background: var(--warning); color: #1a1200; }
.badge-vendu { background: var(--text); color: var(--bg); }
.badge-lg { font-size: .9rem; padding: 8px 16px; left: 16px; top: 16px; }

.empty-state { padding: clamp(40px, 7vw, 80px); text-align: center; border: 1px dashed var(--line-2); border-radius: var(--radius); }
.empty-state p { color: var(--muted); max-width: 520px; margin-inline: auto; }
.empty-state .h-md { color: var(--text); }
.empty-state .btn { margin-top: 12px; }

/* ---------- Services ---------- */

.section-services { background: var(--bg-2); border-block: 1px solid var(--line); }
.services { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.service a { display: block; text-decoration: none; color: inherit; }
.service-media { aspect-ratio: 4 / 5; overflow: hidden; border-radius: var(--radius); margin-bottom: 18px; background: var(--bg-3); }
.service-media img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(.35) contrast(1.05); transition: transform .6s var(--ease), filter .4s; }
.service a:hover .service-media img { transform: scale(1.05); filter: none; }
.service-num { display: block; font-size: .85rem; font-weight: 800; color: var(--accent); letter-spacing: .1em; }
.service-title { margin: 4px 0 8px; font-size: 1.3rem; font-weight: 900; line-height: 1.05; }
.service-text { margin: 0; color: var(--muted); font-size: .95rem; line-height: 1.5; }
@media (max-width: 1100px) { .services { grid-template-columns: repeat(3, 1fr); row-gap: 40px; } }
@media (max-width: 720px) {
    .services { grid-template-columns: 1fr; }
    .service a { display: grid; grid-template-columns: 120px 1fr; gap: 4px 18px; align-items: start; }
    .service-media { grid-row: span 3; margin: 0; aspect-ratio: 1; }
}

/* ---------- Atelier ---------- */

.atelier { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(40px, 7vw, 110px); align-items: center; }
.atelier-media { position: relative; padding: 0 12% 12% 0; }
.atelier-main { border-radius: var(--radius); aspect-ratio: 4 / 5; object-fit: cover; width: 100%; }
.atelier-detail { position: absolute; right: 0; bottom: 0; width: 44%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--radius); border: 6px solid var(--bg); }
.atelier-text p:not(.kicker) { color: #cfcec9; max-width: 520px; }
.atelier-text .h-xl { margin-bottom: 28px; }
.checks { list-style: none; padding: 0; margin: 28px 0 34px; display: grid; gap: 12px; }
.checks li { display: flex; gap: 14px; align-items: baseline; font-weight: 600; }
.checks li::before { content: ""; flex: 0 0 14px; height: 8px; background: var(--accent); transform: skewX(-20deg); }
@media (max-width: 860px) { .atelier { grid-template-columns: 1fr; } }

/* ---------- Bandeau CTA ---------- */

.cta-band { background: var(--accent); color: var(--accent-ink); padding: clamp(56px, 8vw, 100px) 0; }
.cta-band .text-accent { color: var(--accent-ink); opacity: .75; } /* >= 3:1 (grand texte) pour toutes les couleurs proposées */
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.cta-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.cta-band .btn-light { background: var(--accent-ink); color: var(--accent); }
.cta-band .btn-light:hover { background: var(--accent-ink); color: var(--accent); opacity: .88; }

/* ---------- Filtres ---------- */

.filters {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(145px, 1fr)); gap: 14px;
    padding: 20px; margin-bottom: 36px;
    background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius);
}
.filters-actions { display: flex; gap: 10px; align-items: flex-end; }
.filters-actions .btn { flex: 1; }
.js .filters-actions .btn-accent { display: none; }
.js .filters-actions:not(:has(a)) { display: none; }
.filters-bar { display: none; }

/* Mobile : filtres repliés derrière un bouton « Filtrer et trier » */
@media (max-width: 700px) {
    .js .filters-bar { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; }
    .js .filters-toggle { flex: 1; justify-content: center; gap: 10px; }
    .js .filters-toggle[aria-expanded="true"] { border-color: var(--accent); }
    .filters-toggle .btn-count { background: var(--accent); color: var(--accent-ink); }
    .filters-reset { color: var(--muted); font-size: .9rem; white-space: nowrap; }
    .js .filters { display: none; grid-template-columns: 1fr 1fr; align-items: end; margin-bottom: 28px; }
    .js .filters.is-open { display: grid; }
    .js .filters .field:last-of-type { grid-column: 1 / -1; } /* « Trier par » sur toute la largeur */
    .js .filters-actions, .js .filters-actions:not(:has(a)) { display: flex; grid-column: 1 / -1; }
    .js .filters-actions .btn-accent { display: inline-flex; }
    .js .filters-actions .btn-ghost { display: none; } /* « Tout effacer » est déjà dans la barre */
}

/* ---------- Formulaires ---------- */

.field { display: flex; flex-direction: column; gap: 6px; }
.field-label { font-size: .72rem; font-weight: 700; letter-spacing: .14em; color: var(--muted); }
.field input, .field select, .field textarea {
    width: 100%; min-height: 48px; padding: 11px 14px;
    background: var(--bg); border: 1px solid var(--line-2); border-radius: var(--radius);
    font-size: 1rem; transition: border-color .2s;
}
.field textarea { resize: vertical; min-height: 140px; line-height: 1.5; }
.field select {
    appearance: none; -webkit-appearance: none; padding-right: 38px; cursor: pointer;
    background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
    background-position: calc(100% - 20px) 52%, calc(100% - 15px) 52%;
    background-size: 5px 5px; background-repeat: no-repeat;
}
.field select option { background: var(--bg-2); }
.field input:hover, .field select:hover, .field textarea:hover { border-color: #4a4a4a; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.has-error input, .has-error textarea, .has-error select { border-color: var(--danger); }
.field-error { color: var(--danger); font-size: .88rem; }

.form { display: grid; gap: 18px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 600px) { .form-row { grid-template-columns: 1fr; } }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: .9rem; color: var(--muted); cursor: pointer; }
.check input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--accent); flex-shrink: 0; }
.check.has-error span { color: var(--danger); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.alert { margin: 20px 0; padding: 14px 18px; border-radius: var(--radius); border: 1px solid; font-weight: 500; }
.alert-success { border-color: rgba(57,196,110,.45); background: rgba(57,196,110,.1); }
.alert-error { border-color: rgba(255,77,77,.45); background: rgba(255,77,77,.1); }
.alert-info { border-color: var(--line-2); background: var(--bg-2); }

/* ---------- Pagination ---------- */

.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 48px; flex-wrap: wrap; }
.page-link { display: grid; place-items: center; min-width: 46px; height: 46px; border: 1px solid var(--line-2); border-radius: var(--radius); text-decoration: none; font-weight: 700; }
.page-link.is-active { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }

/* ---------- Fiche véhicule ---------- */

.admin-bar { background: var(--warning); color: #1a1200; padding: 10px 0; font-size: .9rem; }
.admin-bar a { font-weight: 700; }
.vehicle-page { padding: 28px 0 clamp(48px, 7vw, 90px); }
.breadcrumb { display: flex; flex-wrap: wrap; gap: 8px; font-size: .85rem; color: var(--muted); margin-bottom: 24px; }
.breadcrumb a { text-decoration: none; }
.breadcrumb span[aria-current] { color: var(--text); }

.vehicle-layout { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(320px, 1fr); gap: clamp(24px, 4vw, 56px); align-items: start; }
@media (max-width: 960px) { .vehicle-layout { grid-template-columns: 1fr; } }

.gallery-main { position: relative; aspect-ratio: 4 / 3; background: var(--bg-2); border-radius: var(--radius); overflow: hidden; }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.gallery-main-btn { display: block; width: 100%; height: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; }
.gallery-nav {
    position: absolute; top: 50%; transform: translateY(-50%);
    width: 52px; height: 52px; border: 0; border-radius: 50%;
    background: rgba(10,10,10,.65); color: var(--text); font-size: 2rem; line-height: 1; cursor: pointer;
    display: grid; place-items: center; padding-bottom: 4px; transition: background .2s;
}
.gallery-nav:hover { background: var(--accent); color: var(--accent-ink); }
.gallery-nav.prev { left: 14px; }
.gallery-nav.next { right: 14px; }
.gallery-counter { position: absolute; right: 14px; bottom: 14px; padding: 4px 10px; background: rgba(10,10,10,.75); border-radius: 3px; font-size: .82rem; font-weight: 600; }
.gallery-thumbs { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(96px, 1fr); gap: 8px; margin-top: 8px; overflow-x: auto; scrollbar-width: thin; }
.gallery-thumb { padding: 0; border: 2px solid transparent; border-radius: var(--radius); overflow: hidden; background: var(--bg-2); cursor: pointer; aspect-ratio: 4 / 3; opacity: .6; transition: opacity .2s, border-color .2s; }
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumb:hover { opacity: 1; }
.gallery-thumb.is-active { border-color: var(--accent); opacity: 1; }

.vehicle-aside { position: sticky; top: calc(var(--header-h) + 20px); }
.vehicle-summary { padding: clamp(22px, 3vw, 34px); background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); }
.vehicle-summary .kicker { margin-bottom: .6rem; }
.vehicle-title { word-break: break-word; }
.vehicle-version { margin: 10px 0 0; color: var(--muted); }
.vehicle-keys { list-style: none; padding: 0; margin: 24px 0; display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.vehicle-keys li { background: var(--bg-2); padding: 12px 14px; font-weight: 700; }
.vehicle-keys span { display: block; font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.vehicle-price { margin: 0; font-size: clamp(2.2rem, 4vw, 3rem); font-weight: 900; line-height: 1; color: var(--accent); }
.vehicle-warranty { margin: 10px 0 0; font-weight: 600; color: var(--success); }
.vehicle-ctas { display: grid; gap: 10px; margin-top: 24px; }

.vehicle-details { display: grid; grid-template-columns: 1.4fr 1fr; gap: clamp(32px, 5vw, 80px); margin-top: clamp(48px, 6vw, 80px); padding-top: clamp(40px, 5vw, 64px); border-top: 1px solid var(--line); }
@media (max-width: 860px) { .vehicle-details { grid-template-columns: 1fr; } }
.prose { color: #d6d5d0; max-width: 70ch; }
.prose + .h-lg, .equipment + .h-lg { margin-top: 40px; }
.equipment { list-style: none; padding: 0; margin: 0 0 40px; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px 24px; }
.equipment li { display: flex; gap: 10px; align-items: baseline; color: #d6d5d0; }
.equipment li::before { content: ""; flex: 0 0 10px; height: 6px; background: var(--accent); transform: skewX(-20deg) translateY(-2px); }
.specs { margin: 0; }
.specs div { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.specs dt { color: var(--muted); }
.specs dd { margin: 0; font-weight: 700; text-align: right; }

.vehicle-contact { display: grid; grid-template-columns: 1fr 1.2fr; gap: clamp(32px, 5vw, 80px); margin-top: clamp(56px, 7vw, 96px); padding: clamp(28px, 5vw, 64px); background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); }
.vehicle-contact p:not(.kicker) { color: var(--muted); }
.vehicle-contact .h-xl { margin-bottom: 18px; }
@media (max-width: 860px) { .vehicle-contact { grid-template-columns: 1fr; } }

.lightbox { width: 100vw; height: 100vh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(5,5,5,.96); }
.lightbox[open] { display: grid; place-items: center; }
.lightbox::backdrop { background: rgba(0,0,0,.9); }
.lightbox img { max-width: 94vw; max-height: 88vh; object-fit: contain; }
.lightbox-close { position: absolute; top: 14px; right: 18px; width: 52px; height: 52px; border: 0; background: none; color: var(--text); font-size: 2.6rem; line-height: 1; cursor: pointer; }

/* ---------- Contact ---------- */

.contact-layout { display: grid; grid-template-columns: 1fr 1.3fr; gap: clamp(32px, 6vw, 96px); align-items: start; }
@media (max-width: 860px) { .contact-layout { grid-template-columns: 1fr; } }
.contact-info { display: grid; gap: 28px; }
.contact-big { display: block; text-decoration: none; font-size: clamp(1.3rem, 2.4vw, 1.8rem); font-weight: 900; font-stretch: 125%; font-style: italic; line-height: 1.15; word-break: break-word; }
.contact-big span, .contact-hours .field-label { display: block; margin-bottom: 6px; font-size: .72rem; letter-spacing: .14em; color: var(--muted); font-weight: 700; font-stretch: 125%; text-transform: uppercase; }
.contact-photo { border-radius: var(--radius); aspect-ratio: 16 / 10; object-fit: cover; width: 100%; }
.contact-form-wrap { padding: clamp(24px, 4vw, 48px); background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); }

.prose-legal h2 { font-size: 1.2rem; font-weight: 800; font-stretch: 125%; font-style: italic; text-transform: uppercase; margin: 40px 0 12px; color: var(--text); }
.prose-legal h2:first-child { margin-top: 0; }

/* ---------- Pages de services ---------- */

.svc-hero { position: relative; isolation: isolate; overflow: hidden; padding: clamp(40px, 6vw, 72px) 0 clamp(48px, 7vw, 96px); border-bottom: 1px solid var(--line); }
.svc-hero-media { position: absolute; inset: 0 0 0 36%; z-index: -1; -webkit-mask-image: linear-gradient(90deg, transparent 0%, rgba(0,0,0,.35) 18%, #000 45%); mask-image: linear-gradient(90deg, transparent 0%, rgba(0,0,0,.35) 18%, #000 45%); }
.svc-hero-media img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(.2) contrast(1.05); }
.svc-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, var(--bg) 0%, var(--bg) 40%, rgba(10,10,10,.55) 62%, rgba(10,10,10,.15) 100%), radial-gradient(900px 380px at 10% 0%, color-mix(in srgb, var(--accent) 12%, transparent), transparent 60%); }
.svc-hero-inner { min-height: clamp(380px, 52vh, 560px); display: flex; flex-direction: column; justify-content: center; }
.svc-hero .breadcrumb { margin-bottom: auto; padding-bottom: 32px; }
.svc-title { max-width: 16ch; }
.svc-lead { max-width: 560px; margin: 22px 0 30px; font-size: clamp(1.02rem, 1.6vw, 1.2rem); color: #dcdbd6; }
@media (max-width: 860px) {
    .svc-hero-media { inset: 0; opacity: .35; -webkit-mask-image: none; mask-image: none; }
    .svc-hero::after { background: linear-gradient(180deg, rgba(10,10,10,.6), var(--bg)); }
    .svc-hero .hero-actions .btn { flex: 1 1 100%; }
}

.svc-features { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.svc-features li { display: flex; gap: 14px; align-items: baseline; padding: 20px 22px; background: var(--bg-2); font-weight: 700; }
.svc-features li::before { content: ""; flex: 0 0 14px; height: 8px; background: var(--accent); transform: skewX(-20deg); }
@media (max-width: 860px) { .svc-features { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .svc-features { grid-template-columns: 1fr; } }

.svc-body { padding-top: clamp(24px, 4vw, 48px); }
.svc-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.svc-text .h-lg { margin-top: 44px; }
.svc-text .h-lg:first-child { margin-top: 0; }
.svc-text .prose p { margin: 0 0 1em; }
.svc-text .prose a, .local-seo .prose a { color: var(--accent); }
.svc-aside { position: sticky; top: calc(var(--header-h) + 20px); display: grid; gap: 16px; }
.svc-aside img { border-radius: var(--radius); aspect-ratio: 4 / 5; object-fit: cover; width: 100%; } /* format natif des photos : affichées en entier */
.svc-aside-card { padding: 22px; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); }
.svc-aside-card p:not(.kicker) { margin: 0 0 10px; color: #cfcec9; }
@media (max-width: 860px) { .svc-grid { grid-template-columns: 1fr; } .svc-aside { position: static; } }

.section-alt { background: var(--bg-2); border-block: 1px solid var(--line); }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(16px, 2vw, 28px); counter-reset: s; }
.step { position: relative; padding: 26px 24px 24px; background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); }
.step::after { content: ""; position: absolute; left: 24px; top: 0; width: 40px; height: 3px; background: var(--accent); transform: skewX(-20deg); }
.step-num { display: block; font-size: 2.4rem; font-weight: 900; font-style: italic; font-stretch: 125%; line-height: 1; color: var(--line-2); }
.step-title { margin: 14px 0 8px; font-size: 1.15rem; font-weight: 900; font-style: italic; font-stretch: 125%; text-transform: uppercase; line-height: 1.1; }
.step p { margin: 0; color: var(--muted); font-size: .95rem; }
@media (max-width: 1000px) { .steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }

.faq-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.faq { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item summary { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 22px 0; cursor: pointer; list-style: none; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; flex-shrink: 0; width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--line-2); border-radius: 50%; font-size: 1.3rem; color: var(--accent); transition: transform .2s var(--ease); }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item summary h3 { margin: 0; font-size: 1.08rem; font-weight: 700; line-height: 1.35; }
.faq-item summary:hover h3 { color: var(--accent); }
.faq-item p { margin: 0 0 24px; color: #cfcec9; max-width: 68ch; }
@media (max-width: 860px) { .faq-wrap { grid-template-columns: 1fr; } }

.related { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.related a { display: inline-flex; align-items: center; gap: 10px; padding: 12px 18px; border: 1px solid var(--line-2); border-radius: 99px; text-decoration: none; font-weight: 700; }
.related a::after { content: "→"; color: var(--accent); transition: transform .2s var(--ease); }
.related a:hover { border-color: var(--accent); color: var(--text); }
.related a:hover::after { transform: translateX(3px); }
.related-lg a { padding: 16px 24px; font-size: 1.05rem; }

.credit-notice { margin: 24px 0 0; padding: 14px 16px; border-left: 3px solid var(--line-2); background: rgba(255,255,255,.03); color: var(--muted); font-size: .8rem; line-height: 1.5; }
.finance-box { display: grid; gap: 4px; margin-top: 14px; padding: 18px 22px; border: 1px solid color-mix(in srgb, var(--accent) 45%, var(--line)); border-radius: var(--radius); background: color-mix(in srgb, var(--accent) 7%, var(--bg-2)); text-decoration: none; color: #cfcec9; font-size: .95rem; }
.finance-box:hover { border-color: var(--accent); color: #cfcec9; }
.finance-box-title { font-size: 1.15rem; font-weight: 900; font-style: italic; font-stretch: 125%; text-transform: uppercase; color: var(--accent); }
.finance-box .link-arrow { margin-top: 6px; color: var(--text); font-size: .8rem; }

.finance-teaser, .local-seo { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.finance-teaser p:not(.kicker):not(.credit-notice) { margin: 0 0 24px; color: #cfcec9; font-size: 1.08rem; }
.local-seo .prose p { margin: 0 0 1em; }
@media (max-width: 860px) { .finance-teaser, .local-seo { grid-template-columns: 1fr; } }

.towns { list-style: none; margin: 0 0 20px; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; }
.towns li { padding: 12px 16px; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); font-weight: 700; }

.vehicle-h1 { margin: 0; }
.vehicle-h1 .kicker { margin-bottom: .6rem; }
.vehicle-h1 .h-xl { display: block; }

.footer-pitch { margin-top: 20px !important; max-width: 280px; color: var(--muted) !important; font-size: .9rem !important; }
.footer-towns { color: var(--muted) !important; font-size: .9rem !important; }
.footer-title-gap { margin-top: 28px; }

/* ---------- Pied de page ---------- */

.site-footer { border-top: 1px solid var(--line); padding: clamp(56px, 8vw, 96px) 0 28px; background: var(--bg); }
.footer-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr 1fr; gap: 40px; }
.footer-brand img { width: 170px; }
.footer-title { font-size: .78rem; font-weight: 800; letter-spacing: .16em; color: var(--muted); margin: 0 0 16px; }
.site-footer p, .site-footer li { margin: 0 0 6px; color: #cfcec9; font-size: .95rem; }
.site-footer a { text-decoration: none; }
.footer-privacy { margin-top: 56px; font-size: .82rem; line-height: 1.6; color: var(--muted); }
.footer-privacy summary { cursor: pointer; list-style: none; }
.footer-privacy summary::-webkit-details-marker { display: none; }
.footer-privacy summary span { color: var(--text); text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 3px; white-space: nowrap; }
.footer-privacy summary:hover span, .footer-privacy summary:focus-visible span { color: var(--accent); }
.footer-privacy[open] summary span { display: none; }
.footer-privacy p { margin: 8px 0 0; max-width: 78ch; }
.footer-privacy strong { color: #cfcec9; font-weight: 600; }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 24px; padding-top: 24px; border-top: 1px solid var(--line); font-size: .85rem; color: var(--muted); }
.footer-credit a { color: var(--text); text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 3px; }
.footer-credit a:hover { color: var(--accent); }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- Apparition au défilement ---------- */

.js [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js [data-reveal].is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .js [data-reveal] { opacity: 1; transform: none; } }

/* Envoi de photos par lien temporaire (téléphone) */
.photo-upload { max-width: 640px; display: grid; gap: 18px; }
.photo-drop { display: grid; gap: 8px; padding: 22px; border: 2px dashed var(--line-2); border-radius: var(--radius); background: var(--bg-2); cursor: pointer; }
.photo-drop:focus-within { border-color: var(--accent); }
.photo-drop input { margin-top: 6px; color: var(--text); max-width: 100%; }
.photo-upload-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 8px; }
.photo-upload-grid img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius); }

/* Question anti-robot du formulaire de contact */
.field-captcha input { max-width: 160px; }
.captcha-question { display: block; margin: 2px 0 8px; font-weight: 600; color: var(--text); }

/* Formulaire : alerte et champs dans un seul bloc (pas de case de grille séparée) */
.contact-form-block { min-width: 0; align-self: start; }
.contact-form-block > .alert:first-child { margin-top: 0; }
