/* ─────────────────────────────────────────────────────────────
   Homepage only (index.html, <body class="home">). Ported from the
   approved mockup (2026-11-17). Every class is hp-* or scoped under
   #games-grid so nothing here leaks into main.css's other pages.
   Game panels are rendered by js/games-section.js from games.json.
   ───────────────────────────────────────────────────────────── */
body.home {
  background: #fff;
  color: var(--site-ink);
  font: 400 17px/1.6 'Nunito', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
.home h1, .home h2, .home h3 { font-family: var(--font-display); font-weight: 600; line-height: 1.08; letter-spacing: -.01em; }
.home p, .home li { text-wrap: pretty; }
.hp-wrap { max-width: 1200px; margin: 0 auto; padding-left: 24px; padding-right: 24px; } /* same content edge as the header and footer */
.hp-skip { position: absolute; left: -999px; }
.hp-skip:focus { left: 16px; top: 80px; z-index: 200; background: #fff; color: var(--site-ink); padding: 8px 12px; border-radius: 8px; }
.hp-eyebrow { display: inline-block; font-weight: 800; font-size: 14px; letter-spacing: .06em; text-transform: uppercase; color: var(--hp-acc, #5B2BC4); }

/* ─── Buttons ───────────────────────────────────────────────── */
.hp-btn {
  display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 0 24px;
  border-radius: 999px; font: 700 17px 'Nunito', sans-serif;
  transition: transform .3s cubic-bezier(.2, .8, .2, 1), box-shadow .3s var(--site-ease), background .25s var(--site-ease), border-color .25s var(--site-ease);
}
.hp-btn:hover { transform: translateY(-2px); }
.hp-btn-sun { background: var(--site-sun); color: var(--site-ink); box-shadow: 0 6px 0 #FFB000; }
.hp-btn-sun:hover { box-shadow: 0 8px 0 #FFB000; }
.hp-btn-ghost { color: #fff; border: 2px solid rgba(255, 255, 255, .4); }
.hp-btn-ghost:hover { border-color: #fff; }
.hp-btn-ink { background: var(--site-ink); color: #fff; }
.hp-btn-ink:hover { background: var(--site-night-2); }

/* ─── Hero ──────────────────────────────────────────────────── */
.hp-hero { background: var(--site-night); color: #fff; position: relative; overflow: hidden; padding-top: 68px; }
.hp-hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(rgba(255, 255, 255, .08) 1.5px, transparent 1.6px); background-size: 28px 28px;
}
.hp-hero-inner { position: relative; z-index: 1; display: grid; grid-template-columns: 1.05fr 1fr; gap: 40px; align-items: center; padding-top: 72px; padding-bottom: 150px; min-height: 640px; }
.hp-hero .hp-eyebrow { color: var(--site-sun); }
.hp-hero h1 { font-size: clamp(40px, 6vw, 72px); margin: 16px 0 20px; }
.hp-hero h1 em { font-style: normal; color: var(--site-sun); }
.hp-lead { font-size: 19px; color: #D9D5F2; max-width: 30em; margin: 0 0 32px; }
.hp-btns { display: flex; flex-wrap: wrap; gap: 12px; }

.hp-hero-art { position: relative; height: 500px; }
.hp-phone { border-radius: 34px; background: #0D0A26; padding: 9px; box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .6); }
.hp-screen { position: relative; width: 100%; aspect-ratio: 9 / 19.5; border-radius: 26px; overflow: hidden; background: #000; }
.hp-screen img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top; opacity: 0; transition: opacity .8s var(--site-ease); }
.hp-screen img.on { opacity: 1; }
/* owner 2026-11-17: "slightly more gaps between the phones": the side phones spread evenly by --sp (the centre one
   centred, every phone full size), and each floating icon keeps its old place relative to its phone; the grandma icon
   sits a little higher, beside the headline, so it keeps clear of the paragraph (39 px). Overlap 104 -> 79 px.
   Where there is no room to spread (961-1199 px and phones) the original fan stays. */
.hp-hero-art { --sp: -2%; }
.hp-hero-art .hp-phone { position: absolute; width: 220px; }
.hp-hero-art .hp-phone { transform: rotate(var(--r, 0deg)); animation: hp-rise .9s cubic-bezier(.2, .8, .2, 1) both, hp-sway 6s ease-in-out 1s infinite; }
.hp-hero-art .hp-p1 { left: var(--sp); top: 60px; --r: -8deg; animation-delay: .15s, 2.2s; }
.hp-hero-art .hp-p2 { left: calc(50% - 110px); top: 0; z-index: 2; animation-delay: .05s, .8s; }
.hp-hero-art .hp-p3 { right: var(--sp); top: 70px; --r: 8deg; animation-delay: .25s, 3.6s; }
@keyframes hp-rise { from { opacity: 0; transform: translateY(60px) rotate(var(--r, 0deg)); } to { opacity: 1; transform: translateY(0) rotate(var(--r, 0deg)); } }
@keyframes hp-sway { 0%, 100% { translate: 0 0; } 50% { translate: 0 -12px; } }
.hp-float { position: absolute; width: 84px; height: 84px; z-index: 3; animation: hp-pop .8s cubic-bezier(.34, 1.56, .64, 1) .5s both, hp-bob 5s ease-in-out 1.3s infinite; }
.hp-float img { width: 100%; height: 100%; border-radius: 22%; box-shadow: 0 14px 30px -10px rgba(0, 0, 0, .55); }
.hp-f1 { left: calc(var(--sp) - 10% - 8px); top: 190px; } /* 8 px off the POTION logo */
.hp-f2 { right: calc(var(--sp) - 4%); top: 10px; animation-delay: .6s, 2.1s; }
.hp-f3 { left: calc(var(--sp) + 18%); bottom: -24px; animation-delay: .7s, 2.9s; }
.hp-f4 { right: calc(var(--sp) - 3%); bottom: 30px; animation-delay: .8s, 3.7s; }
/* pop in on scale only, then a float that starts and ends at rest (no one-frame jump at the hand-off) */
@keyframes hp-pop { from { opacity: 0; transform: scale(.4); } to { opacity: 1; transform: scale(1); } }
@keyframes hp-bob { 0%, 100% { translate: 0 0; rotate: 0deg; } 25% { rotate: -3deg; } 50% { translate: 0 -12px; rotate: 0deg; } 75% { rotate: 3deg; } }

/* soap bubbles drift up through the night sky, in the lanes beside and between the text and the phones, never
   across the text column, which ends near 50% at 1440 (critic 2026-11-17); see-through like the panels' bubbles: a ring + a highlight */
.hp-bubbles { position: absolute; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.hp-bubbles i {
  position: absolute; bottom: 112px; aspect-ratio: 1; border-radius: 50%; /* starts above the wave crest, so the wave never cuts one */
  background: radial-gradient(circle closest-side at 34% 32%, #fff 0 15%, rgba(255, 255, 255, 0) 32%),
    radial-gradient(circle closest-side, rgba(255, 255, 255, .08) 0 60%, rgba(255, 255, 255, .6) 86%, rgba(255, 255, 255, .9) 94%, transparent 100%);
  animation: hp-rise-up 18s linear infinite, hp-sway-x 18s ease-in-out infinite alternate;
}
.hp-bubbles i:nth-child(1) { left: max(4px, calc((100% - 1200px) / 2 - 44px)); width: 34px; animation-delay: -2s; } /* in the margin left of the text */
.hp-bubbles i:nth-child(2) { left: 53%; width: 24px; animation-duration: 14s; animation-delay: -9s; }
.hp-bubbles i:nth-child(3) { left: 63%; width: 26px; animation-duration: 22s; animation-delay: -5s; }
.hp-bubbles i:nth-child(4) { left: 74%; width: 22px; animation-duration: 16s; animation-delay: -12s; }
.hp-bubbles i:nth-child(5) { left: 89%; width: 40px; animation-duration: 24s; animation-delay: -15s; }
.hp-bubbles i:nth-child(6) { left: 95%; width: 22px; animation-duration: 19s; animation-delay: -7s; }
/* fades in and out so the loop restart is never seen, whatever the hero's height */
/* a steady rise (the transform is keyed only at its start and end, so the speed never changes) that fades out
   before the header; a separate eased sideways sway on translate, to the right, away from the left screen edge */
@keyframes hp-rise-up { 0% { opacity: 0; transform: translateY(0); } 10% { opacity: 1; } 65% { opacity: 1; } 80%, 100% { opacity: 0; transform: translateY(-520px); } }
@keyframes hp-sway-x { from { translate: 0 0; } to { translate: 14px 0; } }

/* waves instead of hard edges: hero -> white page, about -> night footer (band: css/site.css .wave-band) */
.hp-wave { position: relative; height: 96px; overflow: hidden; }
.hp-wave .wave-band { height: 97px; -webkit-mask-size: 720px 97px; mask-size: 720px 97px; }
.hp-wave-hero { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; color: #fff; }
.hp-wave-foot { background: var(--site-soft); color: var(--site-night); margin-bottom: -1px; }
.hp-wave-foot .wave-band { animation-duration: 22s; animation-direction: reverse; }

/* ─── Games ─────────────────────────────────────────────────── */
.hp-games { padding: 96px 0 40px; scroll-margin-top: 68px; }
.hp-head { text-align: center; max-width: 640px; margin: 0 auto 40px; }
.hp-head h2 { font-size: clamp(34px, 4.6vw, 52px); margin: 12px 0; }
.hp-head p { color: var(--site-ink-2); margin: 0; }
/* store buttons: directly under "Our games", above the heading (BUG-03); the .btn-google / .btn-apple look is main.css's */
.hp-stores { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; margin: 18px 0 32px; }
/* the blue line between the store buttons and "Pick a game" (whole-pixel sizes, like the buttons) */
.hp-rule { width: 72px; height: 4px; margin: 0 auto 24px; border-radius: 4px; background: #1D4ED8; }
.hp-pick { display: block; line-height: 20px; margin-bottom: 4px; }
.hp-stores .btn { box-sizing: border-box; height: 52px; padding-top: 0; padding-bottom: 0; } /* a whole-pixel height keeps the cards below on whole pixels */
@media (max-width: 480px) { .hp-stores { flex-direction: column; align-items: stretch; max-width: 280px; margin-left: auto; margin-right: auto; } .hp-stores .btn { justify-content: center; } }
.hp-jump { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; max-width: 900px; margin: 0 auto 56px; padding: 0; list-style: none; }
.hp-jump a {
  display: flex; align-items: center; gap: 10px; min-height: 56px; padding: 8px 18px 8px 8px; border-radius: 999px;
  background: var(--site-soft); font-weight: 800; color: var(--site-ink);
  transition: transform .3s cubic-bezier(.2, .8, .2, 1), background .25s var(--site-ease);
}
.hp-jump a:hover { transform: translateY(-2px); background: var(--site-line); }
.hp-jump img { width: 40px; height: 40px; border-radius: 12px; }

#games-grid.hp-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 32px; max-width: none; }

/* a live game: one big panel (main.css's .game-card glass look is overridden here) */
#games-grid .game-card {
  scroll-margin-top: 84px; position: relative; border: 0; backdrop-filter: none; -webkit-backdrop-filter: none; box-shadow: none; color: var(--site-ink);
}
#games-grid .hp-panel {
  grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 56px; align-items: center;
  border-radius: 40px; padding: 56px 64px; overflow: hidden;
  background: radial-gradient(90% 120% at 15% 0%, #fff 0%, transparent 60%), var(--hp-tint, #F1EEFB);
  --hp-acc: #4A3D9E;
}
/* a faint dot texture in the game's colour, fading out across the panel */
#games-grid .hp-panel::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .14;
  background: radial-gradient(var(--hp-acc) 1.4px, transparent 1.5px) 0 0 / 24px 24px;
  -webkit-mask: linear-gradient(200deg, #000, transparent 60%); mask: linear-gradient(200deg, #000, transparent 60%);
}
#games-grid .hp-panel.hp-flip .hp-media { order: 2; }
.hp-media { position: relative; display: flex; flex-direction: column; align-items: center; gap: 16px; }
/* Splash world in miniature: a soft blob in the game's own colour behind the phone (no boxed banner) */
.hp-media::before {
  content: ""; position: absolute; left: 50%; top: 46%; width: 420px; max-width: 120%; aspect-ratio: 1; z-index: 0;
  transform: translate(-50%, -50%); opacity: .6;
  border-radius: 44% 56% 52% 48% / 48% 44% 56% 52%;
  background: radial-gradient(circle at 35% 30%, var(--hp-soft, #CDBEFF), var(--hp-mid, #7457D9));
  animation: hp-blob 14s ease-in-out infinite alternate;
}
.hp-media > * { position: relative; z-index: 1; }
/* three soap bubbles beside the blob, floating together, behind the phone (critic: they covered game UI at 375) */
.hp-media::after {
  content: ""; position: absolute; left: 50%; top: 46%; width: 480px; max-width: 130%; aspect-ratio: 1; z-index: 0; pointer-events: none; /* behind the phone: never over a screenshot */
  transform: translate(-50%, -50%);
  /* each bubble = a centred ring (closest-side, so it never reaches its tile's edge) + an offset highlight */
  --ring: radial-gradient(circle closest-side, color-mix(in srgb, var(--hp-soft, #CDBEFF) 22%, transparent) 0 62%, color-mix(in srgb, var(--hp-mid, #7457D9) 55%, transparent) 86%, rgba(255, 255, 255, .8) 93%, transparent 100%);
  --hl: radial-gradient(circle closest-side at 34% 32%, #fff 0 14%, rgba(255, 255, 255, 0) 30%);
  background: var(--hl) 3% 16% / 64px 64px no-repeat, var(--ring) 3% 16% / 64px 64px no-repeat,
    var(--hl) 97% 72% / 44px 44px no-repeat, var(--ring) 97% 72% / 44px 44px no-repeat,
    var(--hl) 90% 6% / 28px 28px no-repeat, var(--ring) 90% 6% / 28px 28px no-repeat;
  animation: hp-bub-float 7s ease-in-out infinite;
}
@keyframes hp-bub-float { 0%, 100% { translate: 0 0; } 50% { translate: 0 -14px; } }
.hp-media .hp-phone { transition: transform .45s cubic-bezier(.2, .8, .2, 1); }
#games-grid .hp-panel:hover .hp-phone { transform: translateY(-8px) rotate(-1.5deg); }
/* a fixed organic shape that turns and breathes: transform only, so the compositor runs it */
@keyframes hp-blob { to { transform: translate(-50%, -50%) rotate(14deg) scale(1.04); } }
.hp-media .hp-phone { width: 252px; } /* inner 234 px: a whole-pixel 9:19.5 screen */
.hp-dots { display: flex; gap: 8px; }
.hp-dots button { width: 44px; height: 44px; border: 0; background: none; padding: 0; cursor: pointer; display: grid; place-items: center; }
.hp-dots button::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--hp-acc); opacity: .28; transition: opacity .3s var(--site-ease), transform .3s cubic-bezier(.2, .8, .2, 1); }
.hp-dots button[aria-current="true"]::after { opacity: 1; transform: scale(1.3); }
.hp-title { display: flex; align-items: center; gap: 16px; margin-bottom: 16px; }
#games-grid .hp-title .game-card-icon { width: 72px; height: 72px; border-radius: 22%; box-shadow: 0 10px 20px -10px rgba(26, 20, 66, .45); }
#games-grid .game-badge {
  position: static; display: inline-block; background: none; border: 0; padding: 0;
  font-size: 14px; line-height: 20px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--hp-acc);
}
#games-grid .hp-panel h3 { font-size: 42px; line-height: 46px; font-weight: 600; }
#games-grid .hp-panel p { font-size: 19px; color: var(--site-ink); line-height: 30px; margin: 0 0 20px; }
.hp-feats { list-style: none; padding: 0; margin: 0 0 26px; display: grid; gap: 10px; }
.hp-feats li { display: flex; gap: 12px; align-items: flex-start; font-size: 17px; line-height: 26px; font-weight: 700; }
.hp-feats li::before {
  content: ""; flex: none; width: 22px; height: 22px; margin-top: 2px; border-radius: 50%;
  background: var(--hp-acc) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center / 14px no-repeat;
}
#games-grid .game-card-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 0; padding: 0; }
#games-grid .game-card-actions .btn { min-height: 52px; padding: 0 22px; font-size: 16px; }
#games-grid .hp-more { flex-basis: 100%; display: inline-flex; align-items: center; min-height: 44px; padding: 0; font-weight: 800; color: var(--hp-acc); text-decoration: underline; text-underline-offset: 4px; }
#games-grid .hp-more:hover { text-decoration-thickness: 2px; }

/* coming soon / beta: compact cards after the live games */
.hp-soon-head { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 16px; margin-top: 24px; }
.hp-soon-head h3 { font-size: 30px; line-height: 36px; }
.hp-soon-head span { color: var(--site-ink-2); font-size: 17px; line-height: 26px; }
#games-grid .hp-soon {
  display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 4px 18px; align-items: start;
  padding: 24px; border-radius: 28px; border: 0; background: linear-gradient(160deg, var(--hp-tint, var(--site-soft)), #fff 140%);
  box-shadow: 0 20px 40px -32px rgba(26, 20, 66, .5); transition: transform .35s cubic-bezier(.2, .8, .2, 1);
}
#games-grid .hp-soon:hover { transform: translateY(-4px) rotate(-.4deg); }
#games-grid .hp-soon .game-card-icon { grid-row: span 4; width: 72px; height: 72px; border-radius: 22%; box-shadow: 0 10px 20px -10px rgba(26, 20, 66, .45); animation: hp-bob 5s ease-in-out infinite; }
/* staggered by position so any number of cards take turns (a sibling rule put the 3rd in step with the 2nd) */
#games-grid .hp-soon:nth-of-type(3n+2) .game-card-icon { animation-delay: -1.7s; }
#games-grid .hp-soon:nth-of-type(3n) .game-card-icon { animation-delay: -3.4s; }
#games-grid .hp-panel:nth-of-type(3n+2) .hp-media::after { animation-delay: -2.3s; }
#games-grid .hp-panel:nth-of-type(3n+2) .hp-media::before { animation-delay: -4.7s; }
#games-grid .hp-panel:nth-of-type(3n) .hp-media::before { animation-delay: -9.3s; }
#games-grid .hp-panel:nth-of-type(3n) .hp-media::after { animation-delay: -4.6s; }
#games-grid .hp-soon h3 { font-size: 24px; line-height: 30px; font-weight: 600; }
#games-grid .hp-soon p { font-size: 15px; line-height: 22px; color: var(--site-ink-2); margin: 2px 0 6px; }
#games-grid .hp-soon .hp-more { min-height: 44px; padding: 0; }

/* ─── About ─────────────────────────────────────────────────── */
.hp-about { padding: 72px 0 72px; scroll-margin-top: 68px; margin-top: 16px; background: linear-gradient(180deg, #fff 0%, var(--site-soft) 70%); }
.hp-about-inner { display: grid; grid-template-columns: 1.2fr 1fr; gap: 56px; align-items: start; }
.hp-about .hp-eyebrow { color: #0B7672; }
.hp-about h2 { font-size: clamp(32px, 4vw, 46px); margin: 12px 0 20px; }
.hp-about p { color: var(--site-ink-2); margin: 0 0 16px; max-width: 34em; }
.hp-cards { display: grid; gap: 16px; }
.hp-card {
  display: flex; gap: 18px; align-items: center; padding: 22px 24px; border-radius: 24px; background: #fff; color: var(--site-ink); box-shadow: 0 18px 36px -28px rgba(26, 20, 66, .45);
  transition: transform .3s cubic-bezier(.2, .8, .2, 1), background .25s var(--site-ease);
}
.hp-card:hover { transform: translateY(-4px) rotate(-.4deg); }
.hp-card-ic { flex: none; width: 52px; height: 52px; border-radius: 16px; background: var(--site-night); display: grid; place-items: center; }
.hp-card-ic svg { width: 24px; height: 24px; stroke: var(--site-sun); }
.hp-card b { display: block; font: 600 21px var(--font-display); }
.hp-card span span { color: var(--site-ink-2); font-size: 15px; }

/* ─── Reveal on scroll (only once js/home.js has run: no-JS visitors see everything) ── */
.js .hp-rv { opacity: 0; transform: translateY(18px); transition: opacity .6s cubic-bezier(.2, .8, .2, 1), transform .6s cubic-bezier(.2, .8, .2, 1); }
.js .hp-rv.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js .hp-rv { opacity: 1; transform: none; transition: none; }
  .hp-float, .hp-media::before, .hp-media::after, .hp-hero-art .hp-phone, .hp-bubbles i, #games-grid .hp-soon .game-card-icon { animation: none; }
  .hp-media .hp-phone, #games-grid .hp-soon, .hp-card, .hp-jump a, .hp-dots button::after, .hp-btn, #games-grid .btn { transition: none; }
  .hp-screen img { transition: none; }
}

/* ─── Responsive ────────────────────────────────────────────── */
/* two columns with a margin too narrow for the left lane (< 1290 px): it joins the lane between the columns */
@media (min-width: 961px) and (max-width: 1289px) { .hp-bubbles i:nth-child(1) { left: 57%; } }
/* two columns with no gutter beyond the art (961-1199 px): no room to spread, so the original fan; only the top-right
   icon comes in, which the screen edge used to cut */
@media (min-width: 961px) and (max-width: 1199px) {
  .hp-hero-art .hp-p1 { left: 4%; } .hp-hero-art .hp-p2 { left: 31%; } .hp-hero-art .hp-p3 { right: 2%; }
  .hp-f1 { left: -6%; top: 250px; } .hp-f2 { right: -2%; } .hp-f3 { left: 22%; } .hp-f4 { right: -3%; }
}
@media (max-width: 960px) {
  .hp-hero-inner { grid-template-columns: 1fr; min-height: 0; padding-top: 48px; padding-bottom: 120px; }
  .hp-hero-art { height: 420px; max-width: 520px; width: 100%; margin: 0 auto; }
  /* one column: bubbles rise only through the art area under the text, inside the screen edge */
  .hp-bubbles i { animation-name: hp-rise-up-sm, hp-sway-x; bottom: 112px; }
  .hp-bubbles i:nth-child(1) { left: 6px; width: 22px; }
  .hp-bubbles i:nth-child(2) { left: 48%; }
  .hp-bubbles i:nth-child(3) { left: 30%; width: 20px; }
  .hp-bubbles i:nth-child(4) { left: 66%; }
  .hp-bubbles i:nth-child(5) { left: auto; right: 20px; width: 26px; }
  .hp-bubbles i:nth-child(6) { display: none; }
  /* phone/tablet: feature art first, then gameplay, then the details */
  #games-grid .hp-panel, #games-grid .hp-panel.hp-flip { display: flex; flex-direction: column; align-items: stretch; gap: 0; padding: 40px 28px; }
  #games-grid .hp-panel > .hp-copy { display: contents; }
  #games-grid .hp-panel > .hp-copy > * { order: 1; }
  #games-grid .hp-panel h3 { font-size: 36px; line-height: 40px; }
  #games-grid .hp-panel .hp-media, #games-grid .hp-panel.hp-flip .hp-media { order: 0; margin-bottom: 28px; }
  .hp-about-inner { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 640px) {
  body.home { font-size: 16px; }
  .hp-wrap { padding-left: 16px; padding-right: 16px; }
  .hp-hero-art { height: 340px; }
  .hp-hero-art .hp-phone { width: 150px; border-radius: 26px; padding: 7px; }
  .hp-hero-art .hp-screen { border-radius: 20px; }
  .hp-hero-art .hp-p2 { left: calc(50% - 75px); }
  .hp-hero-art .hp-p1 { left: 4%; } .hp-hero-art .hp-p3 { right: 2%; } .hp-f3 { left: 22%; } /* phones: the original fan */
  .hp-float { width: 60px; height: 60px; }
  .hp-f1 { left: 2px; top: 190px; } .hp-f2 { right: 2px; } .hp-f4 { right: 2px; }
  .hp-games { padding-top: 64px; }
  #games-grid .hp-panel, #games-grid .hp-panel.hp-flip { padding: 32px 20px; border-radius: 24px; }
  #games-grid .hp-panel p { font-size: 17px; line-height: 26px; }
  #games-grid .hp-panel h3 { font-size: 30px; line-height: 34px; }
  .hp-feats li { font-size: 16px; line-height: 24px; }
  .hp-media .hp-phone { width: 240px; } /* inner 222 px */
  .hp-media::before { width: 300px; max-width: 100%; } /* stays inside the panel's rounded edge */
  .hp-media::after { width: 330px; max-width: 108%; }
  .hp-wave { height: 64px; }
  .hp-bubbles i { bottom: 80px; }
  .hp-wave .wave-band { height: 65px; width: calc(100% + 480px); -webkit-mask-size: 480px 65px; mask-size: 480px 65px; animation-name: wave-drift-sm; }
  #games-grid .hp-title .game-card-icon { width: 60px; height: 60px; }
  #games-grid .game-card-actions { gap: 10px; }
  /* equal 160px buttons: side by side when two fit (411), an even stack when not (360) */
  #games-grid .game-card-actions .btn { width: auto; min-width: 160px; max-width: none; padding: 0 16px; font-size: 15px; white-space: nowrap; justify-content: center; }
  #games-grid .hp-soon { padding: 20px; }
}
@keyframes wave-drift-sm { to { transform: translateX(-480px); } }
@keyframes hp-rise-up-sm { 0% { opacity: 0; transform: translateY(0); } 12% { opacity: 1; } 65% { opacity: 1; } 80%, 100% { opacity: 0; transform: translateY(-330px); } }
