:root {
  --dock-h: 124px;
  --sb: 0px;
  /* --vv-b: the part of the page a browser's own bottom bar covers (app.js browserBarInset; 0 in an installed app). */
  --safe-b: max(env(safe-area-inset-bottom, 0px), var(--vv-b, 0px)); /* union: the covered strip already includes the home indicator */
  /* Native shell draws the page under the status bar and tells it how tall the bar is (--nat-t). */
  --safe-t: max(env(safe-area-inset-top, 0px), var(--nat-t, 0px));
}
html, body { margin: 0; height: 100%; background: #000; overflow: hidden; overscroll-behavior: none; }
body {
  font: 15px/1.4 ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  user-select: none; -webkit-user-select: none;
  touch-action: none;
}

/* Device frame: full-bleed on phones, framed on desktop.
 * Clip without a scroll container: nested focus/scrollIntoView must never scroll
 * the entire shell and lift its dock, leaving a blank band at the bottom. */
.device {
  position: relative; width: 100%; height: 100%; overflow: clip;
  background: radial-gradient(120% 70% at 50% 108%, #1a0b3d 0%, #0a0518 45%, var(--bg) 75%);
  isolation: isolate;
}
@media (min-width: 560px) and (min-height: 700px) {
  body { display: grid; place-items: center; background: radial-gradient(80% 80% at 50% 50%, #120a26, #000); }
  .device {
    width: 400px; height: min(866px, 96vh); border-radius: 46px;
    box-shadow: 0 0 0 11px #0d0b14, 0 0 0 12px #2a2540, 0 40px 120px rgba(120, 70, 255, .25);
  }
}

/* A Store input must scroll its app document, never the fixed shell's hidden outer stage. */
.device:has(.store-window) { overflow: clip; }

.stars { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -2; }
.nebula { position: absolute; inset: -20%; z-index: -1; pointer-events: none; transition: transform 900ms var(--ease); }
.nebula i { position: absolute; border-radius: 50%; filter: blur(60px); opacity: .5; mix-blend-mode: screen; animation: drift 26s ease-in-out infinite alternate; }
.nebula i:nth-child(1) { width: 70%; height: 40%; left: 5%; top: 10%; background: radial-gradient(closest-side, rgba(110, 60, 255, .55), transparent); }
.nebula i:nth-child(2) { width: 60%; height: 45%; right: -5%; top: 38%; background: radial-gradient(closest-side, rgba(255, 70, 200, .28), transparent); animation-duration: 31s; }
.nebula i:nth-child(3) { width: 90%; height: 40%; left: 0; bottom: -2%; background: radial-gradient(closest-side, rgba(60, 120, 255, .28), transparent); animation-duration: 37s; }
@keyframes drift { to { transform: translate3d(6%, -4%, 0) scale(1.12); } }
.lean { position: absolute; inset: 0; pointer-events: none; z-index: 30; opacity: 0; transition: opacity 300ms; }
.device[data-voice="command"] .lean { opacity: 1; background: radial-gradient(90% 55% at 50% 100%, rgba(63, 224, 255, .25), transparent 70%); }

/* Status bar */
.statusbar {
  display: none !important;
  position: absolute; top: 0; left: 0; right: 0; z-index: 60; height: calc(34px + var(--safe-t));
  padding: calc(10px + var(--safe-t)) 26px 0; display: flex; justify-content: space-between;
  font-size: 13px; font-weight: 650; letter-spacing: .02em; color: rgba(243, 239, 255, .9); pointer-events: none;
}
.sb-right { display: flex; gap: 6px; align-items: center; }
.sb-right svg { width: 16px; height: 12px; }
.batt { width: 24px; height: 11px; border: 1.5px solid currentColor; border-radius: 3.5px; padding: 1.5px; opacity: .9; }
.batt i { display: block; height: 100%; width: 72%; background: currentColor; border-radius: 1.5px; }
@media (min-width: 560px) and (min-height: 700px) { .statusbar { padding-top: 16px; display: flex !important; } :root { --sb: 34px; } }

/* Desks */
/* Desks move through track transforms, never ancestor scrolling. Browser focus inside
 * an embedded Store detail must not horizontally scroll this hidden viewport. */
.desks { position: absolute; inset: 0; z-index: 1; overflow: clip; }
.track { position: absolute; inset: 0; display: flex; will-change: transform; }
.track.anim { transition: transform 520ms var(--ease); }
.desk {
  position: relative; flex: 0 0 100%; height: 100%; overflow: hidden;
  padding: calc(var(--sb) + 18px + var(--safe-t)) 18px calc(var(--dock-h) + var(--safe-b));
  transition: opacity 400ms, filter 400ms;
}
.desk-scroll { height: 100%; overflow-y: auto; overflow-x: hidden; scrollbar-width: none; touch-action: pan-y; overscroll-behavior: contain; padding-bottom: 12px;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 14px, #000 calc(100% - 26px), transparent 100%);
          mask-image: linear-gradient(to bottom, transparent 0, #000 14px, #000 calc(100% - 26px), transparent 100%); }
.desk-scroll::-webkit-scrollbar { display: none; }
.sheet-open .desk { filter: blur(6px) brightness(.55); }
.desk.parked { content-visibility: hidden; } /* two+ swipes away: loaded, not rendered (see parkDesks) */

.desk-label {
  position: absolute; left: 50%; bottom: calc(var(--dock-h) + var(--safe-b) + 4px); z-index: 40;
  transform: translate(-50%, 8px); opacity: 0; pointer-events: none;
  padding: 6px 13px; border-radius: 99px; background: linear-gradient(rgba(12, 8, 28, .78), rgba(12, 8, 28, .78)), var(--wz-panel, var(--wz-base, var(--bg, #05030c))); border: 1px solid var(--line-2);
  font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2);
  transition: opacity 260ms, transform 260ms var(--ease); white-space: nowrap;

}
.desk-label.show { opacity: 1; transform: translate(-50%, 0); }
.desk-label b { color: var(--ink); font-weight: 800; }

/* ---------- Home desk ---------- */
.home { display: flex; flex-direction: column; height: 100%; min-height: 0; box-sizing: border-box; padding-bottom: 14px; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; }
/* Full-height Home (James, 12 Oct): time on top, attention in the middle band, resources anchored just above the dock.
 * Free height splits evenly between the two gaps so the screen fills without one blank band. */
.home-top, .home-attn { flex-shrink: 0; }
.home-gap { flex: 1 1 0; min-height: 16px; }
.home-attn { display: flex; flex-direction: column; gap: clamp(14px, 1.8dvh, 18px); }
.home-attn > .constellation { gap: inherit; }
.home-attn > * { margin-top: 0; margin-bottom: 0; }
.home .now-card { min-height: 68px; padding-top: 16px; padding-bottom: 16px; }
.home [data-home-resources] { margin-top: 0; flex-shrink: 0; }
.home-top { padding: 22px 6px 0; }
.home-date { font-size: 13px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); }
.home-time { font-size: 84px; line-height: .95; font-weight: 200; letter-spacing: -.045em; margin-top: 6px;
  background: linear-gradient(180deg, #fff 30%, #b8a6ff 100%); -webkit-background-clip: text; background-clip: text; color: transparent; font-variant-numeric: tabular-nums; }
.home-line { margin-top: 12px; font-size: 17px; color: var(--ink-2); max-width: 30ch; line-height: 1.38; }
.home-line b { color: var(--ink); font-weight: 650; }
.home-spacer { flex: 1; }
.constellation { display: flex; flex-direction: column; gap: 9px; }
.now-card {
  display: flex; align-items: center; gap: 13px; width: 100%; text-align: left;
  padding: 13px 14px; border-radius: 20px; background: var(--glass); border: 1px solid var(--line);
  -webkit-backdrop-filter: blur(18px) saturate(1.3); backdrop-filter: blur(18px) saturate(1.3);
  transition: transform 160ms, border-color 200ms;
}
.now-card:active { transform: scale(.985); border-color: var(--line-2); }
.now-card .pip { position: relative; flex: 0 0 10px; height: 10px; border-radius: 50%; background: var(--c); box-shadow: 0 0 12px var(--c); }
.now-card .pip.pulse::after { content: ""; position: absolute; inset: -5px; border-radius: 50%; border: 1.5px solid var(--c); animation: pip 1.6s ease-out infinite; }
.now-card .meta { flex: 1; min-width: 0; display: flex; flex-direction: column; text-align: left; }
.now-card .k, .now-card .v { display: block; }
.now-card .n { flex: 0 0 auto; padding-left: 8px; }
.now-card .k { font-size: 11px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--c); }
.now-card .v { font-size: 15px; font-weight: 560; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 1px; }
.now-card .n { font-size: 22px; font-weight: 300; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.side-card { margin-top: 9px; }
.side-card .side-go { flex: 0 0 auto; padding: 8px 15px; border-radius: 99px; background: linear-gradient(140deg, #8f63ff, #ff5ccf); color: #fff; font-size: 14px; font-weight: 700; box-shadow: 0 6px 18px rgba(143, 99, 255, .4); }
.side-card .side-x { flex: 0 0 auto; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; color: var(--ink-3); font-size: 13px; }
.hint-row { margin: 14px 2px 2px; display: flex; gap: 8px; flex-wrap: wrap; }
.say { padding: 7px 11px; border-radius: 99px; border: 1px dashed var(--line-2); font-size: 13px; color: var(--ink-2); }
.say::before { content: "“"; color: var(--violet-2); }
.say::after { content: "”"; color: var(--violet-2); }

/* ---------- Generic desk header ---------- */
.dhead { display: flex; align-items: center; gap: 10px; padding: 8px 4px 14px; }
.dhead .glyph { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; font-size: 17px; background: linear-gradient(140deg, var(--g1, #6b46ff), var(--g2, #ff5ccf)); box-shadow: 0 6px 20px rgba(120, 70, 255, .35); }
.dhead h2 { margin: 0; font-size: 19px; font-weight: 700; letter-spacing: -.01em; }
.dhead p { margin: 0; font-size: 12px; color: var(--ink-3); font-weight: 600; letter-spacing: .04em; }
.dhead .x { margin-left: auto; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; color: var(--ink-3); border: 1px solid var(--line); }
.dhead .x svg { width: 14px; height: 14px; stroke: currentColor; stroke-width: 2.2; fill: none; }

/* ---------- Empty desk ---------- */
.empty-desk { height: 100%; display: grid; place-items: center; text-align: center; padding: 0 30px; }
.empty-desk .ring { width: 150px; height: 150px; border-radius: 50%; margin: 0 auto 26px; border: 1px dashed rgba(205, 190, 255, .25); display: grid; place-items: center; position: relative; animation: spin 40s linear infinite; }
.empty-desk .ring::after { content: ""; position: absolute; top: -4px; left: 50%; width: 8px; height: 8px; margin-left: -4px; border-radius: 50%; background: var(--violet-2); box-shadow: 0 0 14px var(--violet); }
.empty-desk .num { font-size: 52px; font-weight: 200; color: var(--ink-3); animation: spin 40s linear infinite reverse; }
@keyframes spin { to { transform: rotate(360deg); } }
.empty-desk h3 { margin: 0 0 8px; font-size: 20px; font-weight: 650; }
.empty-desk p { margin: 0; color: var(--ink-3); font-size: 14.5px; line-height: 1.5; }
.empty-desk .say { display: inline-block; margin: 14px 3px 0; }

/* ---------- App card on a desk ---------- */
.appcard { border-radius: 26px; overflow: hidden; border: 1px solid var(--line-2); background: var(--glass); }
.appcard .hero { height: 210px; position: relative; display: grid; place-items: center; background: radial-gradient(120% 90% at 30% 10%, var(--g1), transparent 60%), radial-gradient(100% 90% at 90% 100%, var(--g2), transparent 60%), #0d0820; }
.appcard .hero .big { font-size: 64px; filter: drop-shadow(0 10px 24px rgba(0, 0, 0, .5)); }
.appcard .body { padding: 16px; }
.appcard h3 { margin: 0; font-size: 21px; }
.appcard p { margin: 6px 0 14px; color: var(--ink-2); font-size: 14px; }
.cta { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; height: 48px; border-radius: 15px; font-weight: 700; color: #fff; text-decoration: none; background: linear-gradient(90deg, #7a4dff, #c04dff 60%, #ff5ccf); box-shadow: 0 10px 30px rgba(140, 80, 255, .35); }
.cta.ghost { background: transparent; border: 1px solid var(--line-2); box-shadow: none; color: var(--ink-2); margin-top: 8px; }

/* Thread (Wizard app as an app within the OS) */
.thread .bubble { font-size: 14px; }
.typing { display: inline-flex; gap: 4px; padding: 14px 16px; }
.typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--violet-2); animation: typing 1.2s infinite ease-in-out; }
.typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }

/* ---------- Dock / orb ---------- */
.dock {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 50; height: calc(var(--dock-h) + var(--safe-b));
  padding-bottom: calc(28px + var(--safe-b));
  display: flex; align-items: center; justify-content: center; gap: 22px; pointer-events: none;
}
.dock::before { content: ""; position: absolute; inset: -40px 0 0; z-index: -1; pointer-events: none; background: linear-gradient(to top, rgba(5, 3, 12, .92) 20%, rgba(5, 3, 12, 0)); }
.desk-dots { display: flex; gap: 12px; width: 70px; align-items: center; pointer-events: auto; }
.desk-dots.left { justify-content: flex-end; }
.desk-dots.right { justify-content: flex-start; }
.ddot { position: relative; width: 8px; height: 8px; border-radius: 50%; border: 1.5px solid rgba(205, 190, 255, .45); transition: transform 300ms var(--spring), background 300ms, opacity 300ms; }
.ddot::before { content: ""; position: absolute; inset: -12px; }
.ddot.filled { background: rgba(205, 190, 255, .55); border-color: transparent; }
.ddot.live { background: var(--violet-2); box-shadow: 0 0 10px var(--violet); border-color: transparent; }
.ddot.live::after { content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 1px solid var(--violet-2); animation: pip 1.8s ease-out infinite; }
.ddot.pop { transform: scale(1.6); }

.orb-wrap { position: relative; width: 84px; height: 84px; flex: 0 0 84px; pointer-events: auto; touch-action: none; }
.orb { pointer-events: none; position: absolute; inset: -38%; width: 176%; height: 176%; cursor: pointer; outline: none; transition: transform 360ms var(--spring); }
.orb-fallback { position: absolute; inset: 4%; width: 92%; height: 92%; border-radius: 50%; pointer-events: none; }
.orb-wrap[data-mode="listen"] .orb-fallback, .orb-wrap[data-mode="command"] .orb-fallback, .orb-wrap[data-mode="think"] .orb-fallback { animation: spin 5s linear infinite; }
.orb-halo { position: absolute; inset: -30%; border-radius: 50%; pointer-events: none;
  background: conic-gradient(from 0deg, transparent, rgba(143, 99, 255, .5), transparent 30%, rgba(255, 92, 207, .4), transparent 60%, rgba(63, 224, 255, .35), transparent 85%);
  filter: blur(18px); opacity: calc(.22 + var(--energy, .2) * .55); animation: spin 9s linear infinite; }
.orb-wrap[data-mode="command"] .orb-halo { background: conic-gradient(from 0deg, transparent, rgba(63, 224, 255, .7), transparent 35%, rgba(255, 200, 80, .45), transparent 70%); animation-duration: 2.4s; }
.orb-ring { position: absolute; inset: -7px; border-radius: 50%; pointer-events: none; border: 1px solid rgba(205, 190, 255, .16); }
.orb-ring::before, .orb-ring::after { content: ""; position: absolute; inset: -9px; border-radius: 50%; border: 1px solid transparent; border-top-color: rgba(205, 190, 255, .35); animation: spin 7s linear infinite; }
.orb-ring::after { inset: -17px; border-top-color: transparent; border-bottom-color: rgba(255, 92, 207, .25); animation-duration: 13s; animation-direction: reverse; }
.orb-shock { position: absolute; inset: 0; border-radius: 50%; pointer-events: none; border: 2px solid rgba(205, 190, 255, .7); opacity: 0; }
.orb-shock.go { animation: shock 650ms var(--ease); }
@keyframes shock { from { opacity: .9; transform: scale(.9); } to { opacity: 0; transform: scale(2.3); } }
.orb-wrap.dragging .orb { transition: none; }
.moons { position: absolute; inset: -18px; pointer-events: none; animation: spin 24s linear infinite; }
/* Foreground resting motion: the sky moves only while core/scenery.js says Home is live (.scenery-live: Home in
 * front, nothing over it, page visible, touched in the last 45 s) and the skin is Nebula (other skins hide the sky).
 * Everywhere else the drift is paused where it is, so the frozen sky never jumps.
 * Desk slides, voice feedback and Working indicators retain their own motion. */
.device:not(.scenery-live) .nebula i, html:not([data-skin="nebula"]) .nebula i { animation-play-state: paused; }
@media (prefers-reduced-motion: reduce) { .device .nebula i { animation: none; } }
.device .orb-wrap:is([data-mode="idle"], [data-mode="type"], [data-mode="paused"]) .orb-halo,
.device .orb-wrap:is([data-mode="idle"], [data-mode="type"], [data-mode="paused"]) .orb-ring::before,
.device .orb-wrap:is([data-mode="idle"], [data-mode="type"], [data-mode="paused"]) .orb-ring::after,
.device .orb-wrap:is([data-mode="idle"], [data-mode="type"], [data-mode="paused"]) .moons { animation-play-state: paused; }
.device[data-voice="idle"] .timer::before { animation: none; }
.moons i { position: absolute; left: 50%; top: 50%; width: 6px; height: 6px; margin: -3px; border-radius: 50%; background: var(--c); box-shadow: 0 0 8px var(--c); }

.timer { position: absolute; left: 50%; bottom: -24px; transform: translateX(-50%) translateY(6px); opacity: 0; transition: opacity 220ms, transform 260ms var(--ease);
  min-width: 52px; padding: 3px 9px; border-radius: 99px; text-align: center; font-size: 12px; font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: .04em;
  white-space: nowrap; width: max-content; /* one line: the orb is narrower than dot + time, so it used to wrap */
  background: linear-gradient(rgba(12, 6, 30, .9), rgba(12, 6, 30, .9)), var(--wz-panel, var(--wz-base, var(--bg, #05030c))); border: 1px solid rgba(205, 190, 255, .35); color: #fff; pointer-events: none; }
.timer::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--red); margin-right: 6px; vertical-align: 1px; box-shadow: 0 0 8px var(--red); animation: blink 1s steps(2) infinite; }
@keyframes blink { 50% { opacity: .2; } }
.device[data-voice="listen"] .timer, .device[data-voice="command"] .timer, .device[data-voice="paused"] .timer { opacity: 1; transform: translateX(-50%); }
.device[data-voice="paused"] .timer::before { animation: none; background: var(--amber); box-shadow: 0 0 8px var(--amber); }
.device[data-voice="command"] .timer::before { background: var(--cyan); box-shadow: 0 0 8px var(--cyan); }
.hold-hint { position: absolute; left: 50%; top: -30px; transform: translateX(-50%) scale(.8); opacity: 0; transition: opacity 200ms, transform 300ms var(--spring); font-size: 11px; font-weight: 850; letter-spacing: .16em; text-transform: uppercase; color: var(--cyan); text-shadow: 0 0 12px rgba(63, 224, 255, .8); pointer-events: none; white-space: nowrap; }
.device[data-voice="command"] .hold-hint { opacity: 1; transform: translateX(-50%) scale(1); }

/* direction nudge while dragging the orb */
.orb-wrap::after { content: attr(data-dir); position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); white-space: nowrap; pointer-events: none;
  font-size: 11px; font-weight: 850; letter-spacing: .14em; text-transform: uppercase; color: #fff; opacity: 0; transition: opacity 150ms; text-shadow: 0 1px 8px rgba(0,0,0,.9); }
.orb-wrap[data-dir]:not([data-dir=""])::after { opacity: 1; }

/* ---------- Voice arc ---------- */
.voice { position: absolute; inset: 0; z-index: 55; pointer-events: none; }
.arc {
  position: absolute; left: 50%; bottom: calc(14px + var(--safe-b) + 52px); width: 54px; height: 54px; margin: 0 0 -27px -27px;
  border-radius: 50%; display: grid; place-items: center; pointer-events: none; opacity: 0;
  transform: translate(0, 0) scale(.3);
  transition: transform 460ms var(--spring), opacity 220ms;
  background: rgba(18, 10, 42, .72); border: 1px solid rgba(205, 190, 255, .3);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(255, 255, 255, .08);
}
.arc svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.arc small { position: absolute; top: 100%; margin-top: 6px; font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); white-space: nowrap; }
.arc b { font-size: 15px; font-weight: 850; }
.arc:active { background: rgba(60, 40, 120, .8); }
.arc-left { color: #ffb0bf; }
.arc-mid .i-play { display: none; }
.device[data-voice="paused"] .arc-mid .i-play { display: block; }
.device[data-voice="paused"] .arc-mid .i-pause { display: none; }
:where(.device[data-voice="paused"]) .arc-mid { background: color-mix(in srgb, var(--amber) 18%, transparent); border-color: color-mix(in srgb, var(--amber) 50%, transparent); color: var(--amber); }
.voice.on .arc { pointer-events: auto; opacity: 1; }
.voice.on .arc-left  { transform: translate(-86px, -66px) scale(1); transition-delay: 30ms; }
.voice.on .arc-mid   { transform: translate(0, -106px) scale(1); }
.voice.on .arc-right { transform: translate(86px, -66px) scale(1); transition-delay: 60ms; }
.arc-right { color: #fff; }
/* Attach: count badge once a file rides along; a soft pulse while it uploads. */
.arc-count { position: absolute; top: -4px; right: -4px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 99px; display: none; place-items: center;
  font: 800 10.5px/1 system-ui; font-style: normal; background: var(--violet-2); color: #140b2c; }
.arc-right.has .arc-count { display: grid; }
.arc-right.has { border-color: rgba(205, 190, 255, .6); background: rgba(80, 52, 170, .55); }
.arc-right.busy svg { animation: blink 1s ease-in-out infinite; }
.voice.cmd .arc-mid, .voice.cmd .arc-right { opacity: 0; pointer-events: none; transform: translate(0, -60px) scale(.3); }
.voice.cmd .arc-left { opacity: 0; pointer-events: none; }

.transcript {
  position: absolute; left: 16px; right: 16px; bottom: calc(var(--safe-b) + 248px); z-index: 2;
  padding: 14px 16px; border-radius: 22px; opacity: 0; transform: translateY(14px) scale(.98);
  transition: opacity 260ms, transform 360ms var(--ease);
  background: linear-gradient(rgba(14, 8, 34, .78), rgba(14, 8, 34, .78)), var(--wz-panel, var(--wz-base, var(--bg, #05030c))); border: 1px solid rgba(205, 190, 255, .22);

  box-shadow: 0 20px 60px rgba(0, 0, 0, .5);
}
/* A long take never grows the card off screen: the header (with ×) and chips stay visible, the words scroll. */
.transcript:not(.brief) { display: flex; flex-direction: column; max-height: min(44dvh, calc(100dvh - var(--safe-t) - var(--safe-b) - 300px)); }
.transcript:not(.brief) #txText { flex: 0 1 auto; min-height: 25px; overflow-y: auto; overscroll-behavior: contain; }
.transcript:not(.brief) .tx-route, .transcript:not(.brief) .tx-chips { flex: none; }
.voice.tx .transcript { opacity: 1; transform: none; pointer-events: none; }
.voice.tx .transcript:has(.tx-chips:not(:empty)) { pointer-events: auto; }
.voice.cmd .transcript { bottom: calc(var(--safe-b) + 172px); }
.tx-route { display: flex; align-items: center; gap: 8px; font-size: 11px; font-weight: 850; letter-spacing: .12em; text-transform: uppercase; color: var(--violet-2); }
.tx-route b { width: 20px; height: 20px; border-radius: 7px; display: grid; place-items: center; background: rgba(143, 99, 255, .2); font-size: 11px; }
.transcript.command .tx-route { color: var(--cyan); }
.transcript.command .tx-route b { background: rgba(63, 224, 255, .15); }
.transcript.agent .tx-route { color: var(--pink); }
.tx-route .ms { margin-left: auto; color: var(--ink-3); font-weight: 750; }
#txText { margin: 8px 0 0; font-size: 19px; line-height: 1.32; font-weight: 520; min-height: 25px; user-select: text; }
#txText:empty::before { content: ""; display: block; height: 22px; width: 100%;
  background: repeating-linear-gradient(90deg, rgba(205, 190, 255, .5) 0 3px, transparent 3px 7px);
  -webkit-mask: linear-gradient(90deg, transparent, #000 15%, #000 85%, transparent); mask: linear-gradient(90deg, transparent, #000 15%, #000 85%, transparent);
  transform: scaleY(calc(.15 + var(--lvl, 0) * 1.6)); transition: transform 80ms; }
/* × on any choice card (chips showing): one tap closes it, nothing sent. Hidden on plain transcripts and pills. */
.tx-x { display: none; margin-left: auto; flex: none; width: 32px; height: 32px; margin-top: -6px; margin-right: -8px; border-radius: 50%; place-items: center; background: rgba(205, 190, 255, .1); border: 1px solid var(--line-2); color: var(--ink); }
.tx-x svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; }
.tx-x:active { background: rgba(205, 190, 255, .25); }
.transcript:has(.tx-chips:not(:empty)) .tx-x { display: grid; }
.transcript.brief .tx-x { display: none !important; }
.tx-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.tx-chips:empty { display: none; }
.tx-chips button { padding: 6px 10px; border-radius: 99px; font-size: 13px; background: rgba(205, 190, 255, .08); border: 1px solid var(--line-2); color: var(--ink); }
.tx-chips button:active { background: rgba(205, 190, 255, .2); }
.tx-chips .lbl { width: 100%; font-size: 11px; color: var(--ink-3); font-weight: 750; letter-spacing: .06em; text-transform: uppercase; }

/* ---------- Sheets ---------- */
.scrim { position: absolute; inset: 0; z-index: 44; background: rgba(3, 1, 10, .45); opacity: 0; pointer-events: none; transition: opacity 360ms; }
.sheet-open .scrim { opacity: 1; pointer-events: auto; }
.sheet {
  position: absolute; left: 8px; right: 8px; z-index: 46; display: flex; flex-direction: column;
  border-radius: 30px; overflow: hidden;
  background: linear-gradient(180deg, rgba(26, 16, 56, .86), rgba(12, 7, 28, .92)), var(--wz-panel, var(--wz-base, var(--bg, #05030c)));
  border: 1px solid rgba(205, 190, 255, .18);

  box-shadow: 0 30px 80px rgba(0, 0, 0, .6);
  transition: transform 520ms var(--ease), opacity 300ms; will-change: transform;
}
.sheet.dragging { transition: none; }
.sheet-grip { flex: 0 0 auto; width: 40px; height: 4px; border-radius: 99px; background: rgba(205, 190, 255, .3); margin: 9px auto; }
/* Settings' grip is a drag handle: a larger invisible hit area, same 4px bar and spacing. */
#settings > .sheet-grip { box-sizing: content-box; padding: 10px 48px; margin: -1px auto; background-clip: content-box; touch-action: none; cursor: grab; }
/* Apps' grip too (issue 1734); the hit area is a pseudo-element so the bar keeps its exact look. */
#launcher > .sheet-grip { position: relative; touch-action: none; cursor: grab; }
#launcher > .sheet-grip::before { content: ''; position: absolute; inset: -10px -48px; }
.launcher { top: calc(44px + var(--safe-t)); bottom: calc(var(--dock-h) + var(--safe-b) - 12px); transform: translateY(calc(100% + 160px)); opacity: 0; }
.launcher.open { transform: none; opacity: 1; }
.inbox { top: calc(40px + var(--safe-t)); bottom: calc(var(--dock-h) + var(--safe-b) - 12px); transform: translateY(calc(-100% - 60px)); opacity: 0; }
.inbox.open { transform: none; opacity: 1; }
.launcher-body, .inbox-body { flex: 1; min-height: 0; overflow-y: auto; padding: 4px 14px 10px; scrollbar-width: none; touch-action: pan-y; overscroll-behavior: contain; }
.launcher-body::-webkit-scrollbar, .inbox-body::-webkit-scrollbar { display: none; }
.inbox-body { display: flex; flex-direction: column; }
.inbox-body .push { flex: 1; }

.search { flex: 0 0 auto; margin: 6px 12px 12px; height: 50px; border-radius: 17px; display: flex; align-items: center; gap: 10px; padding: 0 15px; background: rgba(205, 190, 255, .08); border: 1px solid var(--line-2); }
.search svg { width: 18px; height: 18px; fill: none; stroke: var(--ink-3); stroke-width: 2.2; stroke-linecap: round; flex: 0 0 auto; }
.search input { flex: 1; min-width: 0; height: 100%; background: none; border: 0; outline: none; font-size: 16px; user-select: text; -webkit-user-select: text; }
.search input::placeholder { color: var(--ink-3); }
.search input::-webkit-search-cancel-button { display: none; }
/* Apps footer: Search plus a visible close button at its right, in thumb reach (wizard-ux issue 1735). */
.launcher-foot { flex: 0 0 auto; display: flex; align-items: center; gap: 8px; margin: 6px 12px 12px; }
.launcher-foot .search { flex: 1 1 auto; min-width: 0; margin: 0; }
.launcher-close { flex: 0 0 auto; display: grid; place-items: center; width: 50px; height: 50px; padding: 0; border-radius: 50%; background: color-mix(in srgb, var(--ink) 7%, transparent); border: 1px solid var(--line-2); color: var(--ink-2); cursor: pointer; }
.launcher-close svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }
.launcher-close:active { background: color-mix(in srgb, var(--ink) 14%, transparent); }

.lgroup { margin: 10px 0 4px; }
.lgroup h4 { margin: 0 4px 8px; font-size: 11px; font-weight: 850; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-2); display: flex; justify-content: space-between; align-items: center; }
.lgroup h4 span { font-weight: 700; letter-spacing: .04em; text-transform: none; font-size: 11px; }
.lgrid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px 6px; }
.lapp { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 4px 0; text-align: center; }
.lapp .ic { position: relative; width: 56px; height: 56px; border-radius: 18px; display: grid; place-items: center; font-size: 25px; background: linear-gradient(145deg, var(--g1), var(--g2)); box-shadow: 0 8px 20px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .22); transition: transform 160ms var(--spring); }
.lapp:active .ic { transform: scale(.9); }
/* App kinds (Miguel's design, every skin's New desk since 23 Oct 2026): system apps wear one accent ring and tint, and
 * Wizard apps, Agents and Connectors fold into one quiet "For agents" row under Apps. Skins may restyle both. */
:is(.launcher, .new-desk) .lapp.lapp-sys .ic { border: 2.5px solid var(--violet-2, #8f63ff); background: linear-gradient(160deg, color-mix(in srgb, var(--violet-2, #8f63ff) 34%, transparent), color-mix(in srgb, var(--violet-2, #8f63ff) 14%, transparent)), var(--bg-2, #0f0c17); box-shadow: 0 4px 14px color-mix(in srgb, var(--violet-2, #8f63ff) 28%, transparent); outline: none; }
:is(.launcher, .new-desk) .forag { margin: 14px 0 4px; }
:is(.launcher, .new-desk) .forag + .forag { margin-top: 8px; }
:is(.launcher, .new-desk) .forag .kg-dev h4 { display: none; }
:is(.launcher, .new-desk) .fa-row { width: 100%; display: flex; align-items: center; gap: 8px; padding: 12px 14px; border-radius: 16px; background: color-mix(in srgb, var(--ink) 6%, transparent); border: 1px solid var(--line-2); color: var(--ink-2); font: inherit; font-size: 13.5px; font-weight: 600; text-align: left; }
:is(.launcher, .new-desk) .fa-row small { color: var(--ink-3); font-size: 12.5px; font-weight: 500; }
:is(.launcher, .new-desk) .fa-row svg { margin-left: auto; width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; transition: transform 200ms; }
:is(.launcher, .new-desk) .forag.open .fa-row svg { transform: rotate(180deg); }
:is(.launcher, .new-desk) .forag:not(.open) .fa-body { display: none; }
:is(.launcher, .new-desk) .forag .fa-body { padding-top: 6px; }
.lapp .ic .badge { position: absolute; right: -4px; bottom: -4px; padding: 1px 5px; border-radius: 6px; font-size: 8.5px; font-weight: 900; letter-spacing: .05em; background: #0d0a18; border: 1px solid var(--line-2); color: var(--ink-2); }
.lapp .nm { font-size: 11.5px; line-height: 1.2; color: var(--ink-2); max-width: 76px; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow-wrap: break-word; hyphens: auto; -webkit-hyphens: auto; }
.lrow { display: flex; align-items: center; gap: 12px; width: 100%; padding: 9px 6px; border-radius: 14px; text-align: left; }
.lrow:active, .lrow.sel { background: rgba(205, 190, 255, .1); }
.lrow .ic { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; font-size: 18px; background: linear-gradient(145deg, var(--g1), var(--g2)); flex: 0 0 auto; }
.lrow .nm { flex: 1; min-width: 0; font-size: 15px; font-weight: 600; }
.lrow .nm small { display: block; font-size: 12px; font-weight: 500; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lrow .kind { font-size: 10px; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); padding: 3px 7px; border-radius: 7px; border: 1px solid var(--line); }
.lrow .kind.cmd { color: var(--cyan); border-color: rgba(63, 224, 255, .35); }
.lrow .kind.view { color: var(--violet-2); }
.lrow .kind.native { color: var(--amber); border-color: rgba(255, 190, 85, .3); }
.noresult { padding: 30px 10px; text-align: center; color: var(--ink-3); }

.ibx-h { display: flex; align-items: center; justify-content: space-between; margin: 12px 4px 6px; }
.ibx-h h4 { margin: 0; font-size: 11px; font-weight: 850; letter-spacing: .14em; text-transform: uppercase; color: var(--c, var(--ink-3)); display: flex; align-items: center; gap: 8px; }
.ibx-h h4 i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); box-shadow: 0 0 8px var(--c); }
.ibx-h span { font-size: 12px; color: var(--ink-3); font-weight: 700; }
.note { position: relative; display: flex; gap: 12px; align-items: flex-start; width: 100%; text-align: left; padding: 12px; border-radius: 18px; margin-bottom: 7px; background: rgba(205, 190, 255, .05); border: 1px solid var(--line); transition: transform 260ms var(--ease), opacity 260ms, background 200ms; touch-action: pan-y; }
.note:active { background: rgba(205, 190, 255, .1); }
.note .ic { flex: 0 0 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; font-size: 16px; background: linear-gradient(145deg, var(--g1, #4a2fa0), var(--g2, #8f3fae)); }
.note .bd { flex: 1; min-width: 0; }
.note .tp { display: flex; gap: 8px; font-size: 11px; font-weight: 750; color: var(--ink-3); letter-spacing: .04em; }
.note .tp .src { text-transform: uppercase; letter-spacing: .1em; }
.note .tp .tm { margin-left: auto; font-variant-numeric: tabular-nums; }
.note .ti { margin-top: 2px; font-size: 15px; font-weight: 620; line-height: 1.3; }
.note .sb { margin-top: 2px; font-size: 13px; color: var(--ink-2); line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.note.working .ic::after { content: ""; position: absolute; left: 34px; top: 34px; width: 8px; height: 8px; border-radius: 50%; background: var(--violet-2); box-shadow: 0 0 8px var(--violet); animation: blink 1s steps(2) infinite; }
.note.gone { transform: translateX(110%); opacity: 0; }
.note.fresh { animation: fresh 600ms var(--spring); }
@keyframes fresh { from { transform: scale(.9); opacity: 0; } }

/* Toast */
.toast { position: absolute; left: 50%; top: calc(46px + var(--safe-t)); z-index: 70; transform: translate(-50%, -16px); opacity: 0; pointer-events: none;
  max-width: calc(100% - 32px); padding: 10px 15px; border-radius: 16px; display: flex; gap: 9px; align-items: center;
  background: linear-gradient(rgba(14, 8, 34, .9), rgba(14, 8, 34, .9)), var(--wz-panel, var(--wz-base, var(--bg, #05030c))); border: 1px solid var(--line-2); font-size: 13.5px; font-weight: 600; box-shadow: 0 14px 40px rgba(0, 0, 0, .5);
    transition: opacity 260ms, transform 360ms var(--spring); }
.toast.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.toast .ti { font-size: 15px; }
.toast button { margin-left: 4px; font-weight: 800; color: var(--violet-2); }
/* A toast with Undo (WosBell.movedToast) keeps its line: absolute at left:50% would otherwise wrap it at half width. */
.toast:has(.wos-undo) { width: max-content; }

/* Coach */
.coach { position: absolute; inset: 0; z-index: 90; display: grid; place-items: end center; background: radial-gradient(80% 60% at 50% 85%, rgba(20, 10, 50, .7), rgba(2, 1, 8, .92)); padding-bottom: calc(var(--safe-b) + 6px); animation: fade 500ms both; }
@keyframes fade { from { opacity: 0; } }
.coach[hidden] { display: none; }
.coach-card { position: relative; width: 100%; height: 520px; text-align: center; }
.coach-orb { position: absolute; left: 50%; bottom: 40px; width: 84px; height: 84px; margin-left: -42px; border-radius: 50%; border: 2px dashed rgba(205, 190, 255, .5); animation: spin 18s linear infinite; }
.coach .c { position: absolute; font-size: 22px; color: var(--violet-2); display: flex; align-items: center; gap: 8px; }
.coach .c b { font-size: 13px; color: var(--ink); letter-spacing: .02em; }
.coach .c-up { left: 50%; bottom: 184px; transform: translateX(-50%); flex-direction: column; gap: 2px; }
.coach .c-down { left: 50%; bottom: 0; transform: translateX(-50%) translateY(6px); flex-direction: column-reverse; gap: 0; opacity: .95; }
.coach .c-left { left: 18px; bottom: 96px; }
.coach .c-right { right: 18px; bottom: 96px; }
.coach p { position: absolute; left: 24px; right: 24px; bottom: 262px; margin: 0; font-size: 17px; line-height: 1.6; color: var(--ink-2); }
.coach p b { color: var(--ink); }
.coach-go { position: absolute; left: 50%; bottom: 410px; transform: translateX(-50%); padding: 12px 28px; border-radius: 99px; font-weight: 800; letter-spacing: .06em; background: linear-gradient(90deg, #7a4dff, #ff5ccf); box-shadow: 0 10px 30px rgba(140, 80, 255, .4); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Voice never fades or covers the screen: James taps the orb, then keeps scrolling and tapping
   while it records and sends. The desk stays at full strength; only the hint row steps aside. */
.desk > * { transition: opacity 260ms var(--ease), filter 260ms var(--ease); }
[data-voice="listen"] .hint-row, [data-voice="paused"] .hint-row, [data-voice="command"] .hint-row, [data-voice="think"] .hint-row { opacity: 0; }

/* unread badge on the orb */
.orb-badge { position: absolute; top: 2px; right: 0; z-index: 3; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 99px; display: grid; place-items: center;
  font-size: 11px; font-weight: 850; color: #160b05; background: var(--amber); box-shadow: 0 0 0 2px rgba(5, 3, 12, .9), 0 0 14px rgba(255, 190, 85, .6); pointer-events: none; }
.orb-badge[hidden] { display: none; }

/* live inbox bits */
.note .ic.emo, .lrow .ic.emo { background: rgba(205, 190, 255, .08); font-size: 18px; }
.ibx-empty { margin: 10px 4px 14px; padding: 16px; border-radius: 18px; text-align: center; color: var(--ink-2); background: rgba(205, 190, 255, .05); border: 1px solid var(--line); }
.ibx-all { color: var(--green); font-weight: 800; font-size: 12px; }
.note .sb { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }


/* ---------- desks hold tiled windows (Omarchy-style) ----------
   Small gaps, rounded corners, the wallpaper bleeding through between tiles. */
.desk { --gap: 8px; }
.desk .glance { position: absolute; inset: 0; padding: inherit; transition: opacity 280ms var(--ease), transform 380ms var(--ease); }
.desk.has-wins .glance { opacity: 0; pointer-events: none; transform: scale(.97); }
.tiles { position: absolute; z-index: 2; left: 10px; right: 10px; top: calc(var(--sb) + var(--safe-t) + 10px); bottom: calc(var(--dock-h) + var(--safe-b) - 14px);
  display: grid; gap: var(--gap); pointer-events: none; transition: inset 380ms var(--ease); }
.tiles[data-n="0"] { display: none; }
.tiles[data-n="1"] { grid-template: "a" 1fr / 1fr; }
.tiles[data-n="2"] { grid-template: "a" 1fr "b" 1fr / 1fr; }
.tiles[data-n="3"] { grid-template: "a a" 1.25fr "b c" 1fr / 1fr 1fr; }
.tiles[data-n="4"] { grid-template: "a b" 1fr "c d" 1fr / 1fr 1fr; }
.win { position: relative; min-width: 0; min-height: 0; display: flex; flex-direction: column; pointer-events: auto; overflow: hidden;
  border-radius: 18px; background: rgba(12, 8, 26, .82); border: 1px solid var(--line-2);
  box-shadow: 0 14px 40px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(255, 255, 255, .04);
  -webkit-backdrop-filter: blur(16px) saturate(1.2); backdrop-filter: blur(16px) saturate(1.2);
  transition: border-color 220ms, box-shadow 220ms, opacity 280ms, transform 380ms var(--ease); }
.win.focus { border-color: rgba(185, 155, 255, .7); box-shadow: 0 0 0 1px rgba(143, 99, 255, .35), 0 0 26px rgba(143, 99, 255, .28), 0 14px 40px rgba(0, 0, 0, .45); }
.win.enter { animation: winIn 380ms var(--spring); }
@keyframes winIn { from { opacity: 0; transform: scale(.9) translateY(14px); } }
.win.leaving { opacity: 0; transform: scale(.92); pointer-events: none; }
/* full screen: the focused window takes the whole desk, the rest step back */
.tiles.has-full { left: 0; right: 0; top: calc(var(--sb) + var(--safe-t)); bottom: calc(var(--dock-h) + var(--safe-b) - 22px); grid-template: "a" 1fr / 1fr !important; }
.tiles.has-full .win:not(.full) { display: none; }
.tiles.has-full .win.full { grid-area: a !important; border-radius: 0 0 22px 22px; border-color: transparent; box-shadow: none; }
.win .i-shrink { display: none; } .win.full .i-shrink { display: inline; } .win.full .i-grow { display: none; }

.wbar { flex: 0 0 auto; display: flex; align-items: center; gap: 8px; height: 34px; padding: 0 4px 0 10px; border-bottom: 1px solid var(--line); touch-action: manipulation; user-select: none; -webkit-user-select: none; }
.wic { flex: 0 0 auto; width: 20px; height: 20px; border-radius: 6px; display: grid; place-items: center; font-size: 11px; background: linear-gradient(140deg, var(--g1), var(--g2)); }
.wt { flex: 1; min-width: 0; font-size: 12.5px; font-weight: 700; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.win.focus .wt, .win.solo .wt { color: var(--ink); }
.wb { flex: 0 0 auto; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 9px; color: var(--ink-3); }
.wb svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.wb[data-wact="menu"] svg { fill: currentColor; stroke: none; }
.wb:active { background: rgba(205, 190, 255, .1); color: var(--ink); }
.wbody { position: relative; flex: 1; min-height: 0; overflow: hidden; }
.wbody > .desk-scroll { padding: 12px 12px 14px; }
.win .frame-wrap { position: absolute; inset: 0; border-radius: 0; }
.appframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #0f1014; color-scheme: dark; }
.frame-wrap { background: #0f1014; }
.frame-fallback { position: absolute; inset: 0; display: none; place-content: center; justify-items: center; gap: 10px; text-align: center; padding: 0 24px; background: var(--bg); }
.frame-wrap.blocked .frame-fallback { display: grid; }
.frame-wrap.blocked .appframe { visibility: hidden; }
.frame-fallback .glyph { width: 56px; height: 56px; border-radius: 18px; display: grid; place-items: center; font-size: 26px; background: linear-gradient(140deg, var(--g1, #6b46ff), var(--g2, #ff5ccf)); }
.frame-fallback h3 { margin: 6px 0 0; font-size: 17px; }
.frame-fallback p { margin: 0 0 6px; color: var(--ink-2); font-size: 14px; }
/* unfocused tiles: one tap focuses, so framed apps don't swallow it */
.shield { position: absolute; inset: 34px 0 0; z-index: 3; display: none; }
.tiles:not([data-n="1"]):not(.has-full) .win:not(.focus) .shield { display: block; }
/* compact tiles get compact content */
.tiles[data-n="3"] .win:not(:first-child) .wbody, .tiles[data-n="4"] .wbody { font-size: 13px; }
.tiles[data-n="4"] .wbar .wb[data-wact="full"], .tiles[data-n="3"] .win:not(:first-child) .wb[data-wact="full"] { display: none; }
.tiles[data-n="4"] .wbar { padding-left: 8px; gap: 5px; }
.tiles[data-n="4"] .ch-top, .tiles[data-n="3"] .win:not(:first-child) .ch-top { display: none; }
.tiles[data-n="4"] .ch-row .pv, .tiles[data-n="3"] .win:not(:first-child) .ch-row .pv { -webkit-line-clamp: 1; }

/* voice: windows stay live and undimmed (see "Voice never fades" above) */
.tiles { transition: opacity 260ms var(--ease), filter 260ms var(--ease), inset 380ms var(--ease); }
/* hold + slide: the neighbour desk this command will open on lights up */
.device.aiming .orb-wrap::after { opacity: 1; color: var(--cyan); }

/* window menu */
.wmenu { position: absolute; z-index: 66; min-width: 210px; padding: 8px; border-radius: 18px; background: linear-gradient(rgba(20, 13, 44, .96), rgba(20, 13, 44, .96)), var(--wz-panel, var(--wz-base, var(--bg, #05030c))); border: 1px solid var(--line-2);
  box-shadow: 0 20px 50px rgba(0, 0, 0, .55);
  opacity: 0; transform: translateY(-6px) scale(.96); transform-origin: top right; pointer-events: none; transition: opacity 160ms, transform 220ms var(--spring); }
.wmenu.open { opacity: 1; transform: none; pointer-events: auto; }
.wm-title { padding: 6px 8px 8px; font-size: 11.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 240px; }
.wmenu button { display: block; width: 100%; text-align: left; padding: 11px 12px; border-radius: 12px; font-size: 15px; font-weight: 650; color: var(--ink); }
.wmenu button:active { background: rgba(205, 190, 255, .1); }
.wmenu button:disabled { opacity: .3; }
.wmenu button[data-mact="close"] { color: #ffb0bf; }
.wm-row { display: flex; gap: 4px; }
.wm-row button { flex: 1; text-align: center; padding: 11px 6px; background: rgba(205, 190, 255, .05); }

.tiles[data-n="4"] .ch-compose, .tiles[data-n="3"] .win:not(:first-child) .ch-compose { display: none; }
.tiles[data-n="4"] .win.focus .ch-compose { display: flex; }

/* narrow tiles (3- and 4-up stacks): compact app headers */
.tiles[data-n="3"] .win:not(:first-child) .wbar .wb[data-wact="menu"] { width: 26px; }
/* desk label sits above the orb, clear of the tiles */
.desk-label { bottom: calc(var(--dock-h) + var(--safe-b) - 6px); }

/* ---------- coming-soon frame (app published from another thread) ---------- */
.frame-coming { display: none; position: absolute; inset: 0; z-index: 2; place-content: center; text-align: center; padding: 0 26px; background: radial-gradient(120% 80% at 50% 30%, rgba(63, 224, 255, .08), transparent 60%), #0c0a18; }
.frame-wrap.coming .frame-coming { display: grid; justify-items: center; }
/* Opening feedback: a tapped app tile answers at once, and a window shows its app with a spinner until the
   app's page has loaded, so a slow app never looks like a missed tap (James, 26 Oct 2026). */
.wos-spin { display: inline-block; width: 14px; height: 14px; border-radius: 50%; border: 2px solid color-mix(in oklab, currentColor 25%, transparent); border-top-color: var(--violet-2, #b69cff); animation: spin .8s linear infinite; vertical-align: -2px; }
.frame-loading { display: none; position: absolute; inset: 0; z-index: 1; place-content: center; justify-items: center; gap: 18px; background: inherit; pointer-events: none; }
.frame-wrap.loading .frame-loading { display: grid; }
.frame-wrap.loading.coming .frame-loading, .frame-wrap.loading.blocked .frame-loading { display: none; }
.frame-loading .glyph { width: 64px; height: 64px; border-radius: 20px; display: grid; place-items: center; font-size: 30px; background: linear-gradient(135deg, var(--g1), var(--g2)); box-shadow: 0 10px 30px rgba(0, 0, 0, .3); }
.frame-loading .wos-spin { width: 22px; height: 22px; color: var(--ink-3, #8d8aa3); }
/* The tapped icon itself answers: it sinks, its picture dims under a dark veil, a spinner turns in its centre, and it
   stops looking (and acting) tappable until the app is up. */
:is(.lapp, .lrow).opening { pointer-events: none; }
:is(.lapp, .lrow).opening .ic { transform: scale(.84) !important; filter: saturate(.6); transition: transform 120ms var(--spring, ease), filter 120ms; }
:is(.lapp, .lrow).opening .ic > :not(.open-spin) { opacity: .3; }
.open-spin { position: absolute; inset: 0; margin: auto; width: 46%; height: 46%; border-radius: 50%; border: 3px solid rgba(255, 255, 255, .28); border-top-color: #fff; animation: spin .7s linear infinite; pointer-events: none; z-index: 2; }
.lapp.opening .ic::before { content: ""; position: absolute; inset: 0; border-radius: inherit; background: rgba(0, 0, 0, .45); z-index: 1; }
.lapp.opening .nm { opacity: .5; }
@media (prefers-reduced-motion: reduce) { .wos-spin, .open-spin { animation: spin 1.6s linear infinite !important; animation-iteration-count: infinite !important; animation-duration: 1.6s !important; } }
.frame-wrap.coming .appframe { visibility: hidden; }
.frame-coming .glyph { width: 64px; height: 64px; border-radius: 20px; display: grid; place-items: center; font-size: 30px; background: linear-gradient(135deg, var(--g1), var(--g2)); box-shadow: 0 10px 30px rgba(63, 224, 255, .2); margin-bottom: 16px; }
.frame-coming h3 { margin: 0 0 6px; font-size: 18px; font-weight: 700; }
.frame-coming p { margin: 0; max-width: 30ch; color: var(--ink-3); font-size: 14px; line-height: 1.45; }

/* ---------- desk peek: long-press a dot → every desk as a card stack ---------- */
.peek { position: absolute; inset: 0; z-index: 70; display: flex; flex-direction: column; justify-content: center; background: linear-gradient(rgba(5, 3, 12, .72), rgba(5, 3, 12, .72)), var(--wz-panel, var(--wz-base, var(--bg, #05030c)));   opacity: 0; pointer-events: none; transition: opacity 220ms var(--ease); }
.peek.open { opacity: 1; pointer-events: auto; }
.pk-stack { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 30px calc(50% - 105px); scrollbar-width: none; perspective: 900px; }
.pk-stack::-webkit-scrollbar { display: none; }
.pk-card { flex: 0 0 210px; height: 360px; scroll-snap-align: center; display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: 26px; text-align: left; color: var(--ink);
  background: linear-gradient(180deg, rgba(40, 28, 80, .75), rgba(14, 10, 30, .85)), var(--wz-panel, var(--wz-base, var(--bg, #05030c))); border: 1px solid var(--line-2); box-shadow: 0 24px 60px rgba(0, 0, 0, .5);
  transform: translateY(40px) rotateY(calc(var(--k) * -6deg)) scale(.92); transition: transform 360ms var(--spring); }
.peek.open .pk-card { transform: translateY(0) rotateY(calc(var(--k) * -6deg)) scale(1); }
.pk-card.here { border-color: var(--violet-2); box-shadow: 0 0 0 1px var(--violet-2), 0 24px 60px rgba(143, 99, 255, .35); }
.pk-card > b { font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }
.pk-body { flex: 1; display: grid; gap: 6px; min-height: 0; }
.pk-n0, .pk-n1 { grid-template-rows: 1fr; } .pk-n2 { grid-template-rows: 1fr 1fr; } .pk-n3, .pk-n4 { grid-template: 1fr 1fr / 1fr 1fr; }
.pk-win { display: flex; flex-direction: column; justify-content: flex-end; gap: 6px; padding: 10px; border-radius: 16px; background: rgba(205, 190, 255, .07); border: 1px solid var(--line); font-size: 13px; font-weight: 650; overflow: hidden; }
.pk-win i { font-style: normal; width: 30px; height: 30px; border-radius: 10px; display: grid; place-items: center; background: linear-gradient(135deg, var(--g1), var(--g2)); font-size: 15px; }
.pk-empty { display: grid; place-items: center; border-radius: 16px; border: 1px dashed var(--line-2); color: var(--ink-3); font-size: 13px; }
.pk-hint { text-align: center; color: var(--ink-3); font-size: 13px; margin: 6px 0 0; }

/* ---------- desk scrub label (the whole bar scrubs; this box only carries the name and takes no touches) ---------- */
.scrub { position: absolute; left: 50%; bottom: calc(2px + var(--safe-b)); width: 190px; height: 26px; margin-left: -95px; pointer-events: none; display: grid; place-items: center; }
.scrub .sc-label { position: absolute; bottom: 30px; white-space: nowrap; padding: 6px 12px; border-radius: 99px; background: linear-gradient(rgba(10, 6, 24, .88), rgba(10, 6, 24, .88)), var(--wz-panel, var(--wz-base, var(--bg, #05030c))); border: 1px solid var(--line-2); font-size: 13px; font-weight: 650; opacity: 0; transform: translateY(6px); transition: opacity 160ms, transform 160ms; pointer-events: none; }
.scrub.on .sc-label { opacity: 1; transform: none; }
/* wizard-ux#1536: while the bar scrubs, the desk under the finger slides in quickly so each step shows that desk. */
.track.anim.bar-scrubbing { transition-duration: 180ms; }

/* ================= Orb as a permanent bottom navigation bar (James, 9 Oct) =================
 * One slim bar owns the bottom edge: content always ends above it, nothing floats over content.
 * Orb 44px in the centre, desk dots beside it; the whole bar is the desk scrub. */
:root { --dock-h: 66px; --orb: 44px; }
.dock { height: calc(var(--dock-h) + var(--safe-b)); padding: 0 0 calc(16px + var(--safe-b)); gap: 18px; align-items: center;
  background: linear-gradient(rgba(8, 5, 18, .94), rgba(8, 5, 18, .94)), var(--wz-panel, var(--wz-base, var(--bg, #05030c))); border-top: 1px solid rgba(205, 190, 255, .10); }
.dock::before { display: none; }
.orb-wrap { width: var(--orb); height: var(--orb); flex: 0 0 var(--orb); margin-top: 6px; }
/* Voice labels touch the orb's top edge inside its dock, never float over chat.
 * Status is non-interactive; the general target appears only during a hold. */
#device > :is(#voiceDestination, #generalVoice) { position: absolute; z-index: 150; bottom: calc(var(--safe-b) + var(--dock-h) - 18px); left: 50%; transform: translateX(-50%); width: max-content; max-width: calc(100% - 24px); min-height: 0; height: 18px; padding: 0 6px; border: 1px solid var(--line-2); border-radius: 9px; background: var(--bg); color: var(--ink); font-size: 10px; line-height: 16px; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none; }
#device :is(#voiceDestination, #generalVoice)[hidden] { display: none !important; }
#device > #generalVoice.hold-target { border-color: var(--violet); }
#device > #generalVoice.selected { background: var(--violet); color: white; }
#device > #voiceDestination.app-voice { border-color: #f2ad52; color: #f2ad52; }
#device.orb-corner > :is(#voiceDestination, #generalVoice) { left: auto; right: var(--corner-r); bottom: calc(var(--safe-b) + var(--corner-b) + var(--corner-orb) - 18px); transform: none; }
#device.immersive:not(.orb-corner) > :is(#voiceDestination, #generalVoice), #device.capturing-screen > :is(#voiceDestination, #generalVoice) { visibility: hidden; }
.orb { inset: -18%; width: 136%; height: 136%; }
.orb-halo { inset: -14%; filter: blur(9px); opacity: calc(.16 + var(--energy, .2) * .4); }
.orb-ring { inset: -4px; }
.orb-ring::before { inset: -4px; } .orb-ring::after { display: none; }
.moons { inset: -9px; } .moons i { width: 5px; height: 5px; margin: -2.5px; }
.orb-badge { top: -4px; right: -10px; min-width: 17px; height: 17px; padding: 0 5px; font-size: 10.5px; }
.timer { bottom: auto; top: -26px; }
.hold-hint { top: -46px; }
.desk-dots { width: 64px; gap: 11px; margin-top: 6px; }
/* the scrub label's box sits on the bar's bottom edge; the label floats above the bar */
.scrub { bottom: var(--safe-b); height: 16px; width: 200px; margin-left: -100px; }
.scrub .sc-label { bottom: calc(var(--dock-h) + 6px); }
/* everything above the bar ends at its top edge */
.desk { padding-bottom: calc(var(--dock-h) + var(--safe-b) + 10px); }
.tiles { bottom: calc(var(--dock-h) + var(--safe-b) + 8px); }
.tiles.has-full { bottom: calc(var(--dock-h) + var(--safe-b)); }
.launcher, .inbox { bottom: calc(var(--dock-h) + var(--safe-b) + 8px); }
.desk-label { bottom: calc(var(--dock-h) + var(--safe-b) + 10px); }
/* voice controls fan out above the bar */
.arc { bottom: calc(var(--safe-b) + var(--dock-h) - 14px); width: 50px; height: 50px; margin: 0 0 -25px -25px; }
.voice.on .arc-left  { transform: translate(-84px, -54px) scale(1); }
.voice.on .arc-mid   { transform: translate(0, -84px) scale(1); }
.voice.on .arc-right { transform: translate(84px, -54px) scale(1); }
.transcript { bottom: calc(var(--safe-b) + var(--dock-h) + 130px); }
.voice.cmd .transcript { bottom: calc(var(--safe-b) + var(--dock-h) + 40px); }
/* first-run coach matches the bar */
.coach-orb { bottom: calc(10px + var(--safe-b)); width: 52px; height: 52px; margin-left: -26px; }
.coach .c-left, .coach .c-right { bottom: 26px; }
.coach .c-up { bottom: 100px; }
.coach .c-down { display: none; }
.coach p { bottom: 160px; }
.coach-go { bottom: 330px; }

/* Dock morph: four buttons flank the unchanged orb; its gesture hit zone stays untouched.
 * All chrome lives inside the existing 66px bar, including timer / first-use tip. */
.device:not(.orb-corner) .voice .arc {
  bottom: calc(var(--safe-b) + 38px); width: 44px; height: 44px;
  margin: 0 0 -22px -22px; backdrop-filter: none; -webkit-backdrop-filter: none;
  box-shadow: none;  transform: scale(.6);
}
:where(.device:not(.orb-corner) .voice) .arc { background: rgba(25, 15, 49, .9); }
.device:not(.orb-corner) .voice.on .arc-left { transform: translate(-124px, 0) scale(1); }
.device:not(.orb-corner) .voice.on .arc-mid { transform: translate(-66px, 0) scale(1); }
.device:not(.orb-corner) .voice.on .arc-screen { transform: translate(66px, 0) scale(1); }
.device:not(.orb-corner) .voice.on .arc-right { transform: translate(124px, 0) scale(1); }
:where(.device:not(.orb-corner)[data-voice="paused"] .voice) .arc-mid { background: color-mix(in srgb, var(--amber) 18%, transparent); border-color: color-mix(in srgb, var(--amber) 50%, transparent); color: var(--amber); }
.device:not(.orb-corner) .voice .arc small { display: none; }
.device:is([data-voice="listen"], [data-voice="paused"]) .desk-dots { opacity: 0; pointer-events: none; }
.device:not(.orb-corner) .timer { top: 44px; min-width: 0; font-size: 10px; line-height: 12px; padding: 0; border: 0; background: var(--wz-panel, var(--wz-base, var(--bg, #05030c))); }
.device:not(.orb-corner) .timer::before { width: 4px; height: 4px; margin-right: 4px; }
.device:not(.orb-corner):is([data-voice="listen"], [data-voice="paused"]) .scrub { pointer-events: none; opacity: 0; }
.device:not(.orb-corner) .voice.on .transcript.brief.tip { bottom: calc(var(--safe-b) + 2px); padding: 0; border: 0; background: var(--wz-panel, var(--wz-base, var(--bg, #05030c))); box-shadow: none;  }
.device:not(.orb-corner) .voice.on .transcript.brief.tip .tx-route { font-size: 10px; }
.device:not(.orb-corner) .voice.on .transcript.brief.tip .tx-route b { display: none; }
.device:not(.orb-corner):has(.voice.on .transcript.brief.tip) .timer { opacity: 0; }
/* Full-screen Chats keeps its established corner orb. The extra chip joins that fan. */
.device.orb-corner .arc-screen { display: none; }
.arc-screen.busy svg { opacity: .4; }
.arc:disabled { pointer-events: none !important; }
/* Capture app pixels without recorder controls or transient shell notices in the picture. */
.device.capturing-screen :is(#voice, #dock, #toast, #deskLabel) { visibility: hidden !important; }

/* ---------- Recorder recordings: shade source + strip on the Mizel desk ---------- */
.note .ic.rec { background: rgba(63, 224, 255, .14); color: #3fe0ff; font-size: 18px; box-shadow: inset 0 0 0 1px rgba(63, 224, 255, .35); }
.note .tp .src.mizel { color: #3fe0ff; }
.mizel-split { position: absolute; inset: 0; display: flex; flex-direction: column; background: #0c0a18; }
.mizel-split .frame-wrap { position: relative; inset: auto; flex: 1; min-height: 0; }
.rec-strip { flex: 0 0 auto; max-height: 34%; display: flex; flex-direction: column; padding: 8px 10px 6px; border-bottom: 1px solid rgba(63, 224, 255, .18);
  background: linear-gradient(180deg, rgba(63, 224, 255, .07), rgba(63, 224, 255, .02)); }
.rec-h { display: flex; justify-content: space-between; align-items: baseline; padding: 0 4px 6px; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }
.rec-h b { color: #3fe0ff; font-weight: 800; }
.rec-list { overflow-y: auto; display: grid; gap: 4px; scrollbar-width: none; }
.rec-list::-webkit-scrollbar { display: none; }
.rec-row { display: grid; grid-template-columns: 44px 1fr 22px; align-items: center; gap: 8px; min-height: 36px; padding: 6px 8px; border-radius: 12px; text-align: left; color: var(--ink); background: rgba(205, 190, 255, .05); border: 1px solid transparent; font: inherit; }
.rec-row:active { background: rgba(63, 224, 255, .14); }
.rec-row.new { border-color: rgba(63, 224, 255, .35); }
.rec-row .rt { font-size: 11.5px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.rec-row .rn { font-size: 13.5px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rec-row.new .rn { font-weight: 800; }
.rec-row .rs { text-align: center; font-size: 14px; }
.rec-row.run .rs { animation: pip 1.6s ease-in-out infinite; }
.rec-row.sum .rs { color: #3fe0ff; }
.rec-empty { padding: 8px 4px; font-size: 13px; color: var(--ink-3); }

/* ---------- Settings gear (Home + empty desks) ---------- */
.gear { position: absolute; z-index: 5; top: calc(var(--sb) + var(--safe-t) + 10px); right: 14px; width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center; background: var(--glass); border: 1px solid var(--line); color: var(--ink-2);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
.gear svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.gear:active { transform: scale(.94); }
.gear-n { position: absolute; top: -3px; right: -3px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; background: var(--amber); color: #1a1000; font-size: 11px; font-weight: 800; display: grid; place-items: center; }
.unsent-card .side-go, .side-card .side-go { flex: 0 0 auto; }
.unsent-card.fail { border-color: rgba(255, 190, 85, .45); }

/* ---------- Settings sheet ---------- */
.settings { --wz-settings-nav-clearance: calc(var(--dock-h) + var(--safe-b)); top: calc(40px + var(--safe-t)); bottom: calc(var(--wz-settings-nav-clearance) + var(--wz-space-2)); transform: translateY(calc(-100% - 60px)); opacity: 0; }
.settings.open { transform: none; opacity: 1; }
.settings-body { flex: 1; min-height: 0; overflow-y: auto; padding: 0 14px 14px; scrollbar-width: none; touch-action: pan-y; overscroll-behavior: contain; }
.settings-body::-webkit-scrollbar { display: none; }
.st-close { position: absolute; z-index: 3; top: 10px; right: 12px; width: 34px; height: 34px; border-radius: 50%; background: rgba(205, 190, 255, .08); color: var(--ink-2); font-size: 15px; }
/* Sent pill: after the orb sends, the transcript card collapses to one short line above the orb
   and fades (~1.2 s). Same quiet confirmation as the floating orb; the sent words stay in the thread. */
.voice .transcript.brief {
  left: 50%; right: auto; width: max-content; max-width: calc(100% - 72px);
  bottom: calc(var(--safe-b) + var(--dock-h) + 16px);
  padding: 8px 14px 8px 9px; border-radius: 999px;
  transform: translate(-50%, 10px) scale(.94);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .45);
}
.voice.tx .transcript.brief { transform: translate(-50%, 0) scale(1); }
.transcript.brief #txText, .transcript.brief .tx-chips { display: none; }
.transcript.brief .tx-route { font-size: 13px; font-weight: 650; letter-spacing: 0; text-transform: none; color: #eee9ff; white-space: nowrap; overflow: hidden; }
.transcript.brief .tx-route span { overflow: hidden; text-overflow: ellipsis; }
.transcript.brief .tx-route b { flex: none; border-radius: 50%; }
.transcript.brief.agent .tx-route b { background: rgba(255, 110, 199, .2); color: var(--pink); }
.transcript.brief.command .tx-route b { color: var(--cyan); }

/* Recording never locks the screen: the whole bottom bar takes desk swipes (James, 9 Oct).
 * Windows end above the bar, so making it touchable covers nothing. */
.dock { pointer-events: auto; touch-action: none; }
/* One-time first-use tip ("tap the orb again to send"), sits above the arc so it never covers a button. */
.voice .transcript.brief.tip { bottom: calc(var(--safe-b) + var(--dock-h) + 104px); }
.transcript.brief.tip .tx-route b { background: rgba(143, 99, 255, .25); color: var(--violet-2); }
/* Bottom label is short (Desk 2 · Chats); cap it so it can never run off the screen. */
.desk-label { max-width: calc(100% - 48px); overflow: hidden; text-overflow: ellipsis; }
/* While recording the timer owns the top of the orb: the unread badge steps aside so the time is readable. */
.device[data-voice="listen"] .orb-badge, .device[data-voice="paused"] .orb-badge, .device[data-voice="command"] .orb-badge { opacity: 0; }

/* ---- Device features (0.7.0 native parity): share sheet, recovered recording, update banner ---- */
.dv-wrap { position: absolute; inset: 0; z-index: 80; pointer-events: none; }
.dv-wrap.open { pointer-events: auto; }
.dv-scrim { position: absolute; inset: 0; background: rgba(2, 1, 8, .6); opacity: 0; transition: opacity 200ms; }
.dv-wrap.open .dv-scrim { opacity: 1; }
.dv-sheet { position: absolute; left: 8px; right: 8px; bottom: calc(var(--safe-b) + 8px); max-height: 78%; overflow-y: auto; padding: 16px 14px 14px; border-radius: 26px;
  background: linear-gradient(rgba(14, 8, 34, .96), rgba(14, 8, 34, .96)), var(--wz-panel, var(--wz-base, var(--bg, #05030c))); border: 1px solid var(--line-2); box-shadow: 0 -10px 50px rgba(0, 0, 0, .5); transform: translateY(110%); transition: transform 260ms var(--ease); scrollbar-width: none; }
.dv-wrap.open .dv-sheet { transform: none; }
/* Share to Wizard keeps voice typing (James, 21 Oct): the orb stays above the sheet and its scrim, so a focused
 * note turns it blue and a tap dictates into the note. The sheet stops above the dock; desk dots step aside. */
.device.dv-share-open .dock, .device.dv-share-open .voice { z-index: 82; }
.device.dv-share-open .desk-dots { visibility: hidden; }
.device.dv-share-open .dv-sheet { bottom: calc(var(--safe-b) + var(--dock-h) + 4px); max-height: calc(100% - var(--safe-b) - var(--dock-h) - 40px); }
.dv-head { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.dv-head b { display: block; font-size: 17px; font-weight: 650; }
.dv-head small { display: block; font-size: 12.5px; color: var(--ink-3); margin-top: 2px; }
.dv-ic { flex: 0 0 38px; height: 38px; border-radius: 13px; display: grid; place-items: center; background: rgba(143, 99, 255, .2); color: var(--violet-2); font-size: 17px; }
.dv-items { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin-bottom: 10px; }
.dv-items:empty { display: none; }
.dv-item { flex: 0 0 auto; display: flex; align-items: center; gap: 8px; max-width: 220px; padding: 5px 8px 5px 5px; border-radius: 14px; background: rgba(205, 190, 255, .07); border: 1px solid var(--line); }
.dv-item img, .dv-fi { flex: 0 0 auto; width: 42px; height: 42px; border-radius: 10px; object-fit: cover; display: grid; place-items: center; background: rgba(0, 0, 0, .25); color: var(--ink-2); }
.dv-nm { min-width: 0; display: flex; flex-direction: column; font-size: 12.5px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dv-nm small { font-size: 11px; color: var(--ink-3); }
.dv-text { width: 100%; box-sizing: border-box; resize: none; margin-bottom: 10px; padding: 10px 12px; border-radius: 16px; background: rgba(205, 190, 255, .06); border: 1px solid var(--line); color: var(--ink); font: inherit; font-size: 14.5px; }
.dv-btn { padding: 9px 16px; border-radius: 99px; background: rgba(205, 190, 255, .08); border: 1px solid var(--line-2); color: var(--ink); font-size: 13.5px; font-weight: 650; }
.dv-btn.primary { background: var(--violet); border-color: transparent; color: #fff; }
.dv-btn.wide { width: 100%; padding: 12px; font-size: 15px; }
.dv-btn:disabled, .dv-thread:disabled { opacity: .5; }
.dv-sub { margin: 14px 4px 6px; font-size: 11px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }
.dv-thread { display: block; width: 100%; text-align: left; padding: 11px 12px; margin-bottom: 6px; border-radius: 14px; background: var(--glass); border: 1px solid var(--line); color: var(--ink); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dv-status { min-height: 18px; margin-top: 8px; font-size: 12.5px; color: var(--ink-2); text-align: center; }
.dv-status:empty { display: none; }
.dv-take { display: flex; align-items: center; gap: 8px; padding: 10px 10px 10px 12px; margin-bottom: 8px; border-radius: 16px; background: var(--glass); border: 1px solid var(--line); }
.dv-tk { flex: 1; font-size: 14px; font-variant-numeric: tabular-nums; }
.dv-note { margin: 6px 4px 0; font-size: 12px; color: var(--ink-3); }
/* .dv-update banners (APK update, web update): core/update-banner.css, shared with the desktop shell. */
/* ================= Immersive full screen (James, 9 Oct) =================
 * A full-screen window owns the whole display: no window title bar, no bottom bar, no desk label.
 * Out: pinch in, swipe up from the bottom edge, or Back. In Chats the orb stays, small, bottom-right,
 * beside the composer, so a voice reply is one tap away. */
.device.immersive .tiles.has-full { top: 0; bottom: var(--safe-b); left: 0; right: 0; }
.device.immersive .tiles.has-full .win.full { border-radius: 0; }
.device.immersive .win.full .wbar { display: none; }
/* Edge to edge (James, 10 Oct): the window's background reaches the top of the glass, its content starts below the
 * camera. A margin (not padding) so absolutely placed content such as Chats moves down too. Hosted apps that read
 * --wos-cutout themselves stay full bleed (.edge-own); others move down and the strip takes their own background. */
.device.immersive .win.full .wbody { margin-top: var(--cut-t, 0px); }
.device.immersive .win.full.edge-own .wbody { margin-top: 0; }
.device.immersive > .wx-banners, .device.immersive .toast { margin-top: var(--cut-t, 0px); } /* notices clear the camera too */
.device.immersive .win.full.app-frame:not(.edge-own) { background: var(--frame-bg, #0f1014); -webkit-backdrop-filter: none; backdrop-filter: none; }
.device.immersive .desk-label, .device.immersive .hint-row { opacity: 0 !important; pointer-events: none; }
.dock { transition: transform 300ms var(--ease), opacity 220ms; }
.device.immersive:not(.orb-corner) .dock { transform: translateY(110%); opacity: 0; pointer-events: none; }
.device.immersive:not(.orb-corner) .arc, .device.immersive:not(.orb-corner) .timer { visibility: hidden; }
.device.immersive .voice .transcript.brief { bottom: calc(var(--safe-b) + 74px); }
.device.immersive .transcript { bottom: calc(var(--safe-b) + 150px); }

/* Text entry temporarily reveals the same corner orb; reading immersion remains unchanged. */
.orb-wrap[data-mode="type"] #orbFallback, .orb-wrap[data-mode="typing"] #orbFallback { filter: sepia(1) saturate(6) hue-rotate(155deg); }
.transcript.dictation #txText { user-select: text; -webkit-user-select: text; white-space: pre-wrap; }
.device.dictation-recording #arcAttach, .device.dictation-recording #arcScreen { display: none; }
/* Dictation progress lives beside the orb, without another card above the app. */
.dictation-status { position: absolute; right: calc(100% + 8px); top: 50%; transform: translateY(-50%); color: var(--ink-3); font-size: 11px; font-weight: 500; line-height: 16px; white-space: nowrap; pointer-events: none; }
.dictation-status:empty { display: none; }
.device.dictation-recording[data-voice="think"] #dotsL { visibility: hidden; }
.device.dictation-recording[data-voice="think"] #transcript { visibility: hidden; pointer-events: none; }

/* Chats in full screen: the bottom bar shrinks to just the orb, in the composer row's right corner. */
.device.orb-corner { --corner-orb: 44px; --corner-r: 12px; --corner-b: 9px; }
.device.orb-corner .dock { left: auto; right: var(--corner-r); bottom: calc(var(--safe-b) + var(--corner-b)); width: var(--corner-orb); height: var(--corner-orb);
  padding: 0; gap: 0; background: none; border: 0; animation: cornerIn 320ms var(--spring); }
@keyframes cornerIn { from { transform: scale(.4); opacity: 0; } }
.device.orb-corner .desk-dots, .device.orb-corner #scrub { display: none; }
.device.orb-corner .orb-wrap { margin: 0; }
.device.orb-corner .win.full .ch-compose { padding-right: calc(var(--corner-orb) + var(--corner-r) + 8px); }
/* Android's document-scroll thread pins the composer (position: fixed) above the bottom bar's strip, so the corner orb is
 * under it, never in it: no empty orb column in the row (James, 8 Nov 2026: the Stop button sat 60px short of the edge, the
 * model chip wrapped). The column is reserved only where the orb really overlays the composer. */
html.wos-doc-scroll .device.orb-corner .wos-doc-thread .ch-compose { padding-right: 10px; }
.device.orb-corner .win.full .ch-scroll { padding-bottom: 72px; }
/* voice controls fan up and left from the corner, Cancel nearest the thumb */
.device.orb-corner .arc { left: auto; right: calc(var(--corner-r) + var(--corner-orb) / 2); bottom: calc(var(--safe-b) + var(--corner-b) + var(--corner-orb) / 2); margin: 0 -25px -25px 0; }
/* the fan sits wholly above the composer row so it never lands on Send or the text field */
.device.orb-corner .voice.on .arc-left  { transform: translate(-118px, -76px) scale(1); }
.device.orb-corner .voice.on .arc-mid   { transform: translate(-68px, -118px) scale(1); }
.device.orb-corner .voice.on .arc-right { transform: translate(-4px, -146px) scale(1); }
.device.orb-corner .timer { left: auto; right: -4px; transform: none; top: -26px; }
.device.orb-corner .hold-hint { left: auto; right: 0; transform: none; }
.device.orb-corner .voice .transcript.brief { left: auto; right: 12px; transform: translateY(10px) scale(.94); bottom: calc(var(--safe-b) + 140px); }
.device.orb-corner .voice.tx .transcript.brief { transform: none; }

/* Full-screen thread (James, 10 Oct): the orb rises into the right-hand column above the composer. Below it sits a
 * band for Done (end of a reply) and ↓ Latest (scrolled up), so neither is ever under the orb; the composer gets its
 * full width back. --comp-h is the composer's measured height. */
.device.orb-lift { --corner-b: calc(var(--comp-h, 63px) + 52px); }
.device.orb-lift .dock { transition: bottom 180ms var(--ease); }
.device.orb-lift .win.full .ch-compose { padding-right: 10px; }
.device.orb-lift .win.full .ch-latest { right: 12px; bottom: calc(var(--comp-h, 63px) + 10px); }
.device.orb-lift .imm-edge { right: 0; }
.device.orb-lift .imm-edge i { left: 50%; }
/* the live transcript card sits above the voice fan (which tops out ~175px above the orb), never on it */
.device.orb-lift .transcript { bottom: calc(var(--safe-b) + var(--corner-b) + var(--corner-orb) + 170px); }
.device.orb-lift .voice .transcript.brief { bottom: calc(var(--safe-b) + var(--corner-b) + var(--corner-orb) + 170px); }

/* Bottom edge: swipe up from anywhere along it to leave full screen. Shows a faint handle on entry. */
.imm-edge { position: absolute; left: 0; right: 0; bottom: 0; height: calc(18px + var(--safe-b)); z-index: 58; display: none; touch-action: none; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.device.immersive .imm-edge { display: block; }
.device.immersive.imm-typing .imm-edge { display: none; }
.device.orb-corner .imm-edge { right: calc(var(--corner-orb) + var(--corner-r) + 6px); height: calc(12px + var(--safe-b)); }
.device.orb-corner .win.full .ch-compose { padding-bottom: 14px; }
.imm-edge i { position: absolute; left: 50%; bottom: calc(5px + var(--safe-b)); width: 64px; height: 4px; margin-left: -32px; border-radius: 99px;
  background: rgba(205, 190, 255, .55); box-shadow: 0 0 10px rgba(143, 99, 255, .5); opacity: 0; transition: opacity 400ms, width 220ms var(--spring); }
.device.imm-tip .imm-edge i, .imm-edge.pull i { opacity: 1; }
.imm-edge.pull i { width: 110px; margin-left: -55px; }
.device.orb-corner .imm-edge i { left: calc(50% + 29px); }
/* Settings → Cancelled recordings (core/cancelled.js) */
/* Home utility shortcuts stay quiet beside Settings, away from attention cards. */
.home .home-top { padding-top: 40px; } /* reserve the 44px shortcut row, including long dates on narrow phones */
.home-tools { position: absolute; z-index: 5; top: calc(var(--sb) + var(--safe-t) + 8px); right: 12px; display: flex; align-items: center; gap: 6px; }
.home-tools .gear { position: relative; top: auto; right: auto; width: 44px; height: 44px; }
.home-system { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; background: transparent; border: 1px solid var(--line); color: var(--ink-3); }
.home-system svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.home-system:active { transform: scale(.94); }
.home-tools button:focus-visible { outline: 2px solid var(--violet-2); outline-offset: 2px; }
@media (hover: hover) { .home-system:hover { color: var(--ink); border-color: var(--violet-2); } }
.device.wx-on .home-tools { top: calc(var(--sb) + var(--safe-t) + var(--wx-banner-height, 42px)); }
.device.wx-on .home-tools .gear { top: auto; }
/* Opinionated: Home shows Ready / Working as two small side-by-side counters; the line under the clock is gone. */
.home .home-line:empty { display: none; }
.home .constellation { flex-direction: row; gap: 9px; }
.home .constellation .now-card { flex: 1 1 0; min-height: 0; padding: 10px 12px; gap: 9px; }
.home .home-attn { margin-top: auto; }
.home .home-gap-b { display: none; }
/* Ready / Working counters, quiet: a small flat dot, the label in plain ink, the count beside it; no glow, no pulsing
   ring, no coloured caps. They sit clear of the resources widget below. */
.home .constellation { margin-bottom: 20px; }
.home .constellation .now-card { min-height: 0; padding: 9px 14px; gap: 8px; background: color-mix(in srgb, var(--ink) 5%, transparent); border-color: transparent; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.home .constellation .now-card .pip { flex-basis: 7px; height: 7px; box-shadow: none; }
.home .constellation .now-card .pip.pulse::after { display: none; }
.home .constellation .now-card .k { font-size: 14px; font-weight: 500; letter-spacing: 0; text-transform: none; color: var(--ink-2); }
.home .constellation .now-card .n { font-size: 16px; font-weight: 500; color: var(--ink); padding-left: 4px; }

/* ================= Distraction-free (James, 18 Oct 2026) =================
 * A short swipe down on the orb (or just above it) hides the bottom bar and every window's title bar. Same layout,
 * no system bars toggled: the tiles grow into the space through their existing inset transition and the title bar
 * slides up out of its window, so the change is one smooth motion. A faint handle marks the bottom edge; swipe up
 * there (or Back) to bring the bars back. A live voice take shows the bar again until it ends. */
.wbar { transition: height 340ms var(--ease), flex-basis 340ms var(--ease), min-height 340ms var(--ease), opacity 220ms, border-color 220ms; }
.win { transition: border-color 220ms, box-shadow 220ms, opacity 280ms, transform 380ms var(--ease), border-radius 340ms var(--ease), padding 340ms var(--ease); }
/* Collapse the bar by height (skins size it 34-44 px), so no sliver of it is left above the app. */
.device.zen .wbar { height: 0 !important; min-height: 0 !important; flex-basis: 0 !important; overflow: hidden; border-bottom-color: transparent; opacity: 0; pointer-events: none; }
.device.zen .win { padding-top: 0 !important; }
/* The app takes the whole viewport; the handle floats over it on a transparent strip. */
.device.zen .tiles { top: calc(var(--sb) + var(--safe-t) + 4px); bottom: 0; }
/* Distraction-free keeps the phone's status bar (only immersive full screen hides it), so the app starts below it. */
.device.zen .tiles[data-n="1"], .device.zen .tiles.has-full { left: 0; right: 0; top: calc(var(--sb) + var(--safe-t)); bottom: 0; }
.device.zen.immersive .tiles.has-full { top: 0; }
.device.zen .tiles[data-n="1"] .win, .device.zen .tiles.has-full .win.full { border-radius: 0; border-color: transparent; box-shadow: none; }
.device.zen .desk { padding-bottom: var(--safe-b); }
.device.zen .dock { transform: translateY(110%); opacity: 0; pointer-events: none; }
.device.zen #scrub, .device.zen .desk-label { opacity: 0 !important; pointer-events: none; }
.device.zen[data-voice]:not([data-voice="idle"]) .dock { transform: none; opacity: 1; pointer-events: auto; }
/* full-screen Chats: the corner orb hides too, and the composer takes its column back */
.device.zen.orb-corner.immersive .tiles.has-full { top: 0; bottom: 0; }
.device.zen.orb-corner .win.full .ch-compose { padding-right: 10px; }
.device.zen.orb-corner .win.full .ch-latest { right: 12px; }
.zen-edge { position: absolute; left: 0; right: 0; bottom: 0; height: calc(24px + var(--safe-b)); z-index: 59; display: none; touch-action: none; cursor: grab; -webkit-tap-highlight-color: transparent; }
.device.zen .zen-edge { display: block; }
.device.zen.immersive:not(.orb-corner) .zen-edge { display: none; }
.device.zen[data-voice]:not([data-voice="idle"]) .zen-edge { display: none; }
.zen-edge i { position: absolute; left: 50%; bottom: calc(10px + var(--safe-b)); width: 44px; height: 4px; margin-left: -22px; border-radius: 99px;
  background: rgba(205, 190, 255, .55); box-shadow: 0 0 0 1px rgba(0, 0, 0, .28), 0 1px 6px rgba(0, 0, 0, .35); transition: width 220ms var(--spring), margin-left 220ms var(--spring), background 300ms, box-shadow 300ms; }
.device.zen-tip .zen-edge i, .zen-edge.pull i { width: 96px; margin-left: -48px; background: rgba(205, 190, 255, .7); box-shadow: 0 0 10px rgba(143, 99, 255, .5); }
.device.zen .imm-edge i { opacity: 0 !important; } /* one handle at a time: the distraction-free one wins */
/* Voice "Sending…" status lives in the dock, on the orb's top edge, like the voice destination label (Miguel,
 * 18 Oct): never over list rows or sort chips, never takes a tap, so another session stays one tap away. */
.device:not(.orb-corner) .voice .transcript.brief:not(.tip) {
  bottom: calc(var(--safe-b) + var(--dock-h) - 18px); z-index: 150; height: 18px; max-width: calc(100% - 24px);
  padding: 0 7px 0 3px; border-radius: 9px; border: 1px solid var(--line-2); background: var(--bg, rgba(8, 5, 18, .94));
  box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; pointer-events: none !important;
  display: flex; align-items: center; transform: translate(-50%, 4px) scale(.96);
}
.device:not(.orb-corner) .voice.tx .transcript.brief:not(.tip) { transform: translate(-50%, 0); }
.device:not(.orb-corner) .transcript.brief:not(.tip) .tx-route { font-size: 10px; line-height: 16px; gap: 4px; font-weight: 650; }
.device:not(.orb-corner) .transcript.brief:not(.tip) .tx-route b { width: 12px; height: 12px; font-size: 8px; background: none !important; }
/* While that label shows, the voice destination label (same spot) steps aside. */
.device:has(.voice.tx .transcript.brief:not(.tip)) > #voiceDestination { visibility: hidden; }

/* Title-bar tools (WizardApp.titlebar.set): an app's own few controls ride its window bar so the app keeps the
 * screen. Neutral, token-only styling; every skin inherits it. */
.wbar > .wtools { flex: 0 1 auto; min-width: 0; display: flex; align-items: center; gap: 2px; margin-left: auto; }
.wbar.has-tools > :is(.wt, .t) { flex: 1 1 auto; }
.wtool { flex: none; height: 30px; min-width: 30px; padding: 0 8px; border: 0; border-radius: 9px; display: grid; place-items: center;
  background: transparent; color: var(--ink-2); font: 600 13px/1 inherit; text-decoration: none; cursor: pointer; }
.wtool-ic { padding: 0; }
.wtool svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.wtool:disabled, .wtool[aria-disabled="true"] { opacity: .3; cursor: default; pointer-events: none; }
.wtool-pick { flex: 0 1 auto; min-width: 0; max-width: 132px; height: 30px; padding: 0 6px; border: 0; border-radius: 9px; appearance: none; -webkit-appearance: none;
  background: var(--glass-2, rgba(255,255,255,.06)); color: var(--ink); font: 600 13px/1 inherit; text-align: center; text-align-last: center; cursor: pointer; }
@media (hover: hover) { .wtool:not(:disabled):hover { color: var(--ink); background: var(--glass-2, rgba(255,255,255,.08)); } }
.wtool { position: relative; }
.wtool-dot::after { content: ""; position: absolute; top: 4px; right: 4px; width: 7px; height: 7px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 0 2px var(--bg); pointer-events: none; }
/* Phone: icon tools are 44px wide, and an invisible hit area reaches 44px tall, whatever height a skin draws them. */
html[data-shell="phone"] .wbar > .wtools > .wtool.wtool-ic[data-tool] { min-width: 44px; }
html[data-shell="phone"] .wbar > .wtools { position: relative; z-index: 1; }   /* the hit area may reach a few px past a slim bar */
html[data-shell="phone"] .wbar > .wtools > .wtool-ic::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 44px; transform: translateY(-50%); }
html[data-shell="phone"] .wbar > .wtools > .wtool-ic.wtool-dot::after { right: 10px; }
