/* Shared styles for the TrueFan website. Colours match ios/TrueFanIOS/TrueFanTheme.swift. */
:root {
  --bg: #F8F3E9;
  --paper: #FFFDF8;
  --ink: #19352D;
  --pine: #0A4B3A;
  --muted: #5C6D66;
  --gold: #B98529;
  /* Gold for text, ticks and focus rings: #B98529 is only 2.9:1 on cream, this is 5.6:1 (matches goldText in the app). */
  --gold-text: #82591A;
  --line: #D9DFD6;
  --error: #A6402A;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #07362B;
    --paper: #0C4436;
    --ink: #F8F3E9;
    --pine: #F8F3E9;
    --muted: #C3D0C9;
    --gold: #E0B25C;
    --gold-text: #E0B25C;
    --line: #2A5D4F;
    --error: #F2A08C;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 20px;
}
.wrap { width: 100%; max-width: 560px; text-align: center; }
.icon {
  display: block;
  width: 72px; height: 72px;
  border-radius: 18px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  margin: 0 auto 28px;
}
.eyebrow {
  margin: 0 0 14px;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-text);
}
h1 {
  margin: 0;
  font-family: ui-serif, "New York", Georgia, "Times New Roman", serif;
  font-size: clamp(3rem, 12vw, 4.75rem);
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--pine);
}
.tagline {
  margin: 18px 0 0;
  font-family: ui-serif, "New York", Georgia, serif;
  font-size: clamp(1.375rem, 4.5vw, 1.75rem);
  line-height: 1.3;
  color: var(--pine);
}
.pitch { margin: 20px auto 0; max-width: 34em; color: var(--muted); }
#waitlist {
  margin: 36px auto 0;
  display: flex;
  gap: 10px;
  max-width: 460px;
}
.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;
}
.trap { position: absolute; left: -9999px; }
input[type="email"] {
  flex: 1;
  min-width: 0;
  min-height: 52px;
  padding: 0 18px;
  font: inherit;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 14px;
}
input[type="email"]::placeholder { color: var(--muted); opacity: 0.8; }
button {
  min-height: 52px;
  padding: 0 22px;
  font: inherit;
  font-weight: 600;
  color: #FFFDF8;
  background: #0A4B3A;
  border: 0;
  border-radius: 14px;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.15s ease, opacity 0.15s ease;
}
@media (prefers-color-scheme: dark) {
  button { color: #07362B; background: #F8F3E9; }
}
button:hover { transform: translateY(-1px); }
/* Feedback on press, not only on release. */
button:active, .site-nav a.cta:active, .join a.button:active { transform: scale(0.97); transition-duration: 0.1s; }
button:disabled { opacity: 0.6; cursor: progress; transform: none; }
input:focus-visible, button:focus-visible {
  outline: 3px solid var(--gold-text);
  outline-offset: 2px;
}
.status { min-height: 1.6em; margin: 14px 0 0; font-weight: 500; }
.status.ok { color: var(--pine); }
.status.err { color: var(--error); }
.fineprint { margin: 6px 0 0; font-size: 0.875rem; color: var(--muted); }
footer {
  padding: 24px 20px 32px;
  text-align: center;
  font-size: 0.875rem;
  color: var(--muted);
}
footer a { color: inherit; }
@media (max-width: 480px) {
  #waitlist { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
  button:hover, button:active, .site-nav a.cta:active, .join a.button:active { transform: none; }
}

/* Privacy step: pop-up shown after "Join the waitlist" */
dialog {
  width: min(520px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  padding: 0;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
}
dialog::backdrop { background: rgba(7, 54, 43, 0.55); }
.dialog-body { padding: 28px 24px 24px; text-align: left; }
dialog h2 {
  margin: 0 0 6px;
  font-family: ui-serif, "New York", Georgia, serif;
  font-size: 1.625rem;
  line-height: 1.2;
  color: var(--pine);
}
dialog .for-email { margin: 0 0 16px; color: var(--muted); font-size: 0.9375rem; overflow-wrap: anywhere; }
dialog ul { margin: 0 0 16px; padding-left: 1.2em; }
dialog li { margin-bottom: 8px; }
dialog a, .legal a { color: var(--pine); text-underline-offset: 2px; }
.consent {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin: 18px 0 20px;
  padding: 14px;
  background: var(--bg);
  border-radius: 14px;
  cursor: pointer;
}
.consent input {
  flex: none;
  width: 24px; height: 24px;
  margin: 1px 0 0;
  accent-color: #0A4B3A;
}
.dialog-actions { display: flex; gap: 10px; flex-wrap: wrap-reverse; justify-content: flex-end; }
.dialog-actions button { flex: 1 1 160px; }
button.secondary {
  color: var(--pine);
  background: transparent;
  border: 1px solid var(--line);
}
input[type="checkbox"]:focus-visible { outline: 3px solid var(--gold-text); outline-offset: 2px; }

/* Privacy notice page */
.legal { display: block; flex: 1; width: 100%; max-width: 680px; margin: 0 auto; padding: 40px 20px 24px; }
.legal .back { display: inline-block; margin-bottom: 28px; font-weight: 500; }
.legal h1 { font-size: clamp(2.25rem, 8vw, 3rem); }
.legal .updated { margin: 10px 0 28px; color: var(--muted); }
.legal h2 {
  margin: 36px 0 8px;
  font-family: ui-serif, "New York", Georgia, serif;
  font-size: 1.375rem;
  color: var(--pine);
}
.legal ul { padding-left: 1.2em; }
.legal li { margin-bottom: 6px; }

/* Shown instead of the form while the waitlist is closed (WAITLIST_OPEN in index.html) */
[hidden] { display: none !important; }
.soon {
  margin: 36px auto 0;
  max-width: 460px;
  padding: 20px 22px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 18px;
}
.soon-title {
  margin: 0;
  font-family: ui-serif, "New York", Georgia, serif;
  font-size: 1.375rem;
  color: var(--pine);
}
.soon-text { margin: 6px 0 0; color: var(--muted); }
.soon a { color: var(--pine); text-underline-offset: 2px; }

/* ---------- Site header, footer and the full home page ---------- */
.skip {
  position: absolute; left: 12px; top: -60px; z-index: 10;
  padding: 10px 16px; border-radius: 10px;
  background: var(--paper); color: var(--pine); font-weight: 600;
}
.skip:focus { top: 12px; }
.site-header {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 12px 24px;
  width: 100%; max-width: 1080px; margin: 0 auto; padding: 18px 20px;
}
.brand {
  display: inline-flex; align-items: center; gap: 10px; min-height: 44px;
  font-family: ui-serif, "New York", Georgia, serif; font-size: 1.375rem; font-weight: 600;
  color: var(--pine); text-decoration: none;
}
.brand img { width: 36px; height: 36px; border-radius: 9px; }
.site-nav ul { display: flex; flex-wrap: wrap; gap: 4px 6px; margin: 0; padding: 0; list-style: none; }
.site-nav a {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 12px;
  border-radius: 10px; color: var(--ink); text-decoration: none; font-weight: 500;
}
.site-nav a:hover { background: var(--paper); }
.site-nav a[aria-current="page"] { color: var(--pine); text-decoration: underline; text-underline-offset: 6px; }
.site-nav a.cta { color: #FFFDF8; background: #0A4B3A; }
@media (prefers-color-scheme: dark) { .site-nav a.cta { color: #07362B; background: #F8F3E9; } }
a:focus-visible { outline: 3px solid var(--gold-text); outline-offset: 2px; border-radius: 6px; }

main.home { display: block; padding: 0; }
.section { width: 100%; max-width: 1080px; margin: 0 auto; padding: 64px 20px; }
.section + .section { padding-top: 24px; }
.section-head { max-width: 640px; margin-bottom: 32px; }
.section h2 {
  margin: 0 0 12px;
  font-family: ui-serif, "New York", Georgia, serif;
  font-size: clamp(1.875rem, 5vw, 2.5rem); line-height: 1.15; letter-spacing: -0.01em; color: var(--pine);
}
.section h3 { margin: 0 0 6px; font-size: 1.1875rem; line-height: 1.3; color: var(--pine); }
.section p { margin: 0 0 12px; }
.lead { color: var(--muted); font-size: 1.125rem; }

.hero {
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 48px; align-items: center; padding-top: 40px;
}
.hero .eyebrow { margin-bottom: 14px; }
.hero h1 { font-size: clamp(2.5rem, 7vw, 4rem); line-height: 1.05; }
.hero .pitch { margin: 20px 0 0; max-width: 32em; }
.hero #waitlist { margin: 32px 0 0; }
.hero .status, .hero .fineprint { text-align: left; }
.hero .facts { display: flex; flex-wrap: wrap; gap: 8px; margin: 24px 0 0; padding: 0; list-style: none; }
.hero .facts li {
  padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--paper); font-size: 0.9375rem; color: var(--ink);
}

/* Phone mock-ups, drawn in HTML and CSS with the app's fictional demo titles (no third-party artwork). */
.phones { display: flex; justify-content: center; gap: 20px; }
.phone {
  flex: none; width: 260px; padding: 14px;
  background: #19352D; border-radius: 40px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.18);
}
.screen {
  min-height: 470px; padding: 22px 16px 16px; border-radius: 28px;
  background: #F8F3E9; color: #19352D; font-size: 0.875rem; line-height: 1.4;
}
.screen .s-title { margin: 0 0 2px; font-weight: 700; font-size: 1.25rem; color: #19352D; }
.screen .s-sub { margin: 0 0 14px; color: #5C6D66; }
.chips { display: flex; gap: 6px; margin-bottom: 14px; }
.chips span { padding: 4px 10px; border-radius: 999px; border: 1px solid #D9DFD6; background: #FFFDF8; font-size: 0.75rem; }
.chips span:first-child { background: #0A4B3A; border-color: #0A4B3A; color: #FFFDF8; }
.shelf {
  display: flex; align-items: flex-end; gap: 3px; height: 150px;
  padding: 0 8px; border-bottom: 8px solid #B98529; border-radius: 2px;
}
.shelf + .shelf { margin-top: 18px; }
.spine {
  display: flex; align-items: center; justify-content: center;
  width: 26px; border-radius: 3px 3px 1px 1px; color: #FFFDF8;
  font-size: 0.625rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
  writing-mode: vertical-rl; transform: rotate(180deg); overflow: hidden; white-space: nowrap;
  box-shadow: inset -3px 0 0 rgba(0, 0, 0, 0.15);
}
.spine.tilt { transform: rotate(180deg) translateX(4px) rotate(-8deg); transform-origin: bottom; }
.quiz-card { padding: 16px; border-radius: 18px; background: #FFFDF8; border: 1px solid #D9DFD6; }
.cover {
  display: flex; align-items: flex-end; height: 150px; margin-bottom: 14px; padding: 12px;
  border-radius: 12px; color: #FFFDF8; font-family: ui-serif, Georgia, serif; font-size: 1.25rem; font-weight: 700;
  background: linear-gradient(160deg, #E0B25C 0%, #8C5A3C 45%, #174C58 100%);
}
.q-btn { margin: 14px 0 10px; padding: 12px; border-radius: 12px; background: #0A4B3A; color: #FFFDF8; text-align: center; font-weight: 600; }
.ai-label { color: #0A4B3A; font-weight: 600; text-align: center; }
.goal { margin-top: 12px; padding: 14px; border-radius: 16px; background: #FFFDF8; border: 1px solid #D9DFD6; }
.goal strong { display: block; color: #0A4B3A; }
.bar { height: 10px; margin-top: 8px; border-radius: 999px; background: #E4EDE0; overflow: hidden; }
.bar span { display: block; height: 100%; border-radius: inherit; background: #0A4B3A; }
.stat-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.stat-row div { padding: 10px; border-radius: 12px; background: #E4EDE0; }
.stat-row b { display: block; font-size: 1.25rem; color: #0A4B3A; }

.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin: 0; padding: 0; list-style: none; counter-reset: step; }
.card {
  padding: 24px; background: var(--paper); border: 1px solid var(--line); border-radius: 20px;
}
.steps .card::before {
  counter-increment: step; content: counter(step);
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; margin-bottom: 12px; border-radius: 50%;
  background: var(--bg); color: var(--gold-text); font-weight: 700;
}
.features { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin: 0; padding: 0; list-style: none; }
.card p { color: var(--muted); }
.card p:last-child { margin-bottom: 0; }
.tag {
  display: inline-block; margin-bottom: 10px; padding: 3px 10px; border-radius: 999px;
  background: var(--bg); color: var(--gold-text); font-size: 0.8125rem; font-weight: 600;
}
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; align-items: start; }
.ticks { margin: 0; padding: 0; list-style: none; }
.ticks li { position: relative; margin-bottom: 12px; padding-left: 30px; }
.ticks li::before {
  content: ""; position: absolute; left: 4px; top: 0.45em; width: 12px; height: 7px;
  border-left: 3px solid var(--gold-text); border-bottom: 3px solid var(--gold-text); transform: rotate(-45deg);
}
.band { background: var(--paper); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.join { text-align: center; }
.join .section-head { margin: 0 auto 8px; }
.join a.button {
  display: inline-flex; align-items: center; min-height: 52px; padding: 0 24px; border-radius: 14px;
  color: #FFFDF8; background: #0A4B3A; font-weight: 600; text-decoration: none;
}
@media (prefers-color-scheme: dark) { .join a.button { color: #07362B; background: #F8F3E9; } }
.section a:not(.button) { color: var(--pine); text-underline-offset: 2px; }

.site-footer { width: 100%; padding: 40px 20px 32px; border-top: 1px solid var(--line); text-align: left; }
.site-footer .inner {
  display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 24px;
  max-width: 1080px; margin: 0 auto;
}
.site-footer h2 { margin: 0 0 8px; font-size: 0.9375rem; color: var(--ink); }
.site-footer ul { margin: 0; padding: 0; list-style: none; }
.site-footer li { margin-bottom: 0; }
.site-footer a { display: inline-flex; align-items: center; min-height: 44px; }
.site-footer .small { max-width: 1080px; margin: 24px auto 0; font-size: 0.8125rem; }

@media (max-width: 900px) {
  .hero, .split { grid-template-columns: 1fr; }
  .features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .phones .phone:nth-child(n+2) { display: none; }
}
@media (max-width: 640px) {
  .steps, .features { grid-template-columns: 1fr; }
  .site-footer .inner { grid-template-columns: 1fr; }
  .section { padding: 48px 16px; }
  .phone { width: 240px; }
}
.legal h3 { margin: 20px 0 6px; font-size: 1.0625rem; color: var(--ink); }
main#content > .wrap a { color: var(--pine); text-underline-offset: 2px; }

/* Increase Contrast: darker secondary text and firmer edges. */
@media (prefers-contrast: more) {
  :root { --muted: #3E4C46; --line: #8A968F; }
  .card, .hero .facts li, input[type="email"] { border-color: var(--ink); }
}
@media (prefers-contrast: more) and (prefers-color-scheme: dark) {
  :root { --muted: #E4ECE7; --line: #8FB3A6; }
}
