/* Complex detail: all tables fit a 360px viewport, including without scripts. */
.complex-detail{min-width:0;overflow-wrap:anywhere}
.complex-detail a,.complex-detail button,.complex-detail summary{min-height:44px}.complex-detail .note a{display:inline;min-height:0}
.complex-detail a{display:inline-flex;align-items:center}
.complex-detail summary{padding:10px 4px;scroll-margin-top:140px}
.complex-detail :focus-visible{outline:3px solid var(--accent);outline-offset:3px}
.complex-detail .facts{grid-template-columns:repeat(auto-fit,minmax(min(200px,100%),1fr))}
.area-panel>summary{border-radius:6px;background:var(--bg);font-size:15px}
.area-panel[open]>summary{color:var(--accent)}
.detail-chart{display:block;width:100%;height:auto;overflow:visible}
.detail-chart text{font-size:11px;fill:var(--mute)}@media(max-width:420px){.detail-chart text{font-size:16px}}
.detail-chart circle{fill:var(--accent)}
.detail-chart .trend{fill:none;stroke:var(--accent);stroke-width:2}
.detail-chart .peak{fill:none;stroke:var(--mute);stroke-width:1;stroke-dasharray:4 3}
.detail-chart .trend.jeonse{stroke:var(--mute);stroke-dasharray:5 3}.detail-chart circle.jeonse{fill:var(--mute)}
.detail-table{width:100%;table-layout:fixed;border-collapse:collapse;font-size:13px;overflow-wrap:anywhere;word-break:normal}
.detail-table caption{text-align:left;color:var(--mute);padding:8px 0;font-size:12px}
.detail-table th,.detail-table td{padding:8px 3px;text-align:left;border-bottom:1px solid var(--line);vertical-align:top}
.detail-table small,.education-list small{display:block;color:var(--mute)}
.detail-table.peers th:first-child{width:30%}.detail-table.peers th:last-child{width:15%}
.complex-detail .tbl{display:table;table-layout:fixed;overflow:visible;width:100%;overflow-wrap:anywhere;word-break:normal}
.detail-action{font-weight:700;margin:4px 0}
.hj-tabs{display:flex;flex-wrap:wrap;gap:6px;margin:4px 0 8px}.hj-tabs[hidden]{display:none}
.hj-tabs button{min-height:44px;padding:0 14px;border:1px solid var(--line);border-radius:999px;background:var(--card);color:var(--ink);font:inherit;font-weight:600;font-variant-numeric:tabular-nums}
.hj-tabs button[aria-pressed="true"]{background:var(--accent);border-color:var(--accent);color:var(--bg)}
/* The sticky header wraps to 177px on phones and is 69px from 560px wide: a #catalysts link must land below it. */
#catalysts{scroll-margin-top:190px}@media(min-width:560px){#catalysts{scroll-margin-top:84px}}
.compare-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.compare-grid article{min-width:0;padding:10px 6px;background:var(--card);border:1px solid var(--line);border-radius:8px}
.compare-grid h2{font-size:14px}.compare-grid dl{font-size:13px}.compare-grid dt{color:var(--mute);margin-top:12px}.compare-grid dd{margin:0}
.detail-movers{padding-left:24px}.detail-movers li{padding:8px 0;border-bottom:1px solid var(--line)}.detail-movers p{margin:0}
#complex-movers,#region-movers{scroll-margin-top:140px}
body:has(.complex-detail) .top a,body:has(.complex-detail) footer a{min-height:44px;display:inline-flex;align-items:center}
@media(prefers-reduced-motion:no-preference){.area-panel[open]>summary{transition:background-color .15s}}
/* A narrow source column must not split 2026-04-01 at its hyphen. */
.hj-date{white-space:nowrap}
/* Surroundings card (surroundings.card + env3d.js). */
.env-list{margin:8px 0;padding-left:18px}.env-list li{margin:4px 0}
#env-view,#plan-view{margin-top:8px}
#plan-3d{margin-top:8px}
.env-stage{position:relative;height:min(78vw,440px);border:1px solid var(--line);border-radius:8px;overflow:hidden;touch-action:pan-y;cursor:grab;background:var(--bg)}
.env-stage canvas{display:block;width:100%;height:100%}
.env-labels{position:absolute;inset:0;pointer-events:none}
.env-labels span{position:absolute;left:0;top:0;white-space:nowrap;font-size:12px;line-height:1.3;padding:2px 6px;border-radius:4px;background:color-mix(in srgb,var(--card) 85%,transparent);color:var(--ink);border:1px solid var(--line)}
.env-labels .home{font-weight:700}.env-labels .plan{color:var(--mute)}
.env-bar{display:flex;flex-wrap:wrap;gap:6px;margin:8px 0}
.env-bar .btn{min-width:44px;min-height:44px}
.env-legend{display:flex;flex-wrap:wrap;gap:4px 12px;list-style:none;margin:4px 0;padding:0;font-size:13px;color:var(--ink)}
.env-legend li{display:inline-flex;align-items:center;gap:6px}
.env-legend i{width:12px;height:12px;border-radius:3px}.env-legend i.line{height:5px;width:16px;opacity:.6}
.around svg{display:block;width:100%;max-width:340px;margin:8px auto;background:var(--bg);border-radius:50%}
.around .ar{fill:none;stroke:var(--line)}.around .at{font-size:10px;fill:var(--mute)}.around svg text{font-size:10px;fill:var(--ink);paint-order:stroke;stroke:var(--bg);stroke-width:3px}
.around .ab{fill:none;stroke-linecap:round;stroke-width:14;opacity:.75}.around .ab.bus{stroke-width:5;opacity:1}.around .am{stroke:var(--card);stroke-width:1.5}.around .ah{fill:var(--ink)}
.around .bigroad{stroke:#64748b}.around .road{stroke:#cbd5e1}.around .ab.road{stroke-width:12}.around .rail{stroke:#b45309}.around .ab.rail{stroke-width:6;opacity:1}.around .play{stroke:#ec4899}.around .conv,.around .super{stroke:#14b8a6}.around .pharm{stroke:#2563eb}.around .ab.super{stroke-linecap:square}.around .ab.conv,.around .ab.super,.around .ab.pharm{stroke-width:5;opacity:1}.around .ab.play{stroke-width:7;opacity:1}.around .park{stroke:#4ade80}.around .water{stroke:#60a5fa}.around .bus{stroke:#f59e0b}
.plan{margin:8px 0}.plan svg{display:block;width:100%;max-width:440px;max-height:440px;margin:0 auto;background:var(--bg);border-radius:8px}.plan .pn{fill:var(--line)}.plan .po{fill:#93c5fd;stroke:#1d4ed8;stroke-width:.6}.plan .pi{stroke:#ea580c;stroke-linecap:round}.plan .pl{stroke:#16a34a;stroke-linecap:square}.plan .pg{fill:none;stroke-dasharray:2 1.5}.plan .pb{stroke:var(--ink);stroke-width:1.5}.plan text{fill:var(--ink);paint-order:stroke;stroke:var(--bg);stroke-width:.25em}.plan figcaption{font-size:12px;color:var(--mute);margin-top:6px}
.around .am.es,.around .am.ms,.around .am.hs{fill:#a855f7}.around .am.station{fill:#ef4444}
.alegend{display:flex;flex-wrap:wrap;gap:4px 12px;font-size:12px;color:var(--mute);margin:4px 0}.alegend span::before{content:"";display:inline-block;width:10px;height:10px;border-radius:50%;margin-right:4px;vertical-align:-1px;background:currentColor}
.alegend .bigroad::before{background:#64748b}.alegend .road::before{background:#cbd5e1}.alegend .rail::before{background:#b45309}.alegend .play::before{background:#ec4899}.alegend .conv::before,.alegend .super::before{background:#14b8a6}.alegend .super::before{border-radius:0}.alegend .pharm::before{background:#2563eb}.alegend .park::before{background:#4ade80}.alegend .water::before{background:#60a5fa}.alegend .bus::before{background:#f59e0b}.alegend .school::before{background:#a855f7}.alegend .station::before{background:#ef4444}.alegend .home::before{background:var(--ink);border-radius:2px}
