/* RULES-1: rules pages (/rules/, /rules/en/, /rules/ai/) on top of /site/site.css. */
.rules h2 { scroll-margin-top: 12px; display: flex; align-items: baseline; gap: 8px; }
.rules h4 { margin: 0 0 2px; font-size: 16px; }
.anchor { color: var(--line); text-decoration: none; font-weight: 400; }
.anchor:hover { color: var(--yellow); }
.rules-alt { font-weight: 700; }
.toc { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 12px 18px; margin: 16px 0 8px; }
.toc ol { columns: 2 220px; column-gap: 24px; margin: 8px 0 0; padding-left: 22px; }
.toc li { break-inside: avoid; margin: 2px 0; }
.toc a { color: var(--text); text-decoration: none; }
.toc a:hover { color: var(--yellow); }
section { margin-top: 8px; }
.quick { counter-reset: q; list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 10px; }
.quick li { counter-increment: q; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px 12px 50px; position: relative; }
.quick li::before { content: counter(q); position: absolute; left: 14px; top: 11px; width: 26px; height: 26px; border-radius: 50%; background: var(--yellow); color: #1b1530; font-weight: 900; display: grid; place-items: center; font-size: 14px; }
.cn { color: var(--yellow); font-weight: 800; }
.rn { font-weight: 800; }
.rn.is-law { color: #ffd666; }
.rn.is-raiders { color: #ff7a7a; }
.rn.is-lone, .rn.is-impostor { color: #c9a6ff; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 20px; align-items: start; }
@media (max-width: 720px) { .split { grid-template-columns: 1fr; } }
.shot { margin: 12px 0; }
.shot img { display: block; width: 100%; height: auto; border-radius: 18px; border: 1px solid var(--line); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35); }
.shot.is-phone { max-width: 300px; }
.shot.is-wide { max-width: 100%; }
.shot figcaption { color: var(--muted); font-size: 14px; margin-top: 8px; line-height: 1.45; }
.shots-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 300px)); gap: 20px; }
.role-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 12px; margin: 12px 0; }
.role-card { display: flex; gap: 14px; background: var(--panel); border: 1px solid var(--line); border-left: 4px solid var(--line); border-radius: 14px; padding: 14px; }
.role-card.is-law { border-left-color: #ffd666; }
.role-card.is-raiders { border-left-color: #ff7a7a; }
.role-card.is-lone, .role-card.is-impostor { border-left-color: #c9a6ff; }
.role-card h3 { margin: 0 0 4px; }
.role-card p { margin: 0; color: var(--muted); font-size: 15px; }
.role-art { width: 64px; height: 64px; border-radius: 50%; flex: none; object-fit: cover; }
.team { font-size: 12px; font-weight: 800; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 1px 8px; vertical-align: middle; margin-left: 4px; }
.table-wrap { overflow-x: auto; margin: 8px 0; }
.table-wrap table { min-width: 420px; }
table.comp td, table.comp th { text-align: center; }
table.comp tbody th { color: var(--yellow); }
.steps { padding-left: 22px; }
.steps li { margin: 6px 0; }
ul.rich li { margin: 6px 0; }
.rings { display: flex; gap: 24px; flex-wrap: wrap; margin: 10px 0; }
.rings figure { margin: 0; width: 220px; }
.rings figcaption { color: var(--muted); font-size: 14px; text-align: center; }
.ring { width: 220px; height: 220px; }
.ring-track { fill: none; stroke: var(--line); stroke-width: 10; }
.ring-seat circle { fill: var(--panel); stroke: var(--cyan); stroke-width: 2.5; }
.ring-seat text { fill: var(--text); font: 800 18px system-ui, sans-serif; text-anchor: middle; }
.ring-seat.is-me circle { fill: var(--yellow); stroke: var(--yellow); }
.ring-seat.is-me text { fill: #1b1530; font-size: 13px; }
.ring-seat.is-dead circle { fill: #15112a; stroke: var(--line); stroke-dasharray: 4 3; }
.ring-seat.is-dead text { fill: var(--muted); font-size: 16px; }
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; margin: 8px 0 16px; }
.game-card { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; display: flex; gap: 12px; padding: 10px; align-items: flex-start; }
.game-card.is-brown { border-left: 4px solid #c98b4a; }
.game-card.is-blue { border-left: 4px solid #5aa9ff; }
.game-card.is-weapon { border-left: 4px solid #9aa3b5; }
/* the art is square with dark bands top and bottom: a wider-than-tall box crops them */
.card-art { width: 108px; height: 84px; object-fit: cover; display: block; flex: none; border-radius: 10px; }
.card-body { min-width: 0; }
.card-body p { margin: 4px 0; font-size: 15px; }
.card-meta { color: var(--muted); font-size: 13px !important; }
.kind { font-weight: 800; }
.card-tip { color: var(--muted); }
.char-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; margin: 8px 0; }
.char-card { display: flex; gap: 12px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 12px; }
.char-card p { margin: 3px 0; font-size: 15px; }
.char-art { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; flex: none; border: 2px solid var(--line); }
.hp { color: #ff7a9c; font-size: 14px; font-weight: 800; margin-left: 4px; }
.ico-list { list-style: none; padding: 0; margin: 6px 0 0; }
.ico-list li { display: flex; gap: 10px; margin: 6px 0; align-items: baseline; }
.ico-list .ico { width: 26px; flex: none; text-align: center; }
.emote { display: inline-block; border: 1px solid var(--line); border-radius: 999px; padding: 1px 10px; margin: 3px 2px; font-size: 14px; }
pre.code { background: #15112a; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; overflow-x: auto; font-size: 13.5px; line-height: 1.5; }
pre.code code { background: none; padding: 0; }
.rules-ai td { vertical-align: top; font-size: 14px; }
.rules-ai td code { overflow-wrap: anywhere; }
.rules-ai td:first-child code { white-space: nowrap; }
