/* Vocabuzz website — the wood skin of the game, on paper. */
@font-face { font-family: "Baloo 2"; font-weight: 500; font-display: swap; src: url(/fonts/baloo2-medium.woff2) format("woff2"); }
@font-face { font-family: "Baloo 2"; font-weight: 700; font-display: swap; src: url(/fonts/baloo2-bold.woff2) format("woff2"); }
@font-face { font-family: "Baloo 2"; font-weight: 800; font-display: swap; src: url(/fonts/baloo2-extrabold.woff2) format("woff2"); }

:root {
  --walnut: #4a2a12;
  --walnut-deep: #2b170a;
  --wood-top: #b7773f;
  --wood-bottom: #8b532a;
  --maple: #e2a967;
  --maple-light: #efc48b;
  --maple-edge: #b97a3c;
  --honey: #f2b947;
  --honey-light: #ffe08a;
  --honey-deep: #d99a2b;
  --leaf: #6fae3f;
  --error: #d9534f;
  --cream: #fff1d6;
  --paper: #fbf4e6;
  --paper-2: #f4e7cf;
  --ink: #3d2410;
  --ink-soft: #6b4a2e;
  --radius: 18px;
  --display: "Baloo 2", ui-rounded, system-ui, sans-serif;
  --body: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font: 17px/1.6 var(--body); color: var(--ink); background: var(--paper); }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--display); line-height: 1.1; margin: 0 0 .4em; }
h1 { font-weight: 800; font-size: clamp(2.3rem, 5.5vw, 3.8rem); }
h2 { font-weight: 800; font-size: clamp(1.8rem, 3.6vw, 2.6rem); }
h3 { font-weight: 700; font-size: 1.3rem; }
p { margin: 0 0 1em; }
.wrap { width: min(1120px, 100% - 40px); margin-inline: auto; }
.center { text-align: center; }
.lede { font-size: 1.15rem; color: var(--ink-soft); max-width: 680px; }
.center .lede { margin-inline: auto; }
.eyebrow { font: 700 .95rem var(--display); letter-spacing: .08em; text-transform: uppercase; color: var(--honey-deep); margin-bottom: .3em; }
/* Visually hidden until focused; no negative offset, which made right-to-left pages (Arabic, Hebrew) scroll sideways */
.skip { position: absolute; top: 0; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip:focus { width: auto; height: auto; clip-path: none; top: 10px; inset-inline-start: 10px; background: #fff; padding: 8px 12px; z-index: 99; }

/* Wood ground, like the game board */
.wood {
  color: var(--cream);
  background:
    repeating-linear-gradient(92deg, rgba(110,63,28,.0) 0 22px, rgba(110,63,28,.18) 23px 24px, rgba(110,63,28,0) 25px 61px),
    linear-gradient(180deg, var(--wood-top), var(--wood-bottom));
}
.wood .lede { color: rgba(255,241,214,.85); }

/* Header */
.site-header { position: sticky; top: 0; z-index: 20; background: var(--walnut); border-bottom: 3px solid #9a6a3e; }
.site-header .wrap { display: flex; align-items: center; gap: 22px; height: 72px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font: 800 1.55rem var(--display); color: var(--honey); }
.brand img { width: 38px; height: 38px; border-radius: 10px; }
.nav { display: flex; gap: 20px; margin-left: auto; align-items: center; }
.nav a { color: var(--cream); text-decoration: none; font: 600 1rem var(--display); opacity: .9; }
.nav a:hover { opacity: 1; color: var(--honey-light); }
@media (max-width: 1000px) { .nav a:not(.btn):not(.btn-gold) { display: none; } }

/* Buttons: honey blocks with a thick bottom edge */
.btn {
  display: inline-flex; align-items: center; gap: 8px; text-decoration: none; cursor: pointer;
  font: 800 1.05rem var(--display); color: var(--walnut); border: 0;
  background: linear-gradient(180deg, var(--honey-light), var(--honey));
  padding: 10px 20px 8px; border-radius: 14px;
  box-shadow: inset 0 -4px 0 var(--honey-deep), 0 3px 0 #9a6420;
  transition: transform .08s;
}
.btn:active { transform: translateY(3px); box-shadow: inset 0 -2px 0 var(--honey-deep), 0 0 0 #9a6420; }
.btn.small { padding: 6px 14px 4px; font-size: .95rem; }

/* The gold call to action: polished metal, a glow, a light sweeping across, sparkles. */
.btn-gold {
  position: relative; overflow: hidden; isolation: isolate;
  display: inline-flex; align-items: center; justify-content: center; text-decoration: none; white-space: nowrap;
  font: 800 1.12rem/1 var(--display); color: #4a2a06; letter-spacing: .01em;
  padding: 12px 22px 10px; border-radius: 999px;
  background: linear-gradient(180deg, #fff6c4 0%, #ffe066 22%, #f7c22e 50%, #e09a12 78%, #f3c544 100%);
  border: 2px solid #fff3b8;
  box-shadow:
    inset 0 2px 0 rgba(255,255,255,.85), inset 0 -4px 0 #b97708,
    0 3px 0 #8a5400, 0 0 0 3px rgba(255,214,90,.35), 0 0 22px 4px rgba(255,196,40,.65);
  text-shadow: 0 1px 0 rgba(255,250,220,.8);
  animation: gold-pulse 2.4s ease-in-out infinite;
  transition: transform .12s, filter .12s;
}
.btn-gold::before { /* light sweep */
  content: ""; position: absolute; z-index: -1; top: -20%; bottom: -20%; width: 40%; left: -60%;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,.9), transparent);
  transform: skewX(-20deg); animation: gold-sweep 3.2s ease-in-out infinite;
}
.btn-gold:hover { transform: translateY(-2px) scale(1.04); filter: brightness(1.08) saturate(1.1); }
.btn-gold:active { transform: translateY(2px); box-shadow: inset 0 2px 0 rgba(255,255,255,.85), inset 0 -2px 0 #b97708, 0 0 0 #8a5400, 0 0 16px 2px rgba(255,196,40,.6); }
@keyframes gold-sweep { 0%, 55% { left: -60%; } 100% { left: 130%; } }
@keyframes gold-pulse { 0%, 100% { box-shadow: inset 0 2px 0 rgba(255,255,255,.85), inset 0 -4px 0 #b97708, 0 3px 0 #8a5400, 0 0 0 3px rgba(255,214,90,.35), 0 0 18px 3px rgba(255,196,40,.55); }
  50% { box-shadow: inset 0 2px 0 rgba(255,255,255,.85), inset 0 -4px 0 #b97708, 0 3px 0 #8a5400, 0 0 0 5px rgba(255,214,90,.45), 0 0 30px 8px rgba(255,196,40,.8); } }
.site-header .btn-gold { font-size: 1.05rem; padding: 10px 20px 8px; }
@media (max-width: 420px) { .site-header .btn-gold { font-size: .95rem; padding: 8px 14px 6px; } }
.badge-play img { height: 62px; width: auto; margin-left: -10px; }

/* Hero */
.hero { padding: 56px 0 0; overflow: hidden; }
.hero .wrap { display: grid; grid-template-columns: 1.15fr .85fr; gap: 40px; align-items: end; }
.hero-text { padding-bottom: 64px; }
.hero h1 { color: var(--cream); text-shadow: 0 3px 0 rgba(43,23,10,.35); }
.hero h1 em { font-style: normal; color: var(--honey-light); }
.hero .proof { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 18px; font-weight: 600; color: rgba(255,241,214,.9); font-size: .98rem; }
.hero .proof span::before { content: "✓ "; color: var(--honey-light); }
.cta-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 26px; }
.phone {
  width: min(300px, 80vw); margin-inline: auto; border-radius: 34px 34px 0 0; padding: 12px 12px 0;
  background: var(--walnut-deep); box-shadow: 0 -10px 40px rgba(43,23,10,.45);
}
.phone img { border-radius: 24px 24px 0 0; }
@media (max-width: 820px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .hero-text { padding-bottom: 10px; text-align: center; }
  .hero .proof, .cta-row { justify-content: center; }
}

section { padding: 80px 0; }
section.tight { padding: 56px 0; }
.alt { background: var(--paper-2); }

/* Demo */
.demo { display: grid; grid-template-columns: minmax(280px, 440px) 1fr; gap: 40px; align-items: start; margin-top: 36px; }
@media (max-width: 860px) { .demo { grid-template-columns: 1fr; } }
.board { position: relative; aspect-ratio: 1; border-radius: 22px; padding: 12px; background: var(--walnut); box-shadow: 0 10px 30px rgba(43,23,10,.3); }
.board-inner { position: relative; width: 100%; height: 100%; border-radius: 12px; overflow: hidden; background: #000 center/cover; }
.blocks { position: absolute; inset: 0; display: grid; grid-template-columns: 1fr 1fr; }
.block {
  position: relative; border: 0; cursor: pointer; font: 800 3.4rem var(--display); color: #7a4a26;
  background: linear-gradient(180deg, var(--maple-light), var(--maple));
  box-shadow: inset 4px 4px 0 rgba(255,255,255,.25), inset -5px -6px 0 var(--maple-edge);
  transition: transform .45s cubic-bezier(.3,1.4,.5,1), opacity .45s;
}
.block:hover { filter: brightness(1.05); }
.block.active { outline: 4px solid var(--honey-light); outline-offset: -6px; z-index: 2; }
.block.found { transform: translateY(-18px) rotate(-6deg) scale(.9); opacity: 0; pointer-events: none; }
.panel { background: #fff; border-radius: var(--radius); padding: 24px; box-shadow: 0 4px 0 #e2d2b4; min-height: 100%; }
.panel .hint { color: var(--ink-soft); }
.word-pic { width: 150px; height: 150px; margin: 0 auto 14px; border-radius: 16px; background: var(--paper); }
.slots { display: flex; justify-content: center; gap: 6px; margin: 10px 0 16px; flex-wrap: wrap; }
.slot { width: 40px; height: 46px; border-radius: 10px; background: var(--paper-2); box-shadow: inset 0 3px 0 rgba(0,0,0,.08); display: grid; place-items: center; font: 800 1.5rem var(--display); text-transform: uppercase; }
.tiles { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; }
.tile {
  width: 44px; height: 48px; border: 0; border-radius: 10px; cursor: pointer; font: 800 1.5rem var(--display); text-transform: uppercase; color: var(--walnut);
  background: linear-gradient(180deg, #fff, #f7ead2); box-shadow: inset 0 -4px 0 #d8c3a0, 0 2px 0 #b99b6e;
}
.tile:disabled { opacity: .25; cursor: default; }
.shake { animation: shake .35s; }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
.buzz-row { display: flex; gap: 10px; margin-top: 8px; }
.buzz-row input { flex: 1; min-width: 0; font: 700 1.2rem var(--display); padding: 8px 14px; border-radius: 12px; border: 2px solid #e2d2b4; background: var(--paper); color: var(--ink); }
.buzzer { width: 52px; height: 52px; border-radius: 50%; border: 0; cursor: pointer; font-size: 1.3rem;
  background: radial-gradient(circle at 35% 30%, #ff8a7a, var(--error)); box-shadow: inset 0 -4px 0 #a33a36, 0 3px 0 #7a2a26; color: #fff; }
.msg { min-height: 1.6em; font-weight: 700; margin-top: 10px; }
.msg.ok { color: var(--leaf); } .msg.ko { color: var(--error); }
.text-btn { background: none; border: 0; padding: 0; color: var(--ink-soft); text-decoration: underline; cursor: pointer; font: inherit; }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 20px; margin-top: 40px; }
@media (max-width: 1000px) { .steps { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 700px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }
.step img { border-radius: 18px; box-shadow: 0 8px 24px rgba(43,23,10,.2); margin-bottom: 16px; }
.step .num { font: 800 .9rem var(--display); color: var(--honey-deep); letter-spacing: .06em; text-transform: uppercase; }

/* Two columns */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
@media (max-width: 820px) { .split { grid-template-columns: 1fr; } }
.pic-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }

/* Word cards */
.word-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); gap: 14px; }
.word-card { margin: 0; background: #fff; border-radius: 16px; padding: 10px 10px 6px; text-align: center; box-shadow: 0 3px 0 #e2d2b4; }
.word-card img { width: 100%; aspect-ratio: 1; border-radius: 10px; }
.word-card span { display: block; font: 700 1.15rem var(--display); margin-top: 6px; }
.word-card small { font: 700 .72rem var(--body); color: #fff; background: #1f4aa8; border-radius: 4px; padding: 1px 5px; vertical-align: 2px; margin-left: 4px; }
.word-grid.mini { grid-template-columns: repeat(4, 1fr); gap: 8px; }
.word-grid.mini .word-card { padding: 6px 6px 2px; }
.word-grid.mini .word-card span { font-size: .95rem; margin-top: 2px; }

/* Level roadmap: maple blocks */
.levels { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; margin-top: 40px; }
@media (max-width: 980px) { .levels { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .levels { grid-template-columns: 1fr; } }
.level {
  display: block; text-decoration: none; border-radius: var(--radius); padding: 20px 18px 18px; color: var(--walnut);
  background: linear-gradient(180deg, var(--maple-light), var(--maple));
  box-shadow: inset 3px 3px 0 rgba(255,255,255,.25), inset -4px -5px 0 var(--maple-edge), 0 4px 0 #8b532a;
  transition: transform .12s;
}
.level:hover { transform: translateY(-3px); }
.level .code { font: 800 2.4rem/1 var(--display); }
.level .name { font: 700 1.1rem var(--display); }
.level .count { font-size: .95rem; opacity: .85; }
.level .samples { font-size: .9rem; margin-top: 8px; opacity: .8; }
.level .go { display: inline-block; margin-top: 10px; font: 800 .95rem var(--display); }
.level.beginner { background: linear-gradient(180deg, var(--honey-light), var(--honey)); box-shadow: inset 3px 3px 0 rgba(255,255,255,.3), inset -4px -5px 0 var(--honey-deep), 0 4px 0 #9a6420; }
.tag { display: inline-block; font: 700 .75rem var(--display); text-transform: uppercase; letter-spacing: .06em; background: var(--walnut); color: var(--honey-light); border-radius: 6px; padding: 2px 8px; margin-bottom: 8px; }

/* Comparison table */
.compare { width: 100%; border-collapse: separate; border-spacing: 0; margin-top: 32px; background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: 0 3px 0 #e2d2b4; }
.compare th, .compare td { padding: 14px 16px; text-align: center; border-bottom: 1px solid var(--paper-2); }
.compare th:first-child, .compare td:first-child { text-align: left; }
.compare thead th { font: 800 1.05rem var(--display); background: var(--paper-2); }
.compare thead th.us { background: var(--honey); color: var(--walnut); }
.compare td.us { background: #fff8e6; font-weight: 700; }
.yes { color: var(--leaf); font-weight: 800; } .no { color: #b9a58a; }
.table-scroll { overflow-x: auto; }

/* FAQ */
.faq { max-width: 780px; margin: 32px auto 0; }
.faq details { background: #fff; border-radius: 14px; margin-bottom: 12px; box-shadow: 0 3px 0 #e2d2b4; }
.faq summary { cursor: pointer; padding: 16px 20px; font: 700 1.15rem var(--display); list-style: none; }
.faq summary::after { content: "+"; float: right; color: var(--honey-deep); }
.faq details[open] summary::after { content: "–"; }
.faq details p { padding: 0 20px 16px; margin: 0; color: var(--ink-soft); }

/* Final CTA */
.final { text-align: center; padding: 80px 0; }
.final h2 { color: var(--cream); }
.final .cta-row { justify-content: center; }

/* Page header for word lists */
.page-head { padding: 48px 0 40px; }
.page-head h1 { color: var(--cream); font-size: clamp(2rem, 4.6vw, 3.2rem); }
.crumbs { font-size: .9rem; margin-bottom: 14px; color: rgba(255,241,214,.8); }
.crumbs a { color: var(--honey-light); }
.level-nav { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.level-nav a { text-decoration: none; font: 700 1rem var(--display); padding: 4px 14px; border-radius: 10px; background: rgba(43,23,10,.3); color: var(--cream); }
.level-nav a[aria-current] { background: var(--honey); color: var(--walnut); }
.theme { margin-top: 44px; }
.theme h2 { font-size: 1.6rem; }
.theme h2 small { font: 600 1rem var(--body); color: var(--ink-soft); margin-left: 6px; }
.inline-cta { display: flex; gap: 20px; align-items: center; justify-content: space-between; flex-wrap: wrap; background: #fff; border-radius: var(--radius); padding: 22px 26px; margin: 44px 0 0; box-shadow: 0 3px 0 #e2d2b4; }
.inline-cta p { margin: 0; font: 700 1.2rem var(--display); }
.toc { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 26px; }
.toc a { font-size: .95rem; text-decoration: none; background: #fff; border-radius: 999px; padding: 4px 12px; box-shadow: 0 2px 0 #e2d2b4; }

/* Footer */
.site-footer { background: var(--walnut-deep); color: rgba(255,241,214,.75); padding: 48px 0 32px; font-size: .95rem; }
.site-footer .cols { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 30px; }
@media (max-width: 700px) { .site-footer .cols { grid-template-columns: 1fr; } }
.site-footer h3 { color: var(--honey); font-size: 1.05rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 6px; }
.site-footer a { color: rgba(255,241,214,.85); text-decoration: none; }
.site-footer a:hover { color: var(--honey-light); }
.site-footer .legal { margin-top: 32px; padding-top: 20px; border-top: 1px solid rgba(255,241,214,.12); font-size: .85rem; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; scroll-behavior: auto !important; } }

/* Header nav links must not dim the gold button */
.nav a.btn-gold, .nav a.btn-gold:hover { color: #4a2a06; opacity: 1; }
/* Level excerpts: 12 words = two full rows */
.word-grid.excerpt { grid-template-columns: repeat(6, 1fr); }
@media (max-width: 760px) { .word-grid.excerpt { grid-template-columns: repeat(3, 1fr); } }

/* ================= Hero demo: the real game screen in a phone ================= */
@font-face { font-family: "Caveat"; font-weight: 700; font-display: swap; src: url(/fonts/caveat-tryit.woff2) format("woff2"); }
.hero { padding: 48px 0 64px; overflow: visible; }
.hero .wrap { grid-template-columns: 1fr auto; align-items: center; gap: 56px; }
.hero-text { padding-bottom: 0; position: relative; }
.demo-col { position: relative; padding-top: 70px; }
.tryit { position: absolute; z-index: 7; top: 40px; left: -200px; width: 200px; pointer-events: none; }
.tryit span { display: inline-block; font: 700 2.6rem/1 "Caveat", cursive; color: var(--honey-light); transform: rotate(-8deg); text-shadow: 0 2px 0 rgba(43,23,10,.35); }
.tryit svg { display: block; width: 200px; height: 110px; margin-top: 2px; overflow: visible; }
.device {
  --w: 320px; --dp: calc(var(--w) / 360);
  width: calc(var(--w) + 24px); padding: 12px; border-radius: 46px;
  background: linear-gradient(145deg, #3a2210, #1c0f05); box-shadow: 0 30px 60px rgba(43,23,10,.5), inset 0 0 0 2px #5a3a1e;
  position: relative;
}
.screen {
  position: relative; width: var(--w); height: calc(740 * var(--dp)); border-radius: 34px; overflow: hidden;
  background: #9a5c2c url(/img/game/wood.webp) center / 100% 100%; font-family: var(--display); color: #fff1d6;
  user-select: none; -webkit-user-select: none; -webkit-tap-highlight-color: transparent;
}
.screen button { font-family: var(--display); -webkit-tap-highlight-color: transparent; }
.g-top { position: absolute; inset: 0 0 auto; height: calc(44 * var(--dp)); background: #4a2c16; border-bottom: calc(1.5 * var(--dp)) solid #a0703f; z-index: 3; }
.g-back { position: absolute; left: calc(14 * var(--dp)); top: calc(10 * var(--dp)); width: calc(24 * var(--dp)); height: calc(24 * var(--dp)); }
.g-seal { position: absolute; left: 50%; top: calc(2 * var(--dp)); width: calc(58 * var(--dp)); height: calc(58 * var(--dp)); margin-left: calc(-29 * var(--dp));
  clip-path: polygon(50% 0%, 59% 6%, 69% 3%, 75% 12%, 85% 12%, 88% 22%, 97% 27%, 95% 37%, 100% 46%, 96% 55%, 99% 65%, 91% 72%, 90% 82%, 80% 86%, 75% 95%, 65% 94%, 57% 100%, 48% 96%, 38% 99%, 31% 91%, 21% 89%, 17% 79%, 8% 74%, 9% 64%, 1% 57%, 5% 48%, 1% 38%, 8% 31%, 10% 21%, 20% 17%, 25% 7%, 35% 7%, 42% 1%);
  background: radial-gradient(circle at 40% 30%, #ffe8a0, #f2b947 45%, #c98a22 85%); display: grid; place-items: center; }
.g-seal span { width: 70%; height: 70%; border-radius: 50%; background: radial-gradient(circle at 50% 35%, #5a3419, #3a200c); display: grid; place-items: center; font-weight: 800; font-size: calc(22 * var(--dp)); color: #fff1d6; box-shadow: inset 0 calc(2 * var(--dp)) calc(3 * var(--dp)) rgba(0,0,0,.4); }
.g-coins { position: absolute; right: calc(8 * var(--dp)); top: calc(8 * var(--dp)); height: calc(28 * var(--dp)); padding: 0 calc(12 * var(--dp)) 0 calc(4 * var(--dp)); border-radius: 99px; background: #3a200c; border: calc(2 * var(--dp)) solid #6b4422; display: flex; align-items: center; gap: calc(6 * var(--dp)); }
.g-coin { width: calc(20 * var(--dp)); height: calc(20 * var(--dp)); border-radius: 50%; background: radial-gradient(circle at 40% 35%, #ffe08a, #f2b947 55%, #c98a22); box-shadow: inset 0 0 0 calc(1.5 * var(--dp)) #b97a1c; position: relative; }
.g-coin::after { content: "★"; position: absolute; inset: 0; display: grid; place-items: center; font-size: calc(11 * var(--dp)); color: #d99a2b; }
.g-coins b { font-weight: 800; font-style: italic; font-size: calc(17 * var(--dp)); min-width: calc(14 * var(--dp)); }
.g-coins.bump { animation: bump .5s; }
@keyframes bump { 40% { transform: scale(1.18); } }
.leaf { position: absolute; pointer-events: none; z-index: 2; }
.leaf.tl { left: 0; top: calc(44 * var(--dp)); width: calc(45 * var(--dp)); }
.leaf.tr { right: 0; top: calc(44 * var(--dp)); width: calc(60 * var(--dp)); }
.leaf.bl { left: 0; bottom: 0; width: calc(75 * var(--dp)); }
.leaf.br { right: 0; bottom: 0; width: calc(85 * var(--dp)); }

.g-board { position: absolute; left: calc(16 * var(--dp)); top: calc(72 * var(--dp)); width: calc(328 * var(--dp)); height: calc(328 * var(--dp)); border-radius: calc(12 * var(--dp)); background: #4a2a12; padding: calc(5 * var(--dp)); box-shadow: 0 calc(4 * var(--dp)) 0 #3a200c, 0 calc(8 * var(--dp)) calc(16 * var(--dp)) rgba(0,0,0,.25); }
.g-frame { position: relative; width: 100%; height: 100%; border-radius: calc(8 * var(--dp)); overflow: hidden; background: #2b170a; }
.g-scene { position: absolute; inset: 0; background: center / cover no-repeat; }
.g-blocks { position: absolute; inset: 0; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; }
.g-block, .g-big {
  border: 0; padding: 0; cursor: pointer; color: #7a4a26; font-weight: 800; font-size: calc(46 * var(--dp));
  background: linear-gradient(160deg, #e9b57a, #d99d5f);
  box-shadow: inset calc(3 * var(--dp)) calc(3 * var(--dp)) 0 rgba(255,236,200,.35), inset calc(-4 * var(--dp)) calc(-5 * var(--dp)) 0 #b97a3c;
  text-shadow: 0 calc(1.5 * var(--dp)) 0 rgba(255,230,190,.5);
}
.g-block { position: relative; transition: transform .35s, opacity .35s; }
.g-block.hint { animation: hint 1.6s ease-in-out infinite; z-index: 1; }
@keyframes hint { 0%, 100% { box-shadow: inset 0 0 0 calc(3 * var(--dp)) #ffe08a, 0 0 calc(14 * var(--dp)) #ffd54a, inset calc(-4 * var(--dp)) calc(-5 * var(--dp)) 0 #b97a3c; } 50% { box-shadow: inset 0 0 0 calc(3 * var(--dp)) #fff3c4, 0 0 calc(26 * var(--dp)) #ffd54a, inset calc(-4 * var(--dp)) calc(-5 * var(--dp)) 0 #b97a3c; } }
.g-block.blink { animation: blink .65s steps(2, jump-none) 1; }
@keyframes blink { 0%, 30%, 60% { opacity: 1; } 15%, 45%, 80% { opacity: .15; } }
.g-block.gone { opacity: 0; pointer-events: none; }
.g-block.shutter { transform: perspective(400px) rotateY(88deg); opacity: 0; transition: transform .45s ease-in, opacity .2s .3s; pointer-events: none; }
.g-big { position: absolute; inset: 0; display: none; cursor: default; transform-origin: var(--ox) var(--oy); }
@keyframes grow { from { transform: scale(.5); } to { transform: scale(1); } }
.g-big .g-pic { display: none; }
.g-cells { position: absolute; inset: calc(6 * var(--dp)); display: grid; grid-template-columns: repeat(8, 1fr); grid-template-rows: repeat(8, 1fr); border-radius: calc(4 * var(--dp)); overflow: hidden; }
.g-cells i { background: #fff var(--img) var(--x) var(--y) / 800% 800% no-repeat; transform: scale(0); }
@keyframes cell { to { transform: scale(1.02); } }

.g-slots { position: absolute; left: 0; right: 0; top: calc(474 * var(--dp)); display: flex; justify-content: center; gap: calc(4 * var(--dp)); opacity: 0; pointer-events: none; transition: opacity .2s; }
.g-slots.on { opacity: 1; pointer-events: auto; }
.g-slots { filter: drop-shadow(0 0 calc(6 * var(--dp)) rgba(106,64,32,.9)); }
.g-slot { width: calc(34 * var(--dp)); height: calc(34 * var(--dp)); border-radius: calc(4 * var(--dp)); border: calc(1.5 * var(--dp)) solid #2b170a; background: #3f2412; color: #fff1d6; font-weight: 800; font-size: calc(18.7 * var(--dp)); line-height: 1; text-transform: uppercase; cursor: pointer; padding: 0; }
.g-slots.wrong { animation: shake .5s; }
.g-slots.wrong .g-slot { background: #f3b5a8; border-color: #d9534f; }
.g-bank { position: absolute; left: 0; right: 0; top: calc(564 * var(--dp)); display: grid; grid-template-columns: repeat(6, calc(42 * var(--dp))); gap: calc(8 * var(--dp)) calc(6 * var(--dp)); justify-content: center; opacity: 0; pointer-events: none; transition: opacity .2s; }
.g-bank.on { opacity: 1; pointer-events: auto; }
.g-tile { width: calc(42 * var(--dp)); height: calc(42 * var(--dp)); border: 0; border-radius: calc(7 * var(--dp)); padding: 0; cursor: pointer; font-weight: 800; font-size: calc(21 * var(--dp)); color: #4a2a12; text-transform: uppercase;
  background: linear-gradient(180deg, #fff6e4, #f2deb8); box-shadow: inset 0 calc(-3 * var(--dp)) 0 #d8bb8a, 0 calc(2 * var(--dp)) 0 #9a7444, 0 calc(3 * var(--dp)) calc(4 * var(--dp)) rgba(0,0,0,.25); transition: transform .08s; }
.g-tile:active { transform: translateY(calc(2 * var(--dp))); }
.g-tile.used { background: #4a2a12; color: transparent; box-shadow: inset 0 calc(2 * var(--dp)) calc(3 * var(--dp)) rgba(0,0,0,.5); cursor: default; }
.g-guess { position: absolute; left: 50%; top: calc(500 * var(--dp)); width: calc(110 * var(--dp)); height: calc(110 * var(--dp)); margin-left: calc(-55 * var(--dp)); border: 0; padding: 0; background: none; cursor: pointer; opacity: 0; pointer-events: none; transform: scale(.6); transition: opacity .25s, transform .35s cubic-bezier(.3,1.5,.5,1); }
.g-guess.on { opacity: 1; pointer-events: auto; transform: scale(1); }
.g-guess::before { content: ""; position: absolute; inset: calc(8 * var(--dp)); border-radius: calc(26 * var(--dp)); transform: rotate(45deg); background: linear-gradient(180deg, #f1d7a8, #d9b47a); box-shadow: 0 calc(4 * var(--dp)) 0 #a07c48, 0 0 calc(18 * var(--dp)) rgba(255,214,90,.55); }
.g-guess::after { content: ""; position: absolute; inset: calc(16 * var(--dp)) calc(16 * var(--dp)) calc(22 * var(--dp)); border-radius: calc(20 * var(--dp)); transform: rotate(45deg); background: linear-gradient(180deg, #ec6a50, #d2412f); box-shadow: 0 calc(6 * var(--dp)) 0 #a8301f, inset 0 calc(3 * var(--dp)) 0 rgba(255,255,255,.25); }
.g-guess span { position: relative; z-index: 1; font-weight: 800; font-size: calc(19 * var(--dp)); color: #fff1d6; text-shadow: 0 calc(2 * var(--dp)) 0 #8a2a1c; top: calc(-3 * var(--dp)); }
.g-guess.on { animation: guess-pulse 1.8s ease-in-out infinite; }
@keyframes guess-pulse { 50% { transform: scale(1.06); } }
.g-toast { position: absolute; left: calc(14 * var(--dp)); right: calc(14 * var(--dp)); top: calc(408 * var(--dp)); padding: calc(7 * var(--dp)) calc(10 * var(--dp)); line-height: 1.3; border-radius: calc(10 * var(--dp)); background: #fff7e2; border: calc(2 * var(--dp)) solid #f2b947; color: #4a2a12; font-weight: 700; font-size: calc(15 * var(--dp)); text-align: center; opacity: 0; transform: translateY(calc(6 * var(--dp))); transition: opacity .2s, transform .2s; pointer-events: none; z-index: 4; }
.g-toast.on { opacity: 1; transform: none; }
.g-toast::before, .g-toast::after { content: ""; position: absolute; top: 50%; border: solid transparent; }
.g-toast[data-tail="left"]::before { right: 100%; margin-top: calc(-9 * var(--dp)); border-width: calc(9 * var(--dp)) calc(12 * var(--dp)) calc(9 * var(--dp)) 0; border-right-color: #f2b947; }
.g-toast[data-tail="left"]::after { right: calc(100% - 3 * var(--dp)); margin-top: calc(-6 * var(--dp)); border-width: calc(6 * var(--dp)) calc(9 * var(--dp)) calc(6 * var(--dp)) 0; border-right-color: #fff7e2; }
.g-end { position: absolute; inset: calc(410 * var(--dp)) 0 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: calc(6 * var(--dp)); padding: 0 calc(20 * var(--dp)); text-align: center; opacity: 0; pointer-events: none; transition: opacity .4s; z-index: 4; }
.g-end.on { opacity: 1; pointer-events: auto; }
.g-end h3 { margin: 0; font-size: calc(34 * var(--dp)); color: #ffe08a; text-shadow: 0 calc(3 * var(--dp)) 0 #6b3a12; letter-spacing: .02em; }
.g-end .g-earned { display: inline-flex; align-items: center; gap: calc(8 * var(--dp)); font-weight: 800; font-size: calc(26 * var(--dp)); color: #fff1d6; text-shadow: 0 calc(2 * var(--dp)) 0 rgba(43,23,10,.5); }
.g-end .g-earned .g-coin { width: calc(30 * var(--dp)); height: calc(30 * var(--dp)); }
.g-end .g-earned .g-coin::after { font-size: calc(16 * var(--dp)); }
.g-end p { margin: 0; font-size: calc(14 * var(--dp)); line-height: 1.35; color: #fff1d6; font-weight: 600; text-shadow: 0 1px 0 rgba(0,0,0,.3); }
.g-end .btn-gold { margin-top: calc(10 * var(--dp)); font-size: calc(17 * var(--dp)); }

/* Mascot: a wooden block that bobs and blinks */
.mascot-wrap { position: absolute; left: -150px; bottom: -6px; width: 150px; z-index: 6; pointer-events: none; transform: translateY(var(--lift, 0px)); transition: transform .7s cubic-bezier(.3,1.25,.5,1); }
.mascot { display: block; width: 100%; animation: bob 2.6s ease-in-out infinite; transform-origin: 50% 100%; }
.mascot .mouth { transform-box: fill-box; transform-origin: 50% 0%; }
.mascot-wrap.talking .mouth { animation: talk .22s ease-in-out infinite alternate; }
@keyframes talk { from { transform: scaleY(1); } to { transform: scaleY(.35); } }
.mascot .eyes { animation: eyes 4.5s infinite; transform-origin: 50% 46%; transform-box: fill-box; }
.mascot .arm-r { animation: wave 2.6s ease-in-out infinite; transform-origin: 0% 50%; transform-box: fill-box; }
.mascot .spark { animation: twinkle 1.8s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
.mascot .spark.s2 { animation-delay: .9s; }
@keyframes bob { 0%, 100% { transform: translateY(0) rotate(-2deg); } 50% { transform: translateY(-10px) rotate(2deg); } }
@keyframes eyes { 0%, 92%, 100% { transform: scaleY(1); } 95% { transform: scaleY(.1); } }
@keyframes wave { 0%, 100% { transform: rotate(0deg); } 50% { transform: rotate(-14deg); } }
@keyframes twinkle { 0%, 100% { opacity: .2; transform: scale(.6); } 50% { opacity: 1; transform: scale(1.1); } }
@media (max-width: 1080px) { .mascot-wrap { left: -110px; width: 120px; } }
@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; justify-items: center; }
  .demo-col { padding-top: 64px; }
  .demo-col { padding-top: 78px; } .tryit { top: 0; left: 6px; width: auto; display: flex; align-items: flex-start; } .tryit span { font-size: 2.2rem; } .tryit svg { width: 92px; height: 52px; margin: 18px 0 0 4px; }
  .mascot-wrap { left: auto; right: -30px; bottom: -20px; width: 84px; }
  .g-toast[data-tail="right"] { padding-right: calc(58 * var(--dp)); }
}
@media (max-width: 400px) { .device { --w: 290px; } .mascot-wrap { right: -12px; width: 72px; } }

/* Topic marquee: two rows sliding in opposite directions */
.topics { padding: 72px 0; overflow: hidden; }
.marquee { overflow: hidden; margin-top: 30px; -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.marquee + .marquee { margin-top: 14px; }
.track { display: flex; gap: 14px; width: max-content; padding: 4px 0 8px; animation: slide-left 70s linear infinite; }
.marquee.rev .track { animation-name: slide-right; }
.marquee:hover .track { animation-play-state: paused; }
@keyframes slide-left { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@keyframes slide-right { from { transform: translateX(-50%); } to { transform: translateX(0); } }
.topic { display: flex; align-items: center; gap: 12px; background: #fff; border-radius: 16px; padding: 10px 18px 10px 10px; box-shadow: 0 3px 0 #e2d2b4; white-space: nowrap; }
.topic img { width: 48px; height: 48px; border-radius: 10px; background: var(--paper); }
.topic b { display: block; font: 800 1.12rem/1.1 var(--display); }
.topic span { font-size: .9rem; color: var(--ink-soft); }

/* Tutorial hand, as in level 1 of the game: its fingertip taps the target */
.g-hand { position: absolute; z-index: 9; width: calc(46 * var(--dp)); height: calc(58 * var(--dp)); margin: calc(-2 * var(--dp)) 0 0 calc(-4 * var(--dp)); pointer-events: none; opacity: 0; transition: opacity .25s; transform-origin: 8% 4%; filter: drop-shadow(0 calc(3 * var(--dp)) calc(4 * var(--dp)) rgba(43,23,10,.55)); overflow: visible; }
.g-hand.on { opacity: 1; animation: tap 1.6s ease-in-out infinite; }
@keyframes tap { 0%, 100% { transform: translate(calc(10 * var(--dp)), calc(12 * var(--dp))) scale(1); } 45% { transform: translate(0, 0) scale(1); } 55% { transform: translate(0, 0) scale(.9); } 70% { transform: translate(calc(4 * var(--dp)), calc(5 * var(--dp))) scale(1); } }

/* Room for the mascot between the text and the phone, so it never covers the text when it rises */
@media (min-width: 1081px) { .hero .wrap { gap: 180px; } }
@media (min-width: 901px) and (max-width: 1080px) { .hero .wrap { gap: 140px; } }

/* Found word: the picture fades off the big block before it shrinks back, so only the plain block returns */
.g-amt { display: inline-flex; align-items: center; gap: calc(6 * var(--dp)); font-size: calc(30 * var(--dp)); color: #7a4a26; }
.g-amt .g-coin { width: calc(28 * var(--dp)); height: calc(28 * var(--dp)); }
.g-amt .g-coin::after { font-size: calc(15 * var(--dp)); }

/* Faithful word cycle */
.g-big.on { display: block; }
.g-big.closing { background: none; box-shadow: none; }
.g-big.closing .g-cells { inset: 0; border-radius: 0; }
.g-cells i { transform: scale(0); }
.g-amt b { font-weight: 800; }
.g-fly { position: absolute; left: 0; top: 0; z-index: 8; pointer-events: none; }

.g-tile.nope { animation: nope .3s; }
@keyframes nope { 25% { transform: translateX(calc(-3 * var(--dp))); } 75% { transform: translateX(calc(3 * var(--dp))); } }

/* Level roadmap, one colour per level, every row aligned across the cards (subgrid) */
.roadmap { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); grid-template-rows: repeat(6, auto); column-gap: 16px; margin-top: 40px; }
.road {
  --tint: color-mix(in srgb, var(--c) 14%, #fff);
  display: grid; grid-template-rows: subgrid; grid-row: span 6; row-gap: 0;
  text-decoration: none; color: var(--ink); background: #fff; border-radius: 20px; padding: 20px 18px 18px;
  border: 2px solid color-mix(in srgb, var(--c) 30%, #fff); box-shadow: 0 4px 0 color-mix(in srgb, var(--c) 35%, #e2d2b4);
  transition: transform .15s, box-shadow .15s;
}
.road:hover { transform: translateY(-4px); box-shadow: 0 8px 0 color-mix(in srgb, var(--c) 45%, #e2d2b4); }
.road-top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 14px; }
.road-icon { width: 58px; height: 58px; border-radius: 16px; background: var(--tint); display: grid; place-items: center; }
.road-icon img { width: 44px; height: 44px; mix-blend-mode: multiply; }
.road-badge { font: 800 .85rem/1 var(--display); letter-spacing: .08em; color: var(--c); background: var(--tint); border: 1.5px solid color-mix(in srgb, var(--c) 40%, #fff); border-radius: 99px; padding: 6px 12px 4px; }
.road-name { font-size: 1.45rem; margin: 0; padding-bottom: 12px; border-bottom: 1.5px solid var(--paper-2); align-self: end; }
.road-stats { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 0 12px; }
.road-start { font: 800 .75rem/1 var(--display); text-transform: uppercase; letter-spacing: .06em; color: #fff; background: var(--c); border-radius: 8px; padding: 6px 8px 4px; white-space: nowrap; }
.road-stats b { display: block; font: 800 1.35rem/1.1 var(--display); color: var(--ink); }
.road-stats small, .road-sample small, .road-meter small { display: block; font: 700 .7rem/1.2 var(--body); letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft); }
.road-stats small { margin-top: 3px; }
.road-sample { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding-bottom: 12px; }
.road-sample small { width: 100%; margin-bottom: 2px; }
.road-sample img { width: 44px; height: 44px; border-radius: 10px; background: var(--tint); padding: 3px; mix-blend-mode: multiply; }
.road-text { margin: 0; padding-bottom: 14px; font-size: .95rem; line-height: 1.45; color: var(--ink-soft); }
.road-meter { display: flex; align-items: center; gap: 5px; align-self: end; }
.road-meter small { margin-right: 6px; }
.road-meter i { width: 18px; height: 6px; border-radius: 3px; background: var(--paper-2); }
.road-meter i.on { background: var(--c); }
.road-go { margin-left: auto; font: 800 .9rem var(--display); color: var(--c); }
@media (max-width: 1100px) { .roadmap { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 16px; grid-template-rows: none; } .road { grid-template-rows: auto auto auto auto 1fr auto; grid-row: auto; } }
@media (max-width: 720px) { .roadmap { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .roadmap { grid-template-columns: 1fr; } }

.legal-text { max-width: 760px; }
.legal-text h2 { font-size: 1.35rem; margin-top: 28px; }
.legal-text p { color: var(--ink-soft); }

/* Language menu */
.lang { position: relative; margin-left: 4px; }
.lang summary { list-style: none; cursor: pointer; color: var(--cream); font: 600 1rem var(--display); padding: 6px 4px; white-space: nowrap; }
.lang summary::-webkit-details-marker { display: none; }
.lang summary::after { content: ""; display: inline-block; width: 7px; height: 7px; margin: 0 0 3px 8px; border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.lang ul { position: absolute; inset-inline-end: 0; top: calc(100% + 8px); margin: 0; padding: 8px 0; list-style: none; background: #fff; border-radius: 14px; box-shadow: 0 12px 32px rgba(43,23,10,.35); max-height: min(70vh, 520px); overflow-y: auto; min-width: 190px; z-index: 30; }
.lang li a { display: block; padding: 8px 20px; color: #3a200c; text-decoration: none; font-size: 1rem; }
.lang li a:hover { background: #fbf1df; }
.lang li a[aria-current] { color: #cf4a3c; font-weight: 700; }
@media (max-width: 760px) { .lang summary { font-size: .9rem; } }

/* Blog (layout after the Shinobi blog, in walnut tones) */
.blog { background: radial-gradient(120% 70% at 30% 0%, #5a3418 0%, var(--walnut-deep) 70%); color: rgba(255,241,214,.82); padding: 64px 0 90px; min-height: 70vh; }
.blog h1 { color: #fff; font: 800 clamp(2.1rem, 4.8vw, 3.3rem)/1.04 var(--display); letter-spacing: -.02em; max-width: 680px; margin: .15em 0 .4em; }
.blog-eyebrow { font: 700 .82rem var(--body); letter-spacing: .2em; text-transform: uppercase; color: #f0907a; margin: 0; }
.blog-lede { font-size: 1.12rem; line-height: 1.6; max-width: 640px; color: rgba(255,241,214,.72); margin: 0 0 40px; }
.blog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 20px; }
.blog-card { display: flex; flex-direction: column; padding: 24px 24px 22px; border-radius: 14px; border: 1px solid rgba(255,224,138,.16); background: rgba(255,241,214,.04); text-decoration: none; transition: border-color .2s, background .2s, transform .2s; }
.blog-card:hover { border-color: rgba(255,224,138,.45); background: rgba(255,241,214,.07); transform: translateY(-2px); }
.blog-cat { font: 700 .7rem var(--body); letter-spacing: .14em; text-transform: uppercase; color: var(--honey); margin: 0 0 10px; }
.blog-card h2 { color: #fff; font: 700 1.2rem/1.3 var(--body); margin: 0 0 12px; }
.blog-sum { font-size: .92rem; line-height: 1.6; color: rgba(255,241,214,.66); margin: 0 0 18px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.blog-meta { font-size: .82rem; color: rgba(255,241,214,.5); margin: auto 0 0; }
.post { max-width: 720px; }
.post-crumbs { font-size: .85rem; color: rgba(255,241,214,.5); margin: 0 0 28px; }
.post-crumbs a { color: rgba(255,241,214,.6); text-decoration: none; }
.post h1 { max-width: none; }
.post > .blog-meta { margin: 0 0 32px; }
.tldr { border: 1px solid rgba(255,224,138,.3); background: rgba(242,185,71,.07); border-radius: 14px; padding: 20px 22px; margin-bottom: 36px; }
.tldr p:last-child { margin: 0; color: rgba(255,241,214,.92); line-height: 1.7; }
.post-body { font-size: 1.08rem; line-height: 1.8; }
.post-body h2 { color: #fff; font: 700 1.6rem var(--body); margin: 2em 0 .6em; letter-spacing: -.01em; }
.post-body strong { color: #fff; }
.post-body a { color: var(--honey-light); }
.post-body li { margin-bottom: .5em; }
.post-cta { margin-top: 48px; padding: 28px; border-radius: 14px; border: 1px solid rgba(255,224,138,.2); text-align: center; }
.post-cta p { color: #fff; font: 700 1.2rem var(--display); margin: 0 0 14px; }
.blog-empty { font-size: 1rem; color: rgba(255,241,214,.55); border: 1px dashed rgba(255,224,138,.25); border-radius: 14px; padding: 28px; text-align: center; margin: 0; }

/* Roomier tutorial bubble (legnico): bigger text and padding; the word cases, letters and Guess move down */
.g-toast { top: calc(410 * var(--dp)); left: calc(12 * var(--dp)); right: calc(12 * var(--dp)); min-height: calc(52 * var(--dp)); display: flex; align-items: center; justify-content: center;
  padding: calc(11 * var(--dp)) calc(16 * var(--dp)); border-radius: calc(16 * var(--dp)); border-width: calc(2.5 * var(--dp)); font-size: calc(18 * var(--dp)); line-height: 1.3;
  box-shadow: 0 calc(4 * var(--dp)) 0 rgba(154,100,32,.35), 0 calc(8 * var(--dp)) calc(18 * var(--dp)) rgba(43,23,10,.3); }
.g-toast[data-tail="left"]::before { margin-top: calc(-11 * var(--dp)); border-width: calc(11 * var(--dp)) calc(14 * var(--dp)) calc(11 * var(--dp)) 0; }
.g-toast[data-tail="left"]::after { margin-top: calc(-7.5 * var(--dp)); border-width: calc(7.5 * var(--dp)) calc(10 * var(--dp)) calc(7.5 * var(--dp)) 0; }
.g-toast[data-tail="right"] { padding-right: calc(62 * var(--dp)); }
.g-slots { top: calc(500 * var(--dp)); }
.g-bank { top: calc(590 * var(--dp)); }
.g-guess { top: calc(522 * var(--dp)); }

/* Phones and narrow tablets (one column): no "Try it!" and no mascot, the phone demo stands alone */
@media (max-width: 900px) {
  .tryit, .mascot-wrap { display: none; }
  .demo-col { padding-top: 8px; }
  .g-toast[data-tail="right"] { padding-right: calc(16 * var(--dp)); }
}

/* Narrow screens: the header keeps the logo, the gold button and a short language code (FR, DE…) */
.lang-code { display: none; }
@media (max-width: 600px) {
  .lang-name { display: none; }
  .lang-code { display: inline; }
  .site-header .wrap { gap: 10px; }
  .brand { font-size: 1.3rem; }
  .brand img { width: 32px; height: 32px; }
}
@media (max-width: 400px) {
  .brand { font-size: 0; gap: 0; }
  .site-header .btn-gold { font-size: .9rem; padding: 8px 14px 6px; }
}

/* Right-to-left pages (Arabic, Hebrew): "Try it!" and the mascot sit on the other side of the phone */
[dir="rtl"] .tryit { left: auto; right: -200px; }
[dir="rtl"] .tryit svg { transform: scaleX(-1); }
[dir="rtl"] .mascot-wrap { left: auto; right: -150px; }
@media (max-width: 1080px) { [dir="rtl"] .mascot-wrap { right: -110px; } }
/* A bubble spoken from the right gets its tail on the right */
.g-toast[data-tail="right"] { padding-right: calc(16 * var(--dp)); }
.g-toast[data-tail="right"]::before { left: 100%; margin-top: calc(-11 * var(--dp)); border-width: calc(11 * var(--dp)) 0 calc(11 * var(--dp)) calc(14 * var(--dp)); border-left-color: #f2b947; }
.g-toast[data-tail="right"]::after { left: calc(100% - 3 * var(--dp)); margin-top: calc(-7.5 * var(--dp)); border-width: calc(7.5 * var(--dp)) 0 calc(7.5 * var(--dp)) calc(10 * var(--dp)); border-left-color: #fff7e2; }

/* Phones: the five steps become a sideways swipe instead of five full-height screenshots in a column */
@media (max-width: 700px) {
  .steps { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 14px; padding: 4px 20px 12px; width: 100%; box-sizing: border-box; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
  .steps::-webkit-scrollbar { display: none; }
  .step { flex: 0 0 68%; scroll-snap-align: center; }
}

/* Phones, after Shinobi's mobile page: text aligned left, the level cards and the comparison kept compact */
@media (max-width: 900px) {
  .hero-text { text-align: start; }
  .hero .proof, .hero .cta-row { justify-content: flex-start; }
}
@media (max-width: 720px) {
  section .wrap.center { text-align: start; }
  section .wrap.center .lede { margin-inline: 0; }
  /* Level cards: a sideways swipe, the next card peeking in */
  .roadmap { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 14px; padding: 4px 20px 14px; width: 100%; box-sizing: border-box; scrollbar-width: none; }
  .roadmap::-webkit-scrollbar { display: none; }
  .road { flex: 0 0 80%; scroll-snap-align: center; display: flex; flex-direction: column; }
  .road-text { flex: 1; }
  /* Comparison: only the Vocabuzz column, like Shinobi on phones */
  .compare th:nth-child(3), .compare th:nth-child(4), .compare td:nth-child(3), .compare td:nth-child(4) { display: none; }
  .compare th:first-child, .compare td:first-child { width: 75%; }
}

/* Google Play on phones: a full-width black button (the badge image stays on larger screens) */
.play-btn { display: none; }
@media (max-width: 600px) {
  .cta-row { width: 100%; }
  .badge-play { display: block; width: 100%; }
  .badge-play img { display: none; }
  /* Same height as the official badge (42 px of black), stretched to the full width; logo and text on the left, as on Shinobi */
  .play-btn { display: flex; align-items: center; justify-content: flex-start; gap: 10px; width: 100%; height: 42px; padding: 0 14px 0 12px; box-sizing: border-box; border-radius: 8px; background: #000; border: 1px solid #a6a6a6; color: #fff; }
  .play-btn svg { width: 22px; height: 24px; flex: none; }
  .play-btn > span { display: flex; flex-direction: column; align-items: flex-start; line-height: 1.1; }
  .play-btn small { font: 400 .62rem var(--body); letter-spacing: .01em; }
  .play-btn b { font: 700 1rem var(--body); letter-spacing: -.015em; }
  .inline-cta { flex-direction: column; align-items: stretch; }
}

/* Scroll reveal: fade and rise into place (site.js adds .reveal, then .in when seen) */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1); transition-delay: var(--d, 0ms); }
.reveal.in { opacity: 1; transform: none; }
.badge-play { text-decoration: none; }
