.games-view { min-height: calc(100dvh - 86px); background: #fffaf0; }
.flash-cover { width:100%; height:100%; object-fit:cover; }
.original-game-title { display:block; font-size:12px; line-height:1.5; color:var(--muted); overflow-wrap:anywhere; margin-top:4px; }
@media(max-width:760px) { .catalog-card .catalog-card-body p { font-size:12px; line-height:1.8; }.catalog-card .catalog-card-foot > .flash-control-label { font-size:10px; line-height:1.6; } }
.flash-badge { position:absolute; bottom:10px; left:10px; border-radius:6px; padding:4px 8px; background:#174a73; color:white; font:800 10px sans-serif; letter-spacing:1px; }
.flash-control-label { font-size:10px; color:var(--green); }
.catalog-card .catalog-card-foot > .flash-control-label { display:inline; }
.flash-frame { width:100%; height:740px; border:0; border-radius:16px; display:block; background:#142b40; }
.flash-shell.is-expanded { position:fixed; inset:0; z-index:10000; background:#142b40; height:100dvh; }
.flash-shell.is-expanded .flash-frame { width:100%; height:100%!important; border-radius:0; }
.flash-shell.is-expanded .flash-note,.flash-shell.is-expanded .flash-credit { display:none; }
.flash-note,.flash-credit { font-size:12px; line-height:1.9; color:var(--muted); }
.is-flash .game-stage { padding:16px; }
.is-flash .game-player-head h2 { direction:ltr; text-align:right; }
@media(max-width:760px) { .flash-frame { height:510px; }.is-flash .game-stage { padding:8px; }.flash-note,.flash-credit { font-size:10px; }.is-flash .game-player-head h2 { font-size:32px; } }
.games-hero { max-width: 1440px; min-height: 620px; margin: auto; padding: clamp(54px,7vw,96px) clamp(22px,6vw,90px); display: grid; grid-template-columns: 1.05fr .95fr; align-items: center; gap: clamp(40px,7vw,100px); }
.games-hero-copy h1 { font-size: clamp(48px,6vw,84px); }
.games-hero-copy > p:not(.eyebrow) { max-width: 680px; margin: 24px 0 34px; color: var(--muted); font-size: clamp(15px,1.5vw,19px); line-height: 2; }
.games-summary { max-width: 670px; display: grid; grid-template-columns: repeat(3,1fr); border-block: 1px solid #b9d0dc; }
.games-summary div { min-width: 0; padding: 22px 16px; display: grid; gap: 4px; border-inline-start: 1px solid #b9d0dc; }
.games-summary div:first-child { border-inline-start: 0; }
.games-summary strong { font: 800 34px "Baloo Bhaijaan 2",sans-serif; font-variant-numeric: tabular-nums; }
.games-summary span { color: var(--muted); font-size: 11px; }
.games-hero-board { position: relative; min-height: 430px; overflow: hidden; border: 3px solid var(--ink); border-radius: 34px; background: var(--blue); box-shadow: 12px 12px 0 var(--ink); direction: ltr; }
.games-hero-board::before { content: ""; position: absolute; width: 240px; height: 240px; inset: 36px auto auto 50%; border: 28px solid var(--yellow); border-radius: 50%; transform: translateX(-50%); opacity: .88; }
.board-robot { position: absolute; width: 180px; height: 150px; inset: 118px auto auto 50%; border: 4px solid var(--ink); border-radius: 42px; background: var(--white); transform: translateX(-50%); }
.board-robot i, .board-robot b { position: absolute; width: 24px; height: 24px; top: 48px; border-radius: 50%; background: var(--blue); }
.board-robot i { left: 42px; } .board-robot b { right: 42px; }
.board-robot span { position: absolute; width: 64px; height: 28px; left: 54px; bottom: 30px; border-bottom: 7px solid var(--ink); border-radius: 50%; }
.games-hero-board p { position: absolute; inset: auto auto 26px 28px; margin: 0; color: var(--white); font: 800 19px/1.1 "Baloo Bhaijaan 2",sans-serif; }
.games-hero-board p strong { color: var(--yellow); font-size: 32px; }
.board-chip { position: absolute; z-index: var(--z-base); width: 70px; height: 70px; display: grid; place-items: center; border: 3px solid var(--ink); border-radius: 18px; background: var(--white); color: var(--ink); font: 800 28px sans-serif; box-shadow: 5px 5px 0 var(--ink); }
.chip-code { inset: 28px 28px auto auto; transform: rotate(6deg); }
.chip-loop { inset: auto 42px 32px auto; transform: rotate(-7deg); }
.chip-bug { inset: 80px auto auto 24px; transform: rotate(-8deg); }

.games-library { padding: 86px clamp(22px,6vw,90px) 120px; background: var(--white); }
.games-section-head { max-width: 1260px; margin: 0 auto 42px; display: flex; align-items: end; justify-content: space-between; gap: 30px; }
.games-section-head h2 { font-size: clamp(36px,4vw,58px); }
.games-section-head > p { max-width: 480px; margin: 0; color: var(--muted); line-height: 1.9; }
.games-grid { max-width: 1260px; margin: auto; display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 24px; }
.game-card { min-width: 0; min-height: 410px; padding: 22px; display: flex; flex-direction: column; border: 2px solid #cbdde4; border-radius: var(--radius); background: #fffdf8; box-shadow: var(--shadow); }
.game-card.is-complete { border-color: var(--green); }
.game-card-top { display: flex; align-items: center; justify-content: space-between; }
.game-card-number { color: var(--muted); font: 800 15px "Noto Kufi Arabic",sans-serif; font-variant-numeric: tabular-nums; }
.game-card-stars { color: #9a6d00; direction: ltr; font-size: 18px; }
.game-card-icon { width: 78px; height: 78px; margin: 22px 0 18px; display: grid; place-items: center; border: 3px solid var(--ink); border-radius: 22px; background: var(--yellow); font: 800 35px sans-serif; box-shadow: 5px 5px 0 var(--ink); }
.game-card-skill { color: var(--green); font-size: 11px; font-weight: 800; }
.game-card h3 { margin-top: 7px; font-size: 30px; }
.game-card p { margin: 10px 0 22px; color: var(--muted); font-size: 13px; line-height: 1.85; }
.game-card-button { width: 100%; margin-top: auto; background: var(--ink); color: var(--white); box-shadow: 0 5px 0 #0d2f4b; }

.game-player { max-width: 1260px; min-height: calc(100dvh - 86px); margin: auto; padding: 54px clamp(18px,4vw,54px) 100px; }
.game-back { min-height: 44px; padding: 8px 0; border: 0; background: transparent; color: var(--ink); font-weight: 800; text-decoration: underline; text-underline-offset: 5px; }
.game-player-head { margin: 26px 0 22px; display: flex; align-items: end; justify-content: space-between; gap: 24px; }
.game-level { color: var(--green); font-size: 12px; font-weight: 800; }
.game-player-head h2 { margin-top: 6px; font-size: clamp(42px,5vw,66px); }
.game-player-head p { margin: 5px 0 0; color: var(--muted); }
.game-score { min-width: 170px; padding: 15px 18px; display: grid; gap: 4px; border: 2px solid var(--ink); border-radius: 18px; background: var(--white); text-align: center; box-shadow: 5px 5px 0 var(--ink); }
.game-score span { color: var(--muted); font-size: 11px; }
.game-score strong { color: #946900; direction: ltr; font-size: 24px; }
.game-objective { padding: 20px 24px; display: flex; align-items: center; gap: 16px; border: 1px solid #c4d7dd; border-radius: 20px 20px 0 0; background: var(--paper); }
.game-objective > span { width: 45px; height: 45px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; background: var(--yellow); font-size: 25px; }
.game-objective strong { display: block; }
.game-objective p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.game-stage { min-height: 440px; padding: clamp(22px,4vw,48px); border: 1px solid #c4d7dd; border-top: 0; border-radius: 0 0 var(--radius) var(--radius); background: var(--white); box-shadow: var(--shadow); }
.game-stage button:focus-visible, .game-back:focus-visible { outline: 4px solid var(--cyan); outline-offset: 3px; }
.game-feedback { min-height: 64px; margin: 20px 0 0; padding: 16px 20px; border-radius: 16px; font-weight: 800; line-height: 1.7; }
.game-feedback:empty { display: none; }
.game-feedback.success { border: 2px solid var(--green); background: #def6e9; color: #145b48; }
.game-feedback.error { border: 2px solid var(--coral); background: #fff0ec; color: #8e2d28; }
.game-feedback.hint { border: 2px solid #9e7b00; background: #fff5bd; color: #574500; }
.game-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.stage-note { color: var(--muted); text-align: center; }
.stepper { display: flex; align-items: center; gap: 10px; direction: ltr; }
.stepper button, .command-pad button { width: 48px; height: 48px; border: 2px solid var(--ink); border-radius: 13px; background: var(--white); color: var(--ink); font-size: 24px; font-weight: 800; box-shadow: 0 3px 0 var(--ink); }
.stepper strong, .stepper b { min-width: 38px; text-align: center; font-variant-numeric: tabular-nums; }

.robot-game-layout, .loop-lab, .rocket-lab, .logic-lab, .debug-lab, .network-lab, .sensor-lab, .city-lab { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: clamp(28px,5vw,70px); }
.robot-route-grid { grid-template-columns: repeat(4,1fr); max-width: 430px; gap: 7px; }
.robot-route-grid span { border-radius: 13px; font-size: 30px; }
.robot-route-grid .obstacle { background: #cbd2d8; color: #697684; }
.robot-route-grid .robot { background: #d8f6f1; color: var(--blue); }
.command-console { padding: 26px; border: 2px solid var(--ink); border-radius: 24px; background: #f4f8fb; }
.command-console h3 { font-size: 30px; }
.command-list { min-height: 72px; margin: 16px 0; padding: 12px; display: flex; flex-wrap: wrap; align-items: center; gap: 7px; border: 2px dashed #a5bac5; border-radius: 14px; background: var(--white); direction: ltr; }
.command-list b { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 10px; background: var(--yellow); font-size: 25px; }
.command-list span { width: 100%; color: var(--muted); text-align: center; direction: rtl; }
.command-pad { margin-bottom: 20px; display: grid; grid-template-columns: repeat(4,48px); gap: 8px; direction: ltr; }

.loop-code { padding: 24px; border: 3px solid var(--ink); border-radius: 22px; background: var(--blue); color: var(--white); box-shadow: 7px 7px 0 var(--ink); }
.loop-code > span, .loop-inner > span { display: block; margin-bottom: 10px; font-weight: 800; }
.loop-inner { margin: 18px 0; padding: 18px; border-radius: 15px; background: #244f88; }
.garden-preview { --garden-cols: 1; min-height: 310px; padding: 24px; display: grid; grid-template-columns: repeat(var(--garden-cols),minmax(40px,1fr)); align-content: center; gap: 12px; border: 3px solid var(--ink); border-radius: 25px; background: #dff5d7; }
.garden-preview span { display: grid; place-items: center; aspect-ratio: 1; color: var(--coral); font-size: 38px; }

.recycle-lab { display: grid; gap: 32px; }
.recycle-item { max-width: 350px; min-height: 190px; margin: auto; padding: 24px; display: grid; place-items: center; border: 3px solid var(--ink); border-radius: 28px; background: var(--paper); box-shadow: 7px 7px 0 var(--ink); }
.recycle-item > span { font-size: 60px; }
.recycle-item strong { font-size: 22px; }
.recycle-item small { color: var(--muted); }
.recycle-bins { display: grid; grid-template-columns: repeat(3,1fr); gap: 15px; }
.recycle-bins button { min-height: 130px; padding: 16px; display: grid; place-items: center; border: 2px solid var(--ink); border-radius: 20px; background: var(--white); color: var(--ink); box-shadow: 0 5px 0 var(--ink); }
.recycle-bins button span { font-size: 36px; }

.rocket-visual { min-height: 400px; display: grid; place-items: center; border: 3px solid var(--ink); border-radius: 30px; background: #dceaff; }
.rocket-visual > span { color: var(--coral); font-size: 160px; transform: rotate(0deg); }
.rocket-visual i { width: 70px; height: 70px; margin-top: -140px; border-radius: 50%; background: var(--yellow); }
.rocket-visual b { padding: 8px 16px; border-radius: 999px; background: var(--ink); color: var(--white); }
.variable-panel { display: grid; gap: 14px; }
.variable-row { padding: 14px; display: grid; grid-template-columns: 36px 1fr auto; align-items: center; gap: 10px; border: 1px solid var(--line); border-radius: 16px; }
.variable-row > span { font-size: 24px; }
.variable-total { padding: 18px; display: flex; justify-content: space-between; border-radius: 16px; background: var(--paper); }

.visitor-tests { display: grid; gap: 12px; }
.visitor-tests > div { padding: 15px; display: grid; gap: 4px; border: 1px solid var(--line); border-radius: 15px; background: #f7fafc; }
.visitor-tests b { color: var(--green); font-size: 12px; }
.visitor-tests em { color: var(--muted); font-size: 11px; }
.formula-list { min-width: 0; padding: 22px; border: 2px solid var(--ink); border-radius: 22px; }
.formula-list legend { padding: 0 10px; font-weight: 800; }
.formula-list label { min-height: 58px; margin: 10px 0; padding: 10px; display: flex; align-items: center; gap: 12px; border: 1px solid var(--line); border-radius: 13px; cursor: pointer; }
.formula-list input { width: 22px; height: 22px; flex: 0 0 auto; }
.formula-list .button { width: 100%; margin-top: 12px; }

.code-window { overflow: hidden; border: 3px solid var(--ink); border-radius: 22px; background: #122a42; color: var(--white); box-shadow: 7px 7px 0 var(--ink); direction: ltr; }
.code-window-bar { min-height: 45px; padding: 10px 14px; display: flex; align-items: center; gap: 6px; background: #e4ecf1; color: var(--ink); }
.code-window-bar span { width: 12px; height: 12px; border-radius: 50%; background: var(--coral); }
.code-window-bar span:nth-child(2) { background: var(--yellow); }.code-window-bar span:nth-child(3) { background: var(--green); }
.code-window-bar b { margin-left: auto; font-size: 11px; }
.code-window ol { margin: 0; padding: 15px 48px 15px 15px; }
.code-window li { padding-left: 5px; }
.code-window li::marker { color: #8eb1c9; font-variant-numeric: tabular-nums; }
.code-window button { width: 100%; min-height: 42px; padding: 6px 9px; display: flex; align-items: center; justify-content: space-between; border: 0; border-radius: 8px; background: transparent; color: var(--white); text-align: left; }
.code-window button.selected { background: #70372f; }
.code-window code { white-space: pre-wrap; }.code-window button span { color: #a9c7d9; font-size: 10px; }
.debug-notes { padding: 24px; border-radius: 22px; background: var(--paper); }
.debug-notes p { color: var(--muted); line-height: 1.9; }.debug-notes > strong { display: block; margin: 18px 0; color: var(--coral); }

.order-lab { max-width: 760px; margin: auto; }
.dependency-note { margin-bottom: 20px; padding: 18px; border-right: 6px solid var(--yellow); background: #f7fafc; }
.dependency-note p { margin: 5px 0 0; color: var(--muted); }
.sortable-steps { margin: 0 0 22px; padding: 0; display: grid; gap: 10px; list-style: none; }
.sortable-steps li { min-height: 70px; padding: 11px 14px; display: grid; grid-template-columns: 44px 1fr auto; align-items: center; gap: 12px; border: 2px solid var(--ink); border-radius: 15px; background: var(--white); }
.sortable-steps li > span { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; background: var(--yellow); font-weight: 800; }
.sortable-steps li div { display: flex; gap: 7px; }
.sortable-steps button { width: 44px; height: 44px; border: 1px solid var(--ink); border-radius: 10px; background: #edf4f8; color: var(--ink); }

.network-map { position: relative; min-height: 410px; border: 3px solid var(--ink); border-radius: 28px; background: #e7f5f2; direction: ltr; }
.network-node { position: absolute; width: 58px; height: 58px; z-index: 1; border: 3px solid var(--ink); border-radius: 50%; background: var(--white); color: var(--ink); font-weight: 800; box-shadow: 3px 3px 0 var(--ink); }
.network-node.selected { background: var(--yellow); }
.node-A { left: 7%; top: 43%; }.node-B { left: 31%; top: 12%; }.node-C { left: 31%; bottom: 12%; }.node-D { right: 31%; top: 25%; }.node-E { right: 31%; bottom: 9%; }.node-F { right: 7%; top: 43%; }
.network-map::before, .network-map::after { content: ""; position: absolute; height: 3px; width: 75%; left: 12%; background: #7896a2; transform-origin: left center; }
.network-map::before { top: 45%; transform: rotate(-15deg); }.network-map::after { bottom: 28%; transform: rotate(12deg); }
.edge { position: absolute; padding: 2px 7px; border-radius: 999px; background: var(--white); font-weight: 800; font-variant-numeric: tabular-nums; }
.e-ab { left: 20%; top: 25%; }.e-ac { left: 20%; bottom: 25%; }.e-bd { left: 47%; top: 17%; }.e-cd { left: 47%; top: 54%; }.e-ce { left: 47%; bottom: 10%; }.e-df { right: 20%; top: 30%; }.e-ef { right: 20%; bottom: 23%; }
.network-console { padding: 24px; border: 2px solid var(--ink); border-radius: 22px; }
.network-console h3 { font-size: 30px; }
#networkPath { min-height: 70px; margin: 18px 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; direction: ltr; }
#networkPath b { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; background: var(--yellow); }

.coordinate-grid { display: grid; grid-template-columns: repeat(4,minmax(58px,1fr)); gap: 8px; direction: ltr; }
.coordinate-grid button { aspect-ratio: 1; min-width: 0; min-height: 58px; padding: 5px; display: grid; place-items: center; border: 2px solid var(--ink); border-radius: 13px; background: #f3f9fb; color: var(--ink); }
.coordinate-grid button.selected { background: var(--yellow); }
.coordinate-grid button span { font-size: 10px; }.coordinate-grid button b { font-size: 22px; }
.sensor-brief { padding: 24px; border: 2px solid var(--ink); border-radius: 22px; background: var(--paper); }
.sensor-brief ul { padding-right: 22px; line-height: 2.2; }.sensor-brief p { color: var(--muted); }

.city-skyline { position: relative; min-height: 460px; overflow: hidden; border: 3px solid var(--ink); border-radius: 30px; background: #d9eff5; }
.city-skyline span, .city-skyline b, .city-skyline i { position: absolute; bottom: 0; border: 3px solid var(--ink); border-bottom: 0; background: var(--blue); }
.city-skyline span { width: 32%; height: 45%; left: 8%; }.city-skyline b { width: 26%; height: 68%; left: 38%; }.city-skyline i { width: 31%; height: 36%; right: 7%; background: var(--cyan); }
.city-skyline em { position: absolute; right: 24px; top: 20px; color: #bd8200; font-style: normal; font-size: 72px; }
.city-dashboard { display: grid; gap: 16px; }
.city-meters { padding: 16px; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; border-radius: 16px; background: var(--ink); color: var(--white); }
.city-meters span { display: grid; gap: 3px; }.city-meters strong { color: var(--yellow); font-variant-numeric: tabular-nums; }
.city-dashboard fieldset { min-width: 0; padding: 14px; border: 1px solid var(--line); border-radius: 15px; }
.city-dashboard legend { padding: 0 8px; font-weight: 800; }
.city-dashboard fieldset > div { display: grid; grid-template-columns: repeat(3,1fr); gap: 7px; }
.city-dashboard label { min-width: 0; cursor: pointer; }.city-dashboard label input { position: absolute; opacity: 0; }
.city-dashboard label span { min-height: 78px; padding: 9px; display: grid; align-content: center; gap: 3px; border: 2px solid var(--line); border-radius: 12px; background: var(--white); text-align: center; }
.city-dashboard label input:checked + span { border-color: var(--ink); background: var(--yellow); }
.city-dashboard label input:focus-visible + span { outline: 4px solid var(--cyan); outline-offset: 3px; }
.city-dashboard label strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }.city-dashboard label small { color: var(--muted); font-size: 8px; }

@media (max-width: 1000px) {
  .games-hero { grid-template-columns: 1fr; }.games-hero-board { min-height: 390px; }
  .games-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .robot-game-layout, .loop-lab, .rocket-lab, .logic-lab, .debug-lab, .network-lab, .sensor-lab, .city-lab { grid-template-columns: 1fr; }
  .mini-grid, .coordinate-grid { width: min(100%,520px); margin-inline: auto; }
}

@media (max-width: 680px) {
  .games-view { min-height: calc(100dvh - 68px); }
  .games-hero { min-height: 0; padding-top: 52px; }.games-hero-board { min-height: 330px; }
  .games-summary { grid-template-columns: 1fr; border-bottom: 0; }.games-summary div { padding: 14px 4px; border-inline-start: 0; border-bottom: 1px solid #b9d0dc; }
  .games-library { padding-block: 62px 80px; }.games-section-head { display: grid; }.games-grid { grid-template-columns: 1fr; }
  .game-card { min-height: 370px; }.game-player { padding-top: 32px; }.game-player-head { align-items: stretch; flex-direction: column; }.game-score { width: 100%; }
  .game-objective { align-items: flex-start; }.game-stage { min-height: 360px; padding: 18px 12px; }
  .command-console, .loop-code, .formula-list, .debug-notes, .network-console, .sensor-brief { padding: 17px; }
  .command-pad { grid-template-columns: repeat(4,44px); }.command-pad button { width: 44px; height: 44px; }
  .recycle-bins { grid-template-columns: 1fr; }.recycle-bins button { min-height: 88px; grid-template-columns: auto 1fr; gap: 15px; }
  .variable-row { grid-template-columns: 30px minmax(70px,1fr); }.variable-row .stepper { grid-column: 1 / -1; justify-content: center; }
  .code-window ol { padding-right: 38px; }.code-window code { font-size: 10px; }.code-window button span { display: none; }
  .sortable-steps li { grid-template-columns: 40px minmax(0,1fr); }.sortable-steps li div { grid-column: 1 / -1; justify-content: end; }
  .network-map { min-height: 340px; }.coordinate-grid { gap: 5px; }.coordinate-grid button { min-height: 54px; }
  .city-skyline { min-height: 300px; }.city-dashboard fieldset > div { grid-template-columns: 1fr; }.city-dashboard label span { min-height: 60px; }
}

@media (prefers-reduced-motion: reduce) {
  .game-card .button { transition: none; }
}
/* Shamsita arcade: playful illustrated covers, compact touch-first browsing. */
.games-view { background: #fffaf1; }
.games-hero { min-height: 470px; padding-block: 56px 48px; gap: 48px; }
.games-hero-copy h1 { font-size: clamp(45px,5.7vw,78px); }
.games-hero-copy > p:not(.eyebrow) { margin: 18px 0; font-size: 16px; }
.games-hero-tags { display: flex; flex-wrap: wrap; gap: 8px 18px; font-size: 11px; color: #32644d; margin-bottom: 26px; }
.arcade-hero-art { min-height: 375px; position: relative; display: grid; place-items: center; background: radial-gradient(ellipse, #f9df8c 0 53%, transparent 54%); }
.hero-console { width: 244px; padding: 20px 20px 14px; background: #a8dcd4; border: 3px solid #174a73; border-radius: 28px 28px 64px 28px; box-shadow: 9px 12px 0 #174a73; transform: rotate(-9deg); }
.console-screen { background: #174a73; border: 8px solid #4e9695; border-radius: 13px; text-align: center; color: #fff3b7; padding: 14px 4px; font-weight: 800; direction: ltr; }
.console-screen > div { font-size: 72px; line-height: 1.3; }.console-screen small { font: 9px monospace; letter-spacing: 2px; }.console-controls { display: flex; justify-content: space-between; align-items: center; direction: ltr; padding-top: 10px; }.console-controls b { font-size: 44px; }.console-controls span { color: #db4d45; letter-spacing: 5px; font-size: 28px; }
.hero-sticker { position: absolute; z-index: 1; display: grid; place-items: center; }.sticker-star { top: 0; right: 12%; font-size: 80px; color: #efae00; transform: rotate(15deg); }.sticker-puzzle { right: 0; bottom: 38px; width: 90px; height: 90px; background: #edcafa; border: 2px solid var(--ink); border-radius: 24px; font-size: 47px; transform: rotate(12deg); box-shadow: 4px 4px 0 var(--ink); }.sticker-palette { left: 0; top: 35px; width: 90px; height: 90px; border-radius: 22px; border: 2px solid var(--ink); background: #ffd68c; font-size: 48px; transform: rotate(-12deg); box-shadow: 4px 4px 0 var(--ink); }.sticker-spark { left: 8%; bottom: 16px; font-size: 72px; color: #db4d45; }.hero-art-caption { position: absolute; bottom: -8px; padding: 6px 18px; border: 2px solid var(--ink); background: #fff; border-radius: 9px; transform: rotate(3deg); font-size: 12px; font-weight: 800; }
.games-library { padding: 0 clamp(16px,5vw,76px) 64px; background: #fffaf1; scroll-margin-top: 100px; }
.games-summary { max-width: 1260px; margin: 0 auto 44px; border: 1px solid #d8dfd6; background: #fff; border-radius: 20px; grid-template-columns: repeat(3,1fr); }
.games-summary div { padding: 15px 24px; display: flex; align-items: center; gap: 14px; border-bottom: 0; }.games-summary strong { font-size: 32px; }.games-summary span { font-size: 12px; }
.games-section-head { margin-bottom: 26px; align-items: center; }.games-section-head h2 { font-size: clamp(30px,3.6vw,46px); }.surprise-button { background: var(--yellow); white-space: nowrap; }
.catalog-toolbar { display: flex; align-items: stretch; gap: 14px; max-width: 1260px; margin: 0 auto 24px; }.catalog-toolbar > label { display: flex; align-items: center; gap: 10px; font-size: 11px; font-weight: 700; }.catalog-toolbar select { max-width: 160px; min-height: 48px; border: 1px solid #b6c9d1; border-radius: 12px; padding: 8px 12px; background: #fff; color: var(--ink); font: inherit; }.catalog-toolbar .games-search { flex: 1; min-width: 140px; border: 1px solid #b6c9d1; border-radius: 14px; padding-inline: 16px; background: #fff; }.games-search span { font-size: 29px; }.games-search input { min-height: 50px; width: 100%; min-width: 0; border: 0; background: transparent; color: var(--ink); font-size: 13px; }.games-search:focus-within { outline: 3px solid var(--cyan); }.games-search input:focus { outline: none; }
.games-categories { max-width: 1260px; margin: auto; display: flex; flex-wrap: wrap; gap: 10px; }.category-chip { display: flex; align-items: center; gap: 7px; padding: 10px 15px; min-height: 46px; border: 1px solid #c7d3d5; border-radius: 99px; background: #fff; color: var(--ink); font-size: 12px; font-weight: 700; }.category-chip span { font-size: 19px; }.category-chip small { font-size: 10px; opacity: .85; }.category-chip.active { color: #fff; border-color: var(--ink); background: var(--ink); }.games-result-count { max-width: 1260px; margin: 26px auto 16px; font-size: 12px; color: var(--muted); }
.games-grid { grid-template-columns: repeat(4,minmax(0,1fr)); gap: 22px; }.catalog-card { min-height: 0; padding: 0; border: 1px solid #d2dcd8; border-radius: 20px; overflow: hidden; background: #fff; box-shadow: 0 5px 0 #e8e9df; transition: transform 160ms ease, box-shadow 160ms ease; }.catalog-card:hover { transform: translateY(-4px); box-shadow: 0 9px 0 #e8e9df; }.game-cover { height: 157px; position: relative; display: grid; place-items: center; overflow: hidden; background: #c7e7e2; }.category-memory .game-cover { background: #e2d5f5; }.category-math .game-cover { background: #fbe0a0; }.category-words .game-cover { background: #f8d4c2; }.category-arcade .game-cover { background: #c4def6; }.category-creative .game-cover { background: #f5d1e2; }.category-coding .game-cover { background: #cbe6cc; }.cover-orbit { position: absolute; width: 120px; height: 120px; border: 1px solid #ffffff90; border-radius: 50%; box-shadow: 0 0 0 16px #ffffff20, 0 0 0 34px #ffffff20; transform: rotate(-18deg); }.cover-icon { z-index: 1; font-size: 70px; line-height: 1; filter: drop-shadow(0 6px 0 #174a731a); transform: rotate(-8deg); }.game-age { position: absolute; left: 12px; top: 12px; font-size: 11px; font-weight: 800; background: #fff; border-radius: 9px; padding: 3px 9px; direction: ltr; }.favorite-button { position: absolute; top: 8px; right: 8px; z-index: 2; width: 44px; height: 44px; border: 0; border-radius: 50%; background: #ffffffdd; color: #ab354b; font-size: 26px; }.catalog-card-body { padding: 17px; display: flex; flex-direction: column; flex: 1; }.catalog-card h3 { margin-top: 8px; font-size: 25px; }.catalog-card p { font-size: 11px; margin: 10px 0 15px; line-height: 1.9; }.catalog-card-foot { display: flex; align-items: center; justify-content: space-between; margin-top: auto; gap: 8px; padding-bottom: 12px; }.catalog-card-foot > span:last-child { font-size: 9px; color: var(--muted); }.catalog-card .game-card-button { min-height: 44px; padding: 8px 14px; border-radius: 12px; font-size: 12px; box-shadow: none; }.catalog-card .game-card-stars { font-size: 16px; }
.games-empty { text-align: center; padding: 48px 16px; }.games-empty > span { font-size: 52px; }.games-empty h3 { font-size: 32px; margin-top: 16px; }.games-empty p { font-size: 13px; }.games-parent-note { max-width: 1260px; margin: 40px auto 0; padding: 18px; border-top: 1px solid #d8dfd6; text-align: center; font-size: 11px; color: var(--muted); line-height: 2; }
.player-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; }.player-toolbar .button { padding: 8px 15px; min-height: 44px; font-size: 12px; }.game-player { scroll-margin-top: 80px; }.game-player-head h2 { font-size: clamp(32px,4vw,54px); }.game-stage { min-height: 300px; }.games-view button:focus-visible,.games-view select:focus-visible { outline: 3px solid #00786d; outline-offset: 3px; }.games-view button:disabled { cursor: default; }
.arcade-shell { max-width: 540px; margin: auto; text-align: center; }.arcade-status { min-height: 30px; font-size: 14px; font-weight: 700; margin: 0 0 22px; }.arcade-grid { display: grid; gap: 8px; direction: ltr; margin: 0 auto 22px; }.cols-2 { grid-template-columns: repeat(2,minmax(0,1fr)); }.cols-3 { grid-template-columns: repeat(3,minmax(0,1fr)); }.cols-4 { grid-template-columns: repeat(4,minmax(0,1fr)); }.cols-7 { grid-template-columns: repeat(7,minmax(0,1fr)); }.cols-10 { grid-template-columns: repeat(10,minmax(0,1fr)); }.cols-11 { grid-template-columns: repeat(11,minmax(0,1fr)); }.cols-12 { grid-template-columns: repeat(12,minmax(0,1fr)); }
.arcade-grid button { min-width: 0; min-height: 44px; aspect-ratio: 1; border: 2px solid #cadbdc; border-radius: 12px; background: #eaf4f0; color: var(--ink); font-size: clamp(24px,4vw,40px); font-weight: 800; touch-action: manipulation; }.arcade-grid button.revealed { background: #fff0b3; }.arcade-grid button.revealed:disabled { background: #d5eed7; border-color: #489168; }.arcade-grid button.lit { color: #785700; background: #ffe284; }.arcade-grid button:disabled:not(.revealed) { opacity: .65; }.arcade-pad { display: flex; justify-content: center; gap: 10px; direction: ltr; margin: 12px 0 22px; }.arcade-pad button { width: 54px; height: 50px; border: 2px solid var(--ink); border-radius: 12px; background: #fff0b3; color: var(--ink); font-size: 26px; touch-action: manipulation; }.quiz-prompt { font-size: clamp(30px,6vw,54px); padding: 24px 10px; margin-bottom: 22px; border-radius: 20px; background: #fff4cf; overflow-wrap: anywhere; }.quiz-options { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }.quiz-options button,.letter-tray button { min-height: 64px; border: 2px solid #bdd2d6; border-radius: 14px; background: #ecf6f3; color: var(--ink); font-size: 24px; }.quiz-options button:disabled { opacity: .4; }.letter-tray { display: flex; justify-content: center; gap: 12px; margin: 20px 0; }.letter-tray button { width: 66px; }.letter-tray button:disabled { opacity: .3; }.word-answer { min-height: 70px; padding: 12px; font-size: 32px; border-bottom: 2px dashed var(--ink); }.sequence-key.tone-0,.bubble.tone-0 { background: #ffc7be; }.sequence-key.tone-1,.bubble.tone-1 { background: #bdddff; }.sequence-key.tone-2,.bubble.tone-2 { background: #fbe187; }.sequence-key.tone-3,.bubble.tone-3 { background: #bbe6d1; }.sequence-key.flash { outline: 6px solid var(--ink); outline-offset: -8px; background: #fff; }.arcade-grid .bubble { border-radius: 50%; }
.maze-board { gap: 2px; padding: 4px; border-radius: 10px; background: #c6ded4; }.maze-cell { aspect-ratio: 1; min-width: 0; display: grid; place-items: center; background: #fff7dc; font-size: clamp(14px,3vw,28px); }.maze-cell.wall { background: #3b8174; border-radius: 4px; }.snake-board { gap: 1px; background: #eef4e8; padding: 5px; border: 2px solid #7c9a8c; border-radius: 12px; }.snake-board span { aspect-ratio: 1; display: grid; place-items: center; font-size: 20px; }.snake-segment { background: #379773; border-radius: 6px; color: #fff; }.sudoku-board { gap: 0; border: 2px solid var(--ink); }.sudoku-cell { display: grid; place-items: center; aspect-ratio: 1; border: 1px solid #aec5ce; background: #fff; font-size: 28px; }.sudoku-cell:nth-child(4n+2) { border-right: 3px solid var(--ink); }.sudoku-cell:nth-child(n+5):nth-child(-n+8) { border-bottom: 3px solid var(--ink); }.sudoku-cell.fixed { background: #e5ecee; }.sudoku-cell select { width: 100%; height: 100%; border: 0; text-align: center; font: inherit; color: var(--ink); background: #fff4cf; }.connect-controls { display: grid; grid-template-columns: repeat(7,minmax(0,1fr)); direction: ltr; gap: 3px; margin-bottom: 8px; }.connect-controls button { min-width: 0; min-height: 44px; font-size: 22px; background: #fff4cf; color: var(--ink); border: 1px solid #b1c5cd; border-radius: 7px; }.connect-board { padding: 8px; gap: 5px; background: var(--ink); border-radius: 12px; }.connect-board span { aspect-ratio: 1; display: grid; place-items: center; border-radius: 50%; background: #fff; color: #dae2e6; font-size: clamp(20px,4vw,35px); }.connect-board .player-1 { color: #b63833; background: #ffd9cb; }.connect-board .player-2 { color: #705000; background: #ffe08a; }
.catch-field { height: 340px; position: relative; overflow: hidden; touch-action: none; border: 2px solid #aacad8; border-radius: 20px; background: #e2f2ff; direction: ltr; }.falling-star { position: absolute; color: #8b6800; font-size: 38px; transform: translateX(-50%); }.catch-basket { position: absolute; bottom: 0; font-size: 45px; transform: translateX(-50%); }.paint-palette { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }.paint-color { width: 48px; height: 46px; border: 2px solid #bac9cc; border-radius: 12px; font-size: 0; }.paint-color[aria-pressed=true] { outline: 3px solid var(--ink); outline-offset: 2px; }.paint-0 { background: #174a73; }.paint-1 { background: #db4d45; }.paint-2 { background: #ffc914; }.paint-3 { background: #21836e; }.paint-4 { background: #3f71b5; }.paint-5 { background: #aa55cf; }.paint-6 { background: #ff8147; }.paint-7 { background: #fff; }.pixel-board { gap: 0; border: 2px solid var(--ink); touch-action: none; }.pixel-board button { min-height: 0; border: 1px solid #dce3e6; border-radius: 0; background: #fff; }.piano-keys { display: flex; direction: ltr; gap: 4px; padding: 12px; background: var(--ink); border-radius: 18px; }.piano-keys button { flex: 1; min-width: 0; min-height: 200px; display: flex; flex-direction: column; justify-content: end; gap: 12px; align-items: center; padding: 10px 2px; border: 0; border-bottom: 7px solid #cad8dc; border-radius: 7px; background: #fff; color: var(--ink); font-size: 17px; }.piano-keys button:active { background: #ffdf70; }.piano-keys small { color: #647b88; font-size: 10px; }.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media(min-width:1600px) { .games-grid { grid-template-columns: repeat(5,minmax(0,1fr)); } }
@media(max-width:1100px) { .games-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }.games-hero { grid-template-columns: 1.1fr .9fr; gap: 25px; }.arcade-hero-art { transform: scale(.88); }.catalog-toolbar { flex-wrap: wrap; }.catalog-toolbar .games-search { flex-basis: 100%; } }
@media(max-width:760px) { .games-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px; }.games-hero { grid-template-columns: 1fr; text-align: center; padding: 35px 24px; }.games-hero-copy > p:not(.eyebrow) { margin-inline: auto; max-width: 460px; }.games-hero-tags { justify-content: center; }.arcade-hero-art { display: none; }.games-summary { margin-bottom: 30px; }.games-summary div { flex-direction: column; gap: 0; padding: 12px 5px; }.games-summary span { font-size: 9px; }.games-summary strong { font-size: 28px; }.games-section-head { display: flex; gap: 12px; }.games-section-head h2 { font-size: 28px; }.games-section-head .eyebrow { font-size: 10px; }.surprise-button { font-size: 10px; padding: 10px; min-height: 44px; }.games-categories { flex-wrap: nowrap; overflow-x: auto; padding: 4px 3px 12px; }.category-chip { flex: 0 0 auto; font-size: 11px; padding: 8px 12px; }.catalog-toolbar { gap: 10px; }.catalog-toolbar > label:not(.games-search) { flex: 1; flex-direction: column; align-items: stretch; gap: 4px; }.catalog-toolbar select { max-width: none; width: 100%; }.catalog-card h3 { font-size: 23px; }.catalog-card-body { padding: 12px; }.catalog-card p { font-size: 10px; }.game-cover { height: 135px; }.cover-icon { font-size: 58px; }.catalog-card-foot > span:last-child { display: none; }.game-card-skill { font-size: 9px; }.game-score { min-width: 0; }.game-player-head { flex-direction: row; align-items: center; gap: 14px; }.game-score { width: auto; padding: 10px; }.game-objective { padding: 15px; }.game-objective p { font-size: 12px; }.game-objective > span { display: none; }.arcade-grid { gap: 5px; }.pixel-board { gap: 0; }.snake-board { gap: 1px; }.piano-keys { padding: 8px; gap: 3px; }.piano-keys button { min-height: 160px; font-size: 12px; }.connect-controls button { min-height: 44px; } }
@media(max-width:360px) { .games-library { padding-inline: 12px; }.games-grid { gap: 10px; }.catalog-card h3 { font-size: 21px; }.game-cover { height: 120px; }.games-section-head { align-items: start; flex-direction: column; }.game-score strong { font-size: 19px; }.game-player-head h2 { font-size: 28px; }.game-player { padding-inline: 12px; }.arcade-pad button { width: 48px; }.arcade-grid button { font-size: 24px; }.pixel-board button { font-size: 0; } }
@media(prefers-reduced-motion:reduce) { .catalog-card { transition: none; }.catalog-card:hover { transform: none; } }
/* Keep the games section reachable from every page on small screens. */
@media (max-width: 1100px) {
  .site-header nav { display: flex; grid-column: 1 / -1; grid-row: 2; justify-content: flex-start; gap: clamp(6px,2vw,16px); min-width:0; max-width:100%; overflow-x:auto; overscroll-behavior-x:contain; border-top: 1px solid #e4eceb; }
  .site-header nav a { flex:0 0 auto; font-size: 11px; min-height: 44px; white-space: nowrap; }
  .game-player, .games-library { scroll-margin-top: 135px; }
}
@media (max-width: 760px) {
  .games-hero { padding-block: 28px; }
  .games-hero-copy h1 { font-size: 44px; }
  .games-hero-copy > p:not(.eyebrow) { font-size: 14px; line-height: 1.9; margin-block: 14px; }
  .games-hero-tags { margin-bottom: 18px; font-size: 10px; }
  .game-player { padding-top: 12px; }
  .game-player-head { margin-block: 14px; }
  .game-player-head h2 { font-size: 32px; }
  #activeGameSkill { display: none; }
  .game-score { padding: 7px 10px; }
  .game-objective { padding: 12px 14px; }
  .game-objective strong { font-size: 12px; }
  .game-objective p { font-size: 11px; }
  .arcade-status { margin-bottom: 12px; font-size: 12px; }
  .maze-board, .snake-board { max-width: 280px; }
  .arcade-pad { margin-block: 10px 6px; }
  .arcade-pad button { height: 44px; }
}
