:root{
  --ube:#5B2EE5; --midnight:#1A0B3B; --lilac:#E3D7FF; --yolk:#FFC02E;
  --pink:#FF8FB8; --dinuguan:#3A1410; --ice:#BFE3FF; --mint:#C8F2DC; --felt:#17694A;
  --wito-green:#6FE3A1; --wito-deep:#0E6B45;
}
*{box-sizing:border-box;margin:0;padding:0}
html,body{height:100%}
body{
  background:#0E0624; display:grid; place-items:center;
  font-family:'Bricolage Grotesque',system-ui,sans-serif;
  -webkit-tap-highlight-color:transparent; overscroll-behavior:none;
}
.phone{
  position:relative; width:min(100vw,440px); height:min(100dvh,900px);
  overflow:hidden; container-type:inline-size; user-select:none;
  background:var(--ube); color:var(--lilac);
}
@media (min-width:441px){ .phone{border-radius:28px} }

.bars{position:absolute; z-index:5; top:14px; left:14px; right:14px; display:flex; gap:4px; pointer-events:none}
.bars i{flex:1; height:4px; border-radius:4px; overflow:hidden; background:color-mix(in srgb, currentColor 28%, transparent)}
.bars b{display:block; width:0; height:100%; background:currentColor}
.bars .done b{width:100%}
.bars .now b{animation:fill var(--slide-time,60s) linear forwards}
.bars.paused b{animation-play-state:paused}
@keyframes fill{to{width:100%}}

/* Wito's name is always green: bright on dark cards; light cards set --wito to the deep green */
.wito{color:var(--wito, var(--wito-green)); font-weight:800}
.polaroid .wito{color:var(--wito-deep)}

/* the song label under the progress bar on every card: three little moving bars, the title, then the artist.
   Plain text, no background; it takes each card's own text colour. */
.nowplaying{position:absolute; z-index:6; left:14px; top:25px; display:flex; align-items:center; gap:1.600cqi; max-width:calc(100% - 28px); color:inherit; font-size:3.300cqi; line-height:1.2; white-space:nowrap; pointer-events:none}
.nowplaying[hidden]{display:none}
.nowplaying strong{font-weight:700; overflow:hidden; text-overflow:ellipsis}
.nowplaying span{opacity:.82; overflow:hidden; text-overflow:ellipsis}
.nowplaying i{display:flex; align-items:flex-end; gap:.5cqi; height:2.600cqi; flex:none}
.nowplaying i b{width:.7cqi; height:100%; border-radius:1px; background:currentColor; transform-origin:bottom; animation:eq .9s ease-in-out infinite}
.nowplaying i b:nth-child(2){animation-delay:.3s}
.nowplaying i b:nth-child(3){animation-delay:.6s}
@keyframes eq{0%,100%{transform:scaleY(.35)} 50%{transform:scaleY(1)}}
.nowplaying.in{animation:label-in .35s ease-out}
@keyframes label-in{from{transform:translateY(-6px); opacity:0}}

/* DEV ONLY: mute toggle, remove before sharing */
.devsound{position:absolute; z-index:6; bottom:6px; right:14px; font:inherit; font-size:3.4cqi; font-weight:700; color:inherit; background:none; border:0; box-shadow:inset 0 0 0 1.5px currentColor; border-radius:99px; padding:1.2cqi 3cqi; cursor:pointer}
.devsound:focus-visible{outline:3px solid var(--yolk); outline-offset:2px}

.nav{position:absolute; z-index:1; top:0; bottom:0; background:none; border:0; cursor:pointer}
.nav.prev{left:0; width:32%}
.nav.next{right:0; width:68%}
.nav:focus-visible{outline:3px solid var(--yolk); outline-offset:-6px}

.slide{
  position:absolute; inset:0; z-index:2; pointer-events:none;
  padding:15cqi 7cqi 8cqi; display:flex; flex-direction:column;
  background:var(--bg); color:var(--fg);
  visibility:hidden; overflow:hidden;
}
.slide.on{visibility:visible}
.slide.on .rise{animation:rise .5s cubic-bezier(.2,.9,.3,1.2) both}
.slide.on .rise:nth-child(2){animation-delay:.08s}
.slide.on .rise:nth-child(3){animation-delay:.16s}
.slide.on .rise:nth-child(4){animation-delay:.24s}
@keyframes rise{from{transform:translateY(6cqi) scale(.94)}}
.tap{pointer-events:auto; position:relative; z-index:3}

.kicker{font-size:5.2cqi; font-weight:600; line-height:1.2}
.big{font-size:17cqi; font-weight:800; line-height:.9; letter-spacing:-.035em; font-stretch:80%}
.num{font-size:31cqi; font-weight:800; line-height:.82; letter-spacing:-.015em; font-stretch:75%; color:var(--pop)}
.body{font-size:5cqi; font-weight:500; line-height:1.35; max-width:32ch}
.small{font-size:3.9cqi; font-weight:500; line-height:1.35; opacity:.85}
.pop{color:var(--pop)}
.push{margin-top:auto}
.gap{margin-top:5cqi}

.blob{position:absolute; border-radius:50%; background:var(--pop); z-index:-1}

/* fillers: decoration that soaks up leftover space */
.fill{flex:1; min-height:0; display:flex; align-items:center; justify-content:center; padding:3cqi 0}
.fill svg{display:block; width:var(--w); max-width:100%; height:100%; max-height:var(--h)}
.polaroid{width:42cqi; background:#fff; padding:2.5cqi 2.5cqi 0; transform:rotate(var(--tilt,-5deg)); box-shadow:1.4cqi 1.4cqi 0 var(--midnight)}
.polaroid div{aspect-ratio:1; display:grid; place-items:center; background:var(--lilac); color:var(--ube); border:.5cqi dashed var(--ube); padding:3cqi; font-size:3.7cqi; font-weight:700; line-height:1.2; text-align:center}
.polaroid figcaption{padding:1.8cqi 0 2.2cqi; font-size:3.7cqi; font-weight:700; color:var(--midnight); text-align:center}
.receipt{position:relative; width:64cqi; background:#fff; color:var(--midnight); padding:4cqi 4.5cqi 3cqi; transform:rotate(3deg); font-size:4.2cqi; font-weight:600}
.receipt h3{font-size:5cqi; font-weight:800; text-align:center; border-bottom:.6cqi dashed var(--midnight); padding-bottom:2cqi; margin-bottom:2cqi}
.receipt p{display:flex; justify-content:space-between; gap:3cqi; line-height:1.5}
.receipt p:last-child{border-top:.6cqi dashed var(--midnight); margin-top:2cqi; padding-top:2cqi; font-weight:800}
.receipt::after{content:''; position:absolute; left:0; right:0; top:100%; height:2.4cqi; background:linear-gradient(135deg,#fff 50%,transparent 50%) 0 0/4.8cqi 100%, linear-gradient(225deg,#fff 50%,transparent 50%) 0 0/4.8cqi 100%}
.court{gap:5cqi}
.court svg{transform:rotate(-12deg)}
.score{display:flex; background:var(--midnight); border-radius:3cqi; padding:2.5cqi 1cqi; transform:rotate(3deg)}
.score div{padding:0 4cqi; text-align:center}
.score div + div{border-left:.5cqi solid #ffffff33}
.score small{display:block; font-size:3.4cqi; font-weight:600; color:var(--lilac); margin-bottom:1cqi}
.score div > b{font-size:13cqi; font-weight:800; font-stretch:75%; line-height:1; color:var(--yolk)}
.score div + div > b{color:var(--pink)}
@media (max-height:720px){ .fill.soft{display:none} }

/* cover */
.cover .big{font-size:18cqi; letter-spacing:-.015em; white-space:nowrap}
/* two photos on a diagonal (top right, bottom left) with the Slay sticker in the bottom-right gap */
.hero{position:relative; width:100%; display:flex; flex-direction:column}
.shot{position:relative; width:min(46cqi, 25dvh)}
.shot.one{align-self:flex-end; margin-right:2cqi}
.shot.two{align-self:flex-start; margin:-9cqi 0 0 2cqi}
.shot .polaroid{width:100%}
.shot.one figcaption{text-align:right; padding-right:1cqi}   /* keeps clear of the second photo's corner */

/* the photo starts gift-wrapped; the first tap starts the music and unwraps it on the beat */
.gift{position:absolute; inset:0; z-index:2; background:var(--yolk); transform:rotate(var(--r)); box-shadow:1.4cqi 1.4cqi 0 var(--midnight); animation:wobble 1.8s ease-in-out infinite}
.gift::before, .gift::after{content:''; position:absolute; background:var(--pink)}
.gift::before{left:calc(50% - 4cqi); top:0; bottom:0; width:8cqi}
.gift::after{top:calc(50% - 4cqi); left:0; right:0; height:8cqi}
.gift i{position:absolute; z-index:1; left:50%; top:50%; width:15cqi; height:15cqi; margin:-7.5cqi; border-radius:50%; background:var(--pink); border:1.2cqi solid var(--midnight)}
@keyframes wobble{0%,100%{transform:rotate(var(--r))} 50%{transform:rotate(calc(var(--r) + 3deg)) scale(1.03)}}
@keyframes jitter{0%,100%{transform:rotate(calc(var(--r) - 2deg))} 50%{transform:rotate(calc(var(--r) + 2deg)) scale(1.04)}}
@keyframes unwrap{to{transform:rotate(calc(var(--r) + 20deg)) scale(1.6); opacity:0; visibility:hidden}}
@keyframes pop{from{transform:rotate(-16deg) scale(.4)}}
@keyframes stick{from{transform:rotate(-30deg) scale(2.4); opacity:0}}
.cover:not(.open) .polaroid{visibility:hidden}
.cover.tapped .gift{animation:jitter .14s linear infinite}
.cover.open .gift{animation:unwrap .4s ease-in forwards}
.cover.open .polaroid{animation:pop .5s cubic-bezier(.2,1.5,.4,1) both}
.shot.one{--r:5deg}
.shot.two{--r:-6deg}
.shot.two .gift{animation-delay:.4s}
.gift.alt{background:var(--pink)}
.gift.alt::before, .gift.alt::after, .gift.alt i{background:var(--yolk)}
.cover.open .shot.two .gift, .cover.open .shot.two .polaroid{animation-delay:.15s}

/* card 2, one sentence in steps: a small lead-in, the big 22 with "my fav number" beside it, then the rest with "favorite memories" large */
.loud{font-weight:800; font-stretch:78%; letter-spacing:-.02em; color:var(--pop)}
.lead{font-size:4.800cqi; font-weight:500; line-height:1.3}
.fav{display:flex; align-items:center; gap:3cqi; margin-top:1cqi}
.fav #age{font-size:36cqi; line-height:.82; font-stretch:75%}
.fav span + span{font-size:12cqi; line-height:.95; white-space:nowrap}
.fav #age i{font-style:normal; font-size:12cqi; font-stretch:78%; margin-left:.6cqi}
.year{margin-top:6cqi; display:grid; gap:1.5cqi; font-size:4.8cqi; font-weight:500; line-height:1.3}
.year .loud{font-size:12cqi; line-height:1.05}
/* "ig ur 22 + 1 now, not bad" with arrows naming whose number is whose: 22 in Wito's green, 1 in Claire's purple */
.math{display:block; width:min(86cqi, 46dvh); margin:0 auto; overflow:visible}
.note .polaroid figcaption{font-size:3.3cqi; white-space:nowrap}
/* a sad cow each side of the photo: a black-and-white one and a brown one with horns, so neither matches the cover's cow */
.note .fill{gap:0}
.note .fill .polaroid{position:relative; z-index:1}   /* the cows peek out from behind the photo's edges */
.note .fill .sadcow{flex:none; width:min(29cqi, 13dvh); height:auto; max-width:none; max-height:none; overflow:visible; margin:6cqi -4.5cqi 0; transform:rotate(var(--lean)); animation:mope 3s ease-in-out infinite}
.note .fill .polaroid ~ .sadcow{animation-delay:-1.5s}
.sadcow .tear{transform-box:fill-box; transform-origin:50% 0; animation:tear 2.4s ease-in infinite}
.note .fill .polaroid ~ .sadcow .tear{animation-delay:-1.1s}
@keyframes mope{0%,100%{transform:rotate(var(--lean)) translateY(0)} 50%{transform:rotate(calc(var(--lean) * 1.5)) translateY(.8cqi)}}
@keyframes tear{0%{transform:translateY(-3px) scale(.4); opacity:0} 20%{transform:translateY(0) scale(1); opacity:1} 75%{opacity:1} 100%{transform:translateY(17px) scale(1); opacity:0}}
@media (prefers-reduced-motion:reduce){ .note .fill .sadcow, .sadcow .tear{animation:none} }
@media (max-height:720px){               /* short phones: shrink card 2's pieces so the photo and the figure both fit */
  .note .fav #age{font-size:28cqi}
  .note .fav span + span{font-size:9.4cqi}
  .note .fav #age i{font-size:9.4cqi}
  .note .year{margin-top:3cqi}
  .note .year .loud{font-size:10.5cqi}
  .note .math{width:min(86cqi, 40dvh)}
  .note .fill{padding:1cqi 0}
}
.year u{color:var(--pop); text-decoration:underline wavy var(--pop); text-decoration-thickness:.5cqi; text-underline-offset:1.4cqi}

/* ice */
/* the line she says to servers, as a speech bubble between two small lead-ins */
/* ice card: "77 ice cubes" as one line, the number carrying it */
.icehead{display:flex; align-items:baseline; flex-wrap:wrap; gap:0 3cqi; margin-top:1cqi}
.icehead .num{font-size:36cqi}
.icehead .unit{font-size:13.5cqi; font-weight:800; font-stretch:78%; letter-spacing:-.02em; line-height:.9; color:var(--pop); white-space:nowrap}
.said{margin-top:6cqi; display:grid; gap:1.8cqi; justify-items:stretch; font-size:4.6cqi; font-weight:500; line-height:1.3}
.bubble{background:var(--fg); color:var(--bg); font-size:6.4cqi; white-space:nowrap; font-weight:800; font-stretch:85%; line-height:1.1; padding:3.2cqi 4.5cqi; border-radius:5cqi 5cqi 5cqi 1cqi; transform:rotate(-1.5deg)}
.bubble em{display:block; text-align:right; font-style:normal; font-size:11.5cqi; line-height:1; margin-top:.6cqi; color:var(--ube)}   /* the part to land on */
/* three glasses along the bottom: the big middle one is tappable, the two side ones are decoration */
.glasses{display:flex; align-items:flex-end; justify-content:center; --side:min(31cqi, 14.5dvh)}
/* the side glasses sit behind the big one: smaller, raised, dimmer, and tucked in behind its edges */
.sideglass{display:block; width:var(--side); margin-bottom:5cqi; opacity:.7; overflow:visible}
.sideglass:first-child{margin-right:calc(var(--side) * -.45); transform:rotate(-5deg)}
.sideglass:last-child{margin-left:calc(var(--side) * -.45); transform:rotate(5deg)}
.glass{display:block; width:min(52cqi, 24dvh); background:none; border:0; cursor:pointer}

/* cubes raining down toward the glasses, staggered so they keep coming without lining up */
.rain{position:relative; container-type:size; overflow:hidden; padding:0}
.rain i{position:absolute; top:0; left:var(--x); width:var(--s); height:var(--s); border-radius:22%; background:var(--ice); opacity:0; animation:drop var(--t) cubic-bezier(.45,.05,.85,.6) var(--d) infinite}
@keyframes drop{0%{transform:translateY(-120%) rotate(0deg); opacity:0} 12%{opacity:.9} 80%{opacity:.9} 100%{transform:translateY(100cqh) rotate(var(--r)); opacity:0}}
.glass svg{display:block; width:100%; overflow:visible}
/* the glasses never sit still: the big one rocks, the side ones lean away and back, the cubes bob, and a few glints twinkle */
.glass{transform-origin:50% 100%; animation:rock 2.6s ease-in-out infinite}
.sideglass{transform-origin:50% 100%; animation:lean 2.6s ease-in-out infinite; --a:-5deg}
.sideglass:last-child{--a:5deg; animation-delay:-1.3s}
@keyframes rock{0%,50%,100%{transform:rotate(0deg) translateY(0)} 25%{transform:rotate(-3deg) translateY(-1.2cqi)} 75%{transform:rotate(3deg) translateY(-1.2cqi)}}
@keyframes lean{0%,100%{transform:rotate(var(--a)) translateY(0)} 50%{transform:rotate(calc(var(--a) * 2)) translateY(-1.5cqi)}}
.glass .cube, .sideglass rect{animation:bob 1.7s ease-in-out infinite}
.glass .cube:nth-child(2n), .sideglass rect:nth-child(2n){animation-delay:-.85s}
.glass .cube:nth-child(3n){animation-delay:-.4s}
@keyframes bob{50%{translate:0 -8px}}
.glint{transform-box:fill-box; transform-origin:center; animation:twinkle 1.8s ease-in-out infinite}
.glint + .glint{animation-delay:-.6s}
.glint + .glint + .glint{animation-delay:-1.2s}
@keyframes twinkle{0%,100%{transform:scale(0) rotate(0deg); opacity:0} 50%{transform:scale(1) rotate(45deg); opacity:1}}
.glass.shake svg{animation:shake .28s}
@keyframes shake{25%{transform:rotate(-5deg) scale(1.04)}60%{transform:rotate(4deg)}}
.glass:focus-visible{outline:3px solid var(--yolk); outline-offset:6px; border-radius:12px}
.crunch{position:absolute; left:50%; bottom:100%; font-weight:800; font-size:6cqi; color:var(--yolk); white-space:nowrap; pointer-events:none; animation:float .8s ease-out forwards}
@keyframes float{from{transform:translate(var(--dx),0) rotate(var(--r))}to{transform:translate(var(--dx),-16cqi) rotate(var(--r)); opacity:0}}

/* top snacks */
/* top food as a podium: 2nd, 1st and 3rd on steps, 4th and 5th in a row under it, then the drinks as honorable mentions */
.podium{list-style:none; padding:0; margin:5cqi 0 0; flex:1 1 auto; min-height:0; max-height:116cqi; display:flex; align-items:stretch; gap:1.5cqi; border-bottom:1.2cqi solid var(--midnight)}
.podium li{flex:1; min-width:0; display:flex; flex-direction:column; justify-content:flex-end}
.podium .p1{order:2} .podium .p2{order:1} .podium .p3{order:3}
.podium .top{display:flex; flex-direction:column; align-items:center; text-align:center}
.podium svg{display:block; overflow:visible}
.podium .dish{width:min(21cqi, 9.5dvh)}
.podium .p1 .dish{width:min(26cqi, 12dvh)}
.podium .crown{width:min(12cqi, 5.5dvh); margin-bottom:-1cqi; transform:rotate(-8deg)}
.podium strong{font-size:5.8cqi; font-weight:800; font-stretch:80%; line-height:1.1; margin:1cqi 0 1.5cqi}
.podium .step{background:var(--midnight); border-radius:3cqi 3cqi 0 0; display:grid; justify-items:center; align-content:start; padding-top:1.5cqi; transform-origin:50% 100%}
.podium .p1 .step{height:50%; background:var(--ube)}
.podium .p2 .step{height:36%}
.podium .p3 .step{height:25%}
.podium b{font-size:15cqi; font-weight:800; font-stretch:75%; line-height:1; color:var(--yolk)}
/* the steps grow in from third to first, each dish lands on its step, then the dishes keep hopping */
.slide.on .podium .step{animation:grow .7s cubic-bezier(.2,1.25,.4,1) backwards}
.slide.on .podium .top{animation:land .55s cubic-bezier(.2,1.4,.4,1) backwards}
.slide.on .podium .p3 .step{animation-delay:.15s} .slide.on .podium .p3 .top{animation-delay:.4s}
.slide.on .podium .p2 .step{animation-delay:.45s} .slide.on .podium .p2 .top{animation-delay:.7s}
.slide.on .podium .p1 .step{animation-delay:.75s} .slide.on .podium .p1 .top{animation-delay:1s}
@keyframes grow{from{transform:scaleY(.12)}}
@keyframes land{from{transform:translateY(-10cqi) scale(.6)}}
.podium .dish{animation:hop 2.2s ease-in-out infinite}
.podium .p2 .dish{animation-delay:-.7s}
.podium .p3 .dish{animation-delay:-1.4s}
.podium .crown{animation:crown 2.2s ease-in-out infinite}
@keyframes hop{0%,100%{transform:translateY(0) rotate(0deg)} 50%{transform:translateY(-1.6cqi) rotate(5deg)}}
@keyframes crown{0%,100%{transform:rotate(-8deg) translateY(0)} 50%{transform:rotate(4deg) translateY(-1.8cqi)}}
.runners{list-style:none; padding:0; margin:4cqi 0 0; display:grid; grid-template-columns:1fr 1fr; gap:2.5cqi}
.runners li{display:flex; align-items:center; gap:2cqi; min-width:0; background:var(--midnight); color:var(--lilac); border-radius:3.5cqi; padding:2cqi 2.5cqi}
.runners b{font-size:9cqi; font-weight:800; font-stretch:75%; line-height:1; color:var(--yolk)}
.runners svg{width:7.5cqi; flex:none}
.runners strong{font-size:4.3cqi; font-weight:700; line-height:1.05}
.mentions{margin-top:4cqi}
.mentions p{font-size:4.4cqi; font-weight:700}
.mentions ul{list-style:none; padding:0; margin:1.5cqi 0 0; display:grid; grid-template-columns:1fr 1fr; gap:2.5cqi}
.mentions li{display:flex; align-items:center; gap:1.5cqi; min-width:0; border:.7cqi dashed var(--midnight); border-radius:99px; padding:1.2cqi 3cqi; font-size:4.6cqi; font-weight:800; font-stretch:85%; line-height:1.05; white-space:nowrap}
.mentions svg{width:8cqi; flex:none}
@media (prefers-reduced-motion:reduce){ .podium .dish, .podium .crown, .slide.on .podium .step, .slide.on .podium .top{animation:none} }

/* shi lin */
.shilin .big{font-size:18cqi}
.shilin .blob{width:60cqi; height:60cqi; left:-22cqi; bottom:-20cqi}
.stamp{align-self:flex-end; margin-top:auto; font-size:11cqi; font-weight:800; font-stretch:75%; color:var(--bg); background:var(--midnight); padding:2cqi 5cqi; border-radius:3cqi; transform:rotate(-6deg)}

/* personality */
.lines{margin-top:7cqi; display:grid; gap:5cqi}
.lines p{font-size:14cqi; font-weight:800; line-height:.95; letter-spacing:-.03em; font-stretch:80%}
.lines p:nth-child(1){color:var(--yolk)}
.lines p:nth-child(2){color:var(--pink)}
.lines p:nth-child(3){color:var(--lilac)}

/* films watched: five movie stills on one strip of film that runs across the whole card.
   The strip steps along one frame at a time, so each still gets a few seconds in the middle with its neighbours peeking in at the sides. */
.reel{--fw:min(72cqi, 35dvh); --step:calc(var(--fw) + 3cqi); position:relative; flex:none; width:112cqi; padding:6.5cqi 0; background:#06020f; overflow:hidden; transform:rotate(-2deg); box-shadow:0 1.3cqi 0 var(--yolk)}
.reel::before, .reel::after{content:""; position:absolute; left:0; right:0; height:3cqi; background:repeating-linear-gradient(90deg, var(--lilac) 0 3.2cqi, transparent 3.2cqi 6cqi); opacity:.9}
.reel::before{top:1.7cqi} .reel::after{bottom:1.7cqi}
.strip{display:flex; gap:3cqi; width:max-content; margin-left:calc((112cqi - var(--fw)) / 2 - var(--step))}
.slide.on .strip{animation:advance 12.5s cubic-bezier(.7,0,.3,1) infinite}   /* starts when the card opens, so the first still is always the first one shown */
@keyframes advance{0%,16%{transform:translateX(0)} 20%,36%{transform:translateX(calc(var(--step) * -1))} 40%,56%{transform:translateX(calc(var(--step) * -2))} 60%,76%{transform:translateX(calc(var(--step) * -3))} 80%,96%{transform:translateX(calc(var(--step) * -4))} 100%{transform:translateX(calc(var(--step) * -5))}}
.frame{position:relative; flex:none; width:var(--fw); margin:0}
.frame svg{display:block; width:100%; height:auto; max-width:none; max-height:none; border-radius:1cqi}
.frame .cloud{animation:cloud 9s ease-in-out infinite alternate}
.frame .cloud.slow{animation-duration:14s; animation-direction:alternate-reverse}
@keyframes cloud{from{transform:translateX(-26px)} to{transform:translateX(30px)}}
.frame .twinkle{animation:twinkle-city 2.4s ease-in-out infinite alternate}
@keyframes twinkle-city{from{opacity:.55} to{opacity:1}}
.frame .alarm{animation:alarm 1.6s ease-in-out infinite alternate}
@keyframes alarm{from{opacity:.35} to{opacity:1}}
.frame .reach{animation:reach 1.8s ease-in-out infinite alternate; transform-origin:286px 150px}
@keyframes reach{from{transform:scale(.94)} to{transform:scale(1.04)}}
.frame .eyes{animation:alarm 1.1s steps(2) infinite alternate}
.frame .pup{animation:pup 1.4s ease-in-out infinite alternate; transform-origin:308px 228px}
.frame .crowd{animation:crowd 6s ease-in-out infinite alternate}
@keyframes pup{from{transform:rotate(-5deg)} to{transform:rotate(6deg)}}
@keyframes crowd{from{transform:translateX(-8px)} to{transform:translateX(10px)}}
.frame .embers{animation:embers 1.6s ease-in-out infinite alternate}
.frame .smoke{animation:smoke 5s ease-in-out infinite alternate; transform-origin:330px 130px}
@keyframes embers{from{transform:translate(0,3px); opacity:.55} to{transform:translate(4px,-5px); opacity:1}}
@keyframes smoke{from{transform:scale(1)} to{transform:scale(1.08) translate(-6px,-4px)}}
@media (prefers-reduced-motion:reduce){ .strip, .frame .cloud, .frame .twinkle, .frame .alarm, .frame .reach, .frame .eyes, .frame .embers, .frame .smoke, .frame .pup, .frame .crowd{animation:none} }
/* year 23 opens with a 13-second clip over the whole card; then the clip is slowly wiped away from right to left behind a yellow edge, like the story advancing, and the content rises in */
.bron .intro{position:absolute; inset:0; z-index:4; width:100%; height:100%; object-fit:cover; background:#000; clip-path:inset(0 0 0 0)}
.bron.played .intro{clip-path:inset(0 100% 0 0); visibility:hidden; transition:clip-path 2.5s cubic-bezier(.65,0,.3,1), visibility 0s 2.5s}   /* only the wipe-away is animated; the clip comes back instantly, so the content never shows first */
.bron::after{content:""; position:absolute; z-index:5; top:0; bottom:0; left:0; width:2.5cqi; background:var(--yolk); transform:translateX(-100%); pointer-events:none}
.bron.played::after{animation:wipe-edge 2.5s cubic-bezier(.65,0,.3,1) both}
@keyframes wipe-edge{from{transform:translateX(100cqi)} to{transform:translateX(-100%)}}
.slide.on.bron.played .rise{animation-delay:1s}
.slide.on.bron:not(.played) .rise{animation:none}
/* top artists as a record player: number one spins on the turntable with the photo as its label, two and three are records half out of their sleeves */
.vinyl{justify-content:space-between}
.deck{--d:min(60cqi, 29dvh); position:relative; margin-top:4cqi; background:var(--ube); border-radius:6cqi; padding:4cqi; display:flex; align-items:flex-end; justify-content:space-between; box-shadow:1.4cqi 1.4cqi 0 var(--midnight)}
.turn{position:relative; width:var(--d); flex:none}
.record{display:block; width:100%; padding:0; background:none; border:0; border-radius:50%; cursor:pointer; color:inherit; font:inherit}
.record .wrap{display:block; position:relative}
.record .wrap::after{content:""; position:absolute; inset:0; border-radius:50%; pointer-events:none; background:conic-gradient(from 25deg, transparent 0 7%, rgba(255,255,255,.2) 12%, transparent 18% 50%, rgba(255,255,255,.14) 61%, transparent 68%)}   /* the sheen stays put while the record turns under it */
.disc{display:block; position:relative; width:100%; aspect-ratio:1; border-radius:50%; border:.8cqi solid var(--midnight); background:repeating-radial-gradient(circle closest-side, #150830 0 3.5%, #2C1C5A 3.5% 4.6%); animation:spin 8s linear infinite}
.disc::after{content:""; position:absolute; left:50%; top:50%; width:4.5%; aspect-ratio:1; transform:translate(-50%,-50%); border-radius:50%; background:var(--ice); border:.4cqi solid var(--midnight)}
.vinyl .label{position:absolute; inset:25%; border-radius:50%; overflow:hidden; border:.8cqi solid var(--yolk); background:var(--lilac); color:var(--ube); display:grid; place-items:center; font-size:8cqi; font-weight:800}
.turn .disc::after{display:none}   /* no spindle hole over his face */
@keyframes spin{to{transform:rotate(360deg)}}
.record.scratch .wrap{animation:scratch .55s ease-out}
@keyframes scratch{0%{transform:rotate(0deg) scale(1)} 20%{transform:rotate(-38deg) scale(1.05)} 45%{transform:rotate(26deg) scale(1.05)} 70%{transform:rotate(-14deg)} 100%{transform:rotate(0deg) scale(1)}}
.vinyl .crunch{color:var(--midnight); z-index:4}
.arm{position:absolute; left:72%; top:-4%; width:40%; overflow:visible; pointer-events:none; z-index:3; transform-origin:75% 16%; animation:arm 2.4s ease-in-out infinite}
@keyframes arm{0%,100%{transform:rotate(0deg)} 50%{transform:rotate(3deg)}}
.tune{position:absolute; left:var(--x); top:2%; font-style:normal; font-size:8cqi; font-weight:800; line-height:1; color:var(--yolk); pointer-events:none; z-index:2; opacity:0; animation:tune 3.4s ease-out var(--d) infinite}
@keyframes tune{0%{transform:translate(0,4cqi) scale(.5) rotate(0deg); opacity:0} 15%{opacity:1} 70%{opacity:1} 100%{transform:translate(var(--dx),-20cqi) scale(1.1) rotate(var(--r)); opacity:0}}
.panel{display:flex; flex-direction:column; align-items:flex-end; gap:3cqi}
.eq{display:flex; align-items:flex-end; gap:1cqi; height:11cqi}
.eq i{width:2cqi; height:100%; border-radius:1cqi; background:var(--yolk); transform-origin:bottom; animation:eq .9s ease-in-out infinite}
.eq i:nth-child(2){animation-delay:-.3s; background:var(--pink)} .eq i:nth-child(3){animation-delay:-.6s} .eq i:nth-child(4){animation-delay:-.15s; background:var(--mint)} .eq i:nth-child(5){animation-delay:-.45s}
.knobs{display:flex; gap:2cqi}
.knobs i{width:5cqi; aspect-ratio:1; border-radius:50%; background:var(--lilac); border:.8cqi solid var(--midnight)}
.headliner{display:flex; align-items:center; gap:3cqi; margin-top:4cqi}
.headliner b{font-size:20cqi; font-weight:800; font-stretch:75%; line-height:.82; color:var(--pop)}
.headliner strong{font-size:11.5cqi; font-weight:800; font-stretch:80%; letter-spacing:-.02em; line-height:.95}
.crate{list-style:none; padding:0; margin:4cqi 0 0; display:grid; grid-template-columns:1fr 1fr; gap:3cqi; --s:min(28cqi, 13dvh)}
.crate li{min-width:0; display:flex; flex-direction:column; align-items:center}   /* each record and its name sit centered in their half */
.lp{position:relative; width:calc(var(--s) * 1.38); height:var(--s); border-radius:0}
.lp .wrap{position:absolute; left:calc(var(--s) * .46); top:4%; width:calc(var(--s) * .92); animation:peek 3s ease-in-out infinite}
.crate li + li .lp .wrap{animation-delay:-1.5s}
@keyframes peek{0%,100%{transform:translateX(0)} 50%{transform:translateX(-9%)}}
.lp .disc{animation-duration:5s}
.lp .label{inset:32%; font-size:0}
.crate li + li .label{background:var(--pink)}
.lp .sleeve{position:absolute; left:0; top:0; width:var(--s); height:var(--s); border-radius:2cqi; border:.8cqi solid var(--midnight); background:var(--lilac); color:var(--ube); box-shadow:1cqi 1cqi 0 var(--midnight); display:grid; place-items:center; font-size:7cqi; font-weight:800; transform:rotate(-3deg)}
.crate li + li .sleeve{transform:rotate(2.5deg)}
/* rank beside the name, the same pattern as "1 Matt Maltese" but smaller */
.rank{display:flex; align-items:center; justify-content:center; gap:2cqi; margin-top:3cqi}
.rank b{font-size:12cqi; font-weight:800; font-stretch:75%; line-height:.82; color:var(--pop)}
.rank strong{font-size:5.6cqi; font-weight:800; font-stretch:85%; line-height:1.05}
@media (prefers-reduced-motion:reduce){ .disc, .arm, .tune, .eq i, .lp .wrap, .record.scratch .wrap{animation:none} .tune{opacity:1} }

/* billiards */
.rack{display:flex; align-items:center; justify-content:center; gap:6cqi; margin:1cqi 0 4cqi}


/* cuddles */
.cuddle .blob{width:70cqi; height:70cqi; right:-25cqi; top:-22cqi}
.btn{font:inherit; font-size:5cqi; font-weight:700; border:0; cursor:pointer; border-radius:99px; padding:3.4cqi 6cqi; background:var(--fg); color:var(--bg); align-self:flex-start}
.btn:active{transform:scale(.96)}
.btn:focus-visible{outline:3px solid var(--yolk); outline-offset:3px}
.toast{min-height:6cqi; margin-top:3cqi; font-size:4.4cqi; font-weight:700}

/* hug */
.hug{display:flex; justify-content:center; margin:auto 0}
.hug span{width:34cqi; height:34cqi; border-radius:50%; display:grid; place-items:center; font-size:5cqi; font-weight:800; transition:margin .35s cubic-bezier(.2,.9,.3,1.4)}
.hug span:first-child{background:var(--ube); color:var(--lilac); margin-right:-6cqi; z-index:1}
.hug span:last-child{background:var(--pink); color:var(--midnight); padding-left:9cqi}
.hug.tight span:first-child{margin-right:-13cqi}
.cuddle .btn.push{margin-top:0}

/* 23 */
.jersey{width:62cqi; margin:4cqi auto 0; display:block; transform:rotate(-4deg)}

/* final */
.final .big{font-size:19cqi}
/* last card: it opens bare, then "Happy", "birthday," and "Claire." land one at a time, the whole cast pops in around the cake, and Wito's lines arrive last */
.final .shout{font-size:13.6cqi; line-height:.95}
.final .shout .line{display:block; white-space:nowrap}
.final .shout .w{display:inline-block}
.final .shout .w3{display:block; font-size:25cqi; line-height:.9; width:max-content}   /* her name carries the card */
.slide.on.final .shout .w{animation:land-word .55s cubic-bezier(.2,1.5,.4,1) backwards}
.slide.on.final .shout .w1{animation-delay:.6s}
.slide.on.final .shout .w2{animation-delay:1.4s}
.slide.on.final .shout .w3{animation-delay:2.2s}
@keyframes land-word{from{opacity:0; transform:translateY(8cqi) scale(.5) rotate(-6deg)}}
.photos{display:flex; justify-content:center; gap:1.2cqi; margin:4cqi -6.5cqi 2cqi}   /* three across, edge to edge, none covering another */
.photos div{flex:none; width:min(31.6cqi, 18dvh); aspect-ratio:3/4; background:var(--lilac); color:var(--ube); border:1.4cqi solid #fff; border-bottom-width:4cqi; display:grid; place-items:center; font-size:3.4cqi; font-weight:700; text-align:center; transform:rotate(var(--tilt)); margin:0}
.photos div:nth-child(1){--in:2.9s} .photos div:nth-child(2){--in:3.05s} .photos div:nth-child(3){--in:3.2s}
.slide.on.final .photos div{animation:guest-in .5s cubic-bezier(.2,1.6,.4,1) var(--in) backwards}
/* the cast in two rows like a group photo, everyone in a party hat: Wito front and centre, flanked by Harvest Moon's Claire and the cover's cow;
   behind them the two cows from the 22 card (cheered up), a number 23, and a sharp-dressed agent in glasses */
.final .fill{align-items:flex-end; padding:2cqi 0 0}
.gang{flex:none; width:86cqi; display:flex; flex-direction:column; align-items:center; padding-top:5cqi}
.gang .row{display:flex; justify-content:center; align-items:flex-end; gap:2.2cqi}
.gang .front{position:relative; z-index:1; margin-top:1.5cqi; gap:3cqi}
.final .gang svg{display:block; flex:none; width:min(19.5cqi, 10.5dvh); height:auto; max-width:none; max-height:none; overflow:visible; transform-origin:50% 90%; transform:rotate(var(--tilt))}
.final .gang .front svg{width:min(23cqi, 12dvh)}
.final .gang .front .g1{width:min(33cqi, 17dvh); --tilt:-4deg; --in:3.6s}
.final .gang .g6{--tilt:-7deg; --in:3.75s}
.final .gang .g2{--tilt:6deg; --in:3.9s}
.final .gang .g3{--tilt:-8deg; --in:4.05s}
.final .gang .g5{--tilt:-3deg; --in:4.2s}
.final .gang .g7{--tilt:4deg; --in:4.35s}
.final .gang .g4{--tilt:8deg; --in:4.5s}
.wish{margin-top:1cqi; font-size:4.6cqi; font-weight:500; line-height:1.3}
.signoff{margin-top:2.5cqi; font-size:4.4cqi; font-weight:700; line-height:1.15}
.signoff .wito{font-size:6cqi; font-stretch:80%}
.slide.on.final .gang svg{animation:guest-in .5s cubic-bezier(.2,1.6,.4,1) var(--in) backwards, guest-hop 2.4s ease-in-out calc(var(--in) + .5s) infinite}
@keyframes guest-in{from{opacity:0; transform:translateY(10cqi) scale(.2) rotate(var(--tilt))}}
@keyframes guest-hop{0%,100%{transform:rotate(var(--tilt)) translateY(0)} 50%{transform:rotate(calc(var(--tilt) * -.6)) translateY(-2.2cqi)}}
.slide.on.final .cow .toot{animation:toot 3s ease-in-out 4.6s infinite}
.slide.on.final .cow .say{animation:moo-say 3s ease-in-out 4.6s infinite}
.slide.on.final .cow .awake{animation:eye-open 3s linear 4.6s infinite}
.slide.on.final .cow .shut{animation:eye-shut 3s linear 4.6s infinite}
.slide.on.final .cow .chew{animation:moo-muzzle 3s ease-in-out 4.6s infinite}
.slide.on.final .cow .ear.left{animation:ear-l 3s ease-in-out 4.8s infinite}
.slide.on.final .cow .ear.right{animation:ear-r 3s ease-in-out 4.95s infinite}
.slide.on.final .cow.flip :is(.awake, .shut, .chew, .toot, .say){animation-delay:6.1s}   /* Wito and the cow take turns blowing */
.slide.on.final .late{animation:late-in .6s cubic-bezier(.2,.9,.3,1.2) 3.4s backwards}
.slide.on.final .signoff{animation-delay:5.2s}
@keyframes late-in{from{opacity:0; transform:translateY(5cqi)}}
@media (max-height:720px){ .final .shout .w3{font-size:21cqi} .wish{font-size:4.05cqi} .gang{padding-top:4cqi} .final .gang svg{width:min(19.5cqi, 9.4dvh)} .final .gang .front svg{width:min(23cqi, 10.6dvh)} .final .gang .front .g1{width:min(33cqi, 15dvh)} }
@media (prefers-reduced-motion:reduce){ .slide.on.final .shout span, .slide.on.final .gang svg, .slide.on.final .photos div, .slide.on.final .late, .slide.on.final .cow :is(.toot, .say, .awake, .shut, .chew, .ear){animation:none} }
.row{display:flex; gap:3cqi; flex-wrap:wrap}
.btn.ghost{background:none; color:var(--fg); box-shadow:inset 0 0 0 2px var(--fg)}

/* photo slots: filled by script.js when the file exists in photos/ */
[data-photo], [data-frame]{position:relative; overflow:hidden}
[data-photo] img, [data-frame] img{position:absolute; inset:0; width:100%; height:100%; object-fit:cover}

/* cover: a frame flips edge-on while its photo changes */
.cover.open .polaroid.swap{animation:flip .6s ease-in-out}          /* needs to outrank the unwrap animation on the same frame */
.cover.open .shot.two .polaroid.swap{animation-delay:0s}
@keyframes flip{50%{transform:rotate(var(--tilt)) scaleX(0)} 80%{transform:rotate(var(--tilt)) scale(1.05)}}

/* cover: two party characters share these .cow rules. Wito (.me) sits in the empty top left of the photo area;
   the cow (.flip), a nod to the farm-game song, sits bottom right. Each faces the photos. */
.hero .cow{position:absolute; z-index:2; left:0; top:5cqi; width:min(38cqi, 18.5dvh); height:auto; max-width:none; max-height:none; overflow:visible; transform:rotate(-6deg); transform-origin:50% 90%}
.cover:not(.open) .cow{visibility:hidden}
.cover.open .cow{animation:stick .4s cubic-bezier(.2,1.6,.4,1) .6s both, moo 2.8s ease-in-out 1.4s infinite}
/* the cow hops and sways in its party hat; its ears flick and its eyes glance around */
@keyframes moo{0%,100%{transform:translate(0,0) rotate(-6deg)} 18%{transform:translate(0,-3.5cqi) rotate(-11deg)} 36%{transform:translate(1.5cqi,0) rotate(2deg)} 54%{transform:translate(1.5cqi,-2.5cqi) rotate(7deg)} 72%{transform:translate(0,0) rotate(-2deg)}}
.cow .ear, .cow .eye, .cow .chew, .cow .pupil, .cow .toot, .cow .say{transform-box:fill-box}
.cow .ear.left{transform-origin:100% 60%}
.cow .ear.right{transform-origin:0% 60%}
.cow .eye{transform-origin:50% 50%}
.cow .chew{transform-origin:50% 0%}
.cow .toot{transform-origin:0% 50%; transform:scaleX(.3)}
.cow .shut{opacity:0}
.cow .say{transform-origin:0% 100%; opacity:0}
.cover.open .cow .ear.left{animation:ear-l 3s ease-in-out 1.6s infinite}
.cover.open .cow .ear.right{animation:ear-r 3s ease-in-out 1.75s infinite}
.cover.open .cow .awake{animation:eye-open 3s linear 1.4s infinite}   /* open eyes swap for happy arcs while it blows */
.cover.open .cow .shut{animation:eye-shut 3s linear 1.4s infinite}
/* one toot every 3 seconds: the party blower shoots out, the eyes squeeze shut with joy, the cheeks puff and a "moo" pops up */
.cover.open .cow .pupil{animation:look 3s ease-in-out 1.4s infinite}
.cover.open .cow .chew{animation:moo-muzzle 3s ease-in-out 1.4s infinite}
.cover.open .cow .toot{animation:toot 3s ease-in-out 1.4s infinite}
.cover.open .cow .say{animation:moo-say 3s ease-in-out 1.4s infinite}
@keyframes ear-l{0%,64%,100%{transform:rotate(0deg)} 72%{transform:rotate(-16deg)} 82%{transform:rotate(9deg)} 92%{transform:rotate(-6deg)}}
@keyframes ear-r{0%,64%,100%{transform:rotate(0deg)} 72%{transform:rotate(16deg)} 82%{transform:rotate(-9deg)} 92%{transform:rotate(6deg)}}
@keyframes eye-open{0%,41%,80%,100%{opacity:1} 44%,77%{opacity:0}}
@keyframes eye-shut{0%,41%,80%,100%{opacity:0} 44%,77%{opacity:1}}
@keyframes look{0%,100%{transform:translate(0,0)} 15%{transform:translate(1.400px,.6px)} 30%{transform:translate(1.400px,-.6px)} 45%{transform:translate(-.8px,-1.200px)} 70%{transform:translate(-.8px,-1.200px)} 85%{transform:translate(-2.400px,.4px)}}
@keyframes toot{0%,38%,84%,100%{transform:scaleX(.3)} 48%{transform:scaleX(1.1)} 54%,74%{transform:scaleX(1)}}
@keyframes moo-muzzle{0%,38%,82%,100%{transform:scale(1,1)} 48%,72%{transform:scale(1.04,1.12)}}
@keyframes moo-say{0%,40%{opacity:0; transform:scale(.3)} 48%{opacity:1; transform:scale(1.15)} 54%,72%{opacity:1; transform:scale(1)} 82%,100%{opacity:0; transform:scale(.6)}}

.hero .cow.me{top:7cqi}                    /* Wito is a round photo sticker with a hat and blower drawn on */
.cover.open .cow.me{animation:stick .4s cubic-bezier(.2,1.6,.4,1) .6s both, sway 3.4s ease-in-out 1.4s infinite}
@keyframes sway{0%,100%{transform:translate(0,0) rotate(-5deg)} 50%{transform:translate(0,-1.600cqi) rotate(3deg)}}   /* a real face only bobs gently; no hopping */
.hero .cow.flip{left:auto; top:auto; right:0; bottom:-2cqi; width:min(34cqi, 16.5dvh); transform:rotate(6deg)}
.cow.flip .toot{transform-origin:100% 50%}
.cow.flip .say{transform-origin:100% 100%}
.cover.open .cow.flip{animation:stick .4s cubic-bezier(.2,1.6,.4,1) .75s both, moo-r 2.8s ease-in-out 2.9s infinite}
@keyframes moo-r{0%,100%{transform:translate(0,0) rotate(6deg)} 18%{transform:translate(0,-3.5cqi) rotate(11deg)} 36%{transform:translate(-1.5cqi,0) rotate(-2deg)} 54%{transform:translate(-1.5cqi,-2.5cqi) rotate(-7deg)} 72%{transform:translate(0,0) rotate(2deg)}}
.cover.open .cow.flip :is(.awake, .shut, .pupil, .chew, .toot, .say){animation-delay:2.9s}   /* the two take turns blowing */
.cover.open .cow.flip .ear.left{animation-delay:3.1s}
.cover.open .cow.flip .ear.right{animation-delay:3.25s}

/* cover: hearts, ice cubes, pasta and eggs drift out from behind the photos */
.burst{position:absolute; inset:0; z-index:0; pointer-events:none}
.shot{z-index:1}
.spark{position:absolute; width:var(--s); height:var(--s); margin:calc(var(--s) / -2) 0 0 calc(var(--s) / -2); animation:drift var(--t) ease-out forwards}
.spark svg{display:block; width:100%; height:100%; overflow:visible}
@keyframes drift{0%{transform:translate(0,0) scale(.3) rotate(0deg); opacity:0} 15%{opacity:1} 70%{opacity:1} 100%{transform:translate(var(--dx), var(--dy)) scale(1) rotate(var(--r)); opacity:0}}

/* cover: a heart or ice cube pops where she taps */
.tappop{position:absolute; z-index:6; width:13cqi; height:13cqi; margin:-6.5cqi 0 0 -6.5cqi; pointer-events:none}   /* thrown and dropped by script.js */
.confetto{position:absolute; z-index:5; margin:-4px 0 0 -4px; pointer-events:none}
.tappop svg{display:block; width:100%; height:100%; overflow:visible}
@keyframes pop-up{0%{transform:translate(0,0) scale(.2) rotate(0deg); opacity:1} 25%{transform:translate(calc(var(--dx) * .3), -4cqi) scale(1.15) rotate(calc(var(--r) * .4)); opacity:1} 100%{transform:translate(var(--dx), -20cqi) scale(.9) rotate(var(--r)); opacity:0}}
@keyframes pop-fade{from{opacity:1} to{opacity:0}}
.polaroid .has-photo{border:0; padding:0}


@media (prefers-reduced-motion:reduce){
  .nowplaying i b, .nowplaying.in{animation:none}
  .cover.open .polaroid.swap, .cover.open .cow, .cover.open .cow .ear, .cover.open .cow .awake, .cover.open .cow .shut, .cover.open .cow .chew, .cover.open .cow .pupil, .cover.open .cow .toot, .cover.open .cow .say{animation:none}
  .tappop{animation:pop-fade .7s ease-out forwards}
  .rain i{animation:none; opacity:.9; top:var(--y); transform:rotate(var(--r))}
  .glass, .sideglass, .glass .cube, .sideglass rect, .glint{animation:none}
  .slide.on .rise, .glass.shake svg, .gift, .cover.tapped .gift, .cover.open .polaroid{animation:none}
  .cover.open .gift{animation:none; display:none}
}
