/* =================================================================
   Science in Solidarity — custom styles
   Built on top of vendored Skeleton 2.0.4 (normalize.css + skeleton.css)
   ================================================================= */

/* ---------- Design tokens ---------- */
:root {
  /* Brand colors */
  --color-blue: #1273c4;
  --color-blue-dark: #0e5a98;
  --color-green: #478b23;
  --color-green-deep: #3c7820;
  --color-maroon: #701b33;
  --color-orange: #fd7505;
  --color-yellow: #fff56e;
  --color-pink: #ffd2e0;
  --color-light-blue: #bfe3f7;
  --color-cream: #fffbf3;
  --color-ink: #1c1c1c;

  /* Semantic roles */
  --color-bg: var(--color-cream);
  --color-text: var(--color-ink);
  --color-link: var(--color-blue);

  /* Type */
  --font-display: 'Archivo Black', 'Arial Black', sans-serif;
  --font-body: 'Work Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Spacing scale */
  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2.5rem;
  --space-5: 4rem;
  --space-6: 6rem;

  --radius-pill: 999px;
  --radius-card: 1.5rem;

  --max-width: 1140px;
}

/* ---------- Base ---------- */
html {
  /* Bumped from the browser default 16px to 18px — every rem-based
     size, spacing value, and line length in this file scales from here. */
  font-size: 112.5%;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background-color: var(--color-bg);
  font-size: 1.125rem;
  line-height: 1.65;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  text-transform: none;
  letter-spacing: normal;
  line-height: 1.15;
  color: var(--color-ink);
}

h1 { font-size: 3rem; }
h2 { font-size: 2.25rem; }
h3 { font-size: 1.5rem; }

@media (min-width: 750px) {
  h1 { font-size: 4.25rem; }
  h2 { font-size: 2.75rem; }
}

p { margin-bottom: 1.4rem; }

a {
  color: var(--color-link);
  text-decoration-thickness: 0.08em;
}

a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid transparent; /* forced-colors / high-contrast mode fallback */
  box-shadow: 0 0 0 3px var(--color-cream), 0 0 0 6px var(--color-ink);
  border-radius: 2px;
}
.button:focus-visible {
  border-radius: var(--radius-pill);
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding-left: var(--space-3);
  padding-right: var(--space-3);
}

img { max-width: 100%; height: auto; }

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

/* ---------- Utilities ---------- */
.u-visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 1000;
  background: var(--color-yellow);
  color: var(--color-ink);
  padding: var(--space-1) var(--space-2);
  font-weight: 700;
}
.skip-link:focus {
  left: var(--space-2);
  top: var(--space-2);
}

.eyebrow {
  font-family: var(--font-body);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.95rem;
  color: var(--color-blue);
  margin-bottom: var(--space-2);
}
.eyebrow--on-blue { color: #fff; }
.events .eyebrow { color: var(--color-blue-dark); }

/* ---------- Buttons ---------- */
.button,
button.button,
input[type="submit"].button {
  display: inline-block;
  height: auto;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1.05rem;
  text-transform: none;
  letter-spacing: normal;
  text-decoration: none;
  border-radius: var(--radius-pill);
  padding: 0.85rem 1.75rem;
  border: 2px solid transparent;
  line-height: 1.2;
  cursor: pointer;
  box-sizing: border-box;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.button:hover,
.button:focus,
button.button:hover,
button.button:focus {
  transform: translateY(-1px);
  border-color: currentColor;
  outline: 0;
}

.button--primary {
  background-color: var(--color-yellow);
  color: var(--color-ink);
}
.button--primary:hover { background-color: #fff89a; color: var(--color-ink); }

.button--outline {
  background-color: transparent;
  border-color: currentColor;
  color: inherit;
}
.button--outline:hover { background-color: rgba(0,0,0,0.06); }

.button--outline-on-blue {
  background-color: transparent;
  border-color: var(--color-light-blue);
  color: #fff;
}
.button--outline-on-blue:hover { background-color: rgba(255,255,255,0.12); }

.button--dark {
  background-color: var(--color-ink);
  color: var(--color-cream);
}
.button--dark:hover { background-color: #000; color: var(--color-cream); }

.button--small {
  padding: 0.6rem 1.25rem;
  font-size: 0.95rem;
}

.button:disabled,
button.button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}
.button:disabled:hover { transform: none; }
.lane-card__soon { font-weight: 400; font-size: 0.85em; }

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
}

/* ---------- Header / Nav ---------- */
.site-header {
  background-color: var(--color-blue);
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: var(--space-2);
  padding-bottom: var(--space-2);
}

.site-header__logo img {
  display: block;
  width: 180px;
  height: auto;
}

.primary-nav ul {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  list-style: none;
  margin: 0;
}

.primary-nav a:not(.button) {
  color: #fff;
  text-decoration: none;
  font-weight: 600;
}
.primary-nav a:not(.button):hover { text-decoration: underline; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  width: 44px;
  height: 44px;
  padding: 0;
  cursor: pointer;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
}
.nav-toggle__bar {
  display: block;
  width: 24px;
  height: 3px;
  background-color: #fff;
  border-radius: 2px;
}

@media (max-width: 749px) {
  .nav-toggle { display: flex; }
  .primary-nav {
    display: none;
    width: 100%;
    order: 3;
  }
  .primary-nav.is-open { display: block; }
  .primary-nav ul {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-2);
    padding: var(--space-3) 0 var(--space-2);
  }
  .site-header__inner { flex-wrap: wrap; }
}

/* ---------- Hero ---------- */
.hero {
  background-color: var(--color-blue);
  color: #fff;
  padding-top: var(--space-6);
  padding-bottom: var(--space-6);
}
.hero__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
  align-items: center;
}
@media (min-width: 750px) {
  .hero__grid {
    grid-template-columns: 1.05fr 0.95fr;
    gap: var(--space-5);
  }
}
.hero h1 { color: #fff; max-width: 18ch; }
.hero__subhead {
  max-width: 42ch;
  font-size: 1.25rem;
  color: #fff;
}
.hero__microcopy {
  font-size: 1.05rem;
  color: #fff;
  margin-bottom: 0;
}
.hero__visual {
  aspect-ratio: 3 / 2;
}
@media (min-width: 750px) {
  .hero__visual { aspect-ratio: 4 / 3; }
}

/* ---------- Duotone image treatment ----------
   Self-contained CSS technique: the photo is desaturated, then a two-color
   brand gradient is laid over it with mix-blend-mode so it reads as a single
   tinted image rather than a literal photo. If the image fails to load
   (see onerror in markup), the gradient blends with the solid background
   color instead, so the panel still looks like a deliberate color block
   rather than a broken image. */
.duotone {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-card);
  background-color: var(--color-blue-dark);
}
.duotone img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: grayscale(1) contrast(1.15) brightness(0.95);
}
.duotone::after {
  content: "";
  position: absolute;
  inset: 0;
  mix-blend-mode: color;
}
.duotone--blue {
  background-color: var(--color-blue-dark);
}
.duotone--blue::after {
  background: linear-gradient(135deg, var(--color-blue-dark), var(--color-light-blue));
}
.duotone--orange {
  background-color: var(--color-ink);
}
.duotone--orange::after {
  background: linear-gradient(135deg, var(--color-ink), var(--color-orange));
}

/* ---------- Start Here / lane cards ---------- */
.start-here {
  padding-top: var(--space-6);
  padding-bottom: var(--space-6);
}
.start-here h2 { max-width: 20ch; margin-bottom: var(--space-4); }

.lane-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-3);
}
@media (min-width: 750px) {
  .lane-grid { grid-template-columns: repeat(3, 1fr); }
}

.lane-card {
  border-radius: var(--radius-card);
  padding: var(--space-4);
  color: #fff;
  display: flex;
  flex-direction: column;
}
.lane-card h3 { color: inherit; margin-top: var(--space-2); margin-bottom: var(--space-1); }
.lane-card p { color: inherit; }
.lane-card .button { margin-top: auto; align-self: flex-start; }

.lane-card__icon svg { width: 40px; height: 40px; color: inherit; }

.lane-card--green { background-color: var(--color-green-deep); }
.lane-card--maroon { background-color: var(--color-maroon); }
.lane-card--pink { background-color: var(--color-pink); color: var(--color-ink); }
.lane-card--pink .button--outline { border-color: var(--color-ink); }

/* ---------- What we're building ---------- */
.building {
  padding-top: var(--space-6);
  padding-bottom: var(--space-6);
  background-color: #fff;
}
.building__intro h2 { margin-bottom: var(--space-3); }
.building__heading-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-2);
}
.building__heading-row h2 { margin-bottom: 0; }
.building__badge {
  flex: 0 0 auto;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  aspect-ratio: 1 / 1;
}
@media (min-width: 750px) {
  .building__badge { width: 84px; height: 84px; }
}

.shift-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 2px solid var(--color-ink);
}
.shift-list__item {
  display: flex;
  align-items: baseline;
  gap: var(--space-2);
  padding: var(--space-3) 0;
  border-bottom: 2px solid var(--color-ink);
  flex-wrap: wrap;
}
.shift-list__from {
  font-size: 1.1rem;
  color: #595959;
  text-decoration: line-through;
  text-decoration-color: var(--color-orange);
  text-decoration-thickness: 2px;
}
.shift-list__arrow {
  color: var(--color-orange);
  font-weight: 700;
  font-size: 1.2rem;
}
.shift-list__to {
  font-family: var(--font-display);
  font-size: 1.4rem;
}

/* ---------- Events ---------- */
.events {
  padding-top: var(--space-6);
  padding-bottom: var(--space-6);
  background-color: var(--color-light-blue);
}
.events__intro { max-width: 50ch; }
.events__placeholder {
  background-color: #fff;
  border: 2px dashed var(--color-blue);
  border-radius: var(--radius-card);
  padding: var(--space-5);
  text-align: center;
  margin-bottom: var(--space-4);
}
.events__placeholder-label {
  margin: 0;
  font-weight: 700;
  color: var(--color-blue-dark);
}

/* ---------- Donate ---------- */
.donate {
  background-color: var(--color-orange);
  color: var(--color-ink);
  padding-top: var(--space-5);
  padding-bottom: var(--space-5);
  text-align: center;
}
.donate h2 {
  color: var(--color-ink);
  max-width: 32ch;
  margin: 0 auto var(--space-3);
}

/* ---------- Final CTA ---------- */
.final-cta {
  background-color: var(--color-blue);
  color: #fff;
  padding-top: var(--space-6);
  padding-bottom: var(--space-6);
  text-align: center;
}
.final-cta h2 { color: #fff; }
.final-cta p {
  max-width: 46ch;
  margin: 0 auto var(--space-3);
  color: #fff;
  font-size: 1.15rem;
}
.final-cta .button-row { justify-content: center; }

/* ---------- Footer ---------- */
.site-footer {
  background-color: var(--color-ink);
  color: var(--color-cream);
  padding-top: var(--space-5);
  padding-bottom: var(--space-3);
}
.site-footer h2 {
  color: var(--color-cream);
  font-size: 1.05rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: var(--space-2);
}
.site-footer a { color: var(--color-cream); }
.site-footer__brand img { width: 160px; margin-bottom: var(--space-2); }
.site-footer__links ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-footer__links li { margin-bottom: 0.5rem; }

.newsletter-form__row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.newsletter-form input[type="email"] {
  flex: 1 1 auto;
  min-width: 0;
  height: auto;
  padding: 0.7rem 1rem;
  border-radius: var(--radius-pill);
  border: 2px solid var(--color-cream);
  background-color: transparent;
  color: var(--color-cream);
}
.newsletter-form input[type="email"]::placeholder { color: rgba(255,251,243,0.6); }
.newsletter-form__credit {
  font-size: 0.9rem;
  margin-top: var(--space-2);
  margin-bottom: 0;
}
.newsletter-form__credit a { color: rgba(255,251,243,0.8); }

.site-footer__bottom {
  border-top: 1px solid rgba(255,251,243,0.2);
  margin-top: var(--space-4);
  padding-top: var(--space-2);
  font-size: 0.95rem;
}
.site-footer__bottom p { margin-bottom: 0; }
