:root {
  color-scheme: light;
  --navy: #061d36;
  --ink: #163b57;
  --sky: #68c7e9;
  --blue: #0872bd;
  --yellow: #ffbe3d;
  --green: #55b83a;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  color: var(--navy);
  background: #fff;
  font: 1rem/1.5 "Trebuchet MS", ui-sans-serif, system-ui, sans-serif;
  min-width: 280px;
}
.skip-link { position: absolute; top: 12px; left: 12px; z-index: 2; padding: 12px 18px; border-radius: 8px; color: #fff; background: var(--navy); transform: translateY(-180%); }
.skip-link:focus { transform: translateY(0); }
.hero { background: radial-gradient(circle, #ffd367 2px, transparent 2.5px) 10px 10px / 34px 34px, #55c1d8; border-bottom: 6px solid #fff; box-shadow: 0 1px 0 #d9edf4; }
.hero-inner { max-width: 1280px; margin: auto; padding: 24px; text-align: center; }
.brand-heading { margin: 0; line-height: 1; }
.brand-logo { display: block; width: min(800px, 100%); height: auto; max-height: 360px; object-fit: contain; margin: 0 auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
button, input, textarea { font: inherit; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, textarea:focus-visible, .suggestions-status a:focus-visible { outline: 3px solid var(--blue); outline-offset: 4px; }
.top-actions { display: flex; justify-content: flex-end; max-width: 1360px; margin: 0 auto; padding: 12px 32px; }
.suggestions-button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 46px; padding: 10px 20px; border: 0; border-radius: 999px; background: #def9f7; color: #005b99; font-weight: 700; }
.suggestions-button:hover { background: #c8f0ed; }
body.dialog-open { overflow: hidden; }
.suggestions-dialog { width: min(560px, calc(100% - 32px)); max-height: calc(100dvh - 32px); padding: 26px; margin: auto; overflow-y: auto; overscroll-behavior: contain; color: var(--navy); background: #fff; border: 2px solid #c9e8fa; border-radius: 24px; box-shadow: 0 18px 64px #061d3640; }
.suggestions-dialog::backdrop { background: #061d3699; }
.dialog-heading { display: flex; align-items: flex-start; gap: 16px; }
.dialog-heading h2 { flex: 1; margin-top: 6px; font-size: clamp(1.375rem, 4vw, 1.625rem); letter-spacing: -.025em; }
.dialog-close { display: grid; place-items: center; flex-shrink: 0; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; background: #e8f7ff; color: var(--navy); font-size: 1.75rem; line-height: 1; }
.suggestions-dialog > p { color: #395770; margin: 12px 0 20px; }
.suggestions-form { display: grid; gap: 18px; }
.suggestions-field { display: grid; gap: 7px; }
.suggestions-field label { font-weight: 700; }
.optional-label { color: #41617a; font-weight: 400; }
.suggestions-field input, .suggestions-field textarea { width: 100%; min-width: 0; padding: 11px 13px; border: 1px solid #8eafc1; border-radius: 12px; color: var(--navy); background: #fff; }
.suggestions-field textarea { resize: vertical; min-height: 132px; }
.suggestions-field input::placeholder, .suggestions-field textarea::placeholder { color: #5a7182; opacity: 1; }
.suggestions-submit { min-height: 48px; padding: 12px 18px; border: 0; border-radius: 12px; background: #167b4e; color: white; font-weight: 700; }
.suggestions-submit:hover { background: #10623d; }
.suggestions-note { margin: -8px 0 0; color: #41617a; font-size: .875rem; }
.suggestions-status { margin: 0; padding: 12px; border-radius: 12px; background: #e8f7ff; color: #163b57; }
.suggestions-status a { color: #005b99; font-weight: 700; }
main { max-width: 1360px; margin: auto; padding: 34px 32px 46px; }
main:focus { outline: none; }
.section-heading { margin: 0 0 26px; text-align: center; }
h2 { margin: 0; font-size: clamp(1.5rem, 2.4vw, 2rem); line-height: 1.25; letter-spacing: -.035em; }
.section-heading p { margin: 8px 0 0; color: #41617a; }
.games { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.game { --accent: #0872bd; --tint: #e8f7ff; --edge: #c9e8fa; --button-ink: #fff; display: flex; flex-direction: column; min-width: 0; color: inherit; text-decoration: none; background: white; border: 2px solid var(--edge); border-radius: 24px; box-shadow: 0 6px 0 var(--edge); transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; }
.game-mate { --accent: #ffbe3d; --tint: #fff8e5; --edge: #f3e4b7; --button-ink: #061d36; }
.game-bio { --accent: #258239; --tint: #edf9e8; --edge: #d0e8c6; }
.game-friends { --accent: #e16c39; --tint: #fff2e9; --edge: #f7d6c3; --button-ink: #061d36; }
.game-art { background: var(--tint); border-radius: 22px 22px 0 0; padding: 17px 14px 12px; }
.subject { display: inline-block; max-width: 100%; background: #fff; padding: 5px 11px; border: 1px solid var(--edge); border-radius: 9px; color: var(--ink); font-size: .875rem; font-weight: 700; }
.game-art img { display: block; width: 100%; height: 154px; margin-top: 12px; object-fit: contain; }
.game-content { display: flex; flex: 1; flex-direction: column; padding: 22px 20px 24px; }
h3 { font-size: 1.5rem; letter-spacing: -.04em; line-height: 1.22; margin: 0; }
.game-content p { margin: 12px 0 24px; color: #395770; flex-grow: 1; }
.play { display: flex; align-items: center; justify-content: center; gap: 13px; border-radius: 12px; background: var(--accent); color: var(--button-ink); min-height: 48px; padding: 10px 18px; font-size: 1.0625rem; font-weight: 900; }
.play span { font-size: 1.375rem; line-height: 1; }
.game:focus-visible { outline: 4px solid var(--navy); outline-offset: 5px; }
.game:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--edge); }
footer { max-width: 1296px; margin: 0 auto; border-top: 1px solid #e0edf3; padding: 22px 0 28px; color: #315571; font-size: .875rem; text-align: center; }
.creator-credit { margin: 0; font-weight: 700; line-height: 1.7; }
@media (hover: hover) { .game:hover { border-color: var(--accent); transform: translateY(-5px); box-shadow: 0 11px 0 var(--edge); } }
@media (max-width: 1390px) { footer { margin-left: 32px; margin-right: 32px; } }
@media (min-width: 1120px) { h3 { min-height: 2.45em; display: flex; align-items: center; } }
@media (max-width: 1119px) {
  .games { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
  main { max-width: 960px; }
  .hero-inner { padding-top: 22px; padding-bottom: 22px; }
  .game-art img { height: 170px; }
}
@media (max-width: 620px) {
  .top-actions { padding: 10px 16px; }
  .suggestions-button { padding: 9px 16px; }
  .suggestions-dialog { padding: 20px; border-radius: 20px; }
  .hero { background-size: 28px 28px; }
  .hero-inner { padding: 18px 12px; }
  .brand-logo { max-height: 260px; }
  main { padding: 25px 16px 32px; }
  .section-heading { margin-bottom: 21px; }
  h2 { font-size: 1.4375rem; }
  .section-heading p { margin-top: 6px; font-size: 1rem; }
  .games { grid-template-columns: minmax(0, 1fr); gap: 22px; }
  .game { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1fr); border-radius: 20px; }
  .game-art { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; border-radius: 18px 0 0 18px; padding: 12px 8px; }
  .subject { padding: 4px 7px; font-size: .875rem; }
  .game-art img { width: 100%; height: auto; aspect-ratio: 1.5; margin-top: 12px; }
  .game-content { padding: 17px 13px; }
  h3 { font-size: 1.25rem; }
  .game-content p { margin: 9px 0 14px; font-size: 1rem; line-height: 1.4; }
  .play { min-height: 44px; padding: 8px 12px; font-size: 1rem; }
  footer { margin: 0 16px; padding: 19px 0 24px; }
}
@media (max-width: 349px) {
  .game { display: flex; }
  .game-art { border-radius: 18px 18px 0 0; }
  .game-art img { height: 125px; }
  .game-content { padding: 16px; }
}
@media (prefers-reduced-motion: reduce) { .game { transition: none; } }
