/* ───────────────────────── Landing page (loaded after f1.css) ───────────────────────── */

/* ── HERO: copy on the left, courier timing board on the right, a track behind both ── */
.hero.landing {
  min-height: 0;
  padding: 118px 1.5rem 4.5rem;
  align-items: stretch;
  text-align: center;
}
.hero-inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 3rem;
  align-items: center;
}
.hero-copy { display: flex; flex-direction: column; align-items: center; min-width: 0; }
.hero.landing h1 {
  font-size: clamp(2rem, 8.2vw, 4.4rem);
  line-height: 0.92;
  letter-spacing: -0.045em;
  margin-bottom: 1.4rem;
}
.hero.landing .hero-sub { max-width: 520px; margin-bottom: 1.8rem; min-height: 0; }

/* the detect-and-track box */
.quick { width: 100%; max-width: 580px; margin: 0 0 1.4rem; text-align: left; animation: fadeUp 0.6s 0.25s ease both; }
.quick-box {
  display: flex;
  align-items: stretch;
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-left: 5px solid var(--f1-red);
  border-radius: 3px;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.quick-box:focus-within { border-color: var(--accent-color, var(--f1-red)); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent-color, var(--f1-red)) 20%, transparent); }
.quick-box input {
  flex: 1;
  min-width: 0;
  height: 58px;
  padding: 0 16px;
  background: transparent;
  border: 0;
  outline: 0;
  color: var(--text);
  font-family: var(--mono);
  font-size: 16px;               /* 16px stops iPhones zooming in */
}
.quick-box input::placeholder { color: var(--text3); font-size: 14px; }
.quick-go {
  flex-shrink: 0;
  margin: 6px;
  padding: 0 22px;
  border: 0;
  background: var(--f1-red);
  color: #fff;
  font-family: var(--display);
  font-size: 13px;
  cursor: pointer;
}
.quick-go:active { transform: scale(0.97); }
.quick-err { min-height: 18px; margin: 8px 0 0; color: #ff5a52; font-family: var(--mono); font-size: 12.5px; }
.quick-result { margin-top: 2px; }
.quick-result[hidden] { display: none; }
.qr-num { font-family: var(--mono); font-size: 12px; color: var(--text3); margin-bottom: 8px; word-break: break-all; }
.qr-maybe { font-size: 12.5px; color: var(--text2); margin-bottom: 6px; }
.qr-row {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 9px 10px 9px 14px; margin-top: 6px;
  background: var(--bg2); border: 1px solid var(--border2); border-left: 4px solid var(--c); border-radius: 3px;
}
.qr-name { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--text); font-size: 15px; min-width: 0; flex-wrap: wrap; }
.qr-name i { width: 9px; height: 9px; border-radius: 50%; background: var(--c); flex-shrink: 0; }
.qr-name em { font-style: normal; font-family: var(--mono); font-size: 10px; font-weight: 500; color: var(--text2); border: 1px solid var(--border2); padding: 1px 8px; }
.qr-btn {
  flex-shrink: 0; min-height: 38px; padding: 0 16px; display: inline-flex; align-items: center;
  border: 1px solid var(--border2); background: transparent; color: var(--text2);
  font-family: var(--mono); font-size: 12px; text-decoration: none; cursor: pointer; border-radius: 3px;
}
.qr-btn.main { background: var(--c); border-color: transparent; color: #fff; font-weight: 700; }

.hero.landing .hero-actions { margin-top: 0.4rem; }

/* the track drawn behind the hero, with a car that keeps lapping */
.hero-circuit {
  position: absolute;
  right: -18%;
  bottom: -4%;
  width: 118%;
  max-width: 900px;
  opacity: 0.28;
  pointer-events: none;
}
.circuit-glow { fill: none; stroke: var(--accent-color, var(--f1-red)); stroke-width: 16; stroke-linejoin: round; opacity: 0.16; }
.circuit-line { fill: none; stroke: var(--accent-color, var(--f1-red)); stroke-width: 4; stroke-linejoin: round; stroke-dasharray: 2 0; }
.circuit-start { stroke: var(--text); stroke-width: 5; stroke-dasharray: 5 5; opacity: 0.85; }
.circuit-car { fill: #fff; stroke: var(--accent-color, var(--f1-red)); stroke-width: 3; }

/* the timing board (wide screens only) */
.board { display: none; }

@media (min-width: 1000px) {
  .hero.landing { text-align: left; padding-top: 128px; }
  .hero.landing h1 { font-size: clamp(2.6rem, 4.7vw, 4.9rem); }
  .hero-inner { grid-template-columns: minmax(0, 1.25fr) minmax(320px, 0.75fr); gap: 3.5rem; }
  .hero-copy { align-items: flex-start; }
  #heroAccent { justify-items: start; }
  .hero.landing .hero-actions { justify-content: flex-start; }
  .hero-circuit { right: -2%; bottom: auto; top: 8%; width: 62%; opacity: 0.4; }

  .board {
    display: block;
    background: color-mix(in srgb, var(--bg2) 92%, transparent);
    border: 1px solid var(--border2);
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
    animation: fadeUp 0.7s 0.2s ease both;
  }
  .board-head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 10px 14px;
    background: var(--f1-red);
    color: #fff;
    font-family: var(--mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; font-weight: 500;
  }
  .board-flag {
    width: 22px; height: 14px;
    background: repeating-conic-gradient(#fff 0% 25%, #111 0% 50%) 0 0 / 7px 7px;
    border: 1px solid rgba(255, 255, 255, 0.6);
  }
  .board-list { list-style: none; margin: 0; padding: 0; }
  .board-row {
    display: grid;
    grid-template-columns: 22px 4px 40px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    padding: 0 14px 0 12px;
    height: 34px;
    border-bottom: 1px solid var(--border);
    font-family: var(--mono);
    font-size: 12px;
    color: var(--text2);
    transition: background 0.4s, color 0.4s;
  }
  .board-row:last-child { border-bottom: 0; }
  .bp { text-align: right; color: var(--text3); }
  .bbar { height: 18px; background: var(--c); }
  .bcode { font-weight: 500; color: var(--text); letter-spacing: 0.06em; }
  .bname { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .bstat { font-size: 10px; letter-spacing: 0.1em; color: var(--text3); }
  .board-row.active { background: color-mix(in srgb, var(--c) 18%, transparent); color: var(--text); }
  .board-row.active .bstat { color: var(--c); font-weight: 500; }
}

/* ── TICKER: a broadcast-style band of couriers scrolling past ── */
.ticker {
  position: relative;
  overflow: hidden;
  background: var(--f1-red);
  color: #fff;
  border-top: 2px solid #fff;
  border-bottom: 2px solid #fff;
  padding: 11px 0;
  white-space: nowrap;
}
.ticker-track { display: inline-flex; gap: 0; animation: ticker 48s linear infinite; will-change: transform; }
.tick {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 0 28px;
  font-family: var(--display); font-weight: 800; font-style: italic;
  font-size: 15px; letter-spacing: 0.08em; text-transform: uppercase;
}
.tick i { width: 12px; height: 12px; background: var(--c); border: 2px solid #fff; transform: skewX(-20deg); }
@keyframes ticker { to { transform: translateX(-50%); } }
.ticker:hover .ticker-track { animation-play-state: paused; }

/* ── TELEMETRY: big numbers ── */
.telemetry {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  max-width: 1100px;
  margin: 3rem auto 0;
  padding: 0 1.25rem;
}
.stat {
  position: relative;
  padding: 1.3rem 1.2rem 1.1rem;
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-top: 4px solid var(--f1-red);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%);
}
.stat b {
  display: block;
  font-family: var(--display);
  font-weight: 800;
  font-style: italic;
  font-size: clamp(2.6rem, 9vw, 4.4rem);
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--text);
}
.stat span { display: block; margin-top: 0.5rem; font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text2); }
html:not(:lang(en)) .stat span { text-transform: none; letter-spacing: 0.03em; }
@media (min-width: 760px) { .telemetry { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; } }

/* ── Sections ── */
.land-section { max-width: 1100px; margin: 0 auto; padding: 5rem 1.25rem 2rem; text-align: left; scroll-margin-top: 24px; }
.land-section h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2.1rem, 6.4vw, 3.8rem);
  line-height: 0.98;
  letter-spacing: -0.04em;
  margin: 0 0 0.9rem;
  text-align: left;
}
.land-lead { max-width: 560px; margin: 0 0 2rem; font-size: 1.02rem; color: var(--text2); line-height: 1.6; text-align: left; }

/* THE GRID: the couriers as a staggered starting grid */
.ledger {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 22px;
  margin: 0;
  padding: 0 0 28px;
  border: 0;
  background: none;
  border-radius: 0;
  overflow: visible;
}
.ledger-row {
  display: flex;
  align-items: center;
  gap: 12px;
  grid-template-columns: none;
  padding: 16px 14px 16px 12px;
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-left: 5px solid var(--c);
  border-radius: 3px;
  text-decoration: none;
  color: var(--text);
  transition: transform 0.18s, background 0.18s, border-color 0.18s;
}
.ledger-row:nth-child(even) { transform: translateY(26px); }
.ledger-row:hover { background: color-mix(in srgb, var(--c) 12%, var(--bg2)); border-color: var(--c); transform: translateY(-3px); }
.ledger-row:nth-child(even):hover { transform: translateY(23px); }
.ledger-pos { min-width: 2.1ch; font-family: var(--display); font-weight: 800; font-style: italic; font-size: 1.25rem; color: var(--text3); letter-spacing: -0.03em; }
.ledger-dot { display: none; }
.ledger-name { flex: 1; min-width: 0; font-weight: 700; font-size: 1.02rem; letter-spacing: -0.01em; }
.ledger-site { display: none; }
.ledger-row svg { flex-shrink: 0; }
@media (min-width: 700px) {
  .ledger { gap: 14px 30px; }
  .ledger-row { padding: 20px 20px 20px 16px; }
  .ledger-pos { font-size: 1.6rem; }
  .ledger-name { font-size: 1.15rem; }
  .ledger-site { display: block; font-family: var(--mono); font-size: 11px; color: var(--text3); }
}

/* PIT STOP: the three steps */
.how { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; border: 0; background: none; border-radius: 0; overflow: visible; }
.how-step {
  position: relative;
  padding: 1.6rem 1.4rem 1.5rem;
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-top: 4px solid var(--f1-red);
  border-radius: 3px;
}
.how-step + .how-step { border-left: 1px solid var(--border2); border-top: 4px solid var(--f1-red); }
.how-num {
  font-family: var(--display); font-weight: 800; font-style: italic;
  font-size: 4.6rem; line-height: 1; letter-spacing: -0.04em;
  color: transparent;
  -webkit-text-stroke: 2px var(--f1-red);
  margin-bottom: 0.6rem;
}
.how-title { font-family: var(--display); font-weight: 800; font-size: 1.15rem; letter-spacing: -0.02em; margin-bottom: 0.5rem; color: var(--text); }
.how-desc { font-size: 14px; line-height: 1.65; color: var(--text2); }
@media (min-width: 820px) {
  .how { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
  .how-step:not(:last-child)::after {
    content: '';
    position: absolute;
    right: -24px; top: 50%;
    border-left: 14px solid var(--f1-red);
    border-top: 10px solid transparent;
    border-bottom: 10px solid transparent;
  }
}

/* TECH SPEC: the feature cards */
.features { max-width: 1100px; margin: 0 auto; padding: 4rem 1.25rem 3rem; text-align: left; }
.features h2.features-title {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2rem, 5.6vw, 3.4rem);
  line-height: 1;
  letter-spacing: -0.04em;
  margin: 0 0 2rem;
  text-align: left;
}
.features-title .h2-line { display: block; white-space: nowrap; }
.features-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; margin: 0; }
.feat-card {
  position: relative;
  padding: 1.5rem 1.4rem 1.4rem;
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-left: 5px solid var(--f1-red);
  transition: border-color 0.2s, background 0.2s, transform 0.25s, opacity 0.5s;
}
.feat-card:hover { background: var(--bg3); transform: translateY(-4px) !important; }
.feat-icon {
  width: 46px; height: 46px; margin-bottom: 1rem;
  display: grid; place-items: center;
  background: var(--f1-red); color: #fff; border: 0;
  clip-path: polygon(0 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
}
.feat-title { font-family: var(--display); font-weight: 800; font-size: 1.1rem; letter-spacing: -0.02em; margin-bottom: 0.45rem; color: var(--text); }
.feat-desc { font-size: 14px; line-height: 1.65; color: var(--text2); }
@media (min-width: 620px) { .features-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 960px) { .features-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; } }

/* CLOSING BAND */
.land-cta {
  position: relative;
  margin: 3rem 0 2rem;
  padding: 5.5rem 1.5rem 5rem;
  text-align: center;
  background: linear-gradient(105deg, var(--f1-red-dark) 0%, var(--f1-red) 55%, #ff2a1f 100%);
  color: #fff;
  border: 0;
  clip-path: polygon(0 0, 100% 5%, 100% 100%, 0 95%);
}
.land-cta::before {
  content: '';
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 12px;
  background: repeating-conic-gradient(#fff 0% 25%, #111 0% 50%) 0 0 / 12px 12px;
  opacity: 0.55;
}
.land-cta-in { position: relative; max-width: 900px; margin: 0 auto; }
.land-cta h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2.2rem, 7vw, 4.6rem);
  line-height: 0.98;
  letter-spacing: -0.045em;
  color: #fff;
  margin: 0 0 2rem;
}
.land-cta .btn-primary { background: #fff; color: #111; }
.land-cta .btn-primary::before { background: linear-gradient(100deg, transparent, rgba(225, 6, 0, 0.25), transparent); }

/* ── Phones: calmer spacing, nothing cut off ── */
@media (max-width: 600px) {
  .hero.landing { padding: 104px 1.1rem 3rem; }
  .quick-box { flex-direction: column; }
  .quick-box input { flex: none; width: 100%; height: 54px; padding: 0 14px; }
  .quick-go { flex: none; margin: 0 8px 8px; height: 48px; padding: 0 14px; font-size: 13px; justify-content: center; }
  .hero.landing .hero-actions { flex-direction: column; align-items: stretch; width: 100%; max-width: 580px; }
  .hero.landing .hero-actions .btn { flex: none; min-height: 52px; display: flex; align-items: center; justify-content: center; text-align: center; }
  .land-section { padding: 3.5rem 1.1rem 1.5rem; }
  .land-section h2 { font-size: clamp(1.8rem, 8.4vw, 2.6rem); }
  .land-lead { font-size: 14px; margin-bottom: 1.5rem; }
  .features { padding: 3rem 1.1rem 2.5rem; }
  .features h2.features-title { font-size: clamp(1.4rem, 7.4vw, 2rem); }
  .land-cta { padding: 4.5rem 1.2rem 4rem; }
}

@media (prefers-reduced-motion: reduce) {
  .ticker-track { animation: none; }
  .circuit-car { display: none; }
  .ledger-row, .ledger-row:hover, .feat-card:hover { transition: none; }
}

.features h2, .features h2.features-title, .features-title .h2-line { text-align: left; }

/* the number gives a small pop when its count finishes */
.stat b.done { animation: statPop 0.45s ease; }
@keyframes statPop { 0% { transform: scale(1); } 40% { transform: scale(1.12); } 100% { transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { .stat b.done { animation: none; } }
