/* ───────────────────────── Tokens ───────────────────────── */
:root {
  /* Scene. To use your own background art, drop it in /assets and set:
     --scene-image: url("assets/your-background.jpg");  (the SVG hills/clouds hide automatically) */
  --scene-image: none;
  --sky-top: #2E9BF0;
  --sky-mid: #6CC5FA;
  --sky-low: #C4EBFF;

  --blue: #007AFB;            /* Pulsera / iMessage blue */
  --blue-hi: #3D9CFF;
  --blue-lo: #0066E0;
  --gray-bub: #ECECEF;
  --ink: #0B0B0F;
  --ink-2: #3C3C43;
  --ink-3: #8A8A8E;
  --line: rgba(60, 60, 67, .12);
  --gold: #F5B301;
  --silver: #C3CCD6;
  --bronze: #E08C45;
  --outline: #0E5DB5;

  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", Inter, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-game: Fredoka, "SF Pro Rounded", ui-rounded, var(--font);

  /* iMessage tail shape, used as a mask so it works on any background */
  --tail: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 20'%3E%3Cpath d='M40 0V20H2.6C1.2 20 .3 19.3.9 18.8 4.6 15.6 7 11.3 7 4V0Z'/%3E%3C/svg%3E");
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: 84px; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  color: var(--ink);
  background: linear-gradient(180deg, var(--sky-top) 0%, var(--sky-mid) 45%, var(--sky-low) 100%) fixed;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
button, input, textarea { font: inherit; color: inherit; }
a { color: inherit; }
img { display: block; }

/* ───────────────────────── Scene ───────────────────────── */
.scene { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden;
  background: var(--scene-image) center / cover no-repeat; }
.scene .sun { position: absolute; top: 90px; right: max(3vw, calc(50vw - 560px)); width: 110px; height: 110px; border-radius: 50%;
  background: radial-gradient(circle, #FFF6B8 0 45%, #FFE26A 46% 62%, rgba(255, 226, 106, 0) 63%);
  box-shadow: 0 0 80px 30px rgba(255, 240, 160, .45); }
.cloud { position: absolute; width: 220px; filter: drop-shadow(0 6px 0 rgba(30, 120, 200, .12)); animation: drift linear infinite; }
.c1 { top: 12vh; left: -240px; width: 240px; animation-duration: 95s;  animation-delay: -20s; }
.c2 { top: 30vh; left: -240px; width: 160px; animation-duration: 130s; animation-delay: -80s; opacity: .95; }
.c3 { top: 48vh; left: -240px; width: 200px; animation-duration: 110s; animation-delay: -55s; }
.c4 { top: 20vh; left: -240px; width: 130px; animation-duration: 150s; animation-delay: -120s; opacity: .9; }
.c5 { top: 62vh; left: -240px; width: 180px; animation-duration: 120s; animation-delay: -10s; }
@keyframes drift { to { transform: translateX(calc(100vw + 520px)); } }
.hills { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: 34vh; min-height: 200px; }
body.has-scene-image .scene > * { display: none; }

/* ───────────────────────── Nav (sticky) ───────────────────────── */
.nav { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: max(10px, env(safe-area-inset-top)) max(16px, calc(50vw - 680px)) 10px; transition: background .25s, box-shadow .25s; }
.nav.scrolled { background: rgba(46, 155, 240, .55); backdrop-filter: blur(16px) saturate(1.4); -webkit-backdrop-filter: blur(16px) saturate(1.4);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .25); }
.brand { display: inline-flex; align-items: center; background: #fff; border-radius: 999px; padding: 9px 16px; flex: none;
  box-shadow: 0 4px 0 rgba(0, 70, 150, .18), 0 8px 20px rgba(0, 60, 140, .15); }
.brand-full { height: 24px; width: auto; }
.brand-mark { display: none; width: 30px; height: 30px; }
.nav-actions { display: flex; align-items: center; gap: 12px; }

/* Bubble-shaped buttons: grey = incoming (tail left), blue = outgoing (tail right) */
.nav-bubble { position: relative; isolation: isolate; border: 0; cursor: pointer; text-decoration: none; white-space: nowrap;
  font-weight: 600; font-size: 16px; line-height: 1; padding: 12px 16px; border-radius: 20px; transition: transform .12s;
  box-shadow: 0 4px 14px rgba(0, 60, 140, .2); }
.nav-bubble:active { transform: scale(.96); }
.nav-bubble::before { content: ""; position: absolute; z-index: -1; bottom: 0; width: 40px; height: 20px; background: inherit;
  -webkit-mask: var(--tail) no-repeat; mask: var(--tail) no-repeat; }
.nav-bubble.in { background: var(--gray-bub); color: var(--ink); }
.nav-bubble.in::before { left: -6px; }
.nav-bubble.out { background: var(--blue); color: #fff; }
.nav-bubble.out::before { right: -6px; transform: scaleX(-1); }

/* ───────────────────────── Layout ───────────────────────── */
.page { position: relative; z-index: 1; max-width: 1360px; margin: 0 auto; padding: 0 16px 150px; }
.rows { max-width: 900px; margin: 0 auto; }
.how, .foot { max-width: 900px; margin-left: auto; margin-right: auto; }
.hero { text-align: center; color: #fff; padding: 4px 0 18px; }
.hero h1 { font-family: var(--font-game); font-weight: 700; font-size: clamp(36px, 9vw, 64px); line-height: 1; margin: 0 0 10px;
  -webkit-text-stroke: 8px var(--outline); paint-order: stroke fill; text-shadow: 0 6px 0 #0A4A93; }
.hero .sub { display: inline-block; margin: 0; font-size: 16px; font-weight: 500; line-height: 1.35;
  background: rgba(10, 80, 170, .32); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); padding: 9px 16px; border-radius: 999px; }

/* Buttons (sheet) */
.btn { appearance: none; border: 0; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; justify-content: center;
  gap: 8px; height: 52px; padding: 0 24px; border-radius: 999px; font-weight: 600; font-size: 17px; transition: transform .12s, box-shadow .12s; }
.btn:active { transform: translateY(2px); }
.btn-primary { background: linear-gradient(180deg, var(--blue-hi), var(--blue)); color: #fff; box-shadow: 0 5px 0 var(--blue-lo), 0 10px 24px rgba(0, 90, 220, .3); }
.btn-primary:active { box-shadow: 0 3px 0 var(--blue-lo); }
.btn-primary[disabled] { opacity: .55; cursor: not-allowed; }
.btn-block { width: 100%; }
.link-btn { background: none; border: 0; color: var(--blue); font-size: 17px; cursor: pointer; padding: 6px 0; }

/* ───────────────────────── Bubbles (shared) ───────────────────────── */
.thread { padding: 6px 0 10px; }
.bubble { position: relative; isolation: isolate; max-width: min(100%, 560px); background: var(--bub, var(--gray-bub)); color: var(--bub-ink, var(--ink));
  border-radius: 22px; padding: var(--pad-y, 9px) var(--pad-x, 14px); line-height: 1.3; overflow-wrap: anywhere; }
.bubble.tail::before { content: ""; position: absolute; z-index: -1; bottom: 0; left: -6px; width: 40px; height: 20px;
  background: var(--bub-end, var(--bub, var(--gray-bub))); -webkit-mask: var(--tail) no-repeat; mask: var(--tail) no-repeat; }

/* ───────────────────────── Leaderboard entries ───────────────────────── */
.msg { --av: 52px; --name: 20px; --pad-x: 18px; --pad-y: 13px; --bub: var(--gray-bub); --bub-ink: var(--ink);
  display: grid; grid-template-columns: 40px var(--av) 1fr; column-gap: 12px; align-items: end; margin-top: 14px; }
.msg .rank { grid-row: 1 / span 2; align-self: center; text-align: right; font-family: var(--font-game); font-weight: 700; font-size: 26px; color: #fff;
  -webkit-text-stroke: 5px var(--outline); paint-order: stroke fill; }
.msg .av { grid-column: 2; grid-row: 1; width: var(--av); height: var(--av); align-self: end; box-shadow: 0 0 0 3px #fff, 0 4px 12px rgba(0, 50, 120, .25); }
.msg .stack { grid-column: 3; grid-row: 1; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.msg .under { grid-column: 3; grid-row: 2; font-size: 13px; font-weight: 600; color: #fff; margin: 6px 0 0 8px; text-shadow: 0 1px 3px rgba(0, 50, 120, .55); }
.msg .bubble { box-shadow: 0 6px 18px rgba(0, 60, 140, .18); }

.av { border-radius: 50%; overflow: hidden; display: grid; place-items: center; color: #fff; font-weight: 700;
  font-size: calc(var(--av) * .38); letter-spacing: .3px; background: linear-gradient(180deg, #A9AEB8, #868B96); flex: none; }
.av img { width: 100%; height: 100%; object-fit: cover; }

.bubble .b-name { font-weight: 700; font-size: var(--name); letter-spacing: -.3px; line-height: 1.15; }
.bubble .b-msg { font-size: 17px; margin-top: 4px; }
.bubble .b-row { display: flex; align-items: baseline; gap: 12px; justify-content: space-between; }
.bubble .b-amt { font-family: var(--font-game); font-weight: 600; font-size: 22px; white-space: nowrap; color: var(--blue); }
.bubble .b-link { display: inline-flex; gap: 4px; align-items: center; margin-top: 6px; font-size: 14.5px; color: var(--blue); text-decoration: none; font-weight: 600; }
.bubble .b-link:hover { text-decoration: underline; }

/* Tapback badge (rank medal) */
.tapback { position: absolute; top: -20px; right: -8px; width: 46px; height: 46px; border-radius: 50%; background: #fff; display: grid; place-items: center;
  font-size: 24px; box-shadow: 0 2px 8px rgba(0, 0, 0, .2); z-index: 2; }
.tapback::after { content: ""; position: absolute; bottom: -5px; left: 5px; width: 10px; height: 10px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .15); }

/* ───────────────────────── Top 5 ─────────────────────────
   #1 huge across the full width. Underneath: #2 and #3 big, side by side,
   with #4 and #5 stacked in the space next to #3.
   Phone: #1 full width, then #2 #3, then #4 #5.                    */
.podium { display: grid; gap: 14px 12px; grid-template-columns: 1fr 1fr; grid-template-areas: "p1 p1" "p2 p3" "p4 p5"; margin-top: 12px; }
.pod.p1 { grid-area: p1; } .pod.p2 { grid-area: p2; } .pod.p3 { grid-area: p3; } .pod.p4 { grid-area: p4; } .pod.p5 { grid-area: p5; }
.podium.n1 { grid-template-areas: "p1 p1"; } .podium.n2 { grid-template-areas: "p1 p1" "p2 p2"; }

.pod { --av: 40px; --name: 19px; --amt: 26px; --msg: 14.5px; --pad-x: 14px; --pad-y: 12px; --lines: 2; --r: 24px;
  --bub: linear-gradient(180deg, var(--blue-hi), var(--blue)); --bub-end: var(--blue); --bub-ink: #fff;
  min-width: 0; display: flex; flex-direction: column; }
.pod.p4, .pod.p5 { --bub: #fff; --bub-end: #fff; --bub-ink: var(--ink); --name: 16px; --amt: 20px; --av: 34px; --msg: 13.5px; }
.pod.p1 { --av: 58px; --name: 34px; --amt: 52px; --msg: 17px; --pad-x: 20px; --pad-y: 18px; --lines: 3; --r: 30px; }
.pod .bubble { flex: 1 1 auto; display: flex; flex-direction: column; width: 100%; max-width: none; border-radius: var(--r); box-shadow: 0 10px 26px rgba(0, 80, 200, .3); }
.pod.p4 .bubble, .pod.p5 .bubble { box-shadow: 0 6px 18px rgba(0, 60, 140, .18); }
.pod-main { min-width: 0; }
.pod .b-name { font-size: var(--name); line-height: 1.05; letter-spacing: -.02em; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.pod .b-msg { font-size: var(--msg); line-height: 1.3; margin-top: .45em; opacity: .97;
  overflow: hidden; display: -webkit-box; -webkit-line-clamp: var(--lines); -webkit-box-orient: vertical; }
.pod-link { display: inline-block; max-width: 100%; margin-top: 8px; font-size: 13px; font-weight: 700; text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  background: rgba(255, 255, 255, .2); color: inherit; padding: 4px 10px; border-radius: 999px; vertical-align: top; }
.pod-link:hover { background: rgba(255, 255, 255, .32); }
.pod.p4 .pod-link, .pod.p5 .pod-link { background: #EEF5FF; color: var(--blue); }
.pod-bottom { margin-top: auto; padding-top: 10px; display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 0 10px; }
.pod-amt { display: flex; align-items: baseline; gap: 6px; }
.pod-amt b { font-family: var(--font-game); font-weight: 600; font-size: var(--amt); line-height: .9; }
.pod.p4 .pod-amt b, .pod.p5 .pod-amt b { color: var(--blue); }
.pod-amt span { font-size: 13px; opacity: .8; }
.place { display: inline-flex; align-items: center; font-family: var(--font-game); font-weight: 600; font-size: 11.5px; letter-spacing: 1.2px;
  text-transform: uppercase; padding: 4px 10px; border-radius: 999px; background: rgba(255, 255, 255, .22); margin-bottom: 8px; white-space: nowrap; }
.pod.p1 .place { background: #FFE27A; color: #6B4A00; }
.pod.p2 .place { background: #E8EEF5; color: #3F4B59; }
.pod.p3 .place { background: #FFD2AE; color: #6A3610; }
.pod.p4 .place, .pod.p5 .place { background: #EEF0F4; color: var(--ink-3); }
.pod .tapback { top: -16px; right: -6px; width: 40px; height: 40px; font-size: 22px; }
.pod.p1 .tapback { width: 56px; height: 56px; font-size: 32px; top: -22px; }

.pod-foot { display: flex; align-items: center; gap: 10px; margin-top: 8px; min-width: 0; }
.pod-foot .av { width: var(--av); height: var(--av); box-shadow: 0 0 0 3px #fff, 0 4px 12px rgba(0, 50, 120, .25); }
.pod.p1 .pod-foot .av { box-shadow: 0 0 0 3px #fff, 0 0 0 7px var(--gold), 0 8px 20px rgba(0, 50, 120, .3); }
.pod.p2 .pod-foot .av { box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--silver), 0 6px 16px rgba(0, 50, 120, .25); }
.pod.p3 .pod-foot .av { box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--bronze), 0 6px 16px rgba(0, 50, 120, .25); }
.pod-foot .under { min-width: 0; font-size: 12px; font-weight: 600; color: #fff; line-height: 1.3; text-shadow: 0 1px 3px rgba(0, 50, 120, .6);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.beat { margin-top: 10px; display: inline-flex; align-items: center; border: 0; cursor: pointer; background: #fff; color: var(--blue);
  font-weight: 700; font-size: 14px; height: 36px; padding: 0 14px; border-radius: 999px; box-shadow: 0 3px 0 rgba(0, 40, 120, .2); white-space: nowrap; }

/* Tablet + laptop: #1 across the top, then [#2][#3][#4 over #5] */
@media (min-width: 700px) {
  .podium { grid-template-columns: 1fr 1fr .8fr; gap: 26px 20px; grid-template-areas: "p1 p1 p1" "p2 p3 p4" "p2 p3 p5"; }
  .podium.n1 { grid-template-areas: "p1 p1 p1"; } .podium.n2 { grid-template-areas: "p1 p1 p1" "p2 p2 ."; }
  .podium.n3 { grid-template-areas: "p1 p1 p1" "p2 p3 ."; } .podium.n4 { grid-template-areas: "p1 p1 p1" "p2 p3 p4" "p2 p3 ."; }
  .pod { --av: 52px; --name: 27px; --amt: 42px; --msg: 16.5px; --pad-x: 20px; --pad-y: 18px; --lines: 3; --r: 28px; }
  .pod.p4, .pod.p5 { --av: 40px; --name: 18px; --amt: 24px; --msg: 14px; --pad-x: 16px; --pad-y: 13px; --lines: 2; --r: 22px; }
  .pod.p1 { --av: 72px; --name: 50px; --amt: 80px; --msg: 20px; --pad-x: 30px; --pad-y: 26px; --r: 38px; }
  /* #1: words on the left, the big amount + beat button on the right */
  .pod.p1 .bubble { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 32px; align-items: end; }
  .pod.p1 .pod-bottom { margin: 0; padding: 0; flex-direction: column; align-items: flex-end; }
  .pod.p1 .pod-amt { flex-direction: column; align-items: flex-end; gap: 2px; }
  .pod.p1 .b-msg { max-width: 46ch; }
  .pod.p1 .place { font-size: 13px; padding: 5px 12px; }
  .pod.p1 .tapback { width: 66px; height: 66px; font-size: 38px; top: -26px; right: -8px; }
  .pod-foot .under { font-size: 13px; }
  .pod.p1 .pod-foot .under { font-size: 14px; }
  /* #1 photo sits beside the bubble (bottom-left, under the tail) to save height */
  .pod.p1 { display: grid; grid-template-columns: calc(var(--av) + 14px) minmax(0, 1fr); column-gap: 12px; align-items: end; }
  .pod.p1 .bubble { grid-column: 2; grid-row: 1; }
  .pod.p1 .pod-foot { grid-column: 1; grid-row: 1; flex-direction: column; align-items: center; gap: 8px; margin: 0 0 2px; }
  .pod.p1 .pod-foot .under { white-space: normal; text-align: center; font-size: 12.5px; }
  /* #2 #3 keep their natural height; #4 #5 become compact rows (photo beside bubble) */
  .pod.p2, .pod.p3, .pod.p4, .pod.p5 { align-self: start; }
  .pod.p4, .pod.p5 { display: grid; grid-template-columns: var(--av) minmax(0, 1fr); column-gap: 10px; align-items: end; }
  .pod.p4 .bubble, .pod.p5 .bubble { grid-column: 2; grid-row: 1; }
  .pod.p4 .pod-foot, .pod.p5 .pod-foot { grid-column: 1; grid-row: 1; margin: 0; }
  .pod.p4 .under, .pod.p5 .under { display: none; }
  .pod.p4 .b-msg, .pod.p5 .b-msg { -webkit-line-clamp: 1; }
  .pod.p4 .place, .pod.p5 .place { margin-bottom: 6px; }
  .beat { font-size: 15px; height: 40px; padding: 0 18px; margin-top: 12px; }
}

/* Laptop: exaggerate */
@media (min-width: 1100px) {
  .podium { gap: 30px 24px; }
  .pod { --av: 64px; --name: 36px; --amt: 58px; --msg: 18.5px; --pad-x: 26px; --pad-y: 24px; --r: 34px; }
  .pod.p4, .pod.p5 { --av: 46px; --name: 21px; --amt: 30px; --msg: 15px; --pad-x: 18px; --pad-y: 15px; --r: 24px; }
  .pod.p1 { --av: 88px; --name: 76px; --amt: 120px; --msg: 24px; --pad-x: 44px; --pad-y: 36px; --r: 48px; }
  .pod.p1 .b-name { -webkit-line-clamp: 1; }
  .pod.p1 .pod-link { font-size: 15px; padding: 6px 14px; margin-top: 14px; }
  .pod.p1 .tapback { width: 80px; height: 80px; font-size: 46px; top: -30px; right: -10px; }
  .pod.p1 .place { font-size: 14px; }
  .beat { font-size: 16px; height: 44px; padding: 0 20px; }
  .pod.p1 .pod-foot .under { font-size: 15px; }
}

/* Shorter laptop screens: keep #1–#3 above the fold */
@media (min-width: 1100px) and (max-height: 820px) {
  .hero { padding-bottom: 8px; }
  .hero h1 { font-size: 50px; margin-bottom: 8px; }
  .hero .sub { font-size: 14.5px; padding: 6px 14px; }
  .podium { gap: 22px 22px; }
  .pod { --av: 52px; --name: 30px; --amt: 46px; --msg: 16.5px; --lines: 2; --pad-y: 18px; }
  .pod.p4, .pod.p5 { --av: 40px; --name: 19px; --amt: 26px; --msg: 14px; --pad-y: 12px; --lines: 1; }
  .pod.p1 { --av: 70px; --name: 64px; --amt: 100px; --msg: 21px; --pad-y: 28px; }
  .pod-foot { margin-top: 6px; }
}
@media (min-width: 1100px) and (max-height: 700px) {
  .hero .sub { display: none; }
  .pod.p1 { --name: 56px; --amt: 86px; --pad-y: 24px; --lines: 2; }
  .pod { --lines: 1; }
}

/* ───────── Top-5 profile pictures: exaggerated (they double as brand logos) ─────────
   Phone: under the bubble tail, big.  Laptop: #1 #2 #3 beside their bubble, huge. */
.pod .tapback.num { font-family: var(--font-game); font-weight: 700; font-size: 20px; color: var(--blue); }
.pod.p1 { --av: 88px; }
.pod.p2, .pod.p3 { --av: 60px; }
.pod.p4, .pod.p5 { --av: 44px; }
.pod-foot .av { font-size: calc(var(--av) * .36); }
.pod.p1 .pod-foot .av { box-shadow: 0 0 0 4px #fff, 0 0 0 9px var(--gold), 0 10px 24px rgba(0, 50, 120, .3); }
.pod.p1 .bubble { padding-top: calc(var(--pad-y) + 4px); }

@media (min-width: 700px) {
  .pod.p1 { --av: 150px; }
  .pod.p2, .pod.p3 { --av: 80px; }
  .pod.p4, .pod.p5 { --av: 54px; }
  .pod.p1 { grid-template-columns: var(--av) minmax(0, 1fr); column-gap: 22px; align-items: center; }
  .pod.p1 .bubble { align-self: stretch; }
  .pod.p1 .pod-foot { gap: 12px; margin: 0; }
  .pod.p1 .pod-foot .av { box-shadow: 0 0 0 5px #fff, 0 0 0 12px var(--gold), 0 14px 30px rgba(0, 50, 120, .35); }
  .pod.p1 .pod-foot .under { font-size: 13.5px; }
  .podium { padding: 0 14px; }
}

@media (min-width: 1100px) {
  .pod.p1 { --av: 210px; column-gap: 30px; }
  .pod.p2, .pod.p3 { --av: 128px; }
  .pod.p4, .pod.p5 { --av: 64px; }
  /* #2 and #3 also get their photo to the left of the bubble */
  .pod.p2, .pod.p3 { display: grid; grid-template-columns: var(--av) minmax(0, 1fr); column-gap: 18px; align-items: center; }
  .pod.p2 .bubble, .pod.p3 .bubble { grid-column: 2; grid-row: 1; align-self: stretch; }
  .pod.p2 .pod-foot, .pod.p3 .pod-foot { grid-column: 1; grid-row: 1; flex-direction: column; align-items: center; gap: 10px; margin: 0; }
  .pod.p2 .pod-foot .under, .pod.p3 .pod-foot .under { white-space: normal; text-align: center; }
  .pod.p2 .pod-foot .av { box-shadow: 0 0 0 4px #fff, 0 0 0 10px var(--silver), 0 10px 24px rgba(0, 50, 120, .3); }
  .pod.p3 .pod-foot .av { box-shadow: 0 0 0 4px #fff, 0 0 0 10px var(--bronze), 0 10px 24px rgba(0, 50, 120, .3); }
  .pod.p1 .pod-foot .av { box-shadow: 0 0 0 6px #fff, 0 0 0 14px var(--gold), 0 16px 36px rgba(0, 50, 120, .35); }
  .pod.p1 .pod-foot .under { font-size: 15px; }
  .pod .tapback.num { font-size: 22px; }
}
@media (min-width: 1100px) and (max-height: 820px) {
  .pod.p1 { --av: 176px; }
  .pod.p2, .pod.p3 { --av: 108px; }
  .pod.p4, .pod.p5 { --av: 54px; }
}
@media (min-width: 1100px) and (max-height: 700px) {
  .pod.p1 { --av: 150px; }
  .pod.p2, .pod.p3 { --av: 92px; }
}

/* ───────── Layout v3: #1 full width · #2 #3 big halves · #4 #5 row below ───────── */
.pod.p2, .pod.p3 { --name: 21px; --amt: 30px; --av: 64px; }
@media (min-width: 700px) {
  .podium { grid-template-columns: 1fr 1fr; grid-template-areas: "p1 p1" "p2 p3" "p4 p5"; }
  .podium.n1 { grid-template-areas: "p1 p1"; } .podium.n2 { grid-template-areas: "p1 p1" "p2 ."; }
  .podium.n3 { grid-template-areas: "p1 p1" "p2 p3"; } .podium.n4 { grid-template-areas: "p1 p1" "p2 p3" "p4 ."; }
  .pod.p2, .pod.p3 { --av: 100px; --name: 34px; --amt: 56px; --msg: 18px; --pad-x: 24px; --pad-y: 22px; --r: 32px; --lines: 3; align-self: stretch; }
  .pod.p2 .tapback, .pod.p3 .tapback { width: 54px; height: 54px; font-size: 30px; top: -22px; }
  .pod.p4, .pod.p5 { --av: 58px; --name: 20px; --amt: 28px; --msg: 15px; --pad-x: 18px; --pad-y: 15px; }
}
@media (min-width: 1100px) {
  .pod.p2, .pod.p3 { --av: 176px; --name: 48px; --amt: 82px; --msg: 21px; --pad-x: 34px; --pad-y: 30px; --r: 42px; column-gap: 26px; }
  .pod.p2 .tapback, .pod.p3 .tapback { width: 66px; height: 66px; font-size: 38px; top: -26px; right: -8px; }
  .pod.p2 .pod-foot .av { box-shadow: 0 0 0 5px #fff, 0 0 0 13px var(--silver), 0 14px 30px rgba(0, 50, 120, .3); }
  .pod.p3 .pod-foot .av { box-shadow: 0 0 0 5px #fff, 0 0 0 13px var(--bronze), 0 14px 30px rgba(0, 50, 120, .3); }
  .pod.p2 .pod-foot .under, .pod.p3 .pod-foot .under { font-size: 14px; }
  .pod.p2 .pod-link, .pod.p3 .pod-link { font-size: 14.5px; padding: 5px 12px; margin-top: 12px; }
  .pod.p4, .pod.p5 { --av: 76px; --name: 24px; --amt: 34px; --msg: 16px; --pad-x: 22px; --pad-y: 18px; --lines: 2; column-gap: 14px; }
  .pod.p4 .b-msg, .pod.p5 .b-msg { -webkit-line-clamp: 2; }
  .pod .tapback.num { width: 48px; height: 48px; font-size: 24px; top: -18px; }
}
@media (min-width: 1100px) and (max-height: 820px) {
  .pod.p2, .pod.p3 { --av: 146px; --name: 40px; --amt: 66px; --msg: 18.5px; --pad-y: 24px; --lines: 2; }
  .pod.p4, .pod.p5 { --av: 64px; --name: 21px; --amt: 30px; }
}
@media (min-width: 1100px) and (max-height: 700px) {
  .pod.p2, .pod.p3 { --av: 124px; --name: 34px; --amt: 56px; --pad-y: 20px; }
}

.pod.is-me .bubble, .msg.is-me .bubble { outline: 4px solid #FFD43B; outline-offset: 3px; }
.msg.flash, .pod.flash { animation: pop .6s cubic-bezier(.2, 1.4, .4, 1); }
@keyframes pop { from { transform: scale(.85); opacity: 0; } to { transform: none; opacity: 1; } }

/* Divider between podium and the rest */
.divider { display: flex; align-items: center; gap: 12px; margin: 44px 4px 4px; font-family: var(--font-game); font-size: 18px; color: #fff; font-weight: 600;
  letter-spacing: .5px; -webkit-text-stroke: 4px var(--outline); paint-order: stroke fill; }
.divider::before, .divider::after { content: ""; flex: 1; height: 3px; border-radius: 2px; background: rgba(255, 255, 255, .6); }

/* Typing indicator = your empty spot */
.typing-row { display: grid; grid-template-columns: 40px 52px 1fr; column-gap: 12px; align-items: center; margin-top: 20px; cursor: pointer; }
.typing-row .rank { text-align: right; font-family: var(--font-game); font-weight: 700; font-size: 26px; color: #FFE14D; -webkit-text-stroke: 5px var(--outline); paint-order: stroke fill; }
.typing-row .av { --av: 52px; width: 52px; height: 52px; background: rgba(255, 255, 255, .5); border: 3px dashed #fff; color: #fff; font-size: 22px; }
.typing-row .spot { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.typing { display: inline-flex; gap: 6px; padding: 16px 20px; box-shadow: 0 6px 18px rgba(0, 60, 140, .18); }
.typing i { width: 10px; height: 10px; border-radius: 50%; background: #9C9CA1; animation: blink 1.3s infinite; }
.typing i:nth-child(2) { animation-delay: .18s; } .typing i:nth-child(3) { animation-delay: .36s; }
@keyframes blink { 0%, 60%, 100% { opacity: .35; transform: translateY(0); } 30% { opacity: 1; transform: translateY(-2px); } }
.typing-row .cta { font-size: 15px; color: #fff; font-weight: 700; margin-left: 8px; text-shadow: 0 1px 3px rgba(0, 50, 120, .55); }
.empty { text-align: center; color: #fff; padding: 40px 10px; font-size: 18px; font-weight: 600; text-shadow: 0 1px 3px rgba(0, 50, 120, .5); }

/* ───────────────────────── How it works ───────────────────────── */
.how { margin-top: 70px; }
.how-head { text-align: center; color: #fff; }
.how-head .founders { display: flex; justify-content: center; }
.how-head .founders img { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; object-position: center 25%; background: #DCEBFF; margin: 0 -8px;
  box-shadow: 0 0 0 3px #fff, 0 6px 16px rgba(0, 50, 120, .25); }
.how-head h2 { font-family: var(--font-game); font-weight: 700; font-size: 40px; margin: 14px 0 4px; -webkit-text-stroke: 6px var(--outline); paint-order: stroke fill; text-shadow: 0 5px 0 #0A4A93; }
.how-head p { margin: 0; font-size: 15px; font-weight: 600; text-shadow: 0 1px 3px rgba(0, 50, 120, .5); }

.chat { max-width: 600px; margin: 0 auto; }
.chat .row { display: flex; align-items: flex-end; gap: 10px; margin-top: 4px; }
.chat .row.me { justify-content: flex-end; }
.chat .row .av { --av: 36px; width: 36px; height: 36px; background: #DCEBFF; visibility: hidden; box-shadow: 0 0 0 2px #fff; }
.chat .row .av img { object-position: center 25%; }
.chat .row.show-av .av { visibility: visible; }
.chat .who { font-size: 13px; font-weight: 600; color: #fff; margin: 14px 0 3px 58px; text-shadow: 0 1px 3px rgba(0, 50, 120, .5); }
.chat .bubble { max-width: 78%; font-size: 17px; box-shadow: 0 4px 14px rgba(0, 60, 140, .15); }
.chat .row.me { margin-top: 14px; }
.chat .row.me + .row.me { margin-top: 4px; }
.chat .row.me .bubble { --bub: var(--blue); color: #fff; }
.chat .row.me .bubble.tail::before { left: auto; right: -6px; transform: scaleX(-1); }
.chat .read { text-align: right; font-size: 12px; font-weight: 600; color: #fff; margin: 4px 4px 0; text-shadow: 0 1px 3px rgba(0, 50, 120, .5); }

/* Tier cards (iMessage app cards) */
.tiers { display: grid; gap: 10px; margin: 8px 0 0 46px; max-width: 460px; }
.tier { display: grid; grid-template-columns: 50px 1fr auto; gap: 14px; align-items: center; text-align: left; width: 100%;
  border: 0; background: #fff; border-radius: 20px; padding: 13px 16px; cursor: pointer; transition: transform .12s;
  box-shadow: 0 5px 0 rgba(0, 70, 150, .14), 0 8px 20px rgba(0, 60, 140, .12); }
.tier:hover { transform: translateY(-2px); } .tier:active { transform: scale(.98); }
.tier .em { width: 50px; height: 50px; border-radius: 14px; display: grid; place-items: center; font-size: 26px; background: #EEF5FF; }
.tier .t-name { font-weight: 700; font-size: 16.5px; }
.tier .t-perk { font-size: 13.5px; color: var(--ink-2); margin-top: 2px; line-height: 1.3; }
.tier .t-price { font-family: var(--font-game); font-weight: 600; font-size: 22px; color: var(--blue); }

.foot { text-align: center; font-size: 13px; color: #fff; font-weight: 500; margin-top: 60px; line-height: 1.5; text-shadow: 0 1px 3px rgba(0, 60, 20, .6); }
.foot p { margin: 4px 0; } .foot a { font-weight: 700; }

/* ───────────────────────── Composer ───────────────────────── */
.composer-wrap { position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; padding: 10px 16px max(12px, env(safe-area-inset-bottom)); pointer-events: none; }
.composer { pointer-events: auto; max-width: 640px; margin: 0 auto; display: flex; align-items: center; gap: 8px; padding: 6px;
  border-radius: 999px; background: rgba(250, 250, 252, .9); backdrop-filter: blur(18px) saturate(1.6); -webkit-backdrop-filter: blur(18px) saturate(1.6);
  box-shadow: 0 6px 24px rgba(0, 40, 100, .25), 0 0 0 .5px rgba(0, 0, 0, .08); }
.composer .plus { width: 38px; height: 38px; border-radius: 50%; border: 0; background: #E4E4E8; color: #6E6E73; font-size: 24px; line-height: 1; cursor: pointer; flex: none; }
.composer .field { flex: 1; text-align: left; height: 38px; border-radius: 999px; border: 1px solid #D6D6DB; background: #fff; padding: 0 14px;
  color: var(--ink-3); font-size: 15.5px; cursor: text; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.composer .send { width: 38px; height: 38px; border-radius: 50%; border: 0; background: var(--blue); display: grid; place-items: center; cursor: pointer; flex: none; }

/* ───────────────────────── Sheet ───────────────────────── */
.sheet-backdrop { position: fixed; inset: 0; z-index: 40; background: rgba(0, 20, 50, .35); display: flex; align-items: flex-end; justify-content: center; animation: fade .2s ease; }
.sheet-backdrop[hidden] { display: none; }
@keyframes fade { from { opacity: 0; } }
.sheet { width: 100%; max-width: 560px; max-height: 92vh; max-height: 92dvh; background: #F2F2F7; border-radius: 22px 22px 0 0; display: flex; flex-direction: column;
  animation: rise .32s cubic-bezier(.2, .9, .3, 1); box-shadow: 0 -10px 40px rgba(0, 0, 0, .2); }
@media (min-width: 700px) { .sheet-backdrop { align-items: center; } .sheet { border-radius: 22px; max-height: 88vh; } }
@keyframes rise { from { transform: translateY(40px); opacity: 0; } }
.grabber { width: 38px; height: 5px; border-radius: 3px; background: #C7C7CC; margin: 7px auto 0; }
.sheet-head { display: grid; grid-template-columns: 70px 1fr 70px; align-items: center; padding: 6px 16px 8px; }
.sheet-head h2 { margin: 0; text-align: center; font-size: 17px; font-weight: 600; }
.sheet-body { overflow-y: auto; padding: 0 16px 8px; -webkit-overflow-scrolling: touch; }
.sheet-foot { padding: 10px 16px max(14px, env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: rgba(242, 242, 247, .96); border-radius: 0 0 22px 22px; }
.secure { text-align: center; font-size: 12px; color: var(--ink-3); margin-top: 8px; }

/* Preview inside the sheet: shown on a mini sky so it looks like the real board */
.preview { background: linear-gradient(180deg, var(--sky-top), var(--sky-mid)); border-radius: 18px; padding: 12px 10px 6px; margin-bottom: 14px; overflow: hidden; }
.preview-label { text-align: center; font-size: 13px; color: #fff; font-weight: 700; text-shadow: 0 1px 2px rgba(0, 50, 120, .4); }
.preview-label b { color: #FFE14D; }
.thread.mini { padding: 4px 6px 14px; }
.thread.mini .msg { margin-top: 10px; --av: 40px; --name: 17px; grid-template-columns: 30px var(--av) 1fr; column-gap: 8px; }
.thread.mini .pod { margin: 22px auto 0; max-width: 360px; --av: 44px; --name: 24px; --amt: 34px; --msg: 15.5px; --pad-x: 18px; --pad-y: 16px; --lines: 3; }
.thread.mini .pod .bubble { display: flex !important; --r: 26px; }
.thread.mini .pod .pod-bottom, .thread.mini .pod .pod-amt { margin-top: auto; padding-top: 10px; flex-direction: row; align-items: baseline; }
.thread.mini .pod .b-name { -webkit-line-clamp: 2; }
.thread.mini .pod { display: flex !important; flex-direction: column; align-items: stretch !important; }
.thread.mini .pod .bubble { align-items: flex-start !important; }
.thread.mini .pod .pod-foot { flex-direction: row !important; align-items: center !important; margin: 8px 0 0 !important; }
.thread.mini .pod .under { display: block !important; white-space: nowrap !important; text-align: left !important; }
.thread.mini .pod .pod-bottom { justify-content: space-between; width: 100%; }
.thread.mini .pod .tapback { width: 44px; height: 44px; font-size: 24px; top: -18px; }
.thread.mini .b-msg { font-size: 15.5px; }

.group { background: #fff; border-radius: 16px; padding: 12px 14px; margin-bottom: 12px; }
.group-title { font-size: 13px; font-weight: 600; color: var(--ink-3); text-transform: uppercase; letter-spacing: .4px; margin-bottom: 10px; display: flex; gap: 8px; align-items: center; }
.tag { font-size: 11px; background: #E8F1FF; color: var(--blue); border-radius: 999px; padding: 2px 8px; letter-spacing: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 7px; }
.chip { border: 1.5px solid #E1E1E6; background: #fff; border-radius: 999px; height: 36px; padding: 0 14px; font-weight: 600; font-size: 15px; cursor: pointer; }
.chip.on { background: var(--blue); border-color: var(--blue); color: #fff; }
.chip.beat-chip { border-color: #FFD43B; background: #FFF8D6; color: #6B4A00; }
.chip.beat-chip.on { background: #FFD43B; color: #3D2A00; }
.amount-field { display: flex; align-items: center; gap: 4px; margin-top: 10px; height: 60px; border-radius: 14px; background: #F4F4F7; padding: 0 16px; }
.amount-field .cur { font-size: 28px; color: var(--ink-3); font-family: var(--font-game); }
.group .amount-field #amountInput { padding: 0; box-shadow: none; flex: 1; min-width: 0; border: 0; background: none; outline: none; font-size: 32px; font-family: var(--font-game); font-weight: 600; }
.amount-field .cur-code { font-size: 13px; color: var(--ink-3); font-weight: 600; }
.perks { margin-top: 12px; display: grid; gap: 6px; }
.credits-box { font-size: 16px; font-weight: 600; color: #6B1D3A; background: linear-gradient(180deg, #FFE9F1, #FFD6E6); border-radius: 12px; padding: 10px 12px; margin-bottom: 4px; }
.credits-box b { font-family: var(--font-game); font-size: 20px; color: #C2185B; }
.perk { display: flex; gap: 8px; align-items: flex-start; font-size: 14.5px; line-height: 1.3; }
.perk .ck { flex: none; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; background: #34C759; color: #fff; margin-top: -1px; }
.perk.off { color: var(--ink-3); } .perk.off .ck { background: #E4E4E8; color: #A0A0A6; }
.nudge { margin-top: 6px; font-size: 13px; color: var(--blue); font-weight: 600; background: #EEF5FF; padding: 8px 10px; border-radius: 10px; cursor: pointer; border: 0; text-align: left; }

.ident { display: flex; gap: 12px; align-items: center; }
.avatar-pick { width: 66px; height: 66px; border-radius: 50%; flex: none; border: 2px dashed #B9C4D2; background: #F4F7FB; color: #7D8A9A; cursor: pointer;
  font-size: 22px; line-height: 1; display: grid; place-items: center; overflow: hidden; padding: 0; }
.avatar-pick small { display: block; font-size: 11px; margin-top: 2px; }
.avatar-pick img { width: 100%; height: 100%; object-fit: cover; }
.avatar-pick.has-img { border: 0; }
.ident-fields { flex: 1; display: grid; gap: 8px; min-width: 0; }
.group input:not([type=checkbox]), .group textarea { width: 100%; border: 0; background: #F4F4F7; border-radius: 12px; padding: 12px 13px; font-size: 16px; outline: none; resize: none; }
.group input:focus, .group textarea:focus { box-shadow: 0 0 0 2px var(--blue) inset; background: #fff; }
.group textarea + input { margin-top: 8px; }
.hint { font-size: 12.5px; color: var(--ink-3); margin: 8px 2px 0; line-height: 1.35; }
.locked { display: none; font-size: 13.5px; color: var(--ink-3); }
#adGroup.is-locked textarea, #adGroup.is-locked input { display: none; }
#adGroup.is-locked .locked { display: block; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; line-height: 1.35; margin: 4px 2px 10px; color: var(--ink-2); cursor: pointer; }
.check input { width: 20px; height: 20px; accent-color: var(--blue); flex: none; margin: 0; }
.check a { color: var(--blue); }
.form-error { color: #E5262B; font-size: 14px; margin: 0 2px 6px; font-weight: 500; }

/* ───────────────────────── Toast ───────────────────────── */
/* Hidden: fully invisible and well above the screen (an empty toast is short, so -160% alone left a sliver showing). */
.toast { position: fixed; left: 50%; top: max(16px, env(safe-area-inset-top)); transform: translate(-50%, calc(-100% - 60px)); z-index: 60; background: rgba(28, 28, 30, .94); color: #fff;
  padding: 12px 18px; border-radius: 16px; font-size: 14.5px; font-weight: 500; max-width: calc(100vw - 32px); text-align: center;
  visibility: hidden; opacity: 0; transition: transform .35s cubic-bezier(.2, .9, .3, 1.2), opacity .2s ease, visibility 0s linear .35s; }
.toast.show { transform: translate(-50%, 0); visibility: visible; opacity: 1; transition: transform .35s cubic-bezier(.2, .9, .3, 1.2), opacity .15s ease, visibility 0s; }

/* ───────────────────────── Responsive ───────────────────────── */
@media (max-width: 600px) {
  .brand { padding: 5px; }
  .brand-full { display: none; }
  .brand-mark { display: block; width: 34px; height: 34px; border-radius: 50%; }
  .nav-bubble { font-size: 15px; padding: 11px 14px; }
  .nav-actions { gap: 10px; }
  .scene .sun { width: 80px; height: 80px; top: 150px; right: -16px; }
  .hero .sub { display: none; }
  .hero { padding-bottom: 14px; }

  .msg { --av: 44px; --name: 18px; --pad-x: 15px; --pad-y: 11px; grid-template-columns: 30px var(--av) 1fr; column-gap: 9px; }
  .msg .rank { font-size: 22px; -webkit-text-stroke-width: 4px; }
  .bubble .b-msg { font-size: 16px; }
  .bubble .b-amt { font-size: 19px; }
  .typing-row { grid-template-columns: 30px 44px 1fr; column-gap: 9px; }
  .typing-row .av { width: 44px; height: 44px; }
  .typing-row .rank { font-size: 22px; }
  .tiers { margin-left: 0; }
  .how-head h2 { font-size: 34px; }
}
@media (min-width: 1100px) {
  .msg { --av: 60px; --name: 23px; --pad-x: 22px; --pad-y: 15px; grid-template-columns: 48px var(--av) 1fr; column-gap: 14px; margin-top: 18px; }
  .msg .rank { font-size: 30px; }
  .bubble .b-msg { font-size: 18px; }
  .bubble .b-amt { font-size: 26px; }
  .typing-row { grid-template-columns: 48px 60px 1fr; column-gap: 14px; }
  .typing-row .av { width: 60px; height: 60px; }
}
@media (max-width: 360px) {
  .nav-bubble { font-size: 14px; padding: 10px 12px; }
}

@media (prefers-reduced-motion: reduce) {
  .cloud, .typing i, .msg.flash { animation: none; }
  html { scroll-behavior: auto; }
}

/* ───────────────────────── Edit my spot ───────────────────────── */
.hero h1 span { color: #FFE14D; white-space: nowrap; }
.edit-link, .foot-edit { display: block; margin: 22px auto 0; border: 0; cursor: pointer; font-weight: 700; font-size: 15px; color: #fff;
  background: rgba(10, 80, 170, .35); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); padding: 10px 18px; border-radius: 999px; }
.edit-link:hover, .foot-edit:hover { background: rgba(10, 80, 170, .5); }
.foot-edit { margin: 0 auto 10px; font-size: 14px; text-shadow: none; }
.code-input { font-family: var(--font-game) !important; font-size: 30px !important; letter-spacing: 10px; text-align: center; font-weight: 600; }
.link-btn.small { font-size: 14px; margin-top: 6px; }
.link-btn.topup { display: block; margin: 8px auto 0; font-size: 15px; font-weight: 600; }
.edit-stats { display: flex; gap: 8px; flex-wrap: wrap; margin: -4px 0 12px; }
.edit-stats span { background: #fff; border-radius: 999px; padding: 6px 12px; font-size: 14px; color: var(--ink-2); }
.edit-stats b { color: var(--ink); }
#editAdGroup.is-locked textarea, #editAdGroup.is-locked input { display: none; }
#editAdGroup.is-locked .locked { display: block; }

/* ───────────────────────── Scene sprites: emojis doing stuff ───────────────────────── */
@keyframes fly { to { transform: translateX(calc(100vw + 300px)); } }

.emo-sprite { position: absolute; font-size: 40px; line-height: 1; filter: drop-shadow(0 6px 6px rgba(0, 50, 20, .2)); }
.emo-sprite.letter { top: 27vh; left: -80px; font-size: 34px; animation: fly 64s linear infinite -44s, wobble 3s ease-in-out infinite; }
.emo-sprite.peek   { bottom: 21vh; left: 3%; font-size: 38px; animation: peek 7s ease-in-out infinite; }
.emo-sprite.bounce { bottom: 14vh; right: 4%; animation: hop 1.6s cubic-bezier(.3, 0, .4, 1) infinite; }
.emo-sprite.dance  { bottom: 6vh; left: 10%; font-size: 44px; transform-origin: 50% 100%; animation: dance 1.2s ease-in-out infinite; }
.emo-sprite.sway   { bottom: 3vh; right: 8%; transform-origin: 50% 100%; animation: sway 4s ease-in-out infinite; }
.emo-sprite.cheers { bottom: 22vh; right: 13%; font-size: 36px; animation: cheers 3.5s ease-in-out infinite; }
@keyframes wobble { 50% { rotate: 12deg; } }
@keyframes peek   { 0%, 55%, 100% { transform: translateY(70%); } 65%, 90% { transform: translateY(0); } }
@keyframes hop    { 0%, 100% { transform: translateY(0) scale(1.08, .92); } 45% { transform: translateY(-46px) scale(.95, 1.05); } }
@keyframes dance  { 0%, 100% { transform: rotate(-12deg); } 50% { transform: rotate(12deg) translateY(-6px); } }
@keyframes sway   { 50% { transform: rotate(9deg); } }
@keyframes cheers { 0%, 100% { transform: rotate(0); } 40% { transform: rotate(-18deg) translateY(-8px); } 50% { transform: rotate(10deg) translateY(-8px); } 60% { transform: rotate(-6deg); } }
@media (max-width: 600px) {
  .emo-sprite { font-size: 30px; } .emo-sprite.cheers, .emo-sprite.sway { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .emo-sprite { animation: none !important; }
  .emo-sprite.letter { left: 85vw; }
}

/* ───────────────────────── Custom emoji on the photo (£100+) ─────────────────────────
   Just the emoji (no circle), perched on the top-right corner so it barely covers the photo. */
.av-wrap { position: relative; flex: none; display: inline-block; line-height: 0; }
.msg .av-wrap { grid-column: 2; grid-row: 1; align-self: end; }
.av-emoji { position: absolute; top: 0; right: 0; z-index: 2; line-height: 1; pointer-events: none;
  font-size: clamp(16px, calc(var(--av) * .34), 64px); transform: translate(38%, -38%);
  filter: drop-shadow(0 2px 3px rgba(0, 40, 100, .35)); }

/* ───────────────────────── Emoji picker: one swipeable line ───────────────────────── */
.emoji-row { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.er-label { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: var(--ink-2); margin-bottom: 6px; }
.emoji-row .locked { display: none; font-size: 13.5px; color: var(--ink-3); }
.emoji-row.is-locked .ep { display: none; }
.emoji-row.is-locked .locked { display: block; }
.ep-line { display: flex; gap: 2px; overflow-x: auto; overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch;
  scroll-snap-type: x proximity; padding: 2px 0 8px; margin: 0 -14px; padding-inline: 14px; outline: none;
  -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
.ep-line::-webkit-scrollbar { height: 4px; } .ep-line::-webkit-scrollbar-thumb { background: #D6D6DB; border-radius: 2px; }
.ep-e { flex: none; width: 44px; height: 44px; border: 0; background: none; border-radius: 12px; font-size: 28px; line-height: 1; cursor: pointer; padding: 0; scroll-snap-align: start; }
.ep-e:hover { background: #F2F2F5; }
.ep-e.on { background: #DCEBFF; box-shadow: inset 0 0 0 2px var(--blue); }
.ep-sep { flex: none; width: 1px; margin: 8px 6px; background: var(--line); }

/* 'Edit my spot' sits in the divider between the top 5 and everyone else */
.divider-edit { flex: none; border: 0; cursor: pointer; font-family: var(--font); font-weight: 700; font-size: 15px; letter-spacing: 0;
  -webkit-text-stroke: 0; color: var(--blue); background: #fff; padding: 9px 18px; border-radius: 999px;
  box-shadow: 0 4px 0 rgba(0, 70, 150, .16), 0 8px 18px rgba(0, 60, 140, .15); transition: transform .12s; }
.divider-edit:hover { transform: translateY(-1px); } .divider-edit:active { transform: scale(.97); }
/* Subtitle now carries the offer, so keep it on phones too (compact) */
@media (max-width: 600px) { .hero .sub { display: inline-block; font-size: 13.5px; padding: 6px 12px; } .hero { padding-bottom: 10px; } }
@media (max-width: 600px) { .hero h1 { font-size: clamp(26px, 8.4vw, 34px); white-space: nowrap; -webkit-text-stroke-width: 6px; text-shadow: 0 4px 0 #0A4A93; margin-bottom: 8px; } }
/* 4th / 5th: a pill-shaped tapback so the ordinal fits */
.pod .tapback.num { width: auto; min-width: 44px; padding: 0 10px; border-radius: 999px; font-size: 17px; letter-spacing: -.2px; }
@media (min-width: 1100px) { .pod .tapback.num { min-width: 52px; height: 46px; font-size: 20px; } }

/* iMessage tails: the corner with the tail is tighter, otherwise big rounded bubbles leave a notch beside the point */
.bubble.tail { border-bottom-left-radius: 18px !important; }
.chat .row.me .bubble.tail { border-bottom-left-radius: 22px !important; border-bottom-right-radius: 18px !important; }
.bubble.tail::before { width: 44px; height: 22px; }

/* Checkout note required by Terms of Sale §8: shown prominently above the consent box */
.credits-note { margin: 2px 2px 12px; padding: 10px 12px; border-radius: 12px; background: #FFF3F7; color: #6B1D3A; font-size: 13.5px; line-height: 1.4; font-weight: 500; }
.credits-note a { color: #C2185B; font-weight: 700; }

/* Page load: keep "How it works" + footer hidden until the board is rendered (no flash, no jump) */
.is-loading .how, .is-loading .foot { visibility: hidden; }
.is-loading .board { min-height: 100vh; }
.board .podium, .board .rows { animation: board-in .35s ease-out both; }
@keyframes board-in { from { opacity: 0; transform: translateY(6px); } }
@media (prefers-reduced-motion: reduce) { .board .podium, .board .rows { animation: none; } }

/* Nav bubbles: both tails point right ("How it works" flipped; "Bid 🔥" as originally) */
.nav-bubble.in::before { left: auto; right: -6px; transform: scaleX(-1); }

/* Emoji avatar (no photo yet), like an iPhone contact with an emoji */
.av.av-emo { display: grid; place-items: center; }
.av.av-emo span { font-size: calc(var(--av, 44px) * .56); line-height: 1; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, .15)); }

/* Live site couldn't reach the board: message + retry (never demo data) */
.load-error { line-height: 1.6; }
.load-error .divider-edit { margin-top: 12px; }

/* Pay/edit preview: 4th/5th badge is a pill sized for its text (the medal circle rule above cut "5th" off) */
.thread.mini .pod .tapback.num { width: auto; min-width: 46px; height: 34px; padding: 0 11px; border-radius: 999px; font-size: 16px; top: -14px; }
.preview { overflow: visible; }

/* ───────── What is Pulsera (film section) ─────────
   Phone: headline → film → text + button, centred. Laptop (≥820px): text left, film right. */
.about { max-width: 1000px; margin: 96px auto 0; padding: 0 4px; display: grid; gap: 26px; justify-items: center; text-align: center;
  grid-template-areas: "head" "film" "body"; }
/* The headline sizes itself to its column (container units), so the longest line ("with new friends 👋")
   always fits next to the film on laptops and inside the screen on phones. */
.about-head { grid-area: head; position: relative; z-index: 1; justify-self: stretch; container-type: inline-size; }
.about-eyebrow { display: inline-block; margin: 0 0 14px; padding: 7px 14px; border-radius: 999px; background: var(--ios-gray, #E9E9EB);
  color: var(--ink); font-size: 15px; font-weight: 600; letter-spacing: -.01em; }
.about h2 { margin: 0; font-family: var(--font); font-weight: 700; letter-spacing: -.035em; line-height: 1.08; color: var(--ink);
  font-size: clamp(28px, 7.6vw, 62px); font-size: clamp(26px, 10.2cqi, 62px); }
.about-line { display: block; }
.rot { display: flex; justify-content: center; gap: .24em; white-space: nowrap; color: var(--blue); }
.rw { display: inline-block; overflow: hidden; padding: .06em .04em .14em; margin: -.06em -.04em -.14em; line-height: 1.12em; }
.rw > span { display: inline-block; will-change: transform; }
.rw > span.in { animation: wIn .62s cubic-bezier(.34, 1.45, .64, 1) both; }
.rw > span.out { animation: wOut .3s cubic-bezier(.5, 0, .75, 0) both; }
@keyframes wIn { from { transform: translateY(110%); } to { transform: none; } }
@keyframes wOut { from { transform: none; } to { transform: translateY(-110%); } }
@media (prefers-reduced-motion: reduce) { .rw > span.in, .rw > span.out { animation: none; } }

/* The film's background is pure white like the page, so there's no frame: the phone just floats on the page.
   Top/bottom edges fade out so zoomed-in scenes don't end in a hard line. */
.film { grid-area: film; position: relative; z-index: 0; margin: -34px 0 -14px; width: min(100%, 400px); aspect-ratio: 9 / 16; }
.film-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; background: #fff;
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 7%, #000 93%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0, #000 7%, #000 93%, transparent 100%); }
.film-sound { position: absolute; right: 8%; bottom: 9%; z-index: 2; width: 40px; height: 40px; border-radius: 50%; border: 0; padding: 0;
  display: grid; place-items: center; cursor: pointer; color: var(--ink); background: rgba(233, 233, 235, .78);
  -webkit-backdrop-filter: blur(14px) saturate(160%); backdrop-filter: blur(14px) saturate(160%); transition: transform .15s ease, background .2s; }
.film-sound:hover { background: rgba(220, 220, 224, .9); }
.film-sound:active { transform: scale(.92); }
.film-sound svg { width: 22px; height: 22px; }
.film-sound .i-on, .film-sound[aria-pressed="true"] .i-off { display: none; }
.film-sound[aria-pressed="true"] .i-on { display: block; }

.about-body { grid-area: body; max-width: 460px; }
.about-body p { margin: 0 0 22px; font-size: 17px; line-height: 1.45; color: var(--ios-label-2, #8A8A8E); }
.about-cta { display: inline-flex; align-items: center; gap: 4px; padding: 14px 20px 14px 26px; border-radius: 999px; background: var(--blue);
  color: #fff; font-size: 17px; font-weight: 600; letter-spacing: -.01em; text-decoration: none;
  box-shadow: 0 8px 22px -8px rgba(0, 122, 251, .55); transition: transform .15s ease, background .2s; }
.about-cta svg { width: 18px; height: 18px; transition: transform .2s ease; }
.about-cta:hover { background: #0A6FE0; }
.about-cta:hover svg { transform: translateX(3px); }
.about-cta:active { transform: scale(.97); }

@media (min-width: 820px) {
  .about { grid-template-columns: minmax(0, 1fr) 420px; grid-template-areas: "head film" "body film"; column-gap: clamp(40px, 6vw, 88px);
    row-gap: 22px; justify-items: start; text-align: left; align-items: center; margin-top: 120px; }
  .about-head { align-self: end; }
  .about-body { align-self: start; }
  .about .rot { justify-content: flex-start; }
  .film { width: 420px; margin: -40px 0; }
}

/* Sky theme: the white film sits in a rounded white card instead. */
html:not(.theme-ios) .film { width: min(78vw, 360px); margin: 0; border-radius: 36px; overflow: hidden; box-shadow: 0 28px 60px -22px rgba(0, 40, 110, .45); }
html:not(.theme-ios) .film-video { -webkit-mask-image: none; mask-image: none; }
/* Sky theme: light text on the sky. */
html:not(.theme-ios) .about h2, html:not(.theme-ios) .about-body p { color: #fff; text-shadow: 0 2px 8px rgba(0, 50, 120, .45); }
html:not(.theme-ios) .about .rot { color: #FFE14D; }
