/* ==========================================================================
   MEN MOTORS — Design tokens
   Palette dérivée du logo : noir profond, or dégradé, blanc cassé.
   Display : Bebas Neue (poster automobile, condensé, franc)
   Corps   : Inter (lisible, neutre, ne fait pas d'ombre à l'or)
   Signature : l'arc de la silhouette du logo, répété comme séparateur
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=Inter:wght@400;500;600;700;800&display=swap');

:root {
  --black: #0a0a0b;
  --charcoal: #151517;
  --panel: #1c1c1f;
  --line: #2b2b2f;
  --gold-1: #c9a227;
  --gold-2: #e8c468;
  --gold-3: #f4dfa0;
  --gold-gradient: linear-gradient(120deg, var(--gold-1), var(--gold-2) 55%, var(--gold-3));
  --white: #f6f5f1;
  --muted: #a9a7a0;
  --success: #3c6b4f;
  --danger: #a4402f;
  --radius: 2px;
  --max-width: 1180px;
  --font-display: 'Bebas Neue', 'Arial Narrow', sans-serif;
  --font-body: 'Inter', -apple-system, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--black);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: 0.01em;
  margin: 0 0 0.4em;
  line-height: 1.05;
}

h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); }
h2 { font-size: clamp(1.9rem, 4vw, 2.8rem); }
h3 { font-size: 1.4rem; }

p { margin: 0 0 1em; color: var(--muted); }

.eyebrow {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold-2);
  display: inline-block;
  margin-bottom: 0.9em;
}

/* ---- Signature arc divider — echoes the logo's car-silhouette curve ---- */
.arc-divider {
  width: 100%;
  height: 40px;
  display: block;
  margin: 0 auto;
}
.arc-divider svg { width: 100%; height: 100%; }
.arc-divider path {
  fill: none;
  stroke: url(#goldStroke);
  stroke-width: 1.5;
}

/* ---------------------------- Buttons ---------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 14px 28px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:focus-visible { outline: 2px solid var(--gold-2); outline-offset: 2px; }

.btn-gold {
  background: var(--gold-gradient);
  color: var(--black);
}
.btn-gold:hover { box-shadow: 0 6px 22px rgba(201, 162, 39, 0.35); }

.btn-outline {
  background: transparent;
  border-color: var(--gold-1);
  color: var(--gold-2);
}
.btn-outline:hover { background: rgba(201, 162, 39, 0.08); }

.btn-block { width: 100%; justify-content: center; }

/* ---------------------------- Header ---------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 10, 11, 0.97);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  padding-bottom: 14px;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-mark {
  font-family: var(--font-display);
  font-size: 1.6rem;
  letter-spacing: 0.03em;
}
.brand-mark span { background: var(--gold-gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }

.brand-logo { height: 54px; width: auto; display: block; }
.footer-grid > div:first-child .brand-logo { height: 62px; margin-bottom: 4px; }

/* Le menu vit hors de l'en-tête dans le code (juste après </header>), pour ne
   jamais être piégé derrière le contenu sur mobile. Sur ordinateur, on le
   repositionne par-dessus l'en-tête avec position:fixed, aligné à droite. */
nav.main-nav {
  position: fixed;
  top: 0;
  right: max(24px, calc((100vw - 1180px) / 2 + 24px));
  height: 83px;
  display: flex;
  gap: 28px;
  align-items: center;
  z-index: 55;
  background: none;
}
nav.main-nav a {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 6px 0;
  border-bottom: 1px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}
nav.main-nav a:hover, nav.main-nav a.active { color: var(--white); border-color: var(--gold-1); }
.nav-toggle { display: none; }

@media (max-width: 780px) {
  nav.main-nav {
    top: 83px;
    right: 0;
    bottom: 0;
    left: 0;
    height: calc(100vh - 83px);
    background: var(--black);
    flex-direction: column;
    padding: 24px;
    gap: 4px;
    transform: translateY(-110%);
    transition: transform 0.25s ease;
    border-top: 1px solid var(--line);
    z-index: 150;
    overflow-y: auto;
  }
  nav.main-nav a { padding: 14px 4px; border-bottom: 1px solid var(--line); font-size: 0.95rem; }
  nav.main-nav.open { transform: translateY(0); }
  .nav-toggle {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    background: none;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    position: relative;
    z-index: 160;
    cursor: pointer;
  }
  .nav-toggle-bar {
    display: block;
    width: 18px;
    height: 2px;
    background: var(--white);
    border-radius: 2px;
    transition: transform 0.2s ease, opacity 0.2s ease, background 0.2s ease;
  }
  .nav-toggle[aria-expanded="true"] { border-color: var(--gold-1); }
  .nav-toggle[aria-expanded="true"] .nav-toggle-bar { background: var(--gold-2); }
  .nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}

/* ---------------------------- Hero ---------------------------- */
.hero {
  position: relative;
  padding: 90px 0 70px;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  top: -20%;
  right: -10%;
  width: 620px;
  height: 620px;
  background: radial-gradient(circle, rgba(201,162,39,0.14), transparent 70%);
  pointer-events: none;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
  position: relative;
}
.hero-copy p.lead { font-size: 1.1rem; max-width: 46ch; }
.hero-actions { display: flex; gap: 14px; margin-top: 28px; flex-wrap: wrap; }
.hero-stats { display: flex; gap: 32px; margin-top: 44px; flex-wrap: wrap; }
.hero-stats div strong {
  display: block;
  font-family: var(--font-display);
  font-size: 2rem;
  background: var(--gold-gradient); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-stats div span { font-size: 0.78rem; color: var(--muted); text-transform: uppercase; letter-spacing: 0.05em; }

@media (max-width: 400px) {
  .hero-stats { gap: 20px; }
  .hero-stats div strong { font-size: 1.6rem; }
  .wrap { padding: 0 18px; }
}

.hero-visual {
  position: relative;
  aspect-ratio: 4/3;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(160deg, var(--panel), var(--charcoal));
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.hero-visual svg { width: 78%; }

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { order: -1; aspect-ratio: 16/10; }
}

/* ---------------------------- Sections ---------------------------- */
section { padding: 72px 0; }
.section-head { max-width: 640px; margin-bottom: 44px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }

.panel-alt { background: var(--charcoal); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

/* ---------------------------- Feature list (flyer's 5 points) ---------------------------- */
.feature-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.feature-item { padding: 26px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--charcoal); }
.feature-item .num { font-family: var(--font-display); font-size: 1.6rem; color: var(--gold-2); display: block; margin-bottom: 10px; }
.feature-item h3 { font-size: 1.05rem; margin-bottom: 6px; font-family: var(--font-body); font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em; }
.feature-item p { font-size: 0.92rem; margin: 0; }

@media (max-width: 900px) { .feature-list { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .feature-list { grid-template-columns: 1fr; } }

.zones-grid { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 500px) { .zones-grid { grid-template-columns: 1fr; } }

/* ---------------------------- Vehicle cards ---------------------------- */
.vehicle-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
@media (max-width: 980px) { .vehicle-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .vehicle-grid { grid-template-columns: 1fr; } }

.vehicle-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--charcoal);
  transition: border-color 0.2s ease, transform 0.2s ease;
  display: flex;
  flex-direction: column;
}
.vehicle-card:hover { border-color: var(--gold-1); transform: translateY(-3px); }
.vehicle-photo {
  aspect-ratio: 4/3;
  background: linear-gradient(150deg, #232326, #151517);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.vehicle-photo img { width: 100%; height: 100%; object-fit: cover; }
.vehicle-photo svg { width: 46%; opacity: 0.35; }
.vehicle-tag {
  position: absolute;
  top: 12px;
  left: 12px;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 5px 10px;
  border-radius: var(--radius);
  background: rgba(10,10,11,0.85);
  border: 1px solid var(--gold-1);
  color: var(--gold-2);
}
.vehicle-tag.soon { border-color: var(--muted); color: var(--muted); }
.vehicle-body { padding: 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.vehicle-body h3 { font-family: var(--font-body); font-weight: 700; font-size: 1.05rem; margin: 0; text-transform: none; }
.vehicle-meta { display: flex; gap: 10px; flex-wrap: wrap; font-size: 0.8rem; color: var(--muted); }
.vehicle-meta span { border: 1px solid var(--line); padding: 3px 8px; border-radius: var(--radius); }
.vehicle-price { font-family: var(--font-display); font-size: 1.7rem; color: var(--gold-2); margin-top: 4px; }
.vehicle-card .btn { margin-top: 10px; }

/* ---------------------------- Filters bar ---------------------------- */
.filters {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--charcoal);
  margin-bottom: 36px;
}
.filters select, .filters input {
  background: var(--panel);
  border: 1px solid var(--line);
  color: var(--white);
  padding: 10px 12px;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 0.88rem;
  flex: 1;
  min-width: 150px;
}
.filters select:focus, .filters input:focus { outline: 1px solid var(--gold-1); }

.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--muted);
  border: 1px dashed var(--line);
  border-radius: var(--radius);
}

/* ---------------------------- Curseurs de filtre (configurateur) ---------------------------- */
.sliders-panel {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  padding: 22px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--charcoal);
  margin-bottom: 16px;
}
@media (max-width: 760px) { .sliders-panel { grid-template-columns: 1fr; gap: 20px; } }

.slider-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; }
.slider-head label { font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); }
.slider-head span { font-family: var(--font-display); font-size: 1.1rem; color: var(--gold-2); }

input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  border-radius: 4px;
  background: var(--line);
  outline: none;
  cursor: pointer;
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--gold-gradient);
  border: 2px solid var(--black);
  cursor: pointer;
  transition: transform 0.15s ease;
}
input[type="range"]::-webkit-slider-thumb:hover { transform: scale(1.15); }
input[type="range"]::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--gold-1);
  border: 2px solid var(--black);
  cursor: pointer;
}

.filter-count {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0 0 20px;
}

.vehicle-card { animation: cardFadeIn 0.3s ease; }
@keyframes cardFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ---------------------------- Comparateur de véhicules ---------------------------- */
.compare-check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 10px;
  cursor: pointer;
}
.compare-check input { accent-color: var(--gold-1); width: 15px; height: 15px; cursor: pointer; }

.compare-bar {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 80;
  background: var(--charcoal);
  border: 1px solid var(--gold-1);
  border-radius: var(--radius);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 0.88rem;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}
.compare-bar strong { color: var(--gold-2); }

.compare-modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(10,10,11,0.88);
  z-index: 90;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 40px 16px;
  overflow-y: auto;
}
.compare-modal {
  background: var(--charcoal);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  max-width: 900px;
  width: 100%;
}
.compare-modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.compare-modal-head h2 { font-size: 1.6rem; margin: 0; }
.compare-scroll { overflow-x: auto; }
.compare-table { width: 100%; border-collapse: collapse; min-width: 480px; }
.compare-table th { padding: 10px 14px; text-align: center; border-bottom: 1px solid var(--line); vertical-align: top; }
.compare-table td { padding: 10px 14px; text-align: center; border-bottom: 1px solid var(--line); font-size: 0.9rem; }
.compare-table .compare-label { text-align: left; color: var(--muted); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.03em; white-space: nowrap; }
.compare-photo { width: 100px; height: 74px; margin: 0 auto 8px; border-radius: 2px; overflow: hidden; background: var(--panel); display: flex; align-items: center; justify-content: center; }
.compare-photo img { width: 100%; height: 100%; object-fit: cover; }
.compare-photo svg { width: 60%; opacity: 0.4; }
.compare-name { font-weight: 700; font-size: 0.9rem; }

@media (max-width: 600px) {
  .compare-bar { width: calc(100% - 32px); justify-content: space-between; bottom: 16px; }
  .compare-modal { padding: 18px; }
}

/* ---------------------------- How it works ---------------------------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; counter-reset: step; }
@media (max-width: 900px) { .steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; } }
.step { position: relative; padding-top: 8px; }
.step::before {
  counter-increment: step;
  content: counter(step);
  font-family: var(--font-display);
  font-size: 2.4rem;
  color: transparent;
  -webkit-text-stroke: 1.5px var(--gold-1);
  display: block;
  margin-bottom: 8px;
}
.step h3 { font-family: var(--font-body); font-weight: 700; font-size: 0.98rem; text-transform: uppercase; letter-spacing: 0.02em; }
.step p { font-size: 0.9rem; }

/* ---------------------------- Forms ---------------------------- */
.form-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--charcoal);
  padding: 32px;
}
.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin-bottom: 8px;
}
.field input, .field select, .field textarea {
  width: 100%;
  background: var(--panel);
  border: 1px solid var(--line);
  color: var(--white);
  padding: 12px 14px;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 0.95rem;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: 1px solid var(--gold-1); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 560px) { .field-row { grid-template-columns: 1fr; } }
.form-note { font-size: 0.82rem; color: var(--muted); margin-top: 14px; }
.form-success, .form-error {
  padding: 16px 18px;
  border-radius: var(--radius);
  font-size: 0.9rem;
  margin-top: 18px;
  display: none;
}
.form-success { background: rgba(60, 107, 79, 0.15); border: 1px solid var(--success); color: #8fd1a9; }
.form-error { background: rgba(164, 64, 47, 0.15); border: 1px solid var(--danger); color: #e8a396; }

/* ---------------------------- Vehicle detail ---------------------------- */
.detail-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 48px; align-items: start; }
@media (max-width: 900px) { .detail-grid { grid-template-columns: 1fr; } }

.map-box {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel);
}
.map-box iframe { display: block; filter: grayscale(0.15) contrast(1.05); }

.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; } }
.detail-gallery-main {
  aspect-ratio: 4/3;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(150deg, #232326, #151517);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  margin-bottom: 12px;
}
.detail-gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.detail-gallery-main svg { width: 40%; opacity: 0.3; }
.detail-thumbs { display: flex; gap: 10px; flex-wrap: wrap; }
.detail-thumbs .thumb {
  width: 74px; height: 56px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  background: var(--panel);
}
.detail-thumbs .thumb img { width: 100%; height: 100%; object-fit: cover; }

.spec-table { width: 100%; border-collapse: collapse; margin-top: 24px; }
.spec-table td { padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 0.92rem; }
.spec-table td:first-child { color: var(--muted); width: 45%; }
.spec-table td:last-child { font-weight: 600; }

.sticky-side { position: sticky; top: 96px; }

/* ---------------------------- Footer ---------------------------- */
footer.site-footer {
  border-top: 1px solid var(--line);
  padding: 56px 0 28px;
  background: var(--charcoal);
}
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; gap: 28px; } }
.footer-grid h4 { font-family: var(--font-body); font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--gold-2); margin-bottom: 14px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li { margin-bottom: 10px; font-size: 0.9rem; color: var(--muted); }
.footer-grid a:hover { color: var(--white); }
.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 22px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 0.78rem;
  color: var(--muted);
}

/* ---------------------------- Utility ---------------------------- */
.center { text-align: center; }
.mt-0 { margin-top: 0; }
.badge-soon {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  border: 1px solid var(--line);
  padding: 4px 10px;
  border-radius: var(--radius);
}
.skip-link {
  position: absolute; left: -9999px; top: 0; background: var(--gold-2); color: var(--black);
  padding: 10px 16px; z-index: 100;
}
.skip-link:focus { left: 16px; top: 16px; }

.hidden { display: none !important; }