/* Player pages (0.51): one centred grid, a top bar, a bar along the bottom. Same tokens as the admin page. */
body.play { height: auto; min-height: 100vh; background: var(--bg); padding-bottom: 84px; }
body.play h1, body.play h2, body.play h3, body.play h4 { font-family: var(--serif); font-weight: 500; letter-spacing: -.01em; }
:root { --wrap: 1312px; --gut: 64px; }
.x-wrap { max-width: calc(var(--wrap) + 2 * var(--gut)); margin: 0 auto; padding: 0 var(--gut); }
.play-main { min-width: 0; }
.x-notes { display: grid; gap: 10px; }
.x-notes > :not([hidden]) { margin-top: 14px; }
.play .muted { color: var(--muted); }
.mono { font-family: var(--mono); }
.pic { position: relative; overflow: hidden; background: var(--panel-3); }
.pic .cover { position: absolute; inset: 0; width: 100%; height: 100%; }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex: none; background: var(--faint); }
.dot.running, .dot.online { background: var(--ok); box-shadow: 0 0 0 3px var(--ok-soft); }
.dot.asleep, .dot.exited { background: var(--sleep); }
.dot.stopped, .dot.held, .dot.missing { background: transparent; border: 1.5px solid var(--faint); }
.dot.starting, .dot.restarting { background: var(--warn); }
.face { image-rendering: pixelated; display: inline-block; vertical-align: middle; border-radius: 2px; }

/* ---- top bar ---- */
.x-top { border-bottom: 1px solid var(--line); background: var(--bg); position: relative; z-index: 3; }
.x-top .x-wrap { display: flex; align-items: center; gap: 36px; height: 60px; }
.a-brand { display: flex; align-items: center; gap: 10px; font: 500 1.45rem var(--serif); text-decoration: none; color: var(--text); flex: none; }
.x-nav { display: flex; gap: 26px; min-width: 0; }
.x-nav a, .x-nav .navlink { text-decoration: none; color: var(--muted); font: 500 .93rem var(--sans); padding: 4px 0; border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: none; box-shadow: none; white-space: nowrap; cursor: pointer; }
.x-nav a:hover, .x-nav .navlink:hover { color: var(--text); background: none; }
.x-nav a.on, .x-nav .navlink.on { color: var(--text); border-bottom-color: var(--accent); }
.a-me { margin-left: auto; display: flex; align-items: center; gap: 8px; font-size: .92rem; min-width: 0; }
.a-me b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 24ch; }
.a-me .muted { margin-left: 6px; padding-left: 10px; border-left: 1px solid var(--line); white-space: nowrap; }
.a-me .x-btn { margin-left: 4px; }
#install-app:not([hidden]) { margin-left: auto; }
#install-app:not([hidden]) + .a-me { margin-left: 0; }

/* ---- buttons: plain and bordered, square corners ---- */
.x-btn, .a-btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 7px 12px; border: 1px solid var(--line-strong); background: var(--panel); color: var(--text);
  border-radius: 3px; font: 500 .86rem var(--sans); text-decoration: none; white-space: nowrap; cursor: pointer; box-shadow: none; }
.x-btn:hover, .a-btn:hover { border-color: var(--muted); background: var(--panel); }
.x-btn.on { color: var(--ok); border-color: var(--ok-line); background: var(--ok-soft); }
.x-btn.sm { padding: 5px 7px; }
.x-btn.ghost { background: transparent; border-color: transparent; }
.x-btn.copied { color: var(--ok); border-color: var(--ok-line); }
.x-btn + .x-btn { margin-left: 6px; }
.a-btn { padding: 8px 14px; border-radius: 3px; font-weight: 600; font-size: .9rem; }
.a-btn.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.a-btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.a-link { text-align: center; font-size: .88rem; color: var(--muted); padding: 4px; background: none; border: 0; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; font-family: var(--sans); }
.a-link:hover { color: var(--text); background: none; }
.a-fav { border: 0; background: none; color: var(--line-strong); padding: 2px; display: inline-flex; box-shadow: none; border-radius: 3px; cursor: pointer; }
.a-fav:hover { background: none; color: var(--muted); }
.a-fav.on { color: #b98a1c; }
.a-fav.on svg { fill: currentColor; }
.a-fav svg { width: 1.1em; height: 1.1em; }
.x-top button:focus-visible, .x-wrap button:focus-visible, .x-bar button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---- home: hero ---- */
.x-hero { position: relative; height: 300px; overflow: hidden; border-bottom: 1px solid var(--line); }
.a-hero-art { position: absolute; inset: 0; background: var(--panel-3); }
.a-hero-art .cover { position: absolute; inset: 0; width: 100%; height: 100%; }
.x-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, var(--bg) 0, color-mix(in srgb, var(--bg) 90%, transparent) 38%, transparent 70%); }
.x-hero-in { position: relative; z-index: 1; padding-top: 42px; }
.a-greet { margin: 0; font: italic 1.15rem var(--serif); color: var(--muted); }
.x-hero h1 { font-size: 3.1rem; line-height: 1.05; letter-spacing: -.02em; margin: 6px 0 24px; max-width: 18ch; }
.a-now { list-style: none; margin: 0; padding: 0; display: flex; gap: 6px; flex-wrap: wrap; }
.a-now a { display: flex; align-items: center; gap: 9px; padding: 5px 12px 5px 5px; background: var(--panel); border: 1px solid var(--line); border-radius: 4px; text-decoration: none; color: var(--text); }
.a-now a:hover { border-color: var(--line-strong); }
.a-now span { display: grid; line-height: 1.15; font-size: .88rem; min-width: 0; }
.a-now small { color: var(--muted); font-size: .76rem; }

/* ---- home: lists ---- */
.x-home { padding-top: 40px; padding-bottom: 60px; }
.x-head { display: flex; align-items: center; gap: 18px; padding-bottom: 14px; border-bottom: 1px solid var(--text); flex-wrap: wrap; }
.x-head h2 { font-size: 1.8rem; }
.x-head .muted { font-size: .9rem; }
.x-allhead { margin-top: 56px; }
.x-allhead .a-seg { margin-left: 8px; }
.x-live { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; padding: 24px 0 0; }
.x-room { display: grid; grid-template-columns: minmax(0, 1fr); border: 1px solid var(--line); border-radius: 4px; background: var(--panel); overflow: hidden; align-content: start; }
.x-room-pic { display: block; height: 150px; }
.x-room-info { padding: 18px 22px 0; min-width: 0; }
.x-room-info h3 { font-size: 1.75rem; display: flex; align-items: center; gap: 10px; min-width: 0; }
.x-room-info h3 a { text-decoration: none; color: var(--text); overflow-wrap: anywhere; }
.x-room-info p { margin: 4px 0 0; overflow-wrap: anywhere; }
.a-meta { color: var(--muted); font-size: .88rem; }
.x-ppl { list-style: none; margin: 14px 0 0; padding: 12px 0 0; border-top: 1px solid var(--panel-2); display: flex; flex-wrap: wrap; gap: 10px 26px; }
.x-ppl li { display: flex; align-items: center; gap: 9px; }
.x-ppl span { display: grid; line-height: 1.2; font-size: .9rem; }
.x-ppl small { color: var(--muted); font-size: .78rem; }
.a-act { display: grid; gap: 8px; grid-template-columns: 1.4fr 1fr auto; align-items: stretch; padding: 18px 22px 20px; }
.a-addr { display: flex; align-items: stretch; text-align: left; border: 0; border-radius: 4px; background: var(--accent); color: var(--accent-ink); padding: 0; overflow: hidden; grid-column: 1; cursor: pointer; min-width: 0; box-shadow: none; }
.a-addr:hover { background: var(--accent-hover); }
.a-addr .mono { flex: 1; padding: 10px 12px; display: flex; align-items: center; font-size: .9rem; min-width: 0; overflow-wrap: anywhere; }
.a-addr-cta { display: flex; align-items: center; gap: 7px; padding: 0 14px; background: var(--accent-hover); font-weight: 600; font-size: .88rem; white-space: nowrap; }
.a-addr.copied .a-addr-cta { background: var(--ok); }
.x-room .a-btn { grid-column: 2; }
.x-room .a-link { grid-column: 3; align-self: center; padding: 0 6px; }

/* panels */
.x-panels { display: grid; grid-template-columns: 1fr 1.2fr 1fr; gap: 24px; margin-top: 24px; }
.x-panel { background: var(--panel); border: 1px solid var(--line); border-radius: 4px; padding: 18px 20px; min-width: 0; }
.x-ph { display: flex; align-items: baseline; gap: 10px; margin-bottom: 12px; }
.x-ph h3 { font-size: 1.15rem; }
.x-ph a, .x-ph .muted { margin-left: auto; font-size: .82rem; color: var(--muted); }
.x-ev { display: flex; gap: 12px; align-items: center; padding: 12px 0; border-top: 1px solid var(--panel-2); }
.x-ph + .x-ev { border-top: 0; padding-top: 0; }
.x-ev-t { display: grid; flex: 1; font-size: .9rem; line-height: 1.35; min-width: 0; overflow-wrap: anywhere; }
.x-ev-t small { color: var(--muted); font-size: .8rem; }
.x-ev-t a { color: inherit; }
.a-cal { flex: none; width: 46px; height: 50px; display: grid; place-content: center; text-align: center; background: var(--accent); color: var(--accent-ink); border-radius: 3px; font-size: .74rem; line-height: 1.1; }
.a-cal b { font: 500 1.3rem var(--serif); }
.a-going { display: flex; align-items: center; gap: 3px; flex-wrap: wrap; }
.x-feed, .x-jump { width: 100%; border-collapse: collapse; font-size: .88rem; }
.x-feed td, .x-jump td { padding: 7px 0; border-top: 1px solid var(--panel-2); vertical-align: middle; }
.x-feed tr:first-child td, .x-jump tr:first-child td { border-top: 0; }
.x-feed td:first-child { width: 30px; }
.x-feed td:last-child { text-align: right; color: var(--muted); font-size: .78rem; white-space: nowrap; padding-left: 10px; }
.x-feed td:nth-child(2) { overflow-wrap: anywhere; }
.x-jump a { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); min-width: 0; }
.x-jump td:nth-child(2), .x-jump td:nth-child(3) { text-align: right; font-weight: 600; padding-left: 8px; white-space: nowrap; }
.x-jump td:last-child { text-align: right; width: 40px; }
.x-jump small { display: block; font-weight: 400; color: var(--muted); font-size: .74rem; }
.x-mini { width: 30px; height: 30px; border-radius: 2px; flex: none; }
.x-empty { padding: 30px 0; color: var(--muted); }

/* filters and the table */
.a-seg { display: flex; border: 1px solid var(--line-strong); border-radius: 4px; overflow: hidden; }
.a-seg button { border: 0; border-radius: 0; background: var(--panel); padding: 6px 13px; font: 500 .88rem var(--sans); color: var(--muted); box-shadow: none; }
.a-seg button + button { border-left: 1px solid var(--line-strong); }
.a-seg button span { color: var(--muted); margin-left: 3px; }
.a-seg button.on { background: var(--accent); color: var(--accent-ink); }
.a-seg button.on span { color: var(--accent-line); }
.a-search { margin-left: auto; display: flex; align-items: center; gap: 8px; border: 1px solid var(--line-strong); border-radius: 4px; padding: 0 10px; background: var(--panel); color: var(--muted); }
.a-search input { border: 0; background: none; padding: 7px 0; font: inherit; width: 180px; outline: none; color: var(--text); box-shadow: none; }
.x-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.x-table th { text-align: left; font-weight: 500; font-size: .8rem; color: var(--muted); padding: 12px 16px 8px 0; }
.x-table td { padding: 10px 16px 10px 0; border-top: 1px solid var(--line); vertical-align: middle; }
.x-table tr:last-child td { border-bottom: 1px solid var(--line); }
.x-table small { display: block; color: var(--muted); font-size: .8rem; overflow-wrap: anywhere; }
.x-table td:nth-child(2) { width: 34%; overflow-wrap: anywhere; }
.x-table td:nth-child(3) { width: 14%; }
.x-table td:nth-child(4) { width: 24%; }
.x-table td:nth-child(5) { width: 8%; }
.x-table .q-a { padding-right: 0; text-align: right; white-space: nowrap; }
.q-pic { width: 86px; }
.q-pic a { display: block; width: 72px; height: 40px; border-radius: 2px; overflow: hidden; }
.q-name { font: 500 1.12rem var(--serif); text-decoration: none; margin-right: 4px; color: var(--text); }

/* ---- world page ---- */
.aw-hero { position: relative; height: 380px; overflow: hidden; background: var(--panel-3); }
.aw-art { position: absolute; inset: 0; }
.aw-art .cover { position: absolute; inset: 0; width: 100%; height: 100%; }
.aw-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgb(20 16 10 / 0) 35%, rgb(20 16 10 / .72)); }
.x-whero { position: absolute; inset: 0; z-index: 1; display: flex; align-items: flex-end; padding-bottom: 36px; color: #fbf8f1; left: 0; right: 0; }
.x-whero > div:not(.x-whero-r) { min-width: 0; }
.x-whero h1 { font-size: 4.6rem; line-height: 1; letter-spacing: -.025em; text-shadow: 0 2px 20px rgb(0 0 0 / .3); overflow-wrap: anywhere; }
.x-whero p { margin: 10px 0 0; font-size: 1.12rem; opacity: .92; overflow-wrap: anywhere; }
.aw-back2 { position: absolute; top: 28px; display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px 6px 8px; background: rgb(253 250 244 / .92); color: #231f19; border-radius: 3px; text-decoration: none; font-size: .88rem; font-weight: 500; }
.x-whero-r { margin-left: auto; }
.x-onfaces { display: flex; align-items: center; gap: 4px; padding: 8px 14px 8px 8px; background: rgb(253 250 244 / .94); color: #231f19; border-radius: 3px; }
.x-onfaces b { margin-left: 8px; color: #237249; }
.aw-nav { position: sticky; top: 0; z-index: 5; background: var(--bg); border-bottom: 1px solid var(--line); }
.aw-nav > .x-wrap { display: flex; gap: 30px; align-items: center; }
.aw-nav a { text-decoration: none; color: var(--muted); padding: 14px 0 12px; font-weight: 500; font-size: .93rem; border-bottom: 2px solid transparent; display: inline-flex; gap: 7px; align-items: center; white-space: nowrap; }
.aw-nav a.on { color: var(--text); border-bottom-color: var(--accent); }
.aw-navr { margin-left: auto; display: flex; align-items: center; gap: 18px; }
.x-wbody { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 64px; padding-top: 36px; padding-bottom: 60px; }
.x-wbody main { min-width: 0; }
.x-wbody main > section { padding-bottom: 44px; margin-bottom: 40px; border-bottom: 1px solid var(--line); }
.x-wbody main > section:last-child { border-bottom: 0; }
.x-wl, .x-wbody .notice { display: block; margin: 0 0 26px; padding: 12px 16px; background: var(--ok-soft); border: 1px solid var(--ok-line); border-radius: 3px; font-size: .92rem; }
.x-wl svg, .x-wbody .notice svg { color: var(--ok); vertical-align: -.18em; margin-right: 4px; }
.x-wl.warn, .x-wbody .notice.warn { background: var(--warn-soft); border-color: var(--warn-line); }
.x-wl.warn svg, .x-wbody .notice.warn svg { color: var(--warn); }
.x-wbody .notice.info { background: var(--panel-2); border-color: var(--line); }
.x-wl .x-btn, .x-wbody .notice button { margin-left: 8px; }
.x-wl .wake { margin-left: 8px; }
.aw-join > h2, .aw-h h2 { font-size: 1.8rem; }
.aw-join > p { margin: 6px 0 20px; max-width: 64ch; }
.aw-ways { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--line-strong); border-radius: 4px; }
.aw-way { padding: 22px 24px 24px; display: flex; flex-direction: column; min-width: 0; }
.aw-way + .aw-way { border-left: 1px solid var(--line-strong); background: var(--panel-2); }
.aw-way.rec { background: var(--panel); }
.aw-way h3 { font-size: 1.2rem; display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.aw-way h3 span { font: 600 .74rem var(--sans); color: var(--ok); background: var(--ok-soft); padding: 2px 7px; border-radius: 2px; }
.aw-way ol { margin: 14px 0 20px; padding-left: 1.3em; display: grid; gap: 8px; flex: 1; }
.aw-way ol li { overflow-wrap: anywhere; }
.aw-way ol a { color: var(--accent); }
.aw-way .a-btn { align-self: flex-start; }
.x-plain { margin-top: 14px; padding: 18px 20px; border: 1px solid var(--line-strong); border-radius: 4px; background: var(--panel); }
.aw-h { display: flex; align-items: baseline; gap: 16px; margin-bottom: 16px; flex-wrap: wrap; }
.aw-h .x-btn { margin-left: auto; }
.aw-sec details.join { border: 0; padding: 0; margin: 0; }
.aw-sec details.join > summary { display: none; }
.aw-sec .chat-log { max-height: 360px; border: 1px solid var(--line); border-radius: 4px; background: var(--panel); padding: 8px 14px; }
.aw-sec .chat-send { padding: 10px; border: 1px solid var(--line); border-top: 0; background: var(--panel-2); margin-top: 0; }
.aw-sec .chat-send input { border: 1px solid var(--line-strong); border-radius: 3px; background: var(--panel); }
.aw-sec .place { border-radius: 3px; }
.aw-sec .shots { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.aw-sec .shot { border-radius: 3px; }
.aw-sec button, .aw-sec .btnlink { border-radius: 3px; }
.aw-rail { min-width: 0; }
.aw-rail section { padding-bottom: 24px; margin-bottom: 24px; border-bottom: 1px solid var(--line); }
.aw-rail h3 { font-size: 1.12rem; margin-bottom: 14px; }
.aw-on { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.aw-on li { display: flex; align-items: center; gap: 10px; }
.aw-on span { margin-left: auto; color: var(--muted); font-size: .85rem; }
.aw-rank { margin: 0; padding: 0; list-style: none; counter-reset: r; display: grid; gap: 8px; font-size: .92rem; }
.aw-rank li { counter-increment: r; display: flex; align-items: center; gap: 10px; }
.aw-rank li::before { content: counter(r); width: 14px; color: var(--muted); font-size: .82rem; }
.aw-rank li b { margin-left: auto; font-weight: 600; }
.aw-rank li.me span { font-weight: 600; }
.aw-dl { display: grid; grid-template-columns: 1fr auto; margin: 0; font-size: .9rem; }
.aw-dl dt { color: var(--muted); padding: 6px 0; border-top: 1px solid var(--panel-3); }
.aw-dl dd { margin: 0; padding: 6px 0; border-top: 1px solid var(--panel-3); text-align: right; font-weight: 500; overflow-wrap: anywhere; }
.aw-dl dt:first-of-type, .aw-dl dd:first-of-type { border-top: 0; }
.aw-rail .x-ev { border-top: 0; padding: 0; align-items: flex-start; }
.aw-manage { padding-top: 0; }
.x-gone { padding-top: 90px; padding-bottom: 120px; max-width: 760px; }
.x-gone h1 { font-size: 2.6rem; }
.x-gone p { color: var(--muted); margin: 10px 0 22px; max-width: 56ch; }

/* ---- setup page ---- */
.st-head { padding-top: 30px; padding-bottom: 26px; border-bottom: 1px solid var(--line); }
.st-crumb { display: inline-flex; align-items: center; gap: 5px; font-size: .88rem; color: var(--muted); text-decoration: none; }
.st-head h1 { font-size: 2.9rem; letter-spacing: -.02em; margin: 10px 0 6px; overflow-wrap: anywhere; }
.st-head p { margin: 0; color: var(--muted); font-size: 1.02rem; }
.st-body { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 64px; padding-top: 12px; padding-bottom: 60px; align-items: start; }
.st-body main { min-width: 0; }
.st-step { display: grid; grid-template-columns: 56px minmax(0, 1fr); padding: 30px 0; border-bottom: 1px solid var(--line); }
.st-n { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--text); border-radius: 3px; font: 500 1.15rem var(--serif); }
.st-step h2 { font-size: 1.55rem; display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.st-step > div > p { margin: 6px 0 16px; color: var(--muted); max-width: 66ch; }
.st-opt { font: 500 .8rem var(--sans); color: var(--muted); border: 1px solid var(--line-strong); padding: 1px 7px; border-radius: 2px; }
.st-row { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.st-small { margin: 12px 0 0; font-size: .86rem; color: var(--muted); overflow-wrap: anywhere; }
.st-pin { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto auto; gap: 18px; align-items: center; padding: 14px 18px 14px 14px; border: 1px solid var(--accent-line); background: var(--accent-soft); border-radius: 4px; }
.st-pin-pic { width: 64px; height: 64px; border-radius: 3px; }
.st-pin b { display: block; font: 500 1.35rem var(--serif); overflow-wrap: anywhere; }
.st-pin span { font-size: .88rem; color: var(--muted); }
.st-pin .st-tag { font-size: .8rem; font-weight: 600; color: var(--accent); border: 1px solid var(--accent-line); background: var(--panel); padding: 3px 9px; border-radius: 2px; }
.st-g { font: 600 .86rem var(--sans); color: var(--muted); margin: 20px 0 6px; }
.st-list { border-top: 1px solid var(--line); }
.st-x { display: grid; grid-template-columns: 22px minmax(0, 1fr) 140px; gap: 14px; align-items: center; padding: 12px 10px; border-bottom: 1px solid var(--line); cursor: pointer; }
.st-x:hover { background: var(--panel); }
.st-x.on { background: color-mix(in srgb, var(--accent-soft) 60%, transparent); }
.st-x input { width: 18px; height: 18px; accent-color: var(--accent); margin: 0; }
.st-x-t b { display: block; font-weight: 600; overflow-wrap: anywhere; }
.st-x-t small { color: var(--muted); font-size: .86rem; }
.st-x-k { text-align: right; font-size: .84rem; color: var(--muted); }
.st-x-k small { display: block; color: var(--muted); font-size: .78rem; }
.st-find { margin: 0 0 8px; }
.st-ol { margin: 6px 0 18px; padding-left: 1.2em; display: grid; gap: 7px; }
.st-addr { display: inline-flex; border: 1px solid var(--line-strong); border-radius: 3px; overflow: hidden; background: var(--panel); max-width: 100%; }
.st-addr .mono { padding: 10px 16px; font-size: 1.05rem; overflow-wrap: anywhere; min-width: 0; }
.st-link { display: flex; margin: 8px 0; }
.st-link .mono { flex: 1; font-size: .82rem; padding: 9px 12px; }
.st-link button { flex: none; white-space: nowrap; }
.st-addr button { border: 0; border-left: 1px solid var(--accent); background: var(--accent); color: var(--accent-ink); padding: 0 16px; font-weight: 600; display: flex; gap: 7px; align-items: center; border-radius: 0; box-shadow: none; }
.st-hand { margin-top: 26px; padding: 0 0 0 56px; }
.st-hand summary { cursor: pointer; font-weight: 600; padding: 6px 0; }
.st-hand[open] summary { margin-bottom: 8px; }
.st-side { position: sticky; top: 24px; margin-top: 30px; padding: 22px 22px 20px; background: var(--panel); border: 1px solid var(--line-strong); border-radius: 4px; }
.st-side h3 { font-size: 1.3rem; margin-bottom: 12px; }
.st-sum { list-style: none; margin: 0; padding: 0; font-size: .9rem; }
.st-sum li { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-top: 1px solid var(--panel-2); }
.st-sum li:first-child { border-top: 0; font-weight: 600; }
.st-sum li span { min-width: 0; overflow-wrap: anywhere; }
.st-sum b { font-weight: 500; color: var(--muted); white-space: nowrap; }
.st-total { display: flex; justify-content: space-between; margin: 6px 0 16px; padding-top: 10px; border-top: 1px solid var(--text); font-weight: 600; }
.st-dl { width: 100%; padding: 12px 14px; font-size: .95rem; white-space: normal; }
.st-note { margin: 12px 0 0; font-size: .82rem; color: var(--muted); }
.st-tip { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; margin: 4px 0 8px; padding: 14px 16px; border: 1px solid var(--accent-line); border-left: 3px solid var(--accent); background: var(--panel); border-radius: 3px; }
.st-tip > svg { color: var(--accent); width: 20px; height: 20px; }
.st-tip p { margin: 3px 0 0; font-size: .88rem; color: var(--muted); max-width: 62ch; }

/* personal extras (0.53): search, "Yours", the private Prism link */
.st-search { display: flex; gap: 8px; margin: 4px 0 8px; }
.st-search input { flex: 1; min-width: 0; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); background: var(--panel); color: var(--text); font: inherit; }
.st-search input:focus-visible, .st-kind:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.st-kinds { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 10px; }
.st-kind { border: 1px solid var(--line-strong); background: var(--panel); color: var(--text); padding: 6px 12px; border-radius: var(--radius-sm); font: 500 .88rem var(--sans); cursor: pointer; box-shadow: none; }
.st-kind.on { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.st-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.st-mine { grid-template-columns: minmax(0, 1fr) 130px auto; cursor: default; }
.st-mine:hover { background: transparent; }
.st-mine.on:hover { background: color-mix(in srgb, var(--accent-soft) 60%, transparent); }
.st-mine.dim .st-x-t b { color: var(--muted); }
.st-mine .a-btn, .st-mine .st-rm { white-space: nowrap; }
.st-rm { display: inline-flex; align-items: center; gap: 5px; font-size: .86rem; }
.st-x-t .st-warn, .st-warn { display: flex; gap: 5px; align-items: flex-start; color: var(--warn); }
.st-x-t .st-warn svg { flex: none; margin-top: 2px; }
.st-no { color: var(--bad); }
.st-count { margin: 10px 0 0; }
.st-warnbox { margin: 8px 0; padding: 10px 14px; border: 1px solid var(--warn-line); border-left: 3px solid var(--warn); background: var(--warn-soft); border-radius: var(--radius-sm); color: var(--text); max-width: 66ch; }
.st-warnbox b { font-weight: 600; }
.st-install-choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 12px; margin: 16px 0; }
.st-install-choice { display: block; text-align: left; padding: 16px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); background: var(--panel); color: var(--text); cursor: pointer; font: inherit; box-shadow: none; }
.st-install-choice b { display: block; margin-bottom: 6px; }
.st-install-choice span { display: block; font-size: .9rem; color: var(--muted); }
.st-install-choice.on { border: 2px solid var(--accent); padding: 15px; background: var(--accent-soft); }
.st-install-choice:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.st-link-details { margin: 12px 0; }
.st-link-details summary { cursor: pointer; font-size: .9rem; }
[data-install-panel] { scroll-margin-top: 24px; }
[data-link-box] .st-link .mono { font-size: .9rem; }
[data-link-box] .st-ol { margin-top: 12px; }
[data-link-box] .st-link { display: flex; }

/* ---- the bar along the bottom ---- */
.x-bar { position: fixed; inset: auto 0 0; z-index: 20; background: var(--bar-bg); color: var(--bar-ink); border-top: 1px solid var(--bar-line); }
.x-bar .x-wrap { display: flex; align-items: center; gap: 22px; height: 72px; }
.x-bar-w { display: flex; align-items: center; gap: 12px; min-width: 250px; text-decoration: none; color: inherit; }
.x-bar-pic { width: 46px; height: 46px; border-radius: 3px; flex: none; }
.x-bar-w > span { display: grid; line-height: 1.25; min-width: 0; }
.x-bar-w em { font-style: normal; font-size: .72rem; color: var(--bar-muted); }
.x-bar-w b { font: 500 1.2rem var(--serif); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.x-bar-w small, .x-bar-v small { color: var(--bar-muted); font-size: .8rem; display: flex; align-items: center; gap: 6px; }
.x-bar-w small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }
.x-bar .dot.running, .x-bar .dot.online { box-shadow: none; background: #5fc48a; }
.x-bar-v { display: grid; font-size: .88rem; line-height: 1.3; padding-left: 22px; border-left: 1px solid var(--bar-line); min-width: 0; }
.x-bar-addr { margin-left: auto; display: flex; align-items: stretch; border: 1px solid var(--bar-line); border-radius: 3px; overflow: hidden; min-width: 0; }
.x-bar-addr .mono { padding: 10px 14px; font-size: 1rem; background: rgb(255 255 255 / .06); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.x-bar-addr button { border: 0; border-radius: 0; background: var(--panel); color: var(--text); padding: 0 14px; font: 600 .88rem var(--sans); display: flex; gap: 7px; align-items: center; box-shadow: none; white-space: nowrap; }
.x-bar-addr button.copied { background: #cfe8d6; color: #1a2010; }
.x-bar-btn { border: 0; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; padding: 11px 16px; background: var(--bar-go); color: #fff; border-radius: 3px; font: 600 .88rem var(--sans); text-decoration: none; white-space: nowrap; box-shadow: none; }
.x-bar-btn:hover { background: #7b9a50; }

/* ---- phones ---- */
@media (max-width: 1100px) {
  .x-live { grid-template-columns: 1fr; }
  .x-panels { grid-template-columns: 1fr 1fr; }
  .x-panels .x-panel:last-child { grid-column: 1 / -1; }
}
@media (max-width: 900px) {
  :root { --gut: 32px; }
  .x-wbody, .st-body { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  /* one column: the header, Join, the side panels, then chat, places, screenshots and stats */
  .x-wbody { display: flex; flex-direction: column; }
  .x-wbody main { display: contents; }
  .x-wbody main > section { order: 3; }
  .x-wbody main > #join { order: 1; }
  .aw-rail { order: 2; }
  .x-whero h1 { font-size: 3.4rem; }
  .st-side { position: static; margin: 8px 0 20px; }
  .x-bar-v { display: none; }
}
@media (max-width: 760px) {
  :root { --gut: 16px; }
  body.play { font-size: 15px; }
  .x-top .x-wrap { flex-wrap: wrap; height: auto; padding-top: 10px; padding-bottom: 0; gap: 8px 16px; }
  .x-nav { order: 3; width: 100%; overflow-x: auto; gap: 20px; padding-bottom: 2px; scrollbar-width: none; }
  .x-nav::-webkit-scrollbar { display: none; }
  .a-me .muted { display: none; }
  .x-hero { height: auto; }
  .x-hero::after { background: linear-gradient(180deg, color-mix(in srgb, var(--bg) 94%, transparent) 0, color-mix(in srgb, var(--bg) 85%, transparent) 60%, color-mix(in srgb, var(--bg) 50%, transparent)); }
  .x-hero-in { padding-top: 22px; padding-bottom: 20px; }
  .x-hero h1 { font-size: 2rem; margin-bottom: 16px; }
  .a-now { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
  .a-now::-webkit-scrollbar { display: none; }
  .a-now a { white-space: nowrap; }
  .x-home { padding-top: 26px; }
  .x-head { gap: 6px 12px; }
  .x-head h2 { font-size: 1.5rem; }
  .x-live, .x-panels { grid-template-columns: 1fr; gap: 16px; }
  .x-room-pic { height: 120px; }
  .x-room-info h3 { font-size: 1.5rem; }
  .a-act { grid-template-columns: 1fr 1fr; }
  .a-addr { grid-column: 1 / -1; }
  .x-room .a-btn { grid-column: 1; }
  .x-room .a-link { grid-column: 2; }
  .x-allhead { margin-top: 36px; }
  .x-allhead .a-seg { margin-left: 0; }
  .x-allhead .a-search { margin-left: 0; width: 100%; }
  .x-allhead .a-search input { width: 100%; }
  .x-table thead { display: none; }
  .x-table, .x-table tbody { display: block; }
  .x-table tr { display: grid; grid-template-columns: 64px minmax(0, 1fr); column-gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
  .x-table td { border: 0 !important; padding: 0; width: auto !important; }
  .x-table td.q-pic { grid-row: 1 / 5; width: 64px !important; }
  .x-table td.q-pic a { width: 64px; height: 40px; }
  .x-table td:nth-child(n+3) { grid-column: 2; font-size: .86rem; }
  .x-table td:nth-child(3) small, .x-table td:nth-child(5) { display: none; }
  .x-table td.q-a { text-align: left; margin-top: 8px; white-space: normal; }
  .x-btn { padding: 8px 12px; }
  .x-bar .x-wrap { height: 64px; gap: 10px; }
  .x-bar-w { min-width: 0; flex: 0 0 auto; }
  .x-bar-w > span:not(.pic), .x-bar-v, .x-bar-addr .mono { display: none; }
  .x-bar-pic { width: 38px; height: 38px; }
  .x-bar-addr { margin-left: auto; }
  .x-bar-addr button { padding: 10px 12px; }
  .x-bar-btn { padding: 10px 12px; }
  .x-bar-btn svg { display: none; }
  .aw-hero { height: 280px; }
  .x-whero { flex-direction: column; align-items: flex-start; justify-content: flex-end; padding-bottom: 18px; gap: 10px; }
  .x-whero h1 { font-size: 2.6rem; }
  .x-whero p { font-size: .98rem; }
  .x-whero-r { margin-left: 0; }
  .aw-back2 { position: static; align-self: flex-start; margin-bottom: auto; margin-top: 14px; }
  .aw-nav > .x-wrap { overflow-x: auto; gap: 22px; scrollbar-width: none; }
  .aw-nav > .x-wrap::-webkit-scrollbar { display: none; }
  .aw-navr { gap: 14px; }
  .x-wbody { padding-top: 22px; }
  .x-wbody main > section { padding-bottom: 28px; margin-bottom: 26px; }
  .aw-join > h2, .aw-h h2 { font-size: 1.5rem; }
  .aw-ways { grid-template-columns: 1fr; }
  .aw-way + .aw-way { border-left: 0; border-top: 1px solid var(--line-strong); }
  .st-head h1 { font-size: 2.1rem; }
  .st-step { grid-template-columns: 34px minmax(0, 1fr); gap: 12px; padding: 24px 0; }
  .st-n { width: 30px; height: 30px; font-size: 1rem; }
  .st-step h2 { font-size: 1.35rem; }
  .st-pin { grid-template-columns: 52px minmax(0, 1fr); }
  .st-pin-pic { width: 52px; height: 52px; }
  .st-pin .st-tag, .st-pin .a-link { grid-column: 2; justify-self: start; }
  .st-tip { grid-template-columns: minmax(0, 1fr); }
  .st-tip > svg { display: none; }
  .st-x { grid-template-columns: 22px minmax(0, 1fr); }
  .st-x-k { grid-column: 2; text-align: left; }
  .st-x-k small { display: inline; margin-left: 6px; }
  .st-mine { grid-template-columns: minmax(0, 1fr) auto; }
  .st-mine .st-x-k { grid-column: 1; }
  .st-mine .a-btn, .st-mine .st-rm { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
  .st-link { flex-direction: column; }
  .st-link .mono { word-break: break-all; }
  .st-link button { justify-content: center; padding: 10px 14px; border-left: 0; }
  .st-search { flex-wrap: wrap; }
  .st-search .a-btn { flex: 1 1 100%; justify-content: center; }
  .st-addr { display: flex; }
  .st-addr .mono { flex: 1; font-size: .95rem; }
  .st-hand { padding-left: 0; }
  .x-gone { padding-top: 50px; }
  .x-gone h1 { font-size: 2rem; }
}
@media (max-width: 520px) { .x-top .hide-sm, .a-me .hide-sm { display: none; } }
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; } }

/* ---- sign in / account setup ---- */
.play-gate { display: grid; place-items: center; padding: 4vh 0 24px; }
.play-gate .gate-card p.small { margin: 1em 0 0; text-align: center; }
.play-gate form p.muted:not(.small) { margin-top: -.4em; }
#password-form .dialog-actions { flex-wrap: wrap; }

.linkbtn { background: none; border: 0; padding: 0; color: var(--accent); text-decoration: underline; text-underline-offset: 2px; font: inherit; cursor: pointer; }
.linkbtn:hover { background: none; }
.play-gate .notice { font-size: .88rem; padding: 9px 12px; border-radius: 10px; display: flex; gap: 8px; align-items: flex-start; margin-top: 10px; }
.play-gate .notice.ok { background: var(--accent-soft); border: 1px solid var(--accent-line); }
.acct-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.acct-head h2 { margin: 0; }
.acct-part { border-top: 1px solid var(--line); padding-top: 12px; margin-top: 12px; }
.acct-part h3 { margin: 0 0 .4em; font-size: 1rem; }
#account-dlg { max-height: min(92vh, 900px); overflow-y: auto; }
.mc-note { align-items: center; flex-wrap: wrap; gap: 10px; }
.mc-note span { flex: 1 1 200px; }
.mc-found { display: flex; gap: 12px; align-items: center; padding: 10px 12px; margin: 0 0 8px; border: 1px solid var(--accent-line);
  background: var(--accent-soft); border-radius: 12px; }
.mc-head { border-radius: 8px; image-rendering: pixelated; flex: none; }
.mc-row { display: flex; gap: 10px; align-items: center; justify-content: space-between; }
.mc-row > span { display: flex; gap: 10px; align-items: center; min-width: 0; }
#mc-dlg { width: min(440px, calc(100% - 32px)); }

/* ---- live map ---- */
.map-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 10px 0; }
.map-row .small { font-size: .85rem; }
.foot-btns { display: inline-flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.tag .ico { width: 12px; height: 12px; vertical-align: -1px; margin-right: 3px; }
/* the "map coming soon" page */
body.map-wait { min-height: 100vh; display: grid; place-items: center; padding: 16px; margin: 0; }
.map-wait-box { max-width: 420px; text-align: center; background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius, 14px); padding: 24px 20px; }
.map-wait-box h1 { font-size: 1.3rem; margin: 0 0 8px; }

/* ---- stats ---- */
.public-stats { margin-top: 4px; min-width: 0; }
.stats-tabs { display: flex; gap: 26px; margin: 0 0 22px; border-bottom: 1px solid var(--line); }
.stats-tabs button { border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: none; box-shadow: none; padding: 8px 0 9px; margin-bottom: -1px; color: var(--muted); font: 500 .93rem var(--sans); cursor: pointer; }
.stats-tabs button:hover { color: var(--text); background: none; }
.stats-tabs button[aria-pressed="true"] { color: var(--text); border-bottom-color: var(--accent); }
.public-stats h4 { font-size: 1.05rem; margin: 26px 0 10px; }
.public-stats h3 { font-size: 1.5rem; margin: 6px 0 16px; }
.stats-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); margin: 0; border: 1px solid var(--line); border-radius: 4px; background: var(--panel); }
.stats-facts > div { padding: 14px 16px 15px; min-width: 0; border-left: 1px solid var(--line); border-top: 1px solid var(--line); margin: -1px 0 0 -1px; }
.stats-facts dt { font-size: .76rem; color: var(--muted); letter-spacing: .02em; }
.stats-facts dd { margin: 3px 0 0; font: 500 1.55rem/1.15 var(--serif); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.st-note { margin: 12px 0 0; color: var(--muted); font-size: .9rem; }
.st-note b { color: var(--text); font-weight: 600; }
.public-stats > div > .muted.small, .public-stats .small.muted { margin: 10px 0 0; }
.st-lists, .boards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; min-width: 0; }
.st-lists { margin-top: 8px; }
.st-lists .st-list, .board { border: 1px solid var(--line); border-radius: 4px; background: var(--panel); padding: 14px 16px 12px; min-width: 0; }
.st-list h4, .board h4 { margin: 0 0 8px; font-size: 1rem; }
.st-list ol, .board ol { list-style: none; margin: 0; padding: 0; }
.st-list li, .board li { position: relative; display: flex; align-items: center; gap: 10px; padding: 6px 8px; margin: 2px 0; min-width: 0; overflow: hidden; border-radius: 3px; }
.st-list li .who, .board li .who { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; position: relative; z-index: 1; text-align: left; }
.st-list li b, .board li b { position: relative; z-index: 1; white-space: nowrap; font-variant-numeric: tabular-nums; font-weight: 600; }
.st-list li .bar, .board li .bar { position: absolute; left: 0; top: 0; bottom: 0; max-width: 100%; background: var(--accent); opacity: .11; z-index: 0; border-radius: 3px; }
.board li .pos { width: 1.4em; text-align: center; font-weight: 600; color: var(--muted); position: relative; z-index: 1; font-variant-numeric: tabular-nums; }
.board li.r1 .pos { color: #b98a1c; } .board li.r2 .pos { color: #7d8790; } .board li.r3 .pos { color: #a8683a; }
.board li.r1 .who { font-weight: 600; }
.boards-more { margin-top: 18px; }
.boards-more > summary, .board-more > summary, .more-boards > summary { cursor: pointer; color: var(--muted); font-size: .88rem; padding: 4px 0; }
.boards-more > summary { font-weight: 600; margin: 0 0 12px; }
.boards-more[open] > summary { margin-bottom: 14px; }
.board-more { margin-top: 4px; }
.st-plain { margin: 0; padding-left: 1.2em; display: grid; gap: 4px; font-size: .92rem; }
.st-back { text-align: left; padding: 0; }
.public-stats > div > .st-list { margin-top: 18px; }
.public-stats .st-plain + .muted { margin-top: 12px; }
.pl-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin: 0 0 10px; }
.pl-tools input { flex: 1 1 220px; min-width: 0; }
.stats-players { list-style: none; margin: 0 0 12px; padding: 0; border-top: 1px solid var(--line); }
.stats-players li { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: baseline; gap: 12px; padding: 9px 2px; border-bottom: 1px solid var(--line); min-width: 0; }
.stats-players li > :first-child { text-align: left; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; justify-self: start; max-width: 100%; font-weight: 600; }
.stats-players .pl-played { text-align: right; font-variant-numeric: tabular-nums; min-width: 4em; }
.stats-players li > :last-child { white-space: nowrap; min-width: 9.5em; }
.stats-players .a-link { text-decoration: none; padding: 0; text-align: left; }
.stats-players .a-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.stats-players li > :last-child { text-align: right; }
@media (max-width: 560px) {
  .stats-tabs { gap: 20px; }
  .stats-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats-facts dd { font-size: 1.35rem; }
  .st-lists, .boards { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .stats-players li { grid-template-columns: minmax(0, 1fr) auto; row-gap: 0; }
  .stats-players li > :last-child { grid-column: 1 / -1; text-align: left; }
}

.manage-box { margin-top:12px; border:1px solid var(--line, #667755); border-radius:8px; padding:8px 12px; }
.manage-box > summary { cursor:pointer; font-weight:bold; }
.manage-body section { margin:12px 0; }
.manage-body h4 { margin:0 0 6px; }
.manage-actions { display:flex; flex-wrap:wrap; gap:8px; }
.manage-list { list-style:none; margin:0; padding:0; }
.manage-list li { display:flex; justify-content:space-between; align-items:center; gap:8px; padding:4px 0; flex-wrap:wrap; }
.manage-add { display:flex; gap:8px; margin-top:8px; }
.manage-add input { flex:1; min-width:0; }
.manage-log { max-height:260px; overflow:auto; font-size:.75rem; white-space:pre-wrap; word-break:break-all; background:rgba(0,0,0,.25); padding:8px; border-radius:6px; }

/* Manage panel: sections a manager opens one at a time. Built for a 320px phone first. */
.manage-body { min-width: 0; }
.manage-body * { min-width: 0; }
.manage-body select, .manage-body input:not([type="checkbox"]) { max-width: 100%; }
.manage-sub, .manage-sub-inner { border-top: 1px solid var(--line); padding: 8px 0; }
.manage-sub > summary { cursor: pointer; font-weight: 700; padding: 4px 0; }
.manage-sub-inner > summary { cursor: pointer; font-size: .9rem; padding: 2px 0; }
.manage-sub h5 { margin: 14px 0 6px; font-size: .92rem; }
.manage-sub .tag { margin-left: 4px; }
.manage-form { display: flex; flex-direction: column; gap: 10px; margin: 10px 0; }
.manage-form label { display: flex; flex-direction: column; gap: 4px; font-size: .9rem; }
.manage-form label.check { flex-direction: row; align-items: center; gap: 8px; }
.manage-form[data-mod-search] { flex-direction: row; flex-wrap: wrap; }
.manage-form[data-mod-search] input { flex: 1 1 140px; }
.manage-body .callout { padding: 8px 10px; margin: 8px 0; border-radius: 8px; background: var(--warn-soft); border: 1px solid var(--warn-line); font-size: .9rem; }
.manage-body .callout.bad-callout { background: var(--bad-soft); border-color: var(--bad); }
.manage-pending { padding: 10px 12px; border-radius: 10px; background: var(--accent-soft); border: 1px solid var(--accent-line); }
.manage-pending p { margin: 4px 0 10px; }
.manage-table-wrap { overflow-x: auto; }
.manage-table { width: 100%; border-collapse: collapse; font-size: .85rem; }
.manage-table th, .manage-table td { text-align: left; padding: 4px 6px; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.manage-body .mod-list, .manage-body .pack-list { list-style: none; margin: 0; padding: 0; }
.manage-body .mod-row { display: flex; flex-direction: column; gap: 6px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.manage-body .mod-row.bad { border-left: 3px solid var(--bad); padding-left: 8px; }
.manage-body .mod-text { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; overflow-wrap: anywhere; }
.manage-body .mod-btns { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.manage-body .mod-extra:empty { display: none; }
.manage-body .pack-list li { padding: 4px 0; }
.manage-body .pack-list li > button { display: flex; width: 100%; justify-content: space-between; align-items: center; gap: 8px; text-align: left; }
.manage-body .pack-list small { display: block; opacity: .75; overflow-wrap: anywhere; }
.manage-body .tag.warn { background: var(--warn-soft); color: var(--warn); }
.manage-body .update-mark { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); margin-right: 4px; }
.manage-actions button, .manage-add button { min-height: 40px; }

table.built { width: 100%; border-collapse: collapse; font-size: .9rem; margin: 4px 0; }
table.built th { text-align: left; font-weight: 700; color: var(--muted); font-size: .8rem; padding: 2px 8px 4px 0; }
table.built td { padding: 4px 8px 4px 0; border-top: 1px solid var(--line); overflow-wrap: anywhere; }
table.built th:not(:first-child), table.built td:not(:first-child) { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }

.play-top #install-app, .play-hi .btnlink, .play-hi button { white-space: nowrap; }
.play-hi { min-width: 0; }
.play-hi > span { min-width: 0; max-width: 38vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 520px) { .play-top .hide-sm, .play-hi .hide-sm { display: none; } }

/* ---- a livelier page ---- */
.banner.play-notice { border-color: var(--warn-line); background: var(--warn-soft); }
.banner.play-notice .ico { color: var(--warn); }
.sug-bar { margin: 4px 0 14px; }
#sug-dlg { width: min(560px, calc(100vw - 32px)); }
#sug-dlg textarea { width: 100%; box-sizing: border-box; font: inherit; }
#sug-dlg .req-list li { justify-content: space-between; }

/* Requests v2 */
#sug-dlg .sug-item { display: block; }
.sug-top { display: flex; gap: 10px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.sug-replies { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 5px; }
.sug-replies li { background: var(--panel-2); border-radius: 10px; padding: 6px 10px; font-size: .88rem; border: 0 !important; display: block !important; }
.sug-replies li.admin { background: var(--accent-soft); }
.sug-reply { display: flex; gap: 6px; margin-top: 6px; }
.sug-reply input { flex: 1; min-width: 0; padding: 6px 10px; font-size: .88rem; }
.mod-check { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: 10px; background: var(--panel-2); border: 1px solid var(--line); margin: -4px 0 10px; }
.mod-check img { width: 40px; height: 40px; border-radius: 8px; flex: none; }
.mod-check.ok { border-color: var(--ok-line); background: var(--ok-soft); }
.mod-check.bad { border-color: var(--warn-line); background: var(--warn-soft); }
.mod-check .ico { width: 14px; height: 14px; vertical-align: -2px; margin-right: 4px; }
.watch-btn { display: inline-flex; align-items: center; gap: 5px; }
.watch-btn .ico { width: 14px; height: 14px; }
/* People and profiles */
button.who-chip { font: inherit; color: inherit; cursor: pointer; text-align: left; }
.people-dlg { width: min(760px, 96vw); }
.people-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; margin-top: 10px; }
.person { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 14px 10px; text-align: center; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); cursor: pointer; font: inherit; color: inherit; }
.person:hover { border-color: var(--accent-line); box-shadow: var(--shadow); }
.person img { width: 56px; height: 56px; border-radius: 8px; image-rendering: pixelated; }
.person .dot { width: 8px; height: 8px; display: inline-block; }
.prof-head { display: flex; gap: 16px; align-items: flex-start; margin: 8px 0 14px; }
.prof-body { width: 60px; height: auto; image-rendering: pixelated; flex: none; }
.prof-head h3 { margin: 0; font-size: 1.5rem; }
.prof-head p { margin: 2px 0 6px; }
.prof-head .dot { width: 8px; height: 8px; display: inline-block; }
.badges { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.badge { display: inline-grid; grid-template-columns: auto 1fr; column-gap: 8px; align-items: center; padding: 7px 12px 7px 9px; border-radius: 12px; background: var(--accent-soft); border: 1px solid var(--accent-line); }
.badge .ico { grid-row: span 2; width: 20px; height: 20px; color: var(--accent); }
.badge b { font-size: .88rem; }
.badge small { color: var(--muted); font-size: .72rem; }
.days { display: grid; grid-template-columns: repeat(14, 1fr); gap: 4px; height: 70px; align-items: end; padding: 4px 0; border-bottom: 1px solid var(--line); }
.days span { height: 100%; display: flex; align-items: flex-end; }
.days i { display: block; width: 100%; min-height: 2px; border-radius: 4px 4px 0 0; background: var(--accent); }
.sug-side { display: inline-flex; gap: 6px; align-items: center; margin-left: auto; }

/* ==== 0.47: chat, places and screenshots on a server's sheet ==== */
.tag.live { color: var(--accent); border-color: currentColor; }
.chat-log { max-height: 320px; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding: 4px 2px 8px;
  overscroll-behavior: contain; }
.cm { display: flex; gap: 8px; align-items: flex-start; font-size: .92rem; }
.cm img { width: 24px; height: 24px; border-radius: 4px; image-rendering: pixelated; flex: none; margin-top: 2px; }
.cm > div { min-width: 0; flex: 1; }
.cm-head { display: flex; gap: 6px; align-items: baseline; flex-wrap: wrap; }
.cm-head time, .cm.sys time { color: var(--muted); font-size: .78rem; }
.cm-text { overflow-wrap: anywhere; white-space: pre-wrap; }
.cm.you .cm-head b { color: var(--accent); }
.cm.sys { color: var(--muted); font-size: .84rem; font-style: italic; padding-left: 32px; display: block; }
.cm-del { margin-left: auto; color: var(--muted); }
.cm-del .ico { width: 14px; height: 14px; }
.chat-send { display: flex; gap: 8px; margin-top: 6px; }
.chat-send input { flex: 1; min-width: 0; }
.chat-note { margin: 6px 0 0; }

.pl-dim { margin: 10px 0 4px; font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.places { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.place { display: flex; gap: 8px; align-items: center; padding: 8px 10px; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.pl-main { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.pl-xyz { flex: none; display: inline-flex; gap: 6px; align-items: center; }
.pl-xyz code { font-size: .82rem; }
.pl-add { margin-top: 10px; }
.pl-add > summary { cursor: pointer; color: var(--accent); display: inline-flex; gap: 6px; align-items: center; font-weight: 600; }
details.join .pl-add > summary::after { transform: none; }
details.join .pl-add[open] > summary::after { transform: rotate(180deg); }
.pl-form { display: grid; gap: 8px; margin-top: 8px; }
.pl-form label { display: grid; gap: 4px; font-size: .88rem; }
.pl-form label.check { display: flex; align-items: center; gap: 8px; }
.pl-here { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.pl-or { margin: 4px 0 0; }
.pl-xyz-in { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) minmax(0, 1.4fr); gap: 6px; }
.pl-xyz-in input, .pl-xyz-in select { width: 100%; min-width: 0; }
@media (max-width: 420px) { .pl-xyz-in { grid-template-columns: repeat(3, minmax(0, 1fr)); } .pl-xyz-in label:last-child { grid-column: 1 / -1; }
  .place { flex-wrap: wrap; } .pl-main { flex-basis: 100%; } .pl-xyz { margin-right: auto; } }

.shot-add { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 10px; }
.shot-add input[name="caption"] { flex: 1 1 180px; min-width: 0; }
.shot-add .busy { opacity: .6; pointer-events: none; }
.shots { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
.shot { padding: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; background: var(--panel-3, #eee);
  display: flex; flex-direction: column; cursor: pointer; font: inherit; color: inherit; text-align: left; }
.shot img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; display: block; }
.shot span { font-size: .78rem; padding: 4px 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--muted); }
.shot-dlg { max-width: min(1200px, 96vw); width: 96vw; padding: 0; border: 0; border-radius: var(--radius); background: #111; color: #eee; }
.shot-dlg::backdrop { background: rgb(0 0 0 / .8); }
.shot-dlg figure { margin: 0; }
.shot-dlg img { width: 100%; max-height: 80vh; object-fit: contain; display: block; background: #000; }
.shot-dlg figcaption { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; padding: 10px 14px; }
.shot-dlg figcaption .muted { color: #aaa; }
.shot-dlg .dlg-x { position: absolute; top: 8px; right: 8px; z-index: 2; background: rgb(0 0 0 / .5); color: #fff; }
.shot-nav { position: absolute; top: 40%; background: rgb(0 0 0 / .45); color: #fff; border: 0; font-size: 2rem; line-height: 1; padding: 8px 12px; border-radius: 8px; cursor: pointer; }
.shot-nav.prev { left: 8px; } .shot-nav.next { right: 8px; }


/* ---- dialogs and the gate use the same square corners, plain buttons and no pills ---- */
body.play dialog { border-radius: 4px; box-shadow: none; border-color: var(--line-strong); }
body.play dialog::backdrop { backdrop-filter: none; }
body.play .gate-card { border-radius: 4px; box-shadow: none; }
body.play dialog button, body.play .gate-card button, body.play .banner button { border-radius: 3px; box-shadow: none; }
body.play .tag, body.play .acc { border-radius: 2px; }
body.play .mod-check, body.play .mc-found, body.play .badge, body.play .person, body.play .sug-replies li { border-radius: 3px; }
body.play .mc-found .mc-head, body.play .person img, body.play .mod-check img { border-radius: 2px; }
body.play input, body.play select, body.play textarea { border-radius: 3px; }

.admin-list { list-style: none; margin: 0 0 8px; padding: 0; }
.admin-list li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 6px 0; border-top: 1px solid var(--line); }
.admin-list li:first-child { border-top: 0; }

/* shown until the first /api/play/state answer */
.play-loading { padding: 32px 16px; text-align: center; }
