@font-face { font-family: "Bricolage Grotesque"; src: url("assets/fonts/bricolage-800.ttf") format("truetype"); font-style: normal; font-weight: 600 800; font-display: swap; }
@font-face { font-family: "Nunito"; src: url("assets/fonts/nunito-700.ttf") format("truetype"); font-style: normal; font-weight: 500 800; font-display: swap; }

:root {
  --blue: #6868e8;
  --blue-dark: #34317e;
  --blue-link: #5555d9;
  --page: #f4f0ff;
  --green: #238b72;
  --mint: #bcebd9;
  --board: #a9dfbd;
  --board-alt: #9bd6b1;
  --ink: #302d49;
  --coral: #ff7469;
  --yellow: #ffd75e;
  --white: #fffdf8;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background:
    radial-gradient(circle at 8% 12%, rgba(255,215,94,.35) 0 90px, transparent 91px),
    radial-gradient(circle at 94% 34%, rgba(255,116,105,.18) 0 150px, transparent 151px),
    var(--page);
  color: var(--ink);
  font-family: "Nunito", sans-serif;
  font-size: 18px;
  line-height: 1.7;
}
a { color: var(--blue-link); text-decoration: underline dotted; text-underline-offset: 4px; }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 4px solid var(--yellow); outline-offset: 4px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.topbar {
  position: relative;
  z-index: 30;
  min-height: 76px;
  padding: 0 max(22px, calc((100% - 1120px) / 2));
  display: flex;
  align-items: center;
  gap: 18px;
  background: linear-gradient(115deg, #312e79, #5555ce 64%, #6868e8);
  color: white;
  box-shadow: 0 5px 0 rgba(52,49,126,.12), 0 12px 28px rgba(52,49,126,.1);
}
.topbar::before {
  content: "";
  position: absolute;
  inset: auto max(18px, calc((100% - 1120px) / 2)) 9px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.24), transparent);
  pointer-events: none;
}
.topbar:not(:has(.language-switcher))::after {
  content: "";
  flex: 0 0 72px;
}
.logo {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: white;
  font-family: "Bricolage Grotesque", sans-serif;
  font-size: 23px;
  font-weight: 800;
  letter-spacing: -.045em;
  text-decoration: none;
  text-shadow: none;
}
.logo-mark { display: inline-flex; align-items: center; filter: drop-shadow(0 3px 0 rgba(31,29,83,.28)); transform: rotate(-7deg); }
.logo-mark i { width: 10px; height: 10px; margin-left: -2px; border-radius: 4px; background: var(--yellow); }
.logo-mark i:first-child { position: relative; width: 17px; height: 17px; margin-left: 0; border-radius: 50%; background: var(--coral); }
.logo-mark i:first-child::before, .logo-mark i:first-child::after { content: ""; position: absolute; width: 3px; height: 3px; margin-top: 4px; border-radius: 50%; background: white; }
.logo-mark i:first-child::before { margin-left: 4px; }
.logo-mark i:first-child::after { margin-left: 10px; }
.menu-button { display: none; align-items: center; gap: 7px; padding: 8px 11px; border: 1px solid rgba(255,255,255,.16); border-radius: 12px; color: white; background: rgba(255,255,255,.08); font-size: 14px; font-weight: 800; }
.menu-button b { font: inherit; }
.main-nav { margin-left: auto; display: flex; gap: 4px; align-items: center; padding: 5px; border: 1px solid rgba(255,255,255,.15); border-radius: 999px; background: rgba(255,255,255,.08); box-shadow: inset 0 1px 0 rgba(255,255,255,.12), 0 8px 22px rgba(31,29,83,.12); }
.main-nav a { padding: 8px 13px; border-radius: 999px; color: white; font-size: 12px; font-weight: 800; text-decoration: none; opacity: .78; transition: opacity .16s, background .16s, transform .16s, box-shadow .16s; }
.main-nav a:hover { opacity: 1; background: rgba(255,255,255,.14); box-shadow: inset 0 0 0 1px rgba(255,255,255,.1); }
.main-nav a.active:not(.play-nav) { position: relative; opacity: 1; }
.main-nav a.active:not(.play-nav)::after { content: ""; position: absolute; left: 14px; right: 14px; bottom: 4px; height: 2px; border-radius: 2px; background: var(--yellow); }
.main-nav a:hover { transform: translateY(-1px); }
.main-nav a.play-nav { padding-inline: 16px; background: var(--yellow); color: var(--blue-dark); opacity: 1; box-shadow: 0 3px 0 rgba(31,29,83,.2); }
.main-nav a.play-nav:hover, .main-nav a.play-nav.active { background: #ffe37b; }
.language-switcher {
  flex: 0 0 88px;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 4px;
  margin-left: -6px;
  color: white;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  opacity: .82;
}
.language-switcher select {
  width: 56px;
  min-height: 34px;
  padding: 0 22px 0 9px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 999px;
  background:
    linear-gradient(45deg, transparent 50%, currentColor 50%) right 10px center / 5px 5px no-repeat,
    rgba(255,255,255,.08);
  color: white;
  font: 800 10px "Nunito", sans-serif;
  letter-spacing: .08em;
  text-align: center;
  appearance: none;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.14);
}
.language-switcher select:hover { background-color: rgba(255,255,255,.14); }
.language-switcher select option { color: var(--ink); background: white; }
main { width: min(1120px, 100%); margin: 0 auto; }
.home-intro { padding: 78px 20px 55px; text-align: center; }
.home-intro h2 { margin: 8px auto 16px; color: var(--blue-dark); font-family: "Bricolage Grotesque", sans-serif; font-size: clamp(48px, 7vw, 82px); line-height: .95; letter-spacing: -.065em; }
.home-intro p { max-width: 700px; margin: 0 auto 24px; color: #595572; font-size: 20px; }
.play-now-link { display: inline-flex; align-items: center; gap: 10px; padding: 12px 20px; border-radius: 999px; background: var(--coral); color: white; font-weight: 800; text-decoration: none; box-shadow: 0 6px 0 rgba(52,49,126,.15); }
.benefit-list { display: flex; justify-content: center; flex-wrap: wrap; gap: 9px; margin: 24px 0 0; padding: 0; list-style: none; }
.benefit-list li { margin: 0; padding: 6px 11px; border-radius: 999px; background: white; color: var(--green); font-size: 12px; font-weight: 800; }
.benefit-list li::before { content: "✓ "; }
.homepage-guides { margin: 0 20px 55px; padding: 35px 40px 42px; border: 2px solid rgba(52,49,126,.08); border-radius: 28px; background: rgba(255,253,248,.78); box-shadow: 0 10px 0 rgba(104,104,232,.07); }
.homepage-guides > h2 { margin: 0; color: var(--blue-dark); font-family: "Bricolage Grotesque", sans-serif; font-size: clamp(34px, 5vw, 52px); line-height: 1; letter-spacing: -.05em; }
.homepage-guides .related-grid { margin-top: 25px; }
.game-wrap { position: relative; padding: 42px 20px 46px; scroll-margin-top: 20px; }
.game-wrap::before { content: ""; position: absolute; inset: 0 0 16%; z-index: -1; background: linear-gradient(135deg, rgba(104,104,232,.14), rgba(188,235,217,.34) 55%, rgba(255,215,94,.2)); border-radius: 0 0 70px 70px; }
.game-card {
  max-width: 900px;
  margin: 0 auto;
  padding: 18px;
  background: rgba(255,253,248,.94);
  border: 2px solid rgba(52,49,126,.11);
  border-radius: 34px;
  box-shadow: 0 18px 0 rgba(104,104,232,.11), 0 38px 80px rgba(52,49,126,.18);
}
.game-card-heading { display: flex; align-items: end; justify-content: space-between; gap: 25px; padding: 6px 10px 18px; }
.game-card-heading .section-label { margin: 0 0 2px; }
.game-card-heading h1 { margin: 0; color: var(--blue-dark); font-family: "Bricolage Grotesque", sans-serif; font-size: clamp(28px, 4vw, 42px); line-height: 1; letter-spacing: -.05em; }
.game-card-heading p { max-width: 245px; margin: 0; color: #6d6884; font-size: 13px; font-weight: 800; line-height: 1.4; text-align: right; }
.score-pill { align-items: center; padding: 7px 11px; border-radius: 12px; background: #fff1ef; }
.score-pill.best-pill { background: #fff7d6; }
.score-pill strong { min-width: 24px; font-size: 17px; line-height: 1; text-align: center; }
.game-meta {
  padding: 9px 8px 14px;
}
.game-meta { display: flex; align-items: center; gap: 10px; color: var(--blue-dark); font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.game-meta span { display: flex; gap: 7px; }
.game-meta strong { color: var(--coral); }
.game-actions { margin-left: auto; display: flex; gap: 7px; }
.game-meta button { width: 40px; height: 36px; border: 1px solid rgba(52,49,126,.07); border-radius: 11px; background: var(--page); color: var(--blue-dark); font-weight: 800; transition: transform .15s, background .15s, box-shadow .15s; }
.game-meta button:hover { transform: translateY(-2px); background: #ebe6ff; }
.game-meta button.muted { color: #9995af; background: #f1eff5; }
.speed-controls { display: flex; align-items: center; gap: 4px; margin: 0 0 0 5px; padding: 4px; border: 1px solid rgba(52,49,126,.06); border-radius: 13px; background: var(--page); }
.speed-controls legend { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
.speed-controls button { width: auto; height: 28px; padding: 0 8px; border-radius: 8px; background: transparent; font-size: 9px; }
.speed-controls button.selected { background: linear-gradient(135deg, var(--blue), #807cf0); color: white; box-shadow: 0 3px 0 rgba(52,49,126,.18); }
.board-wrap { position: relative; aspect-ratio: 10 / 7; overflow: hidden; border: 8px solid #fff; outline: 3px solid rgba(35,139,114,.22); border-radius: 26px; background: var(--board); box-shadow: inset 0 0 0 2px rgba(35,139,114,.12), 0 12px 28px rgba(35,139,114,.18); }
.board-wrap::after { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; box-shadow: inset 0 0 60px rgba(35,139,114,.15); }
canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.game-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  justify-items: center;
  z-index: 2;
  background: linear-gradient(145deg, rgba(52,49,126,.38), rgba(35,139,114,.38));
  backdrop-filter: blur(4px);
  opacity: 0;
  visibility: hidden;
  transition: .2s ease;
}
.game-overlay.active { opacity: 1; visibility: visible; }
.status-overlay { z-index: 4; text-align: center; background: rgba(52,49,126,.62); }
.status-overlay strong { color: white; font-family: "Bricolage Grotesque", sans-serif; font-size: clamp(72px, 14vw, 130px); text-shadow: 0 6px rgba(52,49,126,.25); }
.game-overlay .overlay-title { margin: 18px 0 0; color: white; font-family: "Bricolage Grotesque", sans-serif; font-size: clamp(34px, 6vw, 50px); font-weight: 800; letter-spacing: -.05em; line-height: 1.05; text-align: center; text-shadow: 0 4px rgba(52,49,126,.2); }
.game-overlay p { margin: 12px 0; color: white; font-size: 15px; font-weight: 600; text-shadow: 1px 1px #536d2e; }
.play-button {
  position: relative;
  z-index: 2;
  width: 92px;
  height: 92px;
  padding-left: 12px;
  border: 0;
  border-radius: 50%;
  background: linear-gradient(145deg, #ffe681, var(--yellow));
  color: var(--blue-dark);
  font-size: 42px;
  box-shadow: 0 8px 0 rgba(52,49,126,.18), 0 14px 30px rgba(52,49,126,.25);
  transition: transform .18s, box-shadow .18s;
}
.play-button:hover { transform: translateY(-3px) scale(1.04); box-shadow: 0 10px 0 rgba(52,49,126,.18), 0 18px 35px rgba(52,49,126,.28); }
.preview-snake { position: absolute; top: 20%; right: 12%; display: flex; filter: drop-shadow(0 7px 5px rgba(52,49,126,.18)); transform: rotate(-8deg); }
.preview-snake i { width: 34px; height: 34px; background: var(--blue); border-radius: 12px; box-shadow: -1px 3px rgba(52,49,126,.22); }
.preview-snake i:first-child { border-radius: 50%; background: var(--coral); }
.primary-button { padding: 10px 25px; border: 0; border-radius: 10px; background: white; color: var(--blue-dark); font-weight: 600; }
.game-over-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 9px; }
.secondary-button { padding: 10px 18px; border: 1px solid rgba(255,255,255,.42); border-radius: 10px; background: rgba(52,49,126,.52); color: white; font-weight: 700; }
.touch-controls { display: none; grid-template-columns: repeat(4, 1fr); gap: 6px; padding-top: 8px; }
.touch-controls button { border: 1px solid rgba(52,49,126,.08); border-radius: 12px; padding: 10px; background: var(--page); color: var(--blue-dark); font-weight: 800; box-shadow: 0 3px 0 rgba(52,49,126,.09); }
.content-card {
  padding: 55px 75px 75px;
  background: var(--white);
  border: 2px solid rgba(52,49,126,.08);
  border-radius: 36px 36px 0 0;
  box-shadow: 0 -5px 0 rgba(255,215,94,.35);
}
.content-card h1, .content-card h2 { font-family: "Bricolage Grotesque", sans-serif; color: var(--green); font-weight: 800; line-height: 1.04; letter-spacing: -.05em; }
.article-title { max-width: 780px; margin: 0 auto 28px !important; color: var(--green) !important; text-align: center; font-size: clamp(44px, 6vw, 70px) !important; }
.content-card h1 { max-width: 780px; margin: 0 auto 28px; text-align: center; font-size: clamp(50px, 7vw, 82px); }
.content-card h1::first-line { color: var(--blue-dark); }
.content-card h2 { margin: 65px 0 18px; font-size: clamp(34px, 4vw, 50px); }
.content-card p, .content-card li { text-align: justify; }
.content-card li { margin: 10px 0; }
.pixel-snake {
  position: relative;
  width: 100%;
  height: 32px;
  margin: 25px 0 35px;
  background: repeating-linear-gradient(90deg, var(--blue-dark) 0 13%, var(--blue) 13% 26%, var(--coral) 26% 39%, var(--yellow) 39% 52%);
  box-shadow: 0 6px 0 rgba(0,0,0,.09);
}
.pixel-snake::after { content: ""; position: absolute; right: -1px; top: 0; width: 32px; height: 32px; background: var(--coral); border-radius: 0 8px 8px 0; box-shadow: inset 8px 0 rgba(255,255,255,.25); }
.pixel-snake::before { content: "··"; position: absolute; z-index: 1; right: 4px; top: -4px; color: var(--blue-dark); letter-spacing: 8px; font-weight: 700; }
.illustration { position: relative; height: 280px; margin: 45px 0; overflow: hidden; border: 8px solid #e5f6ed; border-radius: 28px; background: repeating-conic-gradient(var(--board) 0 25%, var(--board-alt) 0 50%) 0 / 80px 80px; box-shadow: 0 12px 0 rgba(35,139,114,.1); }
.apple { position: absolute; left: 15%; top: 28%; width: 55px; height: 55px; border-radius: 48% 48% 52% 52%; background: #b13d28; box-shadow: inset -8px -8px rgba(99,33,21,.18); }
.apple::before { content: ""; position: absolute; top: -13px; left: 29px; width: 8px; height: 18px; border-radius: 10px; background: #507c32; transform: rotate(25deg); }
.snake-art { position: absolute; right: 11%; top: 26%; display: flex; }
.snake-art b { width: 53px; height: 53px; background: var(--blue); border-radius: 15px; }
.snake-art b:first-child { border-radius: 50%; background: var(--coral); }
.page-card { margin: 28px 20px 0; }
.lead { max-width: 820px; margin: 0 auto 30px; color: #54516c; font-size: 21px; text-align: center !important; }
.section-label { display: inline-block; margin-bottom: 8px; color: var(--coral); font-size: 12px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.quick-nav { display: flex; flex-wrap: wrap; gap: 9px; margin: 30px 0 45px; padding: 15px; border-radius: 18px; background: var(--page); }
.quick-nav a { padding: 7px 12px; border-radius: 999px; background: white; font-size: 13px; font-weight: 800; text-decoration: none; }
.info-grid, .stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin: 28px 0; }
.info-card, .stat-card, .callout, .related-links { padding: 23px; border: 2px solid rgba(52,49,126,.08); border-radius: 20px; background: white; box-shadow: 0 7px 0 rgba(104,104,232,.07); }
.info-card:nth-child(3n + 2), .stat-card:nth-child(3n + 2) { background: #fff8dc; }
.info-card:nth-child(3n + 3), .stat-card:nth-child(3n + 3) { background: #e9f8f1; }
.info-card h3, .stat-card strong, .callout h2, .callout h3, .related-links h2, .related-links h3, .faq h3 {
  margin: 0 0 8px;
  color: var(--blue-dark);
  font-family: "Bricolage Grotesque", sans-serif;
  font-size: 23px;
  line-height: 1.15;
  letter-spacing: -.03em;
}
.info-card p, .stat-card p, .callout p { margin: 0; font-size: 15px; text-align: left; }
.stat-card strong { display: block; color: var(--coral); font-size: 35px; }
.callout { margin: 35px 0; border-color: rgba(35,139,114,.15); background: #e9f8f1; }
.callout.coral { border-color: rgba(255,116,105,.18); background: #fff0ee; }
.content-table { width: 100%; margin: 25px 0 40px; border-collapse: separate; border-spacing: 0; overflow: hidden; border: 2px solid rgba(52,49,126,.08); border-radius: 18px; font-size: 15px; }
.content-table th, .content-table td { padding: 15px; border-bottom: 1px solid rgba(52,49,126,.08); text-align: left; vertical-align: top; }
.content-table th { background: var(--blue-dark); color: white; }
.content-table tr:last-child td { border: 0; }
.content-table tr:nth-child(even) td { background: #f8f6ff; }
.steps { counter-reset: step; display: grid; gap: 15px; margin: 25px 0; padding: 0; list-style: none; }
.steps li { position: relative; min-height: 68px; margin: 0; padding: 15px 18px 15px 72px; border-radius: 17px; background: #f8f6ff; text-align: left; }
.steps li::before { counter-increment: step; content: counter(step); position: absolute; left: 17px; top: 14px; width: 39px; height: 39px; display: grid; place-items: center; border-radius: 50%; background: var(--yellow); color: var(--blue-dark); font-weight: 800; }
.faq { display: grid; gap: 10px; margin: 25px 0; }
.faq details { padding: 16px 19px; border: 2px solid rgba(52,49,126,.08); border-radius: 16px; background: white; }
.faq summary { color: var(--blue-dark); font-weight: 800; cursor: pointer; }
.faq p { margin-bottom: 0; font-size: 15px; text-align: left; }
.related-links { margin-top: 55px; background: var(--page); }
.related-links nav { display: flex; flex-wrap: wrap; gap: 10px; }
.related-links a { padding: 8px 13px; border-radius: 12px; background: white; font-size: 14px; font-weight: 800; text-decoration: none; }
.related-section { margin-top: 65px; padding-top: 45px; border-top: 3px dashed rgba(104,104,232,.16); }
.related-section > h2 { margin-top: 0; }
.related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 25px; }
.related-card { position: relative; min-height: 225px; padding: 23px; overflow: hidden; border: 2px solid rgba(52,49,126,.08); border-radius: 22px; background: white; box-shadow: 0 8px 0 rgba(104,104,232,.08); }
.related-card:nth-child(3n + 2) { background: #fff7d6; }
.related-card:nth-child(3n + 3) { background: #e8f8f0; }
.related-card::after { content: ""; position: absolute; right: -25px; bottom: -35px; width: 95px; height: 95px; border: 18px solid rgba(104,104,232,.08); border-radius: 50%; }
.related-card .section-label { margin-bottom: 15px; }
.related-card h3 { margin: 0 0 9px; color: var(--blue-dark); font-family: "Bricolage Grotesque", sans-serif; font-size: 25px; line-height: 1.08; letter-spacing: -.035em; }
.related-card p { position: relative; z-index: 1; margin: 0 0 18px; font-size: 14px; line-height: 1.55; text-align: left; }
.related-card a { position: relative; z-index: 1; font-size: 13px; font-weight: 800; text-decoration: none; }
.international-page .lead { max-width: 900px; }
.international-hero {
  position: relative;
  padding: 10px 0 18px;
  text-align: center;
}
.intl-badges {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 9px;
  margin: 24px 0 0;
}
.intl-badges span {
  padding: 7px 12px;
  border: 1px solid rgba(52,49,126,.08);
  border-radius: 999px;
  background: var(--page);
  color: var(--blue-dark);
  font-size: 12px;
  font-weight: 800;
}
.language-card-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 42px 0 38px;
}
.language-card {
  position: relative;
  min-height: 260px;
  padding: 20px;
  overflow: hidden;
  border: 2px solid rgba(52,49,126,.08);
  border-radius: 24px;
  background: linear-gradient(180deg, #fffdf8, #f8f6ff);
  box-shadow: 0 8px 0 rgba(104,104,232,.07);
  transition: transform .18s, box-shadow .18s, border-color .18s;
}
.language-card:nth-child(3n + 2) { background: linear-gradient(180deg, #fffdf8, #fff7d6); }
.language-card:nth-child(3n + 3) { background: linear-gradient(180deg, #fffdf8, #e9f8f1); }
.language-card.primary-language { border-color: rgba(255,116,105,.26); background: linear-gradient(145deg, #fff0ee, #fffdf8 54%, #f8f6ff); }
.language-card:hover { transform: translateY(-4px); border-color: rgba(104,104,232,.2); box-shadow: 0 13px 0 rgba(104,104,232,.09); }
.language-card .card-link {
  position: absolute;
  inset: 0;
  z-index: 2;
  font-size: 0;
}
.language-card > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 16px;
}
.language-code {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: var(--blue-dark);
  color: white;
  font-family: "Bricolage Grotesque", sans-serif;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -.04em;
  box-shadow: 0 5px 0 rgba(52,49,126,.14);
}
.language-card h2 {
  margin: 0 0 10px;
  color: var(--green);
  font-size: 29px;
}
.language-card p {
  margin: 0 0 18px;
  color: #55516c;
  font-size: 14px;
  line-height: 1.55;
  text-align: left;
}
.language-card > a:not(.card-link) {
  position: relative;
  z-index: 3;
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}
.intl-info-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin: 42px 0 12px;
}
.intl-info-grid .info-card h2 {
  margin: 0 0 10px;
  color: var(--blue-dark);
  font-size: 28px;
}
.intl-info-grid .info-card p { text-align: left; }
.glossary { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px 24px; margin: 25px 0; }
.glossary div { padding: 17px 0; border-bottom: 2px solid rgba(52,49,126,.08); }
.glossary dt { color: var(--green); font-family: "Bricolage Grotesque", sans-serif; font-size: 20px; font-weight: 800; }
.glossary dd { margin: 4px 0 0; font-size: 14px; }
.checklist { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin: 25px 0; padding: 0; list-style: none; }
.checklist li { position: relative; margin: 0; padding: 14px 16px 14px 46px; border-radius: 15px; background: #f8f6ff; text-align: left; font-size: 15px; }
.checklist li::before { content: "✓"; position: absolute; left: 16px; top: 13px; color: var(--green); font-weight: 800; }
.article-meta { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px 18px; margin: -10px 0 30px; color: #716d88; font-size: 13px; font-weight: 800; }
.article-meta span { padding: 5px 10px; border-radius: 999px; background: var(--page); }
.article-intro { max-width: 820px; margin: 0 auto 35px; color: #514d69; font-size: 21px; text-align: center !important; }
.article-body h3 { margin: 32px 0 8px; color: var(--blue-dark); font-family: "Bricolage Grotesque", sans-serif; font-size: 26px; line-height: 1.15; letter-spacing: -.03em; }
.article-body blockquote { margin: 35px 0; padding: 22px 25px; border-left: 7px solid var(--coral); border-radius: 0 18px 18px 0; background: #fff0ee; color: var(--blue-dark); font-size: 20px; font-weight: 800; }
.article-pagination { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-top: 45px; padding-top: 35px; border-top: 3px dashed rgba(104,104,232,.16); }
.article-pagination a { padding: 18px 20px; border: 2px solid rgba(52,49,126,.08); border-radius: 18px; background: white; color: var(--blue-dark); font-weight: 800; line-height: 1.35; text-decoration: none; box-shadow: 0 6px 0 rgba(104,104,232,.07); }
.article-pagination a:last-child { text-align: right; }
.article-pagination small { display: block; margin-bottom: 4px; color: var(--coral); font-size: 10px; letter-spacing: .12em; text-transform: uppercase; }
.error-card { text-align: center; }
.error-hero {
  position: relative;
  max-width: 880px;
  margin: 0 auto 42px;
  padding: 36px 28px 42px;
  overflow: hidden;
  border: 2px solid rgba(52,49,126,.08);
  border-radius: 30px;
  background:
    radial-gradient(circle at 14% 20%, rgba(255,215,94,.38) 0 84px, transparent 85px),
    radial-gradient(circle at 88% 18%, rgba(255,116,105,.18) 0 108px, transparent 109px),
    linear-gradient(180deg, #fffdf8, #f8f6ff);
  box-shadow: 0 12px 0 rgba(104,104,232,.08);
}
.error-hero::after {
  content: "";
  position: absolute;
  left: 8%;
  right: 8%;
  bottom: 20px;
  height: 16px;
  border-radius: 999px;
  background: repeating-linear-gradient(90deg, var(--blue-dark) 0 28px, var(--blue) 28px 56px, var(--coral) 56px 84px, var(--yellow) 84px 112px);
  opacity: .16;
}
.error-code { margin: 0 0 8px; color: var(--coral); font-family: "Bricolage Grotesque", sans-serif; font-size: clamp(88px, 18vw, 180px); font-weight: 800; line-height: .78; letter-spacing: -.08em; }
.error-card .lead { max-width: 720px; }
.error-note { max-width: 680px; margin: -12px auto 26px; color: #5d5874; font-size: 17px; text-align: center !important; }
.error-route-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 32px 0 10px;
}
.error-route-card {
  padding: 22px;
  border: 2px solid rgba(52,49,126,.08);
  border-radius: 22px;
  background: white;
  box-shadow: 0 8px 0 rgba(104,104,232,.08);
  text-align: left;
}
.error-route-card:nth-child(2) { background: #fff7d6; }
.error-route-card:nth-child(3) { background: #e9f8f1; }
.error-route-card:nth-child(4) { background: #fff0ee; }
.error-route-card span {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  margin-bottom: 14px;
  border-radius: 13px;
  background: var(--blue-dark);
  color: white;
  font-weight: 800;
  line-height: 1;
}
.error-route-card h2 {
  margin: 0 0 9px;
  color: var(--green);
  font-size: 28px;
}
.error-route-card p {
  margin: 0 0 16px;
  color: #55516c;
  font-size: 14px;
  line-height: 1.55;
  text-align: left;
}
.error-route-card a { font-size: 13px; font-weight: 800; text-decoration: none; }
.article-body p { max-width: 900px; }
.article-body .content-table { max-width: 100%; }
.breadcrumbs { margin: 0 0 28px; color: #716d88; font-size: 13px; font-weight: 800; }
.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.breadcrumbs li { margin: 0; text-align: left; }
.breadcrumbs li:not(:last-child)::after { content: " /"; color: var(--coral); }
.key-takeaways { margin: 25px 0 35px; padding: 22px 24px; border: 2px solid rgba(35,139,114,.15); border-radius: 20px; background: #e9f8f1; }
.key-takeaways h2 { margin: 0 0 10px !important; color: var(--blue-dark) !important; font-size: 27px !important; }
.key-takeaways ul { margin-bottom: 0; }
.reading-progress { position: fixed; z-index: 50; top: 0; left: 0; width: 0; height: 4px; background: var(--yellow); }
.post-tile { position: relative; }
.post-tile > a.card-link { position: absolute; inset: 0; z-index: 2; border-radius: inherit; font-size: 0; }
.post-tile p a { position: relative; z-index: 3; }
.game-grid, .post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 35px; }
.game-tile, .post-tile { overflow: hidden; border: 2px solid rgba(52,49,126,.09); border-radius: 22px; background: white; box-shadow: 0 9px 0 rgba(104,104,232,.08); transition: transform .2s, box-shadow .2s; }
.game-tile:hover, .post-tile:hover { transform: translateY(-5px) rotate(-.5deg); box-shadow: 0 14px 0 rgba(104,104,232,.1); }
.game-thumb { height: 150px; background: repeating-conic-gradient(var(--board) 0 25%, var(--board-alt) 0 50%) 0 / 55px 55px; display: grid; place-items: center; color: white; font-size: 54px; text-shadow: 2px 2px #5d7832; }
.game-tile div:last-child, .post-tile { padding: 18px; }
.game-tile h3, .post-tile h3 { margin: 0 0 7px; color: var(--green); font-family: "Bricolage Grotesque", sans-serif; font-size: 23px; line-height: 1.1; letter-spacing: -.03em; }
.game-tile p, .post-tile p { margin: 0; font-size: 14px; text-align: left; }
.footer {
  position: relative;
  margin-top: 0;
  padding: 52px 20px 46px;
  overflow: hidden;
  background:
    radial-gradient(circle at 12% 20%, rgba(255,215,94,.2) 0 120px, transparent 121px),
    radial-gradient(circle at 90% 75%, rgba(255,116,105,.18) 0 150px, transparent 151px),
    linear-gradient(135deg, #282667, var(--blue-dark) 48%, #3d3aa1);
  border-top: 8px solid var(--yellow);
}
.footer::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255,255,255,.08) 1px, transparent 1px),
    linear-gradient(0deg, rgba(255,255,255,.06) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,.4), transparent 80%);
}
.footer-inner { position: relative; width: min(1120px, 100%); margin: 0 auto; display: grid; grid-template-columns: minmax(260px, 350px) 1fr; gap: 34px; align-items: start; }
.footer-brand { text-align: left; }
.footer-brand {
  padding: 24px;
  align-self: start;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 24px;
  background: rgba(255,255,255,.08);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.12), 0 18px 40px rgba(31,29,83,.16);
}
.footer-logo { display: inline-flex; margin-bottom: 10px; color: white; font-family: "Bricolage Grotesque", sans-serif; font-size: 30px; font-weight: 800; letter-spacing: -.045em; text-decoration: none; }
.footer a { color: white; }
.footer-columns {
  display: grid;
  grid-template-columns: 1.15fr 1fr 1.35fr;
  gap: 26px;
  padding: 24px 26px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 24px;
  background: rgba(255,255,255,.055);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.08);
}
.footer-column {
  min-width: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.footer-heading {
  margin: 0 0 14px;
  color: var(--yellow);
  font-family: "Bricolage Grotesque", sans-serif;
  font-weight: 800;
  font-size: 22px;
  line-height: 1;
  letter-spacing: -.035em;
}
.footer-column a {
  display: block;
  padding: 7px 0;
  border-bottom: 1px solid rgba(255,255,255,.08);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.35;
  text-decoration: none;
  opacity: .84;
  transition: opacity .16s, color .16s, transform .16s, border-color .16s;
}
.footer-column a:last-child { border-bottom: 0; }
.footer a:hover { opacity: 1; text-decoration: none; }
.footer-column a:hover { transform: translateX(3px); color: var(--yellow); border-color: rgba(255,215,94,.28); }
.footer p { margin: 0; color: #c4c6d6; font-size: 13px; line-height: 1.6; }
.footer-trust {
  display: grid;
  gap: 8px;
  margin: 18px 0 0;
  padding: 16px 0 0;
  border-top: 1px solid rgba(255,255,255,.12);
  list-style: none;
}
.footer-trust li {
  position: relative;
  margin: 0;
  padding-left: 20px;
  color: #fff7d6;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.35;
}
.footer-trust li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .48em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--yellow);
  box-shadow: 0 0 0 3px rgba(255,215,94,.16);
}

@media (max-width: 820px) {
  body { font-size: 18px; }
  .topbar { min-height: 58px; padding: 0 12px; }
  .topbar::before, .topbar:not(:has(.language-switcher))::after { display: none; }
  .logo { font-size: 21px; }
  .logo-mark i { width: 8px; height: 8px; }
  .logo-mark i:first-child { width: 15px; height: 15px; }
  .menu-button { display: inline-flex; margin-left: auto; }
  .menu-button span { font-size: 17px; line-height: 1; }
  .topbar > .language-switcher { flex-basis: 62px; justify-content: flex-start; order: 2; margin-left: auto; }
  .topbar > .language-switcher span { display: none; }
  .topbar > .language-switcher select { width: 54px; min-height: 32px; font-size: 10px; }
  .topbar > .menu-button { order: 3; margin-left: 0; }
  .main-nav { position: absolute; z-index: 20; top: 66px; left: 12px; right: 12px; display: none; margin: 0; padding: 8px; border: 1px solid rgba(255,255,255,.18); border-radius: 18px; background: #312e79; box-shadow: 0 18px 40px rgba(31,29,83,.32); }
  .main-nav.open { display: grid; gap: 3px; }
  .main-nav a { padding: 12px 14px; font-size: 14px; }
  .main-nav a.play-nav { text-align: center; }
  .game-wrap { padding: 20px 0 28px; }
  .game-wrap::before { border-radius: 0 0 28px 28px; }
  .game-card { padding: 8px; border-radius: 0; }
  .game-card-heading { align-items: start; padding: 12px 10px 15px; }
  .game-card-heading h1 { font-size: 29px; }
  .game-card-heading p { display: none; }
  .game-meta { flex-wrap: wrap; gap: 10px; }
  .speed-controls { order: 3; width: 100%; justify-content: center; }
  .board-wrap { border-width: 4px; border-radius: 18px; }
  .play-button { width: 74px; height: 74px; font-size: 33px; }
  .touch-controls { display: grid; }
  .home-intro { padding: 55px 24px 45px; }
  .homepage-guides { margin: 0 0 35px; padding: 28px 20px 34px; border-radius: 22px; }
  .content-card { margin: 0; padding: 22px 25px 50px; border-radius: 22px 22px 0 0; }
  .content-card h1 { font-size: clamp(42px, 13vw, 60px); margin-top: 0; }
  .content-card h2 { margin-top: 45px; font-size: 35px; }
  .content-card p, .content-card li { text-align: left; }
  .pixel-snake { height: 26px; }
  .pixel-snake::after { width: 26px; height: 26px; }
  .illustration { height: 210px; }
  .snake-art { right: 4%; }
  .snake-art b { width: 34px; height: 34px; border-radius: 9px; }
  .apple { width: 42px; height: 42px; }
  .game-grid, .post-grid, .info-grid, .stat-grid, .related-grid, .glossary, .checklist, .language-card-grid, .intl-info-grid, .error-route-grid { grid-template-columns: 1fr; }
  .language-card { min-height: 0; }
  .article-pagination { grid-template-columns: 1fr; }
  .article-pagination a:last-child { text-align: left; }
  .lead { font-size: 18px; text-align: left !important; }
  .article-intro { font-size: 18px; text-align: left !important; }
  .quick-nav { margin-bottom: 30px; }
  .content-table { display: block; overflow-x: auto; }
  .page-card { margin: 28px 0 0; }
  .footer-inner { grid-template-columns: 1fr; }
  .footer-brand { text-align: center; }
  .footer-columns { grid-template-columns: 1fr; gap: 20px; padding: 20px; }
  .footer-column { padding: 0; text-align: left; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .001ms !important; animation-duration: .001ms !important; animation-iteration-count: 1 !important; }
}
