/* ============ TOKENS ============ */
:root {
  /* Light palette — warm ivory base, maroon ink, gold accents */
  --cream:        #FAF4E6;   /* page background */
  --cream-soft:   #F2E8CE;   /* alternating sections */
  --champagne:    #E8D8A8;   /* accent fill */
  --rose-blush:   #F1D7CE;   /* warm hint */
  --gold:         #B8861A;   /* primary accent (richer for contrast on cream) */
  --gold-soft:    #D4A636;
  --gold-pale:    #E8C26A;
  --maroon:       #7A1F2B;   /* ink */
  --maroon-deep:  #4A1018;   /* headings / strong ink */
  --maroon-soft:  #9B3A45;
  --laurel:       #4A6B3A;
  --ink-body:     #3D1820;   /* body text */
  --serif: "Cormorant Garamond", "Times New Roman", serif;
  --sans:  "Inter", system-ui, -apple-system, sans-serif;

  /* Dynamic viewport height (handles iOS URL bar correctly) */
  --vh: 100dvh;
}

@supports not (height: 100dvh) {
  :root { --vh: 100vh; }
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--sans);
  background: var(--cream);
  color: var(--ink-body);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }

/* ============================================================
   MOBILE FIRST  (default styles target ~360–480 phones)
   ============================================================ */

/* ---------- HERO ---------- */
.hero {
  position: relative;
  min-height: var(--vh);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 5rem 1.25rem 4rem;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 25%, rgba(232,194,106,0.5), transparent 55%),
    radial-gradient(ellipse at 70% 80%, rgba(241,215,206,0.55), transparent 60%),
    linear-gradient(180deg, #FAF4E6 0%, #F2E8CE 60%, #EFD7B5 100%);
}
.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(0deg, rgba(122,31,43,0.025) 0, rgba(122,31,43,0.025) 1px, transparent 1px, transparent 3px);
  mix-blend-mode: multiply;
  opacity: 0.5;
}
.hero-vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, transparent 50%, rgba(232,194,106,0.35) 100%);
  pointer-events: none;
}

/* ---------- SCHOOL SHOWCASE ---------- */
.school {
  position: relative;
  height: var(--vh);
  min-height: 480px;
  overflow: hidden;
  background: var(--cream-soft);
}
.school-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.04);
  transition: opacity 1.6s ease, transform 6s ease-out;
}
.school.in-view .school-photo {
  opacity: 1;
  transform: scale(1);
}
.school-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(250,244,230,0) 65%, rgba(74,16,24,0.45) 100%);
}
.school-caption {
  position: absolute;
  left: 1.25rem;
  right: 1.25rem;
  bottom: 1.5rem;
  text-align: center;
  z-index: 1;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 1.2s 0.5s, transform 1.2s 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.school.in-view .school-caption {
  opacity: 1;
  transform: translateY(0);
}
.school-eyebrow {
  font-family: var(--sans);
  font-size: 0.55rem;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--gold-pale);
  margin-bottom: 0.5rem;
  text-shadow: 0 2px 12px rgba(74,16,24,0.5);
}
.school-name {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--cream);
  letter-spacing: 0.05em;
  text-shadow: 0 2px 18px rgba(74,16,24,0.6);
}

.hero-content {
  position: relative;
  text-align: center;
  width: 100%;
  max-width: 1100px;
}

.hero-logo {
  width: 78px;
  height: auto;
  border-radius: 50%;
  margin: 0 auto 1.25rem;
  filter: drop-shadow(0 6px 20px rgba(122,31,43,0.18)) drop-shadow(0 0 28px rgba(184,134,26,0.35));
  opacity: 0;
  animation: fadeUp 1.4s 0.1s forwards;
}

.hero-eyebrow {
  font-family: var(--sans);
  font-size: 0.62rem;
  letter-spacing: 0.32em;
  font-weight: 600;
  color: var(--maroon);
  text-transform: uppercase;
  margin-bottom: 1.25rem;
  opacity: 0;
  animation: fadeUp 1.2s 0.2s forwards;
  padding: 0 0.5rem;
}

.hero-title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 2.6rem;
  line-height: 1.02;
  color: var(--maroon-deep);
  margin-bottom: 1rem;
}
.hero-title .line {
  display: block;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp 1.4s forwards;
}
.hero-title .line:nth-child(1) { animation-delay: 0.4s; }
.hero-title .line:nth-child(2) { animation-delay: 0.6s; font-style: italic; color: var(--gold); font-weight: 400; }
.hero-title .line-name {
  font-size: 0.42em;
  letter-spacing: 0.06em;
  margin-top: 0.35em;
  font-weight: 500;
}

.hero-rule {
  width: 60px;
  height: 1px;
  background: var(--gold);
  margin: 1rem auto;
  opacity: 0;
  animation: widen 1.2s 1s forwards;
}
@keyframes widen {
  from { opacity: 0; width: 0; }
  to   { opacity: 1; width: 60px; }
}

.hero-event {
  font-family: var(--serif);
  font-style: italic;
  font-size: 0.95rem;
  color: var(--maroon);
  margin-bottom: 1.75rem;
  opacity: 0;
  animation: fadeUp 1.2s 1.2s forwards;
  padding: 0 0.5rem;
}

/* FlipDown — native sizing, centered.
   Override default 580px width so it fits the viewport on phone
   without transforms. Larger physical card sizes than the previous
   transform-scaled version, fully readable. */
.flipdown-slot {
  text-align: center;
  margin: 0 auto 1.5rem;
  opacity: 0;
  animation: fadeUp 1.4s 1.5s forwards;
}
.flipdown {
  display: block !important;
  margin: 0 auto !important;
  width: max-content !important;
  max-width: none !important;
  height: auto !important;
  transform: none !important;
}
.flipdown::after {
  content: "";
  display: table;
  clear: both;
}
.flipdown .rotor-group { float: left !important; }
.flipdown .rotor-group-heading::before {
  font-family: var(--sans) !important;
  font-weight: 600 !important;
  letter-spacing: 0.18em !important;
  color: var(--maroon) !important;
}

/* Mobile-first physical rotor sizes — natural total ≈ 290px. */
.flipdown .rotor,
.flipdown .rotor-leaf-front,
.flipdown .rotor-leaf-rear,
.flipdown .rotor-top,
.flipdown .rotor-bottom {
  width: 34px !important;
  font-size: 1.75rem !important;
}
.flipdown .rotor,
.flipdown .rotor-leaf-front,
.flipdown .rotor-leaf-rear {
  height: 54px !important;
  line-height: 54px !important;
}
.flipdown .rotor-top,
.flipdown .rotor-bottom {
  height: 27px !important;
  line-height: 54px !important;
}
.flipdown .rotor-group { padding-right: 6px !important; }
.flipdown .rotor-group:last-child { padding-right: 0 !important; }
.flipdown .rotor { margin: 0 1px !important; }
.flipdown .rotor-group-heading {
  height: 22px !important;
  line-height: 22px !important;
}
.flipdown .rotor-group-heading::before { font-size: 0.55rem !important; }

.hero-date {
  font-family: var(--serif);
  font-size: 0.95rem;
  color: var(--maroon-deep);
  letter-spacing: 0.12em;
  opacity: 0;
  animation: fadeUp 1.2s 1.8s forwards;
}

.scroll-hint {
  position: absolute;
  bottom: 1.25rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  opacity: 0;
  animation: fadeIn 1s 2.5s forwards;
}
.scroll-hint span {
  font-size: 0.55rem;
  letter-spacing: 0.4em;
  color: var(--maroon);
  text-transform: uppercase;
}
.scroll-line {
  width: 1px;
  height: 30px;
  background: linear-gradient(180deg, var(--maroon), transparent);
  animation: scrollPulse 2s infinite;
}

@keyframes scrollPulse {
  0%, 100% { transform: scaleY(1); opacity: 1; }
  50%      { transform: scaleY(0.6); opacity: 0.4; }
}
@keyframes fadeUp { to { opacity: 1; transform: translateY(0); } }
@keyframes fadeIn { to { opacity: 1; } }

/* ---------- BRIDGE ---------- */
.bridge {
  min-height: 50svh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, #EFD7B5 0%, #FAF4E6 50%, #F2E8CE 100%);
  padding: 4rem 1.5rem;
}
.bridge-text {
  font-family: var(--serif);
  font-size: 1.65rem;
  text-align: center;
  font-weight: 400;
  color: var(--maroon-deep);
  line-height: 1.5;
}
.bridge-text span {
  display: block;
  opacity: 0.25;
  transition: opacity 0.6s;
}
.bridge-text span:nth-child(2) { font-style: italic; color: var(--gold); }
.bridge.in-view span { opacity: 1; }
.bridge.in-view span:nth-child(2) { transition-delay: 0.3s; }
.bridge.in-view span:nth-child(3) { transition-delay: 0.6s; }

/* ---------- BATCHES (default = mobile, no sticky) ---------- */
.batches { background: linear-gradient(180deg, #F2E8CE 0%, #FAF4E6 100%); }

.batch {
  position: relative;
  min-height: var(--vh);
}

.batch-sticky {
  position: relative;
  height: auto;
  min-height: var(--vh);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 5rem 1.5rem 4rem;
  gap: 2rem;
  overflow: hidden;
}

.batch-num {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  font-family: var(--serif);
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  color: var(--maroon);
  opacity: 0.55;
}

.batch-gem {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  width: min(70vw, 280px);
  height: min(70vw, 280px);
}

.batch-gem svg,
.batch-gem .batch-photo {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 14px 40px rgba(122,31,43,0.18));
  opacity: 0;
  transform: scale(0.85) rotate(-6deg);
  transition: opacity 1s, transform 1.2s cubic-bezier(0.2, 0.8, 0.2, 1);
  object-fit: contain;
}
.batch-gem .batch-photo {
  filter: drop-shadow(0 14px 40px rgba(184,134,26,0.4)) drop-shadow(0 0 30px rgba(184,134,26,0.25));
}
.batch.in-view .batch-gem svg,
.batch.in-view .batch-gem .batch-photo {
  opacity: 1;
  transform: scale(1) rotate(0deg);
  animation: float 6s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50%      { transform: translateY(-10px) rotate(2deg); }
}

.batch-gem::before {
  content: "";
  position: absolute;
  width: 80%;
  height: 80%;
  border-radius: 50%;
  background: radial-gradient(circle, var(--glow, rgba(232,194,106,0.5)) 0%, transparent 70%);
  filter: blur(50px);
  opacity: 0;
  transition: opacity 1.5s;
  z-index: -1;
}
.batch.in-view .batch-gem::before { opacity: 1; }

.batch-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 1s 0.3s, transform 1s 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.batch.in-view .batch-info {
  opacity: 1;
  transform: translateY(0);
}

.batch-year {
  font-family: var(--serif);
  font-size: 4.5rem;
  font-weight: 500;
  line-height: 0.9;
  color: var(--maroon-deep);
  letter-spacing: -0.02em;
}
.batch-divider {
  width: 50px;
  height: 1px;
  background: var(--gold);
  margin: 0.4rem auto;
}
.batch-gem-name {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.5rem;
  color: var(--gold);
}
.batch-anniversary {
  font-family: var(--sans);
  font-size: 0.65rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--maroon);
  opacity: 0.75;
  font-weight: 500;
}

/* ---------- POLISHED BATCH (mobile) ---------- */
.batch.polished .batch-sticky {
  display: block;
  padding: 0;
  height: var(--vh);
  min-height: var(--vh);
  overflow: hidden;
}

.batch-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: brightness(0.95) contrast(1.02) saturate(1.05);
  opacity: 0;
  transform: scale(1.05);
  transition: opacity 1.6s, transform 5s ease-out;
  z-index: 0;
}
.batch-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(250,244,230,0.55) 0%, rgba(250,244,230,0.05) 22%, rgba(74,16,24,0.15) 55%, rgba(74,16,24,0.92) 100%);
}
.batch.polished.in-view .batch-bg {
  opacity: 1;
  transform: scale(1);
}

.batch.polished .batch-num {
  position: absolute;
  top: 1.25rem;
  left: 1.25rem;
  right: auto;
  z-index: 2;
  color: var(--cream);
  opacity: 0.95;
  text-shadow: 0 2px 12px rgba(74,16,24,0.6);
}

.batch.polished .batch-gem {
  position: absolute;
  top: 18%;
  left: 50%;
  transform: translateX(-50%);
  width: min(58vw, 240px);
  height: min(58vw, 240px);
  z-index: 2;
}
.batch.polished .batch-gem .batch-photo {
  filter: drop-shadow(0 0 50px rgba(232,194,106,0.7)) drop-shadow(0 0 22px rgba(184,134,26,0.5));
}
.batch.polished .batch-gem::before { display: none; }

.batch.polished .batch-info {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 2.25rem;
  z-index: 2;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  padding: 0 1.25rem;
}
.batch.polished .batch-gem-name {
  font-family: var(--serif);
  font-style: normal;
  font-weight: 500;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  font-size: 0.78rem;
  color: var(--gold-pale);
  margin-bottom: 0.2rem;
  text-shadow: 0 2px 14px rgba(74,16,24,0.55);
}
.batch.polished .batch-divider {
  width: 40px;
  margin: 0 auto 0.5rem;
  background: var(--gold-pale);
  opacity: 0.85;
}
.batch.polished .batch-year {
  font-family: var(--serif);
  font-size: 5.25rem;
  font-weight: 500;
  line-height: 0.9;
  color: var(--cream);
  letter-spacing: -0.03em;
  text-shadow: 0 4px 24px rgba(74,16,24,0.7);
}
.batch.polished .batch-anniversary {
  font-family: var(--serif);
  font-style: italic;
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: none;
  color: var(--cream);
  opacity: 0.95;
  text-shadow: 0 2px 14px rgba(74,16,24,0.55);
}

/* ---------- BATCH GALLERY (polaroid wall) ---------- */
.batch-gallery {
  background: linear-gradient(180deg, #FAF4E6 0%, #F2E8CE 100%);
  padding: 5rem 1.25rem 5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.bg-eyebrow {
  font-family: var(--sans);
  font-size: 0.6rem;
  letter-spacing: 0.4em;
  font-weight: 600;
  color: var(--gold);
  text-transform: uppercase;
  margin-bottom: 0.8rem;
}
.bg-title {
  font-family: var(--serif);
  font-size: 2rem;
  font-weight: 500;
  color: var(--maroon-deep);
  line-height: 1.15;
  margin-bottom: 2.5rem;
}
.bg-title em { font-style: italic; color: var(--gold); font-weight: 400; }

.bg-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  justify-items: center;
  max-width: 1100px;
  margin: 0 auto;
}

.polaroid {
  background: #FFFCF2;
  padding: 0.8rem 0.8rem 2.5rem;
  box-shadow:
    0 2px 4px rgba(122,31,43,0.08),
    0 14px 36px rgba(122,31,43,0.18);
  transform: rotate(var(--rot, 0deg)) translateY(20px);
  opacity: 0;
  transition: transform 0.9s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.9s, box-shadow 0.4s;
  width: 100%;
  max-width: 320px;
  position: relative;
}
.polaroid img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  display: block;
}
.polaroid figcaption {
  font-family: var(--serif);
  font-style: italic;
  font-size: 0.95rem;
  color: var(--maroon-deep);
  margin-top: 0.7rem;
  letter-spacing: 0.05em;
}
.batch-gallery.in-view .polaroid {
  opacity: 1;
  transform: rotate(var(--rot, 0deg)) translateY(0);
}
.batch-gallery.in-view .polaroid:nth-child(1) { transition-delay: 0.0s; }
.batch-gallery.in-view .polaroid:nth-child(2) { transition-delay: 0.12s; }
.batch-gallery.in-view .polaroid:nth-child(3) { transition-delay: 0.24s; }
.batch-gallery.in-view .polaroid:nth-child(4) { transition-delay: 0.36s; }

.polaroid:hover {
  box-shadow:
    0 4px 8px rgba(122,31,43,0.12),
    0 22px 50px rgba(122,31,43,0.22);
}

/* ---------- ALL ALUMNI ---------- */
.alumni-all {
  background: linear-gradient(180deg, #FAF4E6 0%, #F2E8CE 50%, #EFD7B5 100%);
  padding: 5rem 1.25rem 6rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.alumni-all::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(232,194,106,0.25), transparent 60%);
  pointer-events: none;
}
.alumni-eyebrow {
  font-family: var(--sans);
  font-size: 0.6rem;
  letter-spacing: 0.4em;
  font-weight: 600;
  color: var(--maroon);
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.alumni-title {
  font-family: var(--serif);
  font-size: 2rem;
  font-weight: 500;
  color: var(--maroon-deep);
  line-height: 1.15;
  margin-bottom: 0.6rem;
}
.alumni-title em { font-style: italic; color: var(--gold); font-weight: 400; }

.alumni-sub {
  font-family: var(--serif);
  font-style: italic;
  color: var(--maroon);
  font-size: 0.95rem;
  letter-spacing: 0.12em;
  margin-bottom: 2.5rem;
  opacity: 0.85;
}

.year-strip {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.4rem 0.6rem;
  max-width: 1100px;
  margin: 0 auto 2rem;
  padding: 0 0.5rem;
  position: relative;
  z-index: 1;
}
.year-tag {
  font-family: var(--serif);
  font-size: 0.85rem;
  color: var(--maroon);
  opacity: 0.4;
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
  transition: opacity 0.4s, transform 0.4s, color 0.4s;
}
.year-tag.celebrant {
  color: var(--gold);
  opacity: 1;
  font-size: 1.25rem;
  font-weight: 600;
  text-shadow: 0 2px 12px rgba(184,134,26,0.4);
  position: relative;
}
.year-tag.celebrant::after {
  content: "★";
  position: absolute;
  top: -0.55em;
  right: -0.7em;
  font-size: 0.45em;
  color: var(--gold);
}
.alumni-all.in-view .year-tag {
  animation: yearFade 0.6s forwards;
}
@keyframes yearFade {
  from { opacity: 0; transform: translateY(8px); }
  to {}
}
.alumni-foot {
  font-family: var(--sans);
  font-size: 0.55rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--maroon);
  opacity: 0.7;
  font-weight: 600;
  position: relative;
  z-index: 1;
}

/* ---------- FINALE ---------- */
.finale {
  position: relative;
  min-height: var(--vh);
  overflow: hidden;
}
.finale-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.05);
  transition: opacity 1.8s ease, transform 8s ease-out;
  z-index: 0;
}
.finale.in-view .finale-photo {
  opacity: 1;
  transform: scale(1);
}

/* Logo + association at upper-right */
.finale-corner {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: rgba(74,16,24,0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  padding: 0.5rem 0.85rem 0.5rem 0.55rem;
  border-radius: 999px;
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 1s 0.3s, transform 1s 0.3s;
}
.finale.in-view .finale-corner {
  opacity: 1;
  transform: translateY(0);
}
.finale-corner-logo {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  flex-shrink: 0;
}
.finale-corner-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}
.finale-corner-name {
  font-family: var(--serif);
  font-size: 0.78rem;
  font-style: italic;
  color: var(--cream);
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.finale-corner-est {
  font-family: var(--sans);
  font-size: 0.5rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold-pale);
  font-weight: 600;
  margin-top: 0.15rem;
}

/* Bottom banner: Come home + date + location */
.finale-banner {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  background: linear-gradient(180deg, rgba(74,16,24,0) 0%, rgba(74,16,24,0.85) 30%, rgba(58,12,18,0.97) 100%);
  padding: 4.5rem 1.25rem 2rem;
  text-align: center;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 1.4s 0.2s, transform 1.4s 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.finale.in-view .finale-banner {
  opacity: 1;
  transform: translateY(0);
}
.finale-line {
  font-family: var(--serif);
  font-style: italic;
  font-size: 3rem;
  font-weight: 500;
  color: var(--cream);
  line-height: 1;
  margin-bottom: 1.25rem;
  text-shadow: 0 4px 30px rgba(0,0,0,0.5);
}
.finale-meta {
  font-family: var(--serif);
  font-size: 0.9rem;
  color: var(--cream);
  letter-spacing: 0.1em;
  line-height: 1.8;
}
.finale-venue {
  font-style: italic;
  color: var(--gold-pale);
  font-size: 0.95em;
  display: block;
  margin-top: 0.15rem;
}

/* ============================================================
   TABLET  (>= 760px)
   ============================================================ */
@media (min-width: 760px) {
  .hero { padding: 4rem 2rem; }
  .hero-logo { width: 100px; margin-bottom: 1.6rem; }
  .hero-eyebrow { font-size: 0.68rem; letter-spacing: 0.45em; margin-bottom: 1.75rem; }
  .hero-title { font-size: 4.2rem; margin-bottom: 1.25rem; }
  .hero-rule { width: 70px; margin: 1.25rem auto; }
  @keyframes widen { from { opacity:0; width:0; } to { opacity:1; width:70px; } }
  .hero-event { font-size: 1.2rem; margin-bottom: 2.5rem; }
  /* Tablet — native rotor size larger */
  .flipdown .rotor,
  .flipdown .rotor-leaf-front,
  .flipdown .rotor-leaf-rear,
  .flipdown .rotor-top,
  .flipdown .rotor-bottom {
    width: 52px !important;
    font-size: 2.6rem !important;
  }
  .flipdown .rotor,
  .flipdown .rotor-leaf-front,
  .flipdown .rotor-leaf-rear {
    height: 84px !important;
    line-height: 84px !important;
  }
  .flipdown .rotor-top,
  .flipdown .rotor-bottom {
    height: 42px !important;
    line-height: 84px !important;
  }
  .flipdown .rotor-group { padding-right: 16px !important; }
  .flipdown .rotor-group-heading { height: 28px !important; line-height: 28px !important; }
  .flipdown .rotor-group-heading::before { font-size: 0.65rem !important; }
  .hero-date { font-size: 1.1rem; letter-spacing: 0.15em; }
  .scroll-hint { bottom: 2rem; }
  .scroll-line { height: 40px; }

  .school-eyebrow { font-size: 0.65rem; }
  .school-name { font-size: 1.6rem; }
  .school-caption { bottom: 2.5rem; }

  .bridge { padding: 5rem 2rem; }
  .bridge-text { font-size: 2.6rem; }

  /* Sticky scroll on tablet+ */
  .batch { height: 130vh; min-height: 800px; }
  .batch-sticky {
    position: sticky;
    top: 0;
    height: 100vh;
    min-height: auto;
    flex-direction: row;
    text-align: left;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    padding: 0 4rem;
    gap: 3rem;
  }
  .batch-num { top: 2.5rem; right: 4rem; font-size: 0.8rem; letter-spacing: 0.3em; }
  .batch-gem { width: auto; height: 60vmin; }
  .batch-gem svg, .batch-gem .batch-photo { max-width: 480px; }
  .batch-info { align-items: flex-start; transform: translateX(40px); }
  .batch.in-view .batch-info { transform: translateX(0); }
  .batch-year { font-size: 7rem; }
  .batch-divider { margin: 0.5rem 0; }
  .batch-gem-name { font-size: 2rem; }
  .batch-anniversary { font-size: 0.72rem; }

  /* Polished batch */
  .batch.polished .batch-num { top: 2.5rem; left: 4rem; font-size: 0.8rem; letter-spacing: 0.3em; }

  .batch-gallery { padding: 7rem 2rem 7rem; }
  .bg-eyebrow { font-size: 0.7rem; }
  .bg-title { font-size: 2.8rem; margin-bottom: 4rem; }
  .bg-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 3.5rem 3rem;
  }
  .polaroid { max-width: 360px; }
  .batch.polished .batch-gem {
    top: 50%;
    left: auto;
    right: 5vw;
    transform: translateY(-50%);
    width: clamp(220px, 30vw, 360px);
    height: clamp(220px, 30vw, 360px);
  }
  .batch.polished .batch-info {
    left: 5vw;
    right: auto;
    bottom: 5rem;
    text-align: left;
    align-items: flex-start;
    padding: 0;
  }
  .batch.polished .batch-divider { margin: 0 0 0.75rem; }
  .batch.polished .batch-gem-name { font-size: 0.95rem; letter-spacing: 0.5em; }
  .batch.polished .batch-year { font-size: 9rem; }
  .batch.polished .batch-anniversary { font-size: 1.2rem; }

  .alumni-all { padding: 7rem 2rem 8rem; }
  .alumni-eyebrow { font-size: 0.7rem; }
  .alumni-title { font-size: 2.8rem; margin-bottom: 0.7rem; }
  .alumni-sub { font-size: 1.1rem; letter-spacing: 0.15em; margin-bottom: 3.5rem; }
  .year-strip { gap: 0.6rem 1rem; }
  .year-tag { font-size: 1rem; }
  .year-tag.celebrant { font-size: 1.5rem; }
  .alumni-foot { font-size: 0.65rem; }

  .finale-corner { top: 1.5rem; right: 1.5rem; padding: 0.6rem 1.1rem 0.6rem 0.65rem; gap: 0.75rem; }
  .finale-corner-logo { width: 48px; height: 48px; }
  .finale-corner-name { font-size: 0.95rem; }
  .finale-corner-est { font-size: 0.55rem; letter-spacing: 0.4em; }
  .finale-banner { padding: 6rem 2rem 3rem; }
  .finale-line { font-size: 4.6rem; margin-bottom: 1.5rem; }
  .finale-meta { font-size: 1.05rem; letter-spacing: 0.12em; }
}

/* ============================================================
   DESKTOP  (>= 1100px)
   ============================================================ */
@media (min-width: 1100px) {
  .hero-logo { width: 120px; }
  .hero-eyebrow { font-size: 0.72rem; letter-spacing: 0.5em; }
  .hero-title { font-size: 5.5rem; }
  .hero-event { font-size: 1.4rem; }
  /* Desktop — full FlipDown native sizing */
  .flipdown .rotor,
  .flipdown .rotor-leaf-front,
  .flipdown .rotor-leaf-rear,
  .flipdown .rotor-top,
  .flipdown .rotor-bottom {
    width: 60px !important;
    font-size: 3rem !important;
  }
  .flipdown .rotor,
  .flipdown .rotor-leaf-front,
  .flipdown .rotor-leaf-rear {
    height: 100px !important;
    line-height: 100px !important;
  }
  .flipdown .rotor-top,
  .flipdown .rotor-bottom {
    height: 50px !important;
    line-height: 100px !important;
  }
  .flipdown .rotor-group { padding-right: 30px !important; }
  .flipdown .rotor-group-heading { height: 30px !important; line-height: 30px !important; }
  .flipdown .rotor-group-heading::before { font-size: 0.7rem !important; }
  .hero-date { font-size: 1.25rem; }

  .bridge-text { font-size: 3.2rem; }

  .batch-sticky { padding: 0 8rem; gap: 4rem; }
  .batch-num { top: 3rem; right: 8rem; }
  .batch-year { font-size: 9rem; }
  .batch-gem-name { font-size: 2.4rem; }

  .batch.polished .batch-num { top: 3rem; left: 6rem; }
  .batch.polished .batch-gem { right: 6rem; }
  .batch.polished .batch-info { left: 6rem; bottom: 6rem; }
  .batch.polished .batch-year { font-size: 12rem; }
  .batch.polished .batch-gem-name { font-size: 1.1rem; }
  .batch.polished .batch-anniversary { font-size: 1.4rem; }

  .alumni-title { font-size: 3.6rem; }

  .bg-grid { grid-template-columns: repeat(4, 1fr); gap: 2.5rem; }
  .bg-title { font-size: 3.2rem; }
  .alumni-sub { font-size: 1.2rem; }
  .year-tag { font-size: 1rem; }
  .year-tag.celebrant { font-size: 1.6rem; }

  .finale-corner { top: 2rem; right: 2rem; padding: 0.7rem 1.25rem 0.7rem 0.75rem; }
  .finale-corner-logo { width: 56px; height: 56px; }
  .finale-corner-name { font-size: 1.1rem; }
  .finale-banner { padding: 7rem 2rem 3.5rem; }
  .finale-line { font-size: 6rem; }
  .finale-meta { font-size: 1.15rem; }
}

/* ---------- A11y / motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
