/* PacePod website. Same palette as src/constants/theme.ts: dark first, light under prefers-color-scheme. */
:root {
  color-scheme: dark;
  --bg: #1e1e22;
  --surface: #26262b;
  --raised: #2f2f35;
  --border: #42424a;
  --fg: #ececf0;
  --muted: #a3a3ad;
  --accent: #fc5200;
  --accent-ink: #ff8a4c; /* orange text on the page background */
  --accent-soft: #46271c;
  --on-accent: #ffffff;

  /* The phone mockup always shows the app's dark theme. */
  --app-bg: #1e1e22;
  --app-surface: #26262b;
  --app-raised: #2f2f35;
  --app-border: #42424a;
  --app-fg: #ececf0;
  --app-muted: #a3a3ad;
  --app-soft: #46271c;
  --app-soft-ink: #ff8a4c;
  --app-danger: #ff4d4f;
  --app-danger-soft: #46262a;
  --app-danger-ink: #ff7a7c;
  --app-success: #2fd06b;

  --display: 'Archivo', 'Helvetica Neue', Arial, sans-serif;
  --body: 'Archivo', 'Helvetica Neue', Arial, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;

  --gutter-l: max(16px, env(safe-area-inset-left, 0px));
  --gutter-r: max(16px, env(safe-area-inset-right, 0px));
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme='dark']) {
    color-scheme: light;
    --bg: #f5f5f7;
    --surface: #ffffff;
    --raised: #e9e9ee;
    --border: #d2d2da;
    --fg: #1e1e22;
    --muted: #5f5f69;
    --accent-ink: #ae3700;
    --accent-soft: #f6ded4;
  }
}
:root[data-theme='light'] {
  color-scheme: light;
  --bg: #f5f5f7;
  --surface: #ffffff;
  --raised: #e9e9ee;
  --border: #d2d2da;
  --fg: #1e1e22;
  --muted: #5f5f69;
  --accent-ink: #ae3700;
  --accent-soft: #f6ded4;
}

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.6;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--accent-ink);
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

h1,
h2,
h3 {
  font-family: var(--display);
  text-wrap: balance;
  margin: 0;
}

.wrap {
  width: 100%;
  max-width: 1120px;
  margin-inline: auto;
  padding-left: var(--gutter-l);
  padding-right: var(--gutter-r);
}

/* Header */
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 20px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--fg);
  text-decoration: none;
  font-family: var(--display);
  font-weight: 800;
  font-stretch: 112%;
  font-size: 1.375rem;
}
.brand img {
  width: 28px;
  height: 38px;
}
.site-nav {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}
.site-nav a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9375rem;
}
.site-nav a:hover {
  color: var(--fg);
}

/* Hero */
.hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  align-items: center;
  gap: 48px;
  padding-block: 40px 88px;
}
.eyebrow {
  font-family: var(--mono);
  font-size: 0.8125rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-ink);
  margin: 0 0 18px;
}
.hero h1 {
  font-size: clamp(2.6rem, 6vw, 4.5rem);
  line-height: 1;
  font-weight: 850;
  font-stretch: 115%;
  letter-spacing: -0.02em;
}
.hero h1 em {
  font-style: normal;
  color: var(--accent);
}
.lede {
  font-size: 1.25rem;
  color: var(--muted);
  max-width: 34em;
  margin: 22px 0 32px;
}
.cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 20px;
}
.play-badge {
  display: inline-block;
  line-height: 0;
  /* The official badge has built-in padding; pull it back so it lines up with the text. */
  margin-left: -12px;
}
.play-badge img {
  width: 220px;
}
.cta-note {
  color: var(--muted);
  font-size: 0.9375rem;
}

/* Phone mockup: the app's running screen, drawn at 390 px and scaled to fit. */
.phone {
  justify-self: center;
  width: 336px;
  padding: 12px;
  border-radius: 52px;
  background: #0b0b0d;
  border: 2px solid #3a3a40;
  box-shadow: 0 40px 80px -30px rgb(252 82 0 / 0.35);
}
.phone-screen {
  width: 312px;
  height: 632px;
  border-radius: 40px;
  overflow: hidden;
  background: var(--app-bg);
}
.app {
  width: 390px;
  height: 790px;
  transform: scale(0.8);
  transform-origin: 0 0;
  padding: 16px;
  display: flex;
  flex-direction: column;
  color: var(--app-fg);
  font-family: var(--body);
  line-height: 1.2;
}
.app-top {
  display: flex;
  align-items: center;
  gap: 8px;
}
.app-icon-btn {
  width: 52px;
  height: 52px;
  flex: none;
  border-radius: 16px;
  background: var(--app-raised);
  display: grid;
  place-items: center;
}
.app-badge {
  flex: 1;
  display: flex;
  justify-content: center;
}
.app-badge span {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1.5px solid var(--app-success);
  color: var(--app-success);
  font-size: 14px;
  font-weight: 700;
}
.app-controls {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 24px;
}
.app-speed {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.app-speed-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
}
.app-speed-value {
  font-size: 104px;
  line-height: 112px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.app-speed-unit,
.app-pace {
  font-size: 26px;
  font-weight: 700;
  color: var(--app-muted);
}
.app-pace {
  font-size: 22px;
}
.app-stepper {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.app-stepper span {
  height: 112px;
  border-radius: 24px;
  background: var(--app-soft);
  color: var(--app-soft-ink);
  display: grid;
  place-items: center;
  font-size: 64px;
  font-weight: 600;
}
.app-presets {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}
.app-presets span {
  min-height: 64px;
  border-radius: 16px;
  background: var(--app-surface);
  border: 1.5px solid var(--app-border);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 700;
}
.app-presets small {
  font-size: 10px;
  font-weight: 400;
  color: var(--app-muted);
}
.app-presets .is-zero {
  color: var(--app-danger);
}
.app-presets .is-active {
  border-color: var(--accent);
}
.app-stats {
  display: flex;
  justify-content: center;
  gap: 24px;
  padding: 16px 0;
  color: var(--app-muted);
  font-size: 17px;
  font-variant-numeric: tabular-nums;
}
.app-stop {
  min-height: 72px;
  border-radius: 24px;
  background: var(--app-danger-soft);
  color: var(--app-danger-ink);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 700;
}

/* Sections */
.section {
  padding-block: 80px;
  border-top: 1px solid var(--border);
}
.section h2 {
  font-size: clamp(2rem, 4vw, 2.75rem);
  line-height: 1.05;
  font-weight: 800;
  font-stretch: 110%;
  letter-spacing: -0.01em;
  max-width: 20em;
}
.section-intro {
  color: var(--muted);
  max-width: 36em;
  margin: 14px 0 0;
}

.steps {
  list-style: none;
  padding: 0;
  margin: 44px 0 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px;
  counter-reset: step;
}
.steps li {
  counter-increment: step;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.steps li::before {
  content: counter(step);
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  display: grid;
  place-items: center;
  font-family: var(--display);
  font-weight: 800;
  font-size: 1.25rem;
}
.steps h3,
.features h3 {
  font-size: 1.25rem;
  font-weight: 700;
}
.steps p,
.features p {
  margin: 0;
  color: var(--muted);
}

.features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 40px 32px;
  margin-top: 44px;
}
.features > div {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--accent-soft);
  color: var(--accent-ink);
  display: grid;
  place-items: center;
  margin-bottom: 6px;
}

.needs {
  margin-top: 44px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.needs > div {
  padding: 22px 24px;
  border-radius: 20px;
  background: var(--surface);
  border: 1px solid var(--border);
}
.needs h3 {
  font-size: 1.0625rem;
  font-weight: 700;
  margin-bottom: 6px;
}
.needs p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9375rem;
}

/* Closing call to action */
.cta-band {
  background: var(--accent);
  color: #ffffff;
}
.cta-band .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-block: 56px;
}
.cta-band h2 {
  font-size: clamp(1.9rem, 4vw, 2.75rem);
  line-height: 1.05;
  font-weight: 850;
  font-stretch: 112%;
  max-width: 14em;
}
.cta-band .play-badge {
  margin-left: 0;
}

/* Footer */
.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 24px;
  padding-block: 32px;
  color: var(--muted);
  font-size: 0.875rem;
}
.site-footer nav {
  display: flex;
  gap: 20px;
}
.site-footer a {
  color: var(--muted);
}

/* Privacy policy */
.doc {
  max-width: 720px;
  padding-block: 32px 96px;
}
.doc h1 {
  font-size: clamp(2.25rem, 5vw, 3.25rem);
  line-height: 1.05;
  font-weight: 850;
  font-stretch: 112%;
}
.doc .updated {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.875rem;
  margin: 12px 0 32px;
}
.doc .summary {
  padding: 20px 24px;
  border-radius: 20px;
  background: var(--accent-soft);
  margin-bottom: 8px;
}
.doc .summary p {
  margin: 0;
}
.doc h2 {
  font-size: 1.5rem;
  font-weight: 750;
  margin: 44px 0 12px;
}
.doc h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 28px 0 8px;
}
.doc p,
.doc li {
  color: var(--fg);
}
.doc ul {
  padding-left: 1.25em;
}
.doc li + li {
  margin-top: 6px;
}
.doc code {
  font-family: var(--mono);
  font-size: 0.875em;
  background: var(--raised);
  padding: 1px 6px;
  border-radius: 6px;
}

@media (max-width: 880px) {
  .hero .wrap {
    grid-template-columns: minmax(0, 1fr);
    padding-block: 16px 64px;
  }
  .steps,
  .features,
  .needs {
    grid-template-columns: minmax(0, 1fr);
  }
  .features {
    gap: 32px;
  }
  .section {
    padding-block: 64px;
  }
}

@media (min-width: 560px) and (max-width: 880px) {
  .features,
  .needs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
