/* Tokens: see DESIGN.md at the repo root. */
:root {
  --ink: #1e293b;
  --surface: #f8fafc;
  --accent: #354CA1;
  --accent-dark: #2a3d81;
  --muted: #64748b;
  --rule: #e2e8f0;
  --mark: #d92d20;
  --display: 'Barlow Condensed', 'Arial Narrow', 'Helvetica Neue', Arial, sans-serif;
  --body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --col: 40rem;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--surface);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.55;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 0.15em; }
a:hover { color: var(--accent-dark); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.1;
  margin: 0 0 0.6em;
}
h1 { font-size: 2.25rem; }
h2 { font-size: 1.75rem; }
h3 { font-size: 1.25rem; margin-top: 1.6em; margin-bottom: 0.3em; }
p { margin: 0 0 1em; }

.masthead,
main,
.site-footer {
  max-width: var(--col);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* Masthead */
.masthead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 1.5rem;
  flex-wrap: wrap;
  padding-top: 1.25rem;
  padding-bottom: 1.25rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--ink);
  text-decoration: none;
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.5rem;
  letter-spacing: -0.01em;
}
.brand img { width: 2.5rem; height: 2.5rem; border-radius: 0.5rem; }
.masthead nav { display: flex; gap: 1.25rem; align-items: center; font-size: 0.9375rem; }
.masthead nav a { color: var(--muted); text-decoration: none; }
.masthead nav a:hover { color: var(--ink); }
.masthead nav .nav-app { color: var(--accent); font-weight: 500; }

/* Hero */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 12.5rem;
  gap: 2.5rem;
  align-items: start;
  padding: 2.5rem 0 3rem;
}
.hero h1 { margin-bottom: 0.75rem; }
.hero-copy > p { font-size: 1.125rem; }
.hero-shot { margin: 0; }
.hero-shot img {
  border-radius: 1.25rem;
  border: 1px solid var(--rule);
}
.cta {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}
.store-badge img { width: 10rem; height: auto; }
.cta-web { font-size: 0.9375rem; }

/* Sections share one surface; rules divide them. */
main > section + section { border-top: 1px solid var(--rule); }
.leagues, .how, .faq { padding: 2.5rem 0; }

/* Signature: the league list as a standings sheet. */
.league-list {
  list-style: none;
  margin: 1.25rem 0 1.5rem;
  padding: 0;
  border-top: 1px solid var(--ink);
  font-variant-numeric: tabular-nums;
}
.league-list li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.25rem 1.5rem;
  align-items: baseline;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--rule);
}
.league-list b { font-weight: 600; }
.league-list span {
  color: var(--muted);
  font-size: 0.9375rem;
  text-align: right;
  white-space: nowrap;
}

/* FAQ */
.faq h3 { color: var(--ink); }

/* Footer */
.site-footer {
  border-top: 1px solid var(--rule);
  padding-top: 1.5rem;
  padding-bottom: 3rem;
  color: var(--muted);
  font-size: 0.9375rem;
}
.site-footer nav { display: flex; gap: 1.25rem; flex-wrap: wrap; margin-bottom: 0.75rem; }
.site-footer a { color: var(--muted); }
.site-footer a:hover { color: var(--ink); }
.site-footer p { margin: 0; }

@media (max-width: 40rem) {
  body { font-size: 1rem; }
  h1 { font-size: 2rem; }
  .hero {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding-top: 1.5rem;
  }
  .hero-shot { width: 11rem; }
  .league-list li { grid-template-columns: 1fr; }
  .league-list span { text-align: left; white-space: normal; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
}

/* Calendar subscription landing page */
.calendar-note { font-size: 0.9375rem; color: var(--muted); }
.btn { display: inline-block; background: var(--accent); color: #fff; padding: 0.7rem 1.25rem; border-radius: 0.5rem; text-decoration: none; font-weight: 500; }
.btn:hover { background: var(--accent-dark); color: #fff; }

/* Content pages: leagues and teams */
.league-list b a { color: var(--ink); text-decoration: none; }
.league-list b a:hover { color: var(--accent); }
.team-list li { grid-template-columns: minmax(0, 1fr) auto auto; }
.team-list small { color: var(--muted); font-size: 0.875rem; }
.league-sport { padding: 1.5rem 0 0.5rem; }
.league-sport h3 { color: var(--muted); font-family: var(--body); font-weight: 600; font-size: 0.875rem; letter-spacing: 0; margin: 1.25rem 0 0.25rem; }
.league-week { border-top: 1px solid var(--rule); padding-top: 1.5rem; }
.team-league { color: var(--muted); font-size: 0.9375rem; margin-bottom: 0.25rem; }
.team-league a { color: var(--muted); }
.table-wrap { overflow-x: auto; }
.schedule-table { width: 100%; border-collapse: collapse; font-size: 0.9375rem; font-variant-numeric: tabular-nums; }
.schedule-table th { text-align: left; font-weight: 600; color: var(--muted); font-size: 0.8125rem; padding: 0.4rem 0.5rem 0.4rem 0; border-bottom: 1px solid var(--ink); }
.schedule-table td { padding: 0.5rem 0.5rem 0.5rem 0; border-bottom: 1px solid var(--rule); white-space: nowrap; }
.schedule-table td:nth-child(3) { white-space: normal; }
.page-cta { border-top: 1px solid var(--rule); padding: 2rem 0 1rem; }
.page-cta .cta { align-items: center; }

.cta-note { color: var(--muted); font-size: 0.9375rem; }

/* Print: a schedule a coach can hand out, with a code to the app */
.print-only { display: none; }
.print-link { font: inherit; font-size: 0.875rem; font-weight: 500; color: var(--accent); background: none; border: 0; padding: 0; margin-left: 0.75rem; cursor: pointer; text-decoration: underline; text-underline-offset: 0.15em; }
.print-hint { color: var(--muted); font-size: 0.9375rem; margin-top: -0.25rem; }
@media print {
  .masthead nav, .site-footer, .cta, .page-cta, .print-link, .print-hint { display: none !important; }
  .print-only { display: block; }
  body { background: #fff; color: #000; font-size: 11pt; }
  .masthead, main { max-width: none; padding: 0; }
  .hero { padding: 0 0 0.5rem; grid-template-columns: 1fr; }
  h1 { font-size: 20pt; }
  .schedule-table { font-size: 10pt; }
  .schedule-table td, .schedule-table th { padding: 4pt 6pt 4pt 0; }
  .schedule-table a { color: #000; text-decoration: none; }
  .print-kit { display: flex; gap: 14pt; align-items: center; border-top: 1px solid #000; padding-top: 10pt; margin-top: 12pt; break-inside: avoid; }
  .print-qr svg { width: 96pt; height: 96pt; }
  .print-kit p { margin: 0 0 4pt; font-size: 10pt; }
}
