:root {
  --bg: #10343f;
  --panel: #0f3a46;
  --card: #1a5263;
  --text: #ffffff;
  --muted: #b4ced6;
  --accent: #ffd54f;
  --primary: #f9a825;
  --ink: #1d1d1b;
}
* { box-sizing: border-box; }
html { color-scheme: dark; }
body {
  margin: 0;
  background: radial-gradient(ellipse at top, #1f5e70 0%, var(--bg) 60%) fixed, var(--bg);
  color: var(--text);
  font: 17px/1.55 system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}
a { color: inherit; }
header.top, main, footer { max-width: 1040px; margin: 0 auto; padding: 0 20px; }
header.top { display: flex; align-items: center; justify-content: space-between; padding-top: 20px; padding-bottom: 20px; }
.brand { font-weight: 800; font-size: 22px; text-decoration: none; letter-spacing: 0.02em; }
.langs { position: relative; }
.langs summary { list-style: none; cursor: pointer; color: var(--muted); border: 1px solid #2f7586; border-radius: 999px; padding: 6px 14px; font-size: 15px; }
.langs summary::-webkit-details-marker { display: none; }
.langs summary:hover, .langs[open] summary { color: var(--text); border-color: var(--muted); }
.langs nav { position: absolute; right: 0; top: calc(100% + 8px); z-index: 2; display: grid; grid-template-columns: repeat(2, minmax(120px, 1fr)); gap: 6px; padding: 10px; background: var(--panel); border: 1px solid #22606f; border-radius: 12px; box-shadow: 0 12px 30px rgb(0 0 0 / 0.35); }
.langs nav .lang { text-align: center; }
.lang { color: var(--muted); text-decoration: none; border: 1px solid #2f7586; border-radius: 999px; padding: 6px 14px; font-size: 15px; }
.lang:hover { color: var(--text); border-color: var(--muted); }
.hero { padding: 48px 0 56px; max-width: 720px; }
h1 { font-size: clamp(32px, 6vw, 54px); line-height: 1.08; margin: 0 0 18px; font-weight: 800; }
.hero p { color: var(--muted); font-size: 19px; margin: 0 0 30px; }
.play {
  display: inline-block; background: var(--primary); color: var(--ink); font-weight: 800; font-size: 20px;
  text-decoration: none; padding: 14px 34px; border-radius: 999px; box-shadow: 0 6px 20px rgb(0 0 0 / 0.25);
}
.play:hover { background: var(--accent); }
h2 { font-size: 30px; margin: 8px 0 4px; }
h3 { font-size: 18px; color: var(--accent); margin: 30px 0 12px; font-weight: 700; }
.muted { color: var(--muted); margin: 0; }
.games { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.games a {
  display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: 12px; align-items: center;
  background: var(--panel); border: 1px solid #22606f; border-radius: 12px; padding: 12px 14px; text-decoration: none;
}
.games a:hover { background: var(--card); border-color: var(--muted); }
.flag { grid-row: span 2; font-size: 26px; line-height: 1; }
.name { font-weight: 700; }
.meta { color: var(--muted); font-size: 14px; }
footer { color: var(--muted); font-size: 14px; padding-top: 56px; padding-bottom: 36px; }
footer p { margin: 0 0 10px; }
.report summary { cursor: pointer; color: var(--muted); text-decoration: underline; width: fit-content; }
.report summary:hover { color: var(--text); }
.report form { display: grid; gap: 10px; max-width: 560px; margin-top: 12px; }
.report textarea { font: inherit; font-size: 16px; color: var(--ink); background: #fdfaf2; border: 0; border-radius: 10px; padding: 10px 12px; resize: vertical; }
.report button { justify-self: start; font: inherit; font-weight: 700; color: var(--ink); background: var(--primary); border: 0; border-radius: 999px; padding: 8px 22px; cursor: pointer; }
.report button:disabled { opacity: 0.5; }
.report-status { min-height: 1.2em; }

/* Rules page */
html { scroll-padding-top: 16px; }
.crumbs { color: var(--muted); font-size: 15px; margin: 8px 0 14px; }
.crumbs a { color: var(--muted); }
.rules h1 { font-size: clamp(30px, 5vw, 46px); margin-bottom: 14px; }
.rules .lead { font-size: 19px; color: #e3eff2; max-width: 760px; }
.rules .lead p { margin: 0 0 10px; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; margin: 22px 0; }
.facts div { background: var(--panel); border: 1px solid #22606f; border-radius: 12px; padding: 10px 14px; }
.facts dt { color: var(--muted); font-size: 13px; text-transform: uppercase; letter-spacing: 0.05em; }
.facts dd { margin: 2px 0 0; font-weight: 600; }
.cta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; margin: 26px 0 8px; }
.columns { display: grid; grid-template-columns: 220px 1fr; gap: 40px; margin-top: 30px; }
.toc { position: sticky; top: 16px; align-self: start; font-size: 15px; }
.toc h2 { font-size: 13px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.05em; margin: 0 0 8px; }
.toc ol { list-style: none; margin: 0; padding: 0; border-left: 2px solid #22606f; }
.toc a { display: block; padding: 5px 12px; color: var(--muted); text-decoration: none; }
.toc a:hover { color: var(--text); }
article { max-width: 720px; min-width: 0; }
article section { margin-bottom: 30px; }
article h2 { font-size: 26px; margin: 0 0 10px; }
article h3 { color: var(--text); font-size: 19px; margin: 18px 0 8px; }
article p, article li { color: #e3eff2; }
article ul { padding-left: 22px; }
article li { margin: 4px 0; }
article strong { color: var(--text); }
article .table { overflow-x: auto; margin: 12px 0; }
article table { border-collapse: collapse; font-size: 15px; min-width: 60%; }
article th, article td { border-bottom: 1px solid #22606f; padding: 6px 12px; text-align: left; }
article th { color: var(--accent); font-weight: 700; }
article td.num, article th.num { text-align: right; }
.related { margin-top: 30px; }
.related h2 { font-size: 24px; margin-bottom: 14px; }
@media (max-width: 760px) {
  .columns { grid-template-columns: 1fr; gap: 10px; }
  .toc { position: static; }
}

/* Footer and legal pages */
footer .legal a { color: var(--muted); }
footer .legal a:hover { color: var(--text); }
.legal-page h1 { margin-bottom: 8px; }
.legal-page article { margin-top: 28px; }
.legal-page code { font-size: 0.9em; overflow-wrap: anywhere; }
