/* Valanar table */
:root {
  --ink: #1d1a16; --ink-soft: #5a5246; --parch: #f3ecdc; --parch-2: #e7dcc4; --line: #cbbd9e;
  --bg: #0f1216; --chrome: #14181e; --chrome-2: #1b2028; --chrome-3: #242b35; --chrome-line: rgba(232, 226, 208, 0.13);
  --text: #e8e2d0; --text-soft: rgba(232, 226, 208, 0.62); --gold: #c9a45c; --danger: #d0604f; --ok: #6fbf73;
  --serif: "Palatino Linotype", "Book Antiqua", Palatino, Georgia, serif;
  --sans: "Segoe UI", system-ui, sans-serif;
  --bar: 48px; --side: 340px;
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body { background: var(--bg); color: var(--text); font: 13px/1.4 var(--sans); overflow: hidden; }
button, input, select, textarea { font: inherit; color: inherit; }
[hidden] { display: none !important; }
.muted { color: var(--text-soft); }
.small { font-size: 12px; }
.err { color: var(--danger); }
body:not(.is-gm) .gm { display: none !important; }
body.is-guest .noguest { display: none !important; }
.guestnote { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border-top: 1px solid var(--line, rgba(255,255,255,.1)); font-size: 13px; color: var(--muted, #aab); }
.guestnote .btn { text-decoration: none; }
.loginpage .loginalt { margin-top: 16px; text-align: center; font-size: 13px; }
.loginpage .loginalt a { color: var(--gold); text-decoration: none; }
.loginpage .loginalt a:hover { text-decoration: underline; }

/* ---------- top bar (matches the map viewer) ---------- */
#topbar {
  position: fixed; z-index: 50; left: 0; right: 0; top: 0; height: var(--bar);
  display: flex; align-items: center; gap: 14px; padding: 0 12px;
  background: #101318; border-bottom: 1px solid var(--chrome-line); box-shadow: 0 1px 8px rgba(0, 0, 0, 0.4);
}
.brand { font: 600 21px/1 var(--serif); letter-spacing: 0.08em; color: var(--gold); text-decoration: none; }
.brand.big { font-size: 34px; text-align: center; margin-bottom: 10px; }
#views { display: flex; gap: 2px; height: 100%; }
#views a { display: flex; align-items: center; height: 100%; padding: 0 12px; color: rgba(232, 226, 208, 0.72); text-decoration: none;
  font: 600 13px/1 var(--sans); letter-spacing: 0.04em; border-bottom: 2px solid transparent; border-top: 2px solid transparent; }
#views a:hover { color: #fff; }
#views a.on { color: #fff; border-bottom-color: var(--gold); }
.crumb { background: none; border: 1px solid transparent; border-radius: 4px; padding: 5px 9px; cursor: pointer; font: 600 14px var(--serif); color: var(--text); }
.crumb:hover { border-color: var(--chrome-line); }
.spacer { flex: 1; }
.conn { width: 9px; height: 9px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px rgba(111, 191, 115, 0.15); }
.conn.bad { background: var(--danger); box-shadow: 0 0 0 3px rgba(208, 96, 79, 0.2); }
.me { color: var(--text-soft); }
.me b { color: var(--text); font-weight: 600; }
#sceneSel { display: flex; align-items: center; gap: 6px; }
#sceneSel select { background: var(--chrome-2); border: 1px solid var(--chrome-line); border-radius: 4px; height: 30px; padding: 0 6px; max-width: 240px; }
#sceneSel .pl { font-size: 12px; color: var(--gold); }

/* ---------- buttons ---------- */
.btn { height: 30px; padding: 0 12px; border-radius: 4px; cursor: pointer; background: var(--chrome-3); border: 1px solid var(--chrome-line); white-space: nowrap; }
.btn:hover:not(:disabled) { border-color: var(--gold); }
.btn:disabled { opacity: 0.45; cursor: default; }
.btn.primary { background: var(--gold); border-color: var(--gold); color: var(--ink); font-weight: 600; }
.btn.danger { color: var(--danger); }
.btn.sm { height: 26px; padding: 0 8px; font-size: 12px; }
.chip { height: 30px; padding: 0 10px; border-radius: 4px; cursor: pointer; background: var(--chrome-2); border: 1px solid var(--chrome-line); }
.chip.sm { height: 26px; font-size: 12px; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.row.end { justify-content: flex-end; }
.grow { flex: 1; }
input[type=text], input[type=number], input[type=password], input:not([type]), input[type=url], select, textarea {
  background: var(--chrome); border: 1px solid var(--chrome-line); border-radius: 4px; padding: 5px 8px; outline: none; min-width: 0;
}
input:focus, select:focus, textarea:focus { border-color: var(--gold); }
label { display: block; font-size: 12px; color: var(--text-soft); margin: 10px 0 3px; }
label.inline { display: inline-flex; gap: 6px; align-items: center; margin: 4px 0; color: var(--text); font-size: 13px; }

/* ---------- layout ---------- */
#app { position: fixed; left: 0; right: 0; top: var(--bar); bottom: 0; }
#stage { position: absolute; left: 48px; top: 0; bottom: 0; right: var(--side); background: #0b0d10; overflow: hidden; }
body.side-closed #stage { right: 0; }
#stage canvas { display: block; }
#tools { position: absolute; left: 0; top: 0; bottom: 0; width: 48px; background: var(--chrome); border-right: 1px solid var(--chrome-line);
  display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 0; z-index: 5; }
#tools button { width: 36px; height: 36px; border-radius: 5px; border: 1px solid transparent; background: none; cursor: pointer; color: var(--text-soft);
  display: flex; align-items: center; justify-content: center; font-size: 17px; line-height: 1; }
#tools button svg { width: 20px; height: 20px; }
#tools button:hover { color: #fff; background: var(--chrome-2); }
#tools button.on { color: var(--ink); background: var(--gold); }
#tools button:disabled { opacity: 0.3; }
#tools .sep { width: 26px; height: 1px; background: var(--chrome-line); margin: 4px 0; }
#layerBtn { font: 700 13px var(--sans) !important; }
#layerBtn.gmlayer { color: #fff !important; background: #7e3f56 !important; }
#subtools { position: absolute; left: 56px; top: 8px; z-index: 6; display: flex; gap: 4px; padding: 4px; background: var(--chrome); border: 1px solid var(--chrome-line); border-radius: 5px; box-shadow: 0 4px 14px rgba(0,0,0,0.4); }
#subtools button { height: 30px; padding: 0 10px; border-radius: 4px; background: none; border: 1px solid transparent; cursor: pointer; color: var(--text-soft); }
#subtools button:hover { color: #fff; background: var(--chrome-2); }
#subtools button.on { color: var(--ink); background: var(--gold); }
#subtools .sep { width: 1px; background: var(--chrome-line); margin: 3px 4px; }
#hud { position: absolute; left: 60px; bottom: 10px; z-index: 4; pointer-events: none; font-size: 12px; color: var(--text-soft);
  background: rgba(16, 19, 24, 0.8); border: 1px solid var(--chrome-line); border-radius: 4px; padding: 4px 9px; }
#hud:empty { display: none; }
#empty { position: absolute; left: 48px; right: var(--side); top: 0; bottom: 0; display: flex; align-items: center; justify-content: center; text-align: center; z-index: 3; }
#empty .box { max-width: 420px; padding: 24px; }
#empty h2 { font: 600 26px var(--serif); margin: 0 0 8px; }

/* ---------- side panel ---------- */
#side { position: absolute; right: 0; top: 0; bottom: 0; width: var(--side); background: var(--chrome); border-left: 1px solid var(--chrome-line); display: flex; flex-direction: column; z-index: 5; }
body.side-closed #side { display: none; }
.tabs { display: flex; border-bottom: 1px solid var(--chrome-line); flex: none; }
.tabs button { flex: 1; height: 38px; background: none; border: 0; border-bottom: 2px solid transparent; cursor: pointer; color: var(--text-soft); font-weight: 600; }
.tabs button:hover { color: #fff; }
.tabs button.on { color: #fff; border-bottom-color: var(--gold); }
.tab { display: none; flex: 1; min-height: 0; overflow-y: auto; padding: 10px 12px; }
.tab.on { display: block; }
#tab-chat.on { display: flex; flex-direction: column; padding: 0; overflow: hidden; }
.tab h3 { font: 600 11px var(--sans); letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-soft); margin: 14px 0 6px; }
.tab h3:first-child { margin-top: 2px; }

/* chat */
#chatlog { flex: 1; overflow-y: auto; padding: 8px 10px; display: flex; flex-direction: column; gap: 6px; }
.msg { padding: 6px 9px; border-radius: 5px; background: var(--chrome-2); border-left: 3px solid var(--c, var(--gold)); }
.msg .who { font-weight: 600; font-size: 12px; color: var(--c, var(--gold)); }
.msg .who .tag { font-weight: 400; color: var(--text-soft); margin-left: 6px; }
.msg .txt { white-space: pre-wrap; word-break: break-word; }
.msg.emote { background: none; font-style: italic; border-left-color: transparent; color: var(--text-soft); }
.msg.private { background: #241d2b; }
.msg.system { background: none; border: 0; color: var(--text-soft); font-size: 12px; text-align: center; }
.roll { display: flex; align-items: center; gap: 10px; margin-top: 3px; }
.roll .total { font: 700 26px/1 var(--serif); color: #fff; min-width: 34px; text-align: center; padding: 4px 6px; border-radius: 4px; background: rgba(0, 0, 0, 0.3); }
.roll .detail { font-size: 12px; color: var(--text-soft); }
.roll .detail .f { color: var(--text); }
.die { display: inline-block; min-width: 20px; padding: 0 4px; margin: 1px; text-align: center; border-radius: 3px; background: var(--chrome-3); color: var(--text); }
.die.max { color: var(--ok); } .die.min { color: var(--danger); }
.die.drop { opacity: 0.35; text-decoration: line-through; }
.roll .lbl { font-weight: 600; color: var(--text); }
#dicebar { display: flex; flex-wrap: wrap; gap: 4px; padding: 6px 10px; border-top: 1px solid var(--chrome-line); align-items: center; }
#dicebar button { height: 26px; padding: 0 8px; border-radius: 4px; background: var(--chrome-2); border: 1px solid var(--chrome-line); cursor: pointer; font-size: 12px; }
#dicebar button:hover { border-color: var(--gold); }
#dicebar label.inline { margin: 0 0 0 auto; font-size: 12px; }
.chatin { display: flex; flex-direction: column; gap: 4px; padding: 0 10px 10px; }
.chatin select { height: 26px; padding: 0 4px; font-size: 12px; align-self: flex-start; max-width: 100%; }
.chatbar { display: flex; align-items: center; gap: 6px; }
.chatbar select { flex: 0 1 auto; min-width: 0; }
.chatbar #clearChat { margin-left: auto; width: 26px; height: 26px; padding: 4px; border: 0; border-radius: 5px; background: none; color: var(--text-soft); cursor: pointer; }
.chatbar #clearChat:hover { background: #5a2222; color: #ffd9d9; }
.chatbar #clearChat svg { width: 100%; height: 100%; }
.msg.deletable { position: relative; }
.msg .msgdel { position: absolute; top: 3px; right: 3px; width: 22px; height: 22px; padding: 3px; border: 0; border-radius: 4px; background: rgba(20,22,27,.85); color: var(--text-soft); cursor: pointer; opacity: 0; transition: opacity .12s; z-index: 2; }
.msg.deletable:hover .msgdel { opacity: 1; }
.msg .msgdel:hover { background: #7a2525; color: #fff; }
.msg .msgdel svg { width: 100%; height: 100%; display: block; }
.chatin textarea { resize: none; height: 54px; }

/* initiative */
.initlist { display: flex; flex-direction: column; gap: 4px; margin-top: 6px; }
.irow { display: flex; align-items: center; gap: 8px; padding: 5px 8px; border-radius: 5px; background: var(--chrome-2); border: 1px solid transparent; cursor: pointer; }
.irow.cur { border-color: var(--gold); background: #2a2516; }
.irow.hid { opacity: 0.6; font-style: italic; }
.irow .nm { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.irow input { width: 52px; text-align: center; padding: 2px 4px; }
.irow .v { font: 700 16px var(--serif); min-width: 26px; text-align: center; }
.irow .x { background: none; border: 0; cursor: pointer; color: var(--text-soft); font-size: 16px; }
.irow .x:hover { color: var(--danger); }
.irow .av { width: 22px; height: 22px; border-radius: 50%; flex: none; background-size: cover; background-position: center; }
.round { font: 600 15px var(--serif); }

/* scenes */
.srow { display: flex; gap: 8px; align-items: center; padding: 6px; border-radius: 5px; background: var(--chrome-2); margin-bottom: 6px; border: 1px solid transparent; }
.srow.viewing { border-color: rgba(201, 164, 92, 0.6); }
.srow .th { width: 56px; height: 40px; flex: none; border-radius: 3px; background: #0b0d10 center / cover no-repeat; }
.srow .nm { flex: 1; min-width: 0; }
.srow .nm b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.srow .badge { font-size: 11px; color: var(--gold); }
.srow .acts { display: flex; flex-wrap: wrap; gap: 4px; justify-content: flex-end; max-width: 150px; }

/* players */
.link { display: flex; gap: 6px; align-items: center; margin: 4px 0; }
.link input { flex: 1; font-size: 12px; }
.prow { display: flex; align-items: center; gap: 8px; padding: 5px 0; border-bottom: 1px solid var(--chrome-line); }
.prow .dot { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.prow .nm { flex: 1; }

/* ---------- floating panels (token, wizard) ---------- */
#panels { position: absolute; inset: 0; pointer-events: none; z-index: 20; }
.panel { position: absolute; pointer-events: auto; width: 320px; max-height: calc(100% - 20px); display: flex; flex-direction: column;
  background: var(--chrome); border: 1px solid var(--chrome-line); border-radius: 6px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55); }
.panel .ph { display: flex; align-items: center; gap: 8px; padding: 8px 10px 8px 12px; border-bottom: 1px solid var(--chrome-line); cursor: move; user-select: none; }
.panel .ph b { flex: 1; font: 600 15px var(--serif); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.panel .ph button { background: none; border: 0; cursor: pointer; color: var(--text-soft); font-size: 18px; width: 26px; height: 26px; border-radius: 4px; }
.panel .ph button:hover { color: #fff; background: var(--chrome-3); }
.panel .pb { padding: 4px 12px 12px; overflow-y: auto; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.two > div > label { margin-top: 8px; }
.bar { display: flex; align-items: center; gap: 4px; }
.bar input { width: 100%; text-align: center; }
.conds { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; margin-top: 4px; }
.conds button { height: 26px; font-size: 11.5px; border-radius: 4px; background: var(--chrome-2); border: 1px solid var(--chrome-line); cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 0 4px; }
.conds button.on { background: var(--cc, var(--gold)); border-color: var(--cc, var(--gold)); color: #111; font-weight: 600; }
.owners { display: flex; flex-direction: column; gap: 2px; }
.tokimg { display: flex; align-items: center; gap: 10px; margin-top: 8px; }
.tokimg .pv { width: 56px; height: 56px; border-radius: 50%; background: #333 center / cover no-repeat; flex: none; border: 2px solid var(--chrome-line); display: flex; align-items: center; justify-content: center; font: 700 18px var(--serif); }

/* ---------- modal ---------- */
#modal { position: fixed; inset: 0; z-index: 100; background: rgba(5, 7, 10, 0.7); display: flex; align-items: center; justify-content: center; padding: 20px; }
.dialog { background: var(--chrome); border: 1px solid var(--chrome-line); border-radius: 8px; box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6); width: min(560px, 100%); max-height: 100%; display: flex; flex-direction: column; }
.dialog.wide { width: min(1240px, 100%); height: min(860px, 100%); }
.dialog .dh { display: flex; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--chrome-line); }
.dialog .dh h2 { flex: 1; margin: 0; font: 600 20px var(--serif); }
.dialog .dh button { background: none; border: 0; font-size: 22px; cursor: pointer; color: var(--text-soft); }
.dialog .db { padding: 12px 16px; overflow-y: auto; flex: 1; min-height: 0; }
.dialog .df { padding: 10px 16px; border-top: 1px solid var(--chrome-line); display: flex; gap: 8px; justify-content: flex-end; align-items: center; }

/* scene wizard */
.wiz { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 14px; height: 100%; }
.wiz .pvw { position: relative; background: #0b0d10; border-radius: 6px; overflow: hidden; min-height: 300px; }
.wiz .pvw canvas { position: absolute; inset: 0; width: 100%; height: 100%; cursor: grab; }
.wiz .pvw canvas.boxing { cursor: crosshair; }
.wiz .drop { position: absolute; inset: 14px; border: 2px dashed var(--chrome-line); border-radius: 8px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; text-align: center; color: var(--text-soft); padding: 20px; }
.wiz .drop.over { border-color: var(--gold); color: #fff; }
.wiz .drop b { font: 600 20px var(--serif); color: var(--text); }
.wiz .pvhint { position: absolute; left: 10px; bottom: 10px; font-size: 12px; color: var(--text-soft); background: rgba(16,19,24,0.85); padding: 3px 8px; border-radius: 4px; pointer-events: none; }
.wiz .side { overflow-y: auto; padding-right: 4px; }
.wiz .side h3 { font: 600 11px var(--sans); letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-soft); margin: 14px 0 4px; }
.wiz .side h3:first-child { margin-top: 0; }
.seg { display: flex; border: 1px solid var(--chrome-line); border-radius: 4px; overflow: hidden; }
.seg button { flex: 1; height: 28px; background: none; border: 0; border-right: 1px solid var(--chrome-line); cursor: pointer; font-size: 12px; color: var(--text-soft); }
.seg button:last-child { border-right: 0; }
.seg button.on { background: var(--gold); color: var(--ink); font-weight: 600; }
.nudge { display: grid; grid-template-columns: repeat(3, 30px); grid-template-rows: repeat(3, 26px); gap: 2px; }
.nudge button { background: var(--chrome-2); border: 1px solid var(--chrome-line); border-radius: 3px; cursor: pointer; font-size: 12px; padding: 0; }
.nudge button:hover { border-color: var(--gold); }
.detect { font-size: 12px; padding: 6px 8px; border-radius: 4px; background: var(--chrome-2); margin-top: 6px; }
.detect.good { color: var(--ok); } .detect.poor { color: #e0b050; }
input[type=range] { width: 100%; accent-color: var(--gold); }
input[type=checkbox] { accent-color: var(--gold); }

/* campaigns page */
#campaigns { position: fixed; left: 0; right: 0; top: var(--bar); bottom: 0; overflow-y: auto; padding: 40px 20px; }
#campaigns .wrap { max-width: 640px; margin: 0 auto; }
#campaigns h1 { font: 600 32px var(--serif); margin: 0 0 18px; }
.crow { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 6px; background: var(--chrome); border: 1px solid var(--chrome-line); margin-bottom: 8px; cursor: pointer; text-decoration: none; color: inherit; }
.crow:hover { border-color: var(--gold); }
.crow b { font: 600 18px var(--serif); flex: 1; }
.crow .mode { font-size: 11px; font-weight: 700; letter-spacing: 0.06em; padding: 2px 7px; border-radius: 3px; background: var(--chrome-3); color: var(--gold); }

/* toasts, banner */
#toasts { position: fixed; z-index: 200; left: 50%; bottom: 20px; transform: translateX(-50%); display: flex; flex-direction: column; gap: 6px; align-items: center; pointer-events: none; }
.toast { background: #20262f; border: 1px solid var(--chrome-line); border-radius: 5px; padding: 7px 14px; box-shadow: 0 4px 14px rgba(0,0,0,0.5); max-width: 520px; }
.toast.bad { border-color: var(--danger); }
#banner { position: fixed; z-index: 150; top: calc(var(--bar) + 10px); left: 50%; transform: translateX(-50%); background: var(--gold); color: var(--ink); padding: 7px 14px; border-radius: 5px; font-weight: 600; box-shadow: 0 4px 14px rgba(0,0,0,0.4); }

/* login */
.loginpage { display: flex; align-items: center; justify-content: center; min-height: 100%; overflow: auto; }
.logincard { width: min(360px, calc(100% - 32px)); padding: 28px; background: var(--chrome); border: 1px solid var(--chrome-line); border-radius: 8px; box-shadow: 0 20px 60px rgba(0,0,0,0.5); }
.logincard h1 { font: 600 22px var(--serif); margin: 0 0 4px; text-align: center; }
.logincard #sub { text-align: center; margin: 0 0 6px; }
.logincard input { width: 100%; height: 36px; }
.logincard .btn { width: 100%; height: 38px; margin-top: 16px; }

@media (max-width: 900px) {
  :root { --side: 300px; }
  #views a { padding: 0 7px; }
  .me { display: none; }
}
@media (max-width: 700px) {
  #sceneSel, .me, #views a:not(.on) { display: none !important; }
  .crumb { font-size: 13px; max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  #topbar { gap: 8px; }
  #stage, #empty { right: 0; }
  #side { width: 100%; top: auto; height: 46%; }
  .wiz { grid-template-columns: 1fr; grid-template-rows: 1fr auto; }
  .wiz .side { max-height: 40vh; }
}

/* quick rolls */
.pair .two { display: grid; grid-template-columns: 1fr 1fr; margin-top: 4px; border: 1px solid var(--chrome-line); border-radius: 5px; overflow: hidden; background: rgba(0,0,0,0.3); }
.pair .pbox { text-align: center; font: 700 24px/1 var(--serif); color: #fff; padding: 8px 0; cursor: help; }
.pair .pbox + .pbox { border-left: 1px solid var(--chrome-line); color: rgba(255,255,255,0.75); }
.pair .plabel { text-align: center; font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-soft); margin-top: 3px; }
.die.third { opacity: 0.55; border: 1px dashed rgba(232,226,208,0.5); margin-left: 4px; }
.three .advline { font-size: 11px; color: var(--text-soft); margin-top: 3px; }
/* sheet roll templates draw inside their own shadow root */
.msg.r20 { padding: 4px 0 2px; background: none; border-left: 0; }
.msg.r20 .who { padding-left: 2px; }
.r20body { margin-top: 2px; }

/* characters */
.crow2 { display: flex; align-items: center; gap: 8px; padding: 6px; border-radius: 5px; background: var(--chrome-2); margin-bottom: 5px; }
.crow2 .nm { flex: 1; min-width: 0; background: none; border: 0; text-align: left; cursor: pointer; padding: 0; }
.crow2 .nm b { display: block; font: 600 15px var(--serif); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.crow2 .nm:hover b { color: var(--gold); }
.av { width: 34px; height: 34px; border-radius: 50%; flex: none; background: var(--chrome-3) center / cover no-repeat; display: inline-flex; align-items: center; justify-content: center; font: 700 13px var(--serif); color: var(--text-soft); }
.av.big { width: 64px; height: 64px; }
.panel.sheetpanel { resize: both; overflow: hidden; min-width: 360px; min-height: 260px; max-height: none; }
.panel.sheetpanel .sheetframe { flex: 1; width: 100%; border: 0; background: #fff; }
.tokchar { margin-top: 6px; padding-bottom: 8px; border-bottom: 1px solid var(--chrome-line); }
body.dragging iframe { pointer-events: none; }

.crow2[draggable=true] { cursor: grab; }
.cfold { margin-bottom: 5px; border-radius: 5px; }
.cfold .cfh { display: flex; align-items: center; gap: 6px; padding: 4px 6px; border-radius: 5px; }
.cfold .cfh:hover { background: var(--chrome-2); }
.cfold .cfh .nm { flex: 1; min-width: 0; display: flex; align-items: center; gap: 6px; background: none; border: 0; color: inherit; cursor: pointer; padding: 2px 0; text-align: left; }
.cfold .cfh .nm b { font: 600 14px var(--serif); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cfold .tw { width: 10px; color: var(--text-soft); }
.cfold .fi { font-size: 13px; }
.cfold .cfb { padding-left: 14px; border-left: 1px solid var(--chrome-line); margin-left: 10px; }
.cloose { min-height: 24px; border-radius: 5px; }
.cloose .droptip { display: none; margin: 4px; }
body.chardrag .cloose .droptip { display: block; }
.dropping { outline: 2px dashed var(--gold); outline-offset: 1px; }

/* stand-in for Roll20 Pictos icons in sheet chat cards (see sheetbase.css) */
@font-face { font-family: "pictos"; src: url("/table/vendor/vtt-icons.woff2") format("woff2"); }

.av.hav { border-radius: 4px; font-size: 17px; }

#subtools { flex-wrap: wrap; max-width: calc(100% - 70px); align-items: center; }
#subtools .subfield { display: inline-flex; align-items: center; gap: 4px; color: var(--text-soft); font-size: 12px; padding: 0 4px; }
#subtools input[type=number], #subtools select { height: 26px; background: var(--chrome-2); color: var(--text); border: 1px solid var(--chrome-line); border-radius: 4px; padding: 0 4px; font: inherit; font-size: 12px; }
#subtools input[type=color] { width: 30px; height: 24px; padding: 0; border: 1px solid var(--chrome-line); background: none; border-radius: 4px; }
.tokvision .row { gap: 6px; align-items: center; flex-wrap: wrap; }
.tokvision input[type=number] { height: 26px; }
.tokvision .btn.on { background: var(--gold); color: var(--ink); border-color: var(--gold); }

/* Many Windows PCs have only an italic "Helvetica" installed, which turned every sheet slanted.
   Inside sheets these names now mean Arial (any PC has it), upright unless a sheet asks for italic. */
@font-face { font-family: "Helvetica Neue"; font-weight: 400; font-style: normal; src: local("Arial"), local("ArialMT"), local("Liberation Sans"), local("DejaVu Sans"); }
@font-face { font-family: "Helvetica Neue"; font-weight: 700; font-style: normal; src: local("Arial Bold"), local("Arial-BoldMT"), local("Liberation Sans Bold"), local("DejaVu Sans Bold"); }
@font-face { font-family: "Helvetica Neue"; font-weight: 400; font-style: italic; src: local("Arial Italic"), local("Arial-ItalicMT"), local("Liberation Sans Italic"), local("DejaVu Sans Oblique"); }
@font-face { font-family: "Helvetica Neue"; font-weight: 700; font-style: italic; src: local("Arial Bold Italic"), local("Arial-BoldItalicMT"), local("Liberation Sans Bold Italic"), local("DejaVu Sans Bold Oblique"); }
@font-face { font-family: "Helvetica"; font-weight: 400; font-style: normal; src: local("Arial"), local("ArialMT"), local("Liberation Sans"), local("DejaVu Sans"); }
@font-face { font-family: "Helvetica"; font-weight: 700; font-style: normal; src: local("Arial Bold"), local("Arial-BoldMT"), local("Liberation Sans Bold"), local("DejaVu Sans Bold"); }
@font-face { font-family: "Helvetica"; font-weight: 400; font-style: italic; src: local("Arial Italic"), local("Arial-ItalicMT"), local("Liberation Sans Italic"), local("DejaVu Sans Oblique"); }
@font-face { font-family: "Helvetica"; font-weight: 700; font-style: italic; src: local("Arial Bold Italic"), local("Arial-BoldItalicMT"), local("Liberation Sans Bold Italic"), local("DejaVu Sans Bold Oblique"); }

.panel .ph .styleSw { font: 600 11px var(--sans); color: var(--gold); border: 1px solid var(--chrome-line); border-radius: 4px; padding: 2px 7px; width: auto; }

/* the world map and wiki, shown inside the table */
#worldFrame { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; z-index: 4; background: #0b0d10; }
body.worldview #tools, body.worldview #subtools, body.worldview #hud, body.worldview #empty { display: none !important; }
body.worldview #stage { left: 0; }
.srow .th.world { background: linear-gradient(135deg, #2d4a5e, #4f6b3a); display: flex; align-items: center; justify-content: center; font-size: 18px; }

/* jukebox */
#tab-audio h3 { margin-top: 18px; }
.astrip { background: var(--chrome-2); border-radius: 6px; padding: 8px 10px; margin-bottom: 8px; }
.astrip .ahead { display: flex; gap: 8px; align-items: baseline; }
.astrip .ahead .np { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.astrip .prog { height: 3px; background: var(--chrome-3); border-radius: 2px; margin: 6px 0; overflow: hidden; }
.astrip .prog i { display: block; height: 100%; width: 0; background: var(--gold); transition: width 1s linear; }
#tab-audio .arow { display: flex; gap: 6px; align-items: center; margin: 4px 0; }
#tab-audio .arow input[type=range] { flex: 1; min-width: 60px; accent-color: var(--gold); }
#tab-audio .arow.at input[type=text] { min-width: 0; }
#tab-audio .grow { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#tab-audio .btn.on { background: var(--gold); color: var(--ink); border-color: var(--gold); }
#tab-audio select { max-width: 110px; }
.aud-mine { margin-top: 20px; border-top: 1px solid var(--chrome-line); padding-top: 4px; }
.aud-mine .arow span { width: 78px; color: var(--text-soft); font-size: 12px; }
.achips { display: flex; flex-wrap: wrap; gap: 6px; }
.achip { display: inline-flex; align-items: center; background: var(--chrome-2); border-radius: 5px; }
.achip .x { background: none; border: 0; color: var(--text-soft); cursor: pointer; padding: 0 6px; font-size: 15px; }
.aboard { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 6px; }
.aboard .btn { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.alist { border-radius: 5px; margin-bottom: 4px; }
.alist .nm { flex: 1; min-width: 0; text-align: left; background: none; border: 0; color: inherit; cursor: pointer; padding: 2px 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.alist.open { background: var(--chrome-2); padding: 4px 8px 8px; }
.aedit { padding: 4px 0 0 4px; }
.adrop { border: 1px dashed var(--chrome-line); border-radius: 6px; padding: 14px; text-align: center; color: var(--text-soft); font-size: 12px; cursor: pointer; margin: 6px 0; }
.adrop.over { border-color: var(--gold); color: var(--gold); }
#joinAudio { margin-right: 8px; }
#side .tabs button { padding: 0 3px; font-size: 12.5px; white-space: nowrap; }

.astrip .btn.sm { min-width: 30px; font-size: 13px; }
body.chardrag .sheetpanel iframe { pointer-events: none; }

/* a switch (the world map's edit mode) */
.switch { display: inline-flex; align-items: center; gap: 8px; height: 30px; padding: 0 6px 0 10px; margin-right: 10px; border: 1px solid var(--chrome-line); border-radius: 15px; background: none; cursor: pointer; color: var(--text-soft); font: 600 12px var(--sans); letter-spacing: 0.03em; }
.switch[hidden] { display: none; }
.switch:hover { color: #fff; border-color: rgba(201,164,92,0.5); }
.switch .track { width: 32px; height: 18px; border-radius: 9px; background: rgba(255,255,255,0.14); position: relative; transition: background 0.15s; }
.switch .knob { position: absolute; left: 2px; top: 2px; width: 14px; height: 14px; border-radius: 50%; background: #e8e2d0; transition: left 0.15s; }
.switch.on { color: #fff; border-color: var(--gold); }
.switch.on .track { background: var(--gold); }
.switch.on .knob { left: 16px; background: #1d1a16; }

/* hiding the side bar */
#sideBtn { margin-left: 8px; width: 30px; height: 30px; border-radius: 5px; border: 1px solid var(--chrome-line); background: none; color: var(--text-soft); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
#sideBtn:hover { color: #fff; border-color: rgba(201,164,92,0.5); }
#sideBtn svg { width: 18px; height: 18px; }
body.side-closed #sideBtn { color: var(--gold); }
body.side-closed #empty { right: 0; }

/* a sheet or handout panel folded down to its title bar (double-click the title) */
.panel.sheetpanel.min { height: auto !important; min-height: 0; resize: none; width: 300px !important; min-width: 0; }
.panel.sheetpanel.min iframe { display: none; }
.panel.sheetpanel .ph { cursor: move; }

/* jukebox, second pass */
#tab-audio .asec { margin-bottom: 6px; }
#tab-audio h3 { margin: 14px 0 8px; }
#tab-audio .ib { width: 28px; height: 28px; border-radius: 6px; border: 1px solid transparent; background: none; color: var(--text-soft); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; flex: none; padding: 0; }
#tab-audio .ib svg { width: 16px; height: 16px; }
#tab-audio .ib:hover { color: #fff; background: var(--chrome-3); }
#tab-audio .ib.on { color: var(--gold); }
#tab-audio .ib.big { width: 34px; height: 34px; border-radius: 50%; background: var(--gold); color: #1d1a16; }
#tab-audio .ib.big svg { width: 18px; height: 18px; }
#tab-audio .ib.big.off { background: var(--chrome-3); color: var(--text-soft); }
#tab-audio .ib.off { opacity: 0.35; cursor: default; }
#tab-audio .ib.pl { color: var(--gold); }
#tab-audio .ib.pl.on { background: var(--gold); color: #1d1a16; }
.astrip.live { box-shadow: inset 3px 0 0 var(--gold); }
.astrip .np { font-size: 13px; }
.astrip.fx .np { font-size: 12px; }
#tab-audio .volic { color: var(--text-soft); display: inline-flex; margin-left: 4px; }
#tab-audio .volic svg { width: 16px; height: 16px; }
#tab-audio .arow.small { font-size: 12px; }
.albl { width: 78px; color: var(--text-soft); font-size: 12px; flex: none; }
.achip .go { background: none; border: 0; color: var(--text); cursor: pointer; padding: 5px 4px 5px 10px; font: inherit; font-size: 13px; }
.achip .go:hover { color: var(--gold); }
#tab-audio .x { background: none; border: 0; color: var(--text-soft); cursor: pointer; font-size: 16px; width: 22px; flex: none; }
#tab-audio .x:hover { color: #e07060; }
.libhead { display: flex; align-items: center; gap: 6px; }
.libhead h3 { flex: 1; }
.afilter { width: 100%; height: 30px; margin-bottom: 6px; background: var(--chrome-2); color: var(--text); border: 1px solid var(--chrome-line); border-radius: 5px; padding: 0 8px; font: inherit; }
.folder { border-radius: 6px; margin-bottom: 4px; border: 1px solid transparent; }
.folder.open { background: rgba(255,255,255,0.025); border-color: var(--chrome-line); }
.folder.over, .asec.lib.over { border-color: var(--gold); background: rgba(201,164,92,0.08); }
.folder.live .fn { color: var(--gold); }
.fhead { display: flex; align-items: center; gap: 4px; padding: 3px 4px; }
.fhead .tw { background: none; border: 0; color: var(--text-soft); cursor: pointer; width: 18px; padding: 0; }
.fhead .fic { color: #b89656; display: inline-flex; }
.fhead .fic svg { width: 17px; height: 17px; }
.fhead .fn { cursor: pointer; font: 600 13.5px var(--sans); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fhead input, .srow input { height: 26px; background: var(--chrome-2); color: var(--text); border: 1px solid var(--gold); border-radius: 4px; padding: 0 6px; font: inherit; min-width: 0; }
.fbody { padding: 0 4px 4px 22px; }
.folder.unsorted .fbody { padding-left: 4px; }
.srow { display: flex; align-items: center; gap: 4px; padding: 2px 2px; border-radius: 5px; cursor: grab; }
.srow:hover { background: var(--chrome-2); }
.srow.live .tn { color: var(--gold); }
.srow .tn { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.srow .dur { width: 34px; text-align: right; flex: none; }
.kind { flex: none; font: 600 10.5px var(--sans); letter-spacing: 0.03em; border-radius: 9px; padding: 2px 7px; border: 1px solid; background: none; cursor: pointer; }
.kind.k-music { color: #8fb4e8; border-color: rgba(143,180,232,0.4); }
.kind.k-ambience { color: #8fd18f; border-color: rgba(143,209,143,0.4); }
.kind.k-effects { color: #e0a060; border-color: rgba(224,160,96,0.45); }
.aboard { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 6px; padding: 4px 6px 8px 22px; }
.aboard .pad { height: 44px; border-radius: 6px; border: 1px solid rgba(224,160,96,0.35); background: linear-gradient(#2a2420, #201b18); color: #f0d8b8; cursor: pointer; font: 600 12px var(--sans); padding: 0 6px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aboard .pad:hover { border-color: #e0a060; }
.aboard .pad:active { transform: scale(0.97); background: #3a2e24; }
.folder .empty { margin: 4px 0 6px; }

/* a token's right-click menu */
/* token HUD: icon columns round the token */
.tokhud { position: fixed; inset: 0; z-index: 300; pointer-events: none; }
.tokhud > * { position: fixed; pointer-events: auto; }
.tokhud .hcol { display: flex; flex-direction: column; gap: 6px; animation: hudin .14s ease-out; }
.tokhud .hcol.l { --dx: 8px; } .tokhud .hcol.r { --dx: -8px; }
@keyframes hudin { from { opacity: 0; transform: translateX(var(--dx, 0)) scale(.96); } }
.tokhud .hb { position: relative; width: 40px; height: 40px; display: grid; place-items: center; padding: 0; border-radius: 11px; cursor: pointer;
  color: #eadfc6; background: linear-gradient(180deg, rgba(44,38,32,.92), rgba(22,19,16,.94)); border: 1px solid rgba(201,164,92,.28);
  box-shadow: 0 6px 16px rgba(0,0,0,.55), inset 0 1px 0 rgba(255,255,255,.06); backdrop-filter: blur(6px); transition: transform .1s, border-color .1s, color .1s, box-shadow .1s; }
.tokhud .hb .ic { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.tokhud .hb:hover { transform: translateY(-1px); border-color: rgba(201,164,92,.85); color: #fff; box-shadow: 0 0 0 3px rgba(201,164,92,.16), 0 8px 18px rgba(0,0,0,.6); }
.tokhud .hb.on { color: #1b150d; background: linear-gradient(180deg, #e2c27c, #b88d43); border-color: #f0d9a2; }
.tokhud .hb.open { border-color: #e2c27c; box-shadow: 0 0 0 3px rgba(201,164,92,.3), 0 8px 18px rgba(0,0,0,.6); }
.tokhud .hb.danger:hover { color: #ff9b86; border-color: #c0584a; box-shadow: 0 0 0 3px rgba(192,88,74,.2); }
.tokhud .hb::after { content: attr(data-tip); position: absolute; top: 50%; transform: translateY(-50%); white-space: nowrap; pointer-events: none; opacity: 0; transition: opacity .12s;
  font: 600 12px var(--sans, system-ui); color: #f3ead6; background: rgba(14,12,10,.92); border: 1px solid rgba(201,164,92,.35); border-radius: 6px; padding: 4px 8px; }
.tokhud .hcol.l .hb::after { right: calc(100% + 8px); }
.tokhud .hcol.r .hb::after, .tokhud .hptop .hb::after { left: calc(100% + 8px); }
.tokhud .hb:hover::after { opacity: 1; }
.tokhud .hptop { display: flex; align-items: center; gap: 6px; animation: hudin .14s ease-out; }
.tokhud .hptop .hb { width: 30px; height: 30px; border-radius: 9px; }
.tokhud .hptop .hb .ic { width: 16px; height: 16px; stroke-width: 2.2; }
.tokhud .hptop .hb::after { display: none; }
.tokhud .hpbox { position: relative; display: flex; align-items: baseline; gap: 4px; height: 38px; padding: 0 12px; border-radius: 11px; overflow: hidden;
  background: linear-gradient(180deg, rgba(44,38,32,.95), rgba(22,19,16,.96)); border: 1px solid rgba(201,164,92,.35); box-shadow: 0 6px 16px rgba(0,0,0,.55); align-items: center; }
.tokhud .hpbox .hpbar { position: absolute; left: 0; bottom: 0; height: 3px; width: calc(var(--k) * 100%); background: var(--hc); }
.tokhud .hpv { width: 52px; background: none; border: 0; color: #fff; font: 700 21px var(--serif); text-align: right; outline: none; padding: 0; }
.tokhud .hpv:focus { color: var(--gold); }
.tokhud .hpm { color: #b9ab90; font: 600 14px var(--serif); }

.tokhud .hpop { width: 286px; padding: 10px; border-radius: 13px; background: linear-gradient(180deg, rgba(38,33,28,.97), rgba(20,17,14,.98)); border: 1px solid rgba(201,164,92,.4);
  box-shadow: 0 16px 40px rgba(0,0,0,.65); animation: hudin .14s ease-out; color: #eadfc6; }
.tokhud .hpop .pt { font: 600 11px var(--sans, system-ui); letter-spacing: .1em; text-transform: uppercase; color: #b9ab90; margin: 0 2px 8px; }
.tokhud .cgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; }
.tokhud .ct { display: flex; align-items: center; gap: 6px; padding: 4px 6px 4px 4px; border-radius: 8px; border: 1px solid transparent; background: rgba(255,255,255,.035); color: #cfc3aa; cursor: pointer; font: 12px var(--sans, system-ui); text-align: left; min-width: 0; }
.tokhud .ct .cb { flex: none; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font: 700 10px system-ui; color: #141210; background: color-mix(in srgb, var(--cc) 55%, #3a332b); }
.tokhud .ct .cn { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tokhud .ct:hover { background: rgba(255,255,255,.08); color: #fff; }
.tokhud .ct.on { border-color: var(--cc); background: color-mix(in srgb, var(--cc) 22%, transparent); color: #fff; }
.tokhud .ct.on .cb { background: var(--cc); box-shadow: 0 0 0 2px rgba(0,0,0,.4), 0 0 10px var(--cc); }
.tokhud .lrow { display: flex; gap: 6px; }
.tokhud .lt { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 4px 6px; border-radius: 10px; border: 1px solid rgba(201,164,92,.18); background: rgba(255,255,255,.035); color: #cfc3aa; cursor: pointer; font: 12px var(--sans, system-ui); }
.tokhud .lt .ic, .tokhud .seg .ic, .tokhud .step .ic { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.tokhud .lt:hover { color: #fff; border-color: rgba(201,164,92,.6); }
.tokhud .lt.on { color: #ffd58a; border-color: #e2c27c; background: radial-gradient(circle at 50% 30%, rgba(255,190,90,.25), rgba(255,255,255,.03) 70%); }
.tokhud .pclear { margin-top: 8px; width: 100%; background: none; border: 0; color: #b9ab90; font: 12px var(--sans, system-ui); cursor: pointer; padding: 4px; border-radius: 6px; }
.tokhud .pclear:hover { color: var(--gold); background: rgba(255,255,255,.04); }
.tokhud .seg { display: flex; gap: 6px; margin-bottom: 8px; }
.tokhud .seg button { flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px; height: 34px; border-radius: 9px; border: 1px solid rgba(201,164,92,.2); background: rgba(255,255,255,.035); color: #cfc3aa; cursor: pointer; font: 12px var(--sans, system-ui); }
.tokhud .seg button .ic { width: 18px; height: 18px; }
.tokhud .seg button:hover { color: #fff; border-color: rgba(201,164,92,.6); }
.tokhud .seg button.on { color: #1b150d; background: linear-gradient(180deg, #e2c27c, #b88d43); border-color: #f0d9a2; }
.tokhud .step { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; }
.tokhud .step .sl { flex: 1; font: 12px var(--sans, system-ui); color: #b9ab90; }
.tokhud .step b { min-width: 52px; text-align: center; font: 700 15px var(--serif); color: #fff; }
.tokhud .step button { width: 32px; height: 30px; display: grid; place-items: center; border-radius: 8px; border: 1px solid rgba(201,164,92,.25); background: rgba(255,255,255,.04); color: #eadfc6; cursor: pointer; }
.tokhud .step button .ic { width: 15px; height: 15px; stroke-width: 2.2; }
.tokhud .step button:hover { border-color: #e2c27c; color: #fff; }
.tokhud .hpop.condpop { width: 380px; }

/* ───────── item cards ───────── */
.icard { --w: 250px; --f1: #a08562; --f2: #5c4630; --a1: #f3e6c4; --a2: #a88a5c; --g1: #e8d9b0; --g2: #9c7f52;
  position: relative; flex: none; width: var(--w); aspect-ratio: 63 / 88; font-size: calc(var(--w) / 21); border-radius: calc(var(--w) * 0.048);
  padding: calc(var(--w) * 0.032); background: #0d0b09; box-shadow: 0 10px 30px rgba(0,0,0,.55), 0 0 0 1px rgba(255,255,255,.06); color: #1d1912; user-select: none; text-align: left; }
.icard.r-common { --f1: #d4d4cc; --f2: #75756e; --a1: #f4f4ef; --a2: #a9a9a0; --g1: #fff; --g2: #9a9a92; }
.icard.r-uncommon { --f1: #62b273; --f2: #1f4b29; --a1: #d6f2d4; --a2: #5f9e64; --g1: #b8f5c0; --g2: #2f8a40; }
.icard.r-rare { --f1: #5b92dc; --f2: #18376a; --a1: #d6e8fb; --a2: #5a86c4; --g1: #bfe0ff; --g2: #2c64b8; }
.icard.r-very-rare { --f1: #a670d4; --f2: #3f1c62; --a1: #ecdcf8; --a2: #8a5ab8; --g1: #ecc9ff; --g2: #7b3cb4; }
.icard.r-legendary { --f1: #eba64a; --f2: #74380c; --a1: #fbe8c4; --a2: #d08a3a; --g1: #ffe3a6; --g2: #d0761c; }
.icard.r-artifact { --f1: #dc5a44; --f2: #561206; --a1: #f8d6cc; --a2: #c45a44; --g1: #ffc2b4; --g2: #b42e1c; }
.icard.r-varies { --f1: #48bcac; --f2: #104c44; --a1: #d0f3ee; --a2: #46a094; --g1: #b4f7ee; --g2: #1c9484; }
.icard .cframe { height: 100%; display: flex; flex-direction: column; gap: .32em; padding: .42em; border-radius: calc(var(--w) * 0.03);
  background: radial-gradient(120% 60% at 50% 0%, rgba(255,255,255,.28), transparent 60%), repeating-linear-gradient(135deg, rgba(0,0,0,.05) 0 2px, transparent 2px 5px), linear-gradient(160deg, var(--f1), var(--f2));
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.25), inset 0 0 1.4em rgba(0,0,0,.35); }
.icard .ct, .icard .cty { display: flex; align-items: center; gap: .4em; padding: .22em .55em; border-radius: .5em / .9em;
  background: linear-gradient(180deg, #f8efda, #d8c7a2); box-shadow: 0 0 0 .1em rgba(0,0,0,.65), inset 0 .1em 0 rgba(255,255,255,.7), 0 .15em .3em rgba(0,0,0,.35); }
.icard .cn { flex: 1; min-width: 0; font: 700 1.08em/1.15 var(--serif); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: .01em; }
.icard .cc { flex: none; font: 600 .78em/1 var(--serif); color: #4a3b26; background: radial-gradient(circle at 35% 30%, #fff6d0, #d9b25a 60%, #8a6420); border-radius: 1em; padding: .25em .5em; box-shadow: 0 0 0 .08em rgba(0,0,0,.5); }
.icard .ca { position: relative; flex: 0 0 43%; display: grid; place-items: center; overflow: hidden; border-radius: .2em;
  background: radial-gradient(circle at 50% 42%, var(--a1), var(--a2) 75%, var(--f2)); box-shadow: 0 0 0 .12em rgba(0,0,0,.7), inset 0 0 1.6em rgba(0,0,0,.35); }
.icard .ca::before { content: ''; position: absolute; inset: 0; background: repeating-radial-gradient(circle at 50% 42%, rgba(255,255,255,.08) 0 .4em, transparent .4em 1.1em); }
.icard .ca .iart { position: relative; width: 70%; height: 82%; filter: drop-shadow(0 .25em .25em rgba(0,0,0,.45)); }
.icard.k-magic .ca .iart { filter: drop-shadow(0 0 .6em var(--g1)) drop-shadow(0 .25em .25em rgba(0,0,0,.45)); }
.icard .ca img { position: relative; width: 100%; height: 100%; object-fit: cover; }
.icard .cty { padding: .18em .55em; }
.icard .cyt { flex: 1; min-width: 0; font: 600 .8em/1.2 var(--serif); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.icard .crr { flex: none; width: .78em; height: .78em; transform: rotate(45deg); background: linear-gradient(135deg, var(--g1), var(--g2)); box-shadow: 0 0 0 .1em #1d1912, 0 0 .35em var(--g2); }
.icard.r-mundane .crr { background: linear-gradient(135deg, #5a4a34, #2a2116); box-shadow: 0 0 0 .1em #1d1912; }
.icard .cx { flex: 1; min-height: 0; overflow: auto; padding: .45em .6em .5em; border-radius: .2em; font: .8em/1.32 var(--serif); color: #221c14;
  background: linear-gradient(180deg, rgba(255,255,255,.35), transparent 30%), #ede2c8; box-shadow: 0 0 0 .12em rgba(0,0,0,.6), inset 0 0 1em rgba(120,90,40,.18); scrollbar-width: thin; scrollbar-color: rgba(90,70,40,.45) transparent; }
.icard .cprops { font-style: italic; font-weight: 600; color: #4a3b26; margin-bottom: .35em; }
.icard .catt { font-style: italic; color: #6b3a1c; margin-bottom: .35em; }
.icard .ctext p { margin: 0 0 .45em; } .icard .ctext p:last-child { margin-bottom: 0; }
.icard .ctext table { width: 100%; border-collapse: collapse; margin: .3em 0 .5em; font-size: .92em; }
.icard .ctext th, .icard .ctext td { border-bottom: 1px solid rgba(90,70,40,.3); padding: .12em .25em; text-align: left; vertical-align: top; }
.icard .ctext th { font-weight: 700; }
.icard .ctext ul { margin: .2em 0 .45em 1.1em; padding: 0; }
.icard .cnotes { margin-top: .5em; padding-top: .35em; border-top: 1px dashed rgba(90,70,40,.5); font-style: italic; color: #5a3a1c; }
.icard .cflav { font-style: italic; color: #6b5a40; text-align: center; padding-top: .8em; }
.icard .cb { display: flex; align-items: center; justify-content: space-between; gap: .4em; min-height: 1.3em; padding: 0 .2em; }
.icard .cw { font: italic .7em/1 var(--serif); color: rgba(255,255,255,.85); text-shadow: 0 1px 1px rgba(0,0,0,.6); }
.icard .cs { margin: -.5em -.1em -.15em 0; padding: .28em .6em; border-radius: .4em; font: 700 .86em/1 var(--serif); color: #1d1912; white-space: nowrap;
  background: linear-gradient(180deg, #f8efda, #cdb98f); box-shadow: 0 0 0 .1em rgba(0,0,0,.7), 0 .2em .4em rgba(0,0,0,.4); }
.icard .cq { position: absolute; top: -.5em; right: -.5em; min-width: 1.9em; height: 1.9em; padding: 0 .35em; border-radius: 1em; display: grid; place-items: center;
  font: 700 .95em/1 var(--sans); color: #1b150d; background: linear-gradient(180deg, #f0d9a2, #c9a45c); box-shadow: 0 0 0 .12em #0d0b09, 0 .2em .4em rgba(0,0,0,.5); }
.icard.mini { --w: 124px; font-size: 10px; cursor: pointer; transition: transform .12s, box-shadow .12s; }
.icard.mini .cframe { padding: 4px; gap: 4px; }
.icard.mini .ct { padding: 3px 6px; border-radius: 5px; min-height: 2.9em; }
.icard.mini .cn { font-size: 11px; line-height: 1.15; white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.icard.mini .ca { flex: 1; }
.icard.mini .cty { padding: 2px 6px; border-radius: 5px; }
.icard.mini .cyt { font-size: 9px; }
.icard.mini .cb { min-height: 0; }
.icard.mini .cw { font-size: 9px; }
.icard.mini .cs { font-size: 10px; padding: 2px 5px; margin: -4px 0 0; }
.icard.mini:hover { transform: translateY(-4px) rotate(-1deg); box-shadow: 0 14px 30px rgba(0,0,0,.6), 0 0 0 2px rgba(201,164,92,.7); }
.icard.big { --w: min(330px, 80vw); cursor: pointer; }
/* a card up close */
.cardview { position: fixed; inset: 0; z-index: 400; display: grid; place-items: center; background: radial-gradient(circle at 50% 45%, rgba(10,8,6,.35), rgba(5,4,3,.75)); backdrop-filter: blur(2px); animation: cvin .16s ease-out; }
@keyframes cvin { from { opacity: 0; } }
.cardview .cvwrap { display: flex; flex-direction: column; align-items: center; gap: 12px; animation: cvpop .2s cubic-bezier(.2,.9,.3,1.2); }
@keyframes cvpop { from { transform: translateY(14px) scale(.94); opacity: 0; } }
.cardview .icard.big { box-shadow: 0 30px 70px rgba(0,0,0,.7), 0 0 0 1px rgba(255,255,255,.08); }
.cardview .icard.big.r-legendary, .cardview .icard.big.r-artifact, .cardview .icard.big.r-very-rare { box-shadow: 0 30px 70px rgba(0,0,0,.7), 0 0 40px color-mix(in srgb, var(--g2) 55%, transparent); }
.cardview .cvacts { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; max-width: 520px; }
.cardview .cvacts .btn, .cardview .cvacts select { height: 30px; }
.cardview .cvacts .qty { display: inline-flex; align-items: center; gap: 6px; padding: 0 6px; border-radius: 6px; background: var(--chrome-2); border: 1px solid var(--chrome-line); }
.cardview .cvacts .qty button { width: 24px; height: 24px; border: 0; border-radius: 4px; background: var(--chrome-3); color: var(--text); cursor: pointer; }
.cardview .cvcredit { font-size: 11px; color: rgba(255,255,255,.45); }
.cardview .cvx { position: fixed; top: 14px; right: 18px; width: 36px; height: 36px; border-radius: 50%; border: 1px solid rgba(255,255,255,.2); background: rgba(0,0,0,.5); color: #fff; font-size: 20px; cursor: pointer; }
/* the Items tab */
:is(#tab-items, #tab-spells) .ihead { display: flex; gap: 6px; }
:is(#tab-items, #tab-spells) .isearch { flex: 1; min-width: 0; height: 30px; background: var(--chrome-2); color: var(--text); border: 1px solid var(--chrome-line); border-radius: 6px; padding: 0 9px; font: inherit; }
:is(#tab-items, #tab-spells) .ichips { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; }
:is(#tab-items, #tab-spells) .ichips button { height: 24px; padding: 0 9px; border-radius: 12px; border: 1px solid var(--chrome-line); background: none; color: var(--text-soft); cursor: pointer; font: 12px var(--sans); }
:is(#tab-items, #tab-spells) .ichips button:hover { color: var(--text); }
:is(#tab-items, #tab-spells) .ichips button.on { background: var(--gold); border-color: var(--gold); color: var(--ink); font-weight: 600; }
:is(#tab-items, #tab-spells) .irar { height: 26px; background: var(--chrome-2); color: var(--text); border: 1px solid var(--chrome-line); border-radius: 5px; }
:is(#tab-items, #tab-spells) .igrid { display: flex; flex-direction: column; gap: 3px; }
:is(#tab-items, #tab-spells) .irow { --g2: #6b5634; display: flex; align-items: center; gap: 9px; padding: 4px 8px 4px 4px; border-radius: 7px; cursor: grab; background: var(--chrome-2); border: 1px solid transparent; border-left: 3px solid var(--g2); }
:is(#tab-items, #tab-spells) .irow:hover { border-color: rgba(201,164,92,.45); border-left-color: var(--g2); background: var(--chrome-3); }
.irow.r-common { --g2: #9a9a92; } .irow.r-uncommon { --g2: #3f9a50; } .irow.r-rare { --g2: #3b74c6; } .irow.r-very-rare { --g2: #8a4cc0; } .irow.r-legendary { --g2: #e0882a; } .irow.r-artifact { --g2: #c03a2a; } .irow.r-varies { --g2: #2a9a8a; }
:is(#tab-items, #tab-spells) .iic { flex: none; width: 38px; height: 38px; border-radius: 7px; display: grid; place-items: center; background: radial-gradient(circle at 50% 40%, #f6ecd4, color-mix(in srgb, var(--g2) 40%, #b9a27a)); box-shadow: inset 0 0 0 1px rgba(0,0,0,.4); }
:is(#tab-items, #tab-spells) .iic .iart { width: 32px; height: 32px; }
:is(#tab-items, #tab-spells) .iic img { width: 34px; height: 34px; border-radius: 6px; object-fit: cover; }
:is(#tab-items, #tab-spells) .inm { flex: 1; min-width: 0; display: flex; flex-direction: column; }
:is(#tab-items, #tab-spells) .inm b { font: 600 13px var(--serif); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
:is(#tab-items, #tab-spells) .inm span { font-size: 11px; color: var(--text-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
:is(#tab-items, #tab-spells) .icost { flex: none; font-size: 11px; color: var(--text-soft); }
:is(#tab-items, #tab-spells) .more { margin: 6px auto; display: block; }
:is(#tab-items, #tab-spells) .icredit { margin-top: 10px; }
/* cards in the chat */
.chatcard { --g2: #8a6d4a; }
.msg.itemmsg .chatcard { display: flex; gap: 9px; margin-top: 4px; padding: 6px; border-radius: 8px; cursor: pointer; background: linear-gradient(180deg, #f4ead2, #e2d3ae); color: #1d1912; box-shadow: 0 0 0 2px var(--g2), 0 4px 10px rgba(0,0,0,.35); }
.chatcard.r-common { --g2: #a8a8a0; } .chatcard.r-uncommon { --g2: #3f9a50; } .chatcard.r-rare { --g2: #3b74c6; } .chatcard.r-very-rare { --g2: #8a4cc0; } .chatcard.r-legendary { --g2: #e0882a; } .chatcard.r-artifact { --g2: #c03a2a; } .chatcard.r-varies { --g2: #2a9a8a; }
.chatcard .ccart { flex: none; width: 54px; height: 54px; border-radius: 6px; display: grid; place-items: center; background: radial-gradient(circle, #fff8e6, color-mix(in srgb, var(--g2) 45%, #b9a27a)); box-shadow: 0 0 0 1px rgba(0,0,0,.5); }
.chatcard .ccart .iart { width: 44px; height: 44px; }
.chatcard .ccart img { width: 54px; height: 54px; border-radius: 6px; object-fit: cover; }
.chatcard .ccbody { min-width: 0; flex: 1; }
.chatcard .ccname { font: 700 14px var(--serif); }
.chatcard .cctype { font: italic 11px var(--serif); color: #5a4a30; }
.chatcard .cctext { font: 12px/1.3 var(--serif); margin-top: 3px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.chatcard .cctext p { margin: 0; } .chatcard .cctext table { display: none; }
/* inventories */
.panel.invpanel { width: 460px; max-height: calc(100% - 80px); display: flex; flex-direction: column; }
.panel.invpanel .pb { overflow: auto; }
.panel.invpanel .hand { display: flex; flex-wrap: wrap; gap: 12px; padding: 8px 4px 12px; }
.itemdrop { outline: 2px dashed var(--gold) !important; outline-offset: -2px; background-color: rgba(201,164,92,.08) !important; }
body.itemdrag .sheetpanel iframe, body.itemdrag #worldFrame { pointer-events: none; }
.bagbtn { display: inline-flex; align-items: center; gap: 3px; }
.bagbtn .ic { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
/* the card editor */
.dialog.itemedit { width: min(980px, 96vw); }
.dialog.itemedit .db { display: flex; gap: 18px; align-items: flex-start; }
.dialog.itemedit .ieform { flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 8px 12px; }
.dialog.itemedit .ieform .wide, .dialog.itemedit .ieform .iew { grid-column: 1 / -1; }
.dialog.itemedit .ieform input:not([type=checkbox]), .dialog.itemedit .ieform select, .dialog.itemedit .ieform textarea { width: 100%; }
.dialog.itemedit .iew { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px 12px; align-items: end; }
.dialog.itemedit .iew:empty { display: none; }
.dialog.itemedit .ieicons { display: grid; grid-template-columns: repeat(auto-fill, minmax(40px, 1fr)); gap: 4px; margin-top: 6px; max-height: 140px; overflow: auto; }
.dialog.itemedit .ieicons button { height: 40px; border-radius: 6px; border: 1px solid var(--chrome-line); background: radial-gradient(circle, rgba(255,255,255,.1), rgba(0,0,0,.2)); cursor: pointer; padding: 3px; }
.dialog.itemedit .ieicons button.on { border-color: var(--gold); box-shadow: 0 0 0 2px rgba(201,164,92,.4); }
.dialog.itemedit .ieicons .iart { width: 100%; height: 100%; }
.dialog.itemedit .iepv { flex: none; position: sticky; top: 0; }
.cardview.away { opacity: 0; pointer-events: none; transition: opacity .15s; }

/* ───────── side bar tabs as pictures ───────── */
#side .tabs button { display: grid; place-items: center; padding: 0; }
#side .tabs button .uic { width: 21px; height: 21px; transition: transform .12s; }
#side .tabs button:hover .uic { transform: translateY(-1px); }
#side .tabs button.on { color: var(--gold); }
#side .tabs button .tabname { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ───────── folders (Items and Spells) ───────── */
.ftree { display: flex; flex-direction: column; gap: 2px; }
.ftree .fold > .fhead { display: flex; align-items: center; gap: 7px; width: 100%; height: 30px; padding: 0 8px 0 4px; border: 0; border-radius: 6px; background: none; color: var(--text); cursor: pointer; font: 13px var(--sans); text-align: left; }
.ftree .fold > .fhead:hover { background: var(--chrome-2); }
.ftree .fhead .tw { width: 12px; color: var(--text-soft); font-size: 10px; }
.ftree .fhead .fic { width: 17px; height: 17px; color: #c9a45c; flex: none; }
.ftree .fhead .fic svg { width: 100%; height: 100%; display: block; }
.ftree .fhead b { flex: 1; font-weight: 600; }
.ftree .fhead .fn { font-size: 11px; color: var(--text-soft); background: var(--chrome-2); border-radius: 9px; padding: 1px 7px; }
.ftree .fkids { display: flex; flex-direction: column; gap: 3px; padding: 2px 0 6px 14px; margin-left: 9px; border-left: 1px solid var(--chrome-line); }
.ftree .fold .fold > .fhead { height: 27px; font-size: 12.5px; }
.ftree .fold .fold .fkids { padding-left: 10px; }

/* ───────── spells ───────── */
.icard.spell.s-abjuration { --f1: #5b92dc; --f2: #18376a; --a1: #d6e8fb; --a2: #5a86c4; --g1: #bfe0ff; --g2: #2c64b8; }
.icard.spell.s-conjuration { --f1: #d9a441; --f2: #5e3a0c; --a1: #fbeccc; --a2: #c99a4a; --g1: #ffe2a0; --g2: #c0801c; }
.icard.spell.s-divination { --f1: #b8c3d4; --f2: #3a4558; --a1: #f2f5fa; --a2: #a8b4c6; --g1: #ffffff; --g2: #7d8ba2; }
.icard.spell.s-enchantment { --f1: #d672ae; --f2: #551540; --a1: #f9dcee; --a2: #c46a9e; --g1: #ffc9ea; --g2: #b43c84; }
.icard.spell.s-evocation { --f1: #e0663c; --f2: #5c1608; --a1: #fbdccb; --a2: #d0704a; --g1: #ffc6a6; --g2: #c4401c; }
.icard.spell.s-illusion { --f1: #a670d4; --f2: #3f1c62; --a1: #ecdcf8; --a2: #8a5ab8; --g1: #ecc9ff; --g2: #7b3cb4; }
.icard.spell.s-necromancy { --f1: #6f8f52; --f2: #1a2610; --a1: #dfe9d2; --a2: #6c8a54; --g1: #d0f0b0; --g2: #4c7030; }
.icard.spell.s-transmutation { --f1: #48bcac; --f2: #104c44; --a1: #d0f3ee; --a2: #46a094; --g1: #b4f7ee; --g2: #1c9484; }
.icard.spell .ca .iart { filter: drop-shadow(0 0 .7em var(--g1)) drop-shadow(0 .25em .25em rgba(0,0,0,.45)); }
.icard .slv { flex: none; min-width: 1.6em; height: 1.6em; padding: 0 .3em; border-radius: 50%; display: grid; place-items: center; font: 700 .85em/1 var(--serif); color: #fff;
  background: radial-gradient(circle at 35% 30%, var(--g1), var(--g2) 65%, var(--f2)); box-shadow: 0 0 0 .1em rgba(0,0,0,.55); text-shadow: 0 1px 1px rgba(0,0,0,.6); }
.icard .stag { flex: none; font: 700 .7em/1 var(--sans, system-ui); padding: .2em .35em; border-radius: .3em; background: #2a231b; color: #f3e6c4; }
.icard .sstats { display: grid; grid-template-columns: 1fr 1fr; gap: .25em .6em; margin-bottom: .5em; padding-bottom: .45em; border-bottom: 1px solid rgba(90,70,40,.3); }
.icard .sst { display: flex; flex-direction: column; min-width: 0; }
.icard .sst b { font: 700 .74em/1.2 var(--sans, system-ui); text-transform: uppercase; letter-spacing: .04em; color: #6b5434; }
.icard .sst span { font-size: .95em; line-height: 1.2; }
.icard .shigher { margin-top: .45em; }
.icard.spell .ca { flex-basis: 30%; }
.irow.srow { --g2: #6b5634; }
.irow.srow.s-abjuration { --g2: #2c64b8; } .irow.srow.s-conjuration { --g2: #c0801c; } .irow.srow.s-divination { --g2: #7d8ba2; } .irow.srow.s-enchantment { --g2: #b43c84; }
.irow.srow.s-evocation { --g2: #c4401c; } .irow.srow.s-illusion { --g2: #7b3cb4; } .irow.srow.s-necromancy { --g2: #4c7030; } .irow.srow.s-transmutation { --g2: #1c9484; }
#tab-spells .stags { display: flex; gap: 3px; flex: none; }
#tab-spells .stags i { font: 700 10px/1 var(--sans); font-style: normal; padding: 3px 4px; border-radius: 3px; background: var(--chrome-3); color: var(--text-soft); }
#tab-spells .ihead .btn { flex: none; }
.chatcard.spellcc.s-abjuration { --g2: #2c64b8; } .chatcard.spellcc.s-conjuration { --g2: #c0801c; } .chatcard.spellcc.s-divination { --g2: #7d8ba2; } .chatcard.spellcc.s-enchantment { --g2: #b43c84; }
.chatcard.spellcc.s-evocation { --g2: #c4401c; } .chatcard.spellcc.s-illusion { --g2: #7b3cb4; } .chatcard.spellcc.s-necromancy { --g2: #4c7030; } .chatcard.spellcc.s-transmutation { --g2: #1c9484; }
.chatcard .ccstats { font: 11px var(--sans); color: #5a4a30; margin-top: 1px; }
.spsrc .row { padding: 4px 0; border-bottom: 1px solid var(--chrome-line); }

/* ───────── the world's clock in the top bar, and weather over battle maps ───────── */
.clockpill { display: flex; align-items: center; gap: 7px; height: 30px; padding: 0 10px 0 8px; margin-right: 8px; border-radius: 15px; border: 1px solid var(--chrome-line); background: var(--chrome-2); color: var(--text); cursor: pointer; }
.clockpill:hover { border-color: rgba(201,164,92,.6); }
.clockpill .ci { display: grid; place-items: center; width: 18px; height: 18px; color: var(--gold); }
.clockpill .ci.w { color: #b9c7da; }
.clockpill .ci svg { width: 18px; height: 18px; }
.clockpill .cl { display: flex; flex-direction: column; line-height: 1.05; text-align: left; }
.clockpill .cl b { font: 600 12.5px var(--sans); }
.clockpill .cl span { font-size: 10.5px; color: var(--text-soft); white-space: nowrap; }
.clockpanel { position: fixed; z-index: 500; width: 340px; padding: 12px 14px; border-radius: 10px; background: var(--chrome); border: 1px solid var(--chrome-line); box-shadow: 0 16px 40px rgba(0,0,0,.55); color: var(--text); font-size: 13px; }
.clockpanel .cphead { display: flex; align-items: center; gap: 12px; }
.clockpanel .cptime { font: 600 28px/1 var(--serif); color: var(--gold); }
.clockpanel .cpadv { display: flex; flex-wrap: wrap; gap: 5px; margin: 8px 0; }
.clockpanel .cpset { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; margin-bottom: 6px; }
.clockpanel .cpset input, .clockpanel .cpset select { height: 28px; padding: 0 6px; font-size: 12.5px; color-scheme: dark; background: var(--chrome-2); color: var(--text); border: 1px solid var(--chrome-line); border-radius: 5px; }
.clockpanel .cplabel { margin: 10px 0 5px; font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--text-soft); }
.clockpanel .cpweather { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.clockpanel .wbtn { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 5px 2px; border-radius: 6px; border: 1px solid transparent; background: var(--chrome-2); color: var(--text-soft); cursor: pointer; font-size: 10.5px; }
.clockpanel .wbtn:hover { color: var(--text); }
.clockpanel .wbtn.on { border-color: var(--gold); color: #fff; background: #2a2516; }
.clockpanel .wbtn .wi svg { width: 20px; height: 20px; display: block; }
.clockpanel .cpwind { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 8px; }
.clockpanel .cpwind label { display: flex; flex-direction: column; gap: 2px; font-size: 11px; color: var(--text-soft); }
.clockpanel label.inline { display: flex; align-items: center; gap: 7px; margin: 4px 0; }
.clockpanel .cpfoot { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--chrome-line); display: flex; justify-content: flex-end; }
#stage canvas.weatherfx { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 3; }
body.worldview #stage canvas.weatherfx { display: none; }
