/* Shared look for the BlockFit Puzzle pages: the game's palette, readable in light and dark. */
:root {
  --bg: #f7f6fc;
  --card: #ffffff;
  --fg: #1d1b33;
  --muted: #5d5a7a;
  --line: #e4e1f2;
  --accent: #4b3fd1;
  --hero-top: #2e2470;
  --hero-bottom: #15123a;
  --summary: #f0eeff;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #12102a;
    --card: #1b1838;
    --fg: #ecebf7;
    --muted: #a9a5c8;
    --line: #2d2953;
    --accent: #a99cff;
    --summary: #221e48;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 16px/1.65 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-text-size-adjust: 100%;
}
.wrap { max-width: 820px; margin: 0 auto; padding: 0 16px; }
a { color: var(--accent); text-underline-offset: 2px; }

.hero {
  background: linear-gradient(var(--hero-top), var(--hero-bottom));
  color: #fff;
  padding: 28px 0 36px;
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  color: #fff; text-decoration: none; font-weight: 700; font-size: 1.05rem;
}
.logo { display: grid; grid-template-columns: repeat(2, 11px); gap: 3px; }
.logo i { width: 11px; height: 11px; border-radius: 3px; display: block; }
.logo i:nth-child(1) { background: #ff6b5a; }
.logo i:nth-child(2) { background: #ffc145; }
.logo i:nth-child(3) { background: #3fc8f2; }
.logo i:nth-child(4) { background: #5bd97a; }
.hero h1 { font-size: clamp(1.9rem, 6vw, 2.6rem); line-height: 1.15; margin: 22px 0 6px; }
.hero .meta { margin: 0; color: #c9c3ff; }

main { padding-top: 28px; padding-bottom: 48px; }
section { margin: 0 0 30px; }
h2 { font-size: 1.25rem; line-height: 1.3; margin: 0 0 10px; }
p { margin: 0 0 12px; }
ul, ol { margin: 0 0 12px; padding-left: 22px; }
li { margin: 4px 0; }

.summary {
  background: var(--summary);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 18px 20px 8px;
}
.summary ul { list-style: none; padding: 0; }
.summary li { padding-left: 26px; position: relative; }
.summary li::before {
  content: ""; position: absolute; left: 0; top: 7px;
  width: 12px; height: 12px; border-radius: 3px; background: #5bd97a;
}

.toc {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 16px 20px 6px;
  margin-bottom: 32px;
}
.toc ol { columns: 2; column-gap: 28px; }
@media (max-width: 560px) { .toc ol { columns: 1; } }

.table { overflow-x: auto; margin: 0 0 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); }
table { width: 100%; border-collapse: collapse; font-size: .94rem; min-width: 620px; }
th, td { text-align: left; vertical-align: top; padding: 11px 13px; border-bottom: 1px solid var(--line); }
th { font-size: .82rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
tr:last-child td { border-bottom: 0; }
td span { color: var(--muted); font-size: .88rem; }

.steps { counter-reset: step; list-style: none; padding: 0; }
.steps li { counter-increment: step; position: relative; padding: 2px 0 2px 40px; margin: 10px 0; }
.steps li::before {
  content: counter(step); position: absolute; left: 0; top: 0;
  width: 28px; height: 28px; border-radius: 8px; background: var(--accent); color: #fff;
  display: grid; place-items: center; font-weight: 700; font-size: .9rem;
}
.card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 18px 20px 8px; margin: 0 0 22px; }
.button {
  display: inline-block; background: var(--accent); color: #fff; text-decoration: none;
  padding: 10px 18px; border-radius: 12px; font-weight: 600; margin: 4px 0 12px;
}
.contact { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 14px 18px; }

footer { border-top: 1px solid var(--line); padding: 18px 0 28px; color: var(--muted); font-size: .9rem; }
footer a { color: var(--muted); }
