/* FLIGHT GLOBE — minimal dark landing page */

:root {
  --bg: #000000;
  --fg: #f5f5f7;
  --muted: #86868b;
  --muted-dim: #5f5f63;
  --line: rgba(255, 255, 255, 0.12);
  --line-soft: rgba(255, 255, 255, 0.07);
  --accent: #4a9eff;
  --max: 1080px;
  --pad: 24px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: inherit;
  text-decoration: none;
}

h1,
h2,
h3 {
  margin: 0;
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.02em;
}

p {
  margin: 0;
}

/* Each sentence on its own line (wraps internally if it must) */
.line {
  display: block;
}

/* Anchors clear the fixed header */
section[id],
[id='stats'] {
  scroll-margin-top: 84px;
}

/* ---------- Navigation ---------- */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(0, 0, 0, 0.72);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--line-soft);
}

.nav-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--pad);
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* White artwork on a transparent background — no tile, no inversion.
   icon-mark.svg is derived from docs/assets/ICON.svg with its background
   tile removed. */
.brand-mark {
  width: 26px;
  height: 26px;
}

.brand-word {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links a {
  font-size: 14px;
  color: var(--muted);
  transition: color 0.25s var(--ease);
}

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

.nav-cta {
  color: var(--fg);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 15px;
  transition: border-color 0.25s var(--ease);
}

.nav-cta:hover {
  border-color: rgba(255, 255, 255, 0.32);
}

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

.hero {
  max-width: 1140px;
  margin: 0 auto;
  padding: 148px var(--pad) 0;
  text-align: center;
}

.hero-title {
  font-size: clamp(38px, 7.2vw, 80px);
  letter-spacing: -0.035em;
}

/* Second headline line fades white → grey */
.hero-title .gradient-text {
  background: linear-gradient(135deg, #ffffff 0%, #808080 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.hero-sub {
  margin: 24px auto 0;
  max-width: 54ch;
  color: var(--muted);
  font-size: clamp(16px, 1.5vw, 19px);
}

.stores {
  margin-top: 40px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

.store {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 11px 20px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--fg);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.25s var(--ease), background-color 0.25s var(--ease);
}

.store:hover {
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.03);
}

.store-text {
  display: block;
}

.store-small {
  display: block;
  font-size: 11px;
  line-height: 1.25;
  color: var(--muted);
}

.store-big {
  display: block;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.01em;
}

.store-mark {
  width: 22px;
  height: 22px;
  flex: none;
}

/* iPhone build not released yet */
.store[disabled] {
  opacity: 0.45;
  border-style: dashed;
  cursor: default;
}

.store[disabled]:hover {
  border-color: var(--line);
  background: transparent;
}

/* The globe is the focal point. app.js sizes the renderer from this
   element's clientHeight, so the explicit height is required. */
.globe-stage {
  position: relative;
  width: 100%;
  max-width: 880px;
  height: clamp(360px, 58vw, 620px);
  margin: 40px auto 0;
}

.globe-stage canvas {
  display: block;
}

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

.section {
  max-width: var(--max);
  margin: 0 auto;
  padding: 148px var(--pad) 0;
}

.section-title {
  font-size: clamp(28px, 4.2vw, 46px);
  letter-spacing: -0.03em;
  text-align: center;
}

.section-sub {
  margin: 18px auto 0;
  max-width: 56ch;
  text-align: center;
  color: var(--muted);
}

.eyebrow {
  display: block;
  margin-bottom: 16px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-align: center;
  color: var(--muted-dim);
}

/* ---------- Features (no cards) ---------- */

.features {
  margin: 76px auto 0;
  max-width: 860px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 56px 72px;
}

.feature-mark {
  width: 22px;
  height: 22px;
  color: var(--fg);
  opacity: 0.85;
}

.feature h3 {
  margin-top: 20px;
  font-size: 17px;
  letter-spacing: -0.01em;
}

.feature p {
  margin-top: 8px;
  font-size: 14.5px;
  color: var(--muted);
}

/* ---------- App preview ---------- */

.showcase {
  margin-top: 76px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 40px;
}

.shot-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 236px;
  padding: 28px;
  border: 1px solid var(--line-soft);
  border-radius: 18px;
}

.shot-label {
  display: block;
  margin-top: 24px;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted-dim);
}

.shot h3 {
  margin-top: 10px;
  font-size: 17px;
  letter-spacing: -0.01em;
}

.shot p {
  margin-top: 8px;
  font-size: 14.5px;
  color: var(--muted);
}

/* Small live globe in the preview card — sized so it plus the frame padding
   exactly matches .shot-frame's min-height. */
.card-globe {
  width: 180px;
  height: 180px;
}

.card-globe canvas {
  display: block;
}

.mock-log {
  display: flex;
  flex-direction: column;
  gap: 5px;
  text-align: center;
}

.mock-log-date {
  font-size: 11.5px;
  color: var(--muted-dim);
}

.mock-log-airline {
  font-size: 15px;
  font-weight: 500;
}

.mock-log-route {
  font-size: 21px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.mock-nations {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  width: 100%;
}

.mock-ring {
  position: relative;
  width: 116px;
  height: 116px;
}

.mock-ring svg {
  width: 100%;
  height: 100%;
}

.mock-ring-value {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
}

.mock-ring-value strong {
  font-size: 23px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.mock-ring-value span {
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-dim);
}

.mock-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
}

.chip {
  font-size: 11px;
  color: var(--muted);
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  padding: 4px 10px;
}

.chip-more {
  color: var(--muted-dim);
  border-style: dashed;
}

/* ---------- Plans ---------- */

.plans {
  margin: 64px auto 0;
  max-width: 760px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.plan {
  display: flex;
  flex-direction: column;
  padding: 32px 28px;
  border: 1px solid var(--line);
  border-radius: 18px;
}

.plan-pro {
  border-color: rgba(74, 158, 255, 0.42);
}

.plan-name {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted-dim);
}

.plan-price {
  margin-top: 14px;
  font-size: 34px;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.plan-price em {
  font-size: 13px;
  font-style: normal;
  font-weight: 400;
  letter-spacing: 0;
  color: var(--muted);
}

.plan-features {
  margin: 26px 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.plan-features li {
  position: relative;
  padding-left: 20px;
  font-size: 14.5px;
  color: var(--muted);
}

.plan-features li::before {
  content: '✓';
  position: absolute;
  left: 0;
  top: 0;
  font-size: 12px;
  color: var(--muted-dim);
}

.plan-note {
  margin-top: 28px;
  text-align: center;
  font-size: 13px;
  color: var(--muted-dim);
}

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

.footer {
  margin-top: 160px;
  border-top: 1px solid var(--line-soft);
}

.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 40px var(--pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  font-size: 13.5px;
  color: var(--muted-dim);
}

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

.footer-links a {
  transition: color 0.25s var(--ease);
}

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

/* ---------- Subtle reveal ----------
   Only armed when JS is present (html.js), so content is never
   hidden if the script fails to load. */

.js [data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.js [data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .js [data-reveal],
  .js [data-reveal].is-visible {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ---------- Small screens ---------- */

@media (max-width: 900px) {
  .section {
    padding-top: 108px;
  }

  .hero {
    padding-top: 120px;
  }

  .globe-stage {
    height: clamp(280px, 78vw, 440px);
    margin-top: 32px;
  }

  .nav-links {
    gap: 18px;
  }

  .nav-links a {
    font-size: 13px;
  }

  .features {
    grid-template-columns: 1fr;
    gap: 44px;
    margin-top: 56px;
  }

  .showcase {
    grid-template-columns: 1fr;
    gap: 48px;
    margin-top: 56px;
  }

  .plans {
    grid-template-columns: 1fr;
    margin-top: 48px;
  }

  .footer {
    margin-top: 108px;
  }
}

@media (max-width: 520px) {
  .nav-links a:not(.nav-cta) {
    display: none;
  }
}

/* ---------- Social / store links ---------- */

/* The Instagram entry behaves like a store button but stays clickable. */
.store-social .store-mark {
  color: var(--fg);
}

/* Store row inside the Get App section */
.stores-download {
  margin-top: 36px;
}

/* ---------- Statistics band ---------- */

.stats-band {
  margin: 64px auto 0;
  max-width: 860px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border: 1px solid var(--line-soft);
  border-radius: 18px;
  overflow: hidden;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 30px 24px;
  border-left: 1px solid var(--line-soft);
}

.stat:first-child {
  border-left: 0;
}

.stat-value {
  font-size: clamp(24px, 3.2vw, 32px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.stat-value em {
  margin-left: 2px;
  font-size: 14px;
  font-style: normal;
  font-weight: 400;
  color: var(--muted);
}

.stat-label {
  font-size: 13px;
  color: var(--muted-dim);
}

/* Pro price is not decided yet */
.plan-price-tba {
  font-size: 26px;
  letter-spacing: -0.02em;
}

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

.footer-links {
  align-items: center;
}

.footer-social {
  display: inline-flex;
  align-items: center;
}

.footer-social svg {
  width: 18px;
  height: 18px;
}

/* ---------- Legal pages (privacy, terms, imprint) ---------- */

.legal {
  max-width: 760px;
  margin: 0 auto;
  padding: 148px var(--pad) 0;
}

.legal-eyebrow {
  display: block;
  margin-bottom: 16px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted-dim);
}

.legal-title {
  font-size: clamp(30px, 5vw, 48px);
  letter-spacing: -0.03em;
}

.legal-updated {
  margin-top: 14px;
  font-size: 13px;
  color: var(--muted-dim);
}

.legal-content {
  margin-top: 44px;
}

.legal-content h2 {
  margin-top: 40px;
  font-size: 20px;
  letter-spacing: -0.01em;
}

.legal-content h2:first-child {
  margin-top: 0;
}

.legal-content h3 {
  margin-top: 28px;
  font-size: 16px;
  letter-spacing: -0.01em;
}

.legal-content p {
  margin-top: 12px;
  font-size: 15.5px;
  color: var(--muted);
}

.legal-content ul {
  margin: 12px 0 0;
  padding-left: 20px;
  font-size: 15.5px;
  color: var(--muted);
}

.legal-content li {
  margin-top: 6px;
}

.legal-content a {
  color: var(--fg);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.legal-back {
  display: inline-block;
  margin-top: 56px;
  font-size: 14px;
  color: var(--muted);
  border-bottom: 1px solid var(--line);
  transition: color 0.25s var(--ease);
}

.legal-back:hover {
  color: var(--fg);
}

/* ---------- Support ---------- */

.support-actions {
  margin-top: 28px;
  display: flex;
  justify-content: flex-start;
}

.support-button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 22px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 15px;
  font-weight: 500;
  color: var(--fg);
  transition: border-color 0.25s var(--ease), background-color 0.25s var(--ease);
}

.support-button:hover {
  border-color: rgba(255, 255, 255, 0.32);
  background: rgba(255, 255, 255, 0.03);
}

.support-button svg {
  width: 18px;
  height: 18px;
  flex: none;
}

@media (max-width: 900px) {
  .stats-band {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stat {
    padding: 24px 20px;
  }

  .stat:nth-child(3) {
    border-left: 0;
  }

  .stat:nth-child(n + 3) {
    border-top: 1px solid var(--line-soft);
  }

  .legal {
    padding-top: 108px;
  }
}

/* On phones the four boxes read far better as one tidy list:
   value on the left, label on the right. */
@media (max-width: 520px) {
  .stats-band {
    grid-template-columns: 1fr;
  }

  .stat {
    flex-direction: row;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 20px;
    border-left: 0;
    border-top: 1px solid var(--line-soft);
  }

  .stat:first-child {
    border-top: 0;
  }

  .stat-value {
    font-size: 22px;
  }

  .stat-label {
    text-align: right;
  }
}
