/* Kasih4u games hub. Same design family as the homepage: sky + paper, Fredoka, crayon tiles. */
@font-face { font-family: "Fredoka"; src: url("/assets/fonts/fredoka-latin.woff2") format("woff2"); font-weight: 500 700; font-display: swap; }
@font-face { font-family: "Nunito"; src: url("/assets/fonts/nunito-latin.woff2") format("woff2"); font-weight: 400 800; font-display: swap; }
:root {
  --paper: #fff7ec; --sky: #bfe9ff; --card: #fff; --line: rgba(31,35,71,.12); --line-strong: rgba(31,35,71,.26);
  --ink: #1f2347;            /* 14.6:1 on paper */
  --muted: #4a4f78;          /* 7.3:1 */
  --blue: #4361ee; --yellow: #ffb703; --red: #e63946;
  --shadow-1: 0 1px 2px rgba(31,35,71,.06), 0 3px 8px rgba(31,35,71,.06);
  --shadow-3: 0 4px 8px rgba(31,35,71,.08), 0 24px 48px rgba(31,35,71,.14);
  --f-d: "Fredoka", ui-rounded, system-ui, sans-serif; --f-b: "Nunito", ui-rounded, system-ui, sans-serif;
  --ease: cubic-bezier(.16, 1, .3, 1);
  --safe-t: env(safe-area-inset-top, 0px); --safe-b: env(safe-area-inset-bottom, 0px);
}
*, *::before, *::after { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; background: linear-gradient(180deg, var(--sky) 0, #e8f7ff 340px, var(--paper) 640px); color: var(--ink); font-family: var(--f-b); font-size: 17px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
.hidden { display: none !important; }
[hidden] { display: none !important; }
a { color: inherit; }
h1, h2 { font-family: var(--f-d); font-weight: 700; margin: 0; letter-spacing: -.02em; line-height: 1.15; }
button { font: inherit; color: inherit; cursor: pointer; touch-action: manipulation; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 12px; }

.top { display: flex; align-items: center; gap: 10px; padding: calc(12px + var(--safe-t)) 18px 8px; max-width: 980px; margin: 0 auto; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; min-height: 44px; }
.word { font-family: var(--f-d); font-weight: 600; font-size: 1.6rem; } .word b { color: var(--red); }
.spacer { flex: 1; }
.icon-btn { display: inline-grid; place-items: center; min-width: 48px; height: 48px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-strong); background: #fff; font-family: var(--f-d); font-weight: 600; box-shadow: var(--shadow-1); transition: transform 150ms var(--ease); }
.icon-btn:active { transform: scale(.94); }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 12px 28px; border-radius: 999px; border: 2px solid var(--ink); background: #fff; font-family: var(--f-d); font-weight: 600; font-size: 1.1rem; box-shadow: 0 3px 0 var(--ink); text-decoration: none; transition: transform 150ms var(--ease), box-shadow 150ms var(--ease); }
.btn:active { transform: translateY(2px) scale(.98); box-shadow: 0 1px 0 var(--ink); }
.btn-primary { background: var(--yellow); } .btn-xl { min-height: 60px; font-size: 1.25rem; padding: 14px 34px; } .btn-sm { min-height: 44px; padding: 8px 18px; font-size: .95rem; box-shadow: 0 2px 0 var(--ink); }

main { max-width: 980px; margin: 0 auto; padding: 8px 18px calc(48px + var(--safe-b)); display: grid; gap: 26px; }
.hero { text-align: center; padding-top: 8px; display: grid; gap: 10px; justify-items: center; }
.hero h1 { font-size: clamp(2.4rem, 8vw, 4rem); }
.lead { color: var(--muted); font-size: 1.15rem; margin: 0; }
.kids { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; list-style: none; margin: 6px 0 0; padding: 0; }
.kids li { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px 6px 8px; border-radius: 999px; background: rgba(255,255,255,.85); border: 1px solid var(--line); font-weight: 800; font-size: .95rem; }
.kids .av { font-size: 26px; line-height: 1; }
.kids .st { color: var(--muted); font-variant-numeric: tabular-nums; }

.install { padding: 20px; border-radius: 28px; background: #fff; border: 3px solid var(--ink); box-shadow: 0 5px 0 var(--ink); display: grid; gap: 14px; justify-items: start; }
.inst-head { display: flex; gap: 14px; align-items: center; }
.inst-ico { font-size: 44px; line-height: 1; }
.install h2 { font-size: 1.6rem; } .inst-sub { margin: 2px 0 0; color: var(--muted); }
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; width: 100%; }
.steps li { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 18px; background: #f6f7ff; border: 2px solid var(--line); font-weight: 700; }
.steps b { flex: none; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: var(--yellow); font-family: var(--f-d); font-size: 1.2rem; }
.steps span { flex: 1; } .share-ico { flex: none; color: var(--blue); }
.note { margin: 0; padding: 10px 14px; border-radius: 14px; background: #fff2d1; color: #7a4d00; font-weight: 700; }
.installed { text-align: center; margin: 0; padding: 10px 14px; border-radius: 16px; background: #e3f6ec; color: #11613a; font-weight: 800; }

.group { display: grid; gap: 12px; }
.group h2 { font-size: 1.5rem; }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 210px), 1fr)); gap: 14px; }
.tile { display: grid; gap: 4px; align-content: start; justify-items: start; padding: 18px 16px 16px; min-height: 150px; border-radius: 26px; border: 3px solid var(--ink); box-shadow: 0 5px 0 var(--ink); text-decoration: none; transition: transform 150ms var(--ease), box-shadow 150ms var(--ease); }
.tile:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--ink); }
.tile .e { font-size: 46px; line-height: 1.1; }
.tile b { font-family: var(--f-d); font-weight: 700; font-size: 1.35rem; line-height: 1.15; }
.tile small { color: var(--ink); opacity: .78; font-weight: 700; font-size: .95rem; line-height: 1.3; }
.t-red { background: #ffd9de; } .t-orange { background: #ffe1cc; } .t-yellow { background: #fff0b8; } .t-green { background: #d6f3e6; }
.t-blue { background: #d9e2ff; } .t-purple { background: #ead9ff; } .t-color { background: linear-gradient(135deg, #ffd9de, #fff0b8 40%, #d6f3e6 70%, #d9e2ff); }

.foot { max-width: 980px; margin: 0 auto; padding: 18px 18px calc(28px + var(--safe-b)); display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; color: var(--muted); font-weight: 700; border-top: 1px solid var(--line); }
.foot a { display: inline-block; min-height: 44px; line-height: 44px; }

.share-arrow { position: fixed; z-index: 50; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 16px; border-radius: 20px; background: var(--ink); color: #fff; font-weight: 800; box-shadow: var(--shadow-3); }
.share-arrow .arrow-sym { font-size: 34px; line-height: 1; animation: bob 1.1s ease-in-out infinite; }
.share-arrow .btn { background: #fff; color: var(--ink); }
.share-arrow.ipad { top: calc(10px + var(--safe-t)); right: 10px; } .share-arrow.ipad .arrow-sym { order: -1; align-self: flex-end; margin-right: 6px; }
.share-arrow.iphone { bottom: calc(16px + var(--safe-b)); left: 50%; transform: translateX(-50%); } .share-arrow.iphone .arrow-sym { order: 3; transform: rotate(180deg); animation: bob-down 1.1s ease-in-out infinite; }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes bob-down { 0%, 100% { transform: rotate(180deg) translateY(0); } 50% { transform: rotate(180deg) translateY(-8px); } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; } }
