/* Intercom web app. Design spec: docs/ui-style.md. No frameworks, no web fonts. */

/* ---------- 1. tokens ---------- */
:root {
  color-scheme: dark;
  --bg: #0b0d10;
  --surface: #14171c;
  --raised: #1c2026;
  --line: rgba(255, 255, 255, .08);
  --line-strong: rgba(255, 255, 255, .18);
  --text: #f2f4f7;
  --muted: #98a2ad;
  --accent: #ffb020;
  --on-accent: #1a1100;
  --ok: #3ddc84;
  --warn: #ffb020;
  --danger: #ff5a4f;
  --info: #4da3ff;
  --r-card: 16px;
  --r-ctl: 12px;
  --tap: 48px;
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px;
  --fs-1: .8125rem; /* 13 */
  --fs-2: .9375rem; /* 15 */
  --fs-3: 1.0625rem; /* 17 */
  --fs-4: 1.375rem; /* 22 */
  --fs-5: 1.75rem; /* 28 */
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, system-ui, sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --overshoot: cubic-bezier(.34, 1.56, .64, 1);
  --tabh: 56px;
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-l: env(safe-area-inset-left, 0px);
  --safe-r: env(safe-area-inset-right, 0px);
  --pad-l: max(var(--s4), var(--safe-l));
  --pad-r: max(var(--s4), var(--safe-r));
}

/* ---------- 2. base ---------- */
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
html, body { height: 100%; margin: 0; overscroll-behavior: none; background: var(--bg); color: var(--text);
  font: 400 var(--fs-2)/1.4 var(--font); -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { overflow: hidden; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
button, input { font: inherit; color: inherit; touch-action: manipulation; }
button { cursor: pointer; }
h1, h2, p, ul { margin: 0; padding: 0; }
ul { list-style: none; }
svg { display: block; flex: none; }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.muted { color: var(--muted); }
.mono { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; }
.selectable, input { -webkit-user-select: text; user-select: text; }
.sr { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.grow { flex: 1; min-width: 0; }
.stack { display: flex; flex-direction: column; gap: var(--s4); }
[data-icon] svg, .ico svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.spin { width: 16px; height: 16px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .8s linear infinite; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- 3. buttons, fields, switches, segmented ---------- */
.btn { white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; gap: var(--s2); min-height: var(--tap); padding: 0 20px;
  border: 0; border-radius: var(--r-ctl); background: var(--raised); color: var(--text); font-size: var(--fs-3); font-weight: 600;
  transition: transform .12s var(--ease), background-color .12s; }
.btn:active { transform: scale(.97); background-color: #262c34; }
.btn.primary { background: var(--accent); color: var(--on-accent); }
.btn.primary:active { background-color: #e69d10; }
.btn.danger { background: var(--danger); color: #1a0502; }
.btn.danger:active { background-color: #e64a3f; }
.btn.text { background: transparent; color: var(--muted); }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .55; pointer-events: none; }
.btn-row { display: flex; flex-wrap: wrap; gap: var(--s3); margin: var(--s2) 0 var(--s4); }
.btn-row .btn { flex: 1 1 140px; }
.icon-btn { display: grid; place-items: center; width: var(--tap); height: var(--tap); flex: none; border: 0; border-radius: 50%; background: transparent; color: var(--text); transition: background-color .12s, transform .12s; }
.icon-btn:active { background: var(--raised); transform: scale(.94); }

.field { display: block; }
.field label { display: block; margin-bottom: 6px; font-size: var(--fs-1); color: var(--muted); }
.field input { display: block; width: 100%; min-height: var(--tap); padding: 0 14px; border: 0; border-radius: var(--r-ctl); background: var(--raised); color: var(--text);
  font-size: max(16px, var(--fs-3)); -webkit-appearance: none; appearance: none; }
.field input::placeholder { color: var(--muted); opacity: 1; }
.field input:focus { outline: none; box-shadow: 0 0 0 2px var(--accent); }
.field .err { margin-top: 6px; font-size: var(--fs-1); color: var(--danger); }
.field .err:empty { display: none; }

.switch-row { cursor: pointer; }
.track { position: relative; flex: none; width: 52px; height: 32px; border-radius: 16px; background: var(--raised); box-shadow: inset 0 0 0 1px var(--line-strong); transition: background-color .18s; }
.knob { position: absolute; top: 2px; left: 2px; width: 28px; height: 28px; border-radius: 50%; background: #c9d0d8; box-shadow: 0 1px 3px rgba(0, 0, 0, .4); transition: transform .22s var(--overshoot), background-color .18s; }
input:checked + .track { background: var(--ok); box-shadow: none; }
input:checked + .track .knob { transform: translateX(20px); background: #fff; }
input:focus-visible + .track { outline: 2px solid var(--accent); outline-offset: 2px; }
.switch-row:active .knob { width: 32px; }
input:checked + .track .knob { transition-property: transform, background-color; }
.switch-row:active input:checked + .track .knob { transform: translateX(16px); }

.seg { position: relative; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; padding: 3px; border-radius: 10px; background: var(--raised); box-shadow: inset 0 0 0 1px var(--line); }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label { position: relative; z-index: 1; display: grid; place-items: center; min-width: 76px; min-height: 48px; padding: 0 12px; border-radius: 8px; color: var(--muted); font-size: var(--fs-2); font-weight: 600; cursor: pointer; transition: color .15s; }
.seg input:checked + label { color: var(--text); }
.seg input:focus-visible + label { outline: 2px solid var(--accent); outline-offset: 1px; }
.seg .thumb { position: absolute; top: 3px; bottom: 3px; left: 3px; width: calc((100% - 6px) / var(--n, 2)); border-radius: 8px; background: var(--surface); box-shadow: 0 0 0 1px var(--line-strong), 0 1px 4px rgba(0, 0, 0, .4); transform: translateX(calc(var(--i, 0) * 100%)); transition: transform .22s var(--overshoot); }

/* ---------- 4. grouped lists ---------- */
.section-label { margin: var(--s2) var(--s1) var(--s2); font-size: var(--fs-1); font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.count { font-variant-numeric: tabular-nums; font-weight: 400; }
.group { --inset: var(--s4); margin: 0 0 var(--s5); border: 1px solid var(--line); border-radius: var(--r-card); background: var(--surface); overflow: hidden; }
.group > * { position: relative; }
.group > * + *::before { content: ""; position: absolute; top: 0; left: var(--inset); right: 0; height: 1px; background: var(--line); }
.row { display: flex; align-items: center; gap: var(--s3); width: 100%; min-height: 56px; padding: var(--s2) var(--s4); border: 0; background: none; color: inherit; text-align: left; font-size: var(--fs-3); }
button.row { transition: background-color .12s; }
button.row:active { background: rgba(255, 255, 255, .05); }
.row-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.row-title { font-size: var(--fs-3); }
.row-hint { font-size: var(--fs-1); color: var(--muted); }
.row-value { color: var(--muted); font-size: var(--fs-3); max-width: 50%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chev svg { width: 20px; height: 20px; color: var(--muted); }
.row.danger-row, .row.danger-row .row-title { color: var(--danger); }

.chip { display: inline-flex; align-items: center; height: 20px; padding: 0 6px; border-radius: 6px; background: var(--raised); color: var(--muted); font-size: var(--fs-1); font-weight: 600; vertical-align: middle; }
.chip.warn { background: rgba(255, 176, 32, .14); color: var(--warn); }
.chip.accent { background: rgba(255, 176, 32, .14); color: var(--accent); }

.avatar { display: grid; place-items: center; flex: none; width: 40px; height: 40px; border-radius: 50%; font-size: var(--fs-2); font-weight: 700; letter-spacing: .02em; }
.avatar.big { width: 64px; height: 64px; font-size: var(--fs-4); }
.avatar.small { width: 32px; height: 32px; font-size: var(--fs-1); }
.avatar.talk { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--accent); }

.notice { display: flex; gap: var(--s3); align-items: flex-start; margin: 0 0 var(--s4); padding: var(--s3) var(--s4); border-left: 3px solid var(--info); border-radius: 4px var(--r-ctl) var(--r-ctl) 4px; background: var(--surface); font-size: var(--fs-2); }
.notice.warn { border-left-color: var(--warn); }
.footnote { margin: 0 var(--s1) var(--s5); font-size: var(--fs-1); color: var(--muted); }

/* channel rows */
.ch-row { gap: var(--s3); min-height: 68px; }
.group.inset { --inset: 68px; }
.ch-ico { display: grid; place-items: center; flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--raised); color: var(--muted); }
.ch-name { display: flex; align-items: center; gap: 6px; min-width: 0; font-size: var(--fs-3); font-weight: 600; }
.ch-name svg { width: 16px; height: 16px; color: var(--muted); }
.ch-sub { font-size: var(--fs-1); color: var(--muted); overflow-wrap: break-word; }
.ch-meta { display: flex; align-items: center; gap: 4px; flex: none; font-size: var(--fs-1); color: var(--muted); font-variant-numeric: tabular-nums; }
.ch-meta svg { width: 16px; height: 16px; }

/* member rows */
.member { min-height: 64px; }
.member .row-title { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 6px; font-weight: 600; }
.member .row-hint.live { color: var(--accent); font-weight: 600; }
.member.stale { opacity: .7; }
.where { display: flex; align-items: center; gap: 6px; flex: none; font-size: var(--fs-2); font-variant-numeric: tabular-nums; text-align: right; }
.where svg { width: 18px; height: 18px; color: var(--info); transition: transform .3s var(--ease); }
.where small { display: block; font-size: var(--fs-1); color: var(--muted); }

/* skeleton + empty */
.skel .ch-ico, .skel i { background: var(--raised); }
.skel i { display: block; height: 12px; border-radius: 6px; margin: 4px 0; }
.skel .ch-ico, .skel i { animation: shimmer 1.4s ease-in-out infinite; }
@keyframes shimmer { 50% { opacity: .45; } }
.empty { display: flex; flex-direction: column; align-items: center; gap: var(--s3); padding: var(--s6) var(--s5); text-align: center; color: var(--muted); }
.empty .ico { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: var(--raised); color: var(--muted); }
.empty .ico svg { width: 30px; height: 30px; }
.empty .ico.bad { color: var(--warn); }
.empty h3 { margin: 0; font-size: var(--fs-3); font-weight: 600; color: var(--text); }
.empty p { max-width: 30ch; }
.empty-fill { flex: 1; display: flex; align-items: center; justify-content: center; }
.group.is-empty { background: transparent; border-style: dashed; border-color: var(--line-strong); }

/* ---------- 5. shell ---------- */
.app { position: fixed; inset: 0; display: flex; flex-direction: column; }
.panes { flex: 1; min-height: 0; position: relative; }
.view { position: absolute; inset: 0; display: none; flex-direction: column; min-height: 0; }
.view.active { display: flex; }

.tabs { order: 2; flex: none; display: flex; background: var(--surface); border-top: 1px solid var(--line);
  padding: 0 var(--safe-r) var(--safe-b) var(--safe-l); }
.rail-brand { display: none; }
.tab { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: var(--tabh); padding: 6px 4px;
  border: 0; background: none; color: var(--muted); font-size: var(--fs-1); font-weight: 600; transition: color .15s; }
.tab:active { transform: scale(.96); }
.tab[aria-current="page"] { color: var(--accent); }
.tab[aria-disabled="true"] { opacity: .45; }
.tab-ico { position: relative; display: block; }
.tab-dot { position: absolute; top: -1px; right: -3px; width: 10px; height: 10px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 2px var(--surface); }
.tab-dot[data-s="me"] { background: var(--accent); } .tab-dot[data-s="other"] { background: var(--info); } .tab-dot[data-s="wait"] { background: var(--muted); }
.tab-label { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* compact sticky bar + large title */
.bar { flex: none; display: flex; align-items: center; gap: var(--s2); min-height: calc(52px + var(--safe-t)); padding: var(--safe-t) max(var(--s2), var(--safe-r)) 0 var(--pad-l);
  border-bottom: 1px solid transparent; transition: background-color .15s, border-color .15s; z-index: 2; }
.view.scrolled .bar { background: rgba(20, 23, 28, .94); border-bottom-color: var(--line); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.bar-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: var(--fs-3); font-weight: 700; opacity: 0; transition: opacity .15s; }
.view.scrolled .bar-title, #v-map .bar-title { opacity: 1; }
#v-map .bar { background: rgba(20, 23, 28, .94); border-bottom-color: var(--line); }
.ch-lock svg { display: inline-block; width: 20px; height: 20px; margin-left: 6px; vertical-align: -2px; color: var(--muted); }
.status { display: flex; align-items: center; gap: var(--s3); flex: none; margin-left: auto; font-size: var(--fs-1); color: var(--muted); }
.bar-title + .status { margin-left: 0; }
.status:last-child { margin-right: var(--s2); }
.st { display: inline-flex; align-items: center; gap: 6px; max-width: 12ch; white-space: nowrap; }
.st .lbl { overflow: hidden; text-overflow: ellipsis; }
.dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.st.ok .dot { background: var(--ok); }
.st.warn .dot { background: var(--warn); }
.st.accent { color: var(--accent); } .st.accent .dot { background: var(--accent); }
.st.info .dot { background: var(--info); }
.scroll { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; padding: 0 var(--pad-r) var(--s5) var(--pad-l); }
.title-block { padding: var(--s1) var(--s1) var(--s3); }
h1.large { font-size: var(--fs-5); line-height: 1.15; font-weight: 700; letter-spacing: -.01em; overflow-wrap: anywhere; }
.subtitle { margin-top: 4px; color: var(--muted); font-size: var(--fs-2); overflow-wrap: anywhere; }
.subtitle:empty { display: none; }

.conn-banner { flex: none; display: flex; align-items: center; gap: var(--s2); padding: 8px var(--pad-r) 8px var(--pad-l); background: rgba(255, 176, 32, .14);
  border-bottom: 1px solid rgba(255, 176, 32, .3); color: var(--warn); font-size: var(--fs-1); font-weight: 600; }
.conn-banner svg { width: 18px; height: 18px; }

/* profile */
.profile { display: flex; align-items: center; gap: var(--s4); margin: 0 var(--s1) var(--s5); }
.profile-name { font-size: var(--fs-4); font-weight: 700; overflow-wrap: anywhere; }
.profile-sub { color: var(--muted); font-size: var(--fs-2); }

/* welcome / first run */
.welcome { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; overflow-y: auto;
  padding: calc(var(--s5) + var(--safe-t)) var(--pad-r) calc(var(--s5) + var(--safe-b)) var(--pad-l); }
.welcome-inner { width: 100%; max-width: 400px; display: flex; flex-direction: column; gap: var(--s4); margin: auto; }
.welcome h1 { font-size: var(--fs-5); font-weight: 700; }
.welcome-logo svg { width: 88px; height: 88px; }
.logo-tile { fill: var(--surface); stroke: none; }
.logo-wave { fill: none; stroke: var(--accent); stroke-width: 30; stroke-linecap: round; }
.logo-dot { fill: var(--accent); stroke: none; }

/* ---------- 6. talk ---------- */
.talk-main { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.ptt-dock { flex: none; display: flex; flex-direction: column; align-items: center; padding: var(--s3) var(--pad-r) var(--s3) var(--pad-l); background: var(--bg); border-top: 1px solid var(--line); }
.talker-line { display: flex; align-items: center; justify-content: center; gap: var(--s2); min-height: 24px; font-size: var(--fs-2); font-weight: 600; color: var(--muted); text-align: center; max-width: 100%; }
.talker-line .dot { background: var(--muted); }
.talker-line.me { color: var(--accent); } .talker-line.me .dot { background: var(--accent); }
.talker-line.other { color: var(--info); } .talker-line.other .dot { background: var(--info); }
.talker-line span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.ptt-wrap { position: relative; width: 148px; height: 148px; margin: 22px 0 18px; }
.ptt { position: absolute; inset: 0; width: 148px; height: 148px; padding: 0; border: 0; border-radius: 50%; background: var(--raised); color: var(--text);
  box-shadow: inset 0 0 0 1.5px var(--line-strong), 0 8px 24px rgba(0, 0, 0, .45); touch-action: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none;
  transition: transform .12s var(--ease), background-color .15s, box-shadow .15s, color .15s; }
.ptt:focus-visible { outline-offset: 5px; }
.ptt-face { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; pointer-events: none; }
.ptt-ico svg { width: 36px; height: 36px; }
.ptt-label { font-size: var(--fs-3); font-weight: 700; line-height: 1.15; }
.ptt-hint { display: none; font-size: var(--fs-1); color: var(--muted); }
@media (hover: hover) and (pointer: fine) { .ptt[data-state="idle"] .ptt-hint, .ptt[data-state="other"] .ptt-hint { display: block; } }
.ptt-ring { position: absolute; inset: 0; border-radius: 50%; border: 3px solid var(--accent); opacity: 0; pointer-events: none; }
.ptt[data-state="req"] { box-shadow: inset 0 0 0 3px var(--accent), 0 8px 24px rgba(0, 0, 0, .45); }
.ptt[data-state="other"] { box-shadow: inset 0 0 0 3px var(--info), 0 0 0 6px rgba(77, 163, 255, .16), 0 8px 24px rgba(0, 0, 0, .45); }
.ptt[data-state="live"] { background: var(--accent); color: var(--on-accent); transform: scale(.97); box-shadow: 0 0 0 0 transparent, 0 8px 24px rgba(0, 0, 0, .45); }
.ptt[data-state="live"] .ptt-ring { animation: pulse 1.5s ease-out infinite; }
.ptt[data-state="denied"] { box-shadow: inset 0 0 0 3px var(--danger), 0 8px 24px rgba(0, 0, 0, .45); color: var(--danger); animation: shake .4s var(--ease); }
@keyframes pulse { from { transform: scale(1); opacity: .7; } to { transform: scale(1.32); opacity: 0; } }
@keyframes shake { 20% { transform: translateX(-8px); } 40% { transform: translateX(7px); } 60% { transform: translateX(-5px); } 80% { transform: translateX(3px); } }

.meter { position: relative; width: 148px; height: 6px; margin: 0 0 8px; border-radius: 3px; background: var(--raised); overflow: hidden; opacity: 0; transition: opacity .15s; }
.meter.on { opacity: 1; }
.meter i { position: absolute; inset: 0; background: var(--ok); transform-origin: left; transform: scaleX(0); }
.meter.hot i { background: var(--warn); } .meter.clip i { background: var(--danger); }
.meter b { position: absolute; top: 0; bottom: 0; left: 0; width: 2px; background: var(--text); }
.ptt-msg { min-height: 1.4em; max-width: 34ch; text-align: center; font-size: var(--fs-1); color: var(--muted); }
.ptt-msg:empty::before { content: "\00a0"; }

/* ---------- 7. map ---------- */
.map-stage { flex: 1; position: relative; min-height: 0; overflow: hidden; }
#map { position: absolute; inset: 0; z-index: 0; background: #10141a; -webkit-user-select: none; user-select: none; }
.map-msg { position: absolute; z-index: 5; top: var(--s3); left: var(--pad-l); right: var(--pad-r); display: flex; align-items: center; gap: var(--s3); padding: var(--s3) var(--s4);
  border: 1px solid var(--line); border-radius: var(--r-card); background: var(--surface); font-size: var(--fs-2); }
.map-fab { position: absolute; z-index: 5; right: max(var(--s3), var(--safe-r)); bottom: 84px; display: flex; flex-direction: column; gap: var(--s2); }
.fab { display: grid; place-items: center; width: var(--tap); height: var(--tap); border: 0; border-radius: 50%; background: var(--surface); color: var(--text);
  box-shadow: 0 0 0 1px var(--line-strong), 0 4px 14px rgba(0, 0, 0, .5); transition: transform .12s; }
.fab:active { transform: scale(.94); }
.fab.accent { background: var(--accent); color: var(--on-accent); box-shadow: 0 4px 14px rgba(0, 0, 0, .5); }
.map-strip { position: absolute; z-index: 5; left: 0; right: 0; bottom: 0; display: flex; gap: var(--s2); overflow-x: auto; padding: var(--s3) var(--pad-r) var(--s3) var(--pad-l);
  scrollbar-width: none; background: linear-gradient(to top, rgba(11, 13, 16, .92) 60%, rgba(11, 13, 16, 0)); }
.map-strip::-webkit-scrollbar { display: none; }
.mchip { display: flex; align-items: center; gap: var(--s2); flex: none; min-height: var(--tap); padding: 0 14px 0 8px; border: 0; border-radius: 24px; background: var(--surface);
  box-shadow: 0 0 0 1px var(--line-strong); font-size: var(--fs-2); font-weight: 600; max-width: 240px; }
.mchip span.n { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mchip small { font-size: var(--fs-1); font-weight: 400; color: var(--muted); font-variant-numeric: tabular-nums; }
.mchip.plain { padding: 0 16px; color: var(--muted); font-weight: 400; white-space: nowrap; max-width: none; }

/* ---------- 8. sheets and toast ---------- */
.backdrop { position: fixed; inset: 0; z-index: 40; display: flex; align-items: flex-end; justify-content: center; background: rgba(0, 0, 0, .6); opacity: 0; transition: opacity .2s; }
.backdrop.in { opacity: 1; }
.sheet { width: 100%; max-width: 600px; max-height: calc(100dvh - var(--safe-t) - 16px); overflow-y: auto; overscroll-behavior: contain; background: var(--surface);
  border-radius: var(--r-card) var(--r-card) 0 0; border-top: 1px solid var(--line-strong); padding: 0 max(var(--s4), var(--safe-r)) calc(var(--s4) + var(--safe-b)) max(var(--s4), var(--safe-l));
  transform: translateY(100%); transition: transform .22s var(--ease); }
.backdrop.in .sheet { transform: none; }
.sheet.dragging { transition: none; }
.sheet-head { touch-action: none; padding-bottom: var(--s2); }
.grab { width: 36px; height: 5px; margin: 8px auto 12px; border-radius: 3px; background: rgba(255, 255, 255, .22); }
.sheet-title { font-size: var(--fs-4); font-weight: 700; line-height: 1.2; overflow-wrap: anywhere; }
.sheet-sub { margin-top: 4px; color: var(--muted); font-size: var(--fs-2); }
.sheet-body { display: flex; flex-direction: column; gap: var(--s4); margin-top: var(--s3); }
.sheet-body .group { margin: 0; }
.sheet-actions { display: flex; flex-direction: column; gap: var(--s2); margin-top: var(--s4); }
@media (min-width: 768px) {
  .backdrop { align-items: center; padding: var(--s5); }
  .sheet { max-width: 520px; max-height: calc(100dvh - 48px); border-radius: var(--r-card); border: 1px solid var(--line-strong); padding-bottom: var(--s4); transform: translateY(14px) scale(.98); opacity: 0; transition: transform .22s var(--ease), opacity .18s; }
  .backdrop.in .sheet { transform: none; opacity: 1; }
  .grab { display: none; }
  .sheet-head { padding-top: var(--s4); }
}
.toast { position: fixed; z-index: 60; left: 50%; bottom: calc(var(--tabh) + var(--nowh, 0px) + var(--safe-b) + var(--s3)); transform: translateX(-50%); max-width: min(92vw, 440px);
  padding: 12px 20px; border-radius: 24px; background: #272d35; box-shadow: 0 0 0 1px var(--line-strong), 0 8px 24px rgba(0, 0, 0, .5); font-size: var(--fs-2); font-weight: 600; text-align: center; pointer-events: none; }
.toast.err { box-shadow: 0 0 0 1.5px var(--danger), 0 8px 24px rgba(0, 0, 0, .5); }
.toast:not([hidden]) { animation: toast-in .2s var(--ease); }
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 12px); } }

/* ---------- 9. tablet and wider: left rail + two panes ---------- */
@media (min-width: 800px) {
  .app { flex-direction: row; }
  .tabs { order: 0; flex-direction: column; justify-content: flex-start; align-items: stretch; gap: var(--s1); width: 88px; border-top: 0; border-right: 1px solid var(--line);
    padding: calc(var(--s3) + var(--safe-t)) var(--s2) var(--s3) max(var(--s2), var(--safe-l)); }
  .rail-brand { display: block; margin: 0 auto var(--s4); }
  .rail-brand svg { width: 44px; height: 44px; }
  .tab { flex: none; min-height: 64px; border-radius: var(--r-ctl); }
  .tab[aria-current="page"] { background: var(--raised); }
  .tab[data-tab="channels"] { display: none; }
  .panes { display: grid; grid-template-columns: clamp(300px, 36%, 380px) minmax(0, 1fr); }
  .view { position: relative; inset: auto; grid-row: 1; min-width: 0; }
  #v-channels { display: flex; grid-column: 1; border-right: 1px solid var(--line); }
  .view:not(#v-channels) { grid-column: 2; }
  [data-tab="channels"] #v-talk { display: flex; }
  .toast { bottom: var(--s5); }
  .app { --pad-r: var(--s4); }
  .nowbar { display: none !important; }
  .rail-now:not([hidden]) { display: flex; }
}
@media (max-height: 700px) { .ptt-wrap { margin: 14px 0 10px; } .ptt-msg:empty { display: none; } .ptt-dock { padding-top: var(--s2); padding-bottom: var(--s2); } .meter { margin-bottom: 4px; } }
@media (max-height: 560px) { .ptt-wrap { margin: 18px 0 14px; } .bar { min-height: calc(44px + var(--safe-t)); } }

/* ---------- 10. reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .ptt[data-state="live"] .ptt-ring { animation: none !important; opacity: .5; transform: scale(1.1); }
  .ptt[data-state="denied"] { animation: none !important; }
  .ell i { animation: none !important; opacity: .6 !important; }
  .skel .ch-ico, .skel i, .spin { animation: none !important; }
}

/* ---------- 11. presence: pills, current channel card, now bar, rail footer ---------- */
.pillwrap { display: flex; align-items: center; gap: var(--s2); min-width: 0; flex: 0 1 auto; }
#v-talk .pillwrap .ch-pill { display: none; }
.ch-pill { display: inline-flex; align-items: center; gap: 8px; min-height: 36px; max-width: 46vw; padding: 0 12px; border: 0; border-radius: 18px; background: var(--raised); box-shadow: inset 0 0 0 1px var(--line-strong);
  color: var(--text); font-size: var(--fs-1); font-weight: 600; transition: transform .12s; }
.ch-pill:active { transform: scale(.97); }
.ch-pill span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ch-pill .dot { background: transparent; box-shadow: inset 0 0 0 1.5px var(--muted); }
.ch-pill[data-s="quiet"] .dot { background: var(--ok); box-shadow: none; }
.ch-pill[data-s="other"] .dot { background: var(--info); box-shadow: none; }
.ch-pill[data-s="me"] .dot { background: var(--accent); box-shadow: none; }
.ch-pill[data-s="wait"] .dot { background: var(--muted); box-shadow: none; }
.ch-pill[data-s="none"] { color: var(--muted); }
.sound-chip { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 12px; border: 0; border-radius: 18px; background: rgba(255, 176, 32, .16); color: var(--warn); font-size: var(--fs-1); font-weight: 700; white-space: nowrap; }
.sound-chip svg { width: 18px; height: 18px; }
.bar { gap: var(--s2); }
#v-map .bar-title, #v-me .bar-title { flex: 0 0 auto; }
#v-map .bar .pillwrap, #v-me .bar .pillwrap { margin-left: auto; }
.status .st { max-width: 9ch; }

.cur-card { display: flex; align-items: stretch; margin: 0 0 var(--s4); border-radius: var(--r-card); background: var(--surface); box-shadow: inset 3px 0 0 var(--accent), inset 0 0 0 1px var(--line-strong); overflow: hidden; }
.cur-main { flex: 1; min-width: 0; display: flex; align-items: center; gap: var(--s3); padding: var(--s3) var(--s2) var(--s3) var(--s4); border: 0; background: none; color: inherit; text-align: left; font: inherit; }
.cur-main:active { background: rgba(255, 255, 255, .05); }
.cur-kicker { font-size: var(--fs-1); font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--accent); }
.cur-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 10px; margin-top: 2px; }
.cur-talk, .now-talk { display: flex; align-items: center; gap: 6px; font-size: var(--fs-1); font-weight: 600; color: var(--muted); }
.cur-talk { margin-top: 2px; }
.cur-talk .dot, .now-talk .dot { background: var(--ok); }
.cur-talk.other, .now-talk.other { color: var(--info); } .cur-talk.other .dot, .now-talk.other .dot { background: var(--info); }
.cur-talk.me, .now-talk.me { color: var(--accent); } .cur-talk.me .dot, .now-talk.me .dot { background: var(--accent); }
.cur-talk.wait .dot, .now-talk.wait .dot { background: var(--muted); }
.cur-leave { flex: none; align-self: center; min-width: 0; padding: 0 var(--s4); color: var(--danger); }
.ch-row.current, .mine-row.current { box-shadow: inset 3px 0 0 var(--accent); }
.mine-row { padding: 0 var(--s2) 0 0; }
.mine-go { flex: 1; min-width: 0; display: flex; align-items: center; gap: var(--s3); min-height: 68px; padding: var(--s2) 0 var(--s2) var(--s4); border: 0; background: none; color: inherit; text-align: left; font: inherit; }
.mine-go:active { background: rgba(255, 255, 255, .05); }
.name-card { padding: var(--s4); border-radius: var(--r-ctl); background: var(--raised); font-size: var(--fs-4); font-weight: 700; text-align: center; overflow-wrap: anywhere; }
.steps { margin: 0 0 var(--s2); padding-left: 22px; color: var(--text); font-size: var(--fs-2); line-height: 1.5; } .steps li { margin: 6px 0; }

.nowbar { order: 1; flex: none; display: flex; align-items: center; gap: var(--s3); min-height: 64px; padding: 8px max(var(--s3), var(--safe-r)) 8px max(var(--s4), var(--safe-l)); background: var(--surface); border-top: 1px solid var(--line-strong); cursor: pointer; }
.nowbar[hidden] { display: none; }
.now-count { display: flex; align-items: center; gap: var(--s2); min-width: 0; color: var(--text); }
.now-count svg { width: 22px; height: 22px; color: var(--muted); }
.now-txt { display: flex; flex-direction: column; min-width: 0; line-height: 1.2; }
.now-txt b { font-size: var(--fs-2); font-weight: 700; white-space: nowrap; }
.now-txt small { font-size: 12px; color: var(--muted); white-space: nowrap; }
.nowbar .now-talk { flex: 1; min-width: 0; justify-content: center; } .nowbar .now-talk span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ptt-mini { flex: none; display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-width: 96px; height: 48px; padding: 0 16px; border: 0; border-radius: 24px; background: var(--raised); color: var(--text);
  box-shadow: inset 0 0 0 1.5px var(--line-strong); font-size: var(--fs-2); font-weight: 700; touch-action: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; transition: transform .12s var(--ease), background-color .15s, box-shadow .15s; }
.ptt-mini svg { width: 22px; height: 22px; }
.ptt-mini[data-state="req"] { box-shadow: inset 0 0 0 2.5px var(--accent); }
.ptt-mini[data-state="other"] { box-shadow: inset 0 0 0 2.5px var(--info); }
.ptt-mini[data-state="live"] { background: var(--accent); color: var(--on-accent); transform: scale(.96); box-shadow: 0 0 0 4px rgba(255, 176, 32, .25); }
.ptt-mini[data-state="denied"] { box-shadow: inset 0 0 0 2.5px var(--danger); color: var(--danger); animation: shake .4s var(--ease); }
.rail-now { display: none; flex-direction: column; align-items: center; gap: var(--s2); margin-top: auto; padding: var(--s3) var(--s1) var(--s2); border-top: 1px solid var(--line); cursor: pointer; }
.rail-count { display: flex; align-items: center; gap: 4px; font-size: var(--fs-2); } .rail-count svg { width: 18px; height: 18px; color: var(--muted); }
.rail-name { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; color: var(--muted); }
.ptt-mini.round { min-width: 56px; width: 56px; height: 56px; padding: 0; border-radius: 50%; } .ptt-mini.round .pm-label { display: none; }
@media (min-width: 768px) { .ch-pill { max-width: 28vw; } }

/* ---------- 12. map controls (MapLibre) ---------- */
.maplibregl-map { font: inherit; }
#map.look-day { background: #f7f4ec; }
.map-top { position: absolute; z-index: 5; top: var(--s3); left: var(--pad-l); right: var(--pad-r); display: flex; align-items: center; justify-content: space-between; gap: var(--s2); pointer-events: none; }
.map-top > * { pointer-events: auto; }
.map-look { padding: 3px; border-radius: 14px; background: var(--surface); box-shadow: 0 0 0 1px var(--line-strong), 0 4px 14px rgba(0, 0, 0, .5); }
.map-look .seg { background: transparent; box-shadow: none; padding: 0; }
.map-look .seg label { min-width: 58px; min-height: 42px; padding: 0 8px; }
.map-look .seg .thumb { top: 0; bottom: 0; left: 0; width: calc(100% / var(--n, 3)); background: var(--raised); }
.map-pill { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 16px 0 12px; border: 0; border-radius: 24px; background: var(--surface); color: var(--text); font-size: var(--fs-2); font-weight: 700;
  box-shadow: 0 0 0 1px var(--line-strong), 0 4px 14px rgba(0, 0, 0, .5); transition: transform .12s; }
.map-pill:active { transform: scale(.96); } .map-pill svg { width: 20px; height: 20px; }
.map-chips { position: absolute; z-index: 5; top: 68px; left: var(--pad-l); display: flex; flex-wrap: wrap; gap: var(--s2); pointer-events: none; }
.chip-pill { display: inline-flex; align-items: center; gap: 8px; min-height: 32px; padding: 0 12px; border-radius: 16px; background: var(--surface); box-shadow: 0 0 0 1px var(--line-strong), 0 2px 8px rgba(0, 0, 0, .45); font-size: var(--fs-1); font-weight: 700; }
.dot.ok { background: var(--ok); }
.map-void { position: absolute; z-index: 4; left: 50%; top: 42%; transform: translate(-50%, -50%); width: min(86%, 320px); display: flex; flex-direction: column; align-items: center; gap: var(--s2); padding: var(--s5) var(--s4); border-radius: var(--r-card);
  background: rgba(20, 23, 28, .96); box-shadow: 0 0 0 1px var(--line-strong), 0 8px 24px rgba(0, 0, 0, .55); text-align: center; pointer-events: none; }
.map-void .ico { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: var(--raised); color: var(--muted); }
.void-t { font-size: var(--fs-3); font-weight: 700; } .void-s { font-size: var(--fs-2); color: var(--muted); }
.map-priv { position: absolute; z-index: 5; left: var(--pad-l); bottom: 78px; max-width: calc(100% - 140px); display: flex; align-items: center; gap: 8px; min-height: 32px; padding: 0 12px; border-radius: 16px; background: rgba(20, 23, 28, .96);
  box-shadow: 0 0 0 1px var(--line-strong); font-size: var(--fs-1); font-weight: 600; color: var(--text); }
.map-priv svg { width: 16px; height: 16px; color: var(--muted); } .map-priv.warn svg { color: var(--warn); }
.link-btn { border: 0; background: none; color: var(--info); font: inherit; font-weight: 700; padding: 6px 4px; text-decoration: underline; }
.map-fab { bottom: 124px; }
.map-stage .maplibregl-ctrl-bottom-right { bottom: 74px; right: 8px; }
.maplibregl-ctrl-attrib { background: rgba(20, 23, 28, .92) !important; color: var(--muted) !important; font-size: 11px; border-radius: 14px; }
.maplibregl-ctrl-attrib a { color: var(--info) !important; }
.maplibregl-ctrl-attrib-button { background-color: transparent !important; filter: invert(1); }
.map-strip { background: linear-gradient(to top, rgba(11, 13, 16, .96) 70%, rgba(11, 13, 16, 0)); }
.map-edges { position: absolute; inset: 0; z-index: 4; pointer-events: none; overflow: hidden; }
.edge-chip { position: absolute; transform: translate(-50%, -50%); display: inline-flex; align-items: center; gap: 4px; min-height: 36px; padding: 0 10px 0 6px; border: 0; border-radius: 18px; background: #0b0d10; color: #fff; pointer-events: auto;
  box-shadow: 0 0 0 2px var(--c, #fff), 0 0 0 4px #fff, 0 3px 10px rgba(0, 0, 0, .5); font-size: 13px; }
.edge-chip svg { width: 16px; height: 16px; color: var(--c); fill: var(--c); } .edge-chip small { font-size: 12px; color: #cbd2da; font-variant-numeric: tabular-nums; }
.mk { position: relative; width: 36px; height: 36px; }
.mk-dot { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; border: 3px solid #0b0d10; box-shadow: 0 0 0 2.5px #fff, 0 2px 8px rgba(0, 0, 0, .45); color: #0b0d10; font: 800 13px var(--font); }
.mk.stale .mk-dot { border-style: dashed; }
.mk-name { position: absolute; top: 44px; left: 50%; transform: translateX(-50%); padding: 2px 8px; border: 1.5px solid #fff; border-radius: 8px; background: #0b0d10; color: #fff; font: 700 13px var(--font); white-space: nowrap; pointer-events: none; box-shadow: 0 1px 4px rgba(0, 0, 0, .5); }
.me-mk { position: relative; width: 22px; height: 22px; }
.me-dot { position: absolute; inset: 0; border-radius: 50%; background: #2f8cff; border: 3px solid #fff; box-shadow: 0 0 0 1.5px #0b0d10, 0 2px 8px rgba(0, 0, 0, .5); }
.me-acc { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); border-radius: 50%; background: rgba(47, 140, 255, .16); border: 1.5px solid rgba(47, 140, 255, .55); pointer-events: none; }
.me-wedge { position: absolute; left: 50%; top: 50%; width: 64px; height: 64px; margin: -32px 0 0 -32px; border-radius: 50%; pointer-events: none;
  background: conic-gradient(from -28deg, rgba(47, 140, 255, .7) 0 56deg, transparent 56deg); -webkit-mask: radial-gradient(circle, transparent 10px, #000 12px, transparent 32px); mask: radial-gradient(circle, transparent 10px, #000 12px, transparent 32px); }

/* saved maps sheet */
.saved-body { display: flex; flex-direction: column; gap: var(--s2); }
.save-card { display: flex; flex-direction: column; gap: var(--s3); padding: var(--s4); border-radius: var(--r-card); background: var(--bg); box-shadow: inset 0 0 0 1px var(--line); }
.field-label { font-size: var(--fs-1); color: var(--muted); margin-bottom: -6px; }
.est .big { font-size: var(--fs-4); font-weight: 700; font-variant-numeric: tabular-nums; } .est .muted { font-size: var(--fs-2); }
.row-hint.warn { color: var(--warn); }
.prog-head { display: flex; justify-content: space-between; align-items: baseline; } .prog-head b { font-variant-numeric: tabular-nums; }
.meter-bar { height: 8px; border-radius: 4px; background: var(--raised); overflow: hidden; } .meter-bar i { display: block; height: 100%; width: 0; background: var(--accent); transition: width .2s; }
.area-row { padding: 0 var(--s1) 0 0; gap: var(--s2); } .area-go { display: flex; flex-direction: column; align-items: flex-start; min-height: 64px; justify-content: center; padding: var(--s2) 0 var(--s2) var(--s4); border: 0; background: none; color: inherit; text-align: left; font: inherit; }
.btn.small { min-height: 36px; padding: 0 14px; font-size: var(--fs-1); }
.icon-btn.danger { color: var(--danger); }
.storage-line { display: flex; justify-content: space-between; align-items: baseline; } .storage-line .row-value { font-variant-numeric: tabular-nums; }
.saved-body .btn { margin-top: var(--s1); }
.empty.small { padding: var(--s4); }

/* ---------- 13. channel lifetime ---------- */
.ch-life { display: flex; align-items: center; gap: 6px; font-size: var(--fs-1); color: var(--muted); font-variant-numeric: tabular-nums; }
.ch-life.now { color: var(--ok); font-weight: 600; } .ch-life.now .dot { background: var(--ok); }
.sort-row { display: flex; justify-content: flex-end; margin: calc(-1 * var(--s1)) 0 var(--s2); }
.sort-seg label { min-width: 72px; min-height: 36px; font-size: var(--fs-1); }
.mine-row.closed { opacity: .55; } .mine-go.static { cursor: default; pointer-events: none; }
.mine-row.closed .btn { margin-right: var(--s2); opacity: 1; }
.chip { white-space: nowrap; flex: none; }
.cur-kicker { white-space: nowrap; }
.cur-main .chev { display: none; }
.field .field-label { margin-bottom: 6px; }
.ch-life { display: block; }
.ch-life.now { display: flex; }

/* ---------- 14. channel history, consent, replay ---------- */
.ch-name .nm { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ch-name > :not(.nm) { flex: none; }
.ch-meta { white-space: nowrap; }
.chip.hist { background: rgba(255, 90, 79, .14); color: #ff8c84; }
.seg input:disabled + label { opacity: .4; cursor: not-allowed; }
.rec-dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--danger); }
.ch-pill, .sound-chip, .btn.small { position: relative; }
.ch-pill::after, .sound-chip::after, .btn.small::after { content: ""; position: absolute; inset: -6px -2px; }
.tab-unread { position: absolute; top: -1px; left: -3px; width: 10px; height: 10px; border-radius: 50%; background: var(--text); box-shadow: 0 0 0 2px var(--surface); }

/* talk header + two views */
.talk-top { flex: none; display: flex; flex-direction: column; gap: var(--s2); padding: 0 var(--pad-r) var(--s2) var(--pad-l); }
.talk-top h1.large { padding: var(--s1) var(--s1) 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; overflow-wrap: normal; }
#v-talk .bar-title { opacity: 0 !important; }
.hist-state { display: flex; align-items: center; gap: var(--s2); min-width: 0; padding: 0 var(--s1); }
.rec-chip { display: inline-flex; align-items: center; gap: 6px; flex: none; height: 28px; padding: 0 10px; border-radius: 14px; background: rgba(255, 90, 79, .14); color: #ff8c84; font-size: var(--fs-1); font-weight: 700; white-space: nowrap; }
.rec-chip i { width: 8px; height: 8px; border-radius: 50%; background: var(--danger); }
.hs-btn { display: inline-flex; align-items: center; gap: 2px; min-width: 0; min-height: 48px; padding: 0 4px 0 6px; border: 0; background: none; color: var(--muted); font-size: var(--fs-1); font-weight: 600; text-align: left; }
.hs-btn span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hs-btn svg { width: 18px; height: 18px; flex: none; }
.hist-seg-host .seg label { min-height: 44px; }
.seg-badge { position: absolute; top: 5px; right: 8px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--accent); color: var(--on-accent); font-size: 12px; line-height: 18px; font-weight: 700; text-align: center; }
.talk-body { flex: 1; min-height: 0; display: flex; position: relative; }
.tpane { min-width: 0; min-height: 0; flex: 1; display: none; }
.talk-body[data-view="people"] #pane-people { display: block; }
.talk-body[data-view="history"] #pane-hist { display: flex; flex-direction: column; }
.talk-main.split #pane-people { display: block; flex: 0 0 300px; border-right: 1px solid var(--line); }
.talk-main.split #pane-hist { display: flex; flex-direction: column; }
.talk-main.split .hist-seg-host { display: none; }
.pane-title { display: none; margin: 0; padding: var(--s2) var(--pad-r) var(--s1) var(--pad-l); font-size: var(--fs-1); font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.talk-main.split .pane-title { display: block; }
.talk-main.typing .ptt-dock { display: none; }

.hwrap { position: relative; flex: 1; min-height: 0; }
.hlist { position: absolute; inset: 0; display: flex; flex-direction: column; gap: 8px; overflow-y: auto; overflow-anchor: none; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; padding: 4px var(--pad-r) 12px var(--pad-l); }
.hlist > * { flex: none; }
.hday { position: sticky; top: 4px; z-index: 2; align-self: center; margin: 8px 0 2px; padding: 4px 12px; border-radius: 12px; background: var(--raised); box-shadow: 0 0 0 1px var(--line-strong); color: var(--muted); font-size: var(--fs-1); font-weight: 600; }
.hrow { display: flex; align-items: flex-end; gap: 8px; max-width: 100%; }
.hrow.mine { flex-direction: row-reverse; }
.hrow .avatar.small { margin-bottom: 2px; }
.hbubble { min-width: 0; max-width: min(84%, 520px); padding: 8px 12px 10px; border-radius: 16px 16px 16px 4px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.hrow.mine .hbubble { border-radius: 16px 16px 4px 16px; background: rgba(255, 176, 32, .13); box-shadow: inset 0 0 0 1px rgba(255, 176, 32, .32); }
.hrow.voice .hbubble { min-width: min(240px, 80%); }
.hmeta { display: flex; align-items: center; gap: 6px; min-height: 22px; font-size: var(--fs-1); color: var(--muted); }
.hname { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 700; color: var(--text); }
.hmeta .rel { flex: none; white-space: nowrap; font-variant-numeric: tabular-nums; }
.hmore { position: relative; display: grid; place-items: center; flex: none; width: 28px; height: 28px; margin: 0 -6px 0 auto; padding: 0; border: 0; border-radius: 50%; background: none; color: var(--muted); }
.hmore::after { content: ""; position: absolute; inset: -10px; }
.hmore:active { background: var(--raised); }
.hmore svg { width: 20px; height: 20px; }
.hvoice { display: flex; align-items: center; gap: 10px; margin-top: 6px; }
.hplay { position: relative; display: grid; place-items: center; flex: none; width: 40px; height: 40px; padding: 0; border: 0; border-radius: 50%; background: var(--accent); color: var(--on-accent); transition: transform .12s var(--ease); }
.hplay::after { content: ""; position: absolute; inset: -4px; }
.hplay:active { transform: scale(.94); }
.hplay svg { width: 20px; height: 20px; }
.hplay.on { background: var(--text); }
.hplay.gone { background: var(--raised); color: var(--muted); }
.hplay .spin { width: 18px; height: 18px; }
.hpane.offline .hplay { opacity: .4; }
.hbar { flex: 1; min-width: 56px; height: 4px; border-radius: 2px; background: rgba(255, 255, 255, .16); overflow: hidden; }
.hbar i { display: block; height: 100%; background: var(--accent); transform-origin: left; transform: scaleX(0); }
.hrow.mine .hbar { background: rgba(255, 255, 255, .22); }
.hdur { flex: none; font-size: var(--fs-1); color: var(--muted); font-variant-numeric: tabular-nums; }
.htext { margin: 6px 0 0; font-size: var(--fs-2); line-height: 1.4; overflow-wrap: anywhere; }
.hmeta + .hcontent > .htext:first-child { margin-top: 2px; }
.hnote { margin: 6px 0 0; font-size: var(--fs-2); color: var(--muted); }
.hnote.small { margin-top: 2px; font-size: var(--fs-1); }
.hmeta + .hcontent > .hnote:first-child { margin-top: 2px; font-style: italic; }
.ell { display: inline-flex; gap: 3px; margin-left: 4px; vertical-align: middle; }
.ell i { width: 4px; height: 4px; border-radius: 50%; background: currentColor; animation: ell 1.2s ease-in-out infinite; }
.ell i:nth-child(2) { animation-delay: .2s; } .ell i:nth-child(3) { animation-delay: .4s; }
@keyframes ell { 0%, 70%, 100% { opacity: .25; } 35% { opacity: 1; } }
.hrow.pending { opacity: .6; }
.hsys { align-self: center; max-width: 92%; padding: 2px 12px; text-align: center; font-size: var(--fs-1); color: var(--muted); }
.hsys.notice-line { display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 12px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); text-align: left; }
.hsys.notice-line svg { width: 18px; height: 18px; color: var(--warn); }
.hload { align-self: center; display: flex; align-items: center; gap: 8px; padding: 6px; color: var(--muted); font-size: var(--fs-1); }
.hnew { position: absolute; z-index: 3; left: 50%; bottom: 10px; transform: translateX(-50%); min-height: 48px; padding: 0 20px; border: 0; border-radius: 24px; background: var(--accent); color: var(--on-accent); font-size: var(--fs-2); font-weight: 700; box-shadow: 0 6px 18px rgba(0, 0, 0, .5); }
.hnew:not([hidden]) { animation: toast-in .2s var(--ease); }
.hstate { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; overflow-y: auto; padding: var(--s4) var(--pad-r) var(--s4) var(--pad-l); }
.hskel { width: 100%; display: flex; flex-direction: column; gap: 14px; }
.hskel .hrow i { display: block; height: 48px; border-radius: 16px; background: var(--raised); animation: shimmer 1.4s ease-in-out infinite; }
.hskel .avatar { background: var(--raised); animation: shimmer 1.4s ease-in-out infinite; }
.hcompose { flex: none; padding: 8px var(--pad-r) 8px var(--pad-l); }
.hc-form { display: flex; align-items: center; gap: 8px; }
.hc-field { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 16px; border-radius: 24px; background: var(--raised); transition: box-shadow .12s; }
.hc-field:focus-within { box-shadow: 0 0 0 2px var(--accent); }
.hc-field input { flex: 1; min-width: 0; height: 46px; padding: 0; border: 0; border-radius: 0; background: transparent; color: var(--text); font-size: max(16px, var(--fs-3)); -webkit-appearance: none; appearance: none; outline: none; }
.hc-field input::placeholder { color: var(--muted); opacity: 1; }
.hc-count { flex: none; font-size: var(--fs-1); color: var(--muted); font-variant-numeric: tabular-nums; }
.hc-count.over { color: var(--warn); }
.hc-send { display: grid; place-items: center; flex: none; width: 48px; height: 48px; padding: 0; border: 0; border-radius: 50%; background: var(--accent); color: var(--on-accent); transition: transform .12s var(--ease), background-color .15s; }
.hc-send:active { transform: scale(.94); }
.hc-send[disabled] { background: var(--raised); color: var(--muted); pointer-events: none; }
.hc-send svg { width: 22px; height: 22px; }
.hc-block { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 4px; color: var(--muted); font-size: var(--fs-2); line-height: 1.3; }
.hc-block > svg { width: 20px; height: 20px; }
.facts { display: flex; flex-direction: column; gap: 14px; }
.fact { display: flex; align-items: flex-start; gap: 12px; }
.fact-ico { display: grid; place-items: center; flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--raised); color: var(--accent); }
.fact-ico svg { width: 20px; height: 20px; }
.fact .row-title { font-size: var(--fs-2); font-weight: 600; }
.fact .row-hint { font-size: var(--fs-2); }
.hint-p { font-size: var(--fs-1); }
.rp-stop { position: relative; display: grid; place-items: center; flex: none; width: 40px; height: 40px; padding: 0; border: 0; border-radius: 50%; background: var(--raised); color: var(--text); box-shadow: inset 0 0 0 1.5px var(--line-strong); }
.rp-stop::after { content: ""; position: absolute; inset: -4px; }
.rp-stop svg { width: 18px; height: 18px; }
.now-talk.replay { color: var(--accent); }
.now-talk.replay .dot { background: var(--accent); }
.nowbar .now-talk.replay span:last-child { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; line-height: 1.2; text-align: left; font-variant-numeric: tabular-nums; }
.nowbar.rp .now-txt { display: none; }
.rail-rp { display: flex; flex-direction: column; align-items: center; gap: 4px; flex: 0 0 100%; }
.rail-rp[hidden] { display: none; }
.rp-t { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; color: var(--accent); font-variant-numeric: tabular-nums; }

/* current channel card: label + name, meta row of whole items, footer actions */
.cur-card { display: flex; flex-direction: column; align-items: stretch; margin: 0 0 var(--s4); }
.cur-main { align-items: flex-start; width: 100%; padding: 14px 16px 12px; }
.cur-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.cur-text .ch-name { font-size: var(--fs-4); line-height: 1.2; }
.cur-text .ch-name svg { width: 18px; height: 18px; }
.cur-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin: 0; }
.cur-talk { margin: 0; }
.cur-life { font-size: var(--fs-1); color: var(--muted); }
.cur-foot { display: flex; justify-content: flex-end; gap: 4px; padding: 0 8px; border-top: 1px solid var(--line); }
.cur-foot .btn { min-height: 48px; padding: 0 16px; }
.cur-leave { align-self: auto; }

/* head unit card (Me) */
.hu-addr { color: var(--muted); font-size: var(--fs-3); max-width: 50%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row .hu-ico svg { width: 22px; height: 22px; color: var(--accent); }

/* ---------- 15. tablet: rail, two panes, gutters ---------- */
@media (min-width: 800px) {
  .app, .app .view { --pad-l: max(24px, var(--safe-l)); --pad-r: max(24px, var(--safe-r)); }
  .tabs { width: 104px; padding-left: max(var(--s2), var(--safe-l)); }
  .tab { gap: 4px; padding: 8px 6px; }
  .tab-label { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; line-height: 1.15; text-align: center; overflow-wrap: anywhere; }
  .panes { grid-template-columns: 340px minmax(0, 1fr); }
  #v-channels .pillwrap, #v-channels .status { display: none; }
  .scroll > * { max-width: 640px; margin-left: auto; margin-right: auto; }
  .rail-now { flex-direction: row; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px 12px; padding: 12px 8px; border: 1px solid var(--line); border-radius: var(--r-card); background: var(--bg); }
  .rail-name { flex: 0 0 100%; text-align: center; font-size: var(--fs-1); }
  .rail-now .ptt-mini.round { flex: 0 0 100%; width: 100%; min-width: 0; height: 52px; border-radius: 26px; }
  .rail-now .ptt-mini.round .pm-label { display: inline; }
  .map-fab { right: 24px; gap: var(--s3); bottom: 132px; }
  .sort-seg label { min-height: 48px; }
  .hbubble { max-width: min(78%, 520px); }
}
@media (min-width: 800px) and (orientation: landscape) { .panes { grid-template-columns: 380px minmax(0, 1fr); } }

/* history location: chip in a row, temporary pin on the map, back pill, share-now button */
.hloc { position: relative; display: inline-flex; align-items: center; gap: 4px; max-width: 100%; height: 28px; margin-top: 6px; padding: 0 10px 0 8px; border: 0; border-radius: 14px; background: rgba(77, 163, 255, .14); color: #7dbcff; font-size: var(--fs-1); font-weight: 700; white-space: nowrap; }
.hloc::after { content: ""; position: absolute; inset: -10px -4px; }
.hloc svg { width: 16px; height: 16px; }
.hloc:active { background: rgba(77, 163, 255, .28); }
.hc-loc { display: grid; place-items: center; flex: none; width: 48px; height: 48px; padding: 0; border: 0; border-radius: 50%; background: var(--raised); color: #7dbcff; box-shadow: inset 0 0 0 1px var(--line-strong); }
.hc-loc:active { transform: scale(.94); }
.hc-loc svg { width: 22px; height: 22px; }
.hpin { position: relative; width: 36px; height: 36px; }
.hpin-dot { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: #0b0d10; color: var(--accent); border: 3px dashed var(--accent); box-shadow: 0 0 0 2.5px #fff, 0 2px 8px rgba(0, 0, 0, .5); }
.hpin-dot svg { width: 18px; height: 18px; }
.hpin-label { position: absolute; top: 44px; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 2px; padding: 0 2px 0 10px; border: 2px dashed var(--accent); border-radius: 18px; background: #0b0d10; color: #fff; font: 700 13px var(--font); white-space: nowrap; box-shadow: 0 1px 6px rgba(0, 0, 0, .55); }
.hpin-x { position: relative; display: grid; place-items: center; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 50%; background: none; color: #fff; }
.hpin-x::after { content: ""; position: absolute; inset: -8px; }
.hpin-x svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.back-pill { position: absolute; z-index: 6; left: var(--pad-l); bottom: 124px; display: inline-flex; align-items: center; gap: 6px; min-height: 48px; padding: 0 18px 0 10px; border: 0; border-radius: 24px; background: var(--surface); color: var(--text); font-size: var(--fs-2); font-weight: 700; box-shadow: 0 0 0 1px var(--line-strong), 0 4px 14px rgba(0, 0, 0, .5); }
.back-pill:active { transform: scale(.96); }
.back-pill svg { width: 20px; height: 20px; }
.back-pill .flip { display: inline-grid; transform: rotate(180deg); }
.hpin svg { fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.ch-tags { display: flex; flex-wrap: wrap; gap: 4px 6px; margin: 2px 0; }
.ch-lock svg { margin-left: 0; }
.rail-name { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.2; overflow-wrap: anywhere; }
.hrow.pending { opacity: .78; }
.cur-text .ch-name .nm { white-space: normal; overflow-wrap: break-word; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
a.row { text-decoration: none; color: inherit; }
a.row:active { background: rgba(255, 255, 255, .05); }
a.row .row-hint { color: var(--muted); }
@media (max-height: 900px) { .talk-main.split .ptt-wrap, .talk-main.split .ptt { width: 112px; height: 112px; } .talk-main.split .ptt-wrap { margin: 12px 0 10px; } .talk-main.split .ptt-ico svg { width: 30px; height: 30px; } }
@media (max-height: 700px) {
  .talk-main:not(.split) .ptt-wrap, .talk-main:not(.split) .ptt { width: 108px; height: 108px; }
  .talk-main:not(.split) .ptt-wrap { margin: 8px 0 6px; }
  .talk-main:not(.split) .ptt-ico svg { width: 28px; height: 28px; }
  .talk-main:not(.split) .ptt-label { font-size: var(--fs-2); }
  .talk-main:not(.split) .talker-line { display: none; }
  .talk-main:not(.split) .meter { display: none; }
  .talk-top h1.large { font-size: var(--fs-4); }
  .talk-top { gap: 0; padding-bottom: 4px; }
  .hs-btn { min-height: 44px; }
}

/* ---------- 16. cosmetic fixes: history day separator, unread badge on the Talk tab ---------- */
/* The sticky day label gets its own blurred strip across the whole list width, so scrolling entries pass under it instead of colliding with it. */
.hday { position: sticky; top: 0; z-index: 2; align-self: stretch; margin: 0 calc(-1 * var(--pad-r)) 0 calc(-1 * var(--pad-l)); padding: 8px var(--pad-r) 8px var(--pad-l); border-radius: 0; background: rgba(11, 13, 16, .94);
  box-shadow: 0 1px 0 var(--line); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); text-align: center; }
.hday > span { display: inline-block; padding: 4px 12px; border-radius: 12px; background: var(--raised); box-shadow: 0 0 0 1px var(--line-strong); color: var(--muted); font-size: var(--fs-1); font-weight: 600; }
.hlist { padding-top: 0; gap: 8px; }
.hday + * { margin-top: 4px; }
/* The unread count is a numbered accent badge at the icon's lower right. It used to be a second bare white dot beside the state dot. */
.tab-unread { top: auto; left: auto; right: -24px; bottom: -3px; width: auto; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: var(--accent); color: var(--on-accent); font: 700 11px/17px var(--font); text-align: center; box-shadow: 0 0 0 2px var(--surface); font-variant-numeric: tabular-nums; }
.tab-dot[data-s="wait"] { background: var(--muted); }

/* ---------- 17. unit badge, vehicles heard by radio ---------- */
.chip.unit { gap: 4px; background: rgba(77, 163, 255, .16); color: #7dbcff; }
.chip.unit svg { width: 14px; height: 14px; }
.chip.unit.mini { height: 18px; padding: 0 5px; font-size: 12px; }
.chip.radio-chip { gap: 4px; background: rgba(77, 163, 255, .16); color: #7dbcff; margin-left: 6px; }
.chip.radio-chip svg { width: 14px; height: 14px; }
.chip svg { fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.rbadge { display: grid; place-items: center; flex: none; width: 30px; height: 30px; border-radius: 50%; box-shadow: inset 0 0 0 2px var(--info); color: var(--info); }
.rbadge svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; }
.rbadge.big { width: 40px; height: 40px; } .rbadge.big svg { width: 22px; height: 22px; }
.mchip.radio { padding: 0 16px 0 8px; max-width: 300px; }
.mchip .col { display: flex; flex-direction: column; min-width: 0; line-height: 1.15; }
.mchip .col small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mchip .chip.unit { margin-left: -2px; }
.mlabel { display: flex; align-items: center; gap: 6px; flex: none; min-height: var(--tap); padding: 0 4px 0 10px; border-left: 1px solid var(--line-strong); color: var(--info); font-size: var(--fs-1); font-weight: 700; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; }
.mlabel svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; }
.member.radio { cursor: pointer; }
/* markers: a unit is a rounded square, a vehicle heard by radio is a hollow ring; both carry a small badge */
.mk-dot { position: relative; }
.mk-ini { pointer-events: none; }
.mk-badge { position: absolute; right: -9px; bottom: -9px; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: #0b0d10; border: 2px solid #fff; color: #fff; }
.mk-badge:empty { display: none; }
.mk-badge svg { width: 12px; height: 12px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mk.unit .mk-dot { border-radius: 11px; }
.mk.radio .mk-dot { background: rgba(11, 13, 16, .18) !important; border: 5px solid var(--rc, #4da3ff); box-shadow: 0 0 0 2px #0b0d10, 0 0 0 4px #fff, 0 2px 8px rgba(0, 0, 0, .45); }
.mk.radio .mk-name { border-style: dashed; }

/* ---------- 18. Unit tab ---------- */
.unit-host { container: unit / inline-size; display: flex; flex-direction: column; gap: var(--s4); }
.ucenter { display: flex; align-items: center; justify-content: center; gap: var(--s3); padding: var(--s6) var(--s4); }
.uempty { display: flex; flex-direction: column; align-items: center; gap: var(--s4); max-width: 420px; margin: var(--s5) auto; padding: var(--s4); text-align: center; }
.uempty.compact { margin: 0 auto; }
.uempty h2 { font-size: var(--fs-4); font-weight: 700; }
.uempty-ico { display: grid; place-items: center; width: 80px; height: 80px; border-radius: 24px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line-strong); color: var(--accent); }
.uempty-ico svg { width: 42px; height: 42px; }
.uempty-list { display: flex; flex-direction: column; gap: var(--s3); text-align: left; width: 100%; }
.uempty-list li { display: flex; align-items: flex-start; gap: var(--s3); padding: var(--s3) var(--s4); border-radius: var(--r-ctl); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); font-size: var(--fs-2); }
.uempty-list svg { width: 22px; height: 22px; color: var(--info); margin-top: 1px; }
.uempty .btn { min-width: 220px; }
.small-note { font-size: var(--fs-1); max-width: 34ch; }

.uhdr { padding: var(--s4); border-radius: var(--r-card); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line-strong); }
.uh-top { display: flex; align-items: center; gap: var(--s3); }
.uh-ico { display: grid; place-items: center; flex: none; width: 48px; height: 48px; border-radius: 14px; background: var(--raised); color: var(--accent); }
.uh-ico svg { width: 28px; height: 28px; }
.uh-name { font-size: var(--fs-4); font-weight: 700; line-height: 1.2; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.uh-state { display: flex; align-items: center; gap: 6px; font-size: var(--fs-1); font-weight: 600; color: var(--muted); }
.uhdr[data-online="1"] .uh-state { color: var(--ok); } .uhdr[data-online="1"] .uh-state .dot { background: var(--ok); }
.uh-say { margin-left: 6px; padding: 1px 8px; border-radius: 10px; background: rgba(77, 163, 255, .16); color: #7dbcff; }
.uh-facts { display: flex; flex-wrap: wrap; gap: var(--s2) var(--s5); margin-top: var(--s3); }
.uh-fact { display: flex; flex-direction: column; min-width: 0; }
.uh-fact small { font-size: var(--fs-1); color: var(--muted); } .uh-fact b { font-size: var(--fs-2); font-weight: 600; overflow-wrap: anywhere; }
.uh-off { display: flex; align-items: center; gap: var(--s2); margin-top: var(--s3); padding: var(--s2) var(--s3); border-radius: var(--r-ctl); background: rgba(255, 176, 32, .14); color: var(--warn); font-size: var(--fs-1); font-weight: 600; }
.uh-off svg { width: 18px; height: 18px; }
.flip90 svg { transform: rotate(90deg); }

.ugroups { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--s4); padding-bottom: var(--s4); }
.ugroup { border-radius: var(--r-card); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); overflow: hidden; }
.ughead { display: flex; align-items: center; gap: var(--s3); width: 100%; min-height: 64px; padding: var(--s3) var(--s4); border: 0; background: none; color: inherit; text-align: left; }
.ughead:active { background: rgba(255, 255, 255, .04); }
.ugtitle { font-size: var(--fs-3); font-weight: 700; }
.ughead .chev svg { transition: transform .2s var(--ease); } .ughead[aria-expanded="true"] .chev svg { transform: rotate(90deg); }
.ugroup.collapsed .ubody { display: none; }
.ubody { padding: 0 0 var(--s2); }
.ugroups.offline .ubody { opacity: .45; pointer-events: none; filter: saturate(.5); }
.usub { margin: var(--s3) var(--s4) 0; padding-top: var(--s2); font-size: var(--fs-1); font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.urow { position: relative; display: block; width: 100%; min-height: 56px; padding: var(--s3) var(--s4); border: 0; background: none; color: inherit; text-align: left; font-size: var(--fs-3); }
.urow + .urow::before { content: ""; position: absolute; top: 0; left: var(--s4); right: 0; height: 1px; background: var(--line); }
.usub + .urow::before { display: none; }
.uhead { display: flex; align-items: center; gap: var(--s2); min-height: 32px; }
.ulabel { flex: 1; min-width: 0; font-size: var(--fs-3); }
.uval { flex: none; max-width: 55%; font-size: var(--fs-2); color: var(--muted); font-variant-numeric: tabular-nums; text-align: right; }
.uval.wrap { overflow-wrap: anywhere; }
.uhint { display: block; margin-top: 2px; font-size: var(--fs-1); color: var(--muted); }
.uends { display: flex; justify-content: space-between; margin-top: -4px; font-size: var(--fs-1); color: var(--muted); }
.uswitch { cursor: pointer; }
.uswitch:active .knob { width: 32px; }
.uvalrow { display: flex; align-items: center; gap: var(--s3); }
.uvalrow .row-text .ulabel { flex: none; }
button.uvalrow:active, button.ubtn:active { background: rgba(255, 255, 255, .05); }
.ubtn { display: flex; align-items: center; gap: var(--s3); }
.ubtn svg { width: 22px; height: 22px; color: var(--muted); }
.ubtn.danger, .ubtn.danger .ulabel, .ubtn.danger svg { color: var(--danger); }
.unote { display: flex; gap: var(--s3); align-items: flex-start; font-size: var(--fs-2); color: var(--muted); }
.unote svg { width: 20px; height: 20px; margin-top: 2px; color: var(--info); }
.ustat { flex: none; display: grid; place-items: center; width: 20px; height: 20px; }
.ustat > * { display: none; }
.ustat svg { width: 18px; height: 18px; }
.urow[data-s="saving"] .ustat .spin { display: block; width: 16px; height: 16px; }
.urow[data-s="ok"] .ustat .tick { display: block; color: var(--ok); }
.urow[data-s="bad"] .ustat .bad { display: block; color: var(--danger); }
.urow.na { opacity: .42; pointer-events: none; }
.urow.uerr { box-shadow: inset 3px 0 0 var(--danger); }
.uflash { animation: uflash 1.4s var(--ease); }
@keyframes uflash { 0% { background: rgba(255, 176, 32, .3); } 100% { background: transparent; } }
.ustate .dot { width: 10px; height: 10px; } .ustate.on .dot { background: var(--ok); }
.tick-on svg { color: var(--accent); }

.urange { display: block; width: 100%; height: 48px; margin: 0; background: transparent; -webkit-appearance: none; appearance: none; touch-action: pan-y; cursor: pointer; }
.urange:focus { outline: none; }
.urange::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: linear-gradient(to right, var(--accent) calc(14px + (100% - 28px) * var(--f, 0)), var(--raised) 0); box-shadow: inset 0 0 0 1px var(--line); }
.urange::-webkit-slider-thumb { -webkit-appearance: none; width: 28px; height: 28px; margin-top: -11px; border-radius: 50%; border: 0; background: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .55); transition: transform .12s; }
.urange::-moz-range-track { height: 6px; border-radius: 3px; background: var(--raised); }
.urange::-moz-range-progress { height: 6px; border-radius: 3px; background: var(--accent); }
.urange::-moz-range-thumb { width: 28px; height: 28px; border: 0; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .55); }
.drag .urange::-webkit-slider-thumb { transform: scale(1.14); }
.urange:focus-visible::-webkit-slider-thumb { outline: 2px solid var(--accent); outline-offset: 3px; }
.urange:disabled { cursor: default; }

.uchlist { display: flex; flex-direction: column; gap: var(--s2); margin-top: var(--s2); }
.uch { display: flex; align-items: flex-start; gap: var(--s3); min-height: 56px; padding: var(--s3); border-radius: var(--r-ctl); background: var(--raised); cursor: pointer; }
.uch-dot { flex: none; width: 22px; height: 22px; margin-top: 1px; border-radius: 50%; box-shadow: inset 0 0 0 2px var(--line-strong); }
.uch input:checked ~ .uch-dot { background: radial-gradient(circle, var(--accent) 0 5px, transparent 6px); box-shadow: inset 0 0 0 2px var(--accent); }
.uch input:checked ~ .row-text .row-title { color: var(--accent); }
.uch input:focus-visible ~ .uch-dot { outline: 2px solid var(--accent); outline-offset: 2px; }
.uch input:disabled ~ * { opacity: .5; }

.useat { margin: var(--s2) var(--s3) var(--s3); border-radius: var(--r-ctl); background: var(--bg); box-shadow: inset 0 0 0 1px var(--line); overflow: hidden; }
.useat.open { box-shadow: inset 0 0 0 1.5px rgba(255, 176, 32, .55); }
.useat-h { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); padding: var(--s3) var(--s4) var(--s2); font-size: var(--fs-3); }
.useat-st { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-1); font-weight: 600; color: var(--muted); }
.useat.open .useat-st { color: var(--accent); } .useat.open .useat-st .dot { background: var(--accent); }
.umeter { position: relative; height: 8px; margin: 0 var(--s4) var(--s2); border-radius: 4px; background: var(--raised); overflow: hidden; }
.umeter i { position: absolute; inset: 0; background: var(--ok); transform-origin: left; transform: scaleX(0); transition: transform .4s linear; }
.useat .urow { padding-left: var(--s4); padding-right: var(--s4); }
.uallmic { padding-bottom: var(--s3); }
.ugroup[data-g="seats"] .ubody { padding-top: 0; }
.uallmic .seg label { min-width: 0; }
.uallmic .seg, .urow > .seg { margin-top: var(--s2); }
.urow > .seg label { min-width: 0; padding: 0 6px; text-align: center; line-height: 1.15; }

/* wireless headsets (packs) */
.useat-r { display: inline-flex; align-items: center; gap: var(--s2); min-width: 0; }
.wb { display: inline-flex; align-items: center; gap: 4px; height: 22px; padding: 0 7px 0 5px; border-radius: 11px; background: rgba(77, 163, 255, .16); color: #7dbcff; font-size: var(--fs-1); font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.wb svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.wb.lo { background: rgba(255, 176, 32, .16); color: var(--warn); } .wb.cr { background: rgba(255, 90, 79, .16); color: var(--danger); }
.wtop .uvalrow { align-items: flex-start; }
.wtop .uvalrow > .uval { padding-top: 2px; }
.uval.okc { color: var(--ok); font-weight: 600; }
.wago { color: var(--warn); }
.wst { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-1); font-weight: 600; color: var(--muted); white-space: nowrap; }
.wst.ok { color: var(--ok); } .wst.ok .dot { background: var(--ok); }
.wst.pair { color: var(--accent); } .wst.pair .dot { background: var(--accent); animation: wpulse 1.2s ease-in-out infinite; }
.wst.stale { color: var(--muted); } .wst.stale .dot { background: transparent; box-shadow: inset 0 0 0 1.5px var(--muted); }
.wseat[data-state="pair"] { box-shadow: inset 0 0 0 1.5px rgba(255, 176, 32, .55); }
@keyframes wpulse { 50% { opacity: .3; } }
.wstat { padding-top: var(--s2); }
.pst { display: flex; flex-wrap: wrap; align-items: center; gap: 6px var(--s4); font-size: var(--fs-2); }
.pst:not(:has(.pi:not([hidden]))) { display: none; }
.pi { display: inline-flex; align-items: center; gap: 6px; color: var(--text); font-variant-numeric: tabular-nums; white-space: nowrap; --c: var(--text); }
.pi b { font-weight: 600; } .pi > span { color: var(--muted); font-size: var(--fs-1); }
.pi.ok { --c: var(--ok); } .pi.lo { --c: var(--warn); } .pi.cr { --c: var(--danger); }
.pi.lo b, .pi.cr b { color: var(--c); }
.pi svg { width: 22px; height: 22px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.pi .sig rect { fill: var(--raised); stroke: none; } .pi .sig rect.on { fill: currentColor; }
.pi.lo .sig rect.on { fill: var(--warn); }
.pi .bat { width: 26px; color: var(--muted); } .pi .bat .lv { fill: var(--c); stroke: none; } .pi.ok .bat .lv { fill: var(--ok); }
.pi .bat .bolt-bg { stroke: var(--surface); stroke-width: 3.2; } .pi .bat .bolt { stroke: var(--text); stroke-width: 1.6; }
.qd { display: inline-flex; gap: 3px; } .qd i { width: 6px; height: 6px; border-radius: 50%; background: var(--raised); box-shadow: inset 0 0 0 1px var(--line-strong); }
.qd i.on { background: var(--c); box-shadow: none; }
.wmute svg { color: var(--danger); } .wmute b { color: var(--danger); }
.wid { margin-top: var(--s1); font-variant-numeric: tabular-nums; user-select: text; -webkit-user-select: text; }
.wnote { margin-top: var(--s1); }
.wprog { position: relative; height: 4px; margin-top: var(--s2); border-radius: 2px; background: var(--raised); overflow: hidden; }
.wprog i { position: absolute; top: 0; bottom: 0; left: 0; width: 35%; border-radius: 2px; background: var(--accent); animation: wprog 1.4s var(--ease) infinite; }
@keyframes wprog { from { transform: translateX(-100%); } to { transform: translateX(290%); } }
.wfold { min-height: 56px; }
.wfold .ulabel { flex: 1; }
.wfold .uval { max-width: 60%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wfold .chev svg { transition: transform .2s var(--ease); } .wfold[aria-expanded="true"] .chev svg { transform: rotate(90deg); }
.wfold .chev { color: var(--muted); }
.wmore { padding-bottom: var(--s2); }
.wmore > .usub:first-child { margin-top: var(--s1); }
.urow.dim { opacity: .45; }
.wacts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s2); padding: var(--s2) var(--s4) var(--s4); }
.wacts .btn { min-width: 0; padding: 0 12px; }
.wacts .wforget { grid-column: 1 / -1; color: var(--danger); }
.wacts.one > .btn { grid-column: 1 / -1; }
.unit-low { flex: none; display: flex; align-items: center; gap: var(--s2); padding: 8px var(--pad-r) 8px var(--pad-l); background: rgba(255, 90, 79, .14); border-bottom: 1px solid var(--line); font-size: var(--fs-2); }
.unit-low .dot { background: var(--danger); }
.unit-low b { font-weight: 700; }
.wbase .uhead .uval { max-width: none; }
.wmore button.uvalrow .row-text { flex: none; }
.wmore button.uvalrow .uval { flex: 1; max-width: none; }
.wadv-btn .ulabel { color: var(--muted); font-size: var(--fs-2); }
.wadv { margin: 0 var(--s4) var(--s2); border-radius: var(--r-ctl); background: rgba(255, 255, 255, .025); box-shadow: inset 0 0 0 1px var(--line); }
.wadv .urow { padding-left: var(--s3); padding-right: var(--s3); }
.upick { margin: 0; }
.upick .row[aria-pressed="true"] .row-title { color: var(--accent); font-weight: 600; }
.tick-gap { width: 24px; flex: none; }
.ugroup[data-g="packs"] .ubody { padding-top: 0; }
@media (prefers-reduced-motion: reduce) { .wprog i { animation: none !important; width: 100%; opacity: .5; } .wst.pair .dot { animation: none !important; } }

@container unit (min-width: 640px) {
  .ugroups { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  .ugroup.wideall { grid-column: 1 / -1; }
  .ugroup.wideall .ubody { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ugroup.wideall .uallmic { grid-column: 1 / -1; }
  .ugroup[data-g="packs"] .ubody { align-items: start; }
  .ugroup[data-g="packs"] .wtop { grid-column: 1 / -1; }
  .ugroup.collapsed .ubody { display: block; }
  .ugroup.collapsed.wideall .ubody { display: grid; }
  .ughead { pointer-events: none; min-height: 56px; } .ughead .chev { display: none; }
  .uhdr { position: sticky; top: 0; z-index: 3; box-shadow: inset 0 0 0 1px var(--line-strong), 0 8px 18px rgba(0, 0, 0, .5); }
  .uh-top { flex-wrap: nowrap; }
  .uh-facts { margin-top: var(--s2); }
}
@media (min-width: 800px) { .unit-scroll > * { max-width: none; } .unit-scroll > .unit-host { max-width: 1040px; } .unit-scroll { padding-top: 0; } }

/* pairing sheet */
.pc { position: relative; height: 72px; margin: var(--s1) 0; }
.pc-input { position: absolute; inset: 0; z-index: 2; width: 100%; height: 100%; padding: 0; border: 0; background: transparent; color: transparent; caret-color: transparent; font-size: 28px; -webkit-appearance: none; appearance: none; }
.pc-input::selection { background: transparent; }
.pc-cells { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: 10px; }
.pc-grp { display: flex; gap: 6px; }
.pc-cell { display: grid; place-items: center; width: 40px; height: 58px; border-radius: var(--r-ctl); background: var(--raised); font: 700 28px ui-monospace, "SF Mono", Menlo, Consolas, monospace; color: var(--text); transition: box-shadow .12s; }
.pc-cell.on { box-shadow: 0 0 0 2px var(--accent); }
.pc.bad .pc-cell { box-shadow: 0 0 0 2px var(--danger); }
.pc-dash { width: 10px; height: 3px; border-radius: 2px; background: var(--line-strong); }
.pc-how { display: flex; align-items: flex-start; gap: var(--s3); font-size: var(--fs-2); }
.pc-how b { font-weight: 700; }
.pc-step { display: grid; place-items: center; flex: none; width: 24px; height: 24px; border-radius: 50%; background: var(--raised); color: var(--accent); font-size: var(--fs-1); font-weight: 700; }
@media (min-width: 420px) { .pc-cell { width: 44px; height: 62px; } .pc-grp { gap: 8px; } }

/* ---------- 19. full-screen map ---------- */
.map-tr { display: flex; align-items: center; gap: var(--s2); }
.map-top { align-items: flex-start; }
.stripbtn, .compass { }
.stripbtn { display: none; }
.compass .cmp { display: grid; transition: transform .2s var(--ease); }
.full-chip, .fullptt, .map-drive { display: none; }
@media (max-width: 520px) { .map-pill > span:not(.ico) { display: none; } .map-pill { width: var(--tap); padding: 0; justify-content: center; } }
@media (max-width: 380px) { .map-look .seg label { min-width: 46px; font-size: var(--fs-1); } .map-top { gap: 6px; } .map-tr { gap: 6px; } }

html[data-full="1"] .tabs, html[data-full="1"] .nowbar, html[data-full="1"] #v-channels { display: none !important; }
html[data-full="1"] #v-map > .bar { display: none; }
html[data-full="1"] #v-map > .conn-banner { position: absolute; z-index: 8; left: 0; right: 0; top: 0; padding-top: calc(8px + var(--safe-t)); }
html[data-full="1"] .panes { grid-template-columns: minmax(0, 1fr); }
html[data-full="1"] .view:not(#v-channels) { grid-column: 1; }
html[data-full="1"] .toast { bottom: calc(var(--s5) + var(--safe-b)); }
html[data-full="1"] .map-priv { display: none; }
html[data-full="1"] .map-stage { --fm: max(20px, calc(var(--safe-l) + 14px)); --fr: max(20px, calc(var(--safe-r) + 14px)); --ft: calc(max(16px, var(--safe-t)) + 8px); --fb: calc(max(20px, var(--safe-b)) + 8px); --stripH: calc(68px + var(--safe-b)); }
html[data-full="1"] .map-stage.strip-off { --stripH: 0px; }
html[data-full="1"] .map-top { top: var(--ft); left: var(--fm); right: var(--fr); }
html[data-full="1"] .fab, html[data-full="1"] .map-pill { min-height: 56px; }
html[data-full="1"] .fab { width: 56px; height: 56px; }
html[data-full="1"] .map-pill { padding: 0 20px 0 16px; width: auto; } html[data-full="1"] .map-pill > span:not(.ico) { display: inline; }
html[data-full="1"] .map-look { padding: 3px; } html[data-full="1"] .map-look .seg label { min-height: 50px; min-width: 62px; }
html[data-full="1"] .map-tr { gap: 12px; }
html[data-full="1"] .map-fab { right: var(--fr); bottom: calc(var(--stripH) + var(--fb) + 28px); gap: 14px; }
html[data-full="1"] .stripbtn { display: grid; }
html[data-full="1"] .map-stage.strip-off .map-strip { display: none; }
html[data-full="1"] .map-strip { padding: 8px var(--fr) calc(8px + var(--safe-b)) var(--fm); background: rgba(11, 13, 16, .55); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
html[data-full="1"] .map-stage .maplibregl-ctrl-bottom-right { bottom: calc(var(--stripH) + 2px); right: max(6px, var(--safe-r)); }
html[data-full="1"] .map-chips { top: auto; left: var(--fm); right: auto; bottom: calc(var(--stripH) + var(--fb) + 96px); }
html[data-full="1"] .back-pill { bottom: calc(var(--stripH) + 96px); left: var(--fm); }
html[data-full="1"] .full-chip { position: absolute; z-index: 6; display: inline-flex; align-items: center; gap: 10px; top: calc(var(--ft) + 56px + 12px); left: var(--fm); max-width: calc(100% - var(--fm) - 150px); min-height: 56px; padding: 0 18px 0 16px;
  border: 0; border-radius: 28px; background: var(--surface); color: var(--text); box-shadow: 0 0 0 1px var(--line-strong), 0 4px 14px rgba(0, 0, 0, .5); font-size: var(--fs-2); font-weight: 700; }
html[data-full="1"] .full-chip:active { transform: scale(.97); }
.full-chip .dot { width: 10px; height: 10px; background: var(--ok); }
.full-chip[data-s="other"] { box-shadow: 0 0 0 2px var(--info), 0 4px 14px rgba(0, 0, 0, .5); } .full-chip[data-s="other"] .dot { background: var(--info); }
.full-chip[data-s="me"] { box-shadow: 0 0 0 2px var(--accent), 0 4px 14px rgba(0, 0, 0, .5); } .full-chip[data-s="me"] .dot { background: var(--accent); }
.full-chip[data-s="wait"] .dot, .full-chip[data-s="none"] .dot { background: var(--muted); }
.fc-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fc-n { display: inline-flex; align-items: center; gap: 4px; flex: none; color: var(--muted); font-variant-numeric: tabular-nums; } .fc-n svg { width: 18px; height: 18px; }
.fc-say { flex: none; padding: 2px 10px; border-radius: 12px; background: rgba(77, 163, 255, .18); color: #7dbcff; white-space: nowrap; }
.full-chip[data-s="me"] .fc-say { background: rgba(255, 176, 32, .18); color: var(--accent); }
html[data-full="1"] .fullptt:not([hidden]) { position: absolute; z-index: 6; display: flex; flex-direction: column; gap: 2px; left: calc(50% - 46px); bottom: calc(var(--stripH) + var(--fb)); width: 92px; height: 92px; min-width: 0; padding: 0; border-radius: 50%; box-shadow: inset 0 0 0 2px var(--line-strong), 0 8px 24px rgba(0, 0, 0, .55); background: var(--surface); }
html[data-full="1"] .fullptt .pm-label { display: block; font-size: var(--fs-2); } html[data-full="1"] .fullptt svg { width: 30px; height: 30px; }
html[data-full="1"] .fullptt[data-state="live"] { background: var(--accent); }
html[data-full="1"] .map-drive:not([hidden]) { position: absolute; z-index: 5; display: flex; align-items: center; gap: 16px; left: var(--fm); top: calc(var(--ft) + 56px + 12px + 56px + 12px); padding: 10px 18px; border-radius: 20px; background: rgba(20, 23, 28, .9);
  box-shadow: 0 0 0 1px var(--line-strong), 0 4px 14px rgba(0, 0, 0, .5); font-variant-numeric: tabular-nums; }
.dv-speed { display: flex; align-items: baseline; gap: 4px; } .dv-speed b { font-size: 34px; line-height: 1; font-weight: 700; } .dv-speed small, .dv-near small { font-size: var(--fs-1); color: var(--muted); }
.dv-near { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; padding-left: 16px; border-left: 1px solid var(--line-strong); } .dv-near b { font-size: var(--fs-2); } .dv-near span { font-size: var(--fs-1); color: var(--muted); }
@media (min-width: 800px) { html[data-full="1"] .map-drive:not([hidden]) { top: auto; bottom: calc(var(--stripH) + var(--fb)); } html[data-full="1"] .full-chip { max-width: min(60%, 560px); } }
.pc-how + .pc-how { margin-top: calc(-1 * var(--s2)); }
.stack > .err { margin: 0; font-size: var(--fs-1); color: var(--danger); }
.stack > .err:empty { display: none; }
.pc-input:focus, .pc-input:focus-visible { outline: none; }
.ustate { display: grid; place-items: center; flex: none; width: 20px; height: 20px; }

@media (max-width: 599px) {
  html[data-full="1"] .map-pill { width: 56px; padding: 0; justify-content: center; }
  html[data-full="1"] .map-pill > span:not(.ico) { display: none; }
  html[data-full="1"] .map-tr { flex-direction: column-reverse; align-items: flex-end; gap: 10px; }
  html[data-full="1"] .map-look .seg label { min-width: 50px; padding: 0 4px; }
  html[data-full="1"] .map-fab { gap: 10px; }
  html[data-full="1"] .full-chip { max-width: calc(100% - var(--fm) - var(--fr) - 76px); }
}
@media (max-height: 700px) { html[data-full="1"] .map-fab { gap: 8px; } html[data-full="1"] .fab { width: 56px; height: 56px; } }

/* ---------- 20. trails ---------- */
/* navigation: phones reach Trails from the Map/Trails switch in the Map header (the tab bar already holds five tabs);
   tablets get a rail item and two panes: the list or a trail's detail on the left, the map on the right */
.tab[data-tab="trails"] { display: none; }
.tab-dot.rec { background: var(--danger); }
.mapseg-host { display: flex; flex: none; }
.mapseg label { min-width: 64px; min-height: 40px; padding: 0 10px; }
.mapseg { position: relative; }
.mapseg label::after { content: ""; position: absolute; inset: -4px 0; }
#v-map .bar-title, #v-trails .bar-title { display: none; }
#v-trails .bar .pillwrap { margin-left: auto; }
#v-map .bar .ch-pill, #v-trails .bar .ch-pill { max-width: 38vw; }
@media (max-width: 380px) { .mapseg label { min-width: 56px; padding: 0 6px; } #v-map .bar .st .lbl, #v-trails .bar .st .lbl { display: none; } }
@media (min-width: 800px) {
  .tab[data-tab="trails"] { display: flex; }
  .mapseg-host { display: none; }
  #v-map .bar-title, #v-trails .bar-title { display: block; }
  #v-trails .bar-title { opacity: 0; } #v-trails.scrolled .bar-title { opacity: 1; }
  [data-tab="trails"] #v-channels { display: none; }
  #v-trails { grid-column: 1 !important; border-right: 1px solid var(--line); }
  [data-tab="trails"] #v-map { display: flex; grid-column: 2; }
  #v-trails .pillwrap, #v-trails .status { display: none; }
}
html[data-full="1"] #v-trails { display: none !important; }

.trails-scroll { padding-top: 0; }
.trails-host { display: block; }
.tbtns .btn { flex: 1 1 120px; }
.btn.recording { box-shadow: inset 0 0 0 1.5px var(--danger); color: var(--danger); }
.ico.rec-on svg, .btn.recording svg { color: var(--danger); }
.tcontrols { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2) var(--s3); margin: 0 0 var(--s4); }
.tsearch { flex: 1 1 200px; position: relative; display: flex; align-items: center; min-height: var(--tap); padding: 0 4px 0 12px; border-radius: var(--r-ctl); background: var(--raised); color: var(--muted); }
.tsearch:focus-within { box-shadow: 0 0 0 2px var(--accent); }
.tsearch svg { width: 20px; height: 20px; }
.tsearch-in { flex: 1; min-width: 0; height: var(--tap); padding: 0 8px; border: 0; background: none; color: var(--text); font-size: max(16px, var(--fs-3)); -webkit-appearance: none; appearance: none; }
.tsearch-in:focus { outline: none; }
.tsearch-in::placeholder { color: var(--muted); opacity: 1; }
.tsearch-in::-webkit-search-cancel-button, .tsearch-in::-webkit-search-decoration { -webkit-appearance: none; appearance: none; display: none; }
.tsearch-x { display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 50%; background: none; color: var(--muted); }
.tsearch-x svg { width: 18px; height: 18px; }
.tsort { flex: 1 1 auto; }
.tsort label { min-width: 0; min-height: var(--tap); font-size: var(--fs-1); padding: 0 8px; }
.group.tgroup { --inset: 84px; }
.trow { gap: var(--s3); min-height: 76px; padding-right: var(--s3); }
.trow.current { box-shadow: inset 3px 0 0 var(--accent); }
.tthumb { flex: none; width: 56px; height: 56px; border-radius: 12px; background: var(--raised); box-shadow: inset 0 0 0 1px var(--line); }
.tthumb.ph { display: grid; place-items: center; color: var(--muted); }
.tname { display: flex; align-items: center; gap: 6px; min-width: 0; font-size: var(--fs-3); font-weight: 600; }
.tname .nm { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tvis { flex: none; color: var(--info); } .tvis svg { width: 16px; height: 16px; }
.tchips { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; }
.ch-sub.bad { color: var(--danger); }
.tnear { flex: none; display: flex; flex-direction: column; align-items: flex-end; font-variant-numeric: tabular-nums; }
.tnear b { font-size: var(--fs-2); font-weight: 600; } .tnear small { font-size: var(--fs-1); color: var(--muted); }
.row-ico { display: grid; place-items: center; flex: none; width: 36px; height: 36px; border-radius: 10px; background: var(--raised); color: var(--text); }
.row-ico svg { width: 20px; height: 20px; }
.row-ico.info { color: var(--info); } .row-ico.info svg { transition: transform .3s var(--ease); }
.danger-row .row-ico { color: var(--danger); background: rgba(255, 90, 79, .12); }
.row.off { opacity: .55; }
.row[aria-disabled="true"] { opacity: .55; }
.tsess { margin: 0 0 var(--s4); padding: var(--s3) var(--s4); border-radius: var(--r-card); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line-strong); }
.tsess.on { box-shadow: inset 3px 0 0 var(--danger), inset 0 0 0 1px var(--line-strong); }
.tsess-top { display: flex; align-items: center; gap: var(--s2); min-width: 0; }
.tsess-dot { flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--muted); }
.tsess.on .tsess-dot { background: var(--danger); animation: shimmer 1.4s ease-in-out infinite; }
.tsess-k { flex: 1; min-width: 0; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tsess-v { flex: none; font-variant-numeric: tabular-nums; color: var(--text); font-weight: 600; }
.tsess-hint { margin: 4px 0 var(--s3); font-size: var(--fs-1); color: var(--muted); }
.tsess-act { display: flex; gap: var(--s2); }
.tsess-act .btn.small { min-height: 40px; padding: 0 16px; font-size: var(--fs-2); }
.hint-p { font-size: var(--fs-2); }

/* detail (tablet pane and phone card share it) */
.tdetail-pane { padding-top: var(--s2); }
.tback { min-height: 44px; padding: 0 8px 0 0; margin-left: -4px; color: var(--accent); font-size: var(--fs-2); }
.tback svg, .tcard-back svg { width: 20px; height: 20px; }
.flip svg { transform: scaleX(-1); }
.tdet-head { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 0 var(--s1) var(--s4); }
.tdet-name { font-size: var(--fs-5); }
.tdet-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 8px; color: var(--muted); font-size: var(--fs-2); }
.tdet-meta .chip { gap: 4px; } .tdet-meta .chip svg { width: 14px; height: 14px; }
.tstats { display: grid; grid-template-columns: repeat(var(--n, 3), minmax(0, 1fr)); gap: 1px; margin: 0 0 var(--s4); border-radius: var(--r-card); background: var(--line); overflow: hidden; box-shadow: 0 0 0 1px var(--line); }
.tstat { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding: var(--s3); background: var(--surface); }
.tstat-k { font-size: var(--fs-1); color: var(--muted); font-weight: 600; }
.tstat b { font-size: var(--fs-4); font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tstat small { font-size: var(--fs-1); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@container tcard (max-width: 440px) { .tstats.four { grid-template-columns: repeat(2, minmax(0, 1fr)); } .tstat b { font-size: var(--fs-3); } .tstat { padding: var(--s3) var(--s3); } }
.trails-host { container: tpane / inline-size; }
@container tpane (max-width: 420px) { .tstats.four { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.tacts { margin-bottom: var(--s4) !important; --inset: 64px; }
.tstart .row-title { font-weight: 600; }
.tprof { margin: 0 0 var(--s4); padding: var(--s3) var(--s4) var(--s2); border-radius: var(--r-card); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.tprof-head { display: flex; justify-content: space-between; align-items: baseline; gap: var(--s2); }
.tprof-head .section-label { margin: 0; }
.tprof-rng { font-size: var(--fs-1); color: var(--muted); font-variant-numeric: tabular-nums; }
.tprof-plot { position: relative; height: 112px; margin-top: var(--s2); touch-action: pan-y; }
.tprof-plot svg { width: 100%; height: 100%; }
.pf-fill { fill: rgba(255, 79, 216, .16); } .pf-line { fill: none; stroke: #ff4fd8; stroke-width: 2.25; stroke-linejoin: round; }
.tprof-cur { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: var(--text); pointer-events: none; }
.tprof-tip { position: absolute; top: -4px; padding: 2px 8px; border-radius: 8px; background: var(--raised); box-shadow: 0 0 0 1px var(--line-strong); font-size: var(--fs-1); font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; pointer-events: none; }
.tprof-axis { display: flex; justify-content: space-between; margin-top: 4px; font-size: var(--fs-1); color: var(--muted); font-variant-numeric: tabular-nums; }
.tdesc { margin: 0 var(--s1) var(--s4); color: var(--muted); font-size: var(--fs-2); white-space: pre-wrap; overflow-wrap: anywhere; }
.tloading { display: flex; align-items: center; gap: var(--s2); padding: var(--s4) var(--s1); color: var(--muted); }

/* phone: the trail as a card over the map */
.tcard { position: absolute; z-index: 7; left: 0; right: 0; bottom: 0; max-height: min(62%, 560px); display: flex; flex-direction: column; container: tcard / inline-size;
  border-radius: var(--r-card) var(--r-card) 0 0; background: var(--surface); box-shadow: 0 -1px 0 var(--line-strong), 0 -8px 28px rgba(0, 0, 0, .5); animation: tcard-in .22s var(--ease); }
@keyframes tcard-in { from { transform: translateY(40px); opacity: 0; } }
.tcard-head { flex: none; padding: 0 max(var(--s3), var(--safe-r)) var(--s2) max(var(--s3), var(--safe-l)); }
.tcard-head .grab { margin: 8px auto 8px; }
.tcard-bar { display: flex; align-items: center; gap: var(--s2); min-width: 0; }
.tcard-title { flex: 1; min-width: 0; font-size: var(--fs-3); font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tcard-back { min-height: 40px; padding: 0 14px 0 8px; box-shadow: 0 0 0 1px var(--line-strong); }
.tcard-body { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: var(--s1) max(var(--s4), var(--safe-r)) var(--s4) max(var(--s4), var(--safe-l)); }
.tcard-body .tdet-head { padding-bottom: var(--s3); }
.map-stage.has-tcard .map-strip, .map-stage.has-tcard .map-priv, .map-stage.has-tcard .maplibregl-ctrl-bottom-right { display: none; }
.map-stage.has-tcard .map-fab { bottom: calc(var(--tcardh, 0px) + 12px); }
.map-stage.has-tcard .map-fab #map-in, .map-stage.has-tcard .map-fab #map-out { display: none; }
@media (min-width: 800px) { .tcard { display: none !important; } }

/* follow chip: how far am I from the shown trail */
.tfollow { position: absolute; z-index: 6; top: 70px; right: var(--pad-r); display: flex; align-items: center; gap: 10px; max-width: min(340px, calc(100% - 32px)); min-height: 56px; padding: 6px 6px 6px 8px;
  border: 0; border-radius: 18px; background: rgba(20, 23, 28, .97); color: var(--text); text-align: left; box-shadow: 0 0 0 1.5px var(--line-strong), 0 4px 14px rgba(0, 0, 0, .5); }
.tfollow[data-s="on"] { box-shadow: 0 0 0 2px var(--ok), 0 4px 14px rgba(0, 0, 0, .5); }
.tfollow[data-s="off"] { box-shadow: 0 0 0 2px var(--warn), 0 4px 14px rgba(0, 0, 0, .5); }
.tf-ico { display: grid; place-items: center; flex: none; width: 40px; height: 40px; border-radius: 12px; background: var(--raised); color: #ff4fd8; }
.tfollow[data-s="off"] .tf-ico { color: var(--warn); } .tf-ico svg { transition: transform .3s var(--ease); }
.tf-t { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.tf-t b { font-size: var(--fs-2); font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-variant-numeric: tabular-nums; }
.tf-t small { font-size: var(--fs-1); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tf-x { display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: 50%; color: var(--muted); }
.tf-x svg { width: 18px; height: 18px; }
.map-stage.has-tcard .tfollow { display: none; }
@media (max-width: 799px) { .tfollow { left: var(--pad-l); right: var(--pad-r); max-width: none; } }
html[data-full="1"] .tfollow { top: calc(var(--ft) + 56px + 12px + 56px + 12px); left: var(--fm); right: auto; }
@media (min-width: 800px) { html[data-full="1"] .tfollow { top: calc(var(--ft) + 56px + 12px); left: auto; right: var(--fr); } }
@media (max-width: 599px) { html[data-full="1"] .tfollow { top: auto; left: var(--fm); right: calc(var(--fr) + 68px); bottom: calc(var(--stripH) + var(--fb) + 104px); max-width: none; } }

/* "Alice shared a trail" notice: like a toast, but tappable */
.tnote { position: fixed; z-index: 61; left: 50%; top: calc(var(--safe-t) + 60px); transform: translateX(-50%); width: min(92vw, 460px); display: flex; align-items: center; gap: var(--s2);
  padding: 6px 4px 6px 12px; border-radius: 20px; background: #272d35; box-shadow: 0 0 0 1.5px #ff4fd8, 0 8px 24px rgba(0, 0, 0, .5); animation: tnote-in .2s var(--ease); }
@keyframes tnote-in { from { opacity: 0; } }
.tnote-ico { flex: none; color: #ff4fd8; } .tnote-t { flex: 1; min-width: 0; font-weight: 600; font-size: var(--fs-2); overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.tnote .btn.small { min-height: 40px; }
@media (min-width: 800px) { .tnote { left: auto; right: var(--s5); transform: none; top: calc(var(--safe-t) + 72px); } }
html[data-full="1"] .tnote { top: calc(var(--safe-t) + 16px); }
.hsys-trail { display: flex; align-items: center; gap: 8px; align-self: center; max-width: 100%; min-height: 40px; padding: 4px 8px 4px 12px; border: 0; border-radius: 20px; background: rgba(255, 79, 216, .12); color: #ff9be9; font: inherit; font-size: var(--fs-1); font-weight: 600; text-align: left; }
.hsys-trail svg { width: 18px; height: 18px; flex: none; } .hsys-trail .chev svg { color: #ff9be9; }
.hsys-trail span:not(.ico) { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* map top bar: the right-hand pills lose their words when the map pane itself is narrow (tablet portrait), not only on phones */
.map-stage { container: mapstage / inline-size; }
@container mapstage (max-width: 560px) { .map-pill:not(.tcard-back) > span:not(.ico) { display: none; } .map-pill:not(.tcard-back) { width: var(--tap); padding: 0; justify-content: center; } .map-look .seg label { min-width: 52px; } }
a.btn { text-decoration: none; }
.map-stage.has-tcard .map-void { top: calc((100% - var(--tcardh, 0px)) / 2 + 20px); padding: var(--s3) var(--s4); }
.map-stage.has-tcard .map-void .void-s { display: none; }
.tchips .chip { height: 22px; }
@media (min-width: 800px) { .trow .chev { display: none; } .trow { padding-right: var(--s4); } }

/* ---------- Draw an area to save (drawarea.js). Phone: a card across the bottom of the map; a map pane 640 px or wider (tablets,
   desktop): a floating card at the bottom left so most of the map stays visible. Big handles for thumbs and gloves. */
.da-card { position: absolute; z-index: 8; left: 0; right: 0; bottom: 0; display: flex; flex-direction: column; gap: var(--s2); padding: var(--s3) max(var(--s3), var(--safe-r)) var(--s3) max(var(--s3), var(--safe-l));
  border-radius: var(--r-card) var(--r-card) 0 0; background: var(--surface); box-shadow: 0 -1px 0 var(--line-strong), 0 -8px 28px rgba(0, 0, 0, .5); animation: tcard-in .22s var(--ease); touch-action: manipulation; }
.da-card[hidden] { display: none; }
.da-head { display: none; align-items: center; justify-content: space-between; gap: var(--s2); margin: -4px -6px -4px 4px; }
.da-title { font-size: var(--fs-3); font-weight: 700; }
.da-segs { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: var(--s2); }
.da-segs .seg label { min-width: 0; padding: 0 4px; gap: 6px; display: flex; font-size: var(--fs-2); white-space: nowrap; }
.da-segs .seg label svg { width: 18px; height: 18px; flex: none; }
.da-segs .seg.none .thumb { opacity: 0; }
.da-segs .seg[hidden] { display: none; }
.da-read { display: flex; flex-direction: column; gap: 2px; min-height: 44px; padding: 0 4px; }
.da-rt { font-size: var(--fs-3); font-weight: 700; font-variant-numeric: tabular-nums; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.da-rs { font-size: var(--fs-1); color: var(--muted); font-variant-numeric: tabular-nums; }
.da-read.warn .da-rs { color: var(--warn); }
.da-chips { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 6px; }
.da-chips::-webkit-scrollbar { display: none; }
.da-chips[hidden] { display: none; }
.da-chips-k { flex: none; font-size: var(--fs-1); color: var(--muted); padding-right: 4px; }
.da-chip { min-width: 0; min-height: var(--tap); padding: 0 4px; white-space: nowrap; border: 0; border-radius: 24px; background: var(--raised); color: var(--text); font: inherit; font-size: var(--fs-2); font-weight: 600; font-variant-numeric: tabular-nums;
  box-shadow: inset 0 0 0 1px var(--line); transition: transform .12s, background-color .12s; }
.da-chip:active { transform: scale(.96); }
.da-chip[aria-pressed="true"] { background: var(--accent); color: var(--on-accent); box-shadow: none; }
.da-quick { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s2); }
.da-q { display: flex; align-items: center; justify-content: center; gap: 6px; min-height: var(--tap); padding: 0 8px; border: 0; border-radius: var(--r-ctl); background: var(--raised); color: var(--text); font: inherit; font-size: var(--fs-1); font-weight: 600;
  white-space: nowrap; transition: transform .12s; }
.da-q:active { transform: scale(.97); }
.da-q svg { width: 20px; height: 20px; flex: none; color: var(--accent); }
.da-q.off { color: var(--muted); } .da-q.off svg { color: var(--muted); }
.da-act { display: flex; gap: var(--s2); }
.da-act .btn.primary { flex: 1; }
.da-act .btn.primary svg { width: 20px; height: 20px; }
.da-act .btn.text { padding: 0 16px; }

.da-handles { position: absolute; inset: 0; z-index: 6; pointer-events: none; overflow: hidden; }
.da-h { position: absolute; left: 0; top: 0; width: 56px; height: 56px; margin: -28px 0 0 -28px; display: grid; place-items: center; pointer-events: auto; touch-action: none; cursor: grab; }
.da-h[hidden] { display: none; }
.da-h.drag { cursor: grabbing; }
.da-k { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 3px var(--accent), 0 2px 8px rgba(0, 0, 0, .55); transition: transform .12s var(--overshoot); }
.da-h.drag .da-k { transform: scale(1.25); }
.da-h.edge.ns .da-k { width: 34px; height: 14px; border-radius: 7px; }
.da-h.edge.ew .da-k { width: 14px; height: 34px; border-radius: 7px; }
.da-h.grip .da-k { width: 44px; height: 44px; background: var(--surface); color: var(--accent); box-shadow: 0 0 0 2px var(--accent), 0 2px 10px rgba(0, 0, 0, .55); }
.da-h.grip .da-k svg { width: 24px; height: 24px; }
html[data-full="1"] .da-h { width: 64px; height: 64px; margin: -32px 0 0 -32px; }
html[data-full="1"] .da-k { width: 28px; height: 28px; }
html[data-full="1"] .da-h.grip .da-k { width: 50px; height: 50px; }

/* while drawing: crosshair, no member strip, edge chips, trail card, follow chip or readouts in the way; the zoom buttons sit above the card */
.map-stage.da-on .map-strip, .map-stage.da-on .map-priv, .map-stage.da-on .map-edges, .map-stage.da-on .tcard, .map-stage.da-on .tfollow, .map-stage.da-on .map-drive,
.map-stage.da-on .map-chips, .map-stage.da-on .back-pill, .map-stage.da-on #map-fit, .map-stage.da-on .stripbtn, .map-stage.da-on .maplibregl-ctrl-bottom-right { display: none !important; }
.map-stage.da-on .map-fab, html[data-full="1"] .map-stage.da-on .map-fab { bottom: calc(var(--dah, 0px) + 12px); }
.map-stage.da-on #map-in, .map-stage.da-on #map-out { display: grid !important; }
.map-stage.da-drawing .maplibregl-canvas-container, .map-stage.da-drawing .maplibregl-canvas { cursor: crosshair; touch-action: none !important; }
html[data-full="1"] .map-stage.da-on { --stripH: 0px; }
html[data-full="1"] .map-stage.da-on .da-card { left: var(--fm); right: var(--fr); bottom: var(--fb); border-radius: var(--r-card); box-shadow: 0 0 0 1px var(--line-strong), 0 8px 28px rgba(0, 0, 0, .55); }
html[data-full="1"] .map-stage.da-on .map-fab { bottom: calc(var(--dah, 0px) + var(--fb) + 12px); }
html[data-full="1"] .map-stage.da-on .fullptt:not([hidden]) { bottom: calc(var(--dah, 0px) + var(--fb) + 12px); }
html[data-full="1"] .map-stage.da-on .full-chip { display: none; }
@container mapstage (max-width: 430px) { .da-segs .seg label svg { display: none; } }
@container mapstage (min-width: 640px) {
  .da-card, html[data-full="1"] .map-stage.da-on .da-card { left: 16px; right: auto; bottom: 16px; width: min(420px, calc(100% - 120px)); border-radius: var(--r-card); box-shadow: 0 0 0 1px var(--line-strong), 0 8px 28px rgba(0, 0, 0, .55); padding: var(--s3) var(--s4) var(--s4); }
  html[data-full="1"] .map-stage.da-on .da-card { left: var(--fm); bottom: var(--fb); }
  .da-head { display: flex; }
  .map-stage.da-on .map-fab { bottom: 16px; }
  html[data-full="1"] .map-stage.da-on .map-fab { bottom: calc(var(--fb) + 12px); }
  html[data-full="1"] .map-stage.da-on .fullptt:not([hidden]) { left: auto; right: calc(var(--fr) + 76px); bottom: var(--fb); }
  html[data-full="1"] .map-stage.da-on .full-chip { display: inline-flex; }
}

/* download progress on the map: pause / resume and stop, 48 px targets */
.map-chips .dl-pill { pointer-events: auto; }
.dl-pill { display: flex; align-items: center; gap: var(--s2); max-width: min(360px, calc(100vw - 32px)); min-height: 56px; padding: 4px 4px 4px 12px; border-radius: 28px; background: var(--surface);
  box-shadow: 0 0 0 1px var(--line-strong), 0 4px 14px rgba(0, 0, 0, .5); }
.dl-ring { flex: none; display: grid; place-items: center; width: 20px; }
.dl-pill.paused .dl-ring .spin { animation: none; border-color: var(--muted); }
.dl-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 5px; padding-right: 4px; }
.dl-t { font-size: var(--fs-2); font-weight: 700; font-variant-numeric: tabular-nums; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dl-bar { display: block; height: 4px; border-radius: 2px; background: var(--raised); overflow: hidden; } .dl-bar i { display: block; height: 100%; width: 0; background: var(--accent); transition: width .2s; }
.dl-pill.paused .dl-bar i { background: var(--muted); }
.dl-b { flex: none; display: grid; place-items: center; width: var(--tap); height: var(--tap); border: 0; border-radius: 50%; background: var(--raised); color: var(--text); transition: transform .12s; }
.dl-b:active { transform: scale(.94); }
.dl-b svg { width: 22px; height: 22px; }
.map-stage:has(> .tfollow:not([hidden])) .map-chips { top: 136px; }
html[data-full="1"] .map-chips { right: calc(var(--fr) + 76px); }
html[data-full="1"] .map-stage:has(> .tfollow:not([hidden])) .map-chips { top: auto; }

/* Saved maps sheet: add buttons, rows with shape icon and inline progress; the download sheet */
.add-card { gap: var(--s2); }
.add-card .row-hint { margin: 0; }
.add-btns { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: var(--s2); }
.saved-body .add-btns .btn { margin-top: 0; padding: 0 12px; }
.area-ico { flex: none; display: grid; place-items: center; width: 40px; height: 40px; margin-left: var(--s3); border-radius: 12px; background: var(--raised); color: var(--muted); }
.area-ico.ok { color: var(--ok); }
.area-ico svg { width: 22px; height: 22px; }
.area-row .area-go { flex: 1; min-width: 0; padding-left: 0; gap: 1px; }
.area-row.current .area-ico { box-shadow: inset 0 0 0 2px var(--ok); }
.area-row .btn.small svg { width: 16px; height: 16px; }
.row-hint.acc { color: var(--accent); }
.meter-bar.slim { display: block; width: 100%; height: 4px; margin-top: 4px; }
.dl-sum .dl-row { min-height: 48px; justify-content: space-between; }
.dl-sum .row-value { max-width: 64%; white-space: normal; text-align: right; font-variant-numeric: tabular-nums; }
.dl-sheet .est { display: flex; flex-direction: column; gap: 4px; }
.dl-looks { display: flex; align-items: center; gap: 8px; }
.dl-looks .row-hint { margin: 0 0 0 4px; }
.dl-swatch { flex: none; width: 22px; height: 22px; border-radius: 6px; box-shadow: inset 0 0 0 1px var(--line-strong); }
.dl-swatch.night { background: linear-gradient(135deg, #0b0d10 50%, #ff8a1f 50% 60%, #1c2026 60%); }
.dl-swatch.day { background: linear-gradient(135deg, #f7f5ef 50%, #e8590c 50% 60%, #e9e6dc 60%); margin-left: -4px; }
.dl-detail label { min-width: 0; padding: 0 6px; }
@media (prefers-reduced-motion: reduce) { .da-card { animation: none; } .da-k, .dl-bar i { transition: none; } }
