@font-face { font-family: "CN Display"; src: url(../assets/fonts/Syne-Display-Latin1-500-700.woff2) format("woff2"); font-weight: 500 700; font-display: swap; }
@font-face { font-family: "CN Text"; src: url(../assets/fonts/DMSans-Text-Latin1-400-600.woff2) format("woff2"); font-weight: 400 600; font-display: swap; }
@font-face { font-family: "CN Mono"; src: url(../assets/fonts/DMMono-Medium-Latin1.woff2) format("woff2"); font-weight: 500; font-display: swap; }
:root {
  --ground: #151518; --ground-2: #1e1f23; --paper: #e8e9e7; --muted: #b2b4bd; --blue: #b2c8f0; --blood: #e2384f; --blood-l: #ffb3b8;
  --line: #3c3d45; --control: #7c7f8a; --rust: #e0805f; --plate: rgba(21, 21, 24, .86); --water: #9fd6d6; --stone: #cfc8bb;
  --display: "CN Display", Arial, sans-serif; --text: "CN Text", Arial, sans-serif; --mono: "CN Mono", ui-monospace, monospace;
  --safe-l: env(safe-area-inset-left, 0px); --safe-r: env(safe-area-inset-right, 0px);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; overflow: hidden; background: var(--ground); color: var(--paper); font: 15px/1.35 var(--text); overscroll-behavior: none; user-select: none; -webkit-user-select: none; touch-action: none; }
#world, #world3d { position: fixed; inset: 0; width: 100%; height: 100%; display: block; }
#world3d { pointer-events: none; }
button { font: inherit; color: inherit; cursor: pointer; touch-action: manipulation; }
button:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
[hidden] { display: none !important; }
.plate { background: var(--plate); border: 1px solid var(--line); border-radius: 10px; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.eyebrow { font: 500 11px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
#hud { position: fixed; inset: 0; pointer-events: none; }
#hud > *, .sheet .panel { zoom: var(--ui, 1); }
#hud > * { pointer-events: auto; }
.bar { height: 6px; background: #2b2c33; border-radius: 3px; overflow: hidden; }
.bar i { display: block; height: 100%; width: 100%; background: #8fd19e; transition: width .15s; }
.key { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 4px; border: 1px solid #5a5c66; border-radius: 4px; background: rgba(21,21,24,.9); font: 500 10.5px/1 var(--mono); color: var(--paper); text-transform: uppercase; }
#party { position: absolute; top: 10px; left: calc(10px + var(--safe-l)); width: 196px; padding: 6px 8px 8px; }
#party .hd { display: flex; justify-content: space-between; margin-bottom: 4px; }
.prow { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; padding: 4px 0; }
.prow .n { font: 600 13px/1.1 var(--display); } .prow .r { font: 500 10px/1.1 var(--mono); color: var(--muted); text-transform: uppercase; align-self: center; }
.prow .bar { grid-column: 1 / -1; } .prow.down .n::after { content: " · down"; color: var(--rust); font: 500 10px var(--mono); }
.prow.net .bar i { background: #b2c8f0; } .prow.net.off { opacity: .55; } .prow.net.inv .n { font-weight: 500; color: var(--muted); } .prow .lead { color: #e7d9a8; font-size: 11px; }
.prow.net.down .n::after { content: ""; }
#partyrows.companions { border-top: 1px solid var(--line); margin-top: 3px; padding-top: 2px; opacity: .8; }
#markbtn { min-height: 24px; padding: 0 8px; border-radius: 8px; border: 1px solid var(--line); background: rgba(21,21,24,.6); font: 500 11px/1 var(--mono); color: var(--paper); margin: -3px 0 0 6px; }
#markbtn[aria-pressed="true"] { border-color: #8fd19e; color: #8fd19e; }
.touch #markbtn { min-height: 44px; min-width: 56px; }
#invchip { min-height: 44px; padding: 6px 12px; border-color: #8fd19e; text-align: left; display: flex; gap: 8px; align-items: center; }
#invchip .l1 { font: 600 12.5px/1.15 var(--display); } #invchip .l2 { font: 500 10.5px/1.3 var(--mono); color: var(--muted); }
#invchip .dot { width: 10px; height: 10px; border-radius: 5px; background: #8fd19e; flex: none; }
.touch #invkey { display: none; }
#chatch { min-height: 40px; border-radius: 8px; border: 1px solid var(--line); background: rgba(21,21,24,.92); color: var(--paper); font: 500 12px var(--mono); padding: 0 6px; max-width: 46%; }
#chatlog .dm { color: #e7c6f0; }
.srow { border-top: 1px solid var(--line); padding: 6px 0; display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.srow .n { font: 600 14px/1.2 var(--display); } .srow .n small { display: block; font: 500 11px/1.3 var(--mono); color: var(--muted); }
#socialbody input { min-height: 44px; flex: 1; min-width: 160px; border-radius: 10px; border: 1px solid var(--line); background: rgba(21,21,24,.92); color: var(--paper); font: 14px var(--text); padding: 0 10px; user-select: text; -webkit-user-select: text; }
#socialbody input:focus-visible, #chatch:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; }
#target { position: absolute; top: 10px; left: 50%; transform: translateX(-50%); width: min(340px, 40vw); padding: 6px 12px 8px; text-align: center; }
#target .n { font: 600 14px/1.15 var(--display); } #target .n small { font: 500 11px var(--mono); color: var(--muted); margin-left: 6px; }
#target .bar { margin-top: 5px; height: 7px; } #target .bar i { background: var(--rust); }
#target .cast { margin-top: 5px; font: 500 11px/1.2 var(--mono); color: #ffcf9e; display: flex; gap: 6px; justify-content: center; align-items: center; }
#target .cast::before { content: ""; width: 0; height: 0; border-left: 6px solid transparent; border-right: 6px solid transparent; border-top: 9px solid var(--rust); }
#nav { position: absolute; top: 10px; right: calc(10px + var(--safe-r)); width: 176px; display: flex; flex-direction: column; gap: 6px; align-items: stretch; }
#minimap { width: 176px; height: 110px; border-radius: 10px; border: 1px solid var(--line); background: rgba(21,21,24,.7); display: block; }
#objective { padding: 6px 10px; font: 600 12.5px/1.25 var(--display); } #objective .s { display: block; font: 500 11px/1.2 var(--mono); color: var(--muted); margin-top: 2px; }
#objective.won { border-color: var(--blue); }
#conn { position: absolute; right: 6px; top: 4px; font: 600 9.5px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; padding: 3px 5px; border-radius: 5px; background: rgba(10,10,12,.72); color: var(--muted); pointer-events: none; }
#conn.live { color: #8fd19e; } #conn.lost, #conn.reconnecting { color: #ffcf9e; } #conn.dev { color: #e7d9a8; }
#menu { display: flex; gap: 6px; justify-content: flex-end; flex-wrap: wrap; }
.mbtn { min-width: 44px; height: 44px; padding: 0 9px; border-radius: 10px; font: 600 12px/1 var(--display); display: inline-flex; align-items: center; gap: 6px; }
.mbtn svg { width: 20px; height: 20px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mbtn[aria-pressed="true"] { color: var(--ground); background: var(--blue); border-color: var(--blue); }
#dock { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 6px; }
#hud > #dock { pointer-events: none; } #dock > * { pointer-events: auto; }
#vitals { display: flex; align-items: center; gap: 10px; padding: 5px 12px 5px 5px; width: min(440px, 92vw); }
#portrait { width: 44px; height: 44px; border-radius: 50%; background: #23242a; border: 1px solid var(--line); flex: none; }
#vitals .col { flex: 1; min-width: 0; }
#vitals .top { display: flex; justify-content: space-between; gap: 8px; font: 600 12.5px/1.1 var(--display); }
#vitals .top .hp { font: 500 11px/1 var(--mono); color: var(--muted); }
#vitals .bar { margin-top: 5px; height: 8px; }
#vitals .tags { margin-top: 4px; font: 500 10.5px/1.2 var(--mono); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#favrow { display: flex; gap: 6px; align-items: flex-end; }
#strip { display: flex; gap: 12px; align-items: flex-end; }
#acts { display: flex; gap: 6px; align-items: flex-end; padding-left: 12px; border-left: 1px solid var(--line); }
#acts[hidden] { display: none; }
.act { position: relative; width: 52px; height: 52px; border-radius: 26px; border: 1.5px solid var(--control); background: var(--plate); padding: 0; display: grid; place-items: center; overflow: hidden; touch-action: none; }
.act .nm { position: relative; z-index: 2; font: 600 10.5px/1 var(--display); }
.act .cd { position: absolute; inset: 0; z-index: 1; background: conic-gradient(rgba(0,0,0,.66) var(--p, 0%), transparent 0); }
.act .secs { position: absolute; z-index: 3; left: 0; right: 0; bottom: 6px; text-align: center; font: 600 11px/1 var(--mono); color: #fff; text-shadow: 0 1px 2px #000; }
.act.cooling .nm { opacity: .6; }
.act.up { border: 2px solid var(--paper); background: #cfc8bb; color: #151518; box-shadow: 0 0 0 3px rgba(207,200,187,.3); }
.fav.arming { border-style: dashed; border-color: #8f8462; } .fav.arming .nm { opacity: .6; }
.arm { color: #e7d9a8; }
.fav { position: relative; width: 58px; height: 58px; border-radius: 10px; border: 1.5px solid var(--control); background: var(--plate); padding: 0; display: grid; place-items: center; overflow: hidden; }
.fav .nm { position: relative; z-index: 2; font: 600 10.5px/1.05 var(--display); text-align: center; padding: 0 3px; }
.fav .cd { position: absolute; inset: 0; z-index: 1; background: conic-gradient(rgba(0,0,0,.66) var(--p, 0%), transparent 0); }
.fav .secs { position: absolute; z-index: 3; left: 0; right: 0; bottom: 3px; text-align: center; font: 600 12px/1 var(--mono); color: #fff; text-shadow: 0 1px 2px #000; }
.fav.cooling .nm { opacity: .6; } .fav.cooling:not(.arming) .why { display: none; }
.fav .why { position: absolute; z-index: 3; left: 0; right: 0; bottom: 3px; font: 500 8.5px/1 var(--mono); text-transform: uppercase; color: #ffcf9e; text-align: center; }
.fav .badge { position: absolute; z-index: 3; top: 3px; right: 3px; width: 14px; height: 14px; }
.fav .badge svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 2; }
.fav[data-src="item"] { border-color: #8f8462; } .fav[data-src="item"] .badge { color: #e7d9a8; }
.fav[data-src="core"] .badge { color: var(--blue); } .fav[data-src="species"] .badge, .fav[data-src="body"] .badge { color: var(--water); }
.fav.ready { border-color: var(--blue); }
.fav.recast { border: 2px dashed var(--blood); box-shadow: 0 0 0 3px rgba(226,56,79,.25); }
.fav.recast .why { color: var(--blood-l); }
.fav.empty .nm { font-size: 20px; font-weight: 500; } .fav.empty { border-style: dashed; background: rgba(21,21,24,.5); color: var(--muted); }
.fav .ico, .act .ico { position: absolute; z-index: 2; left: 50%; transform: translateX(-50%); pointer-events: none; }
.fav .ico { top: 6px; width: 26px; height: 26px; } .touch .fav .ico { top: 7px; width: 28px; height: 28px; }
.fav:not(.noico) .nm { position: absolute; left: 2px; right: 2px; bottom: 4px; font: 600 9.5px/1.05 var(--display); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; padding: 0; }
.fav:not(.noico) .secs { top: 9px; bottom: auto; font-size: 14px; }
.fav:not(.noico) .why { bottom: 5px; padding: 0 2px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.fav.noted:not(.noico) .nm { visibility: hidden; }
.fav.cooling .ico, .act.cooling .ico { opacity: .4; }
.act .ico { top: 7px; width: 22px; height: 22px; } .touch .act .ico { top: 8px; width: 24px; height: 24px; }
.act:not(.noico) .nm { position: absolute; left: 0; right: 0; bottom: 9px; font-size: 9.5px; text-align: center; }
.act:not(.noico) .secs { top: 11px; bottom: auto; font-size: 13px; }
.slotk { display: flex; flex-direction: column; align-items: center; gap: 3px; }
#more { width: 58px; height: 58px; border-radius: 29px; display: grid; place-items: center; padding: 0; font: 600 12px/1 var(--display); }
#more .ct { font: 500 10px/1 var(--mono); color: #e7d9a8; display: block; margin-top: 2px; }
#assist { min-height: 32px; padding: 0 12px; border-radius: 16px; font: 500 11.5px/1 var(--mono); display: inline-flex; align-items: center; gap: 6px; }
#assist[aria-pressed="true"] { border-color: var(--blue); color: var(--blue); }
#tray { padding: 8px; display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; max-width: min(92vw, 560px); }
#tray .hd { width: 100%; display: flex; justify-content: space-between; gap: 8px; }
#pending { min-height: 44px; padding: 6px 12px; border-color: #c8b98a; text-align: left; display: flex; gap: 8px; align-items: center; }
#pending .l1 { font: 600 12.5px/1.15 var(--display); } #pending .l2 { font: 500 10.5px/1.3 var(--mono); color: var(--muted); white-space: pre-line; }
#pending .dot { width: 10px; height: 10px; transform: rotate(45deg); background: #e7d9a8; flex: none; }
#formchip { min-height: 44px; padding: 6px 12px; border-color: #3fa7a0; text-align: left; display: flex; gap: 8px; align-items: center; box-shadow: 0 0 0 2px rgba(63,167,160,.28); }
#formchip .l1 { font: 600 12.5px/1.15 var(--display); } #formchip .l2 { font: 500 10.5px/1.3 var(--mono); color: #c3f0e6; }
#formchip .dot { width: 12px; height: 12px; border-radius: 6px 6px 6px 1px; transform: rotate(-45deg); background: #3fa7a0; flex: none; animation: offer 1.6s ease-in-out 3; }
#formkey { margin-left: auto; flex: none; }
@keyframes offer { 50% { box-shadow: 0 0 0 6px rgba(63,167,160,.35); } }
@media (prefers-reduced-motion: reduce) { #formchip .dot { animation: none; } }
#notice { padding: 7px 14px; font: 600 13px/1.25 var(--text); max-width: min(90vw, 460px); text-align: center; }
#chat { pointer-events: none !important; position: absolute; left: calc(10px + var(--safe-l)); bottom: 10px; width: min(330px, 30vw); display: flex; flex-direction: column; gap: 3px; }
#chatlog { display: flex; flex-direction: column; gap: 2px; font: 13px/1.3 var(--text); text-shadow: 0 1px 2px #000, 0 0 6px #000; max-height: 9.5em; overflow: hidden; }
#chatlog .ln { transition: opacity .6s; } #chatlog .ln.faded { opacity: 0; }
#chatlog .ch { font: 500 10.5px var(--mono); color: var(--muted); margin-right: 4px; } #chatlog .sys { color: #cfd6e6; }
#chatbar, #chat.open #chatlog { pointer-events: auto; }
#chat.open #chatlog { max-height: 16em; overflow-y: auto; background: var(--plate); border-radius: 8px; padding: 6px 8px; }
#chat.open #chatlog .ln.faded { opacity: 1; }
#chatbar { display: flex; gap: 6px; align-items: center; font: 500 11.5px/1 var(--mono); color: var(--muted); min-height: 30px; }
#chatin { flex: 1; min-height: 40px; border-radius: 8px; border: 1px solid var(--blue); background: rgba(21,21,24,.92); color: var(--paper); font: 14px var(--text); padding: 0 10px; user-select: text; -webkit-user-select: text; }
#chatbtn { min-height: 30px; padding: 0 8px; border-radius: 8px; border: 1px solid var(--line); background: rgba(21,21,24,.6); font: 500 11.5px/1 var(--mono); color: var(--muted); display: inline-flex; gap: 6px; align-items: center; }
#hints { position: absolute; right: calc(12px + var(--safe-r)); bottom: 12px; display: flex; gap: 12px; font: 500 11.5px/1 var(--text); color: var(--muted); text-shadow: 0 1px 2px #000; }
#hints span { display: inline-flex; gap: 5px; align-items: center; }
.touch #hints, .touch .slotk .key, .touch #chatbtn .key, .touch #pendkey, .touch #formkey { display: none; }
#pendkey { margin-left: auto; flex: none; }
.touch #dock { left: auto; right: calc(10px + var(--safe-r)); transform: none; align-items: flex-end; }
.touch #acts .slotk[data-action="dodge"] { order: -1; }
.touch #acts { order: -1; flex-direction: column-reverse; padding-left: 0; border-left: 0; gap: 8px; } .touch .act { width: 60px; height: 60px; border-radius: 30px; }
.touch #favrow { display: flex; flex-direction: row-reverse; flex-wrap: wrap-reverse; gap: 8px; width: 264px; } .touch .fav, .touch #more { width: 60px; height: 60px; }
.touch #vitals { position: fixed; left: calc(10px + var(--safe-l)); bottom: 10px; width: min(300px, 38vw); }
.touch #chat { bottom: 74px; width: min(280px, 34vw); } .touch #chatlog { font-size: 12px; max-height: 4.2em; }
.touch #nav { width: 150px; } .touch #minimap { width: 150px; height: 84px; }
.touch #assist, .touch #chatbtn { min-height: 44px; }
.touch #pending { position: fixed; left: 50%; transform: translateX(-50%); bottom: 8px; max-width: 230px; }
.touch #notice { position: fixed; left: 50%; transform: translateX(-50%); top: 76px; bottom: auto; max-width: 300px; font-size: 12.5px; }
.touch #menu { flex-wrap: nowrap; } .touch #nav { width: auto; align-items: flex-end; }
.touch #dock { bottom: 8px; } .touch #objective { padding: 4px 8px; } .touch #objective .s { display: none; }
@media (max-height: 430px) { .touch #minimap { height: 62px; width: 120px; } .touch #menu .mbtn { min-width: 44px; padding: 0 6px; } }
@media (max-height: 430px) { #party { width: 170px; } #target { top: 6px; } .prow { padding: 2px 0; } }
.sheet { position: fixed; top: 0; bottom: 0; right: 0; width: min(560px, 100vw); display: flex; z-index: 10; padding: 8px calc(8px + var(--safe-r)) 8px 8px; }
.sheet.center { left: 0; right: 0; width: auto; justify-content: center; align-items: center; background: rgba(10,10,12,.5); }
.sheet .panel { width: 100%; max-height: 100%; overflow: auto; padding: 12px 14px 14px; }
.sheet.center .panel { width: min(100%, 860px); }
.sheet h2 { margin: 2px 0 2px; font: 700 clamp(18px, 2.2vw, 23px)/1.1 var(--display); }
.sheet .lede { margin: 2px 0 8px; color: var(--muted); font-size: 13px; }
.sheet .head { display: flex; justify-content: space-between; align-items: start; gap: 12px; position: sticky; top: -12px; background: var(--plate); margin: -12px -14px 0; padding: 12px 14px 6px; z-index: 2; }
.btn { min-height: 44px; padding: 0 16px; border-radius: 22px; border: 1px solid var(--control); background: transparent; font: 600 13.5px/1 var(--display); }
.btn.primary { background: var(--blue); color: var(--ground); border-color: var(--blue); }
.btn.small { min-height: 44px; padding: 0 12px; font-size: 12.5px; border-radius: 10px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.grp { margin-top: 8px; }
details.lede summary { cursor: pointer; color: var(--paper); font-size: 12.5px; min-height: 24px; display: list-item; }
#pending.reserved { border-color: #e7d9a8; box-shadow: 0 0 0 2px rgba(231,217,168,.25); } #pending.reserved .l2 { color: #e7d9a8; }
.grp > h3 { margin: 0 0 4px; display: flex; gap: 8px; align-items: baseline; font: 700 14px/1.2 var(--display); }
.ab { border-top: 1px solid var(--line); padding: 7px 0; display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; }
.ab .t { font: 600 14px/1.2 var(--display); display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.ab .t .rk { font: 500 11px/1 var(--mono); color: var(--muted); }
.ab .d { grid-column: 1; font-size: 12.5px; opacity: .92; }
.ab .nums { grid-column: 1; font: 500 11px/1.4 var(--mono); color: var(--blue); }
.ab .stack { grid-column: 1; font: 500 11px/1.4 var(--mono); color: #e7d9a8; }
.ab .ctl { grid-column: 2; grid-row: 1 / span 4; display: flex; flex-direction: column; gap: 6px; min-width: 120px; }
.chips { display: flex; gap: 4px; flex-wrap: wrap; }
.chip { font: 500 10px/1 var(--mono); letter-spacing: .04em; text-transform: uppercase; border: 1px solid var(--line); border-radius: 6px; padding: 3px 5px; color: var(--muted); }
.chip.core { color: var(--blue); border-color: #4e5a73; } .chip.item { color: #e7d9a8; border-color: #6d6447; } .chip.species { color: var(--water); border-color: #3c6466; }
.ab .ctl button[aria-pressed="true"] { background: var(--blue); color: var(--ground); border-color: var(--blue); }
.ab .ctl button.reserve[aria-pressed="false"] { border-style: dashed; color: var(--muted); }
.empty-slot { border-top: 1px dashed var(--line); padding: 8px 0; color: var(--muted); font-size: 13px; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.item-h { font: 600 12.5px/1.2 var(--display); color: #e7d9a8; margin-top: 6px; display: flex; gap: 8px; align-items: center; justify-content: space-between; }
.opts { display: flex; flex-wrap: wrap; gap: 6px; }
.opts button[aria-pressed="true"] { background: var(--blue); color: var(--ground); border-color: var(--blue); }
.note { font-size: 12px; color: var(--muted); margin-top: 8px; }
.labgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; } .labgrid .eyebrow { display: block; margin-bottom: 6px; }
.cands { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; margin-top: 8px; }
.cand { border: 1px solid var(--line); border-radius: 10px; padding: 8px; display: flex; flex-direction: column; gap: 6px; }
.cand .t { font: 600 14px/1.2 var(--display); } .cand .r { font: 500 10.5px/1.2 var(--mono); color: var(--muted); text-transform: uppercase; }
.cand button { min-height: 44px; border-radius: 10px; border: 1px solid var(--control); background: transparent; font: 600 12.5px/1.15 var(--display); text-align: left; padding: 4px 10px; }
.cand button[aria-pressed="true"] { background: var(--blue); color: var(--ground); border-color: var(--blue); }
.bind { display: grid; grid-template-columns: 1fr auto auto; gap: 8px; align-items: center; border-top: 1px solid var(--line); padding: 5px 0; font-size: 13px; }
.bind .key { min-width: 34px; height: 26px; font-size: 12px; }
.bind button.capturing { border-color: var(--blood); color: var(--blood-l); }
.sheet.center .panel.pt-first { width: auto; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 24px 32px 10px; }
.pt-privlink { min-height: 44px; min-width: 44px; padding: 0 10px; background: none; border: 0; color: var(--muted); font: 500 13px/1 var(--text); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.pt-end .actions .pt-privlink { margin-left: auto; }
a.btn { display: inline-flex; align-items: center; color: inherit; text-decoration: none; } .pt-priv a { color: var(--blue); text-underline-offset: 3px; }
#pt-priv { z-index: 12; background: rgba(10,10,12,.72); } .pt-priv.plate { background: var(--ground); backdrop-filter: none; -webkit-backdrop-filter: none; }
.pt-priv { width: min(100%, 600px); max-height: 92vh; overflow-y: auto; font-size: 14px; line-height: 1.45; } .pt-priv h3 { font: 600 14px/1.3 var(--display); margin: 14px 0 4px; } .pt-priv p, .pt-priv ul { margin: 4px 0; } .pt-priv ul { padding-left: 20px; }
#privacy a { color: var(--blue); text-underline-offset: 2px; } #privacy a:focus-visible { outline: 2px solid var(--paper); outline-offset: 2px; }
.portal-name { font: 700 44px/1 var(--display); letter-spacing: -.01em; margin: 0; } .portal-line { margin: 4px 0 14px; color: var(--muted); text-align: center; }
.pt-code { font: 500 14px/1.4 var(--mono); margin: 8px 0; } .pt-play { min-height: 56px; min-width: 200px; font-size: 18px; }
#conn { white-space: nowrap; }
.pt-end { width: min(100%, 560px); max-height: 92vh; overflow-y: auto; }
.pt-q { display: block; margin: 10px 0; } .pt-q span { display: block; font: 600 14px/1.3 var(--display); margin-bottom: 4px; }
.pt-q textarea, .pt-out { width: 100%; box-sizing: border-box; min-height: 48px; font: 14px/1.35 var(--text); color: var(--paper); background: rgba(10,10,14,.55); border: 1px solid var(--control); border-radius: 8px; padding: 8px 10px; resize: vertical; }
.pt-out { font: 11px/1.3 var(--mono); margin-top: 8px; }
.pt-dev { display: grid; grid-template-columns: auto 1fr; gap: 2px 10px; margin: 10px 0; font: 500 12px/1.35 var(--mono); } .pt-dev dt { color: var(--muted); } .pt-dev dd { margin: 0; }
.pt-sent { font-size: 12.5px; color: var(--muted); margin: 8px 0; } .pt-done { font-size: 13px; margin: 8px 0 0; color: #8fd19e; }
@media (max-height: 500px) { .pt-end { padding: 10px 14px; } .pt-q { margin: 4px 0; } .pt-q span { font-size: 13px; margin-bottom: 2px; } .pt-q textarea { min-height: 34px; padding: 6px 8px; } .pt-end h2 { display: none; }
  .pt-dev { display: flex; flex-wrap: wrap; gap: 0 6px; margin: 6px 0; font-size: 11px; } .pt-dev dd { margin-right: 10px; } .pt-sent { font-size: 11.5px; margin: 4px 0; } }
.key { white-space: nowrap; }
@media (pointer: fine) and (max-width: 1180px) { html:not(.touch) #hints { display: none; } html:not(.touch) #chat { bottom: 190px; width: min(300px, 36vw); } html:not(.touch) #chatlog { max-height: 4.2em; } }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
@media (max-height: 500px) {
  #build { width: min(740px, 100vw); }
  #build .head h2 { display: none; }
  #build .head { align-items: center; padding-bottom: 4px; }
  #build .grp { margin-top: 4px; }
  .ab { padding: 5px 0; gap: 1px 8px; }
  .ab .t { font-size: 13px; gap: 6px; }
  .ab .d { font-size: 12px; line-height: 1.3; }
  .ab .ctl { grid-row: 1 / span 3; flex-direction: row; min-width: 0; gap: 4px; align-items: start; }
  .ab .ctl .btn { font-size: 11.5px; padding: 0 8px; min-height: 44px; max-width: 92px; line-height: 1.1; white-space: normal; }
}
.mt10 { margin-top: 10px; } .mt8 { margin-top: 8px; } .span-all { grid-column: 1 / -1; }
