/* Valenti Automobili — feuille de styles du site statique */

:root {
  --red: #e02b20;
  --red-dark: #d80000;
  --green: #077837;
  --ink: #222;
  --text: #666;
  --muted: #f5f5f5;
  --footer: #141414;
  --header-h: 80px;
  --container: 1180px;
  --font-title: "Montserrat", Helvetica, Arial, sans-serif;
  --font-body: "Open Sans", Arial, sans-serif;
}

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

html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.75;
  color: var(--text);
  background: #fff;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--red); text-decoration: none; transition: color .3s; }
a:hover { color: var(--green); }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }

h1, h2, h3, h4 {
  font-family: var(--font-title);
  color: var(--ink);
  line-height: 1.25;
  margin: 0 0 .6em;
  font-weight: 500;
}
h2 { font-size: clamp(22px, 3vw, 30px); }
h3 { font-size: 20px; font-weight: 600; }
p { margin: 0 0 1.1em; }

.container { width: min(100% - 40px, var(--container)); margin-inline: auto; }
.section { padding: 64px 0; }
.section--muted { background: var(--muted); }
.section--flush-top { padding-top: 0; }
.center { text-align: center; }
.narrow { max-width: 860px; margin-inline: auto; }

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  background: #fff; padding: 10px 16px;
}
.skip-link:focus { left: 10px; top: 10px; }

/* ---------- En-tête ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: #fff;
  box-shadow: 0 1px 0 rgba(0, 0, 0, .1);
}
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--header-h);
}
.logo img { height: 46px; width: auto; }

.nav ul { list-style: none; margin: 0; padding: 0; }
.nav > ul { display: flex; gap: 30px; align-items: center; }
.nav a {
  color: rgba(0, 0, 0, .6);
  font-size: 14px; font-weight: 600;
  display: block; padding: 10px 0;
}
.nav a:hover,
.nav a[aria-current="page"],
.nav .is-parent > a { color: var(--red); }

.has-sub { position: relative; }
.has-sub > a::after {
  content: ""; display: inline-block; margin-left: 7px;
  width: 6px; height: 6px;
  border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
  transform: translateY(-3px) rotate(45deg);
}
.sub {
  position: absolute; top: 100%; left: -20px;
  min-width: 220px; padding: 14px 20px !important;
  background: #fff; border-top: 3px solid var(--red);
  box-shadow: 0 2px 5px rgba(0, 0, 0, .1);
  opacity: 0; visibility: hidden; transition: opacity .2s;
}
.has-sub:hover .sub,
.has-sub:focus-within .sub { opacity: 1; visibility: visible; }

.nav-toggle {
  display: none;
  width: 44px; height: 44px; padding: 10px;
  background: none; border: 0; cursor: pointer;
}
.nav-toggle span {
  display: block; height: 3px; margin: 5px 0;
  background: var(--red); transition: transform .25s, opacity .25s;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ---------- Hero (accueil) ---------- */
.hero {
  position: relative;
  min-height: calc(100vh - var(--header-h));
  min-height: calc(100svh - var(--header-h));
  display: grid; place-items: center;
  text-align: center; color: #fff;
  background: #111 center / cover no-repeat;
}
.hero::before { content: ""; position: absolute; inset: 0; background: rgba(0, 0, 0, .6); }
.hero__content { position: relative; padding: 60px 20px; }
.hero__logo { width: min(420px, 70vw); margin: 0 auto 28px; }
.hero__tagline {
  font-family: var(--font-title);
  font-size: clamp(15px, 2vw, 20px); font-weight: 400;
  letter-spacing: .04em; text-transform: uppercase;
  color: #fff; margin: 0;
}
.hero__down {
  position: absolute; left: 50%; bottom: 28px;
  width: 44px; height: 44px; margin-left: -22px;
  display: grid; place-items: center; color: #fff;
  animation: bob 2s ease-in-out infinite;
}
.hero__down:hover { color: #fff; opacity: .7; }
@keyframes bob { 50% { transform: translateY(8px); } }

/* ---------- Bandeau de titre (pages internes) ---------- */
.page-header {
  position: relative;
  padding: 90px 0;
  text-align: center;
  background: #111 center / cover no-repeat;
  border-bottom: 3px solid var(--red);
}
.page-header::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, .65), rgba(0, 0, 0, .75));
}
.page-header h1 {
  position: relative; margin: 0;
  color: #fff; font-size: clamp(28px, 5vw, 44px);
  font-weight: 500; text-transform: uppercase; letter-spacing: .03em;
}

/* ---------- Titres de section ---------- */
.title { margin-bottom: 36px; }
.title h2 { margin-bottom: 14px; }
.title--center { text-align: center; }
.title--upper h2 { text-transform: uppercase; }
.title::after {
  content: ""; display: block;
  width: 90px; height: 2px; background: var(--red-dark);
}
.title--center::after { margin-inline: auto; }
.title--plain::after { display: none; }
.title p { margin: 0 0 14px; }

/* ---------- Citation (accueil) ---------- */
.quote {
  position: relative;
  background: var(--muted);
  padding: 56px 40px 34px;
  margin-top: 56px;
  text-align: center;
  font-weight: 600;
}
.quote::before {
  content: "\201D";
  position: absolute; top: -26px; left: 50%; margin-left: -26px;
  width: 52px; height: 52px; border-radius: 50%;
  background: var(--muted); color: var(--ink);
  font: 700 54px/70px Georgia, serif;
}

/* ---------- Cartes ---------- */
.cards { display: grid; gap: 36px; grid-template-columns: repeat(3, 1fr); }
.cards--4 { grid-template-columns: repeat(4, 1fr); gap: 28px; }
.card { text-align: center; display: flex; flex-direction: column; }
.card__img { overflow: hidden; margin-bottom: 22px; }
.card__img img {
  width: 100%; aspect-ratio: 4 / 3; object-fit: cover;
  transition: transform .5s;
}
.card:hover .card__img img { transform: scale(1.04); }
.card h3 { margin-bottom: 10px; }
.card p { flex: 1; margin-bottom: 14px; }
.more {
  font-size: 14px; font-weight: 700; text-transform: uppercase;
  color: var(--red);
}

/* ---------- Partenaires ---------- */
.partners {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 40px; align-items: center;
}
.partners img { max-height: 110px; width: auto; margin-inline: auto; }

/* ---------- Contenu éditorial ---------- */
.prose ul { padding-left: 1.2em; margin: 0 0 1.1em; }
.prose li::marker { color: var(--red); }
.prose strong { color: var(--ink); }

.split { display: grid; grid-template-columns: 1fr 2fr; gap: 56px; align-items: start; }
.split__img { position: sticky; top: calc(var(--header-h) + 24px); }

.photo-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 40px; }

.steps { display: grid; gap: 56px; }
.step { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.step:nth-child(even) .step__img { order: 2; }
.step__img img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.step h2 { font-size: 24px; margin-bottom: 12px; }
.step h2::after {
  content: ""; display: block; margin-top: 12px;
  width: 70px; height: 2px; background: var(--red-dark);
}

/* ---------- Galerie + visionneuse ---------- */
.gallery {
  display: grid; gap: 14px; margin-top: 40px;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
}
.gallery a { display: block; overflow: hidden; background: #eee; }
.gallery img,
.photo-row img {
  width: 100%; aspect-ratio: 4 / 3; object-fit: cover;
  transition: transform .4s, opacity .3s;
}
.gallery a:hover img,
.photo-row a:hover img { transform: scale(1.05); opacity: .9; }
.photo-row a { display: block; overflow: hidden; }

.lightbox {
  position: fixed; inset: 0; z-index: 300;
  display: none; align-items: center; justify-content: center;
  background: rgba(0, 0, 0, .92);
}
.lightbox.is-open { display: flex; }
.lightbox img { max-width: 92vw; max-height: 88vh; object-fit: contain; }
.lightbox button {
  position: absolute; background: none; border: 0; cursor: pointer;
  color: #fff; font-size: 40px; line-height: 1;
  width: 56px; height: 56px; opacity: .8;
}
.lightbox button:hover { opacity: 1; }
.lightbox__close { top: 10px; right: 10px; }
.lightbox__prev { left: 6px; top: 50%; margin-top: -28px; }
.lightbox__next { right: 6px; top: 50%; margin-top: -28px; }
.lightbox__count {
  position: absolute; bottom: 14px; left: 0; right: 0;
  text-align: center; color: rgba(255, 255, 255, .7); font-size: 13px;
}

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 36px; }
.blurb { text-align: center; }
.blurb svg { width: 42px; height: 42px; color: var(--red); margin-bottom: 14px; }
.blurb h2 { font-size: 18px; font-weight: 600; }
.blurb p { margin: 0; }
.contact-actions { display: flex; flex-wrap: wrap; gap: 16px; justify-content: center; margin-top: 48px; }
.btn {
  display: inline-block; padding: 14px 30px;
  font-family: var(--font-title); font-size: 14px; font-weight: 600;
  text-transform: uppercase; letter-spacing: .05em;
  background: var(--red); color: #fff; border: 2px solid var(--red);
  transition: background .3s, color .3s, border-color .3s;
}
.btn:hover { background: var(--green); border-color: var(--green); color: #fff; }
.btn--ghost { background: transparent; color: var(--red); }
.map { display: block; width: 100%; height: 440px; border: 0; }
.map-link { text-align: center; padding: 14px 0; font-size: 14px; }

/* ---------- Pied de page ---------- */
.site-footer { background: var(--footer); color: rgba(255, 255, 255, .75); }
.site-footer .container {
  display: grid; grid-template-columns: 1.2fr 1fr 1fr 1fr; gap: 40px;
  padding-block: 56px; align-items: start;
}
.site-footer img { width: 130px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer a { color: #fff; font-size: 14px; }
.site-footer a:hover { color: var(--red); }
.social { display: flex; gap: 14px; margin-top: 14px; }
.social svg { width: 22px; height: 22px; display: block; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .1);
  text-align: center; font-size: 13px; padding: 16px 20px;
  background: #0b0b0b;
}
.footer-bottom a { font-size: 13px; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  :root { --header-h: 68px; }
  .logo img { height: 38px; }
  .nav-toggle { display: block; }
  .nav {
    position: absolute; top: 100%; left: 0; right: 0;
    background: #fff; border-top: 3px solid var(--red);
    box-shadow: 0 8px 16px rgba(0, 0, 0, .12);
    max-height: calc(100vh - var(--header-h)); overflow-y: auto;
    display: none;
  }
  .nav.is-open { display: block; }
  .nav > ul { display: block; padding: 10px 20px 20px; }
  .nav li { border-bottom: 1px solid rgba(0, 0, 0, .06); }
  .nav a { padding: 12px 0; }
  .has-sub > a::after { display: none; }
  .sub {
    position: static; opacity: 1; visibility: visible;
    border: 0; box-shadow: none; padding: 0 0 0 18px !important;
  }
  .sub li:last-child { border-bottom: 0; }

  .cards, .cards--4 { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; gap: 32px; }
  .split__img { position: static; max-width: 420px; margin-inline: auto; }
  .site-footer .container { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  .section { padding: 44px 0; }
  .page-header { padding: 60px 0; }
  .cards, .cards--4, .contact-grid, .step { grid-template-columns: 1fr; }
  .step:nth-child(even) .step__img { order: 0; }
  .step { gap: 20px; }
  .partners, .photo-row { grid-template-columns: repeat(2, 1fr); }
  .gallery { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .quote { padding: 48px 22px 24px; }
  .site-footer .container { grid-template-columns: 1fr; text-align: center; }
  .site-footer img { margin-inline: auto; }
  .social { justify-content: center; }
  .map { height: 340px; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ---------- Bandeau de consentement cookies ---------- */
.consent {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 250;
  max-width: 560px; margin-inline: auto; padding: 20px 22px;
  background: #fff; color: var(--text);
  border-top: 3px solid var(--red);
  box-shadow: 0 6px 30px rgba(0, 0, 0, .25);
  font-size: 14px; line-height: 1.6;
}
.consent p { margin: 0 0 14px; }
.consent__actions { display: flex; gap: 12px; justify-content: flex-end; flex-wrap: wrap; }
.consent .btn { padding: 10px 22px; font-size: 13px; cursor: pointer; }
.consent-link {
  background: none; border: 0; padding: 0; cursor: pointer;
  font: inherit; color: #fff;
}
.consent-link:hover { color: var(--red); }
