/* ==========================================================
   Autofficina Festari — foglio di stile
   Colori ripresi dal logo (blu/giallo) e dalla fascia gialla
   sulle pareti dell'officina.
   ========================================================== */

@font-face { font-family: "Barlow"; font-weight: 400; font-style: normal; font-display: swap;
  src: url("barlow-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-weight: 500; font-style: normal; font-display: swap;
  src: url("barlow-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-weight: 600; font-style: normal; font-display: swap;
  src: url("barlow-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 600; font-style: normal; font-display: swap;
  src: url("barlow-condensed-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-weight: 700; font-style: normal; font-display: swap;
  src: url("barlow-condensed-latin-700-normal.woff2") format("woff2"); }

:root {
  --navy: #0a1b45;        /* blu notte: testata, hero, footer */
  --navy-2: #102a66;
  --blue: #0141b1;        /* blu del logo */
  --yellow: #ffd400;      /* giallo del logo */
  --yellow-dark: #e0b900;
  --concrete: #dfe1e4;    /* grigio "zoccolo" dell'officina */
  --concrete-dark: #8b9099;
  --paper: #f5f4f0;
  --white: #ffffff;
  --ink: #131a2b;
  --ink-soft: #4b5468;
  --line: #d6d8dd;

  --display: "Barlow Condensed", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --body: "Barlow", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --wrap: 1160px;
  --gutter: clamp(18px, 4vw, 40px);
  --section: clamp(64px, 9vw, 112px);
  --header-h: 84px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue); }
h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.02; margin: 0; text-wrap: balance; }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: var(--section) 0; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.skip { position: absolute; left: -9999px; top: 0; background: var(--yellow); color: var(--navy); padding: 10px 16px; font-weight: 600; z-index: 100; }
.skip:focus { left: 8px; top: 8px; }

:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; }
.on-light :focus-visible, .form :focus-visible { outline-color: var(--blue); }

/* ---------- Etichette e titoli di sezione ---------- */
.eyebrow {
  font-family: var(--display); font-weight: 600; font-size: 15px;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--blue); margin: 0 0 14px; display: flex; align-items: center; gap: 12px;
}
.eyebrow::before { content: ""; width: 34px; height: 6px; background: var(--yellow); flex: none; }
.dark .eyebrow { color: var(--yellow); }
.title { font-size: clamp(34px, 5vw, 56px); text-transform: uppercase; letter-spacing: .005em; }
.lead { font-size: clamp(18px, 2vw, 20px); color: var(--ink-soft); max-width: 60ch; margin-top: 18px; }
.dark .lead { color: #c9d2e8; }

/* ---------- Pulsanti ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-family: var(--display); font-weight: 700; font-size: 19px; letter-spacing: .06em; text-transform: uppercase;
  text-decoration: none; line-height: 1; padding: 16px 24px; border: 2px solid transparent; border-radius: 2px;
  cursor: pointer; transition: background-color .15s, color .15s, border-color .15s, transform .15s;
}
.btn svg { width: 20px; height: 20px; flex: none; }
.btn--primary { background: var(--yellow); color: var(--navy); }
.btn--primary:hover { background: #ffe14d; }
.btn--ghost { border-color: rgba(255,255,255,.55); color: var(--white); }
.btn--ghost:hover { border-color: var(--white); background: rgba(255,255,255,.1); }
.btn--blue { background: var(--blue); color: var(--white); }
.btn--blue:hover { background: var(--navy-2); }
.btn--outline { border-color: var(--navy); color: var(--navy); }
.btn--outline:hover { background: var(--navy); color: var(--white); }
.btn:active { transform: translateY(1px); }

/* ---------- Testata ---------- */
.header { position: sticky; top: 0; z-index: 50; background: var(--navy); color: var(--white); border-bottom: 4px solid var(--yellow); }
.header__in { height: var(--header-h); display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: flex; align-items: center; flex: none; }
.brand img { height: 60px; width: auto; }
.nav { display: flex; align-items: center; gap: 30px; }
.nav a {
  font-family: var(--display); font-weight: 600; font-size: 18px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--white); text-decoration: none; padding: 8px 0; border-bottom: 3px solid transparent;
}
.nav a:hover { border-bottom-color: var(--yellow); }
.header__cta { display: flex; align-items: center; gap: 12px; }
.header .btn { padding: 12px 18px; font-size: 18px; }
.burger { display: none; width: 46px; height: 46px; background: none; border: 2px solid rgba(255,255,255,.4); border-radius: 2px; color: var(--white); cursor: pointer; padding: 0; align-items: center; justify-content: center; }
.burger svg { width: 24px; height: 24px; }

/* ---------- Hero ---------- */
.hero { position: relative; background: var(--navy); color: var(--white); isolation: isolate; overflow: hidden; }
.hero__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 45%; z-index: -2; }
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(90deg, rgba(10,27,69,.96) 0%, rgba(10,27,69,.88) 38%, rgba(10,27,69,.45) 72%, rgba(10,27,69,.25) 100%);
}
.hero__in { padding: clamp(64px, 11vw, 136px) 0 clamp(56px, 9vw, 112px); max-width: 720px; }
.hero h1 { font-size: clamp(44px, 7.4vw, 88px); text-transform: uppercase; line-height: .95; }
.hero h1 span { color: var(--yellow); }
.hero p.lead { color: #dbe2f3; font-size: clamp(18px, 2.1vw, 21px); max-width: 52ch; margin-top: 22px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }

/* La "fascia" dell'officina: riga gialla sopra lo zoccolo grigio */
.band { background: var(--concrete); border-top: 14px solid var(--yellow); }
.band__grid { display: grid; grid-template-columns: repeat(3, 1fr); }
.band__item { padding: 26px 28px 28px 0; border-right: 1px solid #c3c6cc; margin-right: 28px; }
.band__item:last-child { border-right: 0; margin-right: 0; padding-right: 0; }
.band__label { font-family: var(--display); font-weight: 600; font-size: 14px; letter-spacing: .14em; text-transform: uppercase; color: #555c6b; margin: 0 0 4px; }
.band__value { font-family: var(--display); font-weight: 700; font-size: clamp(22px, 2.4vw, 27px); line-height: 1.12; margin: 0; color: var(--navy); }
.band__value a { color: inherit; text-decoration: none; }
.band__value a:hover { text-decoration: underline; }
.band__note { font-size: 15px; color: var(--ink-soft); margin: 4px 0 0; }

/* ---------- Servizi ---------- */
.services__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap; margin-bottom: clamp(32px, 5vw, 56px); }
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card { background: var(--white); border: 1px solid var(--line); border-top: 6px solid var(--navy); padding: 28px 26px 30px; display: flex; flex-direction: column; }
.card h3 { font-size: 28px; text-transform: uppercase; color: var(--navy); margin-bottom: 10px; }
.card p { color: var(--ink-soft); font-size: 16.5px; }
.card ul { list-style: none; margin: auto 0 0; padding: 18px 0 0; border-top: 1px solid var(--line); font-size: 15.5px; }
.card li { padding-left: 18px; position: relative; margin-bottom: 4px; }
.card li::before { content: ""; position: absolute; left: 0; top: .62em; width: 8px; height: 8px; background: var(--yellow); }
.card--accent { border-top-color: var(--yellow); background: var(--navy); border-color: var(--navy); border-top: 6px solid var(--yellow); }
.card--accent h3 { color: var(--yellow); }
.card--accent p, .card--accent li { color: #d5dcee; }
.card--accent ul { border-top-color: rgba(255,255,255,.2); }

/* ---------- Chi siamo ---------- */
.about { background: var(--white); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.split { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.photo { position: relative; }
.photo img { width: 100%; }
.photo--stripe::after { content: ""; position: absolute; left: -14px; bottom: -14px; width: 46%; height: 14px; background: var(--yellow); }
.values { list-style: none; padding: 0; margin: 30px 0 0; display: grid; gap: 0; border-top: 1px solid var(--line); }
.values li { display: grid; grid-template-columns: 150px 1fr; gap: 18px; padding: 16px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.values strong { font-family: var(--display); font-size: 21px; text-transform: uppercase; letter-spacing: .04em; color: var(--navy); }
.values span { color: var(--ink-soft); font-size: 16.5px; }

/* ---------- Checkstar ---------- */
.checkstar { background: #000; color: var(--white); }
.checkstar__in { display: grid; grid-template-columns: minmax(0, 560px) 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; padding-top: clamp(40px, 6vw, 64px); padding-bottom: clamp(40px, 6vw, 64px); }
.checkstar h2 { font-size: clamp(28px, 3.6vw, 40px); text-transform: uppercase; margin-bottom: 14px; }
.checkstar p { color: #cfd3da; }

/* ---------- Revisioni ---------- */
.revisioni .split { grid-template-columns: 1fr 1.05fr; }
.steps { list-style: none; padding: 0; margin: 28px 0 32px; display: grid; gap: 14px; }
.steps li { background: var(--white); border: 1px solid var(--line); border-left: 6px solid var(--yellow); padding: 16px 20px; }
.steps strong { display: block; font-family: var(--display); font-size: 22px; text-transform: uppercase; color: var(--navy); letter-spacing: .02em; }
.steps span { color: var(--ink-soft); font-size: 16.5px; }
.note { font-size: 14.5px; color: var(--ink-soft); margin-top: 18px; }

/* ---------- Dove siamo ---------- */
.dove { background: var(--navy); color: var(--white); }
.dove .title { color: var(--white); }
.dove__grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(32px, 6vw, 72px); align-items: start; margin-top: clamp(32px, 5vw, 52px); }
.dove__where { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px 24px; flex-wrap: wrap; margin-top: 28px; }
.address { font-style: normal; font-family: var(--display); font-weight: 700; font-size: clamp(26px, 3vw, 34px); line-height: 1.1; text-transform: uppercase; }
.address small { display: block; font-family: var(--body); font-weight: 400; font-size: 16px; text-transform: none; color: #c9d2e8; margin-top: 8px; letter-spacing: 0; line-height: 1.5; }
.hours { width: 100%; border-collapse: collapse; margin: 0; font-size: 17px; }
.hours caption { text-align: left; font-family: var(--display); font-weight: 600; letter-spacing: .14em; text-transform: uppercase; font-size: 15px; color: var(--yellow); padding-bottom: 10px; }
.hours th, .hours td { padding: 11px 0; border-top: 1px solid rgba(255,255,255,.18); text-align: left; font-weight: 400; vertical-align: top; }
.hours td { text-align: right; font-variant-numeric: tabular-nums; }
.hours tr.is-today th, .hours tr.is-today td { color: var(--yellow); font-weight: 600; }
.hours tr.is-today th::after { content: " · oggi"; font-weight: 400; }
.hours .closed { color: #9aa6c4; }

/* ---------- Contatti ---------- */
.contact__grid { display: grid; grid-template-columns: 1fr 1.25fr; gap: clamp(32px, 6vw, 80px); align-items: start; }
.contact-list { list-style: none; padding: 0; margin: 32px 0 0; border-top: 1px solid var(--line); }
.contact-list li { padding: 18px 0; border-bottom: 1px solid var(--line); }
.contact-list .k { display: block; font-family: var(--display); font-weight: 600; font-size: 14px; letter-spacing: .14em; text-transform: uppercase; color: #555c6b; }
.contact-list a { font-family: var(--display); font-weight: 700; font-size: clamp(24px, 3vw, 32px); color: var(--navy); text-decoration: none; line-height: 1.15; overflow-wrap: anywhere; }
.contact-list a:hover { color: var(--blue); text-decoration: underline; }

.form { background: var(--white); border: 1px solid var(--line); border-top: 6px solid var(--navy); padding: clamp(22px, 3.4vw, 38px); }
.form h3 { font-size: 30px; text-transform: uppercase; color: var(--navy); margin-bottom: 6px; }
.form > p { color: var(--ink-soft); font-size: 16px; margin-bottom: 22px; }
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field--full { grid-column: 1 / -1; }
.field label { font-weight: 600; font-size: 15px; }
.field label em { font-style: normal; font-weight: 400; color: var(--ink-soft); }
.field input, .field select, .field textarea {
  font: inherit; font-size: 17px; color: var(--ink); background: var(--paper);
  border: 1.5px solid #b9bdc6; border-radius: 2px; padding: 12px 14px; width: 100%; min-height: 50px;
}
.field textarea { min-height: 130px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(1,65,177,.18); background: var(--white); }
.field label.check { font-weight: 400; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; color: var(--ink-soft); }
.check input { width: 22px; height: 22px; margin: 2px 0 0; flex: none; accent-color: var(--blue); }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.form__foot { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; margin-top: 22px; }
.form__status { font-weight: 600; font-size: 16px; margin: 0; }
.form__status.is-ok { color: #0d6b33; }
.form__status.is-err { color: #b3261e; }
.form.is-sending button[type="submit"] { opacity: .6; pointer-events: none; }

/* ---------- Domande frequenti ---------- */
.faq { background: var(--white); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.faq__in { display: grid; grid-template-columns: 1fr 1.5fr; gap: clamp(28px, 6vw, 80px); align-items: start; }
.faq__list { border-top: 2px solid var(--navy); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; padding: 20px 44px 20px 0; position: relative;
  font-family: var(--display); font-weight: 700; font-size: clamp(21px, 2.2vw, 25px); line-height: 1.15; color: var(--navy);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: 6px; top: 50%; width: 12px; height: 12px; margin-top: -9px;
  border-right: 3px solid var(--blue); border-bottom: 3px solid var(--blue); transform: rotate(45deg); transition: transform .15s;
}
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -3px; }
.faq summary:hover { color: var(--blue); }
.faq details p { color: var(--ink-soft); padding: 0 44px 22px 0; max-width: 62ch; }
.form__privacy { font-size: 14px; color: var(--ink-soft); margin: 18px 0 0; padding-top: 16px; border-top: 1px solid var(--line); }
.dove .lead { margin-bottom: 0; }
.page table { width: 100%; border-collapse: collapse; margin: 14px 0 6px; font-size: 16px; }
.page th, .page td { text-align: left; vertical-align: top; padding: 12px 14px 12px 0; border-top: 1px solid var(--line); }
.page th { font-family: var(--display); font-size: 15px; letter-spacing: .1em; text-transform: uppercase; color: #555c6b; font-weight: 600; }
.page .updated { font-size: 15px; color: var(--ink-soft); }

/* ---------- Footer ---------- */
.footer { background: #071334; color: #b9c3dd; font-size: 15.5px; border-top: 14px solid var(--yellow); }
.footer__in { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 40px; padding-top: 52px; padding-bottom: 40px; }
.footer img { height: 62px; width: auto; margin-bottom: 18px; }
.footer h4 { font-family: var(--display); font-weight: 600; font-size: 15px; letter-spacing: .14em; text-transform: uppercase; color: var(--yellow); margin: 0 0 12px; }
.footer a { color: var(--white); text-decoration: none; }
.footer a:hover { text-decoration: underline; }
.footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.footer__legal { padding-top: 0; padding-bottom: 28px; font-size: 14px; }
.footer__legal > div { border-top: 1px solid rgba(255,255,255,.14); padding-top: 20px; display: flex; justify-content: space-between; gap: 12px 16px; flex-wrap: wrap; }
.footer__credit { margin: 12px 0 0; font-size: 13.5px; color: #8f9bbb; }
.footer .footer__credit a { color: var(--yellow); font-weight: 600; }

/* ---------- Barra "chiama" su smartphone ---------- */
.callbar { display: none; }

/* ---------- Pagine di testo (privacy, grazie, 404) ---------- */
.page { padding: clamp(48px, 8vw, 96px) 0; }
.page .wrap { max-width: 820px; }
.page h1 { font-size: clamp(38px, 6vw, 60px); text-transform: uppercase; color: var(--navy); margin-bottom: 24px; }
.page h2 { font-size: 26px; text-transform: uppercase; color: var(--navy); margin: 36px 0 10px; }
.page ul { padding-left: 20px; }
.page li { margin-bottom: 6px; }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .nav { gap: 20px; }
  .nav a { font-size: 17px; }
  .checkstar__in { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  :root { --header-h: 68px; }
  .burger { display: inline-flex; }
  .nav {
    position: absolute; left: 0; right: 0; top: calc(var(--header-h) + 4px); background: var(--navy);
    flex-direction: column; align-items: stretch; gap: 0; padding: 6px var(--gutter) 18px;
    border-bottom: 4px solid var(--yellow); display: none;
  }
  .nav.is-open { display: flex; }
  .nav a { padding: 16px 0; font-size: 22px; border-bottom: 1px solid rgba(255,255,255,.14); }
  .brand img { height: 48px; }
  .header .btn span { display: none; }
  .header .btn { padding: 0; width: 46px; height: 46px; }
  .split, .revisioni .split, .dove__grid, .contact__grid, .faq__in { grid-template-columns: 1fr; }
  .revisioni .photo { order: -1; }
  .band__grid { grid-template-columns: 1fr; }
  .band__item { border-right: 0; margin-right: 0; padding: 18px 0; border-bottom: 1px solid #c3c6cc; }
  .band__item:last-child { border-bottom: 0; }
  .hero::after { background: linear-gradient(180deg, rgba(10,27,69,.9) 0%, rgba(10,27,69,.82) 100%); }
  .footer__in { grid-template-columns: 1fr; gap: 30px; }
  .photo--stripe::after { left: 0; }
  body { padding-bottom: 68px; }
  .callbar {
    display: grid; grid-template-columns: 1fr 1fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
    border-top: 4px solid var(--yellow); background: var(--navy);
  }
  .callbar a {
    display: flex; align-items: center; justify-content: center; gap: 10px; height: 64px;
    font-family: var(--display); font-weight: 700; font-size: 20px; letter-spacing: .06em; text-transform: uppercase;
    color: var(--white); text-decoration: none;
  }
  .callbar a:first-child { background: var(--yellow); color: var(--navy); }
  .callbar svg { width: 20px; height: 20px; }
}
@media (max-width: 620px) {
  body { font-size: 16.5px; }
  .grid, .fields { grid-template-columns: 1fr; }
  .values li { grid-template-columns: 1fr; gap: 2px; }
  .hero__actions .btn { width: 100%; }
  .hours { font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
@media print {
  .header, .callbar, .hero__actions, .form { display: none; }
  body { padding: 0; background: #fff; }
}
