:root {
  --green: #00d864;
  --ink: #f6faf8;
  --ink-soft: #f2f2f2;
  --muted: #b8c9c1;
  --placeholder: #7c9188;
  --blue: #245dcc;
  --blue-hover: #2b6ae3;
  --board-bg: #081e19;
  --tile-bg: #04100c;
  --field-bg: #061711;
  --eyebrow-bg: #0a291b;
  --font: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html, body { margin: 0; }

body {
  background: #000;
  color: var(--ink);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
}

p, h1, ul { margin: 0; }

/* ---------- Hero frame ---------- */

.hero {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  isolation: isolate;
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: -1;
}

.hero__bg picture { position: absolute; inset: 0; display: block; }

.hero__photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Desktop/mobile copy variants. */
.m-only { display: none !important; }

.hero__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(114.63deg, rgba(0, 0, 0, 0.2) 49.283%, rgba(102, 102, 102, 0.2) 61.706%);
}

/*
 * The stage is the 1440 × 960 design frame. On tablets and up, coming-soon.js
 * zooms it to fit the window (so the page never scrolls) and stretches it to
 * the window width, up to 1920px.
 */
.stage {
  position: relative;
  width: 1440px;
  min-height: 960px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
}

/* ---------- Decorative glows & track contours ---------- */

.deco { position: absolute; top: 0; bottom: 0; right: 0; width: 1440px; pointer-events: none; }
.deco img { position: absolute; display: block; max-width: none; }
.deco__emerald { left: 780px; top: 80px; width: 720px; height: 720px; }
.deco__blue    { left: 930px; top: 260px; width: 560px; height: 560px; }
.deco__track   { left: 690px; top: 115px; width: 860px; height: 660px; }
.deco__track2  { left: 740px; top: 170px; width: 760px; height: 570px; }

/* ---------- Nav ---------- */

.nav {
  position: relative;
  height: 97px;
  padding: 0 77px 0 80px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.nav::after {
  content: "";
  position: absolute;
  left: -100vw; /* full-bleed; .hero clips the overflow */
  right: -100vw;
  top: 96px;
  height: 1px;
  background: #9bc0ac;
  opacity: 0.22;
}

.nav__logo { display: block; margin-top: 25.4px; line-height: 0; }
.nav__logo img { width: 200.557px; height: 54.5177px; display: block; }

.nav__status {
  margin-top: 44px;
  font-size: 13px;
  font-weight: 500;
  line-height: 13px;
  letter-spacing: 1.8px;
  color: var(--muted);
}

/* ---------- Main ---------- */

.main {
  position: relative;
  flex: 1;
  padding: 0 120px;
  display: flex;
  flex-direction: column;
  justify-content: center; /* spare height is shared above and below the content */
}

.main__inner { position: relative; }

/* 50 + 33 spare = the design's 83px above the eyebrow; 30 + 33 = 63px above the footer. */
.intro { padding-top: 50px; padding-bottom: 30px; max-width: 640px; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  height: 36px;
  width: 508px;
  max-width: 100%;
  padding: 0 18px;
  border: 1px solid rgba(0, 216, 100, 0.7);
  border-radius: 18px;
  background: var(--eyebrow-bg);
  color: var(--green);
  font-size: 14px;
  font-weight: 700;
  line-height: 13px;
  letter-spacing: 1.1px;
  white-space: nowrap;
}

.headline {
  margin-top: 39px;
  max-width: 590px;
  font-size: 64px;
  font-weight: 800;
  line-height: 73px;
  letter-spacing: -2.1px;
  color: var(--ink);
}
.headline span { display: block; }

.lede {
  margin-top: 19px;
  font-size: 20px;
  font-weight: 400;
  line-height: 27px;
  color: var(--ink-soft);
}

.checks {
  list-style: none;
  padding: 0;
  margin-top: 39px;
  width: max-content;
  max-width: calc(100vw - 40px);
  display: flex;
  flex-wrap: wrap;
  gap: 8px 26px;
}

.checks li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 700;
  line-height: 13px;
  letter-spacing: 0.55px;
  color: var(--ink);
  white-space: nowrap;
}

.checks li::before {
  content: "✓";
  width: 18px;
  color: var(--green);
  font-size: 19px;
  line-height: 20px;
}

/* ---------- Contact form ---------- */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.contact__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.contact { margin-top: 57px; }

.contact__label {
  font-size: 13px;
  font-weight: 700;
  line-height: 13px;
  letter-spacing: 1.8px;
  color: var(--muted);
}

/* Same 320 / 260 column split as the original email field + button row. */
.contact__grid {
  margin-top: 14px;
  display: grid;
  grid-template-columns: 320px 260px;
  gap: 12px 14px;
}

.field { position: relative; }

.field__input {
  display: block;
  width: 100%;
  height: 62px;
  padding: 0 22px;
  border: 1px solid rgba(214, 231, 221, 0.68);
  border-radius: 13px;
  background: var(--field-bg);
  color: var(--ink);
  font: 400 18px/18px var(--font);
  outline: none;
  transition: border-color 0.15s;
  appearance: none;
  -webkit-appearance: none;
}
.field__input::placeholder { color: var(--placeholder); opacity: 1; }
.field__input:focus { border-color: var(--green); }
.field__input[aria-invalid="true"] { border-color: #ff6b6b; }



.contact__button {
  width: 100%;
  height: 62px;
  border: 0;
  border-radius: 13px;
  background: var(--blue);
  box-shadow: 0 8px 20px rgba(20, 77, 191, 0.42);
  color: var(--ink);
  font: 700 18px/15px var(--font);
  letter-spacing: 0.35px;
  cursor: pointer;
  transition: background-color 0.15s, transform 0.15s, opacity 0.15s;
}
.contact__button:hover { background: var(--blue-hover); }
.contact__button:active { transform: translateY(1px); }
.contact__button:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }
.contact__button[disabled] { opacity: 0.7; cursor: progress; }

.contact__msg {
  margin-top: 10px;
  font-size: 14px;
  line-height: 18px;
  color: var(--green);
}
.contact__msg:empty { display: none; }
.contact__msg.is-error { color: #ff8a8a; }

/* ---------- Countdown board ---------- */

.board {
  position: absolute;
  right: -40px; /* 80px from the frame edge, as in the design */
  top: 295px;   /* 245 below the eyebrow + 50 intro padding */
  width: 586px;
  height: 376px;
  padding: 33px 31px 0;
  border: 1px solid rgba(197, 224, 209, 0.3);
  border-radius: 22px;
  background: var(--board-bg);
}

.board__accent {
  display: block;
  width: 78px;
  height: 3px;
  border-radius: 2px;
  background: var(--green);
}

.board__head {
  margin-top: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-right: 1px;
  font-size: 12px;
  font-weight: 700;
  line-height: 12px;
}

.board__title { letter-spacing: 1.65px; color: var(--muted); }

.board__live {
  display: flex;
  align-items: center;
  gap: 21px;
  letter-spacing: 1.55px;
  color: var(--green);
}
.board__live img { width: 8px; height: 8px; display: block; }
.board__live-sep { margin: 0 -11px; color: rgba(184, 201, 193, 0.5); }
.board__live-date { color: var(--ink); }

.board__divider {
  margin-top: 22px;
  height: 1px;
  background: #406052;
  opacity: 0.45;
}

.tiles {
  margin-top: 29px;
  display: grid;
  grid-template-columns: repeat(4, 120px);
  gap: 13px;
}

.tile {
  height: 124px;
  border: 1px solid rgba(123, 170, 150, 0.38);
  border-radius: 14px;
  background: var(--tile-bg);
  box-shadow: 0 6px 10px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 18px;
}

.tile__num {
  font-size: 56px;
  font-weight: 800;
  line-height: 64px;
  letter-spacing: -1.2px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.tile__label {
  margin-top: 7px;
  font-size: 11px;
  font-weight: 700;
  line-height: 11px;
  letter-spacing: 1.25px;
  color: var(--muted);
}

.board__headline {
  margin-top: 36px;
  font-size: 18px;
  font-weight: 700;
  line-height: 19px;
  color: var(--ink);
}

.board__sub {
  margin-top: 9px;
  font-size: 15px;
  line-height: 15px;
  color: var(--muted);
}

/* ---------- Footer ---------- */

.footer {
  position: relative;
  margin: 0 120px;
  height: 72px;
  padding-top: 23px;
  border-top: 1px solid rgba(167, 198, 182, 0.25);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 12px;
  font-weight: 500;
  line-height: 12px;
  letter-spacing: 1.4px;
  color: var(--muted);
}

/* ---------- Success popup (styled as a countdown board) ---------- */

.modal {
  width: min(520px, calc(100vw - 32px));
  max-width: none;
  max-height: none;
  padding: 0;
  margin: auto;
  border: 0;
  background: transparent;
  color: var(--ink);
  overflow: visible;
}

/* Non-modal fallback when opened without JS (no-JS form submit). */
.modal[open]:not(:modal) {
  position: fixed;
  inset: 0;
  z-index: 10;
  box-shadow: 0 0 0 100vmax rgba(2, 8, 6, 0.72);
}

.modal::backdrop {
  background: rgba(2, 8, 6, 0.72);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.modal__card {
  padding: 33px 31px 32px;
  border: 1px solid rgba(197, 224, 209, 0.3);
  border-radius: 22px;
  background: var(--board-bg);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
}

.modal[open] .modal__card { animation: modal-in 0.28s cubic-bezier(0.2, 0.8, 0.2, 1); }

@keyframes modal-in {
  from { opacity: 0; transform: translateY(12px) scale(0.98); }
  to { opacity: 1; transform: none; }
}

.modal__icon {
  margin: 30px auto 0;
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(0, 216, 100, 0.7);
  border-radius: 50%;
  background: var(--eyebrow-bg);
  color: var(--green);
  font-size: 34px;
  font-weight: 700;
  box-shadow: 0 0 0 8px rgba(0, 216, 100, 0.08);
}

.modal__title {
  margin: 24px 0 0;
  text-align: center;
  font-size: 30px;
  font-weight: 800;
  line-height: 36px;
  letter-spacing: -0.8px;
}

.modal__text {
  margin-top: 12px;
  text-align: center;
  font-size: 16px;
  line-height: 24px;
  color: var(--muted);
}

/* Close button sits at the end of the header row, vertically centred on it. */
.modal__card .board__live { margin-left: auto; }
.modal__close-form { margin: -12px 0 -12px 16px; line-height: 0; }

.modal__close {
  position: relative;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid rgba(123, 170, 150, 0.38);
  border-radius: 50%;
  background: var(--tile-bg);
  color: var(--muted);
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
}
/* The cross is drawn with two bars so it is exactly centred (a text "×" sits off-centre). */
.modal__close::before,
.modal__close::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 14px;
  height: 2px;
  margin: -1px 0 0 -7px;
  border-radius: 1px;
  background: currentColor;
  transform: rotate(45deg);
}
.modal__close::after { transform: rotate(-45deg); }
.modal__close:hover { color: var(--ink); border-color: var(--green); }
.modal__close:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }

@media (prefers-reduced-motion: reduce) {
  .modal[open] .modal__card { animation: none; }
}

/* ---------- Responsive ---------- */

/* ---------- Portrait tablets: stacked layout, zoomed to fit by coming-soon.js ---------- */

@media (min-width: 721px) and (orientation: portrait) {
  .stage { width: auto; min-height: 100vh; }
  .nav { padding: 0 60px; }
  .main { padding: 0 60px; }
  .intro { padding: 40px 0 0; }
  .board {
    position: relative;
    right: auto;
    top: auto;
    width: 100%;
    max-width: 700px;
    height: auto;
    margin: 40px 0 30px;
    padding-bottom: 32px;
  }
  .tiles { grid-template-columns: repeat(4, 1fr); }
  .footer { margin: 0 60px; }
  .deco { right: -120px; width: 900px; }
  .deco img { transform: translateX(-690px); }
}

/* ---------- Mobile (Figma: MiJock Pre-Launch / Mobile v2 / Race Clock, 390 × 772) ---------- */

@media (max-width: 720px) {
  .d-only { display: none !important; }
  .m-only { display: revert !important; }

  body, .hero { background: #05110d; }
  .stage { width: auto; min-height: 0; }
  .deco { display: none; }

  /* Hero: art-directed crop from 85px to 454px, a fade under the nav, and a dark gradient over the top 495px. */
  .hero__bg { bottom: auto; height: 495px; overflow: hidden; }
  .hero__bg picture { top: 85px; bottom: auto; height: 369px; overflow: hidden; }
  .hero__photo { position: absolute; left: -13.08%; top: -33.33%; width: 126.15%; height: 133.33%; max-width: none; }
  .hero__fade { position: absolute; left: 0; right: 0; top: 65px; height: 110px; background: linear-gradient(to bottom, #05110d, rgba(5, 17, 13, 0)); }
  .hero__bg::after {
    background: linear-gradient(to bottom, rgba(3, 10, 8, 0.12) 0%, rgba(3, 10, 8, 0.28) 52%, #05110d 100%);
  }

  .nav { height: 83px; padding: 0 24px; align-items: flex-start; }
  .nav::after { top: 82px; background: #a7c6b6; opacity: 0.25; }
  .nav__logo { margin-top: 23.23px; }
  .nav__logo img { width: 157px; height: 45.4116px; }
  .nav__status { display: none; }

  .main { display: block; padding: 0 24px; }
  /* Flatten the intro so the race clock can sit between the copy and the form. */
  .main__inner { display: flex; flex-direction: column; }
  .intro { display: contents; }
  .eyebrow { order: 1; }
  .headline { order: 2; }
  .lede { order: 3; }
  .checks { display: none; }
  .board { order: 4; }
  .contact { order: 5; }

  .eyebrow {
    display: block;
    width: auto;
    height: auto;
    margin-top: 28px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: none;
    color: #00d863;
    font-size: 10px;
    line-height: 12px;
    letter-spacing: 1.1px;
    white-space: nowrap;
  }

  .headline { margin-top: 12px; max-width: 350px; color: #f6faf7; font-size: 42px; line-height: 43px; letter-spacing: -1.35px; }

  .lede { margin-top: 13px; max-width: 330px; color: #b0c7bd; font-size: 15px; line-height: 20px; }

  /* Race clock board */
  .board {
    position: relative;
    top: auto;
    right: auto;
    z-index: 1;
    width: 100%;
    height: 182px;
    margin: 28px 0 -17px; /* overlaps the top of the waitlist band */
    padding: 16px 20px 0 17px;
    border-color: rgba(107, 158, 138, 0.38);
    border-radius: 18px;
    background: #081f18;
  }
  .board__accent { width: 32px; background: var(--blue); }
  .board__head { margin-top: 10px; height: 16px; padding-right: 0; }
  .board__title { font-size: 9px; line-height: 11px; letter-spacing: 1.3px; color: #b0c7bd; }
  .board__live--m { display: flex !important; gap: 4px; font-size: 10px; line-height: 12px; letter-spacing: 1.55px; }
  .board__divider, .board__headline, .board__sub { display: none; }

  .clock { display: flex !important; align-items: flex-start; margin-top: 8px; color: #f6faf7; }
  .clock__unit { display: flex; flex-direction: column; }
  .clock__unit--days { width: 68px; }
  .clock__num {
    font-size: 38px;
    font-weight: 800;
    line-height: 38px;
    letter-spacing: -1.1px;
    font-variant-numeric: tabular-nums;
  }
  .clock__unit--days .clock__num { margin-top: 1px; font-size: 36px; line-height: 37px; letter-spacing: -1.2px; }
  .clock__label { margin-top: 4px; padding-left: 3px; font-size: 8px; font-weight: 700; line-height: 10px; letter-spacing: 0.9px; color: #b0c7bd; }
  .clock__unit--days .clock__label { margin-top: 3px; padding-left: 1px; }
  .clock__divider { width: 1px; height: 45px; margin: 2px 17px 0 0; background: rgba(107, 158, 138, 0.5); }
  .clock__colon { font-size: 38px; font-weight: 800; line-height: 36px; margin: 0 8px; }
  .clock__headline { margin-top: 20px; color: #f6faf7; font-size: 12px; font-weight: 700; line-height: 15px; }
  .clock__sub { margin-top: 6px; color: #b0c7bd; font-size: 11px; line-height: 14px; }

  /* Waitlist band */
  .contact {
    margin: 0 -24px;
    padding: 37px 24px 44px;
    background: #061712;
  }
  .contact__label { font-size: 10px; line-height: 14px; letter-spacing: 1.15px; color: #b0c7bd; }
  .contact__grid { margin-top: 8px; grid-template-columns: 1fr; gap: 12px; }
  .field__input {
    height: 52px;
    padding: 0 17px;
    border-color: rgba(107, 158, 138, 0.72);
    border-radius: 12px;
    background: #05110d;
    font-size: 15px;
    line-height: 18px;
  }
  .field__input::placeholder { color: #789187; }
  .contact__button {
    height: 54px;
    border-radius: 12px;
    box-shadow: none;
    font-size: 14px;
    line-height: 18px;
    letter-spacing: 0.25px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
  }
  .contact__arrow { font-size: 13px; }

  /* Footer: full-bleed divider, right-aligned year line. */
  .footer {
    z-index: 1;
    margin: -8px 0 0;
    height: auto;
    padding: 18px 24px;
    border-top-color: rgba(167, 198, 182, 0.25);
    justify-content: flex-end;
    font-size: 8px;
    line-height: 12px;
    letter-spacing: 1.4px;
  }

  .modal__card { padding: 24px 20px; }
  .modal__title { font-size: 24px; line-height: 30px; }
}
