/* Headlight Repair Shop — workshop signage theme */

@font-face { font-family: "Oswald"; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/oswald-500.woff2") format("woff2"); }
@font-face { font-family: "Oswald"; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/oswald-600.woff2") format("woff2"); }
@font-face { font-family: "Oswald"; font-style: normal; font-weight: 700; font-display: swap; src: url("../fonts/oswald-700.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/barlow-400.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-style: italic; font-weight: 400; font-display: swap; src: url("../fonts/barlow-400i.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/barlow-500.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/barlow-600.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-style: normal; font-weight: 700; font-display: swap; src: url("../fonts/barlow-700.woff2") format("woff2"); }

:root {
  --ink: #29251f;
  --ink-soft: #5d574c;
  --paper: #fbfaf8;
  --paper-soft: #f3f0ea;
  --signal: #e8590c;
  --signal-btn: #c2410c;
  --signal-btn-dark: #a83509;
  --link: #b54708;
  --line: #e3ded2;
  --field: #b6ae9d;
  --night: #262019;
  --night-deep: #1d1913;
  --night-line: #4a4335;
  --on-night: #d8d2c6;
  --on-night-soft: #a89f8d;
  --ok: #2f7d32;
  --error: #b42318;
  --radius: 4px;
  --radius-lg: 6px;
  --measure: 66ch;
  --max: 1080px;
  --gutter: clamp(1.1rem, 4.5vw, 1.75rem);
  --space: clamp(3rem, 7.5vw, 5rem);
  --font-display: "Oswald", "Arial Narrow", sans-serif;
  --font: "Barlow", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--font); font-size: 1.08rem; line-height: 1.62;
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; height: auto; }

h1, h2, h3 {
  font-family: var(--font-display); font-weight: 600;
  letter-spacing: 0.01em; line-height: 1.14; margin: 0 0 0.55em; text-wrap: balance;
}
h1 { font-size: clamp(2.1rem, 5.2vw, 3rem); text-transform: uppercase; letter-spacing: 0.015em; }
h2 { font-size: clamp(1.45rem, 2.8vw, 1.75rem); }
h3 { font-size: 1.15rem; }
p, ul, ol, dl { margin: 0 0 1.05rem; }
li + li { margin-top: 0.45rem; }

a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { color: var(--ink); text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--signal); outline-offset: 2px; border-radius: 2px; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 1rem; top: -4rem; z-index: 20;
  background: var(--signal-btn); color: #fff; padding: 0.6rem 1rem; border-radius: var(--radius);
}
.skip-link:focus { top: 0.75rem; color: #fff; }

.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 50px; padding: 0.85rem 1.7rem;
  border: 2px solid transparent; border-radius: var(--radius);
  font-family: var(--font-display); font-weight: 600; font-size: 1.02rem;
  text-transform: uppercase; letter-spacing: 0.06em; line-height: 1.2;
  text-decoration: none; text-align: center; cursor: pointer;
}
.btn-primary {
  background: var(--signal-btn); border-color: var(--signal-btn); color: #fff;
  box-shadow: inset 0 -3px 0 rgba(0, 0, 0, 0.28);
}
.btn-primary:hover { background: var(--signal-btn-dark); border-color: var(--signal-btn-dark); color: #fff; }
.btn-primary:active { box-shadow: inset 0 2px 0 rgba(0, 0, 0, 0.28); }
.btn-ghost { background: transparent; border-color: var(--ink); color: var(--ink); }
.btn-ghost:hover { border-color: var(--signal-btn); color: var(--signal-btn); }

/* ── Header ── */
.site-header { background: var(--night); color: var(--on-night); position: relative; z-index: 10; }
.header-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 0 0.85rem; min-height: 4.5rem; }
.brand { display: inline-flex; align-items: center; gap: 0.65rem; margin-right: auto; padding-block: 0.6rem; color: #fff; text-decoration: none; }
.brand:hover { color: #fff; }
.brand-mark { width: 40px; height: 40px; flex: none; }
.brand-name {
  font-family: var(--font-display); font-weight: 600; font-size: 1.28rem; line-height: 1.05;
  text-transform: uppercase; letter-spacing: 0.045em;
}
.brand-name span { display: block; font-size: 0.82rem; font-weight: 500; letter-spacing: 0.14em; color: var(--signal); }
.header-cta { min-height: 42px; padding: 0.45rem 1.05rem; font-size: 0.9rem; }
.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; padding: 0; background: none; color: #fff;
  border: 1px solid var(--night-line); border-radius: var(--radius); cursor: pointer;
}
.nav-toggle-icon, .nav-toggle-icon::before, .nav-toggle-icon::after {
  display: block; width: 20px; height: 2px; background: currentColor; border-radius: 2px; position: relative;
}
.nav-toggle-icon::before, .nav-toggle-icon::after { content: ""; position: absolute; left: 0; }
.nav-toggle-icon::before { top: -6px; }
.nav-toggle-icon::after { top: 6px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon::before { top: 0; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon::after { top: 0; transform: rotate(-45deg); }
.nav-toggle-text {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
html:not(.js) .nav-toggle { display: none; }

.site-nav { flex-basis: 100%; border-top: 1px solid var(--night-line); }
html.js .site-nav:not(.is-open) { display: none; }
.nav-list { list-style: none; margin: 0; padding: 0.3rem 0 0.8rem; }
.nav-item { margin: 0; }
.nav-list > li + li { margin-top: 0; }
.nav-item > a {
  display: block; padding: 0.75rem 0.2rem; border-bottom: 1px solid var(--night-line);
  color: var(--on-night); font-family: var(--font-display); font-weight: 500;
  font-size: 1.02rem; text-transform: uppercase; letter-spacing: 0.05em; text-decoration: none;
}
.nav-item > a:hover { color: #fff; }
.site-nav a[aria-current="page"] { color: var(--signal); }

@media (max-width: 30em) {
  .header-bar { gap: 0 0.55rem; }
  .brand { gap: 0.5rem; }
  .brand-mark { width: 32px; height: 32px; }
  .brand-name { font-size: 1.02rem; }
  .brand-name span { font-size: 0.68rem; }
  .header-cta { padding-inline: 0.7rem; font-size: 0.8rem; }
}
@media (max-width: 23em) { .brand-name span { display: none; } }

@media (min-width: 60em) {
  .header-bar { flex-wrap: nowrap; gap: 1.5rem; }
  .nav-toggle { display: none; }
  .site-nav, html.js .site-nav:not(.is-open) { display: block; flex-basis: auto; border-top: 0; margin-left: auto; }
  .brand { margin-right: 0; }
  .header-cta { order: 2; }
  .nav-list { display: flex; gap: 1.5rem; padding: 0; }
  .nav-item > a { padding: 0.25rem 0; border-bottom: 3px solid transparent; font-size: 0.95rem; white-space: nowrap; }
  .nav-item > a:hover, .site-nav a[aria-current="page"] { color: #fff; border-bottom-color: var(--signal); }
  .site-nav a[aria-current="page"] { color: #fff; }
}

/* ── Hero ── */
.hero { padding-block: clamp(2.4rem, 6vw, 3.8rem) 0.75rem; }
.hero h1 { max-width: 22ch; }
.hero h1::before {
  content: ""; display: block; width: 58px; height: 6px; margin-bottom: 1.1rem;
  background: var(--signal);
}
.hero .lead { font-size: 1.16rem; color: var(--ink-soft); max-width: var(--measure); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.8rem; margin: 1.7rem 0 1.4rem; }
.price-note { color: var(--ink-soft); font-size: 0.92rem; max-width: var(--measure); margin: -0.4rem 0 0.5rem; }
.hero-foto { margin: 1.4rem 0 0.5rem; border-radius: var(--radius-lg); overflow: hidden; background: var(--paper-soft); }
.hero-foto .media-img, .hero-foto .media { display: block; width: 100%; height: auto; aspect-ratio: 2 / 1; object-fit: cover; border-radius: 0; border: 0; }

/* ── Breadcrumb ── */
.migas { margin: 0 0 1.1rem; font-family: var(--font-display); font-weight: 500; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.07em; color: var(--ink-soft); }
.migas ol { display: flex; flex-wrap: wrap; gap: 0.4rem; list-style: none; margin: 0; padding: 0; }
.migas li + li { margin-top: 0; }
.migas li + li::before { content: "\203A"; margin-right: 0.4rem; color: var(--signal); }
.migas a { color: var(--ink-soft); }

/* ── Sections ── */
.section { padding-block: var(--space); }
.section + .section { border-top: 1px solid var(--line); }
.section-alt { background: var(--paper-soft); border-top: 0 !important; }
.section-alt + .section { border-top: 0; }
.prose { max-width: var(--measure); }
.prose h2 { margin-top: 2.2em; }
.prose h2:first-child, .prose h3:first-child { margin-top: 0; }
.prose h3 { margin-top: 1.6em; }
.prose ul, .prose ol { padding-left: 1.3em; }

.split { display: grid; gap: 2.2rem; align-items: center; }
@media (min-width: 52em) {
  .split { grid-template-columns: 1fr 1fr; gap: 3.2rem; }
  .split.reverse > .media, .split.reverse > .media-img { order: -1; }
}
.media {
  width: 100%; border-radius: var(--radius-lg); border: 1px solid var(--line); background-color: var(--paper-soft);
  background-image: linear-gradient(135deg, rgba(41, 37, 31, 0.05) 25%, transparent 25%, transparent 50%, rgba(41, 37, 31, 0.05) 50%, rgba(41, 37, 31, 0.05) 75%, transparent 75%);
  background-size: 24px 24px;
}
.section-alt .media { background-color: var(--paper); }
.media-img { display: block; width: 100%; height: auto; border-radius: var(--radius-lg); }

/* ── Hub panels ── */
.panels { display: grid; gap: 1.3rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); margin: 1.5rem 0 0.5rem; }
.panel { background: var(--paper); border: 1px solid var(--line); border-top: 5px solid var(--signal); border-radius: var(--radius); padding: 1.4rem 1.5rem; }
.panel h2, .panel h3 { margin: 0 0 0.7rem; font-size: 1.08rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--ink); }
.panel p { color: var(--ink-soft); font-size: 1rem; }
.panel ul { list-style: none; padding: 0; margin: 0; }
.panel li { margin: 0 0 0.55rem; }
.panel li a { color: var(--ink); font-weight: 600; font-size: 1.02rem; text-decoration: none; }
.panel li a:hover { color: var(--link); text-decoration: underline; }
.panel-lines li a { font-weight: 400; }

/* ── Lists ── */
.steps { list-style: none; counter-reset: step; padding: 0; max-width: var(--measure); }
.steps > li { counter-increment: step; position: relative; padding-left: 3.3rem; margin: 0 0 1.6rem; }
.steps > li::before {
  content: counter(step); position: absolute; left: 0; top: -0.05rem;
  width: 2.2rem; height: 2.2rem; border-radius: var(--radius); display: grid; place-items: center;
  background: var(--signal); color: var(--night); font-family: var(--font-display); font-weight: 600; font-size: 1.25rem;
}
.steps h3 { margin: 0 0 0.3em; }
.checks { list-style: none; padding: 0; }
.checks li { padding-left: 1.9rem; position: relative; }
.checks li::before {
  content: ""; position: absolute; left: 0.3rem; top: 0.42em; width: 0.5rem; height: 0.9rem;
  border-right: 3px solid var(--signal-btn); border-bottom: 3px solid var(--signal-btn); transform: rotate(40deg);
}

/* ── Fact sheet (model pages) and tables ── */
dl.facts {
  display: grid; grid-template-columns: max-content 1fr; gap: 0.5rem 1.4rem; max-width: var(--measure);
  margin: 1.7rem 0; padding: 1.2rem 1.4rem; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
}
dl.facts dt { font-family: var(--font-display); font-weight: 500; text-transform: uppercase; letter-spacing: 0.06em; font-size: 0.85rem; color: var(--ink-soft); padding-top: 0.15rem; }
dl.facts dd { margin: 0; font-weight: 500; }
@media (max-width: 32em) { dl.facts { grid-template-columns: 1fr; gap: 0.1rem 0; } dl.facts dd { margin-bottom: 0.6rem; } }
table { width: 100%; border-collapse: collapse; margin: 1.3rem 0; font-size: 1rem; }
th, td { text-align: left; padding: 0.65rem 0.75rem; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: var(--paper-soft); font-family: var(--font-display); font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; font-size: 0.88rem; }

/* ── Price block ── */
.price { max-width: var(--measure); background: var(--paper-soft); border: 1px solid var(--line); border-left: 5px solid var(--signal); border-radius: var(--radius); padding: clamp(1.3rem, 3vw, 1.8rem); }
.price-figure { font-family: var(--font-display); font-size: 1.3rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.03em; line-height: 1.3; }
.price p:last-child { margin-bottom: 0; }

/* ── FAQ ── */
.faq { max-width: var(--measure); }
.faq-item { border: 1px solid var(--line); border-radius: var(--radius); padding: 0 1.25rem; margin-bottom: 0.75rem; background: var(--paper); }
.faq-item[open] { background: var(--paper-soft); border-left: 5px solid var(--signal); }
.faq-item summary { cursor: pointer; list-style: none; position: relative; padding: 1.05rem 2.2rem 1.05rem 0; font-weight: 600; line-height: 1.45; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; position: absolute; right: 0; top: 0.75rem; font-family: var(--font-display); font-size: 1.6rem; line-height: 1; font-weight: 500; color: var(--signal-btn); }
.faq-item[open] summary::after { content: "\2212"; }
.faq-answer { padding: 0 0 1.05rem; }
.faq-answer p:last-child { margin-bottom: 0; }

/* ── Notes and closing call to action ── */
.trade-note { max-width: var(--measure); margin: 1.7rem 0 0; padding: 0.85rem 1.1rem; border-left: 5px solid var(--signal); background: var(--paper-soft); color: var(--ink-soft); font-size: 1rem; }
.trade-note a { color: var(--ink); font-weight: 600; }
.notice { font-size: 0.95rem; color: var(--ink-soft); max-width: var(--measure); }
.related { max-width: var(--measure); }
.related ul { padding-left: 1.2em; }
.cta-final { padding-block: var(--space); background: var(--night); color: var(--on-night); }
.cta-final h2 { max-width: 30ch; color: #fff; }
.cta-final h2::before { content: ""; display: block; width: 46px; height: 5px; margin-bottom: 1rem; background: var(--signal); }
.cta-final p { max-width: var(--measure); color: var(--on-night); }

/* ── Quote form ── */
.quote-form { max-width: 44rem; }
.quote-form fieldset { border: 0; padding: 0; margin: 0 0 2.2rem; min-width: 0; }
.quote-form legend {
  font-family: var(--font-display); font-size: 1.25rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em;
  padding: 0 0 0.6rem; margin-bottom: 1.1rem; border-bottom: 2px solid var(--signal); width: 100%;
}
.field { margin-bottom: 1.25rem; }
.field-row { display: grid; gap: 0 1.1rem; }
@media (min-width: 40em) { .field-row { grid-template-columns: repeat(3, 1fr); } .field-row.two { grid-template-columns: 1fr 1fr; } }
.field label, .field .label { display: block; font-weight: 600; font-size: 1rem; margin-bottom: 0.35rem; }
.req, .opt { font-weight: 400; color: var(--ink-soft); font-size: 0.9em; }
.hint { display: block; color: var(--ink-soft); font-size: 0.93rem; margin: -0.15rem 0 0.45rem; }
.quote-form input[type="text"], .quote-form input[type="email"], .quote-form input[type="tel"],
.quote-form select, .quote-form textarea {
  width: 100%; min-height: 50px; padding: 0.75rem 0.85rem; font: inherit; color: var(--ink);
  background: #fff; border: 1px solid var(--field); border-radius: var(--radius);
}
.quote-form textarea { min-height: 8rem; resize: vertical; }
.quote-form input[type="file"] { font: inherit; max-width: 100%; padding: 0.6rem 0; }
.quote-form input:focus-visible, .quote-form select:focus-visible, .quote-form textarea:focus-visible { border-color: var(--ink); outline-color: var(--signal); }
.quote-form :user-invalid { border-color: var(--error); }
.quote-form fieldset.field { margin: 0 0 1.25rem; }
.quote-form legend.label { font-family: var(--font); font-size: 1rem; font-weight: 600; text-transform: none; letter-spacing: 0; border-bottom: 0; margin-bottom: 0.35rem; padding-bottom: 0; }
.choice { display: flex; gap: 0.75rem; align-items: flex-start; margin-bottom: 0.75rem; }
.choice input { width: 1.3rem; height: 1.3rem; margin: 0.2rem 0 0; flex: none; accent-color: var(--signal-btn); }
.choice label { font-weight: 400; margin: 0; }
.choices-inline { display: flex; flex-wrap: wrap; gap: 0.4rem 1.6rem; }
.form-submit { margin-top: 0.6rem; }
.form-notice { font-size: 0.95rem; color: var(--ink-soft); margin-top: 1.1rem; }
.cf-turnstile { margin: 0.5rem 0 1rem; min-height: 65px; }
.form-status:empty { display: none; }
.form-status { margin-top: 1rem; padding: 0.95rem 1.1rem; border-radius: var(--radius); border: 1px solid var(--ok); background: #edf7ee; }
.form-status.is-error { border-color: var(--error); background: #fdeceb; color: var(--error); }
.form-status:focus { outline: 3px solid var(--signal); outline-offset: 2px; }

/* ── Trust strip ── */
.franja-confianza { background: var(--paper-soft); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); color: var(--ink); }
.franja-int { display: grid; gap: 1.6rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); padding-block: 2.4rem; }
.franja-int p { margin: 0; font-size: 0.97rem; color: var(--ink-soft); }
.franja-int strong { display: block; margin-bottom: 0.35rem; font-family: var(--font-display); font-size: 1.05rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: var(--ink); }
.franja-int strong::after { content: ""; display: block; width: 34px; height: 4px; margin-top: 0.45rem; background: var(--signal); }

/* ── Footer ── */
.site-footer { background: var(--night-deep); color: var(--on-night); font-size: 0.97rem; }
.site-footer a { color: var(--on-night); text-decoration: none; }
.site-footer a:hover { color: var(--signal); }
.footer-grid { display: grid; gap: 2.2rem; padding-block: 3rem 2.2rem; }
.footer-name { color: #fff; font-family: var(--font-display); font-weight: 600; font-size: 1.25rem; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 0.6rem; }
.footer-brand { max-width: 34ch; }
.footer-brand a { text-decoration: underline; }
.footer-cols { display: grid; gap: 2.2rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 10.5rem), 1fr)); }
.footer-title { color: var(--signal); font-family: var(--font-display); font-size: 0.95rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.09em; margin-bottom: 0.9rem; }
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li + li { margin-top: 0.55rem; }
.footer-base { border-top: 1px solid var(--night-line); padding-block: 1.3rem; text-align: center; font-size: 0.86rem; color: var(--on-night-soft); }
.footer-base p { margin: 0 auto 0.4rem; max-width: 80ch; }
.footer-base p:last-child { margin-bottom: 0; }
.footer-base a { color: var(--on-night-soft); text-decoration: underline; }
@media (min-width: 64em) { .footer-grid { grid-template-columns: minmax(13rem, 1fr) 3fr; } }

/* ── Error page ── */
.not-found .hero h1 { max-width: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
@media print {
  .site-header, .site-nav, .site-footer, .cta-final, .hero-actions, .migas { display: none; }
}
