/* Home edition: a compact adaptation of the reference's broadsheet grid. */
.home {
  max-width: none;
}
.masthead {
  border-block: var(--rule-double);
  margin: 0 0 2rem;
  padding: 0.8rem 0 1rem;
  text-align: center;
}
.masthead__edition {
  border-bottom: 1px solid var(--rule);
  color: var(--ink-muted);
  display: flex;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  justify-content: space-between;
  letter-spacing: 0.12em;
  padding-bottom: 0.45rem;
  text-transform: uppercase;
}
.masthead__kicker {
  color: var(--ink-muted);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.18em;
  margin: 0.8rem 0 0.35rem;
  text-transform: uppercase;
}
.masthead__title {
  font-family: var(--font-display);
  font-size: clamp(3rem, 9vw, 7rem);
  letter-spacing: -0.035em;
  line-height: 0.82;
  text-transform: uppercase;
  text-wrap: balance;
}
.masthead__title em,
.masthead__title .masthead__accent {
  color: var(--accent);
  font-style: normal;
}
.masthead__subtitle {
  color: var(--ink-soft);
  font-size: var(--fs-md);
  font-style: italic;
  margin: 0.7rem auto 0;
  max-width: 52ch;
}
.masthead__rule {
  color: var(--accent);
  font-size: var(--fs-xs);
  letter-spacing: 0.55em;
  margin-top: 0.75rem;
}

.lead-article {
  border-bottom: 1px solid var(--rule);
  margin-bottom: 2rem;
  padding-bottom: 2rem;
}
.lead-article__headline {
  font-family: var(--font-body);
  font-size: clamp(2.35rem, 6vw, 5.1rem);
  font-weight: 700;
  letter-spacing: -0.045em;
  line-height: 0.92;
  margin-bottom: 0.8rem;
  max-width: 16ch;
  position: relative;
  text-transform: none;
}
.lead-article__headline::before {
  color: var(--accent);
  content: "Front page · Lead story";
  display: block;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: 400;
  letter-spacing: 0.16em;
  line-height: 1.4;
  margin-bottom: 0.65rem;
  text-transform: uppercase;
}
.lead-article__headline::after {
  border-bottom: var(--rule-double);
  content: "";
  display: block;
  margin-top: 0.75rem;
  width: min(100%, 15rem);
}
.lead-article__deck {
  border-left: 3px solid var(--accent);
  color: var(--ink-soft);
  font-size: var(--fs-md);
  font-style: italic;
  margin-bottom: 0.75rem;
  max-width: 72ch;
  padding-left: 0.9rem;
}
.lead-article__byline {
  color: var(--ink-muted);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.lead-article__body {
  column-count: 2;
  column-gap: 2rem;
  column-rule: 1px solid var(--paper-edge);
  hyphens: auto;
  margin-top: 1rem;
  text-align: justify;
}
.lead-article__body p:first-child::first-letter {
  color: var(--accent);
  float: left;
  font-size: 4em;
  font-weight: 700;
  line-height: 0.75;
  padding: 0.08em 0.08em 0 0;
}

.sac-diagram-section {
  border-bottom: 1px solid var(--rule);
  margin: 2rem 0;
  padding-bottom: 2rem;
}
.sac-diagram-lede {
  color: var(--ink-soft);
  font-size: var(--fs-md);
  margin-bottom: 1.25rem;
  max-width: 62ch;
}
.sac-diagram-wrap {
  background: var(--paper-soft);
  border: 1px solid var(--rule);
  box-shadow: 4px 4px 0 var(--paper-edge);
  padding: 0.5rem;
}

/* ── The organisational plate (js/components/sac-diagram.js) ──────
   The chart re-renders into a stacked column below 760px, so there is no
   min-width and nothing to scroll sideways — every label stays full size
   at every width. */

.sacmap__plate {
  display: block;
  width: 100%;
}
.sacmap__sheet {
  fill: var(--paper-soft);
  stroke: var(--ink-rule);
  stroke-width: 1.2;
}
.sacmap__masthead {
  fill: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.08em;
}
.sacmap__kicker {
  fill: var(--ink-muted);
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.22em;
}
/* The stacked plate is only 360 units wide — the wide masthead would run
   into its own border at that size. */
.sacmap__plate--narrow .sacmap__masthead {
  font-size: 14px;
  letter-spacing: 0.04em;
}
.sacmap__plate--narrow .sacmap__kicker {
  font-size: 7px;
  letter-spacing: 0.14em;
}
.sacmap__rule {
  stroke: var(--ink);
  opacity: 0.9;
}

/* Seal */
.sacmap__seal-halo {
  fill: var(--accent);
  opacity: 0.06;
}
.sacmap__seal-ring {
  fill: none;
  stroke: var(--accent);
  stroke-width: 1.8;
}
.sacmap__seal-ring--inner {
  opacity: 0.45;
  stroke-width: 0.7;
}
.sacmap__seal-mark {
  fill: var(--accent);
  font-family: var(--font-body);
  font-size: 21px;
  font-weight: 800;
  letter-spacing: 0.04em;
}
.sacmap__seal-sub {
  fill: var(--ink-muted);
  font-family: var(--font-mono);
  font-size: 6px;
  letter-spacing: 0.16em;
}

/* Connectors */
.sacmap__link {
  fill: none;
  stroke: var(--ink-muted);
  stroke-dasharray: 5 4;
  stroke-width: 0.9;
  transition:
    stroke var(--transition),
    stroke-width var(--transition),
    opacity var(--transition);
}
.sacmap__link.is-active {
  opacity: 1;
  stroke: var(--accent);
  stroke-width: 1.8;
}

/* Body cards */
.sacmap__card a {
  cursor: pointer;
}
.sacmap__card-paper {
  fill: var(--paper);
  stroke: var(--ink);
  stroke-width: 1.05;
  transition:
    fill var(--transition),
    stroke var(--transition);
}
.sacmap__pin {
  fill: var(--accent-gold);
  stroke: rgba(24, 20, 16, 0.32);
  stroke-width: 0.6;
}
.sacmap__card-name {
  fill: var(--ink);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
}
.sacmap__card-members {
  fill: var(--accent);
  font-family: var(--font-mono);
  font-size: 7.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.sacmap__card-note {
  fill: var(--ink-muted);
  font-family: var(--font-body);
  font-size: 8.5px;
}
.sacmap__card.is-active .sacmap__card-paper {
  fill: var(--paper-soft);
  stroke: var(--accent);
}
.sacmap__card a:focus-visible .sacmap__card-paper {
  outline: 2px solid var(--accent);
  stroke: var(--accent);
}

/* ── Assembly: plays once, when the plate scrolls into view ────────
   Every animated property is transform/opacity or stroke-dashoffset, so
   the whole sequence composites without a layout pass. */

.sacmap__rule {
  stroke-dasharray: var(--rule-len, 1400);
  stroke-dashoffset: var(--rule-len, 1400);
  transition: stroke-dashoffset 900ms ease calc(var(--i, 0) * 120ms);
}
.sacmap.is-live .sacmap__rule {
  stroke-dashoffset: 0;
}

.sacmap__seal {
  opacity: 0;
  transform: scale(1.45);
  transform-box: fill-box;
  transform-origin: center;
  transition:
    transform 520ms cubic-bezier(0.2, 1.5, 0.4, 1) 420ms,
    opacity 300ms ease 420ms;
}
.sacmap.is-live .sacmap__seal {
  opacity: 1;
  transform: scale(1);
}
/* the ink spreading out from under a stamp as it lifts */
.sacmap.is-live .sacmap__seal-halo {
  animation: sealPress 900ms ease-out 900ms both;
}
@keyframes sealPress {
  0% {
    opacity: 0.3;
    transform: scale(0.4);
  }
  60% {
    opacity: 0.12;
    transform: scale(1.35);
  }
  100% {
    opacity: 0.06;
    transform: scale(1);
  }
}
.sacmap__seal-halo {
  transform-box: fill-box;
  transform-origin: center;
}

.sacmap__link {
  stroke-dasharray: var(--len, 400);
  stroke-dashoffset: var(--len, 400);
}
.sacmap.is-live .sacmap__link {
  stroke-dashoffset: 0;
  transition:
    stroke-dashoffset 620ms ease calc(950ms + var(--i, 0) * 90ms),
    stroke var(--transition),
    stroke-width var(--transition);
}

.sacmap__card {
  opacity: 0;
  transform: translateY(14px);
  transform-box: fill-box;
  transform-origin: center;
  transition:
    transform 460ms cubic-bezier(0.22, 1, 0.36, 1) calc(1250ms + var(--i, 0) * 110ms),
    opacity 460ms ease calc(1250ms + var(--i, 0) * 110ms);
}
.sacmap.is-live .sacmap__card {
  opacity: 1;
  transform: translateY(0);
}
/* hover lift is a separate, immediate transform — it must not wait on the
   entrance delay, so it only applies once the plate has played */
.sacmap.is-live .sacmap__card.is-active {
  transform: translateY(-3px);
  transition:
    transform var(--transition),
    opacity var(--transition);
}

/* Reduced motion: the plate is simply already assembled. */
@media (prefers-reduced-motion: reduce) {
  .sacmap__rule,
  .sacmap__link {
    stroke-dashoffset: 0;
    transition: none;
  }
  .sacmap__seal,
  .sacmap__card {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .sacmap.is-live .sacmap__seal-halo {
    animation: none;
  }
}
[data-reduce-motion="on"] .sacmap__rule,
[data-reduce-motion="on"] .sacmap__link {
  stroke-dashoffset: 0;
}
[data-reduce-motion="on"] .sacmap__seal,
[data-reduce-motion="on"] .sacmap__card {
  opacity: 1;
  transform: none;
}
.section-divider {
  align-items: center;
  display: flex;
  gap: 1rem;
  margin: 2rem 0;
}
.section-divider::before,
.section-divider::after {
  border-top: var(--rule-heavy);
  content: "";
  flex: 1;
}
.section-divider__ornament {
  color: var(--accent);
  letter-spacing: 0.4em;
}

.body-section {
  border-top: var(--rule-double);
  margin: 2.5rem 0;
  padding-top: 1rem;
}
.body-banner {
  display: grid;
  gap: 0.3rem 1rem;
  grid-template-columns: auto 1fr;
  margin-bottom: 1rem;
}
.body-banner__kicker {
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  grid-column: 1 / -1;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.body-banner__title {
  font-family: var(--font-body);
  font-size: clamp(1.75rem, 4vw, 3rem);
  letter-spacing: -0.025em;
  text-transform: none;
}
.body-banner__tagline {
  color: var(--ink-muted);
  font-size: var(--fs-sm);
  font-style: italic;
}
.body-banner__ornament {
  color: var(--accent);
  letter-spacing: 0.25em;
}
.body-empty {
  color: var(--ink-muted);
  font-family: var(--font-mono);
  font-size: var(--fs-sm);
}
.body-section:not(.is-visible) {
  opacity: 0.5;
}
.body-section.is-visible {
  animation: section-print 450ms ease both;
}
@keyframes section-print {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.paper-grain-overlay {
  inset: 0;
  pointer-events: none;
  position: fixed;
  z-index: 1;
}
.ink-stamp {
  border: 2px solid var(--accent);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.12em;
  padding: 0.2rem 0.55rem;
  text-transform: uppercase;
  transform: rotate(-5deg);
}
.news-ticker {
  border-block: 2px solid var(--rule);
  display: flex;
  margin: 2rem 0;
  overflow: hidden;
}

@media (max-width: 720px) {
  .news-ticker__track {
    min-width: 0;
  }
  /* On phones the bulletin reads as a swipeable strip rather than clipping */
  .news-ticker {
    overflow-x: auto;
    scrollbar-width: thin;
  }
}
.news-ticker__label {
  background: var(--ink);
  color: var(--paper);
  flex: 0 0 auto;
  font-family: var(--font-display);
  padding: 0.4rem 0.75rem;
  text-transform: uppercase;
}
.news-ticker__track {
  display: flex;
  gap: 2rem;
  min-width: max-content;
  padding: 0.4rem 0;
}
.news-ticker__item {
  color: var(--ink-muted);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  text-transform: uppercase;
}
.news-ticker__item::before {
  color: var(--accent);
  content: "✦";
  margin-right: 0.6rem;
}

.notebook-section {
  margin: 2.5rem 0;
}
.notebook-section__heading {
  border-bottom: var(--rule-heavy);
  font-size: var(--fs-xl);
  margin-bottom: 1rem;
  padding-bottom: 0.45rem;
}
.pinned-grid,
.notebook-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  list-style: none;
  padding: 0;
}
.pinned-card,
.notebook-card {
  background: var(--paper-soft);
  border: 1px solid var(--rule);
  box-shadow: 3px 3px 0 var(--paper-edge);
  padding: 1rem;
  position: relative;
}
.pinned-card {
  transform: rotate(var(--tilt, 0deg));
}
.pinned-card::before {
  background: var(--accent);
  border-radius: 50%;
  content: "";
  height: 12px;
  left: 50%;
  position: absolute;
  top: -6px;
  transform: translateX(-50%);
  width: 12px;
}
.pinned-card__title,
.notebook-card__caption {
  font-family: var(--font-body);
  font-size: var(--fs-md);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.08;
  overflow-wrap: anywhere;
  text-transform: none;
}
.pinned-card__title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}
.notebook-card__caption {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  margin-bottom: 0.55rem;
  overflow: hidden;
}
.pinned-card__meta,
.pinned-card__date,
.pinned-card__location,
.notebook-card__meta {
  color: var(--ink-muted);
  display: block;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
}
.pinned-card__body,
.notebook-card__notes {
  color: var(--ink-soft);
  font-size: var(--fs-sm);
}
.pinned-card iframe,
.notebook-card__media {
  aspect-ratio: 16 / 9;
  min-width: 0;
  overflow: hidden;
  width: 100%;
}
.pinned-card iframe,
.notebook-card__media iframe {
  border: 1px solid var(--rule);
  height: 100%;
  width: 100%;
}
.notebook-card__media {
  background: var(--paper-deep);
  margin-bottom: 0.8rem;
}
.pinned-card__link {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  margin-top: 0.6rem;
  text-transform: uppercase;
}
.notebook-card__tape {
  background: rgba(183, 141, 47, 0.45);
  height: 14px;
  position: absolute;
  top: -7px;
  width: 54px;
}
.notebook-card__tape--tl {
  left: 1rem;
  transform: rotate(-4deg);
}
.notebook-card__tape--tr {
  right: 1rem;
  transform: rotate(4deg);
}
.notebook-card__tape--bl {
  bottom: -7px;
  left: 42%;
  transform: rotate(2deg);
}

.home-stats {
  border-block: 1px solid var(--rule);
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  margin: 2rem 0;
  padding: 1rem 0;
}

.home-stat {
  border-left: 3px solid var(--accent);
  padding: 0.35rem 0 0.35rem 0.9rem;
}

.home-stat strong {
  color: var(--accent);
  display: block;
  font-family: var(--font-display);
  font-size: var(--fs-2xl);
  line-height: 0.9;
}

.home-stat span {
  color: var(--ink-muted);
  display: block;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* The figure alone says little; the note under it is the actual fact. */
.home-stat__note {
  color: var(--ink-soft);
  font-family: var(--font-body) !important;
  font-size: var(--fs-xs);
  letter-spacing: 0 !important;
  margin-top: 0.3rem;
  text-transform: none !important;
}

.campus-gallery {
  margin: 2.5rem 0;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 2rem;
}

.campus-gallery__grid {
  display: grid;
  gap: 1.2rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  margin-top: 1rem;
}

.campus-gallery__item {
  background: var(--paper-soft);
  border: 1px solid var(--ink);
  box-shadow: 3px 3px 0 var(--paper-edge);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: rotate(var(--pin-rotate, 0.15deg));
}

.campus-gallery__item a {
  background: var(--paper-deep);
  display: block;
  overflow: hidden;
  flex: 1;
}

.campus-gallery__item img {
  display: block;
  height: auto;
  max-height: 320px;
  object-fit: contain;
  object-position: center;
  width: 100%;
}

.campus-gallery__item figcaption {
  background: var(--paper-soft);
  border-top: 1px solid var(--rule);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  padding: 0.6rem 0.7rem;
}

.campus-gallery__item figcaption strong {
  color: var(--ink);
  display: block;
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: 700;
  margin-bottom: 0.15rem;
  overflow-wrap: anywhere;
}

.campus-gallery__item figcaption span {
  color: var(--ink-muted);
  display: block;
  overflow-wrap: anywhere;
}

@media (max-width: 720px) {
  .lead-article__body {
    column-count: 1;
    text-align: left;
  }
  .body-banner {
    display: block;
  }
  .body-banner__ornament {
    margin-top: 0.4rem;
  }
  .pinned-grid,
  .notebook-grid,
  .campus-gallery__grid {
    grid-template-columns: 1fr;
  }
}

/* Retain a DPI-safe hook for existing paper assets without making them part
   of the critical background. Browsers use the system gradient above.
   The photo masthead (.masthead--photo) is EXCLUDED — its campus photograph
   and legibility scrim must win over this legacy newspaper texture. */
@supports (background-image: image-set(url("x") 1x)) {
  body[data-page="home"] .masthead:not(.masthead--photo) {
    background-image: image-set(
      url("../../assets/newspaper-bg.jpg") 1x,
      url("../../assets/newspaper-bg.jpg") 2x
    );
    background-size: cover;
  }
  .sac-diagram-wrap {
    background-image: image-set(
      url("../../assets/old-paper.jpg") 1x,
      url("../../assets/old-paper.jpg") 2x
    );
  }
}

@media (hover: none) and (pointer: coarse) {
  .masthead,
  .sac-diagram-wrap {
    background-attachment: scroll;
  }
}

/* Hero — front-page photograph, newspaper double-rule + pin */
.hero {
  border-bottom: var(--rule-double);
  border-top: var(--rule-double);
  margin: 0 0 2rem;
  padding: 0.6rem 0 0.8rem;
}

.hero__frame {
  background: var(--paper-deep);
  border: 1px solid var(--ink);
  box-shadow: 4px 4px 0 var(--paper-edge);
  overflow: hidden;
  position: relative;
}

.hero__frame::before {
  background: radial-gradient(circle at 30% 30%, #c9a86a, #8b6f32 65%, #5a4220 100%);
  border: 1px solid rgba(24, 20, 16, 0.32);
  border-radius: 50%;
  box-shadow: 0 1px 2px rgba(24, 20, 16, 0.35);
  content: "";
  height: 14px;
  left: 50%;
  position: absolute;
  top: 8px;
  transform: translateX(-50%);
  width: 14px;
  z-index: 2;
}

.hero__frame img {
  display: block;
  height: auto;
  max-height: min(62vh, 720px);
  object-fit: cover;
  object-position: center;
  width: 100%;
}

.hero__caption {
  color: var(--ink-muted);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  line-height: 1.5;
  margin: 0.6rem 0 0;
  text-align: left;
}

.hero__kicker {
  color: var(--accent);
  display: block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  margin-bottom: 0.25rem;
  text-transform: uppercase;
}

@media (max-width: 720px) {
  .hero__frame img {
    aspect-ratio: 4 / 3;
    max-height: 52vh;
    object-position: center 30%;
  }
  .hero {
    margin-bottom: 1.25rem;
  }
  .masthead__title {
    font-size: clamp(2.4rem, 13vw, 3.6rem);
  }
  .masthead__edition {
    font-size: 0.62rem;
    gap: 0.4rem;
  }
  .lead-article__headline {
    font-size: clamp(1.7rem, 8.5vw, 2.4rem);
    max-width: 100%;
  }
  .postmark {
    height: 58px;
    right: 0.5rem;
    top: 0.5rem;
    width: 58px;
    font-size: 0.5rem;
  }
}

/* Teaser link under the flipping book */
.campus-more {
  font-family: var(--font-mono);
  margin-top: 1rem;
  text-align: center;
}
.campus-more__link {
  border-bottom: 1px solid var(--accent);
  color: var(--accent);
  font-size: var(--fs-xs);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.campus-more__link:hover {
  color: var(--accent-deep);
}

/* ── The Campus in Print — a flipping 3D book ───────────────────── */
.campus-book-section {
  margin: 2.5rem 0;
}
.book {
  perspective: 2600px;
}
/* Viewport clip OUTSIDE the 3D scene: mid-flip leaves swing toward the
   viewer and perspective magnifies them past the stage bounds. Clipping
   here is safe because this wrapper carries no preserve-3d of its own —
   unlike overflow/clip on .book__stage or .book__leaf, which would flatten
   the scene and mirror flipped pages. The 16px bleed preserves base +
   shadow edges; anything beyond reads as the book's physical extent. */
.book__viewport {
  margin: 0 -16px;
  overflow: hidden;
  padding: 16px;
}
.book__stage {
  height: clamp(340px, 42vw, 520px);
  margin: 0 auto;
  max-width: 880px;
  position: relative;
  transform-style: preserve-3d;
  width: 100%;
}
.book__base {
  /* the desk the book rests on — a sheet of paper under the leaves */
  background: var(--paper-deep);
  border: 1px solid var(--ink-rule);
  bottom: -14px;
  box-shadow: 6px 10px 0 var(--paper-edge);
  inset: -8px -14px -14px -14px;
  position: absolute;
  z-index: 0;
}
.book__spine {
  background: linear-gradient(90deg, var(--ink) 0 3px, var(--paper-edge) 3px 7px);
  bottom: 0;
  left: 50%;
  position: absolute;
  top: 0;
  transform: translateX(-50%);
  width: 7px;
  z-index: 6;
}
.book__leaf {
  /* Half the stage, hinged on the centre spine: unflipped it covers the
     right page; flipped (-180deg) it lands exactly on the left page.
     NO overflow/clip on this element: both force transform-style:flat,
     which breaks backface-visibility and renders flipped leaves mirrored.
     Bounds are guaranteed structurally instead — faces are inset:0 with
     their own overflow:hidden, photos use a fixed aspect-ratio, captions
     ellipsis. The drop-shadow intentionally bleeds 4-6px like stacked paper. */
  background: var(--paper-soft);
  border: 1px solid var(--ink);
  bottom: 0;
  box-shadow: 4px 6px 0 var(--paper-edge);
  left: 50%;
  position: absolute;
  top: 0;
  transform: rotateY(0deg);
  transform-origin: left center;
  transform-style: preserve-3d;
  transition: transform 900ms cubic-bezier(0.3, 0.05, 0.25, 1);
  width: calc(50% - 5px);
}
.book__leaf.is-flipped {
  transform: rotateY(-180deg);
}
/* Wrap-around reset: snap every leaf home with no animation. */
.book__stage.no-anim .book__leaf {
  transition: none !important;
}
.book__face {
  align-content: center;
  backface-visibility: hidden;
  bottom: 0;
  display: grid;
  justify-items: center;
  left: 0;
  overflow: hidden;
  /* Dynamic spacing: padding scales with the stage instead of fixed rems */
  padding: clamp(0.6rem, 2.5vw, 1.4rem) clamp(0.5rem, 2vw, 1rem);
  position: absolute;
  right: 0;
  top: 0;
}
/* Paper reverse side of every leaf — what you see mid-flip and on the
   left pile. Pre-rotated so it reads correctly once the leaf turns. */
.book__face--backface {
  background:
    repeating-linear-gradient(115deg, rgba(24, 20, 16, 0.02) 0 1px, transparent 1px 4px),
    var(--paper-deep);
  transform: rotateY(180deg);
}
.book__plate-no {
  color: var(--ink-soft);
  font-family: var(--font-mono);
  font-size: clamp(0.6rem, 1.6vw, 0.72rem);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
/* Plate thumbnail on the reverse side — the left pile always shows a
   framed mini print, never a bare caption on blank paper. */
.book__plate-thumb {
  aspect-ratio: 4 / 3;
  border: 1px solid var(--ink-rule);
  display: block;
  height: auto;
  margin-bottom: 0.6rem;
  object-fit: cover;
  width: min(70%, 240px);
}
.book__plate-rule {
  color: var(--accent);
  font-size: 0.6rem;
  letter-spacing: 0.4em;
  margin-top: 0.5rem;
}
.book__face--cover,
.book__face--back {
  background:
    linear-gradient(135deg, var(--accent) 0 6px, transparent 6px),
    repeating-linear-gradient(115deg, rgba(24, 20, 16, 0.02) 0 1px, transparent 1px 4px),
    var(--paper-soft);
  text-align: center;
}
.book__face__kicker {
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
}
.book__face__title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3.4vw, 2.3rem);
  letter-spacing: -0.02em;
  text-transform: uppercase;
}
.book__face__sub {
  color: var(--ink-muted);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  margin-top: 0.5rem;
  text-transform: uppercase;
}
.book__face__hint {
  color: var(--ink-muted);
  font-size: 0.7rem;
  margin-top: 1.6rem;
}
.book__face__link {
  border-bottom: 1px solid var(--accent);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  margin-top: 1rem;
  text-transform: uppercase;
}
.book__face--spread {
  align-content: stretch;
  display: block;
  padding: 0.7rem;
}
.book__photo {
  display: flex;
  flex-direction: column;
  height: 100%;
  /* The plate is mounted in the middle of the page, as it would be in a
     printed album — a stretched button left the photo pinned to the top
     with its caption stranded at the foot of the page. */
  justify-content: center;
  margin: 0;
}
.book__photo-btn {
  background: none;
  border: 0;
  cursor: zoom-in;
  display: flex;
  flex: 0 1 auto;
  flex-direction: column;
  margin: 0;
  min-height: 0;
  padding: 0;
  width: 100%;
}
.book__photo-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.book__photo img {
  /* Strict uniform frame: every campus photo renders at the same 4:3
     size regardless of source dimensions — no more "huge" outliers. */
  aspect-ratio: 4 / 3;
  border: 1px solid var(--ink-rule);
  display: block;
  flex: none;
  height: auto;
  object-fit: cover;
  object-position: center;
  width: 100%;
}
.book__photo__cap {
  color: var(--ink-muted);
  display: -webkit-box;
  font-family: var(--font-mono);
  font-size: clamp(0.6rem, 1.6vw, 0.72rem);
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  line-height: 1.45;
  margin-top: 0.45rem;
  min-height: 2.1em;
  overflow: hidden;
  text-transform: uppercase;
}
.book__tools {
  align-items: center;
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-top: 1.25rem;
}
.book__counter {
  color: var(--ink-muted);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.1em;
}
.book__flip {
  background: var(--paper-soft);
  border: 1px solid var(--ink);
  color: var(--ink);
  font-size: 1.4rem;
  height: 42px;
  width: 42px;
}
.book__flip:hover {
  background: var(--accent);
  color: var(--paper);
}
.book__play {
  background: transparent;
  border: 1px solid var(--ink);
  color: var(--ink);
  font-size: 0.68rem;
  padding: 0.25rem 0.6rem;
}
.book__play:hover {
  background: var(--ink);
  color: var(--paper);
}

@media (max-width: 720px) {
  /* Each page is only ~half of a 390px screen, so a 340px-tall stage left
     a photo floating in a column of dead paper. Height now tracks the page
     width: a 4:3 plate plus its caption, and little else. */
  .book__stage {
    height: clamp(240px, 70vw, 340px);
  }
  .book__photo__cap {
    font-size: 0.5rem;
  }
  .book__face {
    padding: 0.6rem 0.45rem;
  }
  .book__face--spread {
    padding: 0.45rem;
  }
  .book__plate-no {
    font-size: 0.56rem;
  }
  /* 42px buttons sit a thumb apart, not shoulder to shoulder */
  .book__tools {
    gap: 0.75rem;
    margin-top: 1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .book__leaf {
    transition: none;
  }
}

/* Photo masthead — the campus itself behind the Chronicle title */
.masthead--photo {
  background:
    linear-gradient(
      180deg,
      rgba(24, 20, 16, 0.62) 0%,
      rgba(24, 20, 16, 0.34) 45%,
      rgba(24, 20, 16, 0.72) 100%
    ),
    image-set(
      url("../../assets/masthead-campus.webp") 1x,
      url("../../assets/masthead-campus.webp") 2x
    );
  background-size: cover, cover;
  background-position:
    center,
    center 38%;
  color: #fffaf0;
  margin-bottom: 2rem;
  padding: 2rem 0.8rem 2.2rem;
}
.masthead--photo .masthead__edition,
.masthead--photo .masthead__kicker {
  color: rgba(255, 250, 240, 0.85);
}
.masthead--photo .masthead__edition {
  border-bottom-color: rgba(255, 250, 240, 0.4);
}
.masthead--photo .masthead__title {
  color: #fffaf0;
  text-shadow: 0 2px 14px rgba(24, 20, 16, 0.65);
}
[data-theme="dark"] .masthead--photo .masthead__title {
  color: #f1e8d8;
}
.masthead--photo .masthead__subtitle {
  color: rgba(255, 250, 240, 0.92);
}
.masthead--photo .masthead__rule {
  color: #d46b5f;
}
/* dark theme: deepen the scrim slightly so light ink still reads */
[data-theme="dark"] .masthead--photo {
  background:
    linear-gradient(
      180deg,
      rgba(11, 9, 7, 0.72) 0%,
      rgba(11, 9, 7, 0.46) 45%,
      rgba(11, 9, 7, 0.8) 100%
    ),
    image-set(
      url("../../assets/masthead-campus.webp") 1x,
      url("../../assets/masthead-campus.webp") 2x
    );
  background-size: cover, cover;
  background-position:
    center,
    center 38%;
}
@media (max-width: 720px) {
  .masthead--photo {
    background-position:
      center,
      center 30%;
    padding: 1.2rem 0.5rem 1.5rem;
  }
}

/* ── The Campus Board — map-desk wall of pinned postcards ───────── */
.campus-board-section {
  margin: 2.5rem 0;
}
.board {
  background:
    radial-gradient(circle at 18% 12%, rgba(183, 141, 47, 0.16), transparent 22%),
    radial-gradient(circle at 84% 88%, rgba(131, 13, 13, 0.07), transparent 26%),
    repeating-linear-gradient(94deg, rgba(24, 20, 16, 0.03) 0 2px, transparent 2px 9px),
    linear-gradient(160deg, #d9c9a8 0%, #cdb88e 55%, #c2ab7e 100%);
  border: 4px double var(--ink);
  box-shadow: inset 0 0 42px rgba(24, 20, 16, 0.14);
  padding: clamp(0.8rem, 2.5vw, 1.6rem);
  position: relative;
}
.board__legend {
  color: rgba(24, 20, 16, 0.62);
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.22em;
  margin: 0 0 0.4rem;
  text-align: center;
  text-transform: uppercase;
}
.board__grid {
  display: grid;
  gap: clamp(0.5rem, 1.6vw, 1rem);
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr));
  list-style: none;
  margin: 0.4rem 0 0;
  padding: 0;
}
.board-card {
  background: var(--paper-soft);
  border: 1px solid var(--ink);
  box-shadow: 3px 4px 0 rgba(24, 20, 16, 0.28);
  display: flex;
  flex-direction: column;
  padding: 0.45rem 0.45rem 0;
  position: relative;
  transform: rotate(var(--tilt, 0deg));
  transition:
    transform var(--transition),
    box-shadow var(--transition);
}
.board-card:hover {
  box-shadow: 5px 6px 0 rgba(24, 20, 16, 0.34);
  transform: rotate(var(--tilt, 0deg)) translateY(-3px);
}
.board-card:focus-within {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.board-card a {
  display: block;
  overflow: hidden;
}
.board-card img {
  /* height:auto lets aspect-ratio beat the width/height attribute hints —
     with attrs present, an unset height falls back to the attr value (1200px
     tall cards). auto re-arms the 5/4 box. */
  aspect-ratio: 5 / 4;
  border: 1px solid var(--ink-rule);
  display: block;
  height: auto;
  object-fit: cover;
  width: 100%;
}
.board-card__pin {
  background: radial-gradient(circle at 32% 30%, #d46b5f, #830d0d 68%);
  border: 1px solid rgba(24, 20, 16, 0.4);
  border-radius: 50%;
  box-shadow: 0 2px 3px rgba(24, 20, 16, 0.4);
  height: 13px;
  left: 50%;
  position: absolute;
  top: -7px;
  transform: translateX(-50%);
  width: 13px;
  z-index: 2;
}
.board-card__cap {
  color: var(--ink-soft);
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.06em;
  margin: 0.4rem 0 0.55rem;
  overflow: hidden;
  padding: 0 0.15rem;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}
.board__more {
  color: var(--ink);
  display: inline-block;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.1em;
  margin-top: 1rem;
  text-align: center;
  text-decoration: underline;
  text-underline-offset: 3px;
  width: 100%;
}
.board__more:hover {
  color: var(--accent);
}

@media (prefers-reduced-motion: reduce) {
  .board-card,
  .board-card:hover {
    transition: none;
  }
}

/* Touch targets: book tools + board link clear 44px on coarse pointers. */
@media (pointer: coarse) {
  .book__flip,
  .book__play {
    min-height: 44px;
    min-width: 44px;
  }
  .board__more {
    display: block;
    padding-block: 0.5rem;
  }
}

/* Once assembled, the seal keeps a slow breathing pulse in both themes;
   dark mode inherits the warmer --accent automatically. */
.sacmap.is-live .sacmap__seal-ring {
  animation: seal-pulse 5.5s ease-in-out 1.6s infinite;
}
@keyframes seal-pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.78;
  }
}
@media (prefers-reduced-motion: reduce) {
  .sacmap.is-live .sacmap__seal-ring {
    animation: none;
  }
}
[data-theme="dark"] .sacmap__plate {
  /* gentle vignette under the whole diagram so the paper reads differently
     in the dark edition without repainting the SVG */
  filter: drop-shadow(0 0 18px rgba(212, 107, 95, 0.12));
}

/* ── Editorial folios ─────────────────────────────────────────────
   Section numbers, as a printed edition carries them. Counters derive
   from document order, so adding a section renumbers the rest for free. */
main.home {
  counter-reset: folio;
}
main.home .section-title,
main.home .notebook-section__heading {
  counter-increment: folio;
}
main.home .section-title::after,
main.home .notebook-section__heading::after {
  color: var(--ink-muted);
  content: "§ " counter(folio, upper-roman);
  float: right;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: 400;
  letter-spacing: 0.16em;
  padding-top: 0.55em;
}

/* End-mark at the foot of the edition */
main.home::after {
  color: var(--accent);
  content: "❦";
  display: block;
  font-size: 1.3rem;
  margin-top: 2rem;
  text-align: center;
}
