/* MT-RIDE-1 · F1 — sistema visual de la landing (PIEZA-G-MARCA):
   grabado duotono sobre crema. Fondo crema cálido tipo pergamino,
   verde bosque como único acento de acción, titular sans geométrica
   extra-negrita casi negro, fuentes de datos en monoespaciada pequeña.
   Prohibidos (G-MARCA.8): gradientes genéricos, estética casino/trading,
   neón ajeno al hero, métricas decorativas sin fuente. */
:root {
  --cream: #F2EBDA;
  --ink: #171A17;
  --forest: #1E4D2B;
  --forest-dark: #14331C;
  --charcoal: #3A3F3A;
  --sage: #6B7263;
  --line: #D8CFB8;
  --radius-cta: 9px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: "Avenir Next", "Segoe UI", system-ui, -apple-system, sans-serif;
  line-height: 1.5;
}
.skip {
  position: absolute; left: -999px; top: 0; background: var(--ink); color: #fff;
  padding: 0.5rem 1rem; z-index: 20;
}
.skip:focus { left: 0; }
a { color: var(--forest-dark); }
a:focus-visible, button:focus-visible, input:focus-visible, summary:focus-visible {
  outline: 3px solid var(--forest); outline-offset: 2px;
}
.site-head {
  display: flex; flex-wrap: wrap; gap: 0.75rem 1.5rem; align-items: baseline;
  max-width: 1100px; margin: 0 auto; padding: 1rem 1.25rem 0;
}
.brand { font-weight: 800; margin: 0; }
.brand span { font-weight: 400; color: var(--charcoal); font-size: 0.85em; }
.site-head nav { display: flex; flex-wrap: wrap; gap: 0.4rem 1rem; }
.site-head nav a { text-decoration: none; font-size: 0.95rem; }
.site-head nav a[aria-current="page"] { text-decoration: underline; font-weight: 700; }
.lang-switch { margin-left: auto; display: flex; gap: 0.25rem; }
.lang-btn {
  border: 1px solid var(--sage); background: transparent; color: var(--ink);
  border-radius: 6px; padding: 0.2rem 0.55rem; cursor: pointer; font: inherit; font-size: 0.85rem;
}
.lang-btn[aria-pressed="true"] { background: var(--forest); color: #fff; border-color: var(--forest); }
main { max-width: 1100px; margin: 0 auto; padding: 0 1.25rem 3rem; }
h1 { font-weight: 800; letter-spacing: -0.01em; line-height: 1.05; }
.mono, .source-line, .formula { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; }
.sim-badge {
  display: inline-block; border: 1px solid var(--forest); color: var(--forest-dark);
  border-radius: 6px; padding: 0.15rem 0.6rem; font-size: 0.85rem; font-weight: 600;
}
.lines { list-style: none; padding: 0; }
.lines li {
  display: flex; justify-content: space-between; gap: 1rem;
  border-bottom: 1px solid var(--line); padding: 0.45rem 0;
}
.limit-note { border-left: 4px solid var(--forest); padding-left: 0.8rem; }
input[type="number"] {
  font: inherit; padding: 0.35rem 0.5rem; border: 1px solid var(--sage);
  border-radius: 6px; background: #FFFDF6; color: var(--ink); max-width: 12rem;
}
.calculator label { display: block; margin: 0.5rem 0; }
details { border-bottom: 1px solid var(--line); padding: 0.6rem 0; }
summary { cursor: pointer; font-weight: 700; }
.site-foot {
  max-width: 1100px; margin: 0 auto; padding: 1.5rem 1.25rem 2.5rem;
  border-top: 1px solid var(--line); color: var(--charcoal); font-size: 0.9rem;
}

/* ---------- HERO (F1.1): columna única ~800px, un solo CTA por lámina,
   ilustración 45–50% inferior con borde superior difuminado irregular. */
.hero { max-width: 800px; margin: 0 auto; text-align: center; position: relative; }
.slides { position: relative; }
.slide { display: none; padding-top: 1.5rem; }
.slide.active { display: block; }
.pill {
  display: inline-block; border: 1px solid var(--sage); border-radius: 999px;
  padding: 0.2rem 0.9rem; font-size: 0.85rem; color: var(--charcoal); background: #FBF7EA;
}
.headline {
  font-size: clamp(2.2rem, 6vw, 3.6rem); font-weight: 800; line-height: 1.05;
  letter-spacing: -0.015em; margin: 1rem auto 0.75rem; max-width: 640px;
}
.sub { font-size: 1.2rem; max-width: 600px; margin: 0 auto; color: var(--charcoal); }
.proof-line { margin: 1rem auto 0.25rem; font-weight: 600; }
.proof-line .dot {
  display: inline-block; width: 0.6em; height: 0.6em; border-radius: 50%;
  background: var(--forest); margin-right: 0.5em;
}
.source-line { font-size: 0.75rem; color: var(--charcoal); margin: 0 auto 1.25rem; }
.cta {
  display: inline-block; background: var(--forest); color: #fff; font-weight: 700;
  text-decoration: none; border-radius: var(--radius-cta); padding: 0.8rem 1.9rem;
}
.cta:hover { background: var(--forest-dark); }
.visual-anim {
  position: relative; height: 84px; max-width: 560px; margin: 1.5rem auto 0;
}
.visual-anim .route {
  position: absolute; left: 8%; right: 8%; top: 50%;
  border-top: 3px dashed var(--sage);
}
.visual-anim .pin {
  position: absolute; top: 50%; width: 16px; height: 16px; border-radius: 50%;
  background: var(--forest); transform: translate(-50%, -50%);
  animation: pin-pulse 2.4s ease-in-out infinite;
}
.visual-anim .pin:nth-child(1) { left: 14%; }
.visual-anim .pin:nth-child(2) { left: 50%; animation-delay: 0.5s; }
.visual-anim .pin:nth-child(3) { left: 86%; animation-delay: 1s; }
@keyframes pin-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(30, 77, 43, 0.35); }
  50% { box-shadow: 0 0 0 10px rgba(30, 77, 43, 0); }
}
.illustration { margin: 0; }
.illustration-frame {
  height: 46vh; min-height: 260px; margin-top: 1rem;
  border: 2px solid var(--charcoal);
  background: #E7DCC3;
  color: var(--charcoal);
  display: flex; flex-direction: column; justify-content: flex-end; gap: 0.5rem;
  padding: 1.25rem; text-align: left;
  /* Borde superior difuminado irregular (efecto papel rasgado, F1.1):
     la máscara degrada el borde de forma no uniforme vía clip-path dentado. */
  clip-path: polygon(0 3%, 6% 1%, 13% 3.5%, 22% 1.5%, 31% 3%, 42% 1%, 53% 3.2%, 63% 1.4%, 74% 3%, 84% 1.2%, 93% 3.4%, 100% 1.6%, 100% 100%, 0 100%);
}
.illustration-frame .scene { margin: 0; font-size: 0.95rem; }
.illustration-frame .scene-ref { margin: 0; font-size: 0.8rem; font-style: italic; }
.illustration figcaption { font-size: 0.85rem; color: var(--charcoal); padding-top: 0.5rem; }
.hero-controls {
  display: flex; align-items: center; justify-content: space-between;
  max-width: 800px; margin: 0.75rem auto 0;
}
.arrow {
  width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--sage);
  background: rgba(255, 253, 246, 0.75); color: var(--ink); font-size: 1.1rem; cursor: pointer;
}
.dots { display: flex; gap: 0.5rem; }
.dot-btn {
  width: 14px; height: 14px; border-radius: 50%; border: 1px solid var(--charcoal);
  background: transparent; cursor: pointer; padding: 0;
}
.dot-btn[aria-selected="true"] { background: var(--ink); }
.stories, .thesis { max-width: 800px; margin: 3rem auto 0; }

/* ---------- Móvil (F1.5): se conserva la estructura completa del hero. */
@media (max-width: 640px) {
  .headline { font-size: 2.1rem; }
  .sub { font-size: 1.05rem; }
  .illustration-frame { height: 46vh; min-height: 220px; }
  .site-head nav { order: 3; }
  .lang-switch { margin-left: 0; }
}

/* ---------- Reduced motion (F1.4/F1.11): sin auto-rotación ni animación. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .visual-anim .pin { animation: none; }
  * { transition: none !important; }
}
