@font-face {
  font-family: "Palm Status";
  src: url("./silkscreen-latin-700-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

:root {
  color-scheme: light;
  font-family: "Segoe UI Variable Text", "Segoe UI", system-ui, sans-serif;
  --bg: #f3f4f6;
  --panel: rgba(255, 255, 255, 0.82);
  --panel-strong: rgba(255, 255, 255, 0.96);
  --text: #111111;
  --muted: rgba(17, 17, 17, 0.58);
  --border: rgba(17, 17, 17, 0.12);
  --border-strong: rgba(17, 17, 17, 0.22);
  --surface: rgba(0, 0, 0, 0.035);
  --surface-strong: rgba(0, 0, 0, 0.065);
  --shadow: 0 24px 70px rgba(17, 17, 17, 0.08);
  --highlight: rgba(91, 195, 255, 0.08);
  --status-glow: rgba(91, 195, 255, 0.42);
  --status-track: rgba(91, 195, 255, 0.22);
}

body[data-theme="dark"] {
  color-scheme: dark;
  --bg: #070707;
  --panel: rgba(19, 19, 19, 0.9);
  --panel-strong: rgba(23, 23, 23, 0.96);
  --text: #f7f7f2;
  --muted: rgba(247, 247, 242, 0.62);
  --border: rgba(247, 247, 242, 0.12);
  --border-strong: rgba(247, 247, 242, 0.24);
  --surface: rgba(255, 255, 255, 0.04);
  --surface-strong: rgba(255, 255, 255, 0.08);
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.45);
  --highlight: rgba(124, 216, 255, 0.1);
  --status-glow: rgba(124, 216, 255, 0.52);
  --status-track: rgba(124, 216, 255, 0.28);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.36), transparent 42%),
    linear-gradient(180deg, var(--bg), color-mix(in srgb, var(--bg) 84%, var(--text) 16%));
  color: var(--text);
}

body {
  overflow: hidden;
}

button,
input {
  font: inherit;
}

button {
  border: 0;
  background: none;
  color: inherit;
}

input {
  border: 0;
}

.app-shell {
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 14px;
  transition: padding 140ms ease, gap 140ms ease;
}

.composer-card {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 26px;
  background: var(--panel);
  backdrop-filter: blur(22px);
  box-shadow: var(--shadow);
  transition: padding 140ms ease, gap 140ms ease, border-radius 140ms ease;
}

.window-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}

.window-controls {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
  min-width: 0;
}

.utility-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
}

.utility-main {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  --search-shell-width: 132px;
  --search-shell-min-width: 100px;
  --shortcut-gap: 6px;
  --shortcut-pill-font: 0.78rem;
  --shortcut-pill-pad-y: 4px;
  --shortcut-pill-pad-x: 9px;
  --kbd-font: 0.73rem;
  --kbd-pad-y: 2px;
  --kbd-pad-x: 6px;
}

.utility-main[data-density="compact"] {
  --search-shell-width: 120px;
  --search-shell-min-width: 96px;
  --shortcut-gap: 6px;
  --shortcut-pill-font: 0.78rem;
  --shortcut-pill-pad-y: 4px;
  --shortcut-pill-pad-x: 9px;
  --kbd-font: 0.73rem;
  --kbd-pad-y: 2px;
  --kbd-pad-x: 6px;
}

.utility-main[data-density="tight"] {
  --search-shell-width: 108px;
  --search-shell-min-width: 88px;
  --shortcut-gap: 5px;
  --shortcut-pill-font: 0.76rem;
  --shortcut-pill-pad-y: 3px;
  --shortcut-pill-pad-x: 8px;
  --kbd-font: 0.7rem;
  --kbd-pad-y: 1px;
  --kbd-pad-x: 5px;
}

.utility-main[data-density="micro"] {
  --search-shell-width: 104px;
  --search-shell-min-width: 84px;
  --shortcut-gap: 4px;
  --shortcut-pill-font: 0.62rem;
  --shortcut-pill-pad-y: 2px;
  --shortcut-pill-pad-x: 5px;
  --kbd-font: 0.6rem;
  --kbd-pad-y: 1px;
  --kbd-pad-x: 3px;
}

.utility-main[data-density="nano"] {
  --search-shell-width: 92px;
  --search-shell-min-width: 72px;
  --shortcut-gap: 3px;
  --shortcut-pill-font: 0.51rem;
  --shortcut-pill-pad-y: 1px;
  --shortcut-pill-pad-x: 3px;
  --kbd-font: 0.49rem;
  --kbd-pad-y: 1px;
  --kbd-pad-x: 2px;
}

.brand-lockup {
  display: flex;
  align-items: baseline;
  gap: 10px;
  min-width: 0;
}

.brand-title {
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.brand-title-button {
  padding: 0;
  color: var(--text);
  cursor: text;
}

.brand-title-input {
  min-width: 110px;
  max-width: min(42vw, 320px);
  height: 30px;
  padding: 0 8px;
  border: 1px solid var(--border);
  border-radius: 10px;
  outline: none;
  background: color-mix(in srgb, var(--panel-strong) 76%, var(--surface) 24%);
  color: var(--text);
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.brand-title-input:focus {
  border-color: var(--border-strong);
  box-shadow: 0 0 0 4px var(--highlight);
}

.brand-meta,
.voice-status {
  color: var(--muted);
  font-size: 0.8rem;
}

.chrome-button,
.icon-button {
  height: 38px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--panel-strong);
  transition:
    transform 120ms ease,
    border-color 120ms ease,
    background 120ms ease,
    opacity 120ms ease;
}

.chrome-button:hover,
.icon-button:hover {
  transform: translateY(-1px);
  border-color: var(--border-strong);
}

.chrome-button:active,
.icon-button:active {
  transform: translateY(0);
}

.chrome-button {
  padding: 0 14px;
}

.theme-toggle {
  min-width: 164px;
  height: 34px;
  padding: 3px;
  border-radius: 10px;
  border-color: rgba(17, 17, 17, 0.14);
  background: linear-gradient(180deg, rgba(246, 247, 248, 0.98), rgba(231, 234, 236, 0.94));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.72),
    0 4px 10px rgba(17, 17, 17, 0.06);
  display: inline-flex;
  align-items: center;
  justify-content: stretch;
  gap: 3px;
}

.theme-choice {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 1 1 0;
  height: 24px;
  padding: 0 8px;
  border-radius: 7px;
  color: rgba(17, 17, 17, 0.42);
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition:
    background 120ms ease,
    color 120ms ease,
    box-shadow 120ms ease;
}

.theme-choice[data-theme-option="light"].is-active {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(236, 239, 242, 0.94));
  color: #121417;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    0 1px 4px rgba(17, 17, 17, 0.08);
}

.theme-choice[data-theme-option="dark"].is-active {
  background: linear-gradient(180deg, rgba(35, 39, 43, 0.98), rgba(13, 17, 20, 0.96));
  color: #f7f7f2;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 1px 4px rgba(0, 0, 0, 0.2);
}

body[data-theme="dark"] .theme-toggle {
  border-color: rgba(247, 247, 242, 0.1);
  background: linear-gradient(180deg, rgba(39, 42, 45, 0.94), rgba(26, 29, 32, 0.96));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 4px 10px rgba(0, 0, 0, 0.18);
}

body[data-theme="dark"] .theme-choice {
  color: rgba(247, 247, 242, 0.42);
}

.button-label {
  font-size: 0.84rem;
  font-weight: 600;
}

.composer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 10px;
  align-items: center;
}

.composer-input,
.search-input {
  width: 100%;
  outline: none;
  background: transparent;
  color: var(--text);
}

.composer-input {
  min-height: 52px;
  max-height: 148px;
  padding: 14px 18px;
  border: 1px solid transparent;
  border-radius: 18px;
  background: color-mix(in srgb, var(--panel-strong) 76%, var(--surface) 24%);
  font-size: 1rem;
  line-height: 1.35;
  resize: none;
  overflow-y: auto;
  scrollbar-width: none;
  transition:
    border-color 120ms ease,
    box-shadow 120ms ease,
    background 120ms ease;
}

.composer-input::-webkit-scrollbar {
  display: none;
}

.composer-input:focus,
.search-shell:focus-within {
  border-color: var(--border-strong);
  box-shadow: 0 0 0 5px var(--highlight);
}

.composer-input::placeholder,
.search-input::placeholder {
  color: var(--muted);
}

.icon-button {
  width: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  position: relative;
  overflow: hidden;
}

.icon-button svg,
.search-icon {
  width: 19px;
  height: 19px;
  fill: currentColor;
}

.icon-button.is-primary {
  background: var(--text);
  color: var(--bg);
  border-color: transparent;
}

.icon-button.is-primary:disabled {
  opacity: 0.28;
  cursor: default;
}

.voice-button {
  --mic-level: 0%;
}

.composer > .icon-button {
  align-self: center;
  margin-top: -3px;
}

.voice-button svg {
  position: relative;
  z-index: 1;
}

.voice-meter-bar {
  position: absolute;
  left: 7px;
  right: 7px;
  bottom: 6px;
  height: 4px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--text) 16%, transparent);
  overflow: hidden;
}

.voice-meter-bar::after {
  content: "";
  display: block;
  height: 100%;
  width: var(--mic-level);
  border-radius: inherit;
  background: linear-gradient(90deg, #2fd95f, #6fff9e);
  transition: width 80ms linear, opacity 120ms ease;
  opacity: 0.96;
}

.voice-button.is-ready {
  border-color: color-mix(in srgb, #2fd95f 42%, var(--border));
}

.voice-button.is-listening {
  background: color-mix(in srgb, #0a1d10 72%, var(--panel-strong) 28%);
  color: #ecfff1;
  border-color: #2fd95f;
  box-shadow: 0 0 0 1px rgba(47, 217, 95, 0.18);
}

.search-shell {
  min-width: 0;
  width: min(100%, var(--search-shell-width));
  min-width: var(--search-shell-min-width);
  flex: 0 1 var(--search-shell-width);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  height: 38px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: color-mix(in srgb, var(--panel-strong) 72%, var(--surface) 28%);
  transition:
    border-color 120ms ease,
    box-shadow 120ms ease;
}

.search-icon {
  color: var(--muted);
}

.status-radio {
  --status-shell-border: #14191d;
  --status-shell-bg: linear-gradient(180deg, #8b9599 0%, #647075 12%, #2a3237 52%, #0d1114 100%);
  --status-screen-border: #0f7caf;
  --status-screen-bg:
    linear-gradient(180deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.04) 18%, transparent 19%),
    repeating-linear-gradient(
      180deg,
      rgba(5, 103, 146, 0.12) 0,
      rgba(5, 103, 146, 0.12) 1px,
      transparent 1px,
      transparent 4px
    ),
    linear-gradient(180deg, #76ecff 0%, #33cdf2 54%, #169ccc 100%);
  --status-screen-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    inset 0 -1px 0 rgba(8, 91, 126, 0.3),
    inset 0 0 0 1px rgba(10, 118, 162, 0.18),
    0 0 8px rgba(40, 196, 255, 0.12);
  --status-overlay-bg:
    linear-gradient(180deg, rgba(255, 255, 255, 0.12), transparent 28%),
    linear-gradient(90deg, rgba(255, 255, 255, 0.06), transparent 16%, transparent 84%, rgba(10, 86, 128, 0.08));
  --status-text-color: #0a5b84;
  --status-text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.12),
    0 0 1px rgba(14, 92, 127, 0.16);
  position: relative;
  display: inline-flex;
  align-items: stretch;
  justify-content: center;
  flex: 0 0 auto;
  min-width: 168px;
  max-width: 168px;
  height: 38px;
  padding: 3px;
  border: 1px solid var(--status-shell-border);
  border-radius: 2px;
  background: var(--status-shell-bg);
  box-shadow:
    inset 1px 1px 0 rgba(255, 255, 255, 0.28),
    inset -1px -1px 0 rgba(0, 0, 0, 0.44),
    0 4px 8px rgba(8, 10, 13, 0.12);
  cursor: pointer;
  transition: transform 120ms ease, filter 120ms ease;
  user-select: none;
  -webkit-user-select: none;
}

.status-radio:hover {
  filter: saturate(1.05);
  transform: translateY(-1px);
}

.status-radio:active {
  transform: translateY(0);
}

.status-radio[data-status-theme="paper-light"] {
  --status-shell-border: #c9d0d5;
  --status-shell-bg: linear-gradient(180deg, #ffffff 0%, #eef2f5 48%, #dde4e8 100%);
  --status-screen-border: #d1d6db;
  --status-screen-bg:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(245, 247, 248, 0.98)),
    repeating-linear-gradient(
      180deg,
      rgba(133, 140, 147, 0.08) 0,
      rgba(133, 140, 147, 0.08) 1px,
      transparent 1px,
      transparent 4px
    );
  --status-screen-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    inset 0 -1px 0 rgba(181, 188, 195, 0.24);
  --status-overlay-bg:
    linear-gradient(180deg, rgba(255, 255, 255, 0.1), transparent 30%),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04), transparent 16%, transparent 84%, rgba(188, 193, 198, 0.08));
  --status-text-color: #0f1113;
  --status-text-shadow: 0 1px 0 rgba(255, 255, 255, 0.18);
}

.status-radio[data-status-theme="inverse-dark"] {
  --status-shell-border: #3a4147;
  --status-shell-bg: linear-gradient(180deg, #576067 0%, #2b3136 36%, #111417 100%);
  --status-screen-border: #454d53;
  --status-screen-bg:
    linear-gradient(180deg, rgba(30, 33, 37, 0.98), rgba(5, 7, 9, 1)),
    repeating-linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.06) 0,
      rgba(255, 255, 255, 0.06) 1px,
      transparent 1px,
      transparent 4px
    );
  --status-screen-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    inset 0 -1px 0 rgba(0, 0, 0, 0.4),
    0 0 8px rgba(255, 255, 255, 0.06);
  --status-overlay-bg:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), transparent 26%),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04), transparent 16%, transparent 84%, rgba(255, 255, 255, 0.03));
  --status-text-color: #f7f7f2;
  --status-text-shadow: 0 0 1px rgba(255, 255, 255, 0.2);
}

.status-radio[data-status-theme="dos-green"] {
  --status-shell-border: #17311f;
  --status-shell-bg: linear-gradient(180deg, #345340 0%, #183022 34%, #09150e 100%);
  --status-screen-border: #29573a;
  --status-screen-bg:
    linear-gradient(180deg, rgba(10, 21, 12, 0.98), rgba(2, 7, 4, 1)),
    repeating-linear-gradient(
      180deg,
      rgba(94, 255, 140, 0.08) 0,
      rgba(94, 255, 140, 0.08) 1px,
      transparent 1px,
      transparent 4px
    );
  --status-screen-shadow:
    inset 0 1px 0 rgba(161, 255, 190, 0.08),
    inset 0 -1px 0 rgba(0, 0, 0, 0.42),
    0 0 10px rgba(95, 255, 141, 0.14);
  --status-overlay-bg:
    linear-gradient(180deg, rgba(167, 255, 189, 0.06), transparent 24%),
    linear-gradient(90deg, rgba(161, 255, 190, 0.04), transparent 16%, transparent 84%, rgba(161, 255, 190, 0.03));
  --status-text-color: #72ff8f;
  --status-text-shadow:
    0 0 1px rgba(114, 255, 143, 0.4),
    0 0 6px rgba(114, 255, 143, 0.14);
}

.status-radio[data-status-theme="hyperpop-pink"] {
  --status-shell-border: #7d1858;
  --status-shell-bg: linear-gradient(180deg, #ff8cc8 0%, #b12879 28%, #5b1041 100%);
  --status-screen-border: #ff6ec7;
  --status-screen-bg:
    linear-gradient(180deg, rgba(255, 222, 247, 0.94), rgba(255, 122, 211, 0.98) 52%, rgba(255, 54, 178, 1) 100%),
    repeating-linear-gradient(
      180deg,
      rgba(133, 12, 89, 0.12) 0,
      rgba(133, 12, 89, 0.12) 1px,
      transparent 1px,
      transparent 4px
    );
  --status-screen-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    inset 0 -1px 0 rgba(124, 11, 84, 0.24),
    0 0 10px rgba(255, 71, 196, 0.22);
  --status-overlay-bg:
    linear-gradient(180deg, rgba(255, 255, 255, 0.1), transparent 28%),
    linear-gradient(90deg, rgba(255, 255, 255, 0.06), transparent 16%, transparent 84%, rgba(140, 17, 95, 0.08));
  --status-text-color: #6c0f4d;
  --status-text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.18),
    0 0 6px rgba(255, 120, 214, 0.14);
}

.status-screen {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  position: relative;
  width: 100%;
  height: 100%;
  padding: 0 7px;
  border: 1px solid var(--status-screen-border);
  border-radius: 1px;
  background: var(--status-screen-bg);
  box-shadow: var(--status-screen-shadow);
  overflow: hidden;
  user-select: none;
  -webkit-user-select: none;
}

.status-side-slot {
  display: none;
}

.status-screen::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--status-overlay-bg);
  pointer-events: none;
}

.voice-status {
  position: relative;
  z-index: 1;
  display: inline-block;
  flex: 0 0 auto;
  min-width: max-content;
  white-space: nowrap;
  color: var(--status-text-color);
  font-family: "Palm Status", "Lucida Console", "Consolas", monospace;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1;
  text-transform: uppercase;
  text-shadow: var(--status-text-shadow);
  font-variant-numeric: tabular-nums;
  transform: translateY(1px);
  user-select: none;
  -webkit-user-select: none;
}

.status-ticker {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
  min-width: 100%;
  padding-right: 4px;
  will-change: transform;
}

.status-ticker.is-scrolling {
  justify-content: flex-start;
  animation: status-ticker-scroll var(--ticker-duration, 7s) linear infinite;
}

.voice-status-clone {
  display: none;
}

.status-ticker.is-scrolling .voice-status-clone {
  display: inline-block;
}

@keyframes status-ticker-scroll {
  from {
    transform: translateX(0);
  }

  to {
    transform: translateX(calc(-1 * var(--ticker-distance, 0px)));
  }
}

.shortcut-viewport {
  min-width: 0;
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  overflow: hidden;
  --shortcut-scale: 1;
}

.shortcut-strip {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--shortcut-gap);
  flex: 0 0 auto;
  width: max-content;
  min-width: max-content;
  padding-right: 1px;
  transform: scale(var(--shortcut-scale));
  transform-origin: right center;
}

.shortcut-strip span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: var(--shortcut-pill-pad-y) var(--shortcut-pill-pad-x);
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--muted);
  background: color-mix(in srgb, var(--panel-strong) 70%, var(--surface) 30%);
  font-size: var(--shortcut-pill-font);
  line-height: 1;
  white-space: nowrap;
}

.shortcut-action {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: var(--shortcut-pill-pad-y) var(--shortcut-pill-pad-x);
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--muted);
  background: color-mix(in srgb, var(--panel-strong) 70%, var(--surface) 30%);
  font-size: var(--shortcut-pill-font);
  line-height: 1;
  white-space: nowrap;
}

.shortcut-action:hover {
  border-color: var(--border-strong);
  color: var(--text);
}

kbd {
  padding: var(--kbd-pad-y) var(--kbd-pad-x);
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  font-size: var(--kbd-font);
  font-family: inherit;
  font-weight: 600;
}

.task-tree {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 4px 2px 14px;
  border-radius: 24px;
}

.task-tree.is-root-drop {
  outline: 2px dashed var(--border-strong);
  outline-offset: -10px;
}

.task-item {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.task-item + .task-item {
  margin-top: 10px;
}

.task-main {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto auto;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: color-mix(in srgb, var(--panel) 72%, var(--surface) 28%);
  overflow: hidden;
  transition:
    transform 140ms ease,
    border-color 140ms ease,
    background 140ms ease,
    box-shadow 140ms ease,
    opacity 140ms ease;
}

.task-main.is-collapsible {
  box-shadow: inset 2px 0 0 color-mix(in srgb, var(--border-strong) 32%, transparent);
}

.task-main.is-draggable {
  cursor: grab;
}

.task-main:hover {
  transform: translateY(-1px);
  border-color: var(--border-strong);
}

.task-main.is-selected {
  background: color-mix(in srgb, var(--panel-strong) 78%, var(--highlight) 22%);
  border-color: var(--border-strong);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.08);
}

body[data-theme="dark"] .task-main.is-selected {
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.28);
}

.task-main.is-done .task-label {
  color: var(--muted);
  text-decoration: line-through;
  text-decoration-thickness: 1.5px;
}

.task-main.is-collapsible.is-selected {
  box-shadow:
    0 10px 26px rgba(0, 0, 0, 0.08),
    inset 0 -1px 0 color-mix(in srgb, var(--border-strong) 36%, transparent);
}

.task-main.is-collapsed {
  border-bottom-left-radius: 14px;
  border-bottom-right-radius: 14px;
}

.task-main.is-dragging {
  opacity: 0.34;
  cursor: grabbing;
}

.task-main[data-drop-position="before"]::before,
.task-main[data-drop-position="after"]::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent 0%, var(--text) 12%, var(--text) 88%, transparent 100%);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--highlight) 45%, transparent);
}

.task-main[data-drop-position="before"]::before {
  top: 5px;
}

.task-main[data-drop-position="after"]::after {
  bottom: 5px;
}

.task-main[data-drop-position="before"],
.task-main[data-drop-position="after"] {
  border-color: var(--border-strong);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
}

.task-main[data-drop-position="inside"] {
  border-color: var(--text);
  box-shadow:
    inset 0 0 0 1px color-mix(in srgb, var(--text) 32%, transparent),
    0 10px 24px rgba(0, 0, 0, 0.08);
}

.task-progress-wash {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: var(--progress-width, 0%);
  background: var(--progress-color, transparent);
  opacity: 0.18;
  pointer-events: none;
}

.task-toggle,
.task-content,
.task-created-at,
.task-progress-badge,
.task-remove {
  position: relative;
  z-index: 1;
}

.task-toggle {
  width: 22px;
  height: 22px;
  border: 1.5px solid var(--border-strong);
  border-radius: 999px;
  background: transparent;
  position: relative;
  flex: 0 0 auto;
}

.task-main.is-done .task-toggle {
  background: var(--text);
  border-color: var(--text);
}

.task-main.is-done .task-toggle::after {
  content: "";
  position: absolute;
  inset: 5px;
  border-radius: 999px;
  background: var(--bg);
}

.task-content {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.task-content.is-leaf {
  gap: 0;
}

.task-label {
  display: block;
  width: 100%;
  overflow-wrap: anywhere;
  line-height: 1.35;
}

.task-edit-input {
  width: 100%;
  padding: 0;
  border: 0;
  outline: none;
  background: transparent;
  color: var(--text);
  font-size: 0.98rem;
}

.task-created-at {
  color: color-mix(in srgb, var(--text) 42%, transparent);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.task-progress-badge {
  min-width: 44px;
  padding: 4px 8px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--muted);
  background: color-mix(in srgb, var(--panel-strong) 72%, var(--surface) 28%);
  font-size: 0.72rem;
  font-weight: 700;
  text-align: center;
}

.task-progress-badge.is-hidden {
  opacity: 0;
}

.task-remove {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 1rem;
  font-weight: 700;
  opacity: 0;
  transition:
    opacity 120ms ease,
    background 120ms ease,
    color 120ms ease;
}

.task-main:hover .task-remove,
.task-main.is-selected .task-remove {
  opacity: 1;
}

.task-remove:hover {
  background: var(--surface-strong);
  color: var(--text);
}

.task-children {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-left: 20px;
  padding-left: 16px;
  border-left: 1px solid var(--border);
}

.task-item.is-collapsed > .task-children {
  display: none;
}

.empty-state {
  margin: auto 0;
  text-align: center;
  color: var(--muted);
  padding: 16px 10px 26px;
}

.empty-state.is-hidden {
  display: none;
}

.empty-title {
  margin: 0 0 8px;
  color: var(--text);
  font-size: 1.1rem;
  font-weight: 700;
}

.empty-copy {
  margin: 0;
  line-height: 1.5;
}

body.is-hints-hidden .brand-title {
  display: none;
}

body.is-hints-hidden .brand-meta {
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

body.is-hints-hidden .empty-copy {
  display: none;
}

body.is-hints-hidden .window-bar,
body.is-hints-hidden .utility-row,
body.is-hints-hidden .shortcut-strip,
body.is-hints-hidden .icon-button.is-primary {
  display: none;
}

body.is-hints-hidden .app-shell {
  gap: 6px;
  padding: 8px;
}

body.is-hints-hidden .composer-card {
  gap: 0;
  padding: 6px 8px;
  border-radius: 18px;
  border-color: color-mix(in srgb, var(--border) 62%, transparent);
  background: color-mix(in srgb, var(--panel) 90%, transparent);
  box-shadow: 0 14px 34px rgba(17, 17, 17, 0.05);
  backdrop-filter: blur(14px);
}

body.is-hints-hidden .composer {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 6px;
  align-items: center;
}

body.is-hints-hidden .composer-input {
  min-height: 42px;
  max-height: 116px;
  padding: 10px 14px;
  border-radius: 14px;
  background: color-mix(in srgb, var(--panel-strong) 84%, transparent);
  font-size: 0.96rem;
  line-height: 1.28;
}

body.is-hints-hidden .composer-input:focus {
  box-shadow: 0 0 0 3px var(--highlight);
}

body.is-hints-hidden .icon-button {
  width: 40px;
  height: 40px;
  border-color: color-mix(in srgb, var(--border) 58%, transparent);
}

body.is-hints-hidden .voice-button {
  align-self: center;
  margin-top: -2px;
}

body.is-hints-hidden .task-tree {
  padding-top: 0;
}

body.is-focus-mode .app-shell {
  gap: 10px;
  padding: 10px;
}

body.is-focus-mode .composer-card {
  gap: 8px;
  padding: 10px;
  border-radius: 22px;
}

body.is-focus-mode .window-bar {
  min-height: 26px;
}

body.is-focus-mode .brand-title {
  display: none;
}

body.is-focus-mode .brand-meta {
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

body.is-focus-mode .chrome-button,
body.is-focus-mode .icon-button,
body.is-focus-mode .search-shell,
body.is-focus-mode .status-radio {
  height: 34px;
}

body.is-focus-mode .chrome-button {
  padding: 0 11px;
}

body.is-focus-mode .button-label {
  font-size: 0.78rem;
}

body.is-focus-mode .composer {
  gap: 8px;
}

body.is-focus-mode .composer-input {
  min-height: 46px;
  max-height: 124px;
  padding: 12px 16px;
  border-radius: 16px;
}

body.is-focus-mode .task-tree {
  padding-top: 0;
}

body.is-focus-mode .task-item,
body.is-focus-mode .task-item + .task-item,
body.is-focus-mode .task-children {
  gap: 8px;
}

body.is-focus-mode .task-main {
  min-height: 46px;
  padding: 8px 10px;
  border-radius: 16px;
  gap: 10px;
}

body.is-focus-mode .task-label,
body.is-focus-mode .task-edit-input {
  font-size: 1.02rem;
}

body.is-focus-mode .task-created-at {
  font-size: 0.64rem;
}

body.is-focus-mode .task-progress-badge {
  min-width: 38px;
  padding: 3px 7px;
}

body.is-focus-mode .empty-copy {
  display: none;
}

body.is-focus-mode .empty-title {
  font-size: 0.96rem;
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.03);
  }
}

@keyframes status-scan {
  from {
    transform: translateX(-160%);
  }

  to {
    transform: translateX(380%);
  }
}

@media (max-width: 520px) {
  .app-shell {
    padding: 10px;
    gap: 10px;
  }

  .composer-card {
    padding: 10px;
    border-radius: 22px;
  }

  .utility-row {
    grid-template-columns: 1fr;
  }

  .utility-main {
    gap: 6px;
  }

  .search-shell {
    flex-basis: var(--search-shell-width);
  }

  .voice-status {
    white-space: normal;
  }

  .status-radio {
    width: auto;
    min-width: 150px;
    max-width: 168px;
  }

  .task-main {
    grid-template-columns: auto minmax(0, 1fr) auto auto;
  }

  .task-created-at {
    display: none;
  }
}

@media (max-width: 560px) {
  .window-bar {
    flex-wrap: wrap;
    align-items: flex-start;
  }

  .brand-lockup {
    flex: 1 1 auto;
    min-width: 0;
  }

  .window-controls {
    width: 100%;
    justify-content: flex-end;
  }
}

@media (max-width: 420px) {
  .window-bar {
    gap: 8px;
  }

  .brand-lockup {
    gap: 8px;
  }

  .brand-title {
    font-size: 0.88rem;
  }

  .brand-meta {
    font-size: 0.74rem;
  }

  .window-controls {
    width: 100%;
    justify-content: flex-end;
    gap: 8px;
  }

  .status-radio {
    min-width: 146px;
    max-width: 146px;
  }

  .theme-toggle {
    min-width: 148px;
    height: 32px;
  }

  .theme-choice {
    height: 22px;
    padding: 0 6px;
    font-size: 0.54rem;
  }
}

textarea {
  font: inherit;
}

.browser-app .utility-icon-button {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  font-size: 0.92rem;
  font-weight: 800;
  line-height: 1;
  background: var(--panel-strong);
}

.browser-app .compact-toggle-button {
  letter-spacing: 0.06em;
}

.browser-app .help-modal {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: grid;
  align-items: end;
  justify-items: stretch;
}

.browser-app .help-modal[hidden] {
  display: none !important;
}

.browser-app .help-backdrop {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: rgba(12, 14, 16, 0.42);
  backdrop-filter: blur(8px);
}

.browser-app .help-sheet {
  position: relative;
  z-index: 1;
  margin: 0;
  padding: 18px 18px calc(18px + env(safe-area-inset-bottom));
  border-top-left-radius: 26px;
  border-top-right-radius: 26px;
  background: color-mix(in srgb, var(--panel-strong) 88%, var(--surface) 12%);
  box-shadow: 0 -18px 44px rgba(0, 0, 0, 0.16);
  display: grid;
  gap: 14px;
  transition: transform 180ms ease;
  touch-action: pan-y;
}

.browser-app .help-sheet-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.browser-app .help-sheet-eyebrow {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.browser-app .help-sheet-head h2 {
  margin: 0;
  font-size: 1.08rem;
  line-height: 1.15;
}

.browser-app .help-sheet-copy {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.browser-app .help-dismiss-copy {
  margin: 8px 0 0;
  color: color-mix(in srgb, var(--text) 54%, transparent);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.browser-app .help-close-button,
.browser-app .modal-theme-toggle {
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: color-mix(in srgb, var(--panel-strong) 82%, var(--surface) 18%);
  color: var(--text);
  font-size: 0.86rem;
  font-weight: 700;
}

.browser-app .help-close-button {
  position: relative;
  isolation: isolate;
  min-width: 86px;
  border-color: color-mix(in srgb, #8ec8ff 42%, var(--border));
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(239, 247, 255, 0.94)),
    color-mix(in srgb, var(--panel-strong) 84%, var(--surface) 16%);
  box-shadow:
    0 0 0 1px rgba(120, 188, 255, 0.18),
    0 10px 22px rgba(66, 128, 189, 0.14);
  overflow: visible;
  touch-action: manipulation;
}

.browser-app .help-close-button::before {
  content: "";
  position: absolute;
  inset: -7px;
  border: 2px solid rgba(124, 196, 255, 0.56);
  border-radius: 18px;
  box-shadow:
    0 0 0 3px rgba(124, 196, 255, 0.12),
    0 0 18px rgba(124, 196, 255, 0.22);
  opacity: 0.9;
  animation: help-done-glow 1.7s ease-in-out infinite;
  pointer-events: none;
}

.browser-app .help-close-button::after {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: 12px;
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.74), rgba(255, 255, 255, 0));
  opacity: 0.46;
  pointer-events: none;
}

.browser-app .help-close-label {
  position: relative;
  z-index: 1;
}

.browser-app .help-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.browser-app .help-card {
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: color-mix(in srgb, var(--panel-strong) 78%, var(--surface) 22%);
}

.browser-app .help-card p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.48;
}

.browser-app .help-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--text) 8%, transparent);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.browser-app .touch-drag-ghost {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 40;
  max-width: min(76vw, 280px);
  padding: 10px 14px;
  border: 1px solid var(--border-strong);
  border-radius: 16px;
  background: color-mix(in srgb, var(--panel-strong) 88%, var(--surface) 12%);
  color: var(--text);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.14);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  pointer-events: none;
}

.browser-app.is-browser-mobile {
  overscroll-behavior-y: contain;
}

.browser-app.is-browser-mobile .app-shell {
  padding:
    max(10px, env(safe-area-inset-top))
    10px
    max(14px, env(safe-area-inset-bottom))
    10px;
  gap: 10px;
}

.browser-app.is-browser-mobile .composer-card {
  gap: 8px;
  padding: 10px;
  border-radius: 24px;
}

.browser-app.is-browser-mobile .window-bar {
  align-items: center;
}

.browser-app.is-browser-mobile .window-controls {
  gap: 8px;
}

.browser-app.is-browser-mobile .theme-toggle {
  display: none;
}

.browser-app.is-browser-mobile .status-radio {
  min-width: clamp(140px, 38vw, 176px);
  max-width: clamp(140px, 38vw, 176px);
}

.browser-app.is-browser-mobile .shortcut-viewport {
  display: none;
}

.browser-app.is-browser-mobile .utility-row {
  grid-template-columns: 1fr;
}

.browser-app.is-browser-mobile .utility-main {
  gap: 0;
}

.browser-app.is-browser-mobile .search-shell {
  width: 100%;
  min-width: 0;
  flex: 1 1 auto;
}

.browser-app.is-browser-mobile .composer {
  gap: 8px;
}

.browser-app.is-browser-mobile .composer-input {
  min-height: 48px;
  max-height: 132px;
}

.browser-app.is-browser-mobile .task-tree {
  padding: 0 0 12px;
}

.browser-app.is-browser-mobile .task-main {
  min-height: 60px;
  padding: 10px 12px;
  touch-action: pan-y;
}

.browser-app.is-browser-mobile .task-remove {
  opacity: 1;
}

.browser-app.is-browser-mobile .task-created-at {
  font-size: 0.64rem;
}

.browser-app.is-browser-mobile.is-hints-hidden .window-bar {
  display: flex;
  justify-content: space-between;
}

.browser-app.is-browser-mobile.is-hints-hidden .brand-lockup {
  display: none;
}

.browser-app.is-browser-mobile.is-hints-hidden .icon-button.is-primary {
  display: inline-flex;
}

.browser-app.is-browser-mobile.is-hints-hidden .composer-card {
  gap: 8px;
  padding: 10px;
  border-radius: 22px;
}

.browser-app.is-browser-mobile.is-hints-hidden .composer {
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 8px;
}

.browser-app.is-browser-mobile.is-hints-hidden .composer-input {
  min-height: 46px;
  max-height: 126px;
  padding: 12px 14px;
  font-size: 0.98rem;
}

.browser-app.is-browser-mobile.is-hints-hidden .utility-row {
  display: none;
}

.browser-app.is-browser-mobile.is-hints-hidden .task-tree {
  padding-top: 0;
}

.browser-app.is-browser-mobile.is-hints-hidden .empty-copy {
  display: none;
}

.browser-app.is-browser-mobile.is-help-open .task-tree {
  pointer-events: none;
}

@media (max-width: 560px) {
  .browser-app .help-grid {
    grid-template-columns: 1fr;
  }
}

@keyframes help-done-glow {
  0%,
  100% {
    transform: scale(0.98);
    opacity: 0.72;
  }

  50% {
    transform: scale(1.02);
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .browser-app .help-close-button::before {
    animation: none;
  }
}
