/* ---------------------------------------------------------------------------
   LikeMinds marketing site — design system mirroring the Flutter app's LikeMindsTheme.
   Source of truth for the mobile app is lib/core/theme/likeminds_theme.dart.
   Keep these tokens in sync if LikeMindsTheme changes.
   --------------------------------------------------------------------------- */

:root {
  /* Backgrounds */
  --bg: #0B0B10;
  --surface: #15161D;
  --surface-high: #1E202A;

  /* Borders & dividers */
  --hairline: rgba(255, 255, 255, 0.10);
  --divider: rgba(255, 255, 255, 0.08);

  /* Text */
  --text-primary: #DEE3E3;
  --text-secondary: #BAC9CC;
  --text-tertiary: #5F6473;

  /* Accents */
  --accent: #00C8FF;
  --accent-deep: #0A84FF;
  --accent-on: #001220; /* Foreground on filled cyan buttons */

  /* Radii */
  --radius-xs: 8px;
  --radius-s: 12px;
  --radius-m: 16px;
  --radius-l: 22px;

  /* Spacing rhythm — multiples of 4 like the app */
  --gap-1: 4px;
  --gap-2: 8px;
  --gap-3: 12px;
  --gap-4: 16px;
  --gap-5: 20px;
  --gap-6: 24px;
  --gap-8: 32px;
  --gap-10: 40px;
  --gap-12: 48px;
  --gap-16: 64px;

  /* Typography families */
  --font-heading: 'Atkinson Hyperlegible', system-ui, sans-serif;
  --font-ui: 'Inter', system-ui, sans-serif;
  --font-body: 'Space Grotesk', system-ui, sans-serif;

  /* Motion */
  --motion-fast: 160ms;
  --motion-med: 280ms;
}

/* ---- reset / base -------------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body, h1, h2, h3, p, ul, ol, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
a { color: inherit; text-decoration: none; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text-primary);
  line-height: 1.5;
  min-height: 100vh;
  /* Soft radial accent in the background — same softness as the matchmake
     glow, subtle enough not to compete with content. */
  background-image:
    radial-gradient(ellipse 1200px 600px at 50% -200px,
      rgba(0, 200, 255, 0.10), transparent 70%),
    radial-gradient(ellipse 800px 500px at 50% 110%,
      rgba(10, 132, 255, 0.06), transparent 70%);
  background-attachment: fixed;
}

/* ---- typography ---------------------------------------------------------- */

h1, h2, h3 { font-family: var(--font-heading); color: var(--text-primary); letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 5vw + 1rem, 4rem); font-weight: 800; line-height: 1.05; }
h2 { font-size: clamp(1.5rem, 2vw + 1rem, 2.25rem); font-weight: 700; line-height: 1.15; }
h3 { font-size: 1.25rem; font-weight: 700; }
p { color: var(--text-secondary); }
.lead { font-size: 1.125rem; line-height: 1.5; color: var(--text-secondary); max-width: 60ch; }
.eyebrow {
  font-family: var(--font-ui);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
}
.muted { color: var(--text-tertiary); }
.accent-text { color: var(--accent); }

/* ---- layout -------------------------------------------------------------- */

.container {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  /* Longhand left/right only — the shorthand `padding: 0 X` would zero
     out the vertical padding the `section` rule below tries to apply
     (CSS class beats element for shorthand collisions). */
  padding-left: var(--gap-5);
  padding-right: var(--gap-5);
}

/* Vertical rhythm between sections. Each section's padding accumulates
   with its neighbour's, so two stacked non-hero sections give 2× this
   value of breathing room. The hero gets extra at the top so the page
   doesn't open feeling cramped against the header. */
section { padding-top: var(--gap-12); padding-bottom: var(--gap-12); }
.hero { padding-top: var(--gap-16); padding-bottom: var(--gap-12); }
@media (max-width: 640px) {
  section { padding-top: var(--gap-8); padding-bottom: var(--gap-8); }
  .hero { padding-top: var(--gap-10); padding-bottom: var(--gap-10); }
}

.stack { display: flex; flex-direction: column; gap: var(--gap-4); }
.stack-lg { display: flex; flex-direction: column; gap: var(--gap-8); }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--gap-3); }

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(11, 11, 16, 0.72);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--hairline);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--gap-3) var(--gap-5);
  max-width: 1080px;
  margin: 0 auto;
}
.brand { display: flex; align-items: center; gap: var(--gap-2); }
.brand__icon { width: 32px; height: 32px; }
/* Two-tone gradient wordmark — mirrors the Flutter app's
   LikeMindsWordmark widget. "Like" is cyan-to-blue, "Minds" is light-
   to-deep slate. Manrope (bold) is the brand-only font; the rest of
   the site uses Atkinson Hyperlegible / Inter / Space Grotesk. The
   gradients are clipped to the text via -webkit-background-clip,
   which is supported by every browser the marketing site cares about. */
.brand__name {
  font-family: 'Manrope', system-ui, sans-serif;
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  display: inline-flex;
  line-height: 1;
}
.brand__name__like,
.brand__name__minds {
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.brand__name__like {
  background-image: linear-gradient(
    to bottom,
    #1FAFFF 0%,
    #0079EF 100%
  );
}
.brand__name__minds {
  background-image: linear-gradient(
    to bottom,
    #AEB7C2 0%,
    #6E7A8B 100%
  );
}

/* ---- buttons (mirror the app's button styles) ---------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--gap-2);
  padding: 12px 22px;
  border-radius: var(--radius-m);
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 0.95rem;
  border: 1px solid transparent;
  transition: transform var(--motion-fast) ease, background var(--motion-fast) ease, border-color var(--motion-fast) ease;
  text-align: center;
  white-space: nowrap;
}
.btn:active { transform: scale(0.97); }
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.btn--primary {
  background: var(--accent);
  color: var(--accent-on);
}
.btn--primary:hover { background: #14d3ff; }

.btn--outline {
  background: transparent;
  color: var(--text-primary);
  border-color: var(--hairline);
}
.btn--outline:hover { border-color: rgba(0, 200, 255, 0.5); color: var(--accent); }

.btn--ghost {
  background: transparent;
  color: var(--text-secondary);
}
.btn--ghost:hover { color: var(--accent); }

.btn--block { width: 100%; }

/* ---- card (mirrors Flutter AppCard — flat, hairline border, no glass) ---- */

.card {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-m);
  /* Roomier on desktop, snug on mobile. The app uses 16 by default but
     for marketing surfaces a bit more breathing room reads as premium. */
  padding: var(--gap-6);
}
@media (min-width: 720px) {
  .card { padding: var(--gap-8); }
}
.card--high { background: var(--surface-high); }
.card--accent { border-color: rgba(0, 200, 255, 0.45); }

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

.hero { text-align: center; padding-top: var(--gap-16); }
.hero h1 { max-width: 14ch; margin: var(--gap-3) auto var(--gap-4); }
.hero .lead { margin: 0 auto var(--gap-8); }
.hero__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: var(--gap-3);
  justify-content: center;
}

/* ---- countdown ----------------------------------------------------------- */

.countdown {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--gap-3);
  max-width: 520px;
  margin: var(--gap-6) auto 0;
}
.countdown__unit {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-s);
  padding: var(--gap-4) var(--gap-2);
  text-align: center;
}
.countdown__value {
  font-family: var(--font-heading);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 800;
  color: var(--text-primary);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.countdown__label {
  font-family: var(--font-ui);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin-top: var(--gap-2);
}
.countdown__deadline {
  text-align: center;
  margin-top: var(--gap-4);
  color: var(--text-tertiary);
  font-size: 0.875rem;
}
.countdown--ended .countdown__unit { opacity: 0.5; }

/* ---- form ---------------------------------------------------------------- */

.form-row { display: flex; gap: var(--gap-3); flex-wrap: wrap; }
.form-row .input { flex: 1 1 220px; }

.input {
  width: 100%;
  padding: 14px 16px;
  background: var(--surface-high);
  color: var(--text-primary);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-s);
  font-family: var(--font-body);
  font-size: 1rem;
  transition: border-color var(--motion-fast) ease;
}
.input::placeholder { color: var(--text-tertiary); }
.input:focus { outline: none; border-color: var(--accent); }

.form-status {
  margin-top: var(--gap-3);
  font-size: 0.875rem;
  min-height: 1.25em;
}
.form-status--ok { color: var(--accent); }
.form-status--err { color: #FF6B81; }

/* ---- giveaway: podium ---------------------------------------------------- */

/* Five glossy circular plates in a row. Centre plate is the mystery
   grand prize (slightly bigger + accented). On narrow screens the row
   wraps to keep individual plates from getting too small to read. */
.podium {
  margin-top: var(--gap-6);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: var(--gap-3);
  flex-wrap: wrap;
}
@media (min-width: 720px) {
  /* Wider gap on desktop so the plates breathe a bit. */
  .podium { gap: var(--gap-5); }
}

.podium__plate {
  position: relative;
  width: 88px;
  aspect-ratio: 1;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  /* Glossy disc — radial highlight at top-left over a darker base.
     Two layered backgrounds: the highlight (radial) painted on top
     of the base gradient (linear). Border catches a hairline of
     edge light so the plate reads as raised. */
  background:
    radial-gradient(
      ellipse 60% 40% at 35% 25%,
      rgba(255, 255, 255, 0.28) 0%,
      rgba(255, 255, 255, 0.0) 60%
    ),
    linear-gradient(to bottom, var(--surface-high) 0%, var(--surface) 100%);
  border: 1px solid var(--hairline);
  box-shadow:
    0 6px 14px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  transition: transform var(--motion-fast) ease;
}
.podium__plate:hover {
  transform: translateY(-2px);
}

.podium__plate--grand {
  width: 112px;
  /* Accent-tinted glossy plate for the mystery prize. Same radial
     highlight technique but the base gradient uses the cyan accent
     so the centre disc reads as the focal point. */
  background:
    radial-gradient(
      ellipse 60% 40% at 35% 25%,
      rgba(255, 255, 255, 0.4) 0%,
      rgba(255, 255, 255, 0.0) 60%
    ),
    linear-gradient(
      to bottom,
      rgba(0, 200, 255, 0.55) 0%,
      rgba(10, 132, 255, 0.25) 100%
    );
  border-color: rgba(0, 200, 255, 0.6);
  box-shadow:
    0 10px 22px rgba(0, 200, 255, 0.25),
    0 6px 14px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.podium__icon {
  font-size: 28px;
  line-height: 1;
  margin-bottom: 4px;
}
.podium__plate--grand .podium__icon {
  font-size: 40px;
  font-family: var(--font-heading);
  font-weight: 800;
  color: #fff;
}
.podium__label {
  font-family: var(--font-ui);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-secondary);
}
.podium__plate--grand .podium__label {
  color: #fff;
}

.podium__fineprint {
  margin-top: var(--gap-6);
  text-align: center;
  color: var(--text-tertiary);
  font-size: 0.875rem;
}

.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--gap-4);
}
.feature__title { font-family: var(--font-ui); font-weight: 700; color: var(--text-primary); margin-bottom: var(--gap-2); }

/* ---- step list (used on /join) ------------------------------------------- */

.steps { display: flex; flex-direction: column; gap: var(--gap-4); }
.step { display: flex; gap: var(--gap-4); }
.step__num {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(0, 200, 255, 0.12);
  border: 1px solid rgba(0, 200, 255, 0.55);
  color: var(--accent);
  font-family: var(--font-ui);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.step__body h3 { font-family: var(--font-ui); font-size: 1rem; margin-bottom: var(--gap-1); }
.step__body p { font-size: 0.95rem; }

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

.site-footer {
  border-top: 1px solid var(--hairline);
  padding: var(--gap-8) var(--gap-5);
  margin-top: var(--gap-16);
  text-align: center;
  color: var(--text-tertiary);
  font-size: 0.875rem;
}
.site-footer a:hover { color: var(--accent); }

/* ---- a11y helpers -------------------------------------------------------- */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
