/* Gainist web — tokens mirror gainist-app/tailwind.config.js */
:root {
  --bg: #0e0d10;
  --surface: #17151a;
  --surface2: #201d23;
  --border: #2c2830;
  --cream: #f5f3f0;
  --muted: rgba(245, 243, 240, 0.58);
  --faint: rgba(245, 243, 240, 0.38);
  --accent: #ff6a2c;
  --accent-light: #ff8a54;
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: dark;
}

body {
  margin: 0;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--cream);
  font-family: 'Space Grotesk', system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  padding: clamp(24px, 5vw, 56px) clamp(22px, 6vw, 64px);
}

a {
  color: inherit;
}

::selection {
  background: var(--accent);
  color: var(--bg);
}

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

/* Brand row (header on every page) */
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  width: fit-content;
}

.brand img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: block;
}

.brand span {
  font-family: 'Sora', sans-serif;
  font-weight: 700;
  font-size: 19px;
  letter-spacing: -0.01em;
}

/* ---- Home ---- */

.hero {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 680px;
  padding: 56px 0;
}

.hero h1 {
  margin: 0;
  font-family: 'Sora', sans-serif;
  font-weight: 800;
  font-size: clamp(38px, 8vw, 64px);
  line-height: 1.06;
  letter-spacing: -0.03em;
}

/* Signature: the weight chart, trending up */
.spark {
  margin: 30px 0 6px 4px;
  width: min(230px, 60%);
  height: auto;
  overflow: visible;
}

.spark path {
  stroke: var(--accent);
  stroke-width: 2.5;
  stroke-linecap: round;
  fill: none;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  animation: draw 1.1s cubic-bezier(0.4, 0, 0.2, 1) 0.25s forwards;
}

.spark circle {
  fill: var(--accent-light);
  opacity: 0;
  animation: appear 0.4s ease 1.2s forwards;
}

@keyframes draw {
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes appear {
  to {
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .spark path {
    animation: none;
    stroke-dashoffset: 0;
  }
  .spark circle {
    animation: none;
    opacity: 1;
  }
}

.sub {
  margin: 22px 0 0;
  max-width: 46ch;
  font-size: 17px;
  color: var(--muted);
}

.stores {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 40px;
}

.store {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 13px 22px 13px 18px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 14px;
  text-decoration: none;
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.store:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
}

.store svg {
  width: 22px;
  height: 22px;
  fill: var(--cream);
  flex: none;
}

.store small {
  display: block;
  font-size: 11px;
  line-height: 1.3;
  color: var(--faint);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.store strong {
  display: block;
  font-family: 'Sora', sans-serif;
  font-weight: 700;
  font-size: 15px;
  line-height: 1.35;
}

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

footer {
  border-top: 1px solid var(--border);
  padding-top: 22px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 26px;
  font-size: 13px;
  color: var(--faint);
}

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

footer a:hover {
  color: var(--cream);
  text-decoration: underline;
  text-underline-offset: 3px;
}

footer .copy {
  margin-left: auto;
}

/* ---- Legal pages ---- */

.doc {
  flex: 1;
  max-width: 640px;
  padding: 48px 0 72px;
}

.doc h1 {
  margin: 0;
  font-family: 'Sora', sans-serif;
  font-weight: 700;
  font-size: 27px;
  letter-spacing: -0.02em;
}

.doc .updated {
  margin: 8px 0 0;
  font-size: 13px;
  color: var(--faint);
}

.doc h2 {
  margin: 34px 0 8px;
  font-family: 'Sora', sans-serif;
  font-weight: 600;
  font-size: 17px;
}

.doc p {
  margin: 0;
  color: var(--muted);
}

.doc p + p {
  margin-top: 10px;
}

.doc strong {
  color: var(--cream);
  font-weight: 500;
}
