:root {
  --cream: #f6efe5;
  --paper: #fffaf2;
  --rose: #d8a3a8;
  --blush: #edcbca;
  --dusty-rose: #9b4d5d;
  --burgundy: #5f1730;
  --burgundy-dark: #350b1d;
  --ink: #2d2022;
  --muted: #755f62;
  --gold: #bd8a57;
  --line: rgba(95, 23, 48, 0.17);
  --shadow: 0 24px 70px rgba(53, 11, 29, 0.15);
  --serif: Georgia, "Times New Roman", Times, serif;
  --sans: "Trebuchet MS", "Segoe UI", Arial, sans-serif;
  --script: "Segoe Script", "Bradley Hand", "Brush Script MT", cursive;
  --shell: min(1180px, calc(100vw - 48px));
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

body {
  margin: 0;
  overflow-x: hidden;
  color: var(--ink);
  background:
    radial-gradient(circle at 15% 24%, rgba(216, 163, 168, 0.14), transparent 25rem),
    radial-gradient(circle at 85% 62%, rgba(189, 138, 87, 0.08), transparent 28rem),
    var(--cream);
  font-family: var(--sans);
  line-height: 1.65;
  text-rendering: optimizeLegibility;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: 50;
  pointer-events: none;
  opacity: 0.18;
  content: "";
  background-image:
    repeating-linear-gradient(0deg, transparent, transparent 3px, rgba(72, 39, 40, 0.025) 3px, rgba(72, 39, 40, 0.025) 4px),
    repeating-linear-gradient(90deg, transparent, transparent 5px, rgba(72, 39, 40, 0.018) 5px, rgba(72, 39, 40, 0.018) 6px);
}

body:has(dialog[open]) {
  overflow: hidden;
}

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

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

button {
  font: inherit;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 3px solid #e9ac3e;
  outline-offset: 4px;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 200;
  padding: 10px 15px;
  border-radius: 999px;
  color: var(--paper);
  background: var(--burgundy-dark);
  font-weight: 700;
  transform: translateY(-180%);
  transition: transform 180ms ease;
}

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

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

.section-shell {
  width: var(--shell);
  margin-inline: auto;
}

.section-kicker,
.eyebrow {
  margin: 0 0 18px;
  color: var(--dusty-rose);
  font-size: 0.71rem;
  font-weight: 800;
  letter-spacing: 0.19em;
  line-height: 1.4;
  text-transform: uppercase;
}

.section-kicker::before {
  display: inline-block;
  width: 34px;
  height: 1px;
  margin: 0 10px 3px 0;
  background: currentColor;
  content: "";
}

h1,
h2,
h3,
p {
  text-wrap: pretty;
}

h1,
h2,
h3 {
  font-family: var(--serif);
  font-weight: 400;
  line-height: 0.98;
}

h2 {
  margin: 0;
  color: var(--burgundy);
  font-size: clamp(3rem, 7vw, 6.6rem);
  letter-spacing: -0.055em;
}

h2 em,
h3 em {
  color: var(--dusty-rose);
  font-family: var(--script);
  font-weight: 400;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 22px clamp(22px, 4vw, 64px);
  color: var(--paper);
  transition:
    color 260ms ease,
    background-color 260ms ease,
    padding 260ms ease,
    box-shadow 260ms ease;
}

.site-header.is-scrolled {
  padding-block: 12px;
  color: var(--burgundy);
  background: rgba(246, 239, 229, 0.91);
  box-shadow: 0 1px 0 var(--line);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
}

.wordmark {
  display: flex;
  align-items: baseline;
  gap: 6px;
  color: inherit;
  font-family: var(--serif);
  font-size: 1.8rem;
  line-height: 1;
  text-decoration: none;
}

.wordmark-small {
  font-family: var(--sans);
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.site-header nav {
  display: flex;
  gap: clamp(18px, 3vw, 42px);
}

.site-header nav a {
  position: relative;
  color: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
}

.site-header nav a::after {
  position: absolute;
  right: 0;
  bottom: -7px;
  left: 0;
  height: 1px;
  background: currentColor;
  content: "";
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 200ms ease;
}

.site-header nav a:hover::after,
.site-header nav a:focus-visible::after {
  transform: scaleX(1);
  transform-origin: left;
}

.hero {
  position: relative;
  min-height: 100svh;
  overflow: hidden;
  color: var(--paper);
  background: #261517;
  isolation: isolate;
}

.hero-media,
.hero-shade,
.hero-grain {
  position: absolute;
  inset: 0;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 52%;
  filter: saturate(0.8) contrast(1.04) brightness(0.82);
  transform: scale(1.025);
}

.hero-shade {
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(34, 9, 20, 0.9) 0%, rgba(49, 12, 27, 0.6) 38%, rgba(49, 12, 27, 0.17) 67%, rgba(18, 8, 12, 0.31) 100%),
    linear-gradient(0deg, rgba(25, 9, 15, 0.61) 0%, transparent 38%, rgba(18, 8, 12, 0.18) 100%);
}

.hero-grain {
  z-index: 2;
  opacity: 0.36;
  mix-blend-mode: soft-light;
  background-image:
    repeating-radial-gradient(circle at 10% 30%, rgba(255, 255, 255, 0.16) 0 1px, transparent 1px 4px),
    repeating-linear-gradient(145deg, transparent 0 7px, rgba(255, 255, 255, 0.035) 7px 8px);
}

.hero-content {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: min(780px, calc(100% - 48px));
  min-height: 100svh;
  margin-left: clamp(24px, 8vw, 130px);
  padding: 124px 0 130px;
}

.hero .eyebrow {
  color: var(--blush);
}

.hero h1 {
  max-width: 750px;
  margin: 0;
  font-size: clamp(4.4rem, 11vw, 10.8rem);
  letter-spacing: -0.075em;
  line-height: 0.79;
  text-shadow: 0 10px 40px rgba(21, 4, 12, 0.25);
}

.hero h1 em {
  display: block;
  margin-top: 0.13em;
  color: #f3c4c7;
  font-family: var(--script);
  font-size: 0.63em;
  font-weight: 400;
  letter-spacing: -0.04em;
  line-height: 1;
  transform: rotate(-3deg);
  transform-origin: left center;
}

.hero-intro {
  max-width: 540px;
  margin: 36px 0 0;
  color: rgba(255, 250, 242, 0.86);
  font-family: var(--serif);
  font-size: clamp(1rem, 1.6vw, 1.35rem);
  font-style: italic;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 28px;
  margin-top: 36px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0 24px;
  border: 1px solid currentColor;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-decoration: none;
  text-transform: uppercase;
  transition:
    color 180ms ease,
    background-color 180ms ease,
    transform 180ms ease;
}

.button-light {
  color: var(--burgundy-dark);
  border-color: var(--paper);
  background: var(--paper);
}

.button:hover {
  transform: translateY(-2px);
}

.button-light:hover {
  color: var(--paper);
  background: transparent;
}

.text-link {
  color: var(--paper);
  font-size: 0.77rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-underline-offset: 6px;
  text-transform: uppercase;
}

.hero-stamp {
  position: absolute;
  right: clamp(26px, 6vw, 90px);
  bottom: clamp(84px, 12vh, 145px);
  z-index: 3;
  display: grid;
  width: 132px;
  aspect-ratio: 1;
  place-content: center;
  margin: 0;
  border: 1px solid rgba(255, 250, 242, 0.58);
  border-radius: 50%;
  color: rgba(255, 250, 242, 0.9);
  font-family: var(--serif);
  font-size: 0.74rem;
  font-style: italic;
  line-height: 1.5;
  text-align: center;
  transform: rotate(8deg);
}

.hero-stamp::before,
.hero-stamp::after {
  position: absolute;
  inset: 7px;
  border: 1px dashed rgba(255, 250, 242, 0.35);
  border-radius: 50%;
  content: "";
}

.hero-stamp::after {
  inset: -7px;
  border-style: dotted;
}

.hero-stamp span {
  display: block;
}

.scroll-cue {
  position: absolute;
  bottom: 28px;
  left: clamp(24px, 8vw, 130px);
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 15px;
  color: rgba(255, 250, 242, 0.7);
  font-size: 0.63rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-decoration: none;
  text-transform: uppercase;
}

.scroll-line {
  display: block;
  width: 70px;
  height: 1px;
  overflow: hidden;
  background: rgba(255, 250, 242, 0.36);
}

.scroll-line::after {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--paper);
  content: "";
  animation: scroll-line 2.2s ease-in-out infinite;
}

@keyframes scroll-line {
  0% { transform: translateX(-110%); }
  55%, 100% { transform: translateX(110%); }
}

.opening {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.55fr);
  gap: clamp(60px, 10vw, 150px);
  align-items: center;
  padding-block: clamp(110px, 15vw, 210px);
}

.opening-copy h2 {
  max-width: 780px;
}

.opening-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  max-width: 770px;
  margin-top: 46px;
  color: var(--muted);
  font-size: 0.98rem;
}

.opening-body p {
  margin: 0;
}

.dropcap::first-letter {
  float: left;
  margin: 4px 8px 0 0;
  color: var(--burgundy);
  font-family: var(--serif);
  font-size: 4.3rem;
  line-height: 0.72;
}

.opening-polaroid {
  position: relative;
  width: min(100%, 390px);
  margin: 0 auto;
  padding: 13px 13px 42px;
  background: var(--paper);
  box-shadow: var(--shadow);
  transform: rotate(3deg);
}

.opening-polaroid::before {
  position: absolute;
  top: -22px;
  left: 50%;
  z-index: 2;
  width: 100px;
  height: 36px;
  background: rgba(222, 191, 160, 0.67);
  box-shadow: 0 1px 4px rgba(50, 30, 30, 0.1);
  content: "";
  transform: translateX(-50%) rotate(-3deg);
}

.opening-polaroid button {
  width: 100%;
  aspect-ratio: 0.82;
}

.opening-polaroid img {
  object-position: center 42%;
}

.opening-polaroid figcaption {
  position: absolute;
  right: 20px;
  bottom: 10px;
  left: 20px;
  color: var(--burgundy);
  font-family: var(--script);
  font-size: 1rem;
  text-align: center;
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.36fr);
  column-gap: clamp(40px, 9vw, 130px);
  align-items: end;
  margin-bottom: 100px;
}

.section-heading .section-kicker {
  grid-column: 1 / -1;
}

.section-heading > p:last-child {
  max-width: 360px;
  margin: 0 0 7px;
  color: var(--muted);
}

.chapters {
  padding-bottom: clamp(120px, 16vw, 220px);
}

.chapter {
  position: relative;
  display: grid;
  grid-template-columns: minmax(260px, 0.58fr) minmax(0, 1.15fr);
  gap: clamp(52px, 9vw, 130px);
  padding-block: clamp(90px, 12vw, 150px);
  border-top: 1px solid var(--line);
}

.chapter-copy {
  position: sticky;
  top: 130px;
  align-self: start;
  padding-top: 34px;
}

.chapter-number {
  position: absolute;
  top: -30px;
  left: -18px;
  z-index: -1;
  color: rgba(216, 163, 168, 0.17);
  font-family: var(--serif);
  font-size: clamp(6rem, 11vw, 10.5rem);
  line-height: 1;
}

.chapter-label {
  margin: 0 0 16px;
  color: var(--dusty-rose);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.chapter h3 {
  margin: 0 0 28px;
  color: var(--burgundy);
  font-size: clamp(2.5rem, 5vw, 4.6rem);
  letter-spacing: -0.04em;
}

.chapter-copy > p:not(.chapter-label) {
  max-width: 390px;
  margin: 0;
  color: var(--muted);
}

.chapter-scribble {
  display: block;
  margin: 35px 0 0 18px;
  color: var(--dusty-rose);
  font-family: var(--script);
  font-size: 1rem;
  transform: rotate(-4deg);
}

.chapter-scribble::before {
  display: inline-block;
  width: 35px;
  height: 16px;
  margin-right: 8px;
  border-bottom: 1px solid currentColor;
  border-radius: 50%;
  content: "";
  transform: rotate(-9deg);
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(24px, 4vw, 48px);
  align-items: start;
}

.photo-card {
  position: relative;
  margin: 0;
  padding: 11px 11px 42px;
  background: var(--paper);
  box-shadow: 0 18px 46px rgba(60, 25, 36, 0.13);
  transition:
    box-shadow 220ms ease,
    transform 220ms ease;
}

.photo-card:hover {
  box-shadow: 0 26px 65px rgba(60, 25, 36, 0.2);
  transform: translateY(-5px) rotate(0deg);
}

.photo-card.rotate-left {
  transform: rotate(-2.4deg);
}

.photo-card.rotate-right {
  transform: rotate(2.2deg);
}

.photo-card.rotate-left:hover,
.photo-card.rotate-right:hover {
  transform: translateY(-5px) rotate(0deg);
}

.gallery-item {
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  background: #e8ddd3;
  cursor: zoom-in;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 500ms cubic-bezier(0.2, 0.6, 0.2, 1);
}

.gallery-item:hover img {
  transform: scale(1.025);
}

.photo-card .gallery-item {
  aspect-ratio: 0.78;
}

.photo-card figcaption {
  position: absolute;
  right: 16px;
  bottom: 9px;
  left: 16px;
  overflow: hidden;
  color: var(--burgundy);
  font-family: var(--script);
  font-size: 0.86rem;
  line-height: 1.4;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.wide-card {
  grid-column: 1 / -1;
  width: 86%;
  justify-self: center;
}

.wide-card .gallery-item {
  aspect-ratio: 1.34;
}

.wide-card img {
  object-position: center 46%;
}

.portrait-card {
  margin-top: 90px;
}

.square-card .gallery-item {
  aspect-ratio: 1;
}

.candle-card {
  width: 78%;
}

.candle-card .gallery-item {
  aspect-ratio: 1.42;
}

.hero-card {
  grid-row: span 2;
}

.hero-card .gallery-item {
  aspect-ratio: 0.72;
}

.small-card {
  width: 88%;
  justify-self: center;
}

.small-card .gallery-item {
  aspect-ratio: 0.78;
}

.collage-card {
  margin-top: 70px;
}

.contain-image img {
  object-fit: contain;
  background: #fbf6e9;
}

.quiet-card {
  width: 76%;
}

.quiet-card .gallery-item {
  aspect-ratio: 1.18;
}

.films {
  position: relative;
  overflow: hidden;
  padding-block: clamp(110px, 15vw, 190px);
  color: var(--paper);
  background:
    radial-gradient(circle at 18% 18%, rgba(216, 163, 168, 0.19), transparent 30rem),
    radial-gradient(circle at 90% 72%, rgba(189, 138, 87, 0.12), transparent 26rem),
    var(--burgundy-dark);
}

.films::before {
  position: absolute;
  top: -7vw;
  right: -2vw;
  width: 30vw;
  min-width: 270px;
  aspect-ratio: 1;
  border: 1px solid rgba(246, 239, 229, 0.1);
  border-radius: 50%;
  box-shadow:
    0 0 0 40px rgba(246, 239, 229, 0.025),
    0 0 0 85px rgba(246, 239, 229, 0.018);
  content: "";
}

.films-heading {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(260px, 0.6fr);
  gap: 60px;
  align-items: end;
  margin-bottom: 95px;
}

.section-kicker-light {
  color: var(--blush);
}

.films h2 {
  color: var(--paper);
}

.films h2 em {
  color: var(--blush);
}

.films-heading > p {
  max-width: 380px;
  margin: 0 0 8px;
  color: rgba(255, 250, 242, 0.69);
}

.film-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(22px, 3vw, 42px);
  align-items: start;
}

.film-card {
  margin: 0;
}

.film-card-raised {
  margin-top: -45px;
}

.film-frame {
  position: relative;
  padding: 8px;
  border: 1px solid rgba(255, 250, 242, 0.2);
  background: rgba(255, 250, 242, 0.07);
  box-shadow: 0 30px 80px rgba(10, 2, 7, 0.3);
}

.film-frame video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #16080e;
  object-fit: contain;
}

.film-index {
  position: absolute;
  top: -20px;
  left: -9px;
  z-index: 2;
  display: grid;
  width: 46px;
  aspect-ratio: 1;
  place-items: center;
  border-radius: 50%;
  color: var(--burgundy-dark);
  background: var(--blush);
  font-family: var(--serif);
  font-size: 0.78rem;
}

.film-card figcaption {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 6px 0;
}

.film-card figcaption span:first-child {
  color: var(--blush);
  font-family: var(--serif);
  font-style: italic;
}

.film-card figcaption span:last-child {
  color: rgba(255, 250, 242, 0.57);
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  text-align: right;
}

.hopes {
  padding-block: clamp(110px, 16vw, 210px);
}

.hopes-heading {
  display: block;
  max-width: 900px;
  margin-bottom: 80px;
}

.hope-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.hope-card {
  position: relative;
  min-height: 330px;
  padding: 48px clamp(25px, 3.2vw, 48px);
}

.hope-card + .hope-card {
  border-left: 1px solid var(--line);
}

.hope-number {
  color: var(--dusty-rose);
  font-family: var(--serif);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
}

.hope-icon {
  position: absolute;
  top: 40px;
  right: 38px;
  color: rgba(166, 91, 104, 0.45);
  font-size: 1.4rem;
}

.hope-card h3 {
  max-width: 250px;
  margin: 70px 0 22px;
  color: var(--burgundy);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  line-height: 1.05;
}

.hope-card p {
  max-width: 290px;
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.love-note {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 0.7fr);
  gap: clamp(60px, 12vw, 170px);
  align-items: center;
  padding-bottom: clamp(140px, 17vw, 230px);
}

.note-copy p:last-child {
  max-width: 370px;
  margin: 34px 0 0;
  color: var(--muted);
}

.envelope {
  position: relative;
  width: min(100%, 500px);
  aspect-ratio: 1.45;
  margin: 65px auto 0;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  perspective: 900px;
}

.envelope-back,
.envelope-front,
.envelope-flap {
  position: absolute;
  inset: 0;
  display: block;
  filter: drop-shadow(0 24px 28px rgba(73, 29, 42, 0.16));
}

.envelope-back {
  background: #c9848f;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
}

.letter-preview {
  position: absolute;
  top: -18%;
  right: 8%;
  bottom: 12%;
  left: 8%;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 38px 36px;
  color: var(--burgundy);
  background: var(--paper);
  box-shadow: 0 7px 30px rgba(56, 16, 31, 0.13);
  font-family: var(--script);
  text-align: left;
  transform: translateY(30%);
  transition: transform 500ms cubic-bezier(0.2, 0.75, 0.2, 1);
}

.letter-preview span:first-child {
  font-family: var(--serif);
  font-size: clamp(1.8rem, 4vw, 3rem);
}

.letter-preview span:last-child {
  align-self: flex-end;
  color: var(--dusty-rose);
  font-size: 1.1rem;
}

.envelope-front {
  z-index: 2;
  background: linear-gradient(145deg, #d898a1, #bd717e);
  clip-path: polygon(0 0, 50% 55%, 100% 0, 100% 100%, 0 100%);
}

.envelope-flap {
  z-index: 3;
  background: #e0a3aa;
  clip-path: polygon(0 0, 100% 0, 50% 58%);
  transform-origin: top;
  transition: transform 500ms cubic-bezier(0.2, 0.75, 0.2, 1);
}

.wax-seal {
  position: absolute;
  top: 46%;
  left: 50%;
  z-index: 4;
  display: grid;
  width: 58px;
  aspect-ratio: 1;
  place-items: center;
  border: 4px double rgba(255, 238, 221, 0.34);
  border-radius: 47% 53% 48% 52%;
  color: rgba(255, 238, 221, 0.8);
  background: var(--burgundy);
  box-shadow: 0 6px 10px rgba(53, 11, 29, 0.2);
  font-family: var(--serif);
  font-size: 1.3rem;
  transform: translate(-50%, -50%) rotate(-8deg);
  transition: opacity 180ms ease;
}

.envelope:hover .letter-preview,
.envelope:focus-visible .letter-preview {
  transform: translateY(8%);
}

.envelope:hover .envelope-flap,
.envelope:focus-visible .envelope-flap {
  transform: rotateX(18deg);
}

footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  padding: 34px clamp(24px, 6vw, 90px);
  color: rgba(255, 250, 242, 0.76);
  background: var(--burgundy-dark);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

footer p {
  margin: 0;
}

footer a {
  text-underline-offset: 5px;
}

.heart-button {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 70;
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 15px;
  border: 1px solid rgba(255, 250, 242, 0.32);
  border-radius: 999px;
  color: var(--paper);
  background: rgba(95, 23, 48, 0.92);
  box-shadow: 0 10px 30px rgba(53, 11, 29, 0.25);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  cursor: pointer;
  transition:
    transform 180ms ease,
    background-color 180ms ease;
}

.heart-button:hover {
  background: var(--burgundy-dark);
  transform: translateY(-2px);
}

.heart-button span:first-child {
  font-size: 1.4rem;
  line-height: 1;
}

.heart-button span:last-child {
  font-size: 0.63rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.floating-heart {
  position: fixed;
  z-index: 300;
  color: var(--heart-color, #d88793);
  font-size: var(--heart-size, 18px);
  pointer-events: none;
  animation: float-heart 1.1s cubic-bezier(0.15, 0.7, 0.35, 1) forwards;
}

@keyframes float-heart {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.5) rotate(0deg);
  }
  15% { opacity: 1; }
  100% {
    opacity: 0;
    transform: translate(calc(-50% + var(--heart-x)), calc(-50% + var(--heart-y))) scale(1.15) rotate(var(--heart-r));
  }
}

dialog {
  max-width: none;
  max-height: none;
  margin: auto;
  padding: 0;
  border: 0;
  color: inherit;
  background: transparent;
}

dialog::backdrop {
  background: rgba(31, 6, 17, 0.78);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.letter-dialog {
  width: min(690px, calc(100vw - 28px));
}

.letter-paper {
  position: relative;
  max-height: min(820px, calc(100vh - 36px));
  overflow-y: auto;
  padding: clamp(44px, 8vw, 85px);
  color: var(--ink);
  background:
    linear-gradient(rgba(122, 69, 73, 0.055) 1px, transparent 1px) 0 56px / 100% 30px,
    var(--paper);
  box-shadow: 0 40px 100px rgba(15, 2, 8, 0.45);
}

.letter-paper::before,
.letter-paper::after {
  position: absolute;
  width: 120px;
  height: 34px;
  background: rgba(224, 200, 168, 0.58);
  content: "";
}

.letter-paper::before {
  top: 12px;
  left: -25px;
  transform: rotate(-36deg);
}

.letter-paper::after {
  right: -25px;
  bottom: 12px;
  transform: rotate(-36deg);
}

.dialog-close,
.lightbox-close {
  position: absolute;
  top: 16px;
  right: 18px;
  z-index: 3;
  display: grid;
  width: 42px;
  aspect-ratio: 1;
  padding: 0;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 50%;
  color: var(--burgundy);
  background: transparent;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
}

.letter-date {
  margin: 0 0 26px;
  color: var(--dusty-rose);
  font-size: 0.67rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.letter-paper h2 {
  margin: 0 0 38px;
  font-family: var(--script);
  font-size: clamp(2.8rem, 7vw, 4.7rem);
  letter-spacing: -0.03em;
}

.letter-body {
  color: #4d393c;
  font-family: var(--serif);
  font-size: 1.05rem;
  line-height: 1.85;
}

.letter-body p {
  margin: 0 0 23px;
}

.letter-signoff {
  padding-top: 12px;
  color: var(--burgundy);
  font-family: var(--script);
  font-size: 1.3rem;
  line-height: 1.55;
}

.letter-signoff span {
  color: var(--dusty-rose);
}

.lightbox {
  width: 100vw;
  height: 100vh;
}

.lightbox-shell {
  position: relative;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) 64px;
  align-items: center;
  width: 100%;
  height: 100%;
  padding: 30px;
}

.lightbox figure {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 18px;
  width: 100%;
  height: 100%;
  margin: 0;
  min-height: 0;
}

.lightbox img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
}

.lightbox figcaption {
  min-height: 28px;
  color: var(--paper);
  font-family: var(--serif);
  font-size: 1rem;
  font-style: italic;
  text-align: center;
}

.lightbox-close {
  position: fixed;
  color: var(--paper);
}

.lightbox-nav {
  display: grid;
  width: 48px;
  aspect-ratio: 1;
  padding: 0;
  place-items: center;
  border: 1px solid rgba(255, 250, 242, 0.5);
  border-radius: 50%;
  color: var(--paper);
  background: rgba(255, 255, 255, 0.04);
  font-size: 1.25rem;
  cursor: pointer;
}

.lightbox-prev {
  justify-self: start;
}

.lightbox-next {
  justify-self: end;
}

.js .reveal {
  opacity: 0;
  translate: 0 28px;
  transition:
    opacity 760ms ease,
    translate 760ms cubic-bezier(0.2, 0.75, 0.2, 1);
}

.js .reveal.is-visible {
  opacity: 1;
  translate: 0 0;
}

@media (max-width: 900px) {
  :root {
    --shell: min(100% - 36px, 720px);
  }

  .hero-content {
    width: calc(100% - 40px);
    margin-left: 24px;
  }

  .hero-media img {
    object-position: 50% 52%;
  }

  .hero-shade {
    background:
      linear-gradient(0deg, rgba(37, 8, 20, 0.9) 0%, rgba(37, 8, 20, 0.43) 64%, rgba(18, 8, 12, 0.34) 100%),
      linear-gradient(90deg, rgba(37, 8, 20, 0.45), transparent 85%);
  }

  .hero-stamp {
    display: none;
  }

  .scroll-cue {
    left: 24px;
  }

  .opening {
    grid-template-columns: 1fr;
  }

  .opening-polaroid {
    width: min(86%, 390px);
  }

  .section-heading {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .section-heading > p:last-child {
    margin: 0;
  }

  .chapter {
    grid-template-columns: 1fr;
    gap: 62px;
  }

  .chapter-copy {
    position: relative;
    top: auto;
    padding-right: 10%;
  }

  .chapter-copy > p:not(.chapter-label) {
    max-width: 620px;
  }

  .films-heading {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .film-grid {
    grid-template-columns: 1fr;
    width: min(100%, 680px);
    margin-inline: auto;
  }

  .film-card,
  .film-card-raised {
    margin-top: 0;
  }

  .hope-grid {
    grid-template-columns: 1fr;
  }

  .hope-card {
    min-height: 250px;
  }

  .hope-card + .hope-card {
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .love-note {
    grid-template-columns: 1fr;
  }

  .envelope {
    width: min(82%, 500px);
  }
}

@media (max-width: 620px) {
  :root {
    --shell: calc(100% - 28px);
  }

  html {
    scroll-padding-top: 74px;
  }

  .site-header {
    padding: 16px 18px;
  }

  .site-header nav {
    gap: 14px;
  }

  .site-header nav a:nth-child(2) {
    display: none;
  }

  .site-header nav a {
    font-size: 0.62rem;
  }

  .hero {
    min-height: 720px;
  }

  .hero-content {
    justify-content: flex-end;
    min-height: 720px;
    padding: 120px 0 128px;
  }

  .hero h1 {
    font-size: clamp(4rem, 23vw, 7.2rem);
  }

  .hero-intro {
    max-width: 310px;
    margin-top: 28px;
    font-size: 1rem;
  }

  .hero-actions {
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 28px;
  }

  .button {
    min-height: 46px;
    padding-inline: 19px;
  }

  .scroll-cue span:first-child {
    display: none;
  }

  .opening {
    gap: 80px;
  }

  .opening-body {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .section-heading {
    margin-bottom: 62px;
  }

  .chapter {
    padding-block: 82px;
  }

  .chapter-copy {
    padding-right: 0;
  }

  .photo-grid {
    gap: 20px 14px;
  }

  .photo-card {
    padding: 7px 7px 34px;
  }

  .photo-card figcaption {
    right: 8px;
    bottom: 8px;
    left: 8px;
    font-size: 0.72rem;
  }

  .portrait-card {
    margin-top: 54px;
  }

  .wide-card,
  .candle-card,
  .quiet-card {
    width: 92%;
  }

  .collage-card {
    margin-top: 42px;
  }

  .films {
    padding-block: 100px;
  }

  .film-card figcaption {
    flex-direction: column;
    gap: 4px;
  }

  .film-card figcaption span:last-child {
    text-align: left;
  }

  .hopes-heading {
    margin-bottom: 55px;
  }

  .hope-card {
    min-height: 0;
    padding-block: 38px 46px;
  }

  .hope-card h3 {
    margin-top: 48px;
  }

  .envelope {
    width: 96%;
  }

  .letter-preview {
    padding: 28px 24px;
  }

  footer {
    flex-direction: column;
    align-items: flex-start;
    padding-bottom: 90px;
  }

  .heart-button span:last-child {
    display: none;
  }

  .heart-button {
    width: 48px;
    min-height: 48px;
    padding: 0;
    justify-content: center;
  }

  .lightbox-shell {
    grid-template-columns: 44px minmax(0, 1fr) 44px;
    padding: 60px 8px 20px;
  }

  .lightbox-nav {
    width: 38px;
  }

  .letter-paper {
    padding: 62px 27px 48px;
  }
}

@media (max-width: 430px) {
  .site-header nav a:nth-child(3) {
    display: none;
  }

  .hero h1 {
    font-size: clamp(3.6rem, 19vw, 4.7rem);
  }

  .hero-stamp {
    right: 20px;
    width: 108px;
    font-size: 0.66rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .hero-media img {
    transform: none;
  }

  .js .reveal {
    opacity: 1;
    translate: none;
  }
}
