/* Constela marketing site. Same approach as wontfit.app: no build step for
   the styles, no framework, no script. scripts/build-site.mjs writes the
   pages; this file is hand-written.

   Dark only, like the app: the globe is drawn on space and so is the page.
   One accent, the app's own blue, means "do this". The constellation colours
   appear only where they name a constellation, as in the app. */
:root {
  color-scheme: dark;
  --bg: #05070d;
  --surface: #0c111d;
  --surface-2: #111828;
  --stage: linear-gradient(160deg, #111828 0%, #070a12 100%);
  --line: rgba(255, 255, 255, 0.10);
  --ink: #e8ecf4;
  --ink-soft: #a3abbd;

  --accent: #7cc4ff;
  --accent-text: #8fcdff;
  --accent-ink: #06111f;
  --accent-soft: rgba(124, 196, 255, 0.13);

  --starlink: #7cc4ff;
  --leo: #ffb347;
  --oneweb: #8df0b0;
  --qianfan: #ff8fb8;
  --guowang: #e6d26b;

  --glow: radial-gradient(60% 55% at 78% 30%, rgba(124, 196, 255, 0.16), transparent 70%),
          radial-gradient(45% 50% at 12% 10%, rgba(255, 179, 71, 0.07), transparent 70%);
  --stars: radial-gradient(1px 1px at 12% 18%, rgba(255,255,255,.55), transparent 60%),
           radial-gradient(1px 1px at 32% 72%, rgba(255,255,255,.35), transparent 60%),
           radial-gradient(1px 1px at 58% 12%, rgba(255,255,255,.45), transparent 60%),
           radial-gradient(1px 1px at 84% 64%, rgba(255,255,255,.35), transparent 60%),
           radial-gradient(1px 1px at 46% 44%, rgba(255,255,255,.25), transparent 60%),
           radial-gradient(1px 1px at 92% 22%, rgba(255,255,255,.4), transparent 60%),
           radial-gradient(1px 1px at 6% 86%, rgba(255,255,255,.3), transparent 60%);
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 16px 40px rgba(0, 0, 0, 0.5);

  --radius: 18px;
  --pill: 980px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 72px; background: var(--bg); }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.5 -apple-system, BlinkMacSystemFont, "SF Pro Text",
    "SF Pro Display", "Segoe UI", Roboto, "Helvetica Neue", Arial,
    "Hiragino Sans", "Hiragino Kaku Gothic ProN", "PingFang SC", "Noto Sans CJK", "Microsoft YaHei", sans-serif;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
:lang(ja) body, :lang(zh-Hans) body, body:lang(ja), body:lang(zh-Hans) { letter-spacing: 0; }

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent-text); }

.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding-inline: 20px; }

.skip { position: absolute; left: -999px; top: 8px; background: var(--accent); color: var(--accent-ink); padding: 8px 14px; border-radius: 8px; z-index: 20; }
.skip:focus { left: 8px; }

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

/* ---- header ---- */

header {
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  background: color-mix(in srgb, var(--bg) 80%, transparent);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  z-index: 10;
}
header .wrap { display: flex; align-items: center; gap: 18px; padding-block: 10px; }

.logo {
  flex: none;
  display: flex; align-items: center; gap: 10px;
  font-weight: 800; letter-spacing: -0.2px; font-size: 19px;
  color: var(--ink); text-decoration: none;
}
.logo img { width: 30px; height: 30px; border-radius: 8px; }
.logo span span {
  display: block; white-space: nowrap;
  font-size: 10px; font-weight: 600; letter-spacing: 0.6px;
  color: var(--ink-soft); line-height: 1;
}

nav.top { margin-left: auto; display: flex; gap: 4px; align-items: center; }
nav.top a {
  color: var(--ink-soft); text-decoration: none;
  padding: 7px 10px; border-radius: 8px; font-size: 14px; white-space: nowrap;
  transition: color 0.2s ease;
}
nav.top a:hover { color: var(--ink); }
nav.top a.nav-cta {
  background: var(--accent); color: var(--accent-ink); font-weight: 600;
  border-radius: var(--pill); padding: 7px 15px; margin-left: 6px;
}
nav.top a.nav-cta:hover { color: var(--accent-ink); filter: brightness(1.08); }

/* ---- buttons ---- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 12px 22px; border-radius: var(--pill);
  text-decoration: none; font-weight: 600; font-size: 16px;
  border: 1px solid transparent; cursor: pointer; text-align: center;
  transition: filter 0.2s ease, background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}
.btn svg { width: 20px; height: 20px; flex: none; }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { filter: brightness(1.08); transform: translateY(-1px); }
.btn-ghost { border-color: var(--line); color: var(--ink); background: var(--surface); }
.btn-ghost:hover { border-color: var(--accent-text); color: var(--accent-text); }

/* Store buttons: the store's mark and two lines, like the badges, drawn in
   the page's own style. */
.btn-store { background: var(--ink); color: var(--bg); padding: 9px 20px 9px 16px; text-align: left; }
.btn-store:hover { transform: translateY(-1px); filter: brightness(0.94); }
.btn-store svg { width: 24px; height: 24px; }
.btn-store small { display: block; font-size: 11px; font-weight: 500; line-height: 1.1; letter-spacing: 0.01em; }
.btn-store b { display: block; font-size: 17px; line-height: 1.15; letter-spacing: -0.01em; }

.cta-row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.cta-note { font-size: 14px; color: var(--ink-soft); margin: 16px 0 0; }

/* ---- small labels ---- */

.kicker {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 13px; font-weight: 700; letter-spacing: 0.02em;
  color: var(--accent-text); background: var(--accent-soft);
  padding: 5px 12px; border-radius: var(--pill);
  text-decoration: none; margin-bottom: 18px;
}
.kicker svg { width: 14px; height: 14px; }

.grad {
  background: linear-gradient(120deg, var(--starlink), var(--oneweb));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* The five constellations in their app colours. */
.legend { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 22px 0 0; }
.legend li {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 13px; font-weight: 600; color: var(--ink-soft);
  border: 1px solid var(--line); background: var(--surface);
  border-radius: var(--pill); padding: 4px 11px 4px 9px;
}
.legend li::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--c); }

/* ---- hero ---- */

.hero-band { background: var(--glow), var(--stars); border-bottom: 1px solid var(--line); }
.hero { padding-block: 64px 64px; }
.hero h1 {
  font-size: clamp(38px, 6vw, 64px); line-height: 1.04; letter-spacing: -0.035em;
  font-weight: 700; margin: 0 0 18px; max-width: 15ch;
}
.hero p.lede { font-size: clamp(18px, 2.1vw, 21px); line-height: 1.42; color: var(--ink-soft); max-width: 36ch; margin: 0 0 28px; }
:lang(ja) .hero h1, :lang(zh-Hans) .hero h1 { letter-spacing: 0; line-height: 1.2; }

.hero.split { display: grid; gap: 40px; align-items: center; }
@media (min-width: 900px) { .hero.split { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; } }

.stage {
  position: relative; background: var(--stage);
  border: 1px solid var(--line); border-radius: 24px;
  box-shadow: var(--shadow); overflow: hidden;
}
.stage .tag {
  position: absolute; right: 14px; bottom: 12px;
  font-size: 12px; font-weight: 600; color: var(--ink-soft);
  background: color-mix(in srgb, var(--surface) 85%, transparent);
  border: 1px solid var(--line); border-radius: var(--pill); padding: 4px 10px;
}

/* ---- sections ---- */

section { padding-block: 72px; }
h2 { font-size: clamp(28px, 4vw, 42px); line-height: 1.08; font-weight: 700; letter-spacing: -0.03em; margin: 0 0 10px; }
:lang(ja) h2, :lang(zh-Hans) h2 { letter-spacing: 0; line-height: 1.25; }
.section-lede { color: var(--ink-soft); margin: 0 0 32px; max-width: 56ch; font-size: 19px; }
.center { text-align: center; }
.center .section-lede { margin-inline: auto; }

/* ---- screenshot strip ---- */

.shots {
  list-style: none; padding: 0; margin: 0;
  display: grid; grid-auto-flow: column; grid-auto-columns: minmax(200px, 1fr);
  gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory;
  padding-bottom: 8px; -webkit-overflow-scrolling: touch;
}
.shots li { scroll-snap-align: start; margin: 0; }
.shots .stage { border-radius: 22px; }
.shots figcaption { font-size: 14px; color: var(--ink-soft); margin-top: 10px; text-align: center; }
.shots figure { margin: 0; }
@media (max-width: 620px) { .shots { grid-auto-columns: 62%; } }

/* ---- feature blocks ---- */

.features { display: grid; gap: 16px; }
@media (min-width: 900px) { .features { grid-template-columns: repeat(3, 1fr); } }

.feature {
  background: var(--glow), var(--surface);
  border: 1px solid var(--line); border-radius: 24px;
  padding: 28px; display: flex; flex-direction: column; gap: 14px;
}
.feature h2 { font-size: clamp(24px, 2.6vw, 28px); letter-spacing: -0.02em; margin: 0; }
.feature p { margin: 0; color: var(--ink-soft); font-size: 16px; }
.feature .icon {
  width: 42px; height: 42px; display: grid; place-items: center;
  border-radius: 12px; background: var(--accent-soft); color: var(--accent-text);
}
.feature .icon svg { width: 22px; height: 22px; }
@media (min-width: 900px) {
  .feature.wide { grid-column: 1 / -1; }
  .feature.wide .ticks { columns: 2; column-gap: 40px; }
  .feature.wide .ticks li { break-inside: avoid; }
}

.ticks { list-style: none; padding: 0; margin: 0; }
.ticks li { padding-left: 28px; position: relative; margin-bottom: 10px; font-size: 16px; }
.ticks li::before {
  content: ""; position: absolute; left: 3px; top: 7px;
  width: 12px; height: 7px;
  border-left: 2px solid var(--accent-text); border-bottom: 2px solid var(--accent-text);
  transform: rotate(-45deg);
}

/* ---- card grid ---- */

.grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
@media (min-width: 900px) { .grid.three { grid-template-columns: repeat(3, 1fr); } }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.card h3 { margin: 0 0 4px; font-size: 18px; font-weight: 700; letter-spacing: -0.015em; }
.card p { margin: 0; color: var(--ink-soft); font-size: 15px; line-height: 1.5; }
.card .icon {
  width: 38px; height: 38px; display: grid; place-items: center;
  border-radius: 10px; background: var(--accent-soft); color: var(--accent-text); margin-bottom: 14px;
}
.card .icon svg { width: 19px; height: 19px; }

.callout {
  background: var(--accent-soft);
  border: 1px solid color-mix(in srgb, var(--accent-text) 30%, transparent);
  border-radius: var(--radius); padding: 16px 18px; margin: 22px 0 0;
}
.callout p { margin: 0; color: var(--ink); font-size: 15px; }

/* ---- FAQ ---- */

.faq { max-width: 760px; margin: 0 auto; }
.faq details { border-bottom: 1px solid var(--line); }
.faq details:first-of-type { border-top: 1px solid var(--line); }
.faq summary {
  cursor: pointer; list-style: none; padding: 18px 36px 18px 0; position: relative;
  font-size: 18px; font-weight: 600; letter-spacing: -0.012em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: 8px; top: 26px; width: 9px; height: 9px;
  border-right: 2px solid var(--ink-soft); border-bottom: 2px solid var(--ink-soft);
  transform: rotate(45deg); transition: transform 0.2s ease;
}
.faq details[open] summary::after { transform: rotate(225deg); top: 30px; }
.faq h3 { font: inherit; margin: 0; display: inline; }
.faq details p { margin: 0 0 18px; color: var(--ink-soft); font-size: 16px; }

/* ---- closing band ---- */

.closing {
  background: var(--glow), var(--stars), var(--surface);
  border: 1px solid var(--line); border-radius: 28px;
  padding: 56px 24px; text-align: center;
}
.closing h2 { margin-bottom: 8px; }
.closing p { color: var(--ink-soft); margin: 0 0 24px; font-size: 19px; }
.closing .cta-row { justify-content: center; }

/* ---- footer ---- */

footer.site {
  border-top: 1px solid var(--line); margin-top: 40px;
  padding-block: 32px 48px; color: var(--ink-soft); font-size: 14px;
}
footer.site .wrap { display: flex; gap: 12px 20px; flex-wrap: wrap; align-items: center; }
footer.site a { color: var(--ink-soft); text-decoration: none; }
footer.site a:hover { color: var(--ink); text-decoration: underline; }
footer.site .spacer { margin-left: auto; }
footer.site .disclaimer { flex-basis: 100%; margin: 4px 0 0; font-size: 13px; max-width: 80ch; }
footer.site .languages { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13px; padding-top: 6px; }
footer.site .languages a[aria-current="page"] { color: var(--ink); font-weight: 600; }

@media (max-width: 720px) { nav.top a.optional { display: none; } }
@media (max-width: 480px) {
  .logo span span { display: none; }
  header .wrap { gap: 8px; }
  nav.top a { padding-inline: 8px; }
}
@media (max-width: 620px) {
  .hero { padding-block: 40px 40px; }
  section { padding-block: 48px; }
  .feature { padding: 22px; }
  footer.site .spacer { margin-left: 0; width: 100%; }
  .hero .cta-row .btn { flex: 1 1 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .faq summary::after { transition: none; }
  .btn:hover { transform: none; }
}

/* Break Japanese and Chinese headings between phrases, not mid-word, where
   the browser can. */
:lang(ja) h1, :lang(ja) h2, :lang(zh-Hans) h1, :lang(zh-Hans) h2 { word-break: auto-phrase; }
