/* Fletes Jony: amarillo y negro, mobile first. */

/* Archivo, subseteada a latin básico + tildes/ñ/¿¡. La recta es solo peso; la cursiva suma el eje de ancho. */
@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo-normal.woff2") format("woff2");
  font-weight: 400 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo-italic.woff2") format("woff2");
  font-weight: 400 900;
  font-stretch: 75% 105%;
  font-style: italic;
  font-display: swap;
}

:root {
  --yellow: #fde003;       /* igual al amarillo de la publicidad */
  --ink: #16130a;
  --paper: #fff7c9;
  --white: #fff;
  --ink-soft: #3a3420;     /* texto secundario sobre amarillo (contraste > 9:1); también el hover de los botones negros */
  --ink-mute: #6b6447;     /* placeholders (5,9:1 sobre blanco) */
  --err: #a1160a;

  --gutter: 16px;
  --max: 1120px;
  --radius: 10px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --head: 64px;            /* alto del header fijo */
  --sec-pad: 52px;         /* aire superior de las secciones con ancla */
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scrollbar-color: var(--ink) var(--yellow); }
body {
  margin: 0;
  font-family: "Archivo", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.5;
  color: var(--ink);
  background: var(--yellow);
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-underline-offset: 0.2em; text-decoration-thickness: 2px; }
[hidden] { display: none !important; }

::selection { background: var(--ink); color: var(--yellow); }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 4px; }
input, textarea { caret-color: var(--ink); accent-color: var(--ink); }

/* El header fijo no tapa los títulos al saltar a un ancla */
section[id] { scroll-margin-top: calc(var(--head) - var(--sec-pad) + 20px); }
.zone, #quote-title { scroll-margin-top: calc(var(--head) + 20px); }

.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.skip {
  position: absolute; left: var(--gutter); top: -100px; z-index: 20;
  background: var(--ink); color: var(--yellow); padding: 12px 16px; font-weight: 700;
}
.skip:focus { top: 8px; }

/* Títulos de sección */
.h2 {
  font-style: italic; font-weight: 900; font-stretch: 85%;
  font-size: clamp(2rem, 8vw, 3rem); line-height: 1; letter-spacing: -0.01em;
  text-wrap: balance;
}
.h2--sm { font-size: clamp(1.6rem, 6vw, 2.2rem); }
.formbox .h2 { font-size: clamp(2.2rem, 9vw, 3.4rem); }

/* Botones */
.ico { width: 1.35em; height: 1.35em; flex: none; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.6em;
  min-height: 56px; padding: 0 min(1.4em, 5.5vw);
  font: inherit; font-weight: 800; font-size: 1.0625rem;
  text-decoration: none; text-align: center; cursor: pointer;
  border: 0; border-radius: var(--radius);
  transition: transform 0.15s var(--ease), background-color 0.15s;
}
.btn--black { background: var(--ink); color: var(--yellow); box-shadow: 0 6px 14px -6px rgba(22, 19, 10, 0.55); }
.btn--yellow { background: var(--yellow); color: var(--ink); }
.btn--black:hover { background: var(--ink-soft); transform: translateY(-2px); }
.btn--yellow:hover { background: var(--white); transform: translateY(-2px); }
.btn:active { transform: translateY(1px); }
.btn--lg { min-height: 64px; font-size: 1.1875rem; }
.btn--sm { min-height: 44px; padding: 0 0.9em; font-size: 0.875rem; gap: 0.45em; white-space: nowrap; }
.btn--block { width: 100%; }
.top a:focus-visible, .joke a:focus-visible, .foot a:focus-visible { outline-color: var(--yellow); }
.top .btn--yellow:focus-visible { outline-color: var(--white); }

/* Encabezado fijo */
.top { position: sticky; top: 0; z-index: 10; background: var(--ink); color: var(--yellow); }
.top__row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0 10px; min-height: var(--head); }
.brand {
  text-decoration: none; color: var(--yellow);
  font-style: italic; font-weight: 900; font-stretch: 100%;
  font-size: 1.25rem; line-height: 1; letter-spacing: 0.005em; text-transform: uppercase;
}
.brand span { color: var(--white); }
.brand { display: inline-flex; align-items: center; gap: 0.28em; min-height: 44px; white-space: nowrap; }
.long { display: none; }

/* Hero: la camioneta recortada sobre el amarillo, con la trompa metida en la banda negra */
.hero { position: relative; z-index: 2; padding-block: 28px 12px; overflow-x: clip; }
.hero__grid { display: grid; gap: 20px; }
.hero__title { font-style: italic; font-weight: 900; text-transform: uppercase; line-height: 0.95; }
.plate {
  display: inline-block; background: var(--ink); color: var(--yellow);
  padding: 0.04em 0.28em 0.1em; transform: skewX(-9deg);
  font-size: clamp(2.2rem, 17.5vw, 6rem); font-stretch: 105%; letter-spacing: 0.005em;
}
.plate > span { display: inline-block; transform: skewX(9deg); }
.hero__y {
  display: block; margin-top: 0.08em;
  font-size: clamp(1.7rem, 13.2vw, 4.6rem); font-stretch: 85%; letter-spacing: 0.005em;
}
.hero__lead { margin-top: 18px; max-width: 30ch; font-size: 1.25rem; line-height: 1.35; font-weight: 600; text-wrap: pretty; }
.hero__actions { margin-top: 24px; display: grid; gap: 14px; justify-items: start; }
.hero__actions .btn { width: 100%; }
.hero__phone { font-weight: 600; color: var(--ink-soft); }
.hero__phone a { display: inline-block; padding-block: 10px; margin-block: -10px; color: var(--ink); font-weight: 800; }

.hero__photo { position: relative; }
.hero__photo img { width: 100%; height: auto; }
.hero__photo::after { /* sombra de apoyo bajo las ruedas, no es una tarjeta */
  content: ""; position: absolute; left: 12%; right: 6%; bottom: 1%; height: 7%; z-index: -1;
  background: radial-gradient(closest-side, rgba(22, 19, 10, 0.45), rgba(22, 19, 10, 0));
}
.speed { display: none; }

/* Chiste: un golpe corto, de lado a lado */
.joke { position: relative; z-index: 1; background: var(--ink); color: var(--yellow); padding-block: 56px 44px; }
.joke::before {
  content: ""; position: absolute; left: 0; right: 0; top: -1px; height: 22px;
  background: var(--yellow); clip-path: polygon(0 0, 100% 0, 0 100%);
}
.joke__grid { display: grid; gap: 24px; align-items: center; }
.joke__q {
  font-style: italic; font-weight: 800; font-stretch: 78%; text-transform: uppercase;
  font-size: clamp(2rem, 9.4vw, 3.8rem); line-height: 1; text-wrap: balance;
}
.joke__a {
  margin-top: 14px; color: var(--white);
  font-style: italic; font-weight: 900; font-stretch: 90%; text-transform: uppercase;
  font-size: clamp(1.8rem, 13vw, 5.2rem); line-height: 1;
}
/* Remate: la placa amarilla y el botón van pegados, un poco torcidos, como el trazo de la publicidad */
.joke__cta { display: grid; transform: rotate(-1.5deg); max-width: 460px; }
.joke__call {
  background: var(--yellow); color: var(--ink); padding: 0.55em 0.8em 0.5em;
  border-radius: var(--radius) var(--radius) 0 0;
  font-style: italic; font-weight: 900; font-stretch: 85%; text-transform: uppercase;
  font-size: clamp(1.4rem, 6vw, 1.9rem); line-height: 1.05;
}
.joke__btn {
  display: flex; align-items: center; justify-content: center; gap: 0.6em; min-height: 60px; padding: 0 1em;
  background: var(--white); color: var(--ink); border-radius: 0 0 var(--radius) var(--radius);
  font-weight: 800; font-size: 1.0625rem; text-decoration: none;
  transition: background-color 0.15s;
}
.joke__btn:hover { background: var(--paper); }

/* Servicios */
.services { background: var(--paper); padding-block: var(--sec-pad); }
.services__list { margin-top: 20px; border-top: 3px solid var(--ink); }
.service { display: grid; gap: 4px; padding-block: 18px 20px; border-bottom: 3px solid var(--ink); }
.service__title {
  font-style: italic; font-weight: 900; font-stretch: 90%; text-transform: uppercase;
  font-size: clamp(1.6rem, 6vw, 2rem); line-height: 1.05;
}
.service__text { max-width: 46ch; font-size: 1.125rem; color: var(--ink-soft); }

/* Zona + cómo funciona + formulario */
.quote { padding-block: var(--sec-pad); }
.quote__grid { display: grid; gap: 44px; }
.quote__side { display: grid; gap: 40px; align-content: start; }
.zone__text { margin-top: 14px; max-width: 42ch; font-size: 1.125rem; font-weight: 500; }
.zone__places { margin-top: 18px; display: flex; flex-wrap: wrap; gap: 8px; }
.zone__places li {
  background: var(--ink); color: var(--yellow); font-weight: 800; font-style: italic;
  padding: 6px 16px 8px; transform: skewX(-8deg);
}
.how__list { margin-top: 18px; display: grid; gap: 14px; }
.how__list li { display: grid; grid-template-columns: 44px 1fr; gap: 14px; align-items: center; }
.how__n {
  display: grid; place-items: center; width: 44px; height: 44px;
  background: var(--ink); color: var(--yellow); transform: skewX(-8deg);
  font-style: italic; font-weight: 900; font-size: 1.4rem; line-height: 1;
}
.how__list p { font-size: 1.0625rem; font-weight: 600; max-width: 34ch; }

.formbox__lead { margin-top: 10px; max-width: 44ch; font-size: 1.0625rem; color: var(--ink-soft); font-weight: 500; }
form { margin-top: 22px; display: grid; gap: 18px; }
.field { display: grid; gap: 6px; min-width: 0; }
.field-row { display: grid; gap: 18px; }
label { font-weight: 800; font-size: 1rem; }
.opt { font-weight: 500; color: var(--ink-soft); }
input, textarea {
  width: 100%; font: inherit; font-size: 1rem; /* 16px evita el zoom en iOS */
  color: var(--ink); background: var(--white);
  border: 2px solid var(--ink); border-radius: var(--radius);
  padding: 14px 14px; min-height: 52px;
}
textarea { resize: vertical; min-height: 116px; }
input::placeholder, textarea::placeholder { color: var(--ink-mute); opacity: 1; }
input:hover, textarea:hover { box-shadow: 0 0 0 1px var(--ink); }
input:focus-visible, textarea:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; }
input[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: var(--err); box-shadow: 0 0 0 2px var(--err); }
.err { color: var(--err); font-weight: 700; font-size: 0.9375rem; }
.formbox__note { font-size: 0.9375rem; color: var(--ink-soft); font-weight: 500; }
.status { padding: 14px 16px; background: var(--ink); color: var(--yellow); border-radius: var(--radius); font-weight: 600; }
.status a { color: var(--white); font-weight: 800; }

/* Pie */
.foot { background: var(--ink); color: var(--yellow); padding-block: 40px 44px; }
.foot__grid { display: grid; gap: 20px; }
.foot__brand { font-style: italic; font-weight: 900; text-transform: uppercase; line-height: 1; font-size: 1.75rem; }
.foot__brand span { color: var(--white); }
.foot__phone {
  margin-top: 14px; display: inline-flex; align-items: center; gap: 10px;
  font-weight: 800; font-size: 1.5rem; text-decoration: none; color: var(--yellow); min-height: 48px;
}
.foot__phone:hover, .foot__social a:hover { color: var(--white); }
.foot__social { display: flex; flex-direction: column; }
.foot__social a {
  display: inline-flex; align-items: center; gap: 10px; min-height: 48px;
  color: var(--yellow); text-decoration: none; font-weight: 700; font-size: 1.0625rem;
}

/* Columna única que no crece con su contenido; las palabras largas solo se cortan si no entran (zoom 200%) */
.hero__grid, .joke__grid, .quote__grid, .foot__grid { grid-template-columns: minmax(0, 1fr); }
h1, h2, .btn { overflow-wrap: anywhere; }
.plate { overflow-wrap: normal; }

/* Entrada única al cargar: la camioneta llega con sus líneas de velocidad */
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
  .hero__photo img { animation: arrive 0.9s var(--ease) both; }
  .plate { animation: plate-in 0.7s var(--ease) both; }
  .speed i { animation: streak 0.8s var(--ease) 0.2s both; }
  @keyframes arrive { from { opacity: 0; transform: translateX(8%); } to { opacity: 1; transform: none; } }
  @keyframes plate-in { from { opacity: 0; transform: skewX(-9deg) translateX(-14%); } to { opacity: 1; transform: skewX(-9deg); } }
  @keyframes streak { from { transform: scaleX(0); } to { transform: scaleX(1); } }
}

/* Ancho medio */
@media (min-width: 480px) { .long { display: inline; } }
@media (min-width: 600px) {
  :root { --gutter: 24px; }
  .hero__actions .btn { width: auto; }
  .field-row { grid-template-columns: 1fr 1fr; }
  .foot__social { flex-direction: row; flex-wrap: wrap; gap: 8px 22px; }
  .brand { font-size: 1.5rem; }
  .btn--sm { font-size: 1rem; padding: 0 1.2em; }
}

/* Escritorio */
@media (min-width: 900px) {
  :root { --gutter: 32px; --head: 72px; --sec-pad: 80px; }
  .hero { padding-block: 56px 0; }
  .hero__grid { grid-template-columns: minmax(0, 6fr) minmax(0, 7fr); gap: 40px; align-items: center; }
  .plate { font-size: clamp(4.6rem, 8vw, 6rem); }
  .hero__y { font-size: clamp(2.8rem, 4.8vw, 4.2rem); white-space: nowrap; }
  .hero__photo { margin: 0 -24px -96px 0; }
  .speed { display: block; position: absolute; inset: 0 auto 0 0; }
  .speed i {
    position: absolute; right: 100%; height: 5px; background: var(--ink); border-radius: 3px;
    margin-right: -6px; transform-origin: right center;
  }
  .speed i:nth-child(1) { top: 34%; width: 46px; }
  .speed i:nth-child(2) { top: 41%; width: 26px; }
  .speed i:nth-child(3) { top: 48%; width: 38px; }
  .joke { padding-block: 112px 48px; }
  .joke__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 420px); gap: 56px; }
  .joke::before { height: 36px; }
  .services__list { display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: auto 1fr; border-top: 0; margin-top: 32px; gap: 0 40px; }
  .service { grid-row: span 2; grid-template-rows: subgrid; row-gap: 4px; border-top: 3px solid var(--ink); border-bottom: 0; padding-block: 20px 0; }
  .quote__grid { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 72px; align-items: start; }
  .foot__grid { grid-template-columns: 1fr auto; align-items: center; }
  .foot__social { justify-content: flex-end; }
}
@media (min-width: 900px) and (min-height: 820px) { .quote__side { position: sticky; top: 104px; } }
@media (min-width: 1280px) { .hero__photo { margin-right: -48px; } }
@media (min-width: 600px) and (max-width: 899px) { .hero__photo { max-width: 640px; margin-inline: auto; } }

/* Redes sin enlace (href vacío) no se muestran */
.foot__social a[href=""], .foot__social li:has(a[href=""]) { display: none; }

/* Volver arriba: fijo abajo a la derecha; solo visible (y enfocable) cuando corresponde */
.to-top {
  position: fixed; right: 16px; bottom: 16px; z-index: 9;
  display: grid; place-items: center; width: 48px; height: 48px;
  background: var(--ink); color: var(--yellow); border: 2px solid var(--yellow); border-radius: var(--radius);
  box-shadow: 0 6px 14px -6px rgba(22, 19, 10, 0.55);
  visibility: hidden; opacity: 0; transform: translateY(8px);
  transition: opacity 0.2s, transform 0.2s var(--ease), visibility 0s 0.2s;
}
.to-top.is-on { visibility: visible; opacity: 1; transform: none; transition-delay: 0s; }
.to-top:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; box-shadow: 0 0 0 3px var(--ink); } /* aro doble: se ve sobre amarillo y sobre negro */
.to-top:hover { background: var(--ink-soft); }
@media (min-width: 900px) { .to-top { right: 24px; bottom: 24px; } }
@media (min-width: 1200px) { .joke__a { white-space: nowrap; } }
