@import url("https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Playfair+Display:ital,wght@0,500;0,600;0,700;1,500;1,600&display=swap");

:root {
  color-scheme: light;
  font-family: "DM Sans", "Segoe UI", sans-serif;
  background: #fff0cf;
  color: #3b1944;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  --paper: #fff0cf;
  --paper-light: #fff8e9;
  --ink: #3b1944;
  --pink: #dc4163;
  --pink-dark: #b93053;
  --orange: #f09a2e;
  --yellow: #ffd35c;
  --teal: #237b73;
  --green: #41835b;
  --serif: "Playfair Display", Georgia, "Times New Roman", serif;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(ellipse at 86% 22%, rgb(240 154 46 / 12%), transparent 29rem),
    radial-gradient(ellipse at 5% 80%, rgb(220 65 99 / 9%), transparent 31rem),
    #fff0cf;
}

button,
a {
  font: inherit;
}

button {
  color: inherit;
}

.experience {
  position: relative;
  display: flex;
  min-height: 100svh;
  flex-direction: column;
  overflow: hidden;
  padding: 0 clamp(22px, 7vw, 106px);
  isolation: isolate;
}

.grain {
  position: fixed;
  z-index: -1;
  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='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' opacity='.18' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.13;
  pointer-events: none;
}

.glow {
  position: absolute;
  z-index: -1;
  width: 440px;
  height: 440px;
  border: 1px solid rgb(59 25 68 / 8%);
  border-radius: 50%;
  box-shadow: 0 0 0 18px rgb(220 65 99 / 3%), 0 0 0 38px rgb(240 154 46 / 3%);
  pointer-events: none;
}

.glow-one {
  top: 11%;
  right: -310px;
}

.glow-two {
  bottom: -340px;
  left: -250px;
  width: 500px;
  height: 500px;
}

.rangoli {
  position: absolute;
  z-index: -1;
  width: 145px;
  aspect-ratio: 1;
  border: 2px solid rgb(35 123 115 / 24%);
  border-radius: 50%;
  background:
    radial-gradient(ellipse at center, transparent 26%, rgb(220 65 99 / 20%) 27% 28%, transparent 29%),
    repeating-conic-gradient(from 0deg, transparent 0deg 14deg, rgb(240 154 46 / 43%) 14deg 17deg, transparent 17deg 30deg);
  opacity: 0.67;
  pointer-events: none;
}

.rangoli::before,
.rangoli::after {
  position: absolute;
  border: 2px solid rgb(59 25 68 / 22%);
  border-radius: 50%;
  content: "";
}

.rangoli::before {
  inset: 15px;
}

.rangoli::after {
  inset: 29px;
  background: radial-gradient(circle, rgb(255 211 92 / 75%) 0 3px, transparent 4px);
}

.rangoli-left {
  top: 22%;
  left: -96px;
  transform: rotate(12deg);
}

.rangoli-right {
  right: -94px;
  bottom: 17%;
  width: 180px;
  transform: rotate(-15deg);
}

.topbar {
  position: relative;
  z-index: 3;
  display: flex;
  min-height: 78px;
  align-items: center;
  justify-content: space-between;
  border-bottom: 2px solid rgb(59 25 68 / 13%);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-decoration: none;
}

.wordmark i {
  color: var(--pink);
  font-style: normal;
}

.wordmark-icon {
  display: grid;
  width: 35px;
  height: 35px;
  place-items: center;
  border: 2px solid var(--pink);
  border-radius: 50%;
  background: var(--yellow);
  box-shadow: 3px 3px 0 var(--ink);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.05rem;
  font-weight: 700;
}

.topbar-note {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #765d69;
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.17em;
}

.status-dot {
  width: 8px;
  height: 8px;
  border: 1px solid var(--ink);
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 3px rgb(65 131 91 / 15%);
}

.home {
  display: grid;
  width: min(100%, 1180px);
  flex: 1;
  grid-template-columns: minmax(0, 0.96fr) minmax(0, 1.04fr);
  align-items: center;
  gap: clamp(24px, 5vw, 80px);
  margin: 0 auto;
  padding: 45px 0 55px;
}

.hero-copy {
  position: relative;
  z-index: 1;
  padding: 5px 0 15px;
  animation: copy-appear 750ms 100ms both;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 11px;
  margin: 0 0 25px;
  color: var(--teal);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  line-height: 1.6;
  text-transform: uppercase;
}

.eyebrow-line {
  width: 25px;
  height: 3px;
  background: var(--orange);
}

h1,
h2 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 700;
}

h1 {
  color: var(--ink);
  font-size: clamp(2.65rem, 5.3vw, 5.3rem);
  letter-spacing: -0.045em;
  line-height: 1.07;
}

h1 em {
  color: var(--pink);
  font-weight: 700;
}

.hero-note {
  margin: 25px 0 0;
  color: #725b66;
  font-size: 0.92rem;
  line-height: 1.9;
}

.hero-note span {
  color: var(--pink-dark);
  font-family: var(--serif);
  font-size: 1.13rem;
  font-style: italic;
  font-weight: 700;
}

.hero-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 30px;
  color: var(--ink);
  font-size: 0.63rem;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.meta-star {
  color: var(--orange);
  font-size: 0.85rem;
}

.open-prompt {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 61px;
  color: #765d69;
  font-family: var(--serif);
  font-size: 0.83rem;
  font-style: italic;
  line-height: 1.45;
}

.prompt-arrow {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 2px solid var(--teal);
  border-radius: 50%;
  background: var(--paper-light);
  box-shadow: 3px 3px 0 var(--teal);
  color: var(--teal);
  font-family: "DM Sans", sans-serif;
  font-size: 1rem;
  font-style: normal;
}

.letter-scene {
  position: relative;
  display: flex;
  min-height: 570px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  animation: scene-appear 900ms 160ms both;
}

.scene-halo {
  position: absolute;
  top: 55%;
  left: 50%;
  width: min(75vw, 450px);
  aspect-ratio: 1;
  border: 2px dashed rgb(35 123 115 / 25%);
  border-radius: 50%;
  background: radial-gradient(circle, rgb(255 211 92 / 25%), rgb(240 154 46 / 7%) 57%, transparent 70%);
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.scene-halo::before,
.scene-halo::after {
  position: absolute;
  inset: 20px;
  border: 2px dotted rgb(220 65 99 / 28%);
  border-radius: 50%;
  content: "";
}

.scene-halo::after {
  inset: 42px;
  border-color: rgb(240 154 46 / 32%);
}

.toran {
  position: absolute;
  z-index: 4;
  top: calc(50% - min(34vw, 180px));
  left: 50%;
  width: min(116%, 550px);
  height: auto;
  overflow: visible;
  transform: translateX(-50%);
  pointer-events: none;
}

.toran-string {
  fill: none;
  stroke: var(--ink);
  stroke-linecap: round;
  stroke-width: 5px;
}

.toran-leaf path,
.toran-leaves use {
  fill: var(--green);
  stroke: #235d46;
  stroke-linejoin: round;
  stroke-width: 1.5px;
}

.toran-leaf {
  transform-origin: center;
}

.leaf-a {
  transform: translate(60px, 25px) rotate(-35deg);
}

.leaf-b {
  transform: translate(562px, 25px) rotate(35deg);
}

.toran-flower circle:first-child {
  fill: var(--orange);
  stroke: #b84928;
  stroke-width: 2px;
}

.toran-flower path {
  fill: var(--yellow);
  stroke: #d17227;
  stroke-linejoin: round;
  stroke-width: 1.5px;
}

.toran-flower circle:last-child {
  fill: var(--pink);
  stroke: #9c2948;
  stroke-width: 1.5px;
}

.flower-two circle:first-child,
.flower-four circle:first-child {
  fill: var(--pink);
  stroke: #a52e4b;
}

.flower-two path,
.flower-four path {
  fill: #ffce58;
}

.flower-three circle:first-child {
  fill: var(--teal);
  stroke: #145953;
}

.flower-three path {
  fill: var(--orange);
}

.flower-three circle:last-child {
  fill: var(--yellow);
}

.toran-fringe {
  fill: none;
  stroke: var(--pink);
  stroke-linecap: round;
  stroke-width: 4px;
}

.scene-caption {
  position: relative;
  z-index: 5;
  color: var(--teal);
  font-size: 0.52rem;
  font-weight: 700;
  letter-spacing: 0.23em;
  text-align: center;
}

.scene-caption-top {
  margin-bottom: 22px;
}

.scene-caption-bottom {
  margin-top: 6px;
  color: var(--pink-dark);
}

.envelope-stage {
  position: relative;
  z-index: 2;
  width: min(82vw, 410px);
  aspect-ratio: 1.55;
  transform: rotate(-3deg);
  transition: transform 450ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.envelope-stage:hover {
  transform: rotate(-1deg) translateY(-5px);
}

.envelope-shadow {
  position: absolute;
  right: 3%;
  bottom: -9%;
  left: 3%;
  height: 20%;
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: rgb(59 25 68 / 17%);
}

.letter-card {
  position: absolute;
  z-index: 1;
  top: 1%;
  right: 7%;
  left: 7%;
  display: flex;
  height: 94%;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 3px solid var(--ink);
  background: var(--paper-light);
  box-shadow: 5px 5px 0 var(--orange);
  color: var(--ink);
  transform: translateY(3%);
  transition: transform 850ms cubic-bezier(0.16, 0.78, 0.22, 1);
}

.letter-card::before {
  position: absolute;
  inset: 8px;
  border: 2px dashed var(--pink);
  content: "";
}

.letter-card-kicker,
.letter-card-date {
  z-index: 1;
  color: var(--teal);
  font-size: 0.45rem;
  font-weight: 700;
  letter-spacing: 0.22em;
}

.letter-card-title {
  z-index: 1;
  margin: 7px 0;
  color: var(--pink-dark);
  font-family: var(--serif);
  font-size: clamp(1.25rem, 3.2vw, 2rem);
  font-style: italic;
  font-weight: 700;
  line-height: 1.07;
  text-align: center;
}

.letter-card-rule {
  z-index: 1;
  width: 50px;
  height: 3px;
  margin: 5px 0 9px;
  background: var(--orange);
}

.letter-card-flower {
  position: absolute;
  right: 13px;
  bottom: 11px;
  color: var(--teal);
  font-size: 1.25rem;
}

.envelope {
  position: absolute;
  z-index: 2;
  inset: 0;
  overflow: hidden;
  border: 3px solid var(--ink);
  background: var(--orange);
  box-shadow: 8px 8px 0 var(--ink);
  clip-path: circle(150% at 75% 22%);
}

.envelope-back {
  position: absolute;
  inset: 0;
  background: var(--orange);
}

.envelope-letter-shadow {
  position: absolute;
  z-index: 1;
  top: -4%;
  right: 8%;
  left: 8%;
  height: 97%;
  border: 2px solid var(--ink);
  background: var(--paper-light);
  box-shadow: 4px 4px 0 var(--teal);
  transform: translateY(3%);
  transition: transform 850ms 100ms cubic-bezier(0.16, 0.78, 0.22, 1);
}

.envelope-pocket {
  position: absolute;
  z-index: 2;
  inset: 0;
  border-top: 3px solid rgb(59 25 68 / 40%);
  background: linear-gradient(153deg, transparent 49.5%, rgb(255 211 92 / 34%) 50%, transparent 50.7%),
    linear-gradient(27deg, var(--pink), #f5ad3c 74%, var(--yellow));
  clip-path: polygon(0 0, 50% 52%, 100% 0, 100% 100%, 0 100%);
}

.envelope-flap {
  position: absolute;
  z-index: 4;
  inset: 0 0 auto;
  height: 58%;
  border: 3px solid var(--ink);
  background: var(--yellow);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  transform: rotate(0);
  transform-origin: 50% 0;
  transition: transform 550ms cubic-bezier(0.25, 0.75, 0.3, 1);
}

.seal {
  position: absolute;
  z-index: 5;
  top: 49%;
  left: 50%;
  display: grid;
  width: 61px;
  aspect-ratio: 1;
  place-items: center;
  border: 3px solid var(--ink);
  border-radius: 50%;
  background: var(--pink);
  box-shadow: 4px 4px 0 var(--ink);
  color: var(--paper-light);
  transform: translate(-50%, -50%);
  transition: opacity 240ms ease, transform 300ms ease;
}

.seal::before {
  position: absolute;
  inset: 5px;
  border: 1px dashed var(--yellow);
  border-radius: 50%;
  content: "";
}

.seal span {
  z-index: 1;
  font-family: var(--serif);
  font-size: 1.5rem;
  font-weight: 700;
}

.envelope-sheen {
  position: absolute;
  z-index: 6;
  inset: 0;
  background: repeating-linear-gradient(45deg, transparent 0 17px, rgb(255 248 233 / 9%) 17px 19px);
  pointer-events: none;
}

.matchbox {
  position: absolute;
  z-index: 8;
  bottom: -19%;
  left: -3%;
  width: 35%;
  min-width: 105px;
  height: 27%;
  min-height: 58px;
  filter: drop-shadow(4px 5px 0 var(--ink));
}

.matchbox-tray {
  position: absolute;
  top: 10%;
  right: 0;
  bottom: 4%;
  left: 0;
  overflow: hidden;
  border: 2px solid var(--ink);
  border-radius: 2px;
  background: #e8a73d;
}

.matchbox-sleeve {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  display: flex;
  width: 72%;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 2px solid var(--ink);
  border-radius: 2px;
  background: var(--pink);
  color: var(--paper-light);
  transition: transform 450ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.matchbox-sun {
  color: var(--yellow);
  font-size: clamp(0.85rem, 3.2vw, 1.25rem);
  line-height: 1;
}

.matchbox-label {
  font-size: clamp(0.38rem, 1.4vw, 0.54rem);
  font-weight: 700;
  letter-spacing: 0.12em;
  line-height: 1.12;
}

.matchbox-striker {
  position: absolute;
  top: 7px;
  right: -5px;
  bottom: 7px;
  width: 6px;
  border: 1px solid var(--ink);
  border-radius: 2px;
  background: repeating-linear-gradient(0deg, #552d47 0 2px, #b37b62 2px 3px);
}

.spare-match {
  position: absolute;
  right: 6%;
  display: block;
  width: 34%;
  height: 5px;
  border: 1px solid var(--ink);
  border-radius: 3px;
  background: var(--paper-light);
  transform: rotate(-17deg);
}

.spare-match::before {
  position: absolute;
  top: -1px;
  right: -4px;
  width: 7px;
  height: 5px;
  border: 1px solid var(--ink);
  border-radius: 50%;
  background: var(--pink);
  content: "";
}

.spare-match-one {
  top: 22%;
}

.spare-match-two {
  top: 43%;
  right: 11%;
  transform: rotate(12deg);
}

.spare-match-three {
  top: 64%;
}

.matchstick {
  position: absolute;
  z-index: 9;
  top: 76%;
  left: 11%;
  width: 26%;
  height: 8px;
  border: 2px solid var(--ink);
  border-radius: 5px;
  background: var(--paper-light);
  opacity: 0;
  transform: rotate(-15deg);
  transform-origin: 12% 50%;
}

.matchstick::after {
  position: absolute;
  top: 1px;
  right: 8px;
  bottom: 1px;
  left: 8px;
  border-radius: 2px;
  background: var(--orange);
  content: "";
}

.matchstick-head {
  position: absolute;
  z-index: 2;
  top: 50%;
  right: -8px;
  width: 14px;
  height: 12px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: var(--pink-dark);
  transform: translateY(-50%);
}

.matchstick-head i {
  position: absolute;
  top: -18px;
  left: -1px;
  width: 18px;
  height: 24px;
  border: 2px solid var(--ink);
  border-radius: 60% 40% 55% 45%;
  background: var(--yellow);
  box-shadow: 0 0 0 4px rgb(240 154 46 / 35%);
  opacity: 0;
  transform: rotate(24deg) scale(0.35);
  transform-origin: 50% 100%;
}

.burn-glow {
  position: absolute;
  z-index: 7;
  top: 0;
  left: 0;
  width: 1px;
  height: 1px;
  border-radius: 50%;
  background: radial-gradient(circle, #fff5a8 0 8%, #ffb53d 18%, #ec6435 38%, rgb(220 65 99 / 42%) 54%, transparent 72%);
  opacity: 0;
  pointer-events: none;
}

.floating-spark {
  position: absolute;
  z-index: 7;
  color: var(--pink);
  text-shadow: 2px 2px 0 var(--yellow);
  animation: sparkle-float 2.8s ease-in-out infinite alternate;
  pointer-events: none;
}

.floating-spark-one {
  top: -14%;
  left: 6%;
  color: var(--teal);
  font-size: 1.5rem;
}

.floating-spark-two {
  right: -6%;
  bottom: 9%;
  animation-delay: 900ms;
  font-size: 1.75rem;
}

.floating-spark-three {
  top: 22%;
  right: -12%;
  color: var(--orange);
  animation-delay: 400ms;
  font-size: 2.1rem;
}

.open-button {
  position: relative;
  z-index: 2;
  display: inline-flex;
  min-height: 54px;
  align-items: center;
  justify-content: center;
  gap: 13px;
  margin-top: 31px;
  padding: 0 19px;
  border: 2px solid var(--ink);
  border-radius: 3px;
  background: var(--teal);
  box-shadow: 5px 5px 0 var(--ink);
  color: var(--paper-light);
  cursor: pointer;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.open-button:hover:not(:disabled),
.open-button:focus-visible {
  background: #1d6b64;
  box-shadow: 2px 2px 0 var(--ink);
  transform: translate(3px, 3px);
}

.button-icon {
  color: var(--yellow);
  font-size: 0.85rem;
}

.button-arrow {
  margin-left: 3px;
  color: var(--yellow);
  font-size: 0.95rem;
}

.tap-hint {
  margin: 14px 0 0;
  color: #765d69;
  font-family: var(--serif);
  font-size: 0.74rem;
  font-style: italic;
}

.footer {
  position: relative;
  z-index: 2;
  display: flex;
  min-height: 57px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 2px solid rgb(59 25 68 / 13%);
  color: #765d69;
  font-size: 0.52rem;
  font-weight: 600;
  letter-spacing: 0.15em;
}

.footer-star {
  color: var(--pink);
  font-size: 0.85rem;
}

.invitation {
  position: relative;
  z-index: 2;
  display: flex;
  width: min(100%, 680px);
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  padding: 42px 0 45px;
  animation: reveal-appear 650ms both;
}

.reveal-header {
  margin-bottom: 21px;
  text-align: center;
}

.reveal-overline {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--pink-dark);
  font-size: 0.56rem;
  font-weight: 700;
  letter-spacing: 0.2em;
}

.reveal-overline span {
  color: var(--orange);
  font-size: 0.85rem;
}

.reveal-header p {
  margin: 9px 0 0;
  color: #725b66;
  font-family: var(--serif);
  font-size: 0.91rem;
  font-style: italic;
}

.invite-card {
  position: relative;
  width: min(100%, 540px);
  padding: 9px;
  border: 2px solid var(--ink);
  background: var(--orange);
  box-shadow: 8px 8px 0 var(--ink);
  transform: rotate(-1deg);
  animation: card-arrive 750ms 100ms both;
}

.card-inner {
  position: relative;
  display: flex;
  min-height: 510px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 37px clamp(22px, 7vw, 54px) 32px;
  border: 3px solid var(--ink);
  background:
    radial-gradient(circle at 50% 17%, rgb(255 211 92 / 18%) 0 2px, transparent 3px),
    var(--pink);
  background-size: 22px 22px, auto;
  color: var(--paper-light);
  text-align: center;
}

.card-inner::before {
  position: absolute;
  inset: 10px;
  border: 2px dashed var(--yellow);
  content: "";
  pointer-events: none;
}

.card-inner::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgb(255 255 255 / 8%), transparent 36% 64%, rgb(59 25 68 / 8%));
  content: "";
  pointer-events: none;
}

.card-corner {
  position: absolute;
  z-index: 2;
  display: grid;
  width: 37px;
  height: 37px;
  place-items: center;
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: var(--yellow);
  box-shadow: 2px 2px 0 var(--ink);
  color: var(--ink);
  font-size: 1.1rem;
}

.corner-top-left {
  top: 14px;
  left: 15px;
}

.corner-top-right {
  top: 14px;
  right: 15px;
}

.corner-bottom-left {
  bottom: 14px;
  left: 15px;
}

.corner-bottom-right {
  right: 15px;
  bottom: 14px;
}

.card-kicker {
  position: relative;
  z-index: 1;
  margin: 0;
  color: var(--yellow);
  font-size: 0.48rem;
  font-weight: 700;
  letter-spacing: 0.21em;
}

.diya {
  position: relative;
  z-index: 1;
  width: 39px;
  height: 25px;
  margin: 19px 0 13px;
  border: 2px solid var(--ink);
  border-radius: 4px 4px 22px 22px;
  background: var(--orange);
  box-shadow: 3px 3px 0 var(--ink);
}

.diya::before {
  position: absolute;
  top: -19px;
  left: 50%;
  width: 13px;
  height: 19px;
  border: 2px solid var(--ink);
  border-radius: 100% 0 100% 0;
  background: var(--yellow);
  box-shadow: 2px 2px 0 var(--ink);
  content: "";
  transform: translateX(-50%) rotate(45deg);
  transform-origin: 50% 100%;
  animation: flame-flicker 1.2s ease-in-out infinite alternate;
}

.diya span {
  position: absolute;
  right: -5px;
  bottom: 3px;
  left: -5px;
  height: 2px;
  background: var(--ink);
}

.invite-card h2 {
  position: relative;
  z-index: 1;
  color: var(--paper-light);
  font-size: clamp(2rem, 7vw, 3.5rem);
  letter-spacing: -0.025em;
  line-height: 1.08;
  text-shadow: 1px 2px 0 var(--ink);
}

.invite-card h2 em {
  color: var(--yellow);
  font-size: 0.75em;
  font-weight: 700;
  letter-spacing: 0.025em;
}

.ornament {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 13px 0 12px;
  color: var(--yellow);
  font-size: 0.92rem;
}

.ornament span {
  width: 34px;
  height: 3px;
  background: var(--yellow);
}

.card-lead,
.card-dress,
.card-vibe {
  position: relative;
  z-index: 1;
  margin: 0;
  color: var(--paper-light);
  font-family: var(--serif);
  font-size: 1.02rem;
  font-weight: 600;
  line-height: 1.5;
  text-shadow: 1px 1px 0 var(--pink-dark);
}

.card-dress {
  margin-top: 11px;
  color: #ffe6d8;
  font-family: "DM Sans", sans-serif;
  font-size: 0.73rem;
  font-weight: 500;
  line-height: 1.7;
}

.event-details {
  position: relative;
  z-index: 1;
  display: grid;
  width: 100%;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 20px 0 15px;
  padding: 14px 0;
  border-top: 2px solid var(--yellow);
  border-bottom: 2px solid var(--yellow);
}

.event-detail {
  display: flex;
  flex-direction: column;
  gap: 7px;
  align-items: center;
  padding: 0 7px;
}

.event-detail + .event-detail {
  border-left: 2px dashed rgb(255 211 92 / 80%);
}

.event-detail span {
  color: var(--yellow);
  font-size: 0.49rem;
  font-weight: 700;
  letter-spacing: 0.17em;
}

.event-detail strong {
  color: var(--paper-light);
  font-size: clamp(0.58rem, 2.4vw, 0.72rem);
  font-weight: 700;
  letter-spacing: 0.045em;
  white-space: nowrap;
}

.card-vibe {
  color: var(--yellow);
  font-size: 0.88rem;
  font-style: italic;
}

.card-closing {
  position: relative;
  z-index: 1;
  margin: 12px 0 0;
  color: var(--paper-light);
  font-size: 0.56rem;
  font-weight: 700;
  letter-spacing: 0.21em;
  text-shadow: 1px 1px 0 var(--ink);
}

.replay-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 20px 0 0;
  border: 0;
  background: transparent;
  color: #765d69;
  cursor: pointer;
  font-family: var(--serif);
  font-size: 0.79rem;
  font-style: italic;
  transition: color 180ms ease;
}

.replay-button:hover {
  color: var(--pink-dark);
}

.replay-button span {
  font-family: "DM Sans", sans-serif;
  font-size: 1.1rem;
}

.design-previews {
  margin: 12px 0 0;
  color: #765d69;
  font-size: 0.7rem;
  text-align: center;
}

.design-previews summary {
  color: var(--teal);
  cursor: pointer;
}

.pdf-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  padding: 11px 0 0;
}

.pdf-links a {
  color: var(--pink-dark);
  font-size: 0.69rem;
  text-decoration-color: rgb(185 48 83 / 45%);
  text-underline-offset: 3px;
}

.pdf-links a span {
  margin-left: 3px;
}

.open-button:focus-visible,
.replay-button:focus-visible,
.wordmark:focus-visible,
.pdf-links a:focus-visible,
.design-previews summary:focus-visible {
  outline: 3px solid var(--pink);
  outline-offset: 4px;
}

.is-opening .envelope-flap {
  transform: translateY(-17%) rotate(-15deg);
}

.is-opening .seal {
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.55) rotate(-40deg);
}

.is-opening .letter-card {
  transform: translateY(-37%) rotate(2deg);
}

.is-opening .envelope-letter-shadow {
  transform: translateY(-19%);
}

.is-opening .envelope-stage {
  transform: rotate(0deg) translateY(-10px) scale(1.035);
}

.is-opening .matchbox-sleeve {
  transform: translateX(58%);
}

.is-opening .matchstick {
  animation: match-strike-and-carry 2.5s 160ms cubic-bezier(0.25, 0.7, 0.25, 1) both;
}

.is-opening .matchstick-head i {
  animation: match-ignite 450ms 780ms ease-out both, flame-dance 300ms 1.2s ease-in-out infinite alternate;
}

.is-opening .burn-glow {
  animation: burn-spread 1.05s 1.72s ease-out both;
}

.is-opening .envelope {
  animation: paper-burn 800ms 2.3s ease-in forwards;
}

.is-opening .letter-card {
  animation: letter-emerge 1.05s 2.12s cubic-bezier(0.18, 0.8, 0.25, 1) both;
}

.is-opening .open-button {
  opacity: 0.5;
  pointer-events: none;
}

.home.is-leaving {
  animation: home-leave 500ms ease both;
}

[hidden] {
  display: none !important;
}

@keyframes copy-appear {
  from {
    opacity: 0;
    transform: translate3d(-18px, 8px, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes scene-appear {
  from {
    opacity: 0;
    transform: translate3d(0, 15px, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes sparkle-float {
  from {
    opacity: 0.65;
    transform: translateY(3px) rotate(-7deg) scale(0.92);
  }
  to {
    opacity: 1;
    transform: translateY(-6px) rotate(8deg) scale(1.08);
  }
}

@keyframes flame-flicker {
  from {
    transform: translateX(-50%) rotate(39deg) scale(0.93, 1);
  }
  to {
    transform: translateX(-50%) rotate(51deg) scale(1.05, 0.94);
  }
}

@keyframes reveal-appear {
  from {
    opacity: 0;
    transform: translateY(13px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes card-arrive {
  from {
    opacity: 0;
    transform: translateY(20px) rotate(0);
  }
  to {
    opacity: 1;
    transform: translateY(0) rotate(-1deg);
  }
}

@keyframes home-leave {
  to {
    opacity: 0;
    transform: translateY(-8px);
  }
}

@keyframes match-strike-and-carry {
  0% {
    top: 76%;
    left: 11%;
    opacity: 0;
    transform: rotate(-15deg) scale(0.85);
  }
  8% {
    opacity: 1;
  }
  23% {
    top: 73%;
    left: 22%;
    transform: rotate(-12deg) scale(1);
  }
  31% {
    top: 73%;
    left: 25%;
    transform: rotate(-35deg) scale(1.02);
  }
  60% {
    top: 43%;
    left: 48%;
    transform: rotate(-39deg) scale(1.02);
  }
  82% {
    top: 29%;
    left: 66%;
    transform: rotate(-24deg) scale(1);
  }
  100% {
    top: 29%;
    left: 66%;
    opacity: 1;
    transform: rotate(-24deg) scale(1);
  }
}

@keyframes match-ignite {
  0% {
    opacity: 0;
    transform: rotate(24deg) scale(0.35);
  }
  55% {
    opacity: 1;
    transform: rotate(4deg) scale(1.2);
  }
  100% {
    opacity: 1;
    transform: rotate(16deg) scale(1);
  }
}

@keyframes flame-dance {
  from {
    transform: rotate(10deg) scale(0.94, 1);
  }
  to {
    transform: rotate(23deg) scale(1.08, 0.9);
  }
}

@keyframes burn-spread {
  0% {
    top: 30%;
    left: 72%;
    width: 10px;
    height: 10px;
    opacity: 0;
  }
  18% {
    opacity: 1;
  }
  65% {
    width: 46%;
    height: 75%;
    opacity: 1;
  }
  100% {
    top: -37%;
    left: 30%;
    width: 145%;
    height: 185%;
    opacity: 0;
  }
}

@keyframes paper-burn {
  0% {
    filter: brightness(1);
    clip-path: circle(150% at 75% 22%);
  }
  28% {
    filter: brightness(0.55) sepia(0.8);
  }
  68% {
    filter: brightness(0.78) sepia(0.5);
  }
  100% {
    filter: brightness(1);
    clip-path: circle(0% at 75% 22%);
    visibility: hidden;
  }
}

@keyframes letter-emerge {
  0% {
    z-index: 1;
    transform: translateY(3%) rotate(0);
  }
  80% {
    z-index: 1;
    transform: translateY(-48%) rotate(2deg);
  }
  100% {
    z-index: 8;
    transform: translateY(-45%) rotate(2deg);
  }
}

@media (min-width: 1400px) {
  .home {
    padding-top: 55px;
    padding-bottom: 70px;
  }

  .letter-scene {
    min-height: 625px;
  }
}

@media (max-width: 760px) {
  .experience {
    padding-right: clamp(19px, 5vw, 36px);
    padding-left: clamp(19px, 5vw, 36px);
  }

  .topbar {
    min-height: 65px;
  }

  .home {
    max-width: 550px;
    grid-template-columns: 1fr;
    gap: 0;
    padding: 42px 0 38px;
  }

  .hero-copy {
    text-align: center;
  }

  .eyebrow {
    justify-content: center;
    margin-bottom: 17px;
    font-size: 0.55rem;
  }

  h1 {
    font-size: clamp(2.65rem, 11vw, 4.5rem);
  }

  .hero-note {
    margin-top: 17px;
    font-size: 0.83rem;
    line-height: 1.7;
  }

  .hero-meta {
    justify-content: center;
    margin-top: 19px;
  }

  .open-prompt {
    display: none;
  }

  .letter-scene {
    min-height: 435px;
    margin-top: -1px;
  }

  .scene-halo {
    width: min(82vw, 400px);
  }

  .toran {
    top: calc(50% - 170px);
    width: min(120%, 500px);
  }

  .envelope-stage {
    width: min(82vw, 380px);
  }

  .scene-caption-top {
    margin-bottom: 18px;
  }

  .open-button {
    min-height: 51px;
    margin-top: 25px;
  }

  .footer {
    min-height: 48px;
    font-size: 0.43rem;
    letter-spacing: 0.11em;
  }
}

@media (max-width: 420px) {
  .topbar-note {
    font-size: 0.47rem;
    letter-spacing: 0.12em;
  }

  .wordmark {
    gap: 8px;
    font-size: 0.54rem;
    letter-spacing: 0.13em;
  }

  .wordmark-icon {
    width: 31px;
    height: 31px;
  }

  .home {
    padding-top: 34px;
  }

  h1 {
    font-size: clamp(2.5rem, 10.8vw, 3.5rem);
  }

  .letter-scene {
    min-height: 390px;
  }

  .scene-caption {
    font-size: 0.45rem;
    letter-spacing: 0.17em;
  }

  .toran {
    top: calc(50% - 170px);
    width: 122%;
  }

  .envelope-stage {
    width: min(85vw, 345px);
  }

  .matchbox {
    bottom: -16%;
    left: -2%;
    width: 37%;
    min-width: 98px;
  }

  .seal {
    width: 53px;
  }

  .footer span:first-child {
    max-width: 130px;
    line-height: 1.5;
  }

  .card-inner {
    min-height: 485px;
    padding: 31px 18px 26px;
  }

  .event-detail {
    padding: 0 3px;
  }
}

@media (max-width: 360px) {
  .experience {
    padding-right: 15px;
    padding-left: 15px;
  }

  .hero-note br {
    display: none;
  }

  .event-detail span {
    font-size: 0.44rem;
  }

  .event-detail strong {
    font-size: 0.55rem;
  }
}

@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;
  }
}
