/* Language landing pages (/de/, /es/, /en/spanish/) — games-first layout, 2026-11-21.
   Tiles and the featured tile are pre-rendered by tools/render_static_games.py. */
:root {
  --wrap: 1180px;
}
body { background: var(--krabsy-cream); }

.vh {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0;
}
a:focus-visible, button:focus-visible {
  outline: 3px solid var(--krabsy-ink); outline-offset: 3px; border-radius: 6px;
}
.gt:focus-visible, .pr-card:focus-visible, .pr-q:focus-visible, .gl-teach:focus-visible { border-radius: var(--radius-md); }

/* The logo and the header bar itself (main menu, teacher link, language) is styled in
   krabsy-ui.css "Site header" (lib/krabsy-header.js, 2026-11-27). */

.wrap { max-width: var(--wrap); margin: 0 auto; width: 100%; padding: 0 24px; }
@media (max-width: 559px) { .wrap { padding: 0 16px; } }

/* ── Hero (tools/render_landing_intro.py; design "Mix D2a", owner 2026-11-28) ──
   A white card above the featured game: h1 with a violet highlight on its last
   words, one line (which grammar, for whom), trust chips (free / no sign-up /
   no ads), three call-to-action buttons with Krabsy icons, a quiet teacher
   line; on the right the crab (facing left, towards the text) among turquoise
   sparkles, standing on a soft shadow. Phones: the crab on top. */
.gl-head { padding-top: 30px; padding-bottom: 18px; }
.gl-intro {
  position: relative;
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 12px;
  padding: 30px 0 28px 36px; border-radius: var(--radius-lg); background: #fff; box-shadow: var(--shadow-card);
}
.gl-intro-txt { min-width: 0; }
.gl-intro .gl-prog { grid-column: 1 / -1; margin-top: 12px; margin-right: 36px; }
.gl-head h1 {
  font-family: var(--font-display); font-weight: normal;
  font-size: 2.8rem; line-height: 1.1; letter-spacing: -0.3px; margin: 0; color: var(--k-ink); text-wrap: balance;
}
.gl-hl { white-space: nowrap; background: linear-gradient(transparent 62%, var(--k-main-45) 62%); padding: 0 0.06em; }
.gl-intro-line { margin: 12px 0 0; font-size: 1.16rem; line-height: 1.45; color: var(--k-ink); max-width: 30em; }
.gl-trust { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 0; padding: 0; list-style: none; }
.gl-trust li { display: inline-flex; align-items: center; gap: 6px; padding: 4px 13px 4px 9px; border-radius: 999px;
  background: var(--k-acc-16); color: var(--k-ink); font-weight: 800; font-size: 0.9rem; }
.gl-chk { width: 16px; height: 16px; padding: 2px; border-radius: 50%; background: var(--k-acc); color: var(--k-ink); flex: 0 0 auto; box-sizing: border-box; }
.gl-acts { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
.gl-act {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 56px; padding: 0 26px 0 8px; border-radius: var(--radius-pill);
  background: var(--k-btn2-bg); box-shadow: inset 0 0 0 2px var(--k-btn2-line), 0 3px 0 var(--k-btn2-edge);
  color: var(--k-btn2-fg); font-weight: 800; font-size: 1.1rem; text-decoration: none; white-space: nowrap;
  transition: transform 0.08s, box-shadow 0.08s;
}
.gl-act:hover { background: var(--k-btn2-bg-hover); color: var(--k-btn2-fg); }
.gl-act:active { transform: translateY(2px); box-shadow: inset 0 0 0 2px var(--k-btn2-line), 0 1px 0 var(--k-btn2-edge); }
.gl-act-ico {
  display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto;
  width: 42px; height: 42px; border-radius: 50%; background: var(--k-bg);
}
.gl-act .ki { width: 26px; height: 26px; }
.gl-act-play { background: var(--k-btn-bg); color: var(--k-btn-fg); box-shadow: 0 3px 0 var(--k-btn-edge); }
.gl-act-play:hover { background: var(--k-btn-bg-hover); color: var(--k-btn-fg); }
.gl-act-play:active { box-shadow: 0 1px 0 var(--k-btn-edge); }
.gl-act-play .gl-act-ico { background: #fff; }
.gl-act:focus-visible { border-radius: var(--radius-pill); outline-offset: 4px; }
@media (prefers-reduced-motion: reduce) { .gl-act { transition: none; } }

.gl-join { display: flex; flex-wrap: wrap; gap: 2px 16px; margin: 18px 0 0; font-size: 0.84rem; line-height: 1.4; }
.gl-join a { display: inline-flex; align-items: center; gap: 6px; min-height: 28px;
  color: var(--k-ink); font-weight: 700; text-decoration: none; }
.gl-join a span { text-decoration: underline; text-decoration-color: var(--k-ink-22); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.gl-join a:hover span { color: var(--k-main-lo); text-decoration-color: var(--k-main-lo); }
.gl-join .gl-join-teachers span { color: var(--k-main-lo); text-decoration-color: var(--k-main-45); }
.gl-join .ki { width: 20px; height: 20px; flex: 0 0 auto; }
.gl-class-badge { display: inline-flex; align-items: center; gap: 6px; padding: 2px 12px 2px 6px; border-radius: 999px;
  background: var(--k-acc-16); color: var(--k-ink) !important; font-weight: 700; text-decoration: none; }
.gl-class-badge:hover { background: var(--k-acc-35); }

/* the crab among sparkles (hero art; the SVGs are rendered by render_landing_intro.py) */
.gl-hero-art { position: relative; align-self: stretch; width: 390px; margin: -30px 0 -28px; }
.gl-hero-shadow { position: absolute; left: 0; bottom: 0; width: 100%; height: auto; display: block; }
.gl-hero-shadow ellipse { fill: var(--k-ink); opacity: 0.2; }
.gl-sp-a { fill: var(--k-acc); }
.gl-sp-b { fill: var(--k-acc-35); }
.gl-sp-line { fill: none; stroke: var(--k-acc); stroke-width: 5; stroke-linecap: round; }
.gl-sparkles { position: absolute; left: 0; bottom: 0; width: 100%; height: auto; display: block; animation: gl-rise 6s ease-in-out infinite; }
@keyframes gl-rise { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
.gl-intro-crab { position: absolute; right: 45px; bottom: 38px; width: 294px; height: auto; margin: 0; object-fit: contain;
  animation: gl-cheer 3.6s ease-in-out infinite; transform-origin: 50% 100%; }
@keyframes gl-cheer { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-5px) rotate(1.5deg); } }
@media (prefers-reduced-motion: reduce) { .gl-intro-crab, .gl-sparkles { animation: none; } }

@media (max-width: 1099px) {
  .gl-head h1 { font-size: 2.25rem; }
  .gl-hero-art { width: 290px; }
  .gl-intro-crab { width: 220px; right: 33px; bottom: 28px; }
}
@media (max-width: 899px) {
  .gl-intro { padding: 22px 0 20px 22px; }
  .gl-intro .gl-prog { margin-right: 22px; }
  .gl-head h1 { font-size: 1.9rem; }
  .gl-intro-line { font-size: 1.05rem; }
  .gl-hero-art { width: 200px; margin: -22px 0 -20px; }
  .gl-intro-crab { width: 152px; right: 22px; bottom: 19px; }
}
@media (max-width: 559px) {
  .gl-head { padding-top: 14px; padding-bottom: 12px; }
  .gl-intro { display: flex; flex-direction: column-reverse; padding: 16px; }
  .gl-intro .gl-prog { margin-right: 0; }
  .gl-hero-art { align-self: center; width: 240px; height: 166px; margin: 0 0 6px; }
  .gl-intro-crab { width: 180px; right: 28px; bottom: 23px; }
  .gl-head h1 { font-size: 1.75rem; }
  .gl-intro-line { font-size: 1rem; margin-top: 8px; }
  .gl-trust { gap: 6px; margin-top: 10px; }
  .gl-trust li { font-size: 0.8rem; padding: 3px 10px 3px 7px; }
  .gl-acts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 16px; }
  .gl-act { justify-content: flex-start; min-width: 0; min-height: 52px; padding: 4px 10px 4px 6px; font-size: 1rem; gap: 8px;
    white-space: normal; line-height: 1.15; }
  .gl-act-play { grid-column: 1 / -1; justify-content: center; }
  .gl-acts > .gl-act:nth-child(2):last-child { grid-column: 1 / -1; justify-content: center; }  /* two actions: both full width */
  .gl-act-ico { width: 36px; height: 36px; }
  .gl-join { flex-direction: column; gap: 0; margin-top: 12px; font-size: 0.84rem; }
  .gl-join a { min-height: 34px; }
}

/* Compact banner (owner 2026-11-30, like JuegaPop: games visible without scrolling on a laptop).
   Same content, less height: smaller title, tighter spacing, a smaller crab. */
@media (min-width: 900px) {
  .gl-head { padding-top: 18px; padding-bottom: 12px; }
  .gl-intro { padding: 22px 0 20px 32px; }
  .gl-head h1 { font-size: 2.3rem; }
  .gl-intro-line { margin-top: 8px; font-size: 1.05rem; }
  .gl-trust { margin-top: 10px; }
  .gl-trust li { font-size: 0.84rem; padding: 3px 12px 3px 8px; }
  .gl-acts { margin-top: 14px; gap: 10px; }
  .gl-act { min-height: 48px; font-size: 1.02rem; padding: 0 22px 0 6px; }
  .gl-act-ico { width: 36px; height: 36px; }
  .gl-act .ki { width: 22px; height: 22px; }
  .gl-join { margin-top: 12px; }
  .gl-hero-art { width: 280px; margin: -22px 0 -20px; }
  .gl-intro-crab { width: 200px; right: 40px; bottom: 26px; }
}
@media (max-width: 559px) {
  .gl-hero-art { width: 190px; height: 128px; }
  .gl-intro-crab { width: 138px; right: 26px; bottom: 18px; }
}

/* ── Progress row (returning players only; hidden by default) ─────── */
.gl-prog {
  display: flex; align-items: center; gap: 6px 14px; flex-wrap: wrap;
  margin-top: 4px; font-size: 0.82rem; color: var(--krabsy-ink-mute);
}
.gl-prog[hidden] { display: none; }
.gl-prog strong { color: var(--krabsy-ink); font-variant-numeric: tabular-nums; }
.gl-prog-stat { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.gl-prog-stat svg { width: 14px; height: 14px; color: var(--k-main); }
.gl-prog-chips { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.gl-prog-chip {
  display: inline-flex; align-items: center; min-height: 28px; padding: 0 12px;
  border-radius: var(--radius-pill); background: var(--k-chip-bg); color: var(--k-chip-fg);
  box-shadow: inset 0 0 0 1.5px var(--k-chip-line);
  font-weight: 700; font-size: 0.8rem; text-decoration: none;
}
.gl-prog-chip:hover { background: var(--k-ink-8); color: var(--k-chip-fg); }
.gl-prog-link { font-weight: 700; color: var(--k-link); text-decoration: underline; white-space: nowrap; }
.gl-prog-link:hover { color: var(--k-link-hover); text-decoration: underline; }
@media (max-width: 559px) {
  /* line 1: accuracy · streak · stats link; line 2: verbs to practise */
  .gl-head.has-progress { align-items: flex-start; }
  .gl-prog { font-size: 0.8rem; gap: 0 12px; margin-top: 0; }
  .gl-prog-chips { order: 3; flex: 1 1 100%; }
  .gl-prog-chip { min-height: 40px; padding: 0 14px; }
  .gl-prog-link { display: inline-flex; align-items: center; min-height: 40px; margin-left: auto; }
  .gl-prog-link span { display: none; }
}

/* ── Badges (never smaller than 12px) ─────────────────────────────── */
.bdg {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 2px 9px; border-radius: var(--radius-pill);
  font-size: 0.75rem; font-weight: 700; letter-spacing: 0.3px;
  line-height: 1.5; white-space: nowrap;
  background: var(--k-ink-8); color: var(--krabsy-ink);
}
.bdg-3d    { background: var(--k-acc); color: var(--k-ink); }
.bdg-new   { background: var(--k-main); color: #fff; }
.bdg-beta  { background: var(--k-main-15); color: var(--k-ink); }
.bdg-phone { background: var(--k-acc-16); color: var(--k-ink); }
.bdg-big   { background: transparent; color: var(--k-ink); box-shadow: inset 0 0 0 1px var(--k-ink-22); }
.bdg-soon  { background: var(--k-ink); color: #fff; }

/* ── Top row: the featured game (a wide tile) + the profile card ────
   Owner 2026-11-25: the old dark banner was too big and too different from
   the other games. The featured game is now a tile like the grid's (.gt),
   only wider, with a visible play button; next to it the child's figure and
   shells (.lf, see below). On wide screens the row sits on the grid's four
   columns: tile = three columns, figure = one. */
.gl-top { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.gl-top-feat { display: grid; min-width: 0; }
.gt-wide .gt-thumb { aspect-ratio: 16 / 9; }   /* always 16:9, like the small tiles (owner 2026-11-28) */
.gt-wide .gt-thumb img { object-position: 50% 60%; }
.gt-wide .gt-flags { top: 10px; left: 10px; gap: 6px; }
.gt-wide .gt-flags .bdg { font-size: 0.8rem; padding: 3px 11px; }
.gt-wide { box-shadow: inset 0 0 0 2px var(--k-acc), var(--shadow-card); }
.gt-wide .gt-body { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 4px 12px; padding: 12px 14px 14px; flex: 0 0 auto; }
.gt-wide .gt-name { font-size: 1.25rem; grid-column: 1; }
.gt-wide .gt-tag { grid-column: 1; flex: none; font-size: 0.9rem; color: var(--krabsy-ink-mute); }
.gt-wide .gt-meta { grid-column: 1; }
.gt-wide .bdg-topic { display: none; }
.gt-cta {
  grid-column: 2; grid-row: 1 / span 3; display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 16px; border-radius: var(--radius-pill);
  background: var(--k-btn-bg); color: var(--k-btn-fg); font-weight: 800; font-size: 0.9rem;
  box-shadow: 0 3px 0 var(--k-btn-edge); white-space: nowrap;
}
.gt-cta svg { width: 14px; height: 14px; }
a.gt-wide:hover .gt-cta { background: var(--k-btn-bg-hover); }
@media (min-width: 560px) {
  .gl-top { gap: 16px; }
  .gt.gt-wide { flex-direction: row; }
  /* the picture keeps 16:9 and is never stretched to the card height */
  .gt-wide .gt-thumb { flex: 0 0 58%; aspect-ratio: 16 / 9; align-self: center; }
  .gt-wide .gt-body { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 8px; padding: 14px 22px 16px; flex: 1 1 auto; min-width: 0; }
  .gt-wide .gt-name { font-size: 1.6rem; }
  .gt-wide .gt-tag { font-size: 1rem; line-height: 1.4; }
  .gt-wide .bdg-topic { display: inline-flex; }
  .gt-cta { margin-top: 4px; padding: 10px 22px; font-size: 0.95rem; }
}
@media (min-width: 1000px) {
  .gl-top { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
  .gl-top-feat { grid-column: span 3; }
}

/* The child's figure (#gl-figure): it stands freely on the page, no tile, with a soft
   shadow under its feet and a small label (shells, link). First the picture, then the
   live 3D figure on a transparent canvas (krabsy-landing-figure.js, class .is-live).
   The canvas is larger than the spot (room for a jump and a wave) and lets clicks
   through. Owner 2026-11-25: the figure is for spinning (drag), only the button under
   it opens the profile. Below 1000px: figure left, label right, in the
   slot under the featured tile. */
.lf { display: flex; min-width: 0; margin-top: 8px; }   /* a tall hat stays off the tile above */
.lf-link {
  flex: 1 1 auto; min-width: 0; display: flex; align-items: center; justify-content: center; gap: 4px 12px;
  color: var(--krabsy-ink); text-decoration: none; border-radius: var(--radius-md);
  -webkit-tap-highlight-color: transparent;
}
.lf-stage { position: relative; display: block; width: 122px; height: 126px; }
/* arrows to switch figures right here (owner 2026-11-25) */
.lf-pick { position: relative; display: flex; align-items: center; flex: 0 0 auto; }
.lf-arrow {
  position: relative; z-index: 2; flex: 0 0 auto; width: 34px; height: 34px; padding: 0; border: 0; border-radius: 50%;
  background: #fff; color: var(--krabsy-ink); box-shadow: 0 2px 0 rgba(29, 35, 80, 0.18), inset 0 0 0 1.5px rgba(29, 35, 80, 0.12);
  display: grid; place-items: center; cursor: pointer; -webkit-tap-highlight-color: transparent;
  transition: transform 0.12s ease, background 0.12s ease;
}
.lf-arrow[hidden] { display: none; }
.lf-arrow svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.lf-arrow:hover { background: var(--k-acc); }
.lf-arrow:active { transform: scale(0.92); }
.lf-arrow:focus-visible { outline: 3px solid var(--krabsy-ink); outline-offset: 2px; }
.is-live .lf-stage { cursor: grab; touch-action: pan-y; user-select: none; -webkit-user-select: none; -webkit-user-drag: none; }
.lf-img { -webkit-user-drag: none; user-select: none; }
.is-live .lf-stage:active { cursor: grabbing; }
.lf-stage::before {            /* ground shadow under the picture */
  content: ""; position: absolute; left: 50%; bottom: 3%; width: 70%; height: 13%; transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(29, 35, 80, 0.26), rgba(29, 35, 80, 0.1) 60%, rgba(29, 35, 80, 0));
  transition: opacity 0.35s ease;
}
.lf-img {
  position: absolute; left: 50%; bottom: -1%; height: 116%; width: auto; aspect-ratio: 1; transform: translateX(-50%);
  transition: opacity 0.35s ease;
}
.lf-canvas {
  position: absolute; left: -22%; top: -50%; width: 144%; height: 152%;
  pointer-events: none; opacity: 0; transition: opacity 0.35s ease;
}
.lf-canvas[hidden] { display: none; }
.is-live .lf-canvas { opacity: 1; }
.is-live .lf-img, .is-live .lf-stage::before { opacity: 0; }
.lf-label {
  display: flex; flex-direction: column; align-items: flex-start; gap: 6px; min-width: 0;
  color: var(--krabsy-ink); text-decoration: none; -webkit-tap-highlight-color: transparent;
}
.lf-shells {
  display: inline-flex; align-items: center; gap: 5px; padding: 2px 12px 2px 8px; border-radius: var(--radius-pill);
  background: #fff; box-shadow: inset 0 0 0 1.5px var(--k-main);
  font-weight: 700; font-size: 0.85rem; white-space: nowrap;
}
.lf-shells[hidden] { display: none; }
.lf-shells-ico { width: 20px; height: 20px; flex: 0 0 auto; }
.lf-shells b { font-size: 1.02rem; font-variant-numeric: tabular-nums; }
.lf-cta {                       /* secondary button (the tile's 'Jetzt spielen' is the primary): the way to the profile / figure page */
  display: inline-block; padding: 7px 16px; border-radius: var(--radius-pill);
  background: var(--k-btn2-bg); color: var(--k-btn2-fg); font-weight: 800; font-size: 0.95rem; white-space: nowrap;
  box-shadow: inset 0 0 0 2px var(--k-btn2-line), 0 3px 0 var(--k-btn2-edge); transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.lf-label:hover .lf-cta { background: var(--k-btn2-bg-hover); }
.lf-label:active .lf-cta { transform: translateY(2px); box-shadow: inset 0 0 0 2px var(--k-btn2-line), 0 1px 0 var(--k-btn2-edge); }
.lf-label:focus-visible { outline: none; }
.lf-label:focus-visible .lf-cta { outline: 3px solid var(--krabsy-ink); outline-offset: 2px; }
/* The way to the figure editor (owner 2026-11-27: "the character editor is too hidden"):
   a pencil badge on the figure and, for a child who has the profile button, a second
   button "Figur ändern". (A new visitor's main button already says "Bau deine Figur".) */
.lf-stage-wrap { position: relative; display: block; flex: 0 0 auto; }
.lf-pencil {
  position: absolute; z-index: 3; right: -8px; bottom: -4px; width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center; background: #fff; -webkit-tap-highlight-color: transparent;
  box-shadow: inset 0 0 0 2px rgba(29, 35, 80, 0.16), 0 3px 0 rgba(29, 35, 80, 0.16);
  transition: transform 0.12s ease, background 0.12s ease;
}
.lf-pencil .ki { width: 24px; height: 24px; display: block; }
.lf-pencil:hover { background: var(--k-acc-16); transform: rotate(-8deg) scale(1.06); }
.lf-pencil:active { transform: translateY(2px); }
.lf-pencil:focus-visible, .lf-edit:focus-visible { outline: 3px solid var(--krabsy-ink); outline-offset: 2px; }
.lf-btns { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; min-width: 0; }
.lf-edit {
  display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 4px 16px 4px 10px; border-radius: var(--radius-pill);
  background: #fff; color: var(--krabsy-ink); font-weight: 700; font-size: 0.95rem; white-space: nowrap; text-decoration: none;
  box-shadow: inset 0 0 0 2px rgba(29, 35, 80, 0.16), 0 3px 0 rgba(29, 35, 80, 0.12);
  transition: transform 0.12s ease, box-shadow 0.12s ease; -webkit-tap-highlight-color: transparent;
}
.lf-edit .ki { width: 22px; height: 22px; flex: 0 0 auto; display: block; }
.lf-edit:hover { background: var(--k-acc-16); color: var(--krabsy-ink); }
.lf-edit:active { transform: translateY(2px); box-shadow: inset 0 0 0 2px rgba(29, 35, 80, 0.16), 0 1px 0 rgba(29, 35, 80, 0.12); }
.lf:not(.is-mine) .lf-edit { display: none; }
/* "Jetzt üben · 5 Minuten" with the weekly ring (.kp-go in krabsy-practice.css), under the profile button */
.lf-acts { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; min-width: 0; }
@media (max-width: 559px) {      /* phones: figure + its buttons in a row, the practice button full width below */
  .lf-link { flex-wrap: wrap; row-gap: 10px; }
  .lf-acts { display: contents; }
  .lf-acts .kp-go { flex: 1 1 100%; justify-content: center; }
}
@media (min-width: 560px) and (max-width: 999px) {   /* small tablets: figure, its buttons, the practice button in one row */
  .lf-acts { flex-direction: row; align-items: center; gap: 18px; }
}
@media (min-width: 1000px) {
  .lf-acts { align-items: center; gap: 8px; }
  .lf-btns { gap: 6px; }
  /* the narrow column: the two buttons stacked at one width; the shell count moves up to
     the figure's feet (left; the pencil is on the right), so the column stays as tall as
     the featured tile */
  .lf-btns { position: relative; align-items: stretch; }
  .lf-edit { justify-content: center; }
  .lf-label .lf-cta { flex: 1 1 auto; text-align: center; }
  .lf-shells { position: absolute; z-index: 3; right: calc(50% + 34px); bottom: calc(100% + 4px); background: #fff; }
  .lf { margin-top: 0; }
  .lf-link { flex-direction: column; justify-content: flex-end; gap: 2px; padding-bottom: 4px; }
  .lf-stage { width: 180px; height: 186px; }
  .lf-label { flex-direction: row; align-items: center; justify-content: center; flex-wrap: wrap; gap: 4px 10px; }
}
@media (prefers-reduced-motion: reduce) { .lf-canvas, .lf-img, .lf-stage::before, .lf-pencil, .lf-edit { transition: none; } .lf-pencil:hover { transform: none; } }

/* ── Games grid ───────────────────────────────────────────────────── */
.gl-games { padding-top: 16px; padding-bottom: 28px; }
.gl-bar { display: flex; align-items: center; gap: 12px; margin: 0 0 12px; }
.gl-bar h2 { font-family: var(--font-display); font-weight: normal; font-size: 1.5rem; margin: 0; line-height: 1.2; flex: 0 0 auto; }
.gl-chips-wrap { position: relative; flex: 1 1 auto; min-width: 0; }
.gl-chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 4px; margin: -4px; }
.gl-chips::-webkit-scrollbar { display: none; }
/* Right-edge fade: only while more chips are off-screen (class set by JS) */
.gl-chips-wrap.can-scroll::after {
  content: ""; position: absolute; top: 0; right: -4px; bottom: 0; width: 44px; pointer-events: none;
  background: linear-gradient(to right, rgba(247, 246, 242, 0), var(--k-bg) 85%);
}
.gl-chip {
  flex: 0 0 auto; border: 1.5px solid var(--k-ink-22); background: var(--krabsy-white);
  color: var(--krabsy-ink); font-family: var(--font-body); font-weight: 700; font-size: 0.82rem;
  min-height: 36px; padding: 0 16px; border-radius: var(--radius-pill); cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.gl-chip[hidden] { display: none; }
.gl-chip:hover { background: var(--k-acc-16); }
.gl-chip[aria-pressed="true"] { background: var(--krabsy-ink); border-color: var(--krabsy-ink); color: #fff; }
@media (max-width: 559px) {
  /* h2 stays in the document for screen readers and the outline */
  .gl-bar h2 { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
  .gl-chip { min-height: 40px; }
}

.gl-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 700px)  { .gl-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; } }
@media (min-width: 1000px) { .gl-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; } }

.gt {
  display: flex; flex-direction: column; background: var(--krabsy-white);
  border-radius: var(--radius-md); overflow: hidden; box-shadow: var(--shadow-card);
  color: var(--krabsy-ink); text-decoration: none; transition: transform 0.18s ease;
}
.gt[hidden] { display: none; }
a.gt:hover { transform: translateY(-3px); color: var(--krabsy-ink); }
.gt-thumb { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: var(--k-ink-8); }
.gt-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gt-flags { position: absolute; top: 8px; left: 8px; display: flex; gap: 4px; }
.gt-soon { position: absolute; top: 8px; right: 8px; }
.gt-play {
  position: absolute; right: 8px; bottom: 8px; padding: 5px 12px; border-radius: var(--radius-pill);
  background: var(--k-btn-bg); color: var(--k-btn-fg); font-size: 0.8rem; font-weight: 800;
  opacity: 0; transition: opacity 0.15s ease;
}
a.gt:hover .gt-play, a.gt:focus-visible .gt-play { opacity: 1; }
.gt-body { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 5px; flex: 1; }
.gt-name { font-family: var(--font-display); font-weight: normal; font-size: 1.08rem; line-height: 1.15; margin: 0; }
.gt-tag { margin: 0; font-size: 0.82rem; line-height: 1.35; color: var(--krabsy-ink-mute); flex: 1; }
.gt-meta { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 2px; }
@media (max-width: 559px) {
  .gt-body { padding: 8px 10px 10px; }
  .gt-name { font-size: 1rem; }
  .gt-play { display: none; }
}
/* Coming soon: visible and attractive, clearly not clickable */
.gt.is-soon { cursor: default; background: var(--k-ink-8); box-shadow: inset 0 0 0 2px var(--k-ink-8); }
.gt.is-soon .gt-thumb img { opacity: 0.85; }
.gt.is-soon .gt-name { color: var(--krabsy-ink-mute); }

/* ── Practice without a game ──────────────────────────────────────── */
/* a turquoise tint with a wavy top edge; the crab stands on it (right) */
.gl-band { position: relative; background: var(--k-acc-16); margin-top: 40px; padding: 20px 0 34px; }
.gl-wave { position: absolute; z-index: 2; left: 0; right: 0; bottom: calc(100% - 2px); width: 100%; height: 34px; display: block; }
.gl-wave path { fill: var(--k-acc-16); }
.gl-band > .wrap { position: relative; }
/* the whole crab stands on the wave (owner 2026-11-29: no half crab) */
.gl-peek { position: absolute; z-index: 3; right: 40px; bottom: calc(100% + 14px); width: 150px; height: auto; pointer-events: none; }
@media (max-width: 699px) { .gl-peek { width: 104px; right: 16px; } .gl-band { margin-top: 32px; } }
.gl-h2 { font-family: var(--font-display); font-weight: normal; font-size: 1.5rem; line-height: 1.2; margin: 0 0 2px; }
.gl-sub { font-size: 0.92rem; color: var(--k-ink); margin: 0 0 14px; }
/* One card per topic of the section (tools/render_landing_intro.py, plan 2026-11-28 item 3):
   two compact columns on phones (picture on top), two wide cards per row from 700 px, three
   from 1000 px. The quick links (Sprint, Karteikarten) are a row below. */
.pr-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 700px)  { .pr-cards { gap: 14px; } }
@media (min-width: 1000px) { .pr-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.pr-card {
  display: flex; gap: 14px; align-items: center; padding: 10px 14px 10px 10px; min-width: 0;
  background: var(--krabsy-white); border-radius: var(--radius-md); box-shadow: var(--shadow-card);
  color: var(--krabsy-ink); text-decoration: none; transition: transform 0.18s ease;
}
.pr-card:hover { transform: translateY(-2px); color: var(--krabsy-ink); }
.pr-pic { width: 96px; height: 72px; object-fit: cover; border-radius: 10px; flex: 0 0 auto; background: #fff; }
/* a topic without its own picture: a text-free tile in the palette colours with an icon */
.pr-tile { display: grid; place-items: center; }
.pr-tile .ki { box-sizing: content-box; width: 28px; height: 28px; padding: 6px; border-radius: 50%; background: #fff; }
.pr-tile-acc  { background: var(--k-acc); }
.pr-tile-main { background: var(--k-main); }
.pr-tile-ink  { background: var(--k-ink); }
.pr-txt { min-width: 0; }
.pr-card h3 { font-family: var(--font-display); font-weight: normal; font-size: 1.1rem; margin: 0 0 2px; line-height: 1.2; }
.pr-card p { margin: 0; font-size: 0.8rem; color: var(--krabsy-ink-mute); line-height: 1.4; }
.pr-card .pr-ex { color: var(--krabsy-ink); font-weight: 700; }
.pr-card .pr-grade {          /* school years / level (owner 2026-11-30) */
  display: inline-block; margin-top: 5px; padding: 1px 8px; border-radius: 999px;
  background: var(--k-acc-16, #ede9fe); color: var(--krabsy-ink); font-size: 0.72rem; font-weight: 800;
}
.pr-arrow { margin-left: auto; color: var(--k-main); width: 20px; height: 20px; flex: 0 0 auto; }
@media (max-width: 699px) {
  .pr-card { flex-direction: column; align-items: stretch; gap: 8px; padding: 8px 8px 10px; }
  .pr-pic { width: 100%; height: 64px; }
  .pr-txt { padding: 0 4px; }
  .pr-card h3 { font-size: 1rem; }
  .pr-stats, .pr-arrow { display: none; }
}
.pr-quick { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 12px; }
@media (min-width: 700px) { .pr-quick { gap: 14px; margin-top: 14px; } }
@media (min-width: 1000px) { .pr-quick { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.pr-q {
  display: flex; align-items: center; gap: 10px; padding: 10px 14px; min-height: 48px;
  background: var(--krabsy-white); border-radius: var(--radius-md); box-shadow: var(--shadow-card);
  text-decoration: none; color: var(--krabsy-ink); transition: transform 0.18s ease;
}
.pr-q:hover { transform: translateY(-2px); color: var(--krabsy-ink); }
.pr-q svg { width: 24px; height: 24px; flex: 0 0 auto; color: var(--k-main); }
.pr-q b { display: block; font-size: 0.9rem; }
.pr-q small { display: block; font-size: 0.75rem; color: var(--krabsy-ink-mute); }

/* ── Teacher strip ────────────────────────────────────────────────── */
.gl-teach-wrap { padding-top: 26px; padding-bottom: 6px; }
.gl-tutor-line { margin: 12px 4px 0; font-size: 0.95rem; color: var(--k-ink-72); text-align: right; }
.gl-tutor-line a { color: var(--k-link); font-weight: 700; text-underline-offset: 3px; }
.gl-teach {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  padding: 16px 22px 16px 20px; border-radius: var(--radius-md);
  background: #fff; color: var(--k-ink); text-decoration: none; box-shadow: inset 6px 0 0 var(--k-main), var(--shadow-card);
  transition: transform 0.18s ease;
}
a.gl-teach:hover { transform: translateY(-2px); color: var(--krabsy-ink); }
.gl-teach-crab { width: 84px; height: auto; flex: 0 0 auto; margin: -6px 0 -4px; }
.gl-teach-txt { flex: 1 1 220px; min-width: 0; }
.gl-teach-txt b { display: block; font-family: var(--font-display); font-weight: normal; font-size: 1.3rem; line-height: 1.2; }
.gl-teach-txt span { font-size: 0.95rem; color: var(--k-ink-72); }
@media (max-width: 559px) { .gl-teach-crab { width: 62px; } .gl-teach { gap: 10px 12px; padding: 14px 14px 14px 18px; } .gl-teach-txt { flex-basis: 180px; } }
.gl-teach-cta { padding: 9px 18px; border-radius: var(--radius-pill); background: var(--k-btn2-bg); color: var(--k-btn2-fg); box-shadow: inset 0 0 0 2px var(--k-btn2-line), 0 3px 0 var(--k-btn2-edge); font-weight: 800; font-size: 0.88rem; white-space: nowrap; }
.gl-teach:hover .gl-teach-cta, a.gl-teach-cta:hover { background: var(--k-btn2-bg-hover); }
a.gl-teach-cta { text-decoration: none; }
/* worksheets in the strip (2026-11-30: teachers could not find them from the home page) */
.gl-teach-txt .gl-teach-sheets { display: block; margin-top: 6px; font-size: 0.95rem; color: var(--k-ink); }
.gl-teach-sheets a { color: var(--k-ink); font-weight: 800; text-underline-offset: 3px; display: inline-block; padding: 4px 0; }
.gl-teach-sheets a:hover { color: var(--k-main); }

/* ── Merged SEO text ──────────────────────────────────────────────── */
.k-article.gl-about { max-width: 860px; margin-top: var(--space-6); }
@media (max-width: 919px) { .k-article.gl-about { margin-left: 16px; margin-right: 16px; } }
@media (min-width: 760px) {
  .gl-about-cols { columns: 2; column-gap: 32px; }
  .gl-about-cols > div { break-inside: avoid; }
  .gl-about-cols > div:first-child h3 { margin-top: 0; }
}
.gl-about-cols h3 { margin-top: var(--space-4); }

.ch-footer-tagline { display: block; margin-top: 6px; font-size: 0.7rem; opacity: 0.85; }

@media (min-width: 1000px) {     /* the narrow figure column: title on two lines, without the dot */
  .lf-acts .kp-go-txt b > .kp-go-sep { display: none; }
  .lf-acts .kp-go-txt b > span { display: block; }
}

/* Touch screens: 44 px tap targets (site review S19). */
@media (pointer: coarse) {
  .gl-chip, .lf-label { min-height: 44px; }
  .lf-label { justify-content: center; }
  .lf-arrow::after, .lf-pencil::after {
    content: ""; position: absolute; left: 50%; top: 50%; width: 44px; height: 44px; transform: translate(-50%, -50%);
  }
}
