/* ============================================================
   Fitaino — "Score Report" direction.
   Warm near-black, one amber accent, data-texture details,
   Archivo (display + body) and IBM Plex Mono (data labels).
   ============================================================ */

@font-face {
  font-family: 'Archivo';
  src: url(/fonts/Archivo-Variable-latin.woff2) format('woff2');
  font-weight: 400 900;
  font-display: swap;
}

@font-face {
  font-family: 'IBM Plex Mono';
  src: url(/fonts/IBMPlexMono-400-latin.woff2) format('woff2');
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: 'IBM Plex Mono';
  src: url(/fonts/IBMPlexMono-500-latin.woff2) format('woff2');
  font-weight: 500;
  font-display: swap;
}

:root {
  font-size: 62.5%;

  /* Surfaces — warm-tinted near-black, layered */
  --bg: #0c0b08;
  --bg-band: #110f0b;
  --panel: #14120d;
  --panel-raise: #191610;
  --line: rgba(236, 225, 199, 0.11);
  --line-strong: rgba(236, 225, 199, 0.24);

  /* Text — warm white ramp */
  --text: #f2eee3;
  --text-dim: #aca594;
  --text-faint: #82796a;

  /* The ONE accent */
  --accent: #f2a71b;
  --accent-hover: #ffbc3d;
  --accent-ink: #191204;
  --accent-dim: rgba(242, 167, 27, 0.13);

  /* Rank metals — used ONLY in the rank strip */
  --bronze: #b08d57;
  --silver: #9ea7b3;
  --gold: #d9a441;

  --font-sans: 'Archivo', -apple-system, 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  --font-mono: 'IBM Plex Mono', 'SFMono-Regular', Consolas, monospace;

  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 9rem;
  overflow-x: clip;
}

body {
  margin: 0;
  overflow-x: clip;
  word-break: break-word;
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 1.6rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background: rgba(242, 167, 27, 0.85);
  color: #191204;
}

/* ---------- Typography ---------- */

h1, h2, h3, h4, h5, h6 {
  margin: 0;
  color: var(--text);
  text-wrap: balance;
}

h1 {
  font-size: clamp(4rem, 7vw, 7.2rem);
  font-weight: 640;
  letter-spacing: -0.035em;
  line-height: 1.0;
}

h2 {
  font-size: clamp(3rem, 4.6vw, 4.8rem);
  font-weight: 620;
  letter-spacing: -0.028em;
  line-height: 1.05;
}

h3 {
  font-size: clamp(2rem, 3vw, 2.6rem);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.2;
}

h4 {
  font-size: 1.8rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

p {
  margin: 0;
  font-size: 1.6rem;
  font-weight: 400;
  line-height: 1.65;
  color: var(--text-dim);
}

a {
  color: var(--text);
  text-decoration: none;
}

img {
  max-width: 100%;
}

/* Small uppercase mono annotation — the site's label voice */
.mono-tag {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.mono-tag.accent {
  color: var(--accent);
}

/* Numerals: tabular everywhere they matter */
.num {
  font-variant-numeric: tabular-nums;
}

/* ---------- Layout primitives ---------- */

.container {
  width: 100%;
  max-width: 124rem;
  margin: 0 auto;
  padding: 0 3.2rem;
}

.section {
  padding: 9.6rem 0;
  position: relative;
}

/* Ruled section header: hairline + mono tag left, index right */
.rule-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 2rem;
  border-top: 1px solid var(--line-strong);
  padding-top: 1.6rem;
  margin-bottom: 4.8rem;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 1.3rem 2.4rem;
  border: none;
  border-radius: 0.5rem;
  font-family: inherit;
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: background 0.2s var(--ease), border-color 0.2s var(--ease), color 0.2s var(--ease);
}

.btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-ghost {
  background: transparent;
  border: 1px solid var(--line-strong);
  color: var(--text);
}

.btn-ghost:hover {
  border-color: var(--text-faint);
}

:where(a, button):focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 0.4rem;
}

/* ---------- Store badges ---------- */

.store-badges {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.4rem;
}

.store-badges img {
  height: 4.8rem;
  width: auto;
  display: block;
  border-radius: 0.7rem;
  transition: opacity 0.2s var(--ease);
}

.store-badges a:hover img {
  opacity: 0.85;
}

/* ---------- Scroll animations (used sparingly) ---------- */

[data-animate] {
  opacity: 0;
  transform: translateY(1.6rem);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

[data-animate].is-visible {
  opacity: 1;
  transform: none;
}

[data-animate-delay='1'] { transition-delay: 0.08s; }
[data-animate-delay='2'] { transition-delay: 0.16s; }
[data-animate-delay='3'] { transition-delay: 0.24s; }
[data-animate-delay='4'] { transition-delay: 0.32s; }

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  [data-animate] {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ============================================================
   Phone frame — wraps real app screenshots in a device look.
   ============================================================ */

.phone {
  position: relative;
  width: min(30rem, 76vw);
  padding: 0.9rem;
  border-radius: 4.2rem;
  background: linear-gradient(165deg, #2b261d 0%, #16130d 40%, #0f0d09 100%);
  border: 1px solid rgba(236, 225, 199, 0.16);
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.phone::after {
  /* Notch */
  content: '';
  position: absolute;
  top: 1.9rem;
  left: 50%;
  transform: translateX(-50%);
  width: 8rem;
  height: 2.1rem;
  border-radius: 99rem;
  background: #05070b;
  z-index: 2;
}

/* The inner screen keeps the exact screenshot aspect ratio so nothing crops. */
.phone.shot {
  aspect-ratio: auto;
  height: auto;
}

.phone-screen.screenshot {
  position: relative;
  overflow: hidden;
  border-radius: 3.4rem;
  height: auto;
  aspect-ratio: 1206 / 2622;
  padding: 0;
  background: #0a0d13;
}

.phone-screen.screenshot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ---------- Legal pages ---------- */

.legal-page {
  max-width: 84rem;
  margin: 0 auto;
  padding: 14rem 3.2rem 8rem;
}

.legal-page-header {
  margin-bottom: 4rem;
  border-top: 1px solid var(--line-strong);
  padding-top: 1.6rem;
}

.legal-body {
  border-top: 1px solid var(--line);
  padding: 3.2rem 0 0;
}

.legal-body h4 {
  margin: 3.2rem 0 1.2rem;
  font-size: 2.1rem;
}

.legal-body h5 {
  margin: 2.4rem 0 0.8rem;
  font-size: 1.7rem;
  font-weight: 600;
  color: var(--text);
}

.legal-body h6 {
  margin: 2rem 0 0.6rem;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text);
}

.legal-body p,
.legal-body li {
  font-size: 1.5rem;
  color: var(--text-dim);
}

.legal-body a {
  color: var(--accent);
}

/* ---------- Support page ---------- */

.support-page {
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16rem 3.2rem 10rem;
}

.support-card {
  max-width: 58rem;
  width: 100%;
  border-top: 1px solid var(--line-strong);
  padding-top: 2.4rem;
}

.support-card h2 {
  margin: 1.2rem 0 1.6rem;
}

.support-card .email-btn {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  margin-top: 3.2rem;
  padding: 1.3rem 2.4rem;
  border-radius: 0.5rem;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  font-size: 1.5rem;
  transition: background 0.2s var(--ease);
}

.support-card .email-btn:hover {
  background: var(--accent-hover);
}

/* ---------- Misc ---------- */

main {
  display: block;
  min-height: 60vh;
}

#blazor-error-ui {
  display: none;
}

@media (max-width: 720px) {
  .container {
    padding: 0 2rem;
  }

  .section {
    padding: 6.4rem 0;
  }

  .rule-head {
    margin-bottom: 3.2rem;
  }

  .legal-page,
  .support-page {
    padding-left: 2rem;
    padding-right: 2rem;
  }
}
