/* =====================================================================
   PhiDE Iowa Beta — styles
   ===================================================================== */

:root {
  --black: #000000;
  --ink: #17111F;
  --purple: #5B2D90;
  --purple-deep: #2A1348;
  --purple-bright: #8A5CF5;
  --lilac: #CDB6EA;
  --lilac-soft: #E9E0F5;
  --bone: #F5F2F9;
  --white: #FFFFFF;
  --muted: #5E5670;
  --line: rgba(23, 17, 31, 0.12);
  --line-dark: rgba(255, 255, 255, 0.14);

  --font-display: "Outfit", "Avenir Next", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Instrument Sans", "Helvetica Neue", Arial, sans-serif;

  --max: 1240px;
  --gutter: clamp(20px, 5vw, 64px);
  --radius: 6px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.83, 0, 0.17, 1);
}

*, *::before, *::after { box-sizing: border-box; }
.about-grid > *, .rush-grid > *, .sftk-split > *, .sftk-teaser .wrap > *, .cta-band .wrap > *, .hero-meta > *, .footer-grid > * { min-width: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; cursor: pointer; }
h1, h2, h3, h4 { margin: 0; font-family: var(--font-display); font-weight: 800; line-height: 1; letter-spacing: -0.02em; }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

:focus-visible { outline: 3px solid var(--purple-bright); outline-offset: 3px; }
.dark :focus-visible, .hero :focus-visible, .nav :focus-visible, .purple :focus-visible, .footer :focus-visible, .schedule :focus-visible, .apply-card :focus-visible, .page-hero.has-photo :focus-visible { outline-color: var(--lilac); }

.skip {
  position: absolute; left: 16px; top: -60px; z-index: 1000;
  background: var(--purple); color: var(--white); padding: 10px 16px; border-radius: var(--radius);
}
.skip:focus { top: 16px; }

.wrap { width: min(100% - 2 * var(--gutter), var(--max)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Type scale ---------- */
.display-xl { font-size: clamp(2.3rem, 6.5vw, 5.6rem); }
.display-lg { font-size: clamp(1.9rem, 4.8vw, 4rem); }
.display-md { font-size: clamp(1.6rem, 3vw, 2.4rem); }
.display-sm { font-size: clamp(1.15rem, 1.6vw, 1.35rem); letter-spacing: -0.01em; }
.lede { font-size: clamp(1.1rem, 1.5vw, 1.3rem); line-height: 1.5; max-width: 34em; }
.muted { color: var(--muted); }
.dark .muted { color: var(--lilac); opacity: 0.85; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 48px; padding: 0 22px;
  border-radius: 999px; border: 1.5px solid transparent;
  font-weight: 600; font-size: 1rem; text-decoration: none; line-height: 1;
  transition: background-color .2s var(--ease-out), color .2s var(--ease-out), border-color .2s var(--ease-out), transform .25s var(--ease-out);
  cursor: pointer; white-space: nowrap; touch-action: manipulation;
}
.btn svg { width: 18px; height: 18px; flex: none; }
.btn-primary { background: var(--purple); color: var(--white); }
.btn-primary:hover { background: var(--purple-deep); }
.btn-light { background: var(--white); color: var(--purple-deep); }
.btn-light:hover { background: var(--lilac); }
.btn-ghost { border-color: currentColor; background: transparent; }
.btn-ghost:hover { background: rgba(91, 45, 144, 0.08); }
.dark .btn-ghost:hover, .hero .btn-ghost:hover { background: rgba(255, 255, 255, 0.1); }
.btn:active { transform: scale(0.97); }

.link-arrow { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; text-decoration: none; }
.link-arrow svg { width: 18px; height: 18px; transition: transform .25s var(--ease-out); }
.link-arrow:hover svg { transform: translateX(4px); }
.link-arrow span { text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 4px; transition: text-decoration-color .2s; }
.link-arrow:hover span { text-decoration-color: currentColor; }

/* ---------- Nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 14px var(--gutter);
  color: var(--white);
  transition: background-color .3s, box-shadow .3s;
}
.nav.is-scrolled { background: rgba(0, 0, 0, 0.86); box-shadow: 0 1px 0 var(--line-dark); }
.nav.on-light { color: var(--ink); }
.nav.on-light.is-scrolled { background: rgba(255, 255, 255, 0.94); box-shadow: 0 1px 0 var(--line); }

.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; font-family: var(--font-display); font-weight: 800; font-size: 1.05rem; letter-spacing: -0.01em; }
.brand img { width: 40px; height: 40px; border-radius: 50%; background: var(--white); }
.brand small { display: block; font-family: var(--font-body); font-weight: 500; font-size: 0.78rem; letter-spacing: 0.02em; opacity: 0.8; }

.nav-links { display: flex; align-items: center; gap: 4px; margin: 0; padding: 0; list-style: none; }
.nav-links a {
  display: inline-block; padding: 12px 14px; border-radius: 999px;
  text-decoration: none; font-weight: 500; font-size: 0.98rem;
  transition: background-color .2s;
}
.nav-links a:hover { background: rgba(255, 255, 255, 0.12); }
.on-light .nav-links a:hover { background: rgba(91, 45, 144, 0.08); }
.nav-links a[aria-current="page"] { font-weight: 700; text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 2px; text-decoration-color: var(--purple-bright); }
.nav-cta { display: flex; align-items: center; gap: 8px; }
.nav .btn { min-height: 44px; padding-inline: 18px; font-size: 0.95rem; }
.on-light .btn-light { background: var(--purple); color: var(--white); }
.on-light .btn-light:hover { background: var(--purple-deep); }

.nav-toggle {
  display: none; align-items: center; justify-content: center;
  width: 46px; height: 46px; border-radius: 50%; border: 1.5px solid currentColor; background: transparent; color: inherit;
}
.nav-toggle svg { width: 22px; height: 22px; }
.nav-toggle .icon-close { display: none; }
.nav.is-open .nav-toggle .icon-close { display: block; }
.nav.is-open .nav-toggle .icon-menu { display: none; }

@media (max-width: 1120px) {
  .nav-toggle { display: inline-flex; }
  .nav-cta .btn { display: none; }
  .nav-links {
    position: fixed; inset: 0; z-index: -1;
    flex-direction: column; justify-content: center; align-items: flex-start; gap: 6px;
    padding: 100px var(--gutter) 40px;
    background: var(--black); color: var(--white);
    opacity: 0; visibility: hidden; transform: translateY(-8px);
    transition: opacity .3s var(--ease-out), transform .3s var(--ease-out), visibility 0s .3s;
  }
  .nav.is-open .nav-links { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
  .nav-links a { font-family: var(--font-display); font-size: clamp(2rem, 9vw, 3rem); font-weight: 800; padding: 8px 0; }
  .nav-links li.mobile-only { display: block; margin-top: 24px; }
  .nav-links li.mobile-only a { font-family: var(--font-body); font-size: 1.1rem; }
  .nav.is-open { color: var(--white); background: transparent; }
  .nav.is-open .brand img { background: var(--white); }
}
@media (min-width: 1121px) { .nav-links li.mobile-only { display: none; } }

/* ---------- Hero (home) ---------- */
.hero {
  position: relative; overflow: hidden;
  min-height: 100svh; display: grid; align-content: center;
  background: var(--black); color: var(--white);
  padding: 110px var(--gutter) clamp(40px, 6vh, 72px);
}
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(55% 60% at 30% 45%, rgba(91, 45, 144, 0.38), transparent 70%),
    radial-gradient(40% 35% at 85% 20%, rgba(138, 92, 245, 0.22), transparent 70%);
}
.hero-inner { position: relative; width: min(100%, 1400px); margin-inline: auto; }
.hero-split { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: clamp(32px, 5vw, 80px); align-items: center; }
.hero-copy { min-width: 0; }
.hero-word-wrap { margin: 0 0 18px; line-height: 0; }
.js-anim .hero-word-wrap:not(.is-in) { clip-path: inset(100% 0 0 0); }
.hero-word {
  display: inline-block; vertical-align: top; white-space: nowrap;
  font-family: var(--font-display); font-weight: 800;
  font-size: clamp(4rem, 12vw, 16rem);   /* main.js refines this so the word fills its column */
  line-height: 0.9; letter-spacing: -0.03em;
  margin: 0 0 0 -0.02em;
  color: var(--white);
  user-select: none;
}
.hero-greek { font-family: Georgia, "Times New Roman", serif; font-size: 1.05rem; letter-spacing: 0.18em; color: var(--lilac); margin-bottom: 10px; }
.hero-line { font-size: clamp(1.15rem, 2vw, 1.55rem); line-height: 1.35; max-width: 22em; margin: 0 0 26px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-photo { margin: 0; border-radius: 18px; overflow: hidden; aspect-ratio: 4 / 3; background: var(--purple-deep); box-shadow: 0 40px 90px -30px rgba(138, 92, 245, 0.55); }
.hero-photo img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 860px) {
  .hero { align-content: end; padding-top: 100px; }
  .hero-split { grid-template-columns: minmax(0, 1fr); gap: 28px; }
}

/* ---------- Generic sections ---------- */
.section { padding: clamp(72px, 10vw, 140px) 0; }
.section-tight { padding: clamp(48px, 7vw, 96px) 0; }
.dark { background: var(--black); color: var(--white); }
.purple { background: var(--purple-deep); color: var(--white); }
.bone { background: var(--bone); }
.section-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 16px 40px; margin-bottom: clamp(32px, 5vw, 64px); }
.section-head p { max-width: 36em; }

/* headings that reveal letter-by-letter */
.split { display: inline-block; }
.split .ch { display: inline-block; white-space: pre; }
.split .w { display: inline-block; overflow: hidden; vertical-align: bottom; padding-bottom: 0.08em; margin-bottom: -0.08em; }

/* ---------- About + schedule (home) ---------- */
.about-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.about-copy h2 { margin-bottom: 28px; }
.about-copy p { max-width: 36em; }
.about-motto { margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--line); display: flex; gap: 20px; align-items: baseline; flex-wrap: wrap; }
.about-motto .latin { font-family: var(--font-display); font-weight: 800; font-size: 1.4rem; color: var(--purple); }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 40px; }
.stat b { display: block; font-family: var(--font-display); font-size: clamp(1.8rem, 3vw, 2.6rem); line-height: 1; color: var(--purple); }
.stat span { display: block; font-size: 0.92rem; color: var(--muted); margin-top: 6px; }
@media (max-width: 960px) { .about-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 520px) { .stats { grid-template-columns: 1fr 1fr; } }

/* schedule card */
.schedule {
  background: var(--black); color: var(--white); border-radius: 14px;
  padding: clamp(22px, 3vw, 36px);
  position: sticky; top: 92px;
}
.schedule-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.schedule-head h3 { font-size: 1.35rem; }
.schedule-head span { color: var(--lilac); font-size: 0.92rem; }
.schedule-list { list-style: none; margin: 0; padding: 0; }
.schedule-list li {
  display: grid; grid-template-columns: 86px 1fr; gap: 6px 16px;
  padding: 14px 0; border-top: 1px solid var(--line-dark);
}
.schedule-list li:first-child { border-top: 0; padding-top: 0; }
.schedule-list .d { font-family: var(--font-display); font-weight: 700; font-size: 1rem; color: var(--lilac); line-height: 1.3; }
.schedule-list .d small { display: block; font-family: var(--font-body); font-weight: 400; font-size: 0.78rem; color: rgba(255, 255, 255, 0.74); }
.schedule-list .t { font-weight: 600; line-height: 1.3; }
.schedule-list .m { grid-column: 2; font-size: 0.9rem; color: rgba(255, 255, 255, 0.7); }
.schedule-list li.is-bid .t { color: var(--white); }
.schedule-list li.is-bid .d { color: var(--purple-bright); }
.schedule-foot { margin-top: 22px; display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- Photo marquee ---------- */
.marquee { overflow: hidden; padding: clamp(40px, 5vw, 72px) 0; background: var(--bone); }
.marquee-track { display: flex; gap: 16px; width: max-content; will-change: transform; }
.marquee-track figure { margin: 0; flex: none; width: clamp(220px, 26vw, 360px); aspect-ratio: 4 / 3; overflow: hidden; border-radius: 10px; background: var(--lilac-soft); }
.marquee-track figure:nth-child(3n) { aspect-ratio: 3 / 4; width: clamp(180px, 20vw, 270px); }
.marquee-track img { width: 100%; height: 100%; object-fit: cover; }
.marquee:hover .marquee-track, .marquee:focus-within .marquee-track { animation-play-state: paused; }
.marquee-track.css-anim { animation: marquee 60s linear infinite; }
@keyframes marquee { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  .marquee-track.css-anim { animation: none; }
  .marquee { overflow-x: auto; }
}

/* ---------- Principles ---------- */
.principles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; border-top: 1px solid var(--line-dark); }
.principle { padding: 32px 28px 40px 0; border-bottom: 1px solid var(--line-dark); }
.principle + .principle { border-left: 1px solid var(--line-dark); padding-left: 28px; }
.principle h3 { font-size: clamp(1.5rem, 2.4vw, 2.1rem); margin-bottom: 14px; color: var(--lilac); }
.principle p { color: rgba(255, 255, 255, 0.75); font-size: 0.98rem; }
@media (max-width: 900px) {
  .principles { grid-template-columns: 1fr 1fr; }
  .principle:nth-child(3) { border-left: 0; padding-left: 0; }
}
@media (max-width: 520px) {
  .principles { grid-template-columns: 1fr; }
  .principle + .principle { border-left: 0; padding-left: 0; }
}

/* ---------- Stand for the Kids teaser (home) ---------- */
.sftk-teaser { position: relative; overflow: hidden; }
.sftk-teaser .wrap { position: relative; display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(32px, 5vw, 80px); align-items: center; }
.sftk-teaser figure { margin: 0; border-radius: 14px; overflow: hidden; aspect-ratio: 4 / 3; }
.sftk-teaser img { width: 100%; height: 100%; object-fit: cover; }
.big-number { font-family: var(--font-display); font-weight: 800; font-size: clamp(3.4rem, 8vw, 7rem); line-height: 0.95; letter-spacing: -0.04em; color: var(--white); margin: 8px 0 18px; }
.big-number small { display: block; font-family: var(--font-body); font-weight: 500; font-size: 1.05rem; letter-spacing: 0; color: var(--lilac); margin-top: 8px; }
@media (max-width: 860px) { .sftk-teaser .wrap { grid-template-columns: minmax(0, 1fr); } }

/* ---------- CTA band ---------- */
.cta-band { text-align: left; }
.cta-band .wrap { display: grid; grid-template-columns: 1fr auto; gap: 24px 48px; align-items: center; }
@media (max-width: 760px) { .cta-band .wrap { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Page hero (inner pages) ---------- */
.page-hero { position: relative; padding: clamp(140px, 20vh, 200px) 0 clamp(48px, 7vw, 96px); overflow: hidden; }
.page-hero h1 { max-width: 12ch; }
.page-hero .lede { margin-top: 24px; }
.page-hero.has-photo { min-height: 78svh; display: grid; align-content: end; color: var(--white); }
.page-hero.has-photo::before { content: ""; position: absolute; inset: 0; z-index: 0; background: url("../img/twister.jpg") center 35% / cover no-repeat; }
.page-hero.has-photo::after { content: ""; position: absolute; inset: 0; z-index: 0; background: linear-gradient(180deg, rgba(0,0,0,0.78) 0%, rgba(0,0,0,0.25) 32%, rgba(42,19,72,0.8) 62%, rgba(42,19,72,0.98) 100%); }
.page-hero.has-photo .wrap { position: relative; z-index: 1; }
.page-hero.has-photo h1 { max-width: 14ch; }

/* ---------- Rush page ---------- */
.rush-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.rush-side { position: sticky; top: 100px; }
.rush-side h2 { font-size: clamp(2rem, 3.6vw, 3.4rem); }
@media (max-width: 960px) { .rush-grid { grid-template-columns: minmax(0, 1fr); } .rush-side { position: static; } }

.req-list { list-style: none; margin: 0; padding: 0; counter-reset: req; }
.req-list li { display: grid; grid-template-columns: 40px 1fr; gap: 16px; padding: 22px 0; border-top: 1px solid var(--line); }
.req-list li:last-child { border-bottom: 1px solid var(--line); }
.req-list .check { width: 32px; height: 32px; border-radius: 50%; background: var(--purple); color: var(--white); display: grid; place-items: center; margin-top: 2px; }
.req-list .check svg { width: 16px; height: 16px; }
.req-list h3 { font-family: var(--font-body); font-weight: 700; font-size: 1.1rem; letter-spacing: 0; margin-bottom: 4px; }
.req-list p { color: var(--muted); font-size: 0.98rem; }

/* timeline (rush page) — content is a real sequence, so it's dated */
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 7px; top: 12px; bottom: 12px; width: 2px; background: var(--lilac); }
.timeline li { position: relative; padding: 0 0 36px 40px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before { content: ""; position: absolute; left: 0; top: 8px; width: 16px; height: 16px; border-radius: 50%; background: var(--white); border: 3px solid var(--purple); }
.timeline li.is-bid::before { background: var(--purple); }
.timeline .when { font-family: var(--font-display); font-weight: 700; color: var(--purple); font-size: 1rem; }
.timeline .when small { font-family: var(--font-body); font-weight: 500; color: var(--muted); margin-left: 10px; }
.timeline h3 { font-size: clamp(1.4rem, 2.4vw, 1.9rem); margin: 6px 0 8px; }
.timeline .where { font-weight: 600; }
.timeline .note { color: var(--muted); }

.apply-card { background: var(--purple-deep); color: var(--white); border-radius: 14px; padding: clamp(28px, 4vw, 48px); display: grid; grid-template-columns: 1fr auto; gap: 24px 40px; align-items: center; }
.apply-card h2 { font-size: clamp(1.8rem, 3.4vw, 2.8rem); margin-bottom: 10px; }
.apply-card p { color: var(--lilac); max-width: 34em; }
@media (max-width: 760px) { .apply-card { grid-template-columns: minmax(0, 1fr); } }

/* FAQ */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 24px;
  padding: 22px 0; font-weight: 600; font-size: 1.1rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary svg { width: 22px; height: 22px; flex: none; transition: transform .3s var(--ease-out); }
.faq details[open] summary svg { transform: rotate(45deg); }
.faq .answer { padding: 0 0 24px; color: var(--muted); max-width: 60ch; }

/* ---------- Stand for the Kids page ---------- */
.goal { min-width: 0; background: var(--white); color: var(--ink); border-radius: 14px; padding: clamp(24px, 3.5vw, 40px); box-shadow: 0 30px 60px -30px rgba(42, 19, 72, 0.5); }
.goal-nums { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.goal-nums b { font-family: var(--font-display); font-size: clamp(2.4rem, 5vw, 4rem); line-height: 1; color: var(--purple); font-variant-numeric: tabular-nums; }
.goal-nums span { color: var(--muted); }
.goal-bar { margin: 20px 0 12px; height: 14px; border-radius: 999px; background: var(--lilac-soft); overflow: hidden; }
.goal-bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--purple), var(--purple-bright)); border-radius: inherit; transition: width 1.4s var(--ease-out); }
.goal-foot { display: flex; justify-content: space-between; gap: 12px; font-size: 0.9rem; color: var(--muted); }

.sftk-split { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.fundraising-trackers { display: grid; gap: 24px; min-width: 0; }
.fundraising-trackers .btn, .page-hero [data-sftk-donate] { max-width: 100%; white-space: normal; text-align: center; }
.page-hero.has-photo .wrap { min-width: 0; }
.fundraising-trackers .goal-foot > :first-child { flex-shrink: 0; }
.tracker-status { font-size: 0.85rem; color: var(--muted); }
@media (max-width: 960px) { .sftk-split { grid-template-columns: minmax(0, 1fr); } }

.ways { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.way { padding-top: 22px; border-top: 2px solid var(--purple); }
.way h3 { font-size: 1.4rem; margin-bottom: 10px; }
.way p { color: var(--muted); }
@media (max-width: 760px) { .ways { grid-template-columns: 1fr; } }

.event-rows { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line-dark); }
.event-rows li { display: grid; grid-template-columns: 140px 1fr auto; gap: 8px 24px; padding: 20px 0; border-bottom: 1px solid var(--line-dark); align-items: baseline; }
.event-rows .d { font-family: var(--font-display); font-weight: 700; color: var(--lilac); }
.event-rows .t { font-weight: 600; font-size: 1.1rem; }
.event-rows .n { grid-column: 2; color: rgba(255,255,255,0.7); font-size: 0.95rem; }
.event-rows .w { color: var(--lilac); font-size: 0.95rem; }
@media (max-width: 640px) { .event-rows li { grid-template-columns: 1fr; } .event-rows .n, .event-rows .w { grid-column: 1; } }

.photo-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.photo-pair figure { margin: 0; border-radius: 12px; overflow: hidden; aspect-ratio: 4 / 3; }
.photo-pair img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 600px) { .photo-pair { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
.footer { background: var(--black); color: var(--white); padding: clamp(56px, 8vw, 96px) 0 32px; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 40px 28px; padding-bottom: 40px; border-bottom: 1px solid var(--line-dark); }
.footer .footer-h { font-family: var(--font-body); font-weight: 600; font-size: 0.95rem; color: var(--lilac); margin: 0 0 14px; letter-spacing: 0; line-height: 1.4; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer a { text-decoration: none; opacity: 0.9; }
.footer ul a { display: inline-block; padding: 3px 0; }
.footer a:hover { opacity: 1; text-decoration: underline; text-underline-offset: 4px; }
.footer-brand { display: flex; gap: 16px; align-items: flex-start; }
.footer-brand img { width: 56px; height: 56px; border-radius: 50%; background: var(--white); flex: none; }
.footer-brand b { display: block; font-family: var(--font-display); font-size: 1.2rem; }
.footer-brand p { color: rgba(255,255,255,0.7); font-size: 0.95rem; margin-top: 8px; max-width: 32em; }
.footer-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding-top: 24px; font-size: 0.85rem; color: rgba(255,255,255,0.6); }
@media (max-width: 960px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Motion setup: elements start visible; JS hides them only when animating ---------- */
.js-anim [data-reveal] { opacity: 0; }
@media (prefers-reduced-motion: reduce) { .js-anim [data-reveal] { opacity: 1; } }

/* ---------- A semester with PhiDE (home) ---------- */
.counts { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: clamp(32px, 5vw, 56px); }
.count { display: flex; align-items: baseline; gap: 10px; padding: 12px 18px 12px 14px; border: 1px solid var(--line); border-radius: 999px; }
.count b { font-family: var(--font-display); font-weight: 800; font-size: 1.6rem; line-height: 1; color: var(--purple); }
.count span { font-size: 0.95rem; color: var(--muted); }
.semester-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.sem-group { border-top: 2px solid var(--purple); padding-top: 18px; }
.sem-group h3 { font-size: 1.35rem; margin-bottom: 12px; }
.sem-group ul { margin: 0; padding-left: 1.1em; display: grid; gap: 6px; color: var(--muted); }
.sem-group li::marker { color: var(--lilac); }
.meetings { margin-top: clamp(40px, 6vw, 72px); }
.meetings-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 32px; margin-bottom: 16px; }
.event-rows.light { border-top-color: var(--line); }
.event-rows.light li { border-bottom-color: var(--line); }
.event-rows.light .d { color: var(--purple); }
.event-rows.light .w { color: var(--muted); }
.event-rows.light .n { color: var(--muted); }
@media (max-width: 800px) { .semester-grid { grid-template-columns: 1fr; gap: 24px; } }

/* ---------- Executive board page ---------- */
.exec-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 36px 24px; }
.exec-card figure { margin: 0 0 14px; aspect-ratio: 3 / 4; border-radius: 12px; overflow: hidden; background: var(--lilac-soft); }
.exec-card img { width: 100%; height: 100%; object-fit: cover; }
.exec-card h3 { font-family: var(--font-body); font-weight: 700; font-size: 1.1rem; letter-spacing: 0; line-height: 1.3; }
.exec-card .role { color: var(--purple); font-weight: 600; font-size: 0.95rem; margin-top: 2px; }
.exec-card .meta { color: var(--muted); font-size: 0.92rem; margin-top: 4px; }
.exec-card a { display: inline-block; margin-top: 8px; font-size: 0.9rem; color: var(--purple); text-underline-offset: 3px; overflow-wrap: anywhere; }
@media (max-width: 640px) { .exec-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 16px; } }

/* ---------- Photo + copy band ---------- */
.split-band .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 5vw, 80px); align-items: center; }
.split-band figure { margin: 0; border-radius: 14px; overflow: hidden; aspect-ratio: 4 / 3; }
.split-band img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 860px) { .split-band .wrap { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Nav icon link (Instagram) ---------- */
.nav-icon { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 50%; border: 1.5px solid currentColor; color: inherit; transition: background-color .2s; }
.nav-icon svg { width: 20px; height: 20px; }
.nav-icon:hover { background: rgba(255, 255, 255, 0.12); }
.on-light .nav-icon:hover { background: rgba(91, 45, 144, 0.08); }
@media (max-width: 1120px) { .nav-cta .nav-icon { display: none; } }

/* ---------- Photo strip caption ---------- */
.marquee-cap { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding-bottom: 20px; }
.marquee-cap .link-arrow { color: var(--purple); }

/* ---------- Featured fundraiser (Stand for the Kids) ---------- */
.featured { border: 2px solid var(--purple); border-radius: 16px; padding: clamp(24px, 4vw, 44px); display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr); gap: clamp(24px, 4vw, 56px); align-items: center; }
.featured .kicker { color: var(--purple); font-weight: 600; margin-bottom: 8px; }
.featured h2 { font-size: clamp(1.8rem, 3.6vw, 3rem); margin-bottom: 14px; }
.featured p { color: var(--muted); max-width: 40em; }
.featured-facts { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 24px; margin-bottom: 24px; }
.featured-facts b { display: block; font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; line-height: 1.2; }
.featured-facts span { color: var(--muted); font-size: 0.9rem; }
@media (max-width: 860px) { .featured { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Calendar page ---------- */
.calendar-empty { border: 1px dashed var(--line); border-radius: 12px; padding: 32px; color: var(--muted); max-width: 40em; }

/* ---------- Helpful links page ---------- */
.link-groups { display: grid; gap: clamp(40px, 6vw, 72px); }
.link-group h2 { margin-bottom: 20px; }
.link-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.link-list li { display: grid; }
.link-card { display: grid; grid-template-rows: auto 1fr auto; gap: 10px; padding: 22px 24px; border: 1px solid var(--line); border-radius: 14px; text-decoration: none; color: inherit; transition: border-color .2s, transform .25s var(--ease-out), box-shadow .25s; }
.link-card:hover { border-color: var(--purple); transform: translateY(-2px); box-shadow: 0 24px 40px -30px rgba(42, 19, 72, 0.5); }
.link-card .link-title { font-weight: 700; font-size: 1.1rem; line-height: 1.3; display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.link-card .link-title svg { width: 18px; height: 18px; flex: none; color: var(--purple); margin-top: 3px; }
.link-card .link-text { color: var(--muted); font-size: 0.95rem; }
.link-card .link-host { color: var(--purple); font-size: 0.85rem; font-weight: 600; }

/* ---------- Spacing utilities (keeps the CSP free of inline styles) ---------- */
.mt-10 { margin-top: 10px; }
.mt-14 { margin-top: 14px; }
.mt-20 { margin-top: 20px; }
.mt-24 { margin-top: 24px; }
.mt-28 { margin-top: 28px; }
.mt-36 { margin-top: 36px; }

/* ---------- Pause control for the photo strip (WCAG 2.2.2) ---------- */
.btn-pause { min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1.5px solid var(--purple); background: transparent; color: var(--purple); font-weight: 600; font-size: 0.95rem; transition: background-color .2s; }
.btn-pause:hover { background: rgba(91, 45, 144, 0.08); }
.marquee-track.is-paused { animation-play-state: paused; }
@media (prefers-reduced-motion: reduce) { .btn-pause { display: none; } }

/* ---------- Notices ---------- */
.apply-card .fine { font-size: 0.9rem; color: var(--lilac); max-width: 44em; }
.apply-card .fine a { color: inherit; }

/* ---------- Legal pages ---------- */
.legal-toc ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.legal-toc a { display: block; padding: 8px 12px; border-radius: 8px; text-decoration: none; color: var(--muted); font-size: 0.95rem; }
.legal-toc a:hover { background: var(--bone); color: var(--ink); }
.legal-body { max-width: 68ch; }
.legal-body h2 { font-size: clamp(1.4rem, 2.4vw, 1.9rem); margin: 44px 0 12px; scroll-margin-top: 100px; }
.legal-body h2:first-child { margin-top: 0; }
.legal-body p, .legal-body li { line-height: 1.65; }
.legal-body ul { padding-left: 1.2em; margin: 0 0 1em; display: grid; gap: 8px; }
.legal-body a { color: var(--purple); }
