/* ==========================================================================
   TEMA: Showroom Light  —  versione chiara del tema "Showroom" (dark)
   Font (Google Fonts, OFL): Archivio (display, asse wdth), Hanken Grotesk (testo), JetBrains Mono (dati)
   Per cambiare look basta modificare le variabili qui sotto.
   ========================================================================== */
:root {
  /* Font */
  --font-display: "Archivo", "Arial Narrow", sans-serif;
  --font-body: "Hanken Grotesk", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
  --display-stretch: 125%;            /* Archivo Expanded */

  /* Palette base */
  --bg: #FAF8F4;
  --surface: #FFFFFF;
  --surface-alt: #F1ECE3;
  --line: #E6E0D4;
  --line-strong: #C9C3B6;
  --ink: #111214;
  --muted: #5E5A52;
  --accent: var(--brand-primary, #FF6A2B);
  --accent-hover: var(--brand-secondary, #F25A18);
  --accent-ink: var(--brand-primary, #B93D0A);   /* accento usato come testo su fondo chiaro (contrasto AA) */
  --on-accent: var(--brand-on-primary, #111214);
  --dark: #111214;
  --on-dark: #FAF8F4;
  --success: #1E7A4C;
  --star: var(--brand-primary, #FF6A2B);
  --ghost-line: #C9C3B6;
  --shadow: 0 1px 2px rgba(17,18,20,.04), 0 12px 32px rgba(17,18,20,.06);

  /* Header + hero */
  --header-bg: #FAF8F4;
  --hero-bg: #FAF8F4;
  --hero-ink: #111214;
  --hero-muted: #5E5A52;
  --hero-line: #E6E0D4;
  --hero-card: #FFFFFF;
  --hero-watermark: #EFE9DE;
  --accent-hero: var(--brand-primary, #B93D0A);
  --search-bg: #FFFFFF;
  --search-ink: #111214;

  /* Servizi */
  --services-bg: #FAF8F4;
  --services-ink: #111214;
  --services-muted: #5E5A52;
  --service-a-bg: #111214;  --service-a-ink: #FAF8F4;  --service-a-line: #111214;  --accent-on-a: var(--brand-primary, #FF6A2B);
  --service-b-bg: #FFFFFF;  --service-b-ink: #111214;  --service-b-line: #E6E0D4;

  /* Chi siamo */
  --about-bg: #F1ECE3;

  /* Contatti */
  --contact-bg: #FFFFFF;
  --contact-ink: #111214;
  --contact-muted: #5E5A52;
  --contact-line: #E6E0D4;

  /* Footer */
  --footer-bg: #F1ECE3;
  --footer-ink: #111214;
  --footer-muted: #5E5A52;
  --footer-line: #E6E0D4;
}

/* ==========================================================================
   BASE — reset e tipografia
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, p, dl, dd, figure, blockquote { margin: 0; }
button, select { font: inherit; color: inherit; }

.container { width: 100%; max-width: 1440px; margin: 0 auto; padding: 0 64px; }
.accent { color: var(--accent); }

.icon {
  width: 18px; height: 18px; flex-shrink: 0;
  fill: none; stroke: currentColor; stroke-width: 2.1;
  stroke-linecap: round; stroke-linejoin: round;
}

.eyebrow, .kicker {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--font-mono); font-size: 13px; font-weight: 500;
  letter-spacing: .12em; text-transform: uppercase; color: var(--muted);
}
.eyebrow { color: var(--hero-muted); }
.eyebrow__line { width: 32px; height: 2px; background: var(--accent); }

.section__title {
  font-family: var(--font-display); font-stretch: var(--display-stretch);
  font-weight: 800; font-size: clamp(36px, 4.2vw, 60px);
  line-height: 1.02; letter-spacing: -.02em;
}
.section__title--xl { font-size: clamp(44px, 5vw, 72px); line-height: .98; }
.section__lead { font-size: 19px; line-height: 1.6; color: var(--muted); }
.subtitle {
  font-family: var(--font-display); font-stretch: var(--display-stretch);
  font-weight: 800; font-size: 30px; letter-spacing: -.01em;
}

/* ==========================================================================
   BOTTONI
   ========================================================================== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 56px; padding: 0 28px; border-radius: 999px;
  font-size: 16px; font-weight: 700; white-space: nowrap;
  border: 1px solid transparent; cursor: pointer;
  transition: transform .15s ease, background-color .15s ease, border-color .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn--sm { height: 48px; padding: 0 20px; font-size: 15px; }
.btn--lg { height: 60px; padding: 0 32px; font-size: 17px; }
.btn--primary { background: var(--accent); color: var(--on-accent); }
.btn--primary:hover { background: var(--accent-hover); }
.btn--ghost { border-color: var(--ghost-line); color: inherit; }
.btn--ghost:hover { border-color: currentColor; }
.btn--dark { background: var(--dark); color: var(--on-dark); }
.btn--outline { border-color: var(--ink); color: var(--ink); }
.btn--light { background: #fff; color: #111; }

.link-arrow {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 10px 0; font-size: 17px; font-weight: 700;
  border-bottom: 2px solid currentColor;
}
.link-arrow--accent { color: var(--accent-ink); border-bottom: 0; }

.round-btn {
  width: 48px; height: 48px; border-radius: 999px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--line-strong); background: transparent; cursor: pointer; color: var(--ink);
}
.round-btn--dark { background: var(--dark); border-color: var(--dark); color: var(--on-dark); }

.badge {
  display: inline-flex; align-items: center; height: 40px; padding: 0 16px;
  border-radius: 999px; background: var(--accent); color: var(--on-accent);
  font-family: var(--font-mono); font-weight: 600; font-size: 15px;
}
.badge--sm { height: 32px; padding: 0 12px; font-size: 13px; }

/* ==========================================================================
   TOP BAR + HEADER
   ========================================================================== */
.topbar { background: var(--header-bg); color: var(--hero-muted); border-bottom: 1px solid var(--hero-line); font-size: 13px; }
.topbar__inner { height: 44px; display: flex; align-items: center; justify-content: space-between; }
.topbar__group { display: flex; gap: 32px; align-items: center; }
.topbar__item { display: inline-flex; gap: 8px; align-items: center; }
.topbar__item .icon { width: 14px; height: 14px; }
.topbar__phone { color: var(--hero-ink); font-weight: 600; }

.header {
  position: sticky; top: 0; z-index: 50;
  background: var(--header-bg); color: var(--hero-ink);
  border-bottom: 1px solid var(--hero-line);
}
.header__inner { height: 88px; display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.logo img { width: 200px; height: auto; }
.nav { display: flex; gap: 36px; font-size: 15px; font-weight: 500; }
.nav__link { padding: 12px 0; color: var(--hero-muted); border-bottom: 2px solid transparent; }
.nav__link:hover, .nav__link.is-active { color: var(--hero-ink); border-bottom-color: var(--accent); }
.header__cta { display: flex; gap: 12px; }

/* ==========================================================================
   HERO
   ========================================================================== */
.hero {
  position: relative; overflow: hidden;
  color: var(--hero-ink);
  background-color: var(--hero-bg);
  /* immagine di sfondo impostata inline per pagina (tenant hero_images o fallback del tema) */
  background-size: cover; background-position: center bottom;
  padding: 88px 0 64px;
}
.hero__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 24px; align-items: start; }
.hero__text { grid-column: span 6; display: flex; flex-direction: column; gap: 32px; position: relative; z-index: 2; }
.hero__title {
  font-family: var(--font-display); font-stretch: var(--display-stretch);
  font-weight: 800; font-size: clamp(56px, 6.4vw, 92px);
  line-height: .95; letter-spacing: -.02em;
}
.hero__lead { max-width: 520px; font-size: 20px; line-height: 1.55; color: var(--hero-muted); }
.hero__actions { display: flex; gap: 16px; flex-wrap: wrap; }

.hero__visual { grid-column: span 6; position: relative; min-height: 460px; overflow: visible; }
.hero__watermark {
  position: absolute; right: 0; top: 8px;
  font-family: var(--font-display); font-stretch: var(--display-stretch);
  font-weight: 900; font-size: 150px; line-height: 1; letter-spacing: -.04em; white-space: nowrap;
  color: var(--hero-watermark); user-select: none; pointer-events: none;
}
.hero__car { position: absolute; right: -40px; top: 150px; width: 112%; max-width: none; }
.hero__badge {
  position: absolute; left: 24px; top: 40px; z-index: 2;
  display: flex; flex-direction: column; gap: 4px; padding: 16px 20px;
  border-radius: 16px; background: var(--hero-card); border: 1px solid var(--hero-line);
  box-shadow: var(--shadow);
}
.hero__badge-label { font-family: var(--font-mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--hero-muted); }
.hero__badge-title { font-size: 17px; font-weight: 700; }
.hero__badge-price { font-size: 15px; color: var(--hero-muted); }
.hero__badge-price strong { color: var(--accent-hero); }

/* Ricerca rapida */
.search {
  position: relative; z-index: 2; margin-top: 48px;
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr));
  padding: 8px; border-radius: 20px;
  background: var(--search-bg); color: var(--search-ink);
  box-shadow: var(--shadow);
}
.search__field { display: flex; flex-direction: column; gap: 4px; padding: 14px 24px; border-right: 1px solid var(--line); }
.search__field:nth-child(4) { border-right: 0; }
.search__label { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.search select { border: 0; padding: 0; background: transparent; font-size: 17px; font-weight: 600; cursor: pointer; }
.search__submit {
  border: 0; border-radius: 14px; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 12px;
  background: var(--dark); color: var(--on-dark); font-size: 17px; font-weight: 700;
}

/* ==========================================================================
   SEZIONI GENERICHE
   ========================================================================== */
.section { padding: 120px 0; }
.section--alt { background: var(--surface-alt); }
.section__head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 56px; }
.section__head > div:first-child { display: flex; flex-direction: column; gap: 16px; }
.section__head--small { margin: 80px 0 32px; align-items: center; }
.carousel-nav { display: flex; gap: 8px; }

/* Auto in evidenza */
.featured {
  display: grid; grid-template-columns: 7fr 5fr; gap: 24px;
  padding: 16px; border-radius: 28px; background: var(--surface); box-shadow: var(--shadow);
}
.featured__media { position: relative; border-radius: 18px; overflow: hidden; min-height: 460px; background: var(--surface-alt); }
.featured__media img { width: 100%; height: 100%; object-fit: cover; }
.featured__media .badge { position: absolute; left: 24px; top: 24px; }
.featured__counter {
  position: absolute; right: 24px; bottom: 24px; padding: 8px 14px; border-radius: 999px;
  background: var(--surface); font-size: 13px; font-weight: 600; color: var(--muted);
}
.featured__body { padding: 32px 32px 32px 16px; display: flex; flex-direction: column; justify-content: space-between; gap: 32px; }
.featured__brand { font-family: var(--font-mono); font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.featured__model {
  margin-top: 16px;
  font-family: var(--font-display); font-stretch: var(--display-stretch);
  font-weight: 800; font-size: 52px; line-height: 1; letter-spacing: -.02em;
}
.specs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 28px; }
.specs__item { padding: 16px; border: 1px solid var(--line); border-radius: 14px; display: flex; flex-direction: column; gap: 6px; }
.specs dt { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.specs dd { font-family: var(--font-mono); font-size: 19px; font-weight: 600; }
.price { display: flex; flex-direction: column; gap: 4px; margin-bottom: 24px; }
.price__old { font-size: 17px; color: var(--muted); text-decoration: line-through; }
.price__row { display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.price__now { font-family: var(--font-display); font-weight: 800; font-size: 56px; letter-spacing: -.02em; line-height: 1.1; }
.price__save { font-size: 15px; font-weight: 700; color: var(--success); }
.featured__actions { display: flex; gap: 12px; }
.featured__actions .btn { flex: 1; }

/* Card auto */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 24px; }
.car-card { display: flex; flex-direction: column; border-radius: 22px; overflow: hidden; background: var(--surface); box-shadow: var(--shadow); transition: transform .2s ease; }
.car-card:hover { transform: translateY(-4px); }
.car-card__media { position: relative; aspect-ratio: 10 / 7; background: var(--surface-alt); }
.car-card__media img { width: 100%; height: 100%; object-fit: cover; }
.car-card__media .badge { position: absolute; left: 16px; top: 16px; }
.car-card__body { padding: 24px; display: flex; flex-direction: column; gap: 6px; }
.car-card__title { font-size: 20px; font-weight: 700; }
.car-card__meta { font-family: var(--font-mono); font-size: 14px; color: var(--muted); }
.car-card__foot { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; padding-top: 14px; border-top: 1px solid var(--line); }
.car-card__price { font-family: var(--font-display); font-weight: 800; font-size: 26px; }
.view-toggle { display: inline-flex; gap: 8px; margin-bottom: 16px; }
.view-toggle-btn { width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--line-strong); background: var(--surface); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; opacity: .55; color: var(--ink); }
.view-toggle-btn.active { opacity: 1; background: var(--surface-alt); border-color: var(--accent); }
.cards.view-list { display: flex; flex-direction: column; gap: 16px; }
.view-list .car-card { flex-direction: row; }
.view-list .car-card__media { width: 260px; flex: 0 0 260px; aspect-ratio: auto; }
.view-list .car-card__body { flex-direction: row; align-items: center; gap: 24px; padding: 20px 24px; flex: 1; }
.view-list .car-card__main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.view-list .car-card__foot { margin-top: 0; padding-top: 0; border-top: 0; flex-direction: column; align-items: flex-end; gap: 8px; border-left: 1px solid var(--line); padding-left: 24px; flex-shrink: 0; }
@media (max-width: 700px) {
  .view-list .car-card { flex-direction: column; }
  .view-list .car-card__media { width: 100%; aspect-ratio: 10 / 7; }
  .view-list .car-card__body { flex-direction: column; align-items: stretch; }
  .view-list .car-card__foot { border-left: 0; padding-left: 0; flex-direction: row; justify-content: space-between; align-items: center; }
}

/* Servizi */
.section--services { background: var(--services-bg); color: var(--services-ink); }
.section--services .kicker, .section--services .section__lead { color: var(--services-muted); }
.services { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 24px; }
.services__intro { grid-column: span 4; display: flex; flex-direction: column; gap: 20px; padding-right: 24px; }
.service {
  grid-column: span 4; min-height: 380px; padding: 40px; border-radius: 24px;
  display: flex; flex-direction: column; justify-content: space-between; gap: 32px;
}
.service--a { background: var(--service-a-bg); color: var(--service-a-ink); border: 1px solid var(--service-a-line); }
.service--b { background: var(--service-b-bg); color: var(--service-b-ink); border: 1px solid var(--service-b-line); }
.service__icon { width: 72px; height: 72px; border-radius: 20px; display: flex; align-items: center; justify-content: center; }
.service__icon .icon { width: 34px; height: 34px; stroke-width: 2; }
.service--a .service__icon { background: var(--accent); color: var(--on-accent); }
.service--b .service__icon { background: var(--dark); color: var(--accent); }
.service__title { font-family: var(--font-display); font-weight: 800; font-size: 30px; margin-bottom: 12px; }
.service__text { font-size: 17px; line-height: 1.6; opacity: .85; margin-bottom: 16px; }
.service--a .link-arrow--accent { color: var(--accent-on-a); }

/* Chi siamo */
.about { display: grid; grid-template-columns: 1fr 1fr; min-height: 700px; background: var(--about-bg); }
.about__media { position: relative; overflow: hidden; }
.about__media img { width: 100%; height: 100%; object-fit: cover; }
.about__caption { position: absolute; left: 32px; bottom: 32px; padding: 8px 14px; border-radius: 999px; background: var(--surface); font-size: 13px; font-weight: 600; color: var(--muted); }
.about__body { padding: 120px 96px 120px 80px; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 28px; }
.stats { width: 100%; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; padding: 28px 0; border-top: 1px solid var(--line-strong); border-bottom: 1px solid var(--line-strong); }
.stats__item { display: flex; flex-direction: column-reverse; gap: 6px; }
.stats dt { font-size: 14px; color: var(--muted); }
.stats dd { font-family: var(--font-display); font-stretch: var(--display-stretch); font-weight: 800; font-size: 40px; }

/* Recensioni */
.rating { display: flex; gap: 24px; align-items: center; }
.rating__score { display: flex; flex-direction: column; align-items: flex-end; }
.rating__score strong { font-family: var(--font-display); font-stretch: var(--display-stretch); font-size: 36px; font-weight: 800; }
.rating__score span { font-size: 14px; color: var(--muted); }
.reviews { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.review { display: flex; flex-direction: column; gap: 20px; min-height: 280px; padding: 36px; border-radius: 22px; background: var(--surface); box-shadow: var(--shadow); border: 1px solid var(--line); }
.review__stars { display: flex; gap: 4px; }
.review__stars svg { width: 20px; height: 20px; fill: var(--star); }
.review__text { flex: 1; font-size: 19px; line-height: 1.55; }
.review__author { display: flex; gap: 14px; align-items: center; padding-top: 20px; border-top: 1px solid var(--line); }
.review__author strong { display: block; }
.review__author small { font-size: 14px; color: var(--muted); }
.avatar { width: 44px; height: 44px; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; background: var(--dark); color: var(--on-dark); font-weight: 700; font-size: 13px; }

/* Contatti */
.section--contact { background: var(--contact-bg); color: var(--contact-ink); }
.section--contact .kicker { color: var(--contact-muted); }
.contact { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 24px; align-items: center; }
.contact__body { grid-column: span 5; display: flex; flex-direction: column; gap: 32px; }
.contact__list { border-top: 1px solid var(--contact-line); }
.contact__list div { display: flex; justify-content: space-between; gap: 16px; padding: 20px 0; border-bottom: 1px solid var(--contact-line); font-size: 18px; }
.contact__list dt { color: var(--contact-muted); }
.contact__list dd { font-weight: 600; text-align: right; }
.contact__actions { display: flex; gap: 12px; flex-wrap: wrap; }
.section--contact .btn--ghost { border-color: var(--contact-line); }
.contact__map { grid-column: 7 / span 6; position: relative; border-radius: 28px; overflow: hidden; aspect-ratio: 15 / 11; border: 1px solid var(--contact-line); }
.contact__map img { width: 100%; height: 100%; object-fit: cover; }
.contact__pin-label { position: absolute; left: 50%; top: 26%; transform: translateX(-50%); padding: 10px 16px; border-radius: 12px; background: var(--dark); color: var(--on-dark); font-size: 14px; font-weight: 700; white-space: nowrap; }
.contact__maps-link { position: absolute; right: 24px; bottom: 24px; }

/* Footer */
.footer { background: var(--footer-bg); color: var(--footer-ink); border-top: 1px solid var(--footer-line); padding: 56px 0; }
.footer__top { display: flex; justify-content: space-between; align-items: center; gap: 24px; margin-bottom: 40px; }
.footer__top img { width: 200px; }
.footer__nav { display: flex; gap: 32px; font-size: 15px; color: var(--footer-muted); }
.footer__nav a:hover { color: var(--footer-ink); }
.footer__bottom { display: flex; justify-content: space-between; gap: 24px; font-size: 13px; color: var(--footer-muted); }

/* WhatsApp flottante */
.wa-float {
  position: fixed; right: 24px; bottom: 24px; z-index: 60;
  width: 60px; height: 60px; border-radius: 999px;
  display: flex; align-items: center; justify-content: center;
  background: var(--accent); color: var(--on-accent); box-shadow: 0 10px 30px rgba(0,0,0,.2);
}
.wa-float .icon { width: 26px; height: 26px; }

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 1100px) {
  .container { padding: 0 32px; }
  .nav { display: none; }                 /* sostituire con menu hamburger del tema */
  .hero__text, .hero__visual { grid-column: 1 / -1; }
  .hero__visual { min-height: 360px; margin-top: 24px; }
  .hero__car { position: relative; top: 60px; right: auto; width: 100%; }
  .search { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .search__field { border-right: 0; border-bottom: 1px solid var(--line); }
  .search__submit { grid-column: 1 / -1; height: 56px; margin-top: 8px; }
  .featured { grid-template-columns: minmax(0, 1fr); }
  .featured__body { padding: 16px; }
  .cards, .reviews { grid-template-columns: 1fr 1fr; }
  .services__intro, .service { grid-column: 1 / -1; min-height: 0; }
  .about { grid-template-columns: 1fr; }
  .about__media { aspect-ratio: 12 / 9; }
  .about__body { padding: 72px 32px; }
  .contact__body, .contact__map { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  .container { padding: 0 16px; }
  .topbar { display: none; }
  .header__inner { height: 72px; }
  .logo img { width: 160px; }
  .header__cta .btn--ghost { display: none; }
  .hero { padding: 48px 0 40px; }
  .hero__watermark { font-size: 110px; }
  .hero__badge { display: none; }
  .search { grid-template-columns: 1fr; }
  .section { padding: 72px 0; }
  .section__head { flex-direction: column; align-items: flex-start; }
  .featured__media { min-height: 260px; }
  .featured__model { font-size: 40px; }
  .specs { gap: 8px; }
  .specs__item { padding: 12px; }
  .specs dd { font-size: 15px; overflow-wrap: anywhere; }
  .price__now { font-size: 44px; }
  .featured__actions { flex-direction: column; }
  .featured__actions .btn { flex: 0 0 auto; }
  .hero__visual { min-height: 0; }
  .hero__car { top: 0; }
  .hero__watermark { top: -10px; }
  .cards, .reviews { grid-template-columns: 1fr; }
  .stats dd { font-size: 30px; }
  .rating { flex-direction: column; align-items: flex-start; }
  .rating__score { align-items: flex-start; }
  .footer__top, .footer__bottom { flex-direction: column; align-items: flex-start; }
  .footer__nav { flex-wrap: wrap; gap: 16px 24px; }
}
