/* Hop & Learn website. Same sticker look as the game and as kids.kaivocards.com: thick navy outlines, hard offset shadows,
   a bright sky with clouds and green hills. Built by tools/site/build.py. No external resources (fonts are self-hosted). */

/* Fonts: the game's own families. unicode-range makes each visitor download only the files for the script they read.
   Fredoka (titles) covers Latin and Hebrew; Rubik (text) covers Latin, Hebrew, Cyrillic and Arabic; Baloo 2 covers Devanagari.
   Chinese, Japanese and Korean use the system fonts. */
@font-face { font-family: "HL Fredoka"; src: url("/fonts/fredoka.ttf?v=071c16b87b") format("truetype"); font-weight: 300 700; font-style: normal; font-display: swap; unicode-range: U+20-7E, U+A0-17F, U+2C6, U+2DC, U+590-5FF, U+2010-2027, U+2030-203A, U+20AC, U+2122, U+2190-2193, U+2212, U+FB1D-FB4F; }
@font-face { font-family: "HL Rubik"; src: url("/fonts/rubik-hebrew-latin.woff2?v=4bce92e956") format("woff2"); font-weight: 400 900; font-style: normal; font-display: swap; unicode-range: U+20-7E, U+A0-17F, U+192, U+2C6, U+2DC, U+590-5FF, U+200C-2027, U+2030-203A, U+20AC, U+2122, U+2190-2193, U+2212, U+2605, U+2713, U+2715, U+FB1D-FB4F; }
@font-face { font-family: "HL Rubik"; src: url("/fonts/rubik.ttf?v=3b7d0fe762") format("truetype"); font-weight: 300 900; font-style: normal; font-display: swap; unicode-range: U+400-52F, U+600-6FF, U+750-77F, U+8A0-8FF, U+FB50-FDFF, U+FE70-FEFF; }
@font-face { font-family: "HL Baloo Title"; src: url("/fonts/baloo-title-devanagari.woff2?v=fdf41da0df") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; unicode-range: U+900-97F, U+1CD0-1CFF, U+200C-200D, U+25CC, U+A8E0-A8FF; }
@font-face { font-family: "HL Baloo"; src: url("/fonts/baloo-devanagari.woff2?v=255d53d4c3") format("woff2"); font-weight: 400 800; font-style: normal; font-display: swap; unicode-range: U+900-97F, U+1CD0-1CFF, U+200C-200D, U+25CC, U+A8E0-A8FF; }

:root {
  --ink: #14213d; --paper: #ffffff; --sky: #59c4ff; --sky2: #e6f8ff; --gold: #ffc93c; --grass: #2bb673; --grass2: #1f8f58;
  --blue: #3d9bff; --orange: #ff8a3d; --pink: #ff6fa8; --text: #14213d; --muted: #3c4a6b; --soft: #eef9ff; --link: #0b62c4;
  --display: "HL Fredoka", "Arial Rounded MT Bold", ui-rounded, system-ui, sans-serif;
  --read: "HL Rubik", ui-rounded, "SF Pro Rounded", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --lh: 1.6; --tlh: 1.12;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { margin: 0; font-family: var(--read); font-size: 18px; line-height: var(--lh); color: var(--text); background: var(--soft); overflow-x: hidden; padding-inline: env(safe-area-inset-left, 0) env(safe-area-inset-right, 0); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--link); }
:focus-visible { outline: 4px solid var(--ink); outline-offset: 3px; box-shadow: 0 0 0 7px var(--gold); }
.wrap { width: min(1080px, 100% - 32px); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; inset-inline-start: 8px; top: -80px; background: var(--gold); color: var(--ink); padding: 10px 16px; border: 3px solid var(--ink); border-radius: 12px; z-index: 50; font-weight: 700; }
.skip:focus { top: 8px; }

/* top bar sits on the sky */
.bar { position: absolute; inset: 0 0 auto 0; z-index: 10; padding-top: env(safe-area-inset-top, 0); }
.bar .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding-block: 12px 8px; }
.brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; font: 700 24px/1 var(--display); color: #fff; text-decoration: none; -webkit-text-stroke: 5px var(--ink); paint-order: stroke fill; text-shadow: 3px 3px 0 var(--ink); white-space: nowrap; }
.brand img { width: 40px; height: 40px; border: 3px solid var(--ink); border-radius: 11px; box-shadow: 2px 3px 0 var(--ink); }
.bar select { margin-inline-start: auto; font: 700 15px var(--read); color: var(--ink); background: #fff; border: 3px solid var(--ink); border-radius: 12px; padding: 8px 10px; min-height: 44px; box-shadow: 0 4px 0 var(--ink); max-width: 46vw; }
.bar nav { display: flex; gap: 8px; align-items: center; order: 3; flex: 0 0 100%; overflow-x: auto; padding: 0 2px 8px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.bar nav::-webkit-scrollbar { display: none; }
.bar nav a { flex: none; white-space: nowrap; font: 700 14px var(--read); color: var(--ink); background: #fff; border: 3px solid var(--ink); border-radius: 12px; padding: 8px 12px; min-height: 44px; text-decoration: none; box-shadow: 0 4px 0 var(--ink); display: inline-flex; align-items: center; }
.bar nav a[aria-current="page"] { background: var(--gold); }

/* hero: sky, sun, clouds, rolling grass */
.hero { position: relative; isolation: isolate; overflow: hidden; background: linear-gradient(180deg, var(--sky) 0%, #8fd6ff 55%, var(--sky2) 100%); border-bottom: 6px solid var(--ink); color: var(--ink); }
.sun { position: absolute; inset-inline-end: 7%; top: 74px; width: clamp(64px, 12vw, 120px); aspect-ratio: 1; border-radius: 50%; background: var(--gold); border: 5px solid var(--ink); box-shadow: 0 0 0 14px rgba(255, 255, 255, .35); z-index: -1; animation: bob 7s ease-in-out infinite; }
.cloud { position: absolute; background: #fff; border: 5px solid var(--ink); border-radius: 999px; height: 44px; width: 130px; z-index: -1; opacity: .96; animation: drift 40s linear infinite alternate; }
.cloud::before, .cloud::after { content: ""; position: absolute; background: #fff; border: 5px solid var(--ink); border-bottom: 0; border-radius: 999px 999px 0 0; }
.cloud::before { width: 56px; height: 40px; left: 18px; top: -30px; } .cloud::after { width: 44px; height: 30px; left: 70px; top: -22px; }
.cloud.a { left: 4%; top: 120px; } .cloud.b { left: 48%; top: 210px; transform: scale(.8); animation-duration: 55s; } .cloud.c { left: 78%; top: 330px; transform: scale(.65); animation-duration: 47s; }
.hero .wrap { display: grid; grid-template-columns: 1.15fr .85fr; gap: 28px; align-items: center; padding-block: 110px 150px; }
.hero .copy { text-align: center; }
.logo { margin: 0; font: 700 clamp(48px, 9vw, 92px)/1.02 var(--display); color: #fff; -webkit-text-stroke: 10px var(--ink); paint-order: stroke fill; text-shadow: 6px 7px 0 var(--ink); letter-spacing: .01em; }
.tagline { display: inline-block; font: 600 clamp(20px, 3.4vw, 28px)/1.2 var(--display); margin: 18px 0 0; color: var(--ink); background: var(--gold); border: 4px solid var(--ink); border-radius: 16px; padding: 10px 18px; box-shadow: 6px 6px 0 var(--ink); transform: rotate(-1.5deg); max-width: 100%; }
.lede { margin: 22px auto 0; font-size: clamp(17px, 2.4vw, 20px); font-weight: 600; max-width: 40ch; color: var(--ink); }
.devices { display: inline-block; margin-top: 14px; font: 700 14px var(--read); padding: 4px 12px; border: 3px solid var(--ink); border-radius: 999px; background: #fff; color: var(--ink); }
.cta { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; align-items: center; margin-top: 22px; }
.store { display: inline-flex; align-items: center; gap: 12px; min-height: 60px; background: #111; color: #fff; border: 4px solid var(--ink); border-radius: 16px; padding: 8px 20px 8px 16px; text-decoration: none; box-shadow: 0 6px 0 var(--ink); transition: transform .1s; text-align: start; }
.store:hover { transform: translateY(-2px); } .store:active { transform: translateY(4px); box-shadow: 0 2px 0 var(--ink); }
.store svg { width: 30px; height: 30px; fill: #fff; flex: none; }
.store small { display: block; font: 600 13px/1.1 var(--read); }
.store b { display: block; font: 600 23px/1.1 var(--read); letter-spacing: -.01em; }
.art { position: relative; justify-self: center; width: min(300px, 78%); }
.art .shot { border: 5px solid var(--ink); border-radius: 30px; box-shadow: 10px 12px 0 var(--ink); transform: rotate(4deg); background: var(--sky); }
.art .icon { position: absolute; width: 34%; inset-inline-start: -14%; bottom: 8%; border: 5px solid var(--ink); border-radius: 24%; box-shadow: 6px 7px 0 var(--ink); transform: rotate(-9deg); animation: bob 5s ease-in-out infinite; }
[dir="rtl"] .art .shot { transform: rotate(-4deg); } [dir="rtl"] .art .icon { transform: rotate(9deg); }
.hills { position: absolute; left: 0; right: 0; bottom: -2px; height: 110px; z-index: -1; }
.hills i { position: absolute; bottom: 0; background: var(--grass); border: 5px solid var(--ink); border-radius: 50% 50% 0 0; }
.hills i:nth-child(1) { left: -10%; width: 70%; height: 90px; } .hills i:nth-child(2) { right: -12%; width: 75%; height: 110px; background: var(--grass2); }
.hills i:nth-child(3) { left: 30%; width: 40%; height: 60px; }
@keyframes bob { 50% { translate: 0 -10px; } }
@keyframes drift { to { translate: 60px 0; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; scroll-behavior: auto !important; transition: none !important; } }

/* sections */
section.block { padding-block: 52px 8px; }
h2.title { font: 700 clamp(28px, 4.6vw, 42px)/var(--tlh) var(--display); margin: 0 0 20px; color: var(--text); }
h2.title::after { content: ""; display: block; width: 96px; height: 10px; border: 3px solid var(--ink); border-radius: 8px; margin-top: 10px; background: linear-gradient(90deg, var(--blue) 0 25%, var(--gold) 25% 50%, var(--grass) 50% 75%, var(--orange) 75%); }
[dir="rtl"] h2.title::after { background: linear-gradient(-90deg, var(--blue) 0 25%, var(--gold) 25% 50%, var(--grass) 50% 75%, var(--orange) 75%); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.two p { margin: 0; }
.intro p:first-child { font-size: 22px; font-weight: 700; font-family: var(--display); line-height: 1.35; }
.grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.grid.g3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.win { background: var(--paper); border: 4px solid var(--ink); border-radius: 18px; box-shadow: 7px 8px 0 var(--ink); overflow: hidden; }
.win > header { display: flex; align-items: center; gap: 8px; padding: 10px 16px; border-bottom: 4px solid var(--ink); background: var(--blue); }
.win.gold > header { background: var(--gold); } .win.green > header { background: var(--grass); } .win.orange > header { background: var(--orange); } .win.pink > header { background: var(--pink); }
.win > header :is(h1, h2, h3) { margin: 0; flex: 1; font: 700 22px/var(--tlh) var(--display); color: #fff; -webkit-text-stroke: 4px var(--ink); paint-order: stroke fill; word-spacing: .1em; text-shadow: 2px 2px 0 var(--ink); }
.win > header i { flex: none; width: 14px; height: 14px; border: 3px solid var(--ink); border-radius: 50%; background: #fff; }
.win .body { padding: 18px 22px 22px; }
.win .body > p { margin: 0; }
.pill { background: var(--paper); border: 4px solid var(--ink); border-radius: 18px; box-shadow: 5px 6px 0 var(--ink); padding: 16px 18px; }
.pill p { margin: 0; }
.pill.row { display: flex; gap: 14px; align-items: flex-start; }
.pill.row .dot { flex: none; margin: 0; }
.dot { width: 42px; height: 42px; border: 3px solid var(--ink); border-radius: 50%; margin-bottom: 10px; display: grid; place-items: center; font: 700 22px/1 var(--display); color: #fff; -webkit-text-stroke: 4px var(--ink); paint-order: stroke fill; }
.c-blue { background: var(--blue); } .c-gold { background: var(--gold); } .c-green { background: var(--grass); } .c-orange { background: var(--orange); } .c-pink { background: var(--pink); }
.ticks { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.ticks li { position: relative; padding-inline-start: 42px; }
.ticks li::before { content: "\2713"; position: absolute; inset-inline-start: 0; top: 0; width: 30px; height: 30px; border: 3px solid var(--ink); border-radius: 50%; background: var(--grass); color: #fff; font-weight: 900; font-size: 16px; display: grid; place-items: center; }
.ticks.big li { font-size: 19px; font-weight: 600; }
.ticks.cols { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px 28px; }

/* screenshots: a swipe row on phones, five in a row on wide screens */
.shots { display: flex; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 6px 4px 22px; margin: 0; list-style: none; scrollbar-width: thin; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain; }
.shots li { flex: 0 0 min(62vw, 240px); scroll-snap-align: center; }
.shots img { width: 100%; aspect-ratio: 460 / 1000; border: 4px solid var(--ink); border-radius: 24px; box-shadow: 6px 7px 0 var(--ink); background: var(--sky); }
@media (min-width: 980px) {
  .shots { display: grid; grid-template-columns: repeat(5, 1fr); overflow: visible; padding-inline: 0; }
  .shots li:nth-child(odd) img { transform: rotate(-1.5deg); } .shots li:nth-child(even) img { transform: rotate(1.5deg) translateY(10px); }
}

details { background: var(--paper); border: 4px solid var(--ink); border-radius: 16px; box-shadow: 4px 5px 0 var(--ink); margin-bottom: 14px; }
summary { cursor: pointer; padding: 14px 18px; font-weight: 700; list-style: none; display: flex; justify-content: space-between; gap: 12px; min-height: 52px; align-items: center; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; flex: none; font: 700 26px/1 var(--display); } details[open] summary::after { content: "\2212"; }
details p { margin: 0; padding: 0 18px 16px; }
.more { margin: 18px 0 0; font-weight: 600; }

/* closing band */
.band { margin-top: 56px; background: var(--gold); color: var(--ink); border: 4px solid var(--ink); border-radius: 22px; box-shadow: 7px 8px 0 var(--ink); padding: 26px 22px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; }
.band p { margin: 0; flex: 1 1 320px; font: 700 clamp(21px, 3vw, 26px)/1.3 var(--display); }
.band .icon { width: 84px; height: 84px; flex: none; border: 4px solid var(--ink); border-radius: 22px; box-shadow: 4px 5px 0 var(--ink); }

/* footer: the grass */
footer { margin-top: 64px; border-top: 6px solid var(--ink); background: var(--grass2); color: #fff; padding-block: 32px calc(32px + env(safe-area-inset-bottom, 0)); }
footer .wrap { display: flex; flex-wrap: wrap; gap: 6px 24px; align-items: center; }
footer h2 { flex-basis: 100%; margin: 0; font: 700 14px var(--read); letter-spacing: .08em; text-transform: uppercase; opacity: .92; }
footer a { color: #fff; font-weight: 700; padding: 8px 0; min-height: 44px; display: inline-flex; align-items: center; }
footer small { flex-basis: 100%; font-size: 15px; opacity: .95; }
.langs { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 0 16px; margin-top: 16px; padding-top: 12px; border-top: 2px dashed rgba(255, 255, 255, .5); font-size: 15px; }
.langs a { font-weight: 600; opacity: .92; text-decoration: none; }
.langs a:hover, .langs a[aria-current] { opacity: 1; text-decoration: underline; text-underline-offset: 3px; }

/* page hero for the text pages */
.page .hero .wrap { display: block; padding-block: 150px 84px; text-align: center; }
.page .hero .logo { font-size: clamp(40px, 7vw, 64px); }
.page .hills { height: 50px; } .page .hills i:nth-child(n) { height: 44px; }
.page .cloud.b, .page .cloud.c { display: none; }
.doc { max-width: 860px; margin: 36px auto 0; }
.doc .body h2 { font: 700 24px/var(--tlh) var(--display); margin: 28px 0 8px; }
.doc .body p, .doc .body li { max-width: 68ch; }
.doc .body ul { padding-inline-start: 1.3rem; }
.doc .body > :first-child { margin-top: 0; }
.updated { font-size: 14px; font-weight: 700; color: var(--muted); }
.doc .q { margin: 0 0 16px; }
.doc .q b { display: block; }

/* notes: translation notice and "also in your language" */
.note { background: var(--gold); color: var(--ink); border: 3px solid var(--ink); border-radius: 14px; padding: 10px 14px; margin: 0 0 18px; font-weight: 600; }
.note a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.note a.btn { text-decoration: none; }
.suggest { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: 18px 0 0; }
.suggest[hidden] { display: none; }
.suggest p { margin: 0; flex: 1 1 220px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 8px 18px; font: 600 18px/1.15 var(--display); color: var(--ink); background: #fff; border: 4px solid var(--ink); border-radius: 14px; box-shadow: 0 5px 0 var(--ink); text-decoration: none; cursor: pointer; transition: transform .1s; }
.btn:hover { transform: translateY(-2px); } .btn:active { transform: translateY(4px); box-shadow: 0 1px 0 var(--ink); }
.btn.green { background: #7ee3a8; } .btn.plain { background: transparent; box-shadow: none; border-color: transparent; text-decoration: underline; }
.hero .btn { background: #fff; }

/* wide screens: brand, menu and language on one line */
@media (min-width: 1000px) {
  .bar .wrap { flex-wrap: nowrap; padding-block: 14px; }
  .bar nav { order: 2; flex: 0 1 auto; overflow: visible; padding: 0 0 4px; margin-inline: auto; }
  .bar select { order: 3; margin-inline-start: 0; }
  .hero .copy { text-align: start; }
  .hero .cta { justify-content: flex-start; }
  .lede { margin-inline: 0; }
  .page .hero .wrap { padding-block: 110px 80px; }
}
/* phones and tablets: the menu takes a second row, so the hero starts lower */
@media (max-width: 999px) {
  .hero .wrap { padding-block-start: 150px; }
  .sun { top: 130px; }
  .cloud.a { top: 170px; } .cloud.b { top: 250px; }
}
@media (max-width: 760px) {
  .hero .wrap { grid-template-columns: 1fr; padding-block-end: 130px; gap: 40px; }
  .art { width: min(230px, 64%); }
  .two { grid-template-columns: 1fr; }
  .cloud.c { display: none; }
  .win .body { padding: 16px 16px 18px; }
  .band { padding: 22px 18px; }
}
@media (max-width: 420px) {
  .brand { font-size: 21px; -webkit-text-stroke-width: 4px; }
  .brand img { width: 34px; height: 34px; }
  .logo { -webkit-text-stroke-width: 8px; text-shadow: 4px 5px 0 var(--ink); }
  body { font-size: 17px; }
}
@media (max-width: 900px), (pointer: coarse) {
  .bar nav a, .bar select { min-width: 44px; justify-content: center; }
  footer a { min-width: 44px; justify-content: center; }
}

/* the brand name is Latin in every language: always the game's Fredoka */
.logo, .brand { font-family: "HL Fredoka", "Arial Rounded MT Bold", ui-rounded, system-ui, sans-serif; }

/* per-language fonts and spacing */
:lang(ru) { --display: "HL Rubik", "Arial Rounded MT Bold", system-ui, sans-serif; }
:lang(ar) { --display: "HL Rubik", "Geeza Pro", "Segoe UI", system-ui, sans-serif; --read: "HL Rubik", "Geeza Pro", "Segoe UI", system-ui, sans-serif; --lh: 1.8; --tlh: 1.4; }
:lang(he) { --lh: 1.65; --tlh: 1.25; }
:lang(hi) { --display: "HL Baloo Title", "HL Fredoka", "Kohinoor Devanagari", "Noto Sans Devanagari", system-ui, sans-serif; --read: "HL Baloo", "HL Rubik", "Kohinoor Devanagari", "Noto Sans Devanagari", system-ui, sans-serif; --lh: 1.75; --tlh: 1.4; }
:lang(zh) { --display: "HL Fredoka", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif; --read: "HL Rubik", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif; --lh: 1.75; --tlh: 1.3; }
:lang(ja) { --display: "HL Fredoka", "Hiragino Maru Gothic ProN", "Hiragino Sans", "Yu Gothic", "Noto Sans CJK JP", sans-serif; --read: "HL Rubik", "Hiragino Maru Gothic ProN", "Hiragino Sans", "Yu Gothic", "Noto Sans CJK JP", sans-serif; --lh: 1.8; --tlh: 1.3; }
:lang(ko) { --display: "HL Fredoka", "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans CJK KR", sans-serif; --read: "HL Rubik", "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans CJK KR", sans-serif; --lh: 1.75; --tlh: 1.3; }
:lang(ar) .ticks li, :lang(ar) details p { line-height: var(--lh); }
/* joined or dense scripts: no tracking and no uppercase, thinner sticker outlines */
html:is(:lang(ar), :lang(he), :lang(hi), :lang(zh), :lang(ja), :lang(ko)) footer h2 { letter-spacing: 0; text-transform: none; }
html:is(:lang(ar), :lang(hi), :lang(zh), :lang(ja), :lang(ko)) .win > header :is(h1, h2, h3) { -webkit-text-stroke-width: 3px; text-shadow: 2px 2px 0 var(--ink); }
html:is(:lang(zh), :lang(ja), :lang(ko)) :is(.tagline, h2.title, .band p, .intro p:first-child) { font-weight: 700; }
html:is(:lang(zh), :lang(ja), :lang(ko)) .intro p:first-child { font-family: var(--read); }
