/* Together We Compete — styles
   Mobile first. Breakpoints: 640px, 900px. */

:root {
  --ink: #14161a;
  --page: #fbfaf7;
  --surface: #eceae3;
  --body: #55575c;
  --blue: #1f5eff;
  --orange: #ff6a3d;
  --rule: rgba(20, 22, 26, 0.14);
  --rule-dark: rgba(251, 250, 247, 0.16);

  --font-head: "Archivo", "Arial Black", Arial, sans-serif;
  --font-body: "Hanken Grotesk", "Helvetica Neue", Arial, sans-serif;
  --font-label: "Space Grotesk", "Helvetica Neue", Arial, sans-serif;

  --container: 1120px;
  --gutter: 1.25rem;
  --section-y: 4.5rem;
}

@media (min-width: 640px) {
  :root { --gutter: 2rem; --section-y: 6rem; }
}
@media (min-width: 900px) {
  :root { --gutter: 2.5rem; --section-y: 8rem; }
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.55;
}
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3, h4, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }
button, input, textarea { font: inherit; color: inherit; }

:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
}
.band :focus-visible,
.site-footer :focus-visible {
  outline-color: var(--orange);
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -100%;
  z-index: 100;
  padding: 0.6rem 1rem;
  background: var(--ink);
  color: var(--page);
  text-decoration: none;
}
.skip-link:focus { top: 1rem; }

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Type */
.eyebrow {
  font-family: var(--font-label);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 1.25rem;
}
.band .eyebrow { color: var(--orange); }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.05;
  text-wrap: balance;
}

.hero__title {
  font-weight: 900;
  font-size: clamp(2.75rem, 11vw, 4.75rem);
  letter-spacing: -0.03em;
  line-height: 0.95;
  max-width: 12ch;
}
.section__title {
  font-size: clamp(2rem, 6.5vw, 3.5rem);
  max-width: 18ch;
}
.section__lede,
.hero__lede {
  color: var(--body);
  font-size: 1.125rem;
  max-width: 34rem;
  margin-top: 1.5rem;
}
.band .section__lede { color: rgba(251, 250, 247, 0.78); }
.hero__lede { font-size: clamp(1.125rem, 2.4vw, 1.375rem); margin-top: 2rem; }

.placeholder {
  color: var(--orange);
  font-family: var(--font-label);
  font-weight: 500;
}
/* Orange fails contrast on light backgrounds, so placeholders there use blue. */
.section .placeholder,
.page-head .placeholder { color: var(--blue); }

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3.25rem;
  padding: 0 1.5rem;
  font-family: var(--font-label);
  font-weight: 600;
  font-size: 0.9375rem;
  letter-spacing: 0.02em;
  text-decoration: none;
  border: 2px solid var(--ink);
  border-radius: 999px;
  cursor: pointer;
  transition: background-color 120ms ease, color 120ms ease, border-color 120ms ease;
}
.button--primary { background: var(--ink); color: var(--page); }
.button--primary:hover { background: var(--blue); border-color: var(--blue); }
.button--secondary { background: transparent; color: var(--ink); }
.button--secondary:hover { border-color: var(--blue); color: var(--blue); }
.button--light { background: var(--page); color: var(--ink); border-color: var(--page); }
.button--light:hover { background: var(--orange); border-color: var(--orange); }
.button--small { min-height: 2.5rem; padding: 0 1.125rem; font-size: 0.8125rem; }
.button-row { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2.5rem; }
.button-row .button { flex: 1 1 auto; }
@media (min-width: 640px) { .button-row .button { flex: 0 0 auto; } }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--page);
  border-bottom: 1px solid var(--rule);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4rem;
  flex-wrap: wrap;
}
.logo img { height: 28px; width: auto; }

.nav-toggle {
  background: none;
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 0.4rem 1rem;
  font-family: var(--font-label);
  font-weight: 600;
  font-size: 0.8125rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}
.nav-toggle[aria-expanded="true"] .nav-toggle__label::after { content: " ×"; }

.site-nav { display: none; flex-basis: 100%; padding-bottom: 1rem; }
.site-nav.is-open { display: block; }
.site-nav ul { display: flex; flex-direction: column; gap: 0.25rem; }
.site-nav a:not(.button) {
  display: block;
  padding: 0.75rem 0;
  font-family: var(--font-label);
  font-weight: 500;
  font-size: 0.9375rem;
  text-decoration: none;
  border-bottom: 1px solid var(--rule);
}
.site-nav a:not(.button):hover,
.site-nav a[aria-current="page"] { color: var(--blue); }
.site-nav .button { margin-top: 0.75rem; align-self: flex-start; }

@media (min-width: 900px) {
  .nav-toggle { display: none; }
  .site-nav { display: block; flex-basis: auto; padding: 0; }
  .site-nav ul { flex-direction: row; align-items: center; gap: 2rem; }
  .site-nav a:not(.button) { padding: 0; border: 0; }
  .site-nav .button { margin: 0; }
}

/* Sections */
.hero { padding-block: calc(var(--section-y) * 0.9) var(--section-y); }
.hero__inner { display: grid; gap: 3rem; }
.hero__visual {
  position: relative;
  aspect-ratio: 4 / 3;
}
.hero__visual canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  opacity: 0;
  transition: opacity 600ms ease;
  touch-action: pan-y;
  cursor: grab;
}
.hero__visual canvas.is-ready { opacity: 1; }
.hero__visual canvas.is-grabbing { cursor: grabbing; }
@media (min-width: 900px) {
  .hero { padding-block: calc(var(--section-y) * 0.75) var(--section-y); }
  .hero__inner { grid-template-columns: 1.15fr 0.85fr; align-items: center; gap: 4rem; }
  .hero__visual { aspect-ratio: 4 / 5; }
}
.section { padding-block: var(--section-y); }
.section--tight { padding-top: 0; }
[id] { scroll-margin-top: 4.5rem; }

.page-head { padding-block: calc(var(--section-y) * 0.8) calc(var(--section-y) * 0.6); }
.page-head__title {
  font-weight: 900;
  font-size: clamp(2.5rem, 9vw, 4.75rem);
  letter-spacing: -0.03em;
  line-height: 0.98;
  max-width: 14ch;
}

.band { background: var(--ink); color: var(--page); padding-block: var(--section-y); }
.band__inner { display: grid; gap: 2rem; }
.band__action { display: flex; align-items: end; }
.band__action .button { width: 100%; }
@media (min-width: 640px) { .band__action .button { width: auto; } }
@media (min-width: 900px) {
  .band__inner { grid-template-columns: 1fr auto; align-items: end; gap: 4rem; }
}

.section__more { margin-top: 2rem; font-family: var(--font-label); font-weight: 600; font-size: 0.9375rem; }
.section__more a { text-decoration: none; border-bottom: 2px solid var(--ink); padding-bottom: 0.15rem; }
.section__more a:hover { color: var(--blue); border-color: var(--blue); }

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

/* Prose (about page) */
.prose { max-width: 38rem; }
.prose p { font-size: clamp(1.125rem, 2.2vw, 1.375rem); line-height: 1.5; }
.prose p + p { margin-top: 1.5rem; }
.prose p:first-of-type { color: var(--ink); }
.prose p:not(:first-of-type) { color: var(--body); }
.section--alt { background: var(--surface); }

/* Steps */
.steps {
  display: grid;
  gap: 2.5rem;
  margin-top: 3.5rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--rule);
}
@media (min-width: 900px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 3rem; } }
.step__number {
  display: block;
  font-family: var(--font-label);
  font-weight: 600;
  font-size: 0.8125rem;
  letter-spacing: 0.18em;
  color: var(--blue);
  margin-bottom: 1rem;
}
.step__title { font-size: 1.5rem; margin-bottom: 0.75rem; }
.step p { color: var(--body); max-width: 28rem; }

/* Donate */
.split { display: grid; gap: 2.5rem; }
@media (min-width: 640px) { .split { grid-template-columns: 1fr 1fr; gap: 3rem; } }
.list-heading { font-size: 1.25rem; margin-bottom: 1rem; }
.plain-list li {
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--rule);
}
.note { color: var(--body); margin-top: 1.25rem; font-size: 0.9375rem; }

.methods { display: grid; gap: 1.5rem; margin-top: 3rem; max-width: 44rem; }
@media (min-width: 640px) { .methods { grid-template-columns: repeat(2, 1fr); gap: 2rem; } }
.method { padding-top: 1rem; border-top: 2px solid var(--ink); }
.method__title { font-size: 1.125rem; margin-bottom: 0.5rem; }
.method p { color: var(--body); font-size: 0.9375rem; }

/* Form */
.form { margin-top: 4rem; max-width: 44rem; }
.form__title { font-size: 1.5rem; margin-bottom: 1.75rem; }
.form__grid { display: grid; gap: 1.25rem; }
@media (min-width: 640px) {
  .form__grid { grid-template-columns: 1fr 1fr; gap: 1.5rem 1.25rem; }
  .field--full { grid-column: 1 / -1; }
}
.field { display: flex; flex-direction: column; gap: 0.4rem; }
fieldset.field { border: 0; padding: 0; margin: 0; min-width: 0; }
.field label, .field legend {
  font-family: var(--font-label);
  font-weight: 500;
  font-size: 0.875rem;
  padding: 0;
}
.optional { color: var(--body); font-weight: 400; }
.field input[type="text"],
.field input[type="email"],
.field input[type="tel"],
.field input[type="number"],
.field textarea {
  width: 100%;
  padding: 0.8rem 0.9rem;
  background: var(--page);
  border: 1.5px solid var(--ink);
  border-radius: 6px;
}
.field textarea { resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: #7a7c80; }
.radio-group { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; margin-top: 0.25rem; }
.radio { display: inline-flex; align-items: center; gap: 0.5rem; font-family: var(--font-body); font-size: 1rem; }
.radio input { width: 1.125rem; height: 1.125rem; accent-color: var(--blue); margin: 0; }
.form .button { margin-top: 1.75rem; width: 100%; }
@media (min-width: 640px) { .form .button { width: auto; } }
.form__notice {
  margin-top: 1rem;
  padding: 0.9rem 1rem;
  border-left: 3px solid var(--orange);
  color: var(--ink);
  font-size: 0.9375rem;
}

/* Events */
.events { margin-top: 3rem; border-top: 1px solid var(--rule); }
.events--top { margin-top: 0; }
.events--top + .events-empty { margin-top: 0; }
.event {
  display: grid;
  gap: 0.35rem 1.5rem;
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--rule);
  grid-template-columns: 5rem 1fr;
  grid-template-areas:
    "date sport"
    "date title"
    "date where"
    "date link";
}
.event__date {
  grid-area: date;
  font-family: var(--font-head);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1;
}
.event__date-month {
  display: block;
  font-family: var(--font-label);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 0.35rem;
}
.event__date-day { font-size: 2.25rem; }
.event__sport {
  grid-area: sport;
  font-family: var(--font-label);
  font-weight: 500;
  font-size: 0.8125rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--body);
}
.event__title { grid-area: title; font-size: 1.375rem; }
.event__where { grid-area: where; color: var(--body); }
.event__link { grid-area: link; margin-top: 0.5rem; font-family: var(--font-label); font-weight: 600; font-size: 0.9375rem; }
.event__link:hover { color: var(--blue); }
@media (min-width: 640px) {
  .event { grid-template-columns: 7rem 1fr auto; grid-template-areas:
    "date sport link"
    "date title link"
    "date where link"; align-items: start; }
  .event__link { margin-top: 0.25rem; align-self: center; }
}
.events-empty {
  margin-top: 3rem;
  padding: 2rem 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  color: var(--body);
  max-width: 32rem;
}

/* Facts */
.facts { max-width: 36rem; margin-top: 2.5rem; }
.facts li { padding: 1rem 0; border-top: 1px solid var(--rule); font-size: 1.0625rem; }
.facts li:last-child { border-bottom: 1px solid var(--rule); }

/* Founders */
.founders { display: grid; gap: 2rem; margin-top: 2.5rem; }
@media (min-width: 640px) { .founders { grid-template-columns: repeat(3, 1fr); gap: 2rem; } }
.founder { display: grid; gap: 0.25rem; }
.founder__photo {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 12px;
  background: var(--page);
  margin-bottom: 0.75rem;
}
.founder__photo img { width: 100%; height: 100%; object-fit: cover; }
.founder__name { font-size: 1.375rem; }
.founder__role { color: var(--body); font-family: var(--font-label); font-size: 0.875rem; }
.founders + .note { margin-top: 2rem; }

/* Pillars (Mini Olympics) */
.pillars { display: grid; gap: 2rem; margin-top: 3rem; }
@media (min-width: 900px) { .pillars { grid-template-columns: repeat(3, 1fr); gap: 2.5rem; } }
.pillar { padding-top: 1.25rem; border-top: 2px solid var(--blue); }
.pillar__title { font-size: 1.25rem; margin-bottom: 0.6rem; }
.pillar p { color: var(--body); max-width: 26rem; }

/* Contact */
.contact { margin-top: 2.5rem; max-width: 36rem; }
.contact li { display: flex; gap: 1.5rem; align-items: baseline; padding: 1rem 0; border-top: 1px solid var(--rule); }
.contact li:last-child { border-bottom: 1px solid var(--rule); }
.contact__label { flex: 0 0 6rem; font-family: var(--font-label); font-weight: 500; font-size: 0.875rem; color: var(--body); }
.contact a { text-decoration: none; }
.contact a:hover { text-decoration: underline; }

/* Footer */
.site-footer {
  background: var(--ink);
  color: var(--page);
  padding-block: 3.5rem;
}
.site-footer__mission {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: clamp(1.5rem, 4vw, 2rem);
  letter-spacing: -0.02em;
  line-height: 1.1;
  max-width: 16ch;
}
.site-footer__grid {
  display: grid;
  gap: 1.5rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rule-dark);
}
@media (min-width: 640px) { .site-footer__grid { grid-template-columns: 1fr 1fr; gap: 2rem; } }
.site-footer__links { display: flex; flex-direction: column; gap: 0.6rem; }
.site-footer__links a[aria-current="page"] { color: var(--orange); }
.site-footer__links a { text-decoration: none; }
.site-footer__links a:hover { text-decoration: underline; }
.site-footer__meta {
  margin-top: 1.5rem;
  font-family: var(--font-label);
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
  color: rgba(251, 250, 247, 0.7);
}
