:root {
  color-scheme: light;
  --paper: #fff9ee;
  --ink: #291b36;
  --muted: #63546c;
  --berry: #b52f55;
  --purple: #4f2b97;
  --purple-dark: #361d73;
  --yellow: #ffcc5a;
  --display: "Cormorant Garamond", Georgia, serif;
  --sans: "Manrope", system-ui, sans-serif;
  font-family: var(--sans);
  background: var(--paper);
  color: var(--ink);
  font-synthesis: none;
}

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

body {
  display: flex;
  flex-direction: column;
  min-width: 280px;
  margin: 0;
  background: radial-gradient(ellipse at 4% 90%, #ffe9e3 0, transparent 42%),
              radial-gradient(ellipse at 93% 5%, #fff0d7 0, transparent 36%),
              var(--paper);
  min-height: 100svh;
}

button { font: inherit; }
button:focus-visible, .postcard[data-keyboard-focus]:focus-visible {
  outline: 3px solid var(--purple-dark);
  outline-offset: 5px;
}

.postcard:not([data-keyboard-focus]):focus { outline: none; }

.shell {
  width: min(100% - 112px, 1240px);
  margin-inline: auto;
}

.masthead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 102px;
  border-bottom: 1px solid #32203e24;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -.027em;
}

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  color: #fff2ce;
  background: var(--purple);
  border-radius: 50%;
  transform: rotate(-9deg);
}

.mail-icon {
  position: relative;
  display: inline-block;
  width: 21px;
  height: 15px;
  flex: 0 0 auto;
  border: 1.65px solid currentColor;
  border-radius: 3px;
  overflow: hidden;
}

.mail-icon::after {
  position: absolute;
  content: "";
  width: 13px;
  height: 13px;
  top: -7px;
  left: 2.5px;
  border-right: 1.65px solid currentColor;
  border-bottom: 1.65px solid currentColor;
  border-radius: 1px;
  transform: rotate(45deg);
}

.occasion {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0;
  color: #614577;
  font-size: .875rem;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.spark {
  display: block;
  width: 16px;
  height: 16px;
  background: currentColor;
  clip-path: polygon(50% 0, 61% 38%, 100% 50%, 61% 62%, 50% 100%, 39% 62%, 0 50%, 39% 38%);
}

.occasion .spark { color: var(--berry); }

.hero {
  display: grid;
  grid-template-columns: minmax(0, 44fr) minmax(0, 56fr);
  grid-template-rows: auto auto minmax(0, 1fr);
  column-gap: clamp(24px, 4.6vw, 72px);
  padding-block: clamp(44px, 7vh, 88px) clamp(32px, 6vh, 72px);
}

.intro {
  grid-column: 1;
  grid-row: 1;
  align-self: end;
}

.intro h1 {
  margin: 0;
  font: 700 clamp(3.6rem, 6.75vw, 6.75rem)/.85 var(--display);
  letter-spacing: -.048em;
  text-wrap: balance;
}

.intro em {
  position: relative;
  display: block;
  width: max-content;
  max-width: 100%;
  margin-top: .095em;
  padding-inline-end: .08em;
  color: var(--berry);
  font-style: italic;
}

.school-name {
  display: block;
  margin-top: .16em;
  font-size: .76em;
  font-variant-numeric: lining-nums;
}

.headline-spark {
  position: absolute;
  top: .095em;
  left: calc(100% + .095em);
  width: .31em;
  height: .35em;
  background: #f5a92e;
  clip-path: polygon(50% 0, 59% 33%, 85% 14%, 70% 42%, 100% 50%, 69% 58%, 85% 85%, 59% 69%, 50% 100%, 41% 69%, 15% 85%, 31% 59%, 0 50%, 31% 41%, 15% 15%, 41% 32%);
  transform: rotate(12deg);
}

.intro h1 + p {
  max-width: 28ch;
  margin: clamp(24px, 3vw, 38px) 0 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.45vw, 1.22rem);
  line-height: 1.65;
  font-weight: 600;
}

.controls {
  grid-column: 1;
  grid-row: 2;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 18px;
  margin-top: clamp(24px, 3vw, 36px);
}

.open-button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  min-height: 60px;
  min-width: 207px;
  padding: 13px 22px;
  border: 1px solid #422481;
  border-radius: 12px;
  background: var(--purple);
  color: #fff9ee;
  box-shadow: 0 5px 0 var(--purple-dark);
  font-size: 1rem;
  font-weight: 800;
  scroll-margin-block: 14px;
  cursor: pointer;
  transition: background .18s ease, box-shadow .18s ease, transform .18s ease;
}

.open-button .mail-icon { color: #ffdb77; }

.open-button .action-spark {
  display: none;
  flex: 0 0 auto;
  color: #ffdb77;
}

.open-button[data-prediction-action] .mail-icon { display: none; }
.open-button[data-prediction-action] .action-spark { display: block; }

.new-envelope-button {
  min-height: 44px;
  padding: 8px 6px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--purple);
  font-size: .93rem;
  font-weight: 800;
  text-decoration: underline;
  text-decoration-color: #7352aa82;
  text-underline-offset: 4px;
  cursor: pointer;
}

@media (hover: hover) {
  .open-button:hover {
    background: #5a35a5;
    box-shadow: 0 7px 0 var(--purple-dark);
    transform: translateY(-2px);
  }

  .new-envelope-button:hover { text-decoration-color: currentColor; }
}

.open-button:active {
  box-shadow: 0 2px 0 var(--purple-dark);
  transform: translateY(3px);
}

.scene {
  position: relative;
  isolation: isolate;
  grid-column: 2;
  grid-row: 1 / 4;
  display: grid;
  place-items: center;
  width: 100%;
  min-width: 0;
  min-height: min(43vw, 572px);
  aspect-ratio: 1.14;
  overflow: hidden;
  border: 1px solid #ab8bcc;
  border-radius: 32px;
  background:
    radial-gradient(ellipse at 54% 46%, #f6e5fe85, transparent 60%),
    radial-gradient(circle, #50337d24 .75px, transparent 1px) 0 0 / 10px 10px,
    #e1cef8;
  box-shadow: 0 13px 34px #53396717;
}

.scene-frame {
  position: absolute;
  inset: 13px;
  border: 1px solid #7652a14d;
  border-radius: 23px;
  pointer-events: none;
}

.scene-frame::before, .scene-frame::after {
  content: "";
  position: absolute;
  width: 19px;
  height: 19px;
  border: solid #8965b4;
}

.scene-frame::before {
  top: 9px;
  left: 9px;
  border-width: 1px 0 0 1px;
  border-radius: 4px 0 0;
}

.scene-frame::after {
  bottom: 9px;
  right: 9px;
  border-width: 0 1px 1px 0;
  border-radius: 0 0 4px;
}

.decorations, .confetti {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.flower {
  position: absolute;
  display: block;
  height: auto;
  user-select: none;
  filter: drop-shadow(0 4px 0 #67378d20);
  transition: transform .68s cubic-bezier(.21,.75,.28,1);
}

.scene-daisy {
  z-index: 1;
  width: 20%;
  top: 9%;
  left: 10%;
  transform: rotate(-19deg);
}

.scene-tulips {
  z-index: 9;
  width: 21%;
  right: 4.5%;
  bottom: 11%;
  transform: rotate(21deg);
}

.scene-cornflower {
  width: 13%;
  left: 7.5%;
  bottom: 13%;
  transform: rotate(-25deg);
}

.scene:not([data-state="closed"]) .scene-daisy { transform: translate(-22%, -9%) rotate(-29deg); }
.scene:not([data-state="closed"]) .scene-tulips {
  z-index: 7;
  transform: translate(26%, 12%) rotate(29deg);
}
.scene:not([data-state="closed"]) .scene-cornflower { transform: translate(-16%, 11%) rotate(-32deg); }

.scene-spark { position: absolute; }

.scene-spark-one {
  width: 29px;
  height: 29px;
  top: 14%;
  left: 39%;
  color: #9d62d4;
  transform: rotate(13deg);
}

.scene-spark-two {
  width: 26px;
  height: 26px;
  right: 11%;
  top: 38%;
  color: #f7b328;
}

.scene-spark-three {
  width: 20px;
  height: 20px;
  bottom: 14%;
  left: 26%;
  color: #a260ce;
}

.scene-dot {
  position: absolute;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #c95b85;
}

.scene-dot-one { left: 7%; top: 38%; }
.scene-dot-two { right: 7%; bottom: 38%; background: #9c6cc5; }

.heart {
  display: block;
  width: 16px;
  height: 16px;
  position: relative;
  background: currentColor;
  transform: rotate(-45deg) scale(.8);
}

.heart::before, .heart::after {
  content: "";
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: currentColor;
}

.heart::before { top: -50%; left: 0; }
.heart::after { left: 50%; top: 0; }

.scene-heart {
  position: absolute;
  top: 17%;
  left: 55%;
  color: #d1507c;
  transform: rotate(-29deg) scale(.62);
}

.postal-stamp {
  position: absolute;
  top: 10%;
  right: 10%;
  display: grid;
  place-items: center;
  width: 11%;
  aspect-ratio: .85;
  transform: rotate(13deg);
  padding: 1.3%;
  background: #fff3d8;
  border: 2px dashed #a17abf;
  box-shadow: 2px 4px 0 #7951a02b;
}

.stamp-inner {
  position: absolute;
  inset: 5%;
  background: #ffc0ca;
  border: 1px solid #b84867;
}

.postal-stamp img {
  z-index: 1;
  width: 74%;
  height: auto;
  transform: rotate(-14deg);
}

.postmark {
  position: absolute;
  top: 23%;
  right: 21%;
  width: 10%;
  display: grid;
  gap: 3px;
  transform: rotate(-12deg);
  opacity: .75;
}

.postmark i {
  display: block;
  height: 7px;
  border-top: 1px solid #8050ab;
  border-radius: 50%;
}

.envelope, .envelope-trigger {
  position: absolute;
  top: 49%;
  left: 49.5%;
  width: 64%;
  aspect-ratio: 1.57;
  transform: translate(-50%, -50%) rotate(-9deg);
}

.envelope {
  z-index: 5;
  pointer-events: none;
  border-radius: 12px;
  perspective: 1050px;
  box-shadow: 0 7px 0 #7741921c, 0 18px 28px #5b2f713c, 0 38px 62px #5b2f7134;
  transition: transform .34s cubic-bezier(.23,.76,.36,1), opacity .34s ease;
}

.envelope-trigger {
  z-index: 10;
  border: 0;
  border-radius: 13px;
  cursor: pointer;
  background: transparent;
  touch-action: pan-x pinch-zoom;
  -webkit-tap-highlight-color: transparent;
}

.envelope-trigger:focus-visible { outline-offset: 8px; }
.envelope-trigger[hidden] { display: none; }

@media (hover: hover) {
  .scene[data-state="closed"]:has(.envelope-trigger:hover) .envelope {
    transform: translate(-50%, -53%) rotate(-6deg) scale(1.025);
  }
}

.envelope-base, .envelope-lining, .envelope-paper, .envelope-bottom, .envelope-top {
  position: absolute;
  inset: 0;
  border-radius: 12px;
}

.envelope-base {
  background: #dc627c;
  border: 1px solid #a73c60;
}

.envelope-lining {
  inset: 1% 1% 12%;
  background:
    repeating-linear-gradient(135deg, #e888a2 0 5px, #f4aabd 5px 10px);
}

.envelope-paper {
  inset: 9% 7% 6%;
  border-radius: 6px;
  background: #fff4d8;
}

.envelope-paper::before {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid #eabb91;
  border-radius: 3px;
}

.envelope-bottom {
  background: linear-gradient(19deg, #ff9daa, #ffc0be 60%, #ffacb8);
  border: 1px solid #c65b74;
  clip-path: polygon(0 0, 50% 57%, 100% 0, 100% 100%, 0 100%);
}

.envelope-bottom::before, .envelope-bottom::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
}

.envelope-bottom::before {
  background: #bf58776b;
  clip-path: polygon(0 100%, 50% 44%, 100% 100%, 50% 45.5%);
}

.envelope-bottom::after {
  background: linear-gradient(145deg, #ffbac0, #ffb1b4 69%, #ff919f);
  clip-path: polygon(0 100%, 50% 45%, 100% 100%);
}

.envelope-top {
  z-index: 1;
  transform-origin: top center;
  transform-style: preserve-3d;
  transition: transform .42s cubic-bezier(.32,.08,.36,1);
}

.envelope-top::before, .envelope-top::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 11px 11px 0 0;
  transform-origin: top center;
  clip-path: polygon(0 0, 100% 0, 100% 3%, 55% 61%, 52% 64%, 48% 64%, 45% 61%, 0 3%);
  backface-visibility: hidden;
}

.envelope-top::before {
  background: linear-gradient(180deg, #ffd1ce 0, #ffb2b5 59%, #d76c84 64%);
}

.envelope-top::after {
  background: linear-gradient(0deg, #dc748f, #f9b0bf);
  transform: rotateX(180deg);
}

.envelope-seal {
  position: absolute;
  z-index: 2;
  top: 62%;
  left: 50%;
  width: 16.5%;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  transform: translate(-50%, -50%) rotate(7deg);
  border: 2px solid #a32b4c;
  border-radius: 44% 49% 46% 51%;
  background: radial-gradient(circle at 40% 24%, #e7667e, #c63d62 64%, #9d2949);
  box-shadow: inset 0 2px 3px #ffa8ae9c, 0 4px 7px #962c555e;
  color: #ffe0cd;
  transition: transform .27s ease, opacity .21s ease;
}

.envelope-seal::after {
  content: "";
  position: absolute;
  inset: 11%;
  border: 1px solid #892441a3;
  border-radius: 50%;
  box-shadow: 0 1px 1px #f98ca391;
}

.envelope-seal .heart {
  width: 32%;
  height: auto;
  aspect-ratio: 1;
  margin-top: 12%;
  transform: rotate(-45deg) scale(.79);
}

.envelope-address {
  position: absolute;
  bottom: 6%;
  right: 8%;
  color: #8a2f51;
  font: italic 700 clamp(1.35rem, 2.6vw, 2.35rem)/1 var(--display);
}

.scene:not([data-state="closed"]) .envelope-top { transform: rotateX(174deg); }
.scene:not([data-state="closed"]) .envelope-seal {
  transform: translate(-50%, -50%) rotate(17deg) scale(.7);
  opacity: 0;
}

.scene:not([data-state="closed"]) .envelope {
  opacity: 0;
  transform: translate(-50%, -8%) rotate(4deg) scale(.82);
  transition-delay: .35s;
}

.gesture-hint {
  position: absolute;
  right: 12px;
  bottom: 7%;
  left: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin: 0;
  color: #593b76;
  font-size: .9rem;
  font-weight: 800;
  text-align: center;
  transition: opacity .22s ease;
}

.gesture-icon {
  position: relative;
  width: 15px;
  height: 22px;
  border: 1.5px solid currentColor;
  border-radius: 6px;
}

.gesture-icon::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 3px;
  width: 4px;
  height: 6px;
  border-radius: 3px;
  background: currentColor;
}

.scene:not([data-state="closed"]) .gesture-hint { opacity: 0; }

.postcard {
  --card-paper: #fff0f2;
  --card-accent: #9a2d56;
  --card-edge: #d998aa;
  position: absolute;
  z-index: 8;
  top: 48%;
  left: 50%;
  display: grid;
  place-items: center;
  width: min(77%, 472px);
  min-height: min(67%, 364px);
  border: 1px solid var(--card-edge);
  border-radius: 12px;
  background: radial-gradient(ellipse at 50% 35%, #fffaf3, transparent 75%), var(--card-paper);
  box-shadow: 0 11px 0 #8055a422, 0 18px 41px #59378e37;
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, -15%) rotate(-9deg) scale(.72);
  transition: transform .65s cubic-bezier(.18,.8,.28,1), opacity .44s ease, visibility 0s linear .44s;
}

.postcard::before {
  position: absolute;
  inset: 9px;
  border: 1px solid var(--card-edge);
  border-radius: 7px;
  content: "";
  pointer-events: none;
}

.scene:is([data-state="opening"], [data-state="open"]) #postcard,
.scene[data-state="prediction"] #fortune {
  z-index: 9;
  visibility: visible;
  opacity: 1;
  transform: translate(-50%, -50%) rotate(-2deg);
  transition-delay: 0s;
}

.scene[data-state="opening"] #postcard { transition-delay: .19s, .26s, 0s; }
.scene[data-state="prediction"] #fortune { transform: translate(-50%, -50%) rotate(1.5deg); }

.postcard[data-theme="peach"] { --card-paper: #ffe5d6; --card-accent: #9b3a38; --card-edge: #d89881; }
.postcard[data-theme="lilac"] { --card-paper: #ede2ff; --card-accent: #603997; --card-edge: #b69ad5; }
.postcard[data-theme="gold"] { --card-paper: #fff0c8; --card-accent: #805014; --card-edge: #d8af65; }
.postcard[data-theme="mint"] { --card-paper: #e4f2d8; --card-accent: #3a6349; --card-edge: #96b691; }

.card-flowers { position: absolute; inset: 0; pointer-events: none; }
.card-flower { position: absolute; display: block; width: min(16%, 66px); height: auto; }
.card-flower-left { left: -4%; bottom: 6%; transform: rotate(-26deg); }
.card-flower-right { right: -3%; top: 5%; transform: rotate(23deg); }
.card-spark { position: absolute; right: 9%; bottom: 9%; color: var(--card-accent); opacity: .65; }

.card-copy {
  position: relative;
  width: 100%;
  padding: 31px clamp(23px, 4.8vw, 58px);
  text-align: center;
}

.card-occasion {
  margin: 0 0 12px;
  color: var(--card-accent);
  font-size: .875rem;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.card-copy h2 {
  margin: 0;
  color: var(--card-accent);
  font: italic 700 clamp(2.15rem, 4.7vw, 4.25rem)/.88 var(--display);
  letter-spacing: -.03em;
  text-wrap: balance;
}

.card-message {
  margin: 17px 0 0;
  color: #44354c;
  font-size: clamp(.99rem, 1.4vw, 1.13rem);
  line-height: 1.55;
  font-weight: 600;
  text-wrap: pretty;
}

.fortune-card {
  --card-accent: #77372f;
  --card-edge: #c48943;
  background:
    radial-gradient(ellipse at 50% 28%, #fff9e4 0, transparent 68%),
    linear-gradient(145deg, #ffeebd, #ffddb5 74%, #ffd4bb);
}

.fortune-card::before { border-style: dashed; }

.fortune-stars {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin: 0 0 15px;
}

.fortune-stars .spark:first-child { color: #b84763; transform: rotate(14deg); }
.fortune-stars .spark:nth-child(2) { width: 27px; height: 27px; color: #b86c1a; }
.fortune-stars .spark:last-child { width: 12px; height: 12px; color: #6b429c; transform: rotate(-10deg); }
.fortune-card h2 { font-size: clamp(2rem, 4.2vw, 3.8rem); }

.confetti { z-index: 11; overflow: hidden; }

.petal {
  position: absolute;
  top: 52%;
  left: 50%;
  width: var(--petal-size);
  height: calc(var(--petal-size) * .72);
  border-radius: 70% 24% 68% 22%;
  background: var(--petal-color);
  opacity: 0;
  animation: petal-burst .91s cubic-bezier(.14,.7,.32,1) both;
  animation-delay: var(--petal-delay);
}

@keyframes petal-burst {
  0% { transform: translate(-50%, -50%) rotate(0) scale(.25); opacity: 0; }
  17% { opacity: 1; }
  68% { opacity: .9; }
  100% { transform: translate(var(--petal-x), var(--petal-y)) rotate(var(--petal-rotation)); opacity: 0; }
}

.script-notice {
  color: var(--berry);
  margin: 22px 0 0;
}

.credits {
  margin-block-start: auto;
  padding-block: 18px 22px;
  border-top: 1px solid #32203e24;
  color: var(--muted);
  font-size: .875rem;
  text-align: center;
}

.credits p {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 9px;
  margin: 0;
}

.credits strong {
  color: var(--ink);
  font-weight: 800;
}

@media (max-width: 1070px) {
  .shell { width: calc(100% - 72px); }
  .intro h1 { font-size: clamp(3.35rem, 7.1vw, 5.1rem); }
  .scene { min-height: 410px; }
  .card-copy { padding-inline: clamp(22px, 4vw, 45px); }
}

@media (max-width: 760px) {
  .shell { width: min(100% - 40px, 570px); }
  .masthead { min-height: 70px; }
  .brand { gap: 8px; }
  .brand-mark { width: 34px; height: 34px; }
  .brand-mark .mail-icon { transform: scale(.82); }
  .occasion { gap: 5px; font-size: .75rem; letter-spacing: .08em; }
  .occasion .spark { width: 12px; height: 12px; }

  .hero {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding-block: 27px 31px;
  }

  .intro { align-self: center; text-align: center; }
  .intro h1 { font-size: clamp(3.2rem, 15vw, 5.45rem); }
  .intro em { margin-inline: auto; margin-top: .055em; }
  .headline-spark { top: .1em; }
  .intro h1 + p { max-width: 32ch; margin: 17px auto 0; line-height: 1.45; }
  .controls { justify-content: center; margin: 0; }
  .open-button { min-height: 52px; border-radius: 10px; }

  .scene { min-height: 294px; aspect-ratio: 1.10; border-radius: 22px; }
  .scene-frame { inset: 8px; border-radius: 16px; }
  .scene-frame::before { top: 5px; left: 5px; }
  .scene-frame::after { bottom: 5px; right: 5px; }
  .scene-daisy { left: 9%; top: 12%; }
  .scene-tulips { right: 5%; bottom: 14%; }
  .scene-cornflower { bottom: 17%; }
  .scene-spark-one, .scene-spark-two, .scene-spark-three { width: 16px; height: 16px; }
  .scene-dot { width: 5px; height: 5px; }
  .postmark { gap: 2px; }
  .postmark i { height: 4px; }
  .gesture-hint { bottom: 8%; font-size: .8rem; gap: 7px; }
  .gesture-icon { transform: scale(.84); }
  .envelope, .envelope-trigger { width: 68%; }
  .envelope-address { font-size: clamp(1.22rem, 5.4vw, 2.25rem); }

  .postcard { width: min(84%, 410px); min-height: 72%; top: 48%; border-radius: 9px; }
  .postcard::before { inset: 7px; border-radius: 5px; }
  .card-copy { padding: 24px 20px; }
  .card-copy h2 { font-size: clamp(2rem, 8vw, 3.65rem); }
  .card-occasion { margin-bottom: 8px; font-size: .75rem; }
  .card-message { margin-top: 11px; font-size: 1rem; line-height: 1.45; }
  .card-spark { width: 12px; height: 12px; }
  .fortune-card .card-copy { padding-block: 18px; }
  .fortune-card h2 { font-size: clamp(1.85rem, 7.2vw, 3.15rem); }
  .fortune-stars { margin-bottom: 10px; }
  .fortune-stars .spark:nth-child(2) { width: 22px; height: 22px; }
}

@media (max-width: 360px) {
  .shell { width: calc(100% - 26px); }
  .masthead { min-height: 58px; }
  .brand { font-size: .92rem; }
  .occasion { font-size: .69rem; letter-spacing: .05em; }
  .hero { gap: 12px; padding-block: 14px 25px; }
  .scene { min-height: 280px; }
  .intro h1 { font-size: clamp(2.9rem, 15.7vw, 3.55rem); }
  .intro h1 + p { margin-top: 12px; }
  .postcard { width: 87%; }
  .card-copy { padding: 17px 18px; }
  .card-copy h2 { font-size: 1.9rem; }
  .card-message { line-height: 1.35; }
  .fortune-card h2 { font-size: 1.85rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
    transition-delay: 0ms !important;
  }
  .petal { display: none; }
}
