/*
 * Pedal Chronicle marketing site. Tokens match the app (frontend/src/index.css):
 * near-black surfaces, Archivo with its condensed cut for display type,
 * square corners, hairline borders, teal accent and brand red.
 */
:root {
  --bg: #0c0d0e;
  --surface: #151719;
  --panel: #111315;
  --line: #26292c;
  --line-soft: #1c1e20;
  --line-strong: #3a3e42;
  --fg: #f2f2f0;
  --fg-soft: #c9cbcc;
  --fg-2: #a3a6a8;
  --fg-3: #8a8e91;
  --fg-4: #6e7275;
  --accent: #64ccde;
  --brand-red: #c54040;
  --good: oklch(0.78 0.13 160);
  --warning: oklch(0.82 0.14 80);
  --critical: oklch(0.7 0.17 32);
  --gutter: 40px;
  --max: 1200px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 24px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: "Archivo", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: #9fe0eb;
}

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* Type */
.eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 10px;
}

.display {
  font-weight: 800;
  line-height: 0.88;
  text-transform: uppercase;
  font-variation-settings: "wdth" 62;
  margin: 0;
}

.section-title {
  font-size: 40px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  font-variation-settings: "wdth" 70;
  margin: 0 0 14px;
}

.lede {
  font-size: 18px;
  color: var(--fg-soft);
  max-width: 580px;
  margin: 0;
}

.muted {
  color: var(--fg-3);
}

/* Buttons: the app's square, uppercase buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 15px 24px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: background-color 0.15s, color 0.15s, border-color 0.15s;
}

.btn-primary {
  background: var(--fg);
  color: var(--bg);
}

.btn-primary:hover {
  background: #fff;
  color: var(--bg);
}

.btn-outline {
  border: 1px solid var(--line-strong);
  color: var(--fg);
}

.btn-outline:hover {
  background: var(--line-soft);
  color: var(--fg);
}

/* Header */
.site-header {
  position: absolute;
  inset: 0 0 auto;
  z-index: 2;
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-top: 26px;
  padding-bottom: 26px;
}

.site-header nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-2);
}

.nav-link:hover {
  color: var(--fg);
}

.logo {
  display: block;
  width: 150px;
  height: auto;
}

/* Hero: the app dashboard's photo band */
.hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line-soft);
}

.hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.32;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to right, var(--bg) 25%, rgba(12, 13, 14, 0.55)),
    linear-gradient(to bottom, transparent 55%, var(--bg));
}

.hero .wrap {
  position: relative;
  z-index: 1;
  padding-top: 170px;
  padding-bottom: 96px;
}

.hero h1 {
  font-size: 128px;
  max-width: 980px;
}

.hero h1 span {
  color: var(--fg-3);
}

.hero .lede {
  margin-top: 26px;
  font-size: 20px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 34px;
}

/* Strava's logo: separate from our brand and less prominent than it */
.powered-by {
  display: block;
  margin-top: 40px;
  height: 18px;
  width: auto;
  opacity: 0.9;
}

/* The Strava line */
.statement {
  border-bottom: 1px solid var(--line-soft);
}

.statement .wrap {
  padding-top: 64px;
  padding-bottom: 64px;
}

.statement p {
  margin: 0;
  max-width: 860px;
  font-size: 30px;
  line-height: 1.3;
  font-weight: 500;
  color: var(--fg-2);
}

.statement strong {
  color: var(--fg);
  font-weight: 800;
}

/* Feature sections */
.feature {
  border-bottom: 1px solid var(--line-soft);
}

.feature .wrap {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 64px;
  align-items: center;
  padding-top: 96px;
  padding-bottom: 96px;
}

.feature.flip .copy {
  order: 2;
}

/* Wide screenshots run full width under a two-column intro, so they stay legible */
.feature.wide .wrap {
  grid-template-columns: 1fr;
  gap: 44px;
}

.feature.wide .copy {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 64px;
  align-items: start;
}

.feature.wide .section-title {
  margin: 0;
}

.feature.wide .copy-body ul {
  margin-top: 20px;
}

.feature .num {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--fg-4);
  margin: 0 0 18px;
}

.feature ul {
  list-style: none;
  padding: 0;
  margin: 24px 0 0;
  display: grid;
  gap: 10px;
}

.feature li {
  display: grid;
  grid-template-columns: 14px minmax(0, 1fr);
  gap: 12px;
  color: var(--fg-soft);
  font-size: 15px;
}

.feature li::before {
  content: "";
  width: 14px;
  height: 3px;
  margin-top: 11px;
  background: var(--accent);
}

/* Screenshots of the real app */
.shot {
  margin: 0;
  border: 1px solid var(--line);
  background: var(--bg);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.45);
}

.shot.light {
  border-color: #2c2f32;
  background: #f3f4f5;
  padding: 18px;
}

.shot-stack {
  display: grid;
  gap: 18px;
}

.shot-pair {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

figcaption {
  font-size: 12px;
  color: var(--fg-4);
  padding: 10px 14px;
  border-top: 1px solid var(--line-soft);
}

/* Smaller features */
.extras .wrap {
  padding-top: 88px;
  padding-bottom: 88px;
}

.extras-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  margin-top: 36px;
  background: var(--line-soft);
  border: 1px solid var(--line-soft);
}

.extra {
  background: var(--bg);
  padding: 26px 24px 28px;
}

.extra h3 {
  margin: 0 0 8px;
  font-size: 20px;
  font-weight: 800;
  text-transform: uppercase;
  font-variation-settings: "wdth" 75;
}

.extra p {
  margin: 0;
  font-size: 14px;
  color: var(--fg-3);
}

/* FAQ */
.faq .wrap {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
  gap: 64px;
  padding-top: 88px;
  padding-bottom: 88px;
  border-top: 1px solid var(--line-soft);
}

details {
  border-bottom: 1px solid var(--line-soft);
}

details:first-child {
  border-top: 1px solid var(--line-soft);
}

summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 20px 0;
  cursor: pointer;
  list-style: none;
  font-size: 17px;
  font-weight: 700;
}

summary::-webkit-details-marker {
  display: none;
}

summary::after {
  content: "+";
  font-size: 22px;
  font-weight: 400;
  color: var(--fg-3);
  flex-shrink: 0;
}

details[open] summary::after {
  content: "–";
}

details p {
  margin: 0 0 22px;
  color: var(--fg-2);
  max-width: 680px;
}

/* Closing call to action */
.cta {
  position: relative;
  overflow: hidden;
  border-top: 1px solid var(--line-soft);
}

.cta::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to right, var(--bg) 30%, rgba(12, 13, 14, 0.7)),
    linear-gradient(to bottom, var(--bg), transparent 30%);
}

.cta .wrap {
  position: relative;
  z-index: 1;
  padding-top: 96px;
  padding-bottom: 96px;
}

.cta h2 {
  font-size: 88px;
  max-width: 820px;
}

.cta .lede {
  margin-top: 20px;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--line-soft);
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px 32px;
  padding-top: 32px;
  padding-bottom: 36px;
  font-size: 13px;
  color: var(--fg-4);
}

.site-footer nav {
  display: flex;
  gap: 24px;
}

.site-footer nav a {
  color: var(--fg-3);
}

.site-footer nav a:hover {
  color: var(--fg);
}

.site-footer .powered-by {
  margin: 0;
  height: 16px;
}

/* Legal and support pages */
.page-header .wrap {
  padding-top: 130px;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--line-soft);
}

.page-header h1 {
  font-size: 88px;
}

.prose .wrap {
  max-width: 820px;
  margin-left: max(0px, calc((100vw - var(--max)) / 2));
  padding-top: 44px;
  padding-bottom: 96px;
}

.prose h2 {
  font-size: 24px;
  font-weight: 800;
  text-transform: uppercase;
  font-variation-settings: "wdth" 75;
  margin: 44px 0 12px;
}

.prose h3 {
  font-size: 17px;
  font-weight: 700;
  margin: 26px 0 8px;
}

.prose p,
.prose li {
  color: var(--fg-soft);
}

.prose ul {
  padding-left: 20px;
}

.prose li {
  margin: 4px 0;
}

.prose strong {
  color: var(--fg);
}

.prose a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Tablet */
/* Pricing */
.pricing .wrap {
  padding-top: 44px;
  padding-bottom: 96px;
}

.pricing .lede {
  max-width: 640px;
  margin: 0;
}

.plans {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  max-width: 820px;
  margin: 36px 0 64px;
  background: var(--line-soft);
  border: 1px solid var(--line-soft);
}

.plan {
  background: var(--bg);
  padding: 30px 28px 32px;
}

.plan.featured {
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--accent);
}

.plan h2 {
  margin: 0 0 14px;
  font-size: 22px;
  font-weight: 800;
  text-transform: uppercase;
  font-variation-settings: "wdth" 75;
}

.plan .badge {
  margin: 0 0 12px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.plan .price {
  margin: 0 0 6px;
}

.plan .amount {
  font-size: 64px;
  line-height: 1;
  font-weight: 800;
  font-variation-settings: "wdth" 62;
}

.plan .per {
  color: var(--fg-3);
}

.plan .muted {
  margin: 0;
  font-size: 14px;
}

.included {
  list-style: none;
  padding: 0;
  margin: 16px 0 56px;
  max-width: 820px;
  columns: 2;
  column-gap: 40px;
}

.included li {
  break-inside: avoid;
  padding: 10px 0 10px 26px;
  border-bottom: 1px solid var(--line-soft);
  position: relative;
  color: var(--fg-soft);
}

.included li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 17px;
  width: 10px;
  height: 5px;
  border-left: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(-45deg);
}

.notes {
  max-width: 820px;
  margin: 16px 0 48px;
}

.notes dt {
  font-weight: 700;
  margin-top: 22px;
}

.notes dd {
  margin: 6px 0 0;
  color: var(--fg-3);
}

@media (max-width: 1024px) {
  :root {
    --gutter: 28px;
  }

  .hero h1 {
    font-size: 96px;
  }

  .feature .wrap,
  .faq .wrap {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .feature.flip .copy {
    order: 0;
  }

  .feature.wide .copy {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .extras-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .included {
    columns: 1;
  }
}

/* Phone */
@media (max-width: 640px) {
  :root {
    --gutter: 16px;
  }

  .site-header .wrap {
    padding-top: 18px;
    padding-bottom: 18px;
  }

  .site-header .nav-link {
    display: none;
  }

  .plans {
    grid-template-columns: 1fr;
  }

  .plan .amount {
    font-size: 52px;
  }

  .site-header .btn {
    padding: 11px 14px;
    font-size: 12px;
  }

  .logo {
    width: 116px;
  }

  .hero .wrap {
    padding-top: 118px;
    padding-bottom: 56px;
  }

  .hero::after {
    background: linear-gradient(to bottom, rgba(12, 13, 14, 0.45), var(--bg));
  }

  .hero h1 {
    font-size: 64px;
  }

  .hero .lede {
    font-size: 17px;
  }

  .hero-actions .btn {
    flex: 1 1 100%;
  }

  .statement p {
    font-size: 22px;
  }

  .section-title {
    font-size: 32px;
  }

  .feature .wrap {
    padding-top: 60px;
    padding-bottom: 60px;
  }

  .shot-pair {
    grid-template-columns: 1fr;
  }

  .extras-grid {
    grid-template-columns: 1fr;
  }

  .cta h2,
  .page-header h1 {
    font-size: 56px;
  }

  .page-header .wrap {
    padding-top: 100px;
  }
}
