.how .stage { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 24px; padding: 0 clamp(16px, 4vw, 48px) 40px; max-width: 1400px; margin: 0 auto; }
@media (max-width: 980px) { .how .stage { grid-template-columns: 1fr; } }
.canvas-wrap { position: relative; height: min(80vh, 720px); min-height: 480px; border-radius: 18px; overflow: hidden; background: radial-gradient(120% 90% at 30% 20%, #1d3442, #0d1820 70%); box-shadow: var(--shadow); }
#scene { display: block; width: 100%; height: 100%; position: absolute; inset: 0; cursor: grab; touch-action: none; }
#scene:active { cursor: grabbing; }
.hint { position: absolute; right: 16px; bottom: 8px; margin: 0; color: #8da1ad; font-size: .78rem; }
.legend { position: absolute; left: 16px; bottom: 12px; display: flex; gap: 14px; flex-wrap: wrap; color: #c9d4da; font-size: .78rem; }
.legend .dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 6px; vertical-align: -1px; }
.dot.q { background: #e0a43a; } .dot.k { background: #f1d27a; } .dot.v { background: #6fc3bb; } .dot.f { background: #2ee6c9; box-shadow: 0 0 8px #2ee6c9; }
.answer-card { position: absolute; right: 18px; top: 18px; width: min(340px, 70%); background: var(--card); border-radius: 12px; padding: 12px 16px; border-left: 4px solid var(--amber); box-shadow: 0 10px 30px rgb(0 0 0 / 35%); animation: rise .4s ease-out; font-size: .92rem; }
.answer-card p { margin: 4px 0 0; }
.chip { display: inline-block; background: var(--teal); color: #fff; border-radius: 5px; font-size: .7rem; font-weight: 700; padding: 0 5px; vertical-align: 1px; }
.panel { background: rgb(255 253 248 / 85%); border: 1px solid var(--line); border-radius: 18px; padding: 20px 22px; align-self: start; }
.steps { list-style: none; padding: 0; margin: 0 0 14px; display: flex; flex-wrap: wrap; gap: 6px; counter-reset: s; }
.steps button { border: 1px solid var(--line); background: var(--card); border-radius: 999px; padding: 4px 12px 4px 8px; font-size: .82rem; cursor: pointer; }
.steps li { counter-increment: s; }
.steps button::before { content: counter(s); display: inline-grid; place-items: center; width: 18px; height: 18px; margin-right: 6px; border-radius: 50%; background: var(--line); font-size: .7rem; font-weight: 700; }
.steps button.on { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.steps button.on::before { background: var(--amber); color: var(--ink); }
.panel h1 { font-size: 1.7rem; margin: 8px 0 10px; }
.panel p { margin: 0 0 12px; }
.rrf table { width: 100%; border-collapse: collapse; font-size: .82rem; font-variant-numeric: tabular-nums; }
.rrf th, .rrf td { text-align: left; padding: 4px 6px; border-bottom: 1px solid var(--line); }
.rrf tr.win td { background: var(--teal-soft); font-weight: 600; }
.mode { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 16px; font-size: .85rem; }
.mode button { border: 1px solid var(--line); background: var(--card); border-radius: 8px; padding: 4px 10px; cursor: pointer; }
.mode button.on { background: var(--teal); color: #fff; border-color: var(--teal); }
.nav { display: flex; gap: 8px; margin-top: 18px; }
.nav button { flex: 1; border: 0; border-radius: 10px; padding: 9px; background: var(--ink); color: var(--paper); font-weight: 600; cursor: pointer; }
.nav button:hover { background: var(--teal); }
