:root {
  --ink: #2d2622;
  --ink-soft: #655a51;
  --cream: #f5f0e6;
  --paper: #fffaf1;
  --paper-deep: #eadbc5;
  --terracotta: #b8684d;
  --terracotta-deep: #7e3f32;
  --peach: #e8aa8d;
  --sage: #7a8d68;
  --sage-deep: #3d5944;
  --mustard: #d8ad55;
  --night: #241d20;
  --night-soft: #3b2d31;
  --line: rgba(91, 66, 52, 0.2);
  --shadow-paper: 0 22px 60px rgba(87, 55, 36, 0.13), 0 4px 12px rgba(87, 55, 36, 0.08);
  --shadow-soft: 0 12px 28px rgba(68, 47, 37, 0.12);
  --heading: "Cormorant Garamond", Georgia, serif;
  --body: "Be Vietnam Pro", "Segoe UI", sans-serif;
  --container: 1180px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  overflow-x: hidden;
  color: var(--ink);
  background: var(--cream);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

body.modal-open { overflow: hidden; }

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

button, a { font: inherit; }

button { border: 0; }

a { color: inherit; text-decoration: none; }

button, a, [tabindex] { -webkit-tap-highlight-color: transparent; }

button:focus-visible, a:focus-visible, [tabindex]:focus-visible {
  outline: 3px solid var(--mustard);
  outline-offset: 4px;
}

.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.icon {
  width: 1.25rem;
  height: 1.25rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.6;
  flex: 0 0 auto;
}

.icon--small { width: 1rem; height: 1rem; }

.skip-link {
  position: fixed;
  z-index: 100;
  top: 1rem;
  left: 1rem;
  padding: 0.7rem 1rem;
  color: var(--ink);
  background: var(--paper);
  border-radius: 0.6rem;
  box-shadow: var(--shadow-soft);
  transform: translateY(-150%);
  transition: transform 180ms ease;
}

.skip-link:focus { transform: translateY(0); }

.container { width: min(calc(100% - 3.5rem), var(--container)); margin-inline: auto; }

.section { position: relative; padding: 8rem 0; }

.eyebrow {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin: 0 0 1.2rem;
  color: var(--terracotta-deep);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.17em;
  line-height: 1.2;
  text-transform: uppercase;
}

.eyebrow__line { width: 2.8rem; height: 1px; background: currentColor; opacity: 0.7; }
.eyebrow__dot { width: 0.45rem; height: 0.45rem; background: var(--mustard); border-radius: 50%; box-shadow: 0 0 0 5px rgba(216, 173, 85, 0.22); }
.eyebrow--light { color: rgba(255, 247, 232, 0.78); }
.eyebrow__line--light { background: rgba(255, 247, 232, 0.65); }

h1, h2, h3, p { margin-top: 0; }

h1, h2, h3 { font-family: var(--heading); font-weight: 600; }

h2 {
  margin-bottom: 1.2rem;
  color: var(--ink);
  font-size: clamp(3rem, 6vw, 5.4rem);
  letter-spacing: -0.035em;
  line-height: 0.91;
}

h2 span { color: var(--terracotta); font-style: italic; }

.section-heading { max-width: 43rem; }
.section-heading--center { margin-inline: auto; text-align: center; }
.section-heading--center .eyebrow { justify-content: center; }
.section-heading--split { display: flex; align-items: end; justify-content: space-between; gap: 4rem; max-width: none; }
.section-heading--split .section-heading__lead { max-width: 22rem; margin-bottom: 1.25rem; }
.section-heading__lead { max-width: 35rem; margin-bottom: 0; color: var(--ink-soft); font-size: 0.96rem; line-height: 1.8; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  min-height: 3.9rem;
  padding: 0.7rem 1.15rem 0.7rem 0.75rem;
  color: var(--paper);
  background: var(--terracotta-deep);
  border: 1px solid rgba(255, 248, 228, 0.35);
  border-radius: 999px;
  box-shadow: 0 12px 30px rgba(55, 29, 21, 0.22), inset 0 1px 0 rgba(255,255,255,0.2);
  cursor: pointer;
  font-size: 0.83rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: transform 220ms var(--ease), background 220ms ease, box-shadow 220ms ease;
}

.button:hover { background: #934b3a; box-shadow: 0 15px 35px rgba(55, 29, 21, 0.3), inset 0 1px 0 rgba(255,255,255,0.2); transform: translateY(-3px); }
.button:active { transform: translateY(0) scale(0.98); }
.button__icon { display: grid; place-items: center; width: 2.4rem; height: 2.4rem; color: var(--terracotta-deep); background: var(--paper); border-radius: 50%; }
.button__arrow { margin-left: 0.2rem; transition: transform 200ms ease; }
.button:hover .button__arrow { transform: translateY(3px); }

.icon-button {
  display: inline-grid;
  place-items: center;
  width: 2.65rem;
  height: 2.65rem;
  color: currentColor;
  background: transparent;
  border: 1px solid currentColor;
  border-radius: 50%;
  cursor: pointer;
  transition: color 180ms ease, background 180ms ease, transform 180ms ease;
}

.icon-button:hover { color: var(--paper); background: var(--terracotta); transform: translateY(-2px); }

/* Hero */
.hero {
  position: relative;
  display: flex;
  min-height: 100svh;
  overflow: hidden;
  isolation: isolate;
  color: var(--paper);
  background: #5a4539;
}

.hero__backdrop, .hero__wash { position: absolute; inset: -1.5rem; z-index: -2; }
.hero__backdrop { background: url("./assets/hero/hero-image.jpg") center 60% / cover no-repeat; filter: blur(3px) saturate(0.78); transform: scale(1.04); }
.hero__wash { z-index: -1; background: linear-gradient(104deg, rgba(43, 28, 24, 0.78) 0%, rgba(96, 54, 43, 0.47) 42%, rgba(245, 184, 140, 0.27) 100%), linear-gradient(180deg, rgba(35, 28, 26, 0.4) 0%, transparent 34%, rgba(39, 25, 23, 0.58) 100%); }

.site-nav {
  position: absolute;
  top: 1.25rem;
  left: 50%;
  right: auto;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  transform: translateX(-50%);
}

.brand { display: inline-flex; align-items: center; gap: 0.7rem; color: var(--paper); }
.brand__seal { display: grid; place-items: center; width: 2.8rem; height: 2.8rem; color: var(--terracotta-deep); background: var(--paper); border: 3px solid rgba(255,255,255,0.48); border-radius: 50%; box-shadow: 0 4px 15px rgba(0,0,0,0.15); }
.brand__seal .icon { width: 1.3rem; height: 1.3rem; }
.brand strong { display: block; font-family: var(--heading); font-size: 1.2rem; line-height: 0.9; letter-spacing: 0.06em; }
.brand small { display: block; margin-top: 0.25rem; color: rgba(255,255,255,0.72); font-size: 0.57rem; letter-spacing: 0.09em; text-transform: uppercase; }
.site-nav__links { display: flex; align-items: center; gap: 1.8rem; color: rgba(255,255,255,0.78); font-size: 0.74rem; font-weight: 600; }
.site-nav__links a { position: relative; padding: 0.35rem 0; }
.site-nav__links a::after { position: absolute; right: 0; bottom: 0; left: 0; height: 1px; background: var(--paper); content: ""; transform: scaleX(0); transform-origin: right; transition: transform 200ms ease; }
.site-nav__links a:hover::after { transform: scaleX(1); transform-origin: left; }
.nav-cta { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.5rem 0.75rem; color: var(--paper); border: 1px solid rgba(255,255,255,0.35); border-radius: 999px; font-size: 0.7rem; font-weight: 600; transition: background 180ms ease, color 180ms ease; }
.nav-cta:hover { color: var(--terracotta-deep); background: var(--paper); }

.hero__content { align-self: center; padding-top: 5.5rem; padding-bottom: 5rem; }
.hero__content .eyebrow { margin-bottom: 1.5rem; }
.hero__title { max-width: 55rem; margin-bottom: 1.4rem; color: var(--paper); font-size: clamp(4.3rem, 10vw, 9.7rem); letter-spacing: -0.06em; line-height: 0.79; }
.hero__title-line { display: block; opacity: 0; transform: translateY(22px); transition: opacity 800ms ease, transform 900ms var(--ease); }
.hero__title-line.is-visible { opacity: 1; transform: translateY(0); }
.hero__title-line--accent { color: #ffd8ba; font-size: 0.77em; }
.hero__title-line--accent em { color: #fff3dc; font-style: italic; }
.hero__subtitle { margin-bottom: 2rem; color: rgba(255, 248, 237, 0.83); font-size: 0.88rem; line-height: 1.7; }
.hero__subtitle span { color: rgba(255, 248, 237, 0.62); font-size: 0.78rem; letter-spacing: 0.1em; text-transform: uppercase; }
.hero__scroll { position: absolute; right: 1.75rem; bottom: 1.8rem; display: flex; align-items: center; gap: 0.65rem; color: rgba(255,255,255,0.72); font-size: 0.65rem; letter-spacing: 0.12em; text-transform: uppercase; writing-mode: vertical-rl; }
.hero__scroll .icon { animation: floatDown 2s ease-in-out infinite; }
.hero__leaf { position: absolute; z-index: -1; color: rgba(255,255,255,0.18); }
.hero__leaf .icon { width: 10rem; height: 10rem; stroke-width: 0.6; }
.hero__leaf--one { top: 18%; right: 3%; transform: rotate(18deg); }
.hero__leaf--two { bottom: 5%; left: 42%; transform: rotate(-40deg) scale(0.7); }

@keyframes floatDown { 0%, 100% { transform: translateY(-3px); } 50% { transform: translateY(4px); } }

/* Letter */
.letter-section { overflow: hidden; background: var(--cream); }
.letter-section::before { position: absolute; top: 16rem; right: -4rem; width: 18rem; height: 18rem; border: 1px solid rgba(184,104,77,0.16); border-radius: 50%; content: ""; box-shadow: 0 0 0 2rem rgba(184,104,77,0.03), 0 0 0 5rem rgba(184,104,77,0.025); }
.letter-card { position: relative; max-width: 1040px; margin: 4.8rem auto 0; padding: 0.55rem; background: linear-gradient(135deg, rgba(184,104,77,0.3), transparent 28%, rgba(122,141,104,0.35) 75%, transparent); transform: rotate(-0.45deg); transition: transform 500ms var(--ease), box-shadow 500ms ease; }
.letter-card:hover { transform: rotate(0deg) translateY(-4px); }
.letter-card__content { position: relative; padding: clamp(2rem, 5vw, 4.6rem); overflow: hidden; background-color: var(--paper); background-image: radial-gradient(rgba(151, 111, 71, 0.13) 0.7px, transparent 0.7px), linear-gradient(135deg, rgba(255,255,255,0.5), transparent 35%); background-size: 9px 9px, auto; box-shadow: var(--shadow-paper); }
.letter-card__content::after { position: absolute; inset: 1rem; border: 1px solid rgba(126,63,50,0.2); pointer-events: none; content: ""; }
.letter-card__topline { position: relative; z-index: 1; display: flex; justify-content: space-between; padding-bottom: 1.2rem; color: var(--terracotta-deep); border-bottom: 1px dashed rgba(126,63,50,0.35); font-size: 0.64rem; font-weight: 700; letter-spacing: 0.15em; text-transform: uppercase; }
.letter-card__body { position: relative; z-index: 1; display: grid; grid-template-columns: 1.15fr 0.85fr; gap: clamp(2rem, 6vw, 6rem); padding: 3rem 1.6rem 2rem; }
.letter-card__copy { max-width: 38rem; font-family: var(--heading); font-size: clamp(1.15rem, 1.7vw, 1.45rem); line-height: 1.47; }
.letter-card__copy p { margin-bottom: 1.05rem; }
.letter-card__salute { color: var(--terracotta-deep); font-weight: 700; }
.letter-card__closing { margin-top: 1.8rem; color: var(--terracotta-deep); font-size: 1.2rem; }
.letter-card__closing strong { font-size: 1.5rem; font-style: italic; }
.letter-card__photo { align-self: center; margin: 0; transform: rotate(4deg); }
.photo-frame { padding: 0.6rem 0.6rem 2.4rem; background: #fffdf7; box-shadow: 0 12px 23px rgba(74,47,32,0.15); }
.photo-frame img { width: 100%; aspect-ratio: 0.87; object-fit: cover; }
.letter-card__photo figcaption { margin-top: -2rem; padding-inline: 0.9rem; color: var(--terracotta-deep); font-family: var(--heading); font-size: 1.15rem; line-height: 1.05; text-align: center; transform: rotate(-2deg); }
.letter-card__signature { position: relative; z-index: 1; display: flex; align-items: center; justify-content: center; gap: 0.6rem; color: var(--terracotta); font-family: var(--heading); font-size: 1.2rem; font-style: italic; }
.letter-card__signature .icon { width: 0.9rem; height: 0.9rem; fill: currentColor; stroke-width: 1; }
.letter-card__corner { position: absolute; z-index: 2; width: 5.8rem; height: 5.8rem; border: 1px solid var(--terracotta); opacity: 0.55; }
.letter-card__corner--tl { top: 1.3rem; left: 1.3rem; border-right: 0; border-bottom: 0; }
.letter-card__corner--br { right: 1.3rem; bottom: 1.3rem; border-top: 0; border-left: 0; }

/* Wall */
.wall-section { overflow: hidden; color: var(--ink); background: #dfe6d3; }
.wall-section__pattern { position: absolute; inset: 0; opacity: 0.32; background-image: linear-gradient(26deg, transparent 48%, rgba(61,89,68,0.08) 49%, transparent 51%), linear-gradient(-26deg, transparent 48%, rgba(61,89,68,0.08) 49%, transparent 51%); background-size: 44px 44px; pointer-events: none; }
.wall-section__inner { position: relative; z-index: 1; }
.wall-section h2 { color: var(--sage-deep); }
.wall-section h2 span { color: var(--terracotta-deep); }
.wall-meta { display: flex; align-items: center; justify-content: space-between; gap: 2rem; margin: 3.2rem 0 2rem; }
.wall-meta__count { display: flex; align-items: center; gap: 0.8rem; color: var(--sage-deep); }
.wall-meta__count strong { font-family: var(--heading); font-size: 4rem; font-weight: 600; line-height: 0.75; }
.wall-meta__count span { border-left: 1px solid rgba(61,89,68,0.4); padding-left: 0.8rem; font-size: 0.67rem; font-weight: 700; letter-spacing: 0.08em; line-height: 1.35; text-transform: uppercase; }
.wall-meta__hint { display: inline-flex; align-items: center; gap: 0.55rem; margin: 0; color: var(--sage-deep); font-family: var(--heading); font-size: 1.1rem; font-style: italic; }
.wall-meta__hint .icon { color: var(--terracotta); }
.student-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.flip-card { width: 100%; min-height: 15.8rem; padding: 0; color: inherit; background: transparent; cursor: pointer; perspective: 1000px; text-align: left; }
.flip-card__inner { position: relative; width: 100%; height: 100%; min-height: 15.8rem; transform-style: preserve-3d; transition: transform 650ms var(--ease); }
.flip-card.is-flipped .flip-card__inner, .flip-card:hover .flip-card__inner { transform: rotateY(180deg); }
.flip-card__face { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: space-between; padding: 1.35rem; overflow: hidden; border: 1px solid rgba(99,65,47,0.13); border-radius: 0.3rem; backface-visibility: hidden; box-shadow: 3px 5px 0 rgba(107,73,51,0.11), 0 10px 18px rgba(77,70,45,0.08); }
.flip-card__front { background: var(--card-bg, #fff3cb); transform: rotate(var(--tilt, -1deg)); }
.flip-card__back { color: #fff9ec; background: var(--card-back, var(--terracotta-deep)); transform: rotateY(180deg); }
.flip-card__face::before { position: absolute; width: 5rem; height: 5rem; border: 1px solid currentColor; border-radius: 50%; content: ""; opacity: 0.1; }
.flip-card__front::before { top: -2.2rem; right: -1.8rem; }
.flip-card__back::before { bottom: -2.5rem; left: -2rem; }
.flip-card__number { color: rgba(73,55,38,0.55); font-size: 0.62rem; font-weight: 700; letter-spacing: 0.14em; }
.flip-card__icon { display: grid; place-items: center; width: 2.7rem; height: 2.7rem; color: var(--card-back, var(--terracotta-deep)); background: rgba(255,255,255,0.58); border-radius: 50%; }
.flip-card__icon .icon { width: 1.3rem; height: 1.3rem; }
.flip-card__name { margin: 0.6rem 0 0; color: var(--ink); font-family: var(--heading); font-size: 1.45rem; font-weight: 600; line-height: 0.98; }
.flip-card__instruction { display: flex; align-items: center; justify-content: space-between; color: rgba(73,55,38,0.58); font-size: 0.62rem; letter-spacing: 0.03em; }
.flip-card__instruction .icon { width: 0.9rem; height: 0.9rem; }
.flip-card__back .flip-card__number { color: rgba(255,249,236,0.58); }
.flip-card__back-title { display: block; margin: 0.5rem 0 0.75rem; color: #fff9ec; font-family: var(--heading); font-size: 1.55rem; font-weight: 600; line-height: 0.9; }
.flip-card__message { margin: 0; color: rgba(255,249,236,0.87); font-family: var(--heading); font-size: 1.08rem; line-height: 1.2; }
.flip-card__nickname { display: inline-flex; align-items: center; gap: 0.4rem; color: #fbd6ae; font-size: 0.62rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
.flip-card__nickname .icon { width: 0.8rem; height: 0.8rem; }

/* Gallery */
.gallery-section { background: var(--paper); }
.gallery-section::before { position: absolute; top: 0; left: 0; width: 100%; height: 1.5rem; background: repeating-linear-gradient(135deg, rgba(126,63,50,0.1) 0 8px, transparent 8px 16px); opacity: 0.45; content: ""; }
.gallery-grid { columns: 3; column-gap: 1.15rem; margin-top: 4rem; }
.gallery-card { position: relative; display: block; width: 100%; padding: 0; margin: 0 0 1.15rem; overflow: hidden; color: inherit; background: transparent; border: 0; border-radius: 0.28rem; cursor: pointer; break-inside: avoid; text-align: left; }
.gallery-card:nth-child(3n + 1) { transform: rotate(-0.7deg); }
.gallery-card:nth-child(3n + 2) { transform: rotate(0.45deg); }
.gallery-card:nth-child(3n) { transform: rotate(-0.25deg); }
.gallery-card__image { position: relative; overflow: hidden; background: var(--paper-deep); }
.gallery-card img { width: 100%; aspect-ratio: var(--aspect, 1.17); object-fit: cover; transition: transform 700ms var(--ease), filter 500ms ease; }
.gallery-card__caption { position: absolute; right: 0; bottom: 0; left: 0; padding: 3rem 1.1rem 1rem; color: #fffaf0; background: linear-gradient(transparent, rgba(32,22,20,0.84)); font-family: var(--heading); font-size: 1.3rem; line-height: 1.05; opacity: 0; transform: translateY(0.45rem); transition: opacity 300ms ease, transform 300ms var(--ease); }
.gallery-card:hover img, .gallery-card:focus-visible img { filter: saturate(1.1); transform: scale(1.05); }
.gallery-card:hover .gallery-card__caption, .gallery-card:focus-visible .gallery-card__caption { opacity: 1; transform: translateY(0); }
.gallery-card__expand { position: absolute; top: 0.8rem; right: 0.8rem; display: grid; place-items: center; width: 2.3rem; height: 2.3rem; color: #fffaf0; background: rgba(38,25,24,0.52); border: 1px solid rgba(255,255,255,0.38); border-radius: 50%; opacity: 0; transition: opacity 200ms ease; }
.gallery-card:hover .gallery-card__expand, .gallery-card:focus-visible .gallery-card__expand { opacity: 1; }

/* Cinema */
.cinema-section { overflow: hidden; color: #fff6e7; background: var(--night); }
.cinema-section::before, .cinema-section::after { position: absolute; width: 17rem; height: 17rem; border: 1px solid rgba(232,170,141,0.18); border-radius: 50%; content: ""; }
.cinema-section::before { top: -8rem; left: -6rem; box-shadow: 0 0 0 2rem rgba(232,170,141,0.04), 0 0 0 4rem rgba(232,170,141,0.03); }
.cinema-section::after { right: -9rem; bottom: -9rem; }
.cinema-section__glow { position: absolute; top: -20rem; left: 46%; width: 45rem; height: 45rem; background: rgba(184,104,77,0.15); border-radius: 50%; filter: blur(4rem); }
.cinema-layout { position: relative; z-index: 1; display: grid; grid-template-columns: 0.72fr 1.28fr; align-items: center; gap: clamp(3rem, 8vw, 8rem); }
.cinema-copy { max-width: 23rem; }
.cinema-copy h2 { margin-bottom: 1.5rem; color: #fff6e7; }
.cinema-copy h2 span { color: #e8aa8d; }
.cinema-copy > p { color: rgba(255,246,231,0.68); font-size: 0.92rem; line-height: 1.8; }
.cinema-copy__note { display: flex; align-items: center; gap: 0.8rem; margin-top: 2rem; color: #e8aa8d; font-family: var(--heading); font-size: 1.2rem; line-height: 1.05; }
.cinema-copy__note .icon { width: 1.8rem; height: 1.8rem; }
.cinema-copy__note small { color: rgba(255,246,231,0.46); font-family: var(--body); font-size: 0.6rem; letter-spacing: 0.08em; text-transform: uppercase; }
.cinema-player { position: relative; padding: 0.7rem; background: #1b1718; border: 1px solid rgba(255,246,231,0.18); box-shadow: 0 25px 60px rgba(0,0,0,0.35); }
.cinema-player__screen { position: relative; overflow: hidden; aspect-ratio: 16 / 9; background: #2a2021; }
.cinema-player__screen::before, .cinema-player__screen::after { position: absolute; z-index: 2; width: 1rem; height: 100%; background: repeating-linear-gradient(to bottom, #1b1718 0 1.2rem, transparent 1.2rem 2rem); content: ""; opacity: 0.8; }
.cinema-player__screen::before { left: -0.15rem; }.cinema-player__screen::after { right: -0.15rem; }
.cinema-player__screen img { width: 100%; height: 100%; object-fit: cover; transition: opacity 260ms ease, transform 700ms var(--ease); }
.cinema-player__screen.is-changing img { opacity: 0.25; transform: scale(1.04); }
.cinema-player__grain { position: absolute; z-index: 3; inset: 0; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.12'/%3E%3C/svg%3E"); mix-blend-mode: screen; pointer-events: none; }
.cinema-player__overlay { position: absolute; z-index: 4; top: 1rem; right: 1.2rem; left: 1.2rem; display: flex; justify-content: space-between; color: rgba(255,246,231,0.8); font-family: monospace; font-size: 0.55rem; letter-spacing: 0.12em; }
.cinema-player__frame b { color: #e8aa8d; }
.cinema-player__mark { color: rgba(255,246,231,0.6); }
.cinema-player__control { position: absolute; z-index: 5; right: 50%; bottom: 50%; display: grid; place-items: center; width: 4rem; height: 4rem; color: #fff6e7; background: rgba(42,30,31,0.64); border: 1px solid rgba(255,246,231,0.55); border-radius: 50%; cursor: pointer; opacity: 0; transform: translate(50%, 50%) scale(0.9); transition: opacity 200ms ease, transform 250ms var(--ease), background 200ms ease; }
.cinema-player__control .icon { width: 1.5rem; height: 1.5rem; }
.cinema-player:hover .cinema-player__control, .cinema-player:focus-within .cinema-player__control { opacity: 1; transform: translate(50%, 50%) scale(1); }
.cinema-player__control:hover { background: var(--terracotta); }
.cinema-player__caption { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; padding: 1.1rem 0.25rem 0.65rem; }
.cinema-player__caption p { max-width: 80%; margin: 0; color: #f8dfc4; font-family: var(--heading); font-size: 1.35rem; line-height: 1; }
.cinema-player__caption span { color: rgba(255,246,231,0.5); font-family: monospace; font-size: 0.66rem; }
.cinema-player__progress { height: 2px; background: rgba(255,246,231,0.16); }
.cinema-player__progress span { display: block; width: 5.55%; height: 100%; background: #e8aa8d; transition: width 400ms var(--ease); }
.cinema-player__controls { display: flex; align-items: center; gap: 0.75rem; padding-top: 0.75rem; }
.cinema-player__controls .icon-button { width: 2rem; height: 2rem; color: rgba(255,246,231,0.68); border-color: rgba(255,246,231,0.25); }
.cinema-player__controls .icon-button:hover { color: var(--night); background: #e8aa8d; }
.filmstrip { display: flex; flex: 1; gap: 0.5rem; overflow-x: auto; padding: 0.2rem 0.1rem 0.4rem; scrollbar-color: #b8684d transparent; scrollbar-width: thin; }
.filmstrip__item { flex: 0 0 3.7rem; width: 3.7rem; height: 2.65rem; padding: 0; overflow: hidden; background: #302729; border: 1px solid rgba(255,246,231,0.2); cursor: pointer; opacity: 0.5; transition: opacity 180ms ease, border-color 180ms ease, transform 180ms ease; }
.filmstrip__item:hover, .filmstrip__item.is-active { border-color: #e8aa8d; opacity: 1; transform: translateY(-2px); }
.filmstrip__item img { width: 100%; height: 100%; object-fit: cover; }

/* Footer and lightbox */
.site-footer { color: rgba(255,247,232,0.78); background: #33272a; }
.site-footer__main { display: grid; grid-template-columns: 1fr 1.4fr auto; align-items: center; gap: 3rem; padding-top: 3.5rem; padding-bottom: 3.5rem; }
.brand__seal--footer { color: #33272a; background: #f6dfc5; border-color: rgba(246,223,197,0.4); }
.site-footer__message { color: rgba(255,247,232,0.62); font-size: 0.73rem; line-height: 1.6; }
.site-footer__message p { margin-bottom: 0.4rem; }
.back-top { display: inline-flex; align-items: center; gap: 0.5rem; color: #f6dfc5; font-size: 0.7rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
.back-top .icon { transform: rotate(180deg); transition: transform 180ms ease; }.back-top:hover .icon { transform: rotate(180deg) translateY(3px); }
.site-footer__bottom { display: flex; justify-content: space-between; padding-top: 1rem; padding-bottom: 1rem; border-top: 1px solid rgba(255,247,232,0.12); color: rgba(255,247,232,0.4); font-size: 0.61rem; letter-spacing: 0.1em; text-transform: uppercase; }

.lightbox { position: fixed; z-index: 50; inset: 0; display: grid; place-items: center; padding: 4rem clamp(3.5rem, 10vw, 9rem); background: rgba(28,20,20,0.94); opacity: 0; transition: opacity 200ms ease; }
.lightbox:not([hidden]) { display: grid; opacity: 1; }
.lightbox__figure { max-width: min(74rem, 100%); max-height: calc(100vh - 8rem); margin: 0; text-align: center; }
.lightbox__figure img { max-width: 100%; max-height: calc(100vh - 11rem); object-fit: contain; box-shadow: 0 2rem 5rem rgba(0,0,0,0.4); }
.lightbox__figure figcaption { margin-top: 1rem; color: #f8dfc4; font-family: var(--heading); font-size: 1.4rem; line-height: 1.1; }
.lightbox__close, .lightbox__nav { position: absolute; z-index: 1; color: #fff6e7; border-color: rgba(255,246,231,0.55); }
.lightbox__close { top: 1.5rem; right: 1.5rem; }.lightbox__nav { top: 50%; transform: translateY(-50%); }.lightbox__nav:hover { transform: translateY(-50%) scale(1.05); }
.lightbox__nav--prev { left: 1.4rem; }.lightbox__nav--next { right: 1.4rem; }
.lightbox__counter { position: absolute; right: 1.5rem; bottom: 1.4rem; color: rgba(255,246,231,0.58); font-family: monospace; font-size: 0.7rem; }

.reveal { opacity: 0; transform: translateY(18px); transition: opacity 700ms ease, transform 800ms var(--ease); }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

@media (max-width: 980px) {
  .site-nav__links { display: none; }
  .student-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cinema-layout { gap: 3rem; }
  .site-footer__main { grid-template-columns: 1fr 1.4fr; }.back-top { grid-column: 2; }
}

@media (max-width: 720px) {
  .container { width: min(calc(100% - 2rem), var(--container)); }
  .section { padding: 5.6rem 0; }
  .site-nav { top: 1rem; }.nav-cta { display: none; }
  .brand__seal { width: 2.45rem; height: 2.45rem; }.brand strong { font-size: 1.05rem; }
  .hero__content { padding-top: 6.5rem; }.hero__title { font-size: clamp(3.7rem, 17vw, 6rem); line-height: 0.82; }
  .hero__subtitle { font-size: 0.78rem; }.hero__scroll { right: 0.65rem; bottom: 1rem; }
  .hero__leaf--one { top: 29%; right: -4rem; }.hero__leaf--two { left: 4%; bottom: 8%; }
  .section-heading--split { display: block; }.section-heading--split .section-heading__lead { margin-top: 1.6rem; }
  h2 { font-size: clamp(3rem, 14vw, 4.8rem); }
  .letter-card { margin-top: 3.2rem; }.letter-card__content { padding: 1.3rem; }.letter-card__content::after { inset: 0.6rem; }
  .letter-card__topline { font-size: 0.52rem; }.letter-card__body { display: flex; flex-direction: column; gap: 2.2rem; padding: 2rem 0.7rem 1.7rem; }
  .letter-card__copy { font-size: 1.2rem; }.letter-card__photo { width: min(70%, 15rem); margin: 0 auto; }
  .letter-card__corner { width: 3.8rem; height: 3.8rem; }.letter-card__corner--tl { top: 0.85rem; left: 0.85rem; }.letter-card__corner--br { right: 0.85rem; bottom: 0.85rem; }
  .wall-meta { align-items: start; flex-direction: column; gap: 1rem; margin-top: 2.4rem; }.wall-meta__count strong { font-size: 3.3rem; }
  .student-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.7rem; }.flip-card, .flip-card__inner { min-height: 14rem; }.flip-card__face { padding: 0.95rem; }.flip-card__name { font-size: 1.18rem; }.flip-card__back-title { font-size: 1.25rem; }.flip-card__message { font-size: 0.98rem; }
  .gallery-grid { columns: 2; column-gap: 0.7rem; margin-top: 2.7rem; }.gallery-card { margin-bottom: 0.7rem; }.gallery-card__caption { padding: 2rem 0.65rem 0.65rem; font-size: 1rem; }
  .cinema-layout { display: flex; flex-direction: column; align-items: stretch; gap: 2.6rem; }.cinema-copy { max-width: none; }.cinema-copy h2 { font-size: clamp(3.3rem, 15vw, 5rem); }
  .cinema-player { padding: 0.45rem; }.cinema-player__caption { padding-inline: 0.35rem; }.cinema-player__caption p { font-size: 1.15rem; }
  .site-footer__main { display: flex; align-items: start; flex-direction: column; gap: 1.7rem; padding-top: 2.8rem; padding-bottom: 2.8rem; }.back-top { margin-top: 0.4rem; }.site-footer__bottom { gap: 1rem; flex-direction: column; }
  .lightbox { padding: 4rem 2.5rem; }.lightbox__nav--prev { left: 0.6rem; }.lightbox__nav--next { right: 0.6rem; }.lightbox__close { top: 1rem; right: 1rem; }
}

@media (max-width: 390px) {
  .student-grid { gap: 0.55rem; }.flip-card, .flip-card__inner { min-height: 13.5rem; }.flip-card__face { padding: 0.78rem; }.flip-card__number, .flip-card__instruction { font-size: 0.53rem; }.flip-card__name { font-size: 1.08rem; }.flip-card__back-title { font-size: 1.12rem; }.flip-card__message { font-size: 0.9rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .reveal, .hero__title-line { opacity: 1; transform: none; }
  .hero__scroll .icon { animation: none; }
  .flip-card:hover .flip-card__inner { transform: none; }
  .flip-card.is-flipped .flip-card__inner { transform: rotateY(180deg); }
}
