/*
 * Gymnav website. The look follows DESIGN.md ("Iron Arena"): a near-black arena, one accent
 * (Volt), Barlow Condensed for titles and labels, Barlow for text, and "the plate" (a panel with
 * two cut corners). No external requests: fonts, images and this file are all served from here.
 */

/* ---------------------------------------------------------------- Fonts (SIL OFL 1.1, see fonts/OFL.txt) */

@font-face {
  font-family: "Barlow Condensed";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/barlow-condensed-600.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow Condensed";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/barlow-condensed-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: 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");
}

/* Local fallbacks sized to Barlow's metrics, so the page does not jump when the fonts arrive. */
@font-face {
  font-family: "Barlow Fallback";
  src: local("Arial"), local("Helvetica Neue"), local("Helvetica"), local("Roboto");
  size-adjust: 93.8%;
  ascent-override: 106.6%;
  descent-override: 21.3%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "Barlow Condensed Fallback";
  src: local("Arial Bold"), local("Arial"), local("Helvetica Neue"), local("Roboto");
  font-weight: 600 700;
  size-adjust: 74.9%;
  ascent-override: 133.5%;
  descent-override: 26.7%;
  line-gap-override: 0%;
}

/* ---------------------------------------------------------------- Tokens (DESIGN.md, Volt) */

:root {
  color-scheme: dark;

  --bg: #0b0b0c;
  --surface: #151517;
  --surface-high: #1f1f22;
  --line: #2b2b2f;
  --line-strong: #47474d;
  --text: #f2f0e9;
  --text-muted: #a3a199;
  --text-faint: #6b6a64; /* decorative only, never text */
  --accent: #d8ff3e;
  --accent-dim: #8faa2a;
  --accent-high: #ecff9a;
  --accent-low: #bfe52f;
  --accent-glow: rgba(216, 255, 62, 0.35);
  --accent-wash: rgba(216, 255, 62, 0.1);
  --on-accent: #0b0b0c;

  --font-display: "Barlow Condensed", "Barlow Condensed Fallback", "Arial Narrow", sans-serif;
  --font-body: "Barlow", "Barlow Fallback", system-ui, sans-serif;

  --cut: 12px;
  --gutter: 20px;
  --max: 1180px;
  --header-h: 64px;

  --ease-out: cubic-bezier(0.2, 0.8, 0.2, 1);
}

/* ---------------------------------------------------------------- Base */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}
a:hover {
  color: var(--accent-high);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

p,
ul,
ol {
  margin: 0 0 1em;
}

strong {
  font-weight: 600;
  color: var(--text);
}

.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: 12px;
  top: -100px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--accent);
  color: var(--on-accent);
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  text-decoration: none;
}
.skip-link:focus {
  top: 12px;
}

.container {
  width: 100%;
  max-width: calc(var(--max) + 2 * var(--gutter));
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ---------------------------------------------------------------- Type */

h1,
h2,
h3,
.display {
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  line-height: 1;
  letter-spacing: 0.005em;
  margin: 0;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.625rem, 1.5rem + 4.6vw, 4.875rem);
  line-height: 0.98;
  padding-top: 0.08em; /* room for Å, Ä and Ö above the first line */
}

h2 {
  font-size: clamp(2.125rem, 1.4rem + 3.2vw, 3.5rem);
  line-height: 1;
  padding-top: 0.08em;
}

h3 {
  font-size: clamp(1.5rem, 1.2rem + 1vw, 1.875rem);
  line-height: 1.05;
}

.lead {
  font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.25rem);
  line-height: 1.55;
  color: var(--text-muted);
  max-width: 38em;
}
.lead strong {
  color: var(--text);
}

.muted {
  color: var(--text-muted);
}

.accent-text {
  color: var(--accent);
}

/* A HUD caption: a short accent bar, an uppercase label and a thin line that runs on. */
.hud {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.15;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0 0 18px;
}
.hud::before {
  content: "";
  flex: none;
  width: 3px;
  height: 14px;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent-glow);
}
.hud::after {
  content: "";
  flex: 1 1 auto;
  min-width: 24px;
  height: 1px;
  background: linear-gradient(90deg, var(--line-strong), transparent);
}
.hud--short::after {
  max-width: 80px;
}
.hud__num {
  color: var(--accent);
}

/* ---------------------------------------------------------------- The plate (cut-corner panel) */

.plate {
  --plate-bg: var(--surface);
  --plate-edge: var(--line);
  position: relative;
  isolation: isolate;
  padding: 24px;
  clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, var(--cut) 100%, 0 calc(100% - var(--cut)));
  background: var(--plate-edge);
}
.plate::before {
  content: "";
  position: absolute;
  inset: 1px;
  z-index: -1;
  clip-path: polygon(0 0, calc(100% - var(--cut) + 0.4px) 0, 100% calc(var(--cut) - 0.4px), 100% 100%, calc(var(--cut) - 0.4px) 100%, 0 calc(100% - var(--cut) + 0.4px));
  background:
    linear-gradient(180deg, rgba(242, 240, 233, 0.045), transparent 38%),
    var(--plate-bg);
}
.plate--active {
  --plate-edge: var(--accent);
}
.plate--raised {
  --plate-bg: var(--surface-high);
}
.plate--dashed {
  background: none;
  clip-path: none;
  border: 1px dashed var(--line-strong);
}
.plate--dashed::before {
  clip-path: none;
  inset: 0;
}

/* ---------------------------------------------------------------- Buttons */

.btn {
  --cut: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 26px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.125rem;
  line-height: 1.1;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-decoration: none;
  border: 0;
  cursor: pointer;
  transition: transform 0.15s var(--ease-out), filter 0.2s var(--ease-out), background-color 0.2s;
}
.btn:active {
  transform: scale(0.97);
}
.btn svg {
  width: 18px;
  height: 18px;
  flex: none;
}

.btn--primary {
  color: var(--on-accent);
  background: linear-gradient(180deg, var(--accent-high) 0%, var(--accent) 45%, var(--accent-low) 100%);
  clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, var(--cut) 100%, 0 calc(100% - var(--cut)));
}
.btn--primary:hover {
  color: var(--on-accent);
  filter: brightness(1.06);
}
/* The glow sits on a wrapper: a clip-path would cut a shadow off. */
.glow {
  display: inline-block;
  filter: drop-shadow(0 0 14px var(--accent-glow));
}

.btn--secondary {
  color: var(--text);
  background: transparent;
  box-shadow: inset 0 0 0 1px var(--line-strong);
  border-radius: 2px;
}
.btn--secondary:hover {
  color: var(--text);
  box-shadow: inset 0 0 0 1px var(--text-muted);
  background: rgba(242, 240, 233, 0.04);
}

/* ---------------------------------------------------------------- Tags */

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 9px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.8125rem;
  line-height: 1.2;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--text-muted);
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  white-space: nowrap;
}
/* Coming, not built: the app's "unconfirmed" look (dashed outline, with its word). */
.tag--coming {
  border-style: dashed;
  border-color: var(--text-muted);
}
.tag--live {
  color: var(--accent);
  border-color: rgba(216, 255, 62, 0.5);
}
.tag--live::before {
  content: "";
  width: 6px;
  height: 6px;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent);
}

/* ---------------------------------------------------------------- Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: rgba(11, 11, 12, 0.82);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  backdrop-filter: blur(14px) saturate(1.2);
  border-bottom: 1px solid rgba(43, 43, 47, 0.7);
}
.site-header .container {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 16px;
}
/* The mark (assets/img/mark.svg, the app icon's route G) beside the name (assets/img/wordmark.svg).
   Swapping either file changes it on every page. */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  flex: none;
  padding: 8px 0;
  text-decoration: none;
}
.brand .brand__mark {
  width: auto;
  height: 28px;
  filter: drop-shadow(0 0 8px rgba(216, 255, 62, 0.35));
}
.brand .brand__name {
  width: auto;
  height: 21px;
}
.site-nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
}
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 12px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9375rem;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--text-muted);
  text-decoration: none;
}
.site-nav a:hover {
  color: var(--text);
}
.site-nav a[aria-current="page"] {
  color: var(--text);
  box-shadow: inset 0 -2px 0 var(--accent);
}

.lang-switch {
  display: inline-flex;
  margin-left: 6px;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
}
.lang-switch a,
.lang-switch span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 40px;
  padding: 0 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.875rem;
  letter-spacing: 1.2px;
  text-decoration: none;
}
.lang-switch span {
  background: var(--accent);
  color: var(--on-accent);
}
.lang-switch a {
  color: var(--text-muted);
}
.lang-switch a:hover {
  color: var(--text);
  background: rgba(242, 240, 233, 0.05);
}

@media (max-width: 520px) {
  .site-nav .nav-optional {
    display: none;
  }
  .site-nav a {
    padding: 0 8px;
  }
}
@media (max-width: 400px) {
  .site-header .container {
    gap: 8px;
  }
  .brand {
    gap: 8px;
  }
  .brand .brand__mark {
    height: 23px;
  }
  .brand .brand__name {
    height: 17px;
  }
  .site-nav {
    gap: 2px;
  }
  .site-nav a {
    padding: 0 6px;
    font-size: 0.875rem;
  }
  .lang-switch {
    margin-left: 2px;
  }
  .lang-switch a,
  .lang-switch span {
    min-width: 40px;
    padding: 0 8px;
  }
}

/* The state of the app, always in view at the top: honest about where it is. */
.status-strip {
  border-bottom: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(216, 255, 62, 0.07), transparent 60%);
}
.status-strip .container {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 38px;
  padding-top: 6px;
  padding-bottom: 6px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.8125rem;
  line-height: 1.3;
  letter-spacing: 1.3px;
  text-transform: uppercase;
  color: var(--text-muted);
}
.status-strip .dot {
  flex: none;
  width: 7px;
  height: 7px;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent);
}

/* ---------------------------------------------------------------- Sections */

.section {
  position: relative;
  padding: clamp(64px, 6vw + 32px, 128px) 0;
  overflow: hidden;
  overflow: clip;
}
.section--tight {
  padding: clamp(48px, 4vw + 24px, 88px) 0;
}
.section + .section {
  border-top: 1px solid rgba(43, 43, 47, 0.6);
}
.section__head {
  max-width: 760px;
  margin-bottom: clamp(32px, 3vw + 16px, 56px);
}
h2 + .lead,
h2 + p {
  margin-top: 18px;
}

/* ---------------------------------------------------------------- The stage: the arena floor */

.stage {
  position: relative;
  isolation: isolate;
}
.stage__floor {
  position: absolute;
  z-index: -2;
  left: 50%;
  bottom: -2%;
  width: 260%;
  height: 46%;
  transform: translateX(-50%) perspective(520px) rotateX(64deg);
  transform-origin: 50% 100%;
  background-image:
    linear-gradient(to right, rgba(242, 240, 233, 0.085) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(242, 240, 233, 0.085) 1px, transparent 1px);
  background-size: 54px 54px;
  background-position: center bottom;
  -webkit-mask-image: radial-gradient(ellipse 46% 78% at 50% 100%, #000 18%, transparent 72%);
  mask-image: radial-gradient(ellipse 46% 78% at 50% 100%, #000 18%, transparent 72%);
  pointer-events: none;
}
.stage__light {
  position: absolute;
  z-index: -1;
  left: 50%;
  bottom: -4%;
  width: 150%;
  height: 34%;
  transform: translateX(-50%);
  background: radial-gradient(ellipse 50% 50% at 50% 60%, rgba(242, 240, 233, 0.13), rgba(242, 240, 233, 0.03) 55%, transparent 72%);
  pointer-events: none;
}
.stage__ring {
  position: absolute;
  z-index: -1;
  left: 50%;
  bottom: 1.5%;
  width: min(118%, calc(var(--phone-w, 290px) * 1.7));
  aspect-ratio: 5 / 1;
  transform: translateX(-50%);
  border-radius: 50%;
  border: 1.5px solid rgba(216, 255, 62, 0.42);
  box-shadow: 0 0 22px rgba(216, 255, 62, 0.16), inset 0 0 22px rgba(216, 255, 62, 0.1);
  pointer-events: none;
}
.stage__beam {
  position: absolute;
  z-index: -3;
  left: 50%;
  top: -12%;
  width: 90%;
  height: 120%;
  transform: translateX(-50%);
  background: radial-gradient(ellipse 50% 60% at 50% 0%, rgba(242, 240, 233, 0.07), transparent 70%);
  pointer-events: none;
}

/* ---------------------------------------------------------------- Phone (drawn in CSS) */

.phone {
  --w: var(--phone-w, clamp(232px, 22vw + 90px, 320px));
  position: relative;
  width: var(--w);
  margin: 0 auto;
}
.phone__body {
  position: relative;
  padding: calc(var(--w) * 0.032);
  border-radius: calc(var(--w) * 0.15);
  background: linear-gradient(145deg, #2a2a2e 0%, #121214 22%, #0a0a0b 60%, #1c1c1f 100%);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.07),
    0 0 0 1px #000,
    0 30px 60px -20px rgba(0, 0, 0, 0.85),
    0 60px 120px -40px rgba(0, 0, 0, 0.9);
}
/* Side keys */
.phone__body::before,
.phone__body::after {
  content: "";
  position: absolute;
  width: 3px;
  border-radius: 2px;
  background: linear-gradient(90deg, #1b1b1e, #3a3a40);
}
.phone__body::before {
  right: -3px;
  top: 24%;
  height: 11%;
}
.phone__body::after {
  left: -3px;
  top: 19%;
  height: 16%;
  box-shadow: 0 calc(var(--w) * 0.24) 0 0 #26262a;
}
.phone__screen {
  position: relative;
  overflow: hidden;
  border-radius: calc(var(--w) * 0.12);
  background: var(--bg);
  padding-top: calc(var(--w) * 0.085); /* the status bar strip, with the camera */
}
.phone__screen::before {
  content: "";
  position: absolute;
  top: calc(var(--w) * 0.03);
  left: 50%;
  width: calc(var(--w) * 0.034);
  height: calc(var(--w) * 0.034);
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #2b3140, #050506 60%);
  box-shadow: 0 0 0 1px #000;
}
.phone__screen img,
.phone__screen video {
  display: block;
  width: 100%;
  height: auto;
  background: var(--bg);
}
/* A faint sheen over the glass */
.phone__screen::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, rgba(255, 255, 255, 0.05) 0%, transparent 28%, transparent 70%, rgba(255, 255, 255, 0.025) 100%);
  pointer-events: none;
}
.phone figcaption,
.shot-caption {
  margin-top: 18px;
  text-align: center;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.8125rem;
  letter-spacing: 1.3px;
  text-transform: uppercase;
  color: var(--text-muted);
}

.phone--small {
  --phone-w: clamp(200px, 14vw + 90px, 260px);
}

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

.hero {
  position: relative;
  padding: clamp(40px, 4vw + 20px, 88px) 0 clamp(56px, 5vw + 24px, 112px);
  overflow: hidden;
}
.hero::before {
  /* the arena's darkness, lit from above */
  content: "";
  position: absolute;
  inset: 0;
  z-index: -4;
  background:
    radial-gradient(ellipse 70% 55% at 72% 8%, rgba(216, 255, 62, 0.055), transparent 70%),
    radial-gradient(ellipse 60% 70% at 20% 0%, rgba(242, 240, 233, 0.04), transparent 70%);
}
.hero__grid {
  display: grid;
  gap: clamp(40px, 5vw, 72px);
  align-items: center;
}
.hero__copy > * + * {
  margin-top: 22px;
}
.hero__copy .hud {
  margin-bottom: 0;
}
.hero h1 .line {
  display: block;
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 18px;
  padding-top: 8px;
}
.hero__note {
  font-size: 0.9375rem;
  color: var(--text-muted);
  max-width: 34em;
}
.hero__visual {
  position: relative;
  padding: 8px 0 28px;
}

/* HUD callouts beside the phone (wide screens only) */
.callouts {
  display: none;
}

@media (min-width: 960px) {
  .hero__grid {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  }
}
@media (min-width: 1100px) {
  .hero__visual {
    --phone-w: 316px;
  }
}
@media (min-width: 1280px) {
  .hero__copy {
    max-width: 600px;
  }
  .callouts {
    display: block;
    position: absolute;
    inset: 0;
    pointer-events: none;
  }
  .callout {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.8125rem;
    letter-spacing: 1.3px;
    text-transform: uppercase;
    color: var(--text-muted);
    white-space: nowrap;
  }
  .callout b {
    color: var(--text);
    font-weight: 700;
  }
  .callout::before {
    content: "";
    width: 7px;
    height: 7px;
    flex: none;
    border: 1.5px solid var(--accent);
    transform: rotate(45deg);
    box-shadow: 0 0 8px var(--accent-glow);
  }
  .callout--left {
    flex-direction: row-reverse;
    text-align: right;
    right: calc(50% + var(--phone-w) / 2 - 8px);
  }
  .callout--right {
    left: calc(50% + var(--phone-w) / 2 - 8px);
  }
  .callout--a {
    top: 25%;
  }
  .callout--b {
    top: 79%;
  }
  .callout--c {
    top: 20%;
  }
  .callouts--plan .callout--a {
    top: 46%;
  }
  .callouts--plan .callout--b {
    top: 75%;
  }
  .callouts--plan .callout--c {
    top: 33%;
  }
  .callout .wire {
    width: 36px;
    height: 1px;
    background: var(--line-strong);
  }
}

/* ---------------------------------------------------------------- Pillars (three plates) */

.pillars {
  display: grid;
  gap: 16px;
}
@media (min-width: 820px) {
  .pillars {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
  }
}
.pillar {
  --cut: 14px;
  padding: 28px 26px 30px;
}
.pillar__num {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 3rem;
  line-height: 1;
  color: var(--accent);
  text-shadow: 0 0 18px var(--accent-glow);
  font-variant-numeric: tabular-nums;
  margin-bottom: 18px;
}
.pillar h3 {
  margin-bottom: 12px;
}
.pillar p {
  color: var(--text-muted);
  margin: 0;
}

/* ---------------------------------------------------------------- Feature rows (text beside a phone) */

.feature {
  display: grid;
  gap: 40px;
  align-items: center;
}
.feature + .feature {
  margin-top: clamp(72px, 7vw + 24px, 136px);
}
.feature__copy h2 {
  margin-bottom: 18px;
}
.feature__copy .lead {
  margin-bottom: 22px;
}
.feature__visual {
  position: relative;
  padding-bottom: 20px;
}
@media (min-width: 900px) {
  .feature {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: clamp(48px, 6vw, 96px);
  }
  .feature--flip .feature__visual {
    order: -1;
  }
}

.ticks {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}
.ticks li {
  position: relative;
  padding-left: 28px;
  color: var(--text-muted);
}
.ticks li strong {
  color: var(--text);
}
.ticks li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.55em;
  width: 12px;
  height: 7px;
  border-left: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(-45deg);
}

/* Two phones side by side */
.pair {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: clamp(14px, 3vw, 32px);
}
.pair .phone {
  margin: 0;
}
.pair .phone:first-child {
  transform: translateY(-28px);
}
.pair--spaced {
  margin-top: clamp(56px, 5vw + 24px, 96px);
}

/* Three phones in a row: the way to a machine, from above to arrival */
.trio-stage {
  padding-bottom: 12px;
}
.trio {
  display: grid;
  justify-items: center;
  gap: 40px;
}
.trio .phone {
  --phone-w: clamp(220px, 12vw + 120px, 290px);
  margin: 0;
}
@media (min-width: 760px) {
  .trio {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: end;
    gap: clamp(14px, 3vw, 44px);
  }
  .trio .phone {
    --phone-w: clamp(200px, 14vw + 80px, 290px);
  }
  .trio .phone:nth-child(2) {
    transform: translateY(-32px);
  }
}
@media (max-width: 600px) {
  .pair {
    flex-direction: column;
    align-items: center;
    gap: 36px;
  }
  .pair .phone:first-child {
    transform: none;
  }
}

/* ---------------------------------------------------------------- Figure stills (the lifter through a movement) */

.filmframe {
  --cut: 14px;
  margin: 0;
  padding: 0;
}
.filmframe img {
  width: 100%;
  height: auto;
  clip-path: polygon(0 0, calc(100% - var(--cut) + 1px) 0, 100% calc(var(--cut) - 1px), 100% 100%, 0 100%);
}
.filmframe figcaption {
  padding: 12px 16px 14px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.875rem;
  letter-spacing: 1.3px;
  text-transform: uppercase;
  color: var(--text-muted);
}
.filmframe .hud__num {
  font-weight: 700;
}
.figure-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}
.figure-row img,
.figure-row video {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  background: var(--bg);
}
@media (min-width: 720px) {
  .figure-row {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin-top: 20px;
  }
}

/* ---------------------------------------------------------------- Rows of small plates */

.grid-2,
.grid-3,
.grid-4 {
  display: grid;
  gap: 16px;
}
.grid-3.filmstrip {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
@media (max-width: 560px) {
  .grid-3.filmstrip .filmframe figcaption {
    padding: 8px 8px 10px;
    font-size: 0.75rem;
    letter-spacing: 0.8px;
  }
}
@media (min-width: 720px) {
  .grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
  }
  .grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 900px) {
  .grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
  }
}
@media (min-width: 1100px) {
  .grid-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.card h3 {
  font-size: 1.5rem;
  margin-bottom: 10px;
}
.card p {
  color: var(--text-muted);
  margin: 0;
}
.card p + p {
  margin-top: 10px;
}
.card .tag {
  margin-bottom: 14px;
}
.card__icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 18px;
  border: 1px solid rgba(216, 255, 62, 0.55);
  background: var(--accent-wash);
  color: var(--accent);
  box-shadow: 0 0 16px rgba(216, 255, 62, 0.12);
}
.card__icon svg {
  width: 22px;
  height: 22px;
}

/* The three ways a gym gets mapped */
.ways {
  counter-reset: way;
}
.way {
  --cut: 16px;
  padding: 30px 26px;
}
.way__head {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin-bottom: 14px;
}
.way__num {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 2.5rem;
  line-height: 1;
  color: var(--accent);
  text-shadow: 0 0 16px var(--accent-glow);
}
.way__who {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.8125rem;
  letter-spacing: 1.3px;
  text-transform: uppercase;
  color: var(--text-muted);
}
.way h3 {
  margin-bottom: 12px;
}
.way p,
.way li {
  color: var(--text-muted);
}
.way ul {
  margin: 14px 0 0;
}

/* ---------------------------------------------------------------- Steps (a numbered strip) */

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0;
  border-left: 1px solid var(--line-strong);
}
.steps li {
  position: relative;
  padding: 4px 0 26px 28px;
}
.steps li:last-child {
  padding-bottom: 0;
}
.steps li::before {
  content: "";
  position: absolute;
  left: -5px;
  top: 10px;
  width: 9px;
  height: 9px;
  background: var(--bg);
  border: 1.5px solid var(--accent);
  transform: rotate(45deg);
}
.steps h3 {
  font-size: 1.25rem;
  margin-bottom: 6px;
}
.steps p {
  color: var(--text-muted);
  margin: 0;
}

/* ---------------------------------------------------------------- Call to action band */

.cta {
  --cut: 20px;
  padding: clamp(28px, 4vw, 56px);
}
.cta--accent {
  --plate-edge: rgba(216, 255, 62, 0.6);
}
.cta--accent::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(ellipse 60% 90% at 100% 0%, rgba(216, 255, 62, 0.09), transparent 70%);
  pointer-events: none;
}
.cta__grid {
  display: grid;
  gap: 28px;
  align-items: center;
}
@media (min-width: 900px) {
  .cta__grid {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  }
}
.cta h2 {
  margin-bottom: 16px;
}
.cta__actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}
.contact-line {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.125rem;
  letter-spacing: 0.6px;
}

/* ---------------------------------------------------------------- Coming list */

.coming {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}
.coming li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 6px 16px;
  align-items: baseline;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.coming li:last-child {
  border-bottom: 0;
}
.coming .tag {
  grid-row: span 2;
  align-self: start;
}
.coming strong {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  line-height: 1.15;
}
.coming span.desc {
  color: var(--text-muted);
}
@media (max-width: 460px) {
  .coming li {
    grid-template-columns: 1fr;
  }
  .coming .tag {
    grid-row: auto;
    justify-self: start;
  }
}

/* ---------------------------------------------------------------- Long text (privacy policy) */

.prose {
  max-width: 760px;
}
.prose h2 {
  font-size: clamp(1.625rem, 1.3rem + 1.2vw, 2.25rem);
  margin: 56px 0 16px;
}
.prose h3 {
  font-size: 1.375rem;
  margin: 32px 0 10px;
}
.prose p,
.prose li {
  color: var(--text-muted);
}
.prose strong {
  color: var(--text);
}
.prose ul {
  padding-left: 1.25em;
}
.prose li + li {
  margin-top: 6px;
}
.prose li::marker {
  color: var(--accent-dim);
}
.prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1.5em;
  font-size: 0.9375rem;
}
.prose th,
.prose td {
  text-align: left;
  vertical-align: top;
  padding: 10px 12px 10px 0;
  border-bottom: 1px solid var(--line);
}
.prose th {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.8125rem;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--text-muted);
}
.prose td:first-child {
  color: var(--text);
  font-weight: 500;
  width: 34%;
}
@media (max-width: 640px) {
  .prose table,
  .prose tbody,
  .prose tr,
  .prose td {
    display: block;
    width: 100%;
  }
  .prose thead {
    display: none;
  }
  .prose tr {
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
  }
  .prose td,
  .prose td:first-child {
    width: auto;
    padding: 3px 0;
    border: 0;
  }
  .prose td + td::before {
    content: attr(data-label);
    display: block;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.75rem;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: var(--text-muted);
  }
}
.prose .toc {
  list-style: none;
  padding: 0;
  columns: 2 220px;
  column-gap: 32px;
}
.prose .toc li {
  break-inside: avoid;
  margin: 0 0 6px;
}
.prose .toc a {
  color: var(--text-muted);
  text-decoration: none;
}
.prose .toc a:hover {
  color: var(--text);
  text-decoration: underline;
}
.page-head {
  padding-top: clamp(40px, 4vw + 20px, 80px);
}
.prose > h2:first-child {
  margin-top: 0;
}
.page-head h1 {
  font-size: clamp(2.5rem, 1.6rem + 4vw, 4.5rem);
}
.notice-banner {
  --cut: 14px;
  margin: 28px 0 8px;
}
.notice-banner p {
  margin: 0;
  color: var(--text-muted);
}
.notice-banner p + p {
  margin-top: 8px;
}
.notice-banner .tag {
  margin-bottom: 12px;
}

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

.site-footer {
  border-top: 1px solid var(--line);
  padding: 56px 0 40px;
  background: linear-gradient(180deg, #0d0d0e, var(--bg));
  font-size: 0.9375rem;
  color: var(--text-muted);
}
.footer__grid {
  display: grid;
  gap: 32px;
}
@media (min-width: 820px) {
  .footer__grid {
    grid-template-columns: 1.3fr 1fr 1fr;
  }
}
.footer__brand .brand {
  margin-bottom: 14px;
}
.footer__brand .brand__mark {
  height: 24px;
}
.footer__brand .brand__name {
  height: 18px;
}
.footer__title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.8125rem;
  letter-spacing: 1.3px;
  text-transform: uppercase;
  color: var(--text);
  margin: 0 0 12px;
}
.footer__links {
  list-style: none;
  margin: 0;
  padding: 0;
}
.footer__links li + li {
  margin-top: 4px;
}
.footer__links a {
  display: inline-block;
  padding: 6px 0;
  color: var(--text-muted);
  text-decoration: none;
}
.footer__links a:hover {
  color: var(--text);
  text-decoration: underline;
}
.footer__company p {
  margin: 0 0 6px;
}
.footer__note {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 0.875rem;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  justify-content: space-between;
}
.footer__note p {
  margin: 0;
  max-width: 60em;
}

/* ---------------------------------------------------------------- 404 */

.notfound {
  position: relative;
  overflow: hidden;
  overflow: clip;
  min-height: 60vh;
  display: grid;
  align-content: center;
  gap: 20px;
  padding-top: 80px;
  padding-bottom: 80px;
}
.notfound .code {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(5rem, 16vw, 10rem);
  line-height: 0.9;
  color: var(--accent);
  text-shadow: 0 0 30px var(--accent-glow);
}

/* ---------------------------------------------------------------- Motion */

/* Elements build themselves in, as the app's screens do. Without JavaScript nothing is hidden. */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out);
}
.js [data-reveal].is-in {
  opacity: 1;
  transform: none;
}
.js [data-reveal]:nth-child(2) {
  transition-delay: 60ms;
}
.js [data-reveal]:nth-child(3) {
  transition-delay: 120ms;
}
.js [data-reveal]:nth-child(4) {
  transition-delay: 180ms;
}

.hero__copy > * {
  animation: rise 0.65s var(--ease-out) both;
}
.hero__copy > :nth-child(2) {
  animation-delay: 60ms;
}
.hero__copy > :nth-child(3) {
  animation-delay: 120ms;
}
.hero__copy > :nth-child(4) {
  animation-delay: 180ms;
}
.hero__copy > :nth-child(5) {
  animation-delay: 240ms;
}
.hero__visual .phone {
  animation: arrive 0.9s 0.15s var(--ease-out) both;
}
.hero__visual .stage__ring {
  animation: ring 4.5s 1s ease-in-out infinite;
}
.callout {
  animation: fade 0.6s 0.8s var(--ease-out) both;
}
.callout:nth-child(2) {
  animation-delay: 0.95s;
}
.callout:nth-child(3) {
  animation-delay: 1.1s;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@keyframes arrive {
  from {
    opacity: 0;
    transform: translateY(26px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@keyframes fade {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
@keyframes ring {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.55;
  }
}

/* Reduced motion: entrances become plain fades or nothing; nothing loops. */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    animation-delay: 0ms !important;
    transition-duration: 0.01ms !important;
    transition-delay: 0ms !important;
    scroll-behavior: auto !important;
  }
  .js [data-reveal] {
    opacity: 1;
    transform: none;
  }
}

/* ---------------------------------------------------------------- Clips: the promo's lines and the motion control */

/* A clip below the first screen gets its poster from site.js when it comes near, so the page does
   not fetch every poster at once. Without JavaScript the poster is a picture laid over the video. */
.clip-box {
  display: block;
  position: relative;
}
.clip-box .clip-fallback {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

/* The line for each beat of the promo, under the phone. While the promo plays, the beat on screen is
   lit; paused or with reduced motion, the lines are a plain list. */
.beats {
  list-style: none;
  margin: 26px auto 0;
  padding: 0;
  width: min(100%, 360px);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 14px;
  counter-reset: beat;
}
.beats li {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9375rem;
  line-height: 1.2;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
  transition: color 0.2s var(--ease-out);
}
.beats__n {
  flex: none;
  font-weight: 700;
  color: var(--accent-dim);
  font-variant-numeric: tabular-nums;
}
.beats.is-live li.is-on {
  color: var(--text);
}
.beats.is-live li.is-on .beats__n {
  color: var(--accent);
  text-shadow: 0 0 10px var(--accent-glow);
}

/* One small control that pauses and plays every clip on the page. */
.motion-toggle {
  --cut: 8px;
  position: fixed;
  right: 14px;
  bottom: 14px;
  z-index: 60;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 14px 0 12px;
  border: 0;
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.8125rem;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--text);
  background: rgba(31, 31, 34, 0.92);
  box-shadow: inset 0 0 0 1px var(--line-strong);
  clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, var(--cut) 100%, 0 calc(100% - var(--cut)));
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.motion-toggle:hover {
  box-shadow: inset 0 0 0 1px var(--text-muted);
}
.motion-toggle__icon {
  position: relative;
  width: 10px;
  height: 12px;
  flex: none;
}
/* Pause: two bars. Play: a triangle. */
.motion-toggle__icon::before,
.motion-toggle__icon::after {
  content: "";
  position: absolute;
  top: 0;
  width: 3px;
  height: 12px;
  background: var(--accent);
}
.motion-toggle__icon::before {
  left: 0;
}
.motion-toggle__icon::after {
  right: 0;
}
.motion-toggle.is-paused .motion-toggle__icon::before {
  width: 0;
  height: 0;
  background: none;
  border-style: solid;
  border-width: 6px 0 6px 10px;
  border-color: transparent transparent transparent var(--accent);
}
.motion-toggle.is-paused .motion-toggle__icon::after {
  display: none;
}

/* ---------------------------------------------------------------- Print (the gym page gets printed) */

@media print {
  :root {
    --bg: #fff;
    --surface: #fff;
    --surface-high: #fff;
    --text: #111;
    --text-muted: #333;
    --line: #ccc;
    --line-strong: #999;
  }
  body {
    background: #fff;
    color: #111;
  }
  .site-header,
  .status-strip,
  .skip-link,
  .stage__floor,
  .stage__light,
  .stage__ring,
  .stage__beam,
  .callouts,
  .motion-toggle,
  .hero::before {
    display: none !important;
  }
  .section {
    padding: 24px 0;
  }
  .plate {
    background: #999;
  }
  .phone {
    --w: 180px;
  }
  .accent-text,
  .pillar__num,
  .way__num {
    color: #111;
    text-shadow: none;
  }
  a {
    color: #111;
  }
  .js [data-reveal] {
    opacity: 1;
    transform: none;
  }
  .site-footer .wordmark-img {
    filter: invert(1);
  }
}
