[data-ui=instrument] .topbar {
  height: 44px;
}
[data-ui=instrument] .filterbar {
  height: 40px;
}
[data-ui=instrument] .topbar-nav-on {
  box-shadow: inset 0 -2px 0 var(--accent);
}
[data-ui=instrument] .detail-tab-on {
  box-shadow: inset 0 -2px 0 var(--accent);
}
[data-ui=instrument] .board-columns {
  gap: 0;
}
[data-ui=instrument] .column {
  background: transparent;
  border-right: 1px solid var(--border);
}
[data-ui=instrument] .column:last-child {
  border-right: none;
}
[data-ui=instrument] .chip {
  background: transparent;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
[data-ui=instrument] .chip::before {
  content: "";
  width: 6px;
  height: 6px;
  margin-right: 6px;
  flex: none;
  background: currentColor;
}
[data-ui=instrument] .avatar {
  width: 18px;
  height: 18px;
  border-radius: 2px;
  border: none;
}
[data-ui=instrument] .avatar + .avatar {
  margin-left: -4px;
}
[data-ui=instrument] .avatar-upload::after {
  border-radius: 2px;
}
[data-ui=instrument] .avatar-none {
  border: 1px dashed var(--border-strong);
  background: transparent;
}
[data-ui=instrument] .primary {
  background: transparent;
  border: 1px solid var(--accent-border);
  color: var(--accent);
}
[data-ui=instrument] .primary:hover {
  background: transparent;
  border-color: var(--accent);
  color: var(--accent);
}
[data-ui=instrument] .quiet {
  background: transparent;
}
[data-ui=instrument] .comment-when {
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
[data-ui=instrument] .card-comments,
[data-ui=instrument] .card-deadline {
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
[data-ui=instrument] .member-status {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
[data-ui=instrument] .member-you {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: var(--radius-sm);
}
[data-ui=instrument] .log-row {
  padding: 6px 2px;
}
[data-ui=instrument] .settings-sections {
  width: 200px;
}
[data-ui=instrument] .settings-section-link {
  font-size: 13px;
  letter-spacing: normal;
  text-transform: none;
}
[data-ui=instrument] .settings-section-link.active {
  background: var(--row-hover);
  box-shadow: inset 2px 0 0 var(--accent);
}

[data-ui=instrument] .modal-scrim:has(> .modal-task) {
  background: color-mix(in srgb, var(--scrim) 65%, transparent);
  justify-content: flex-end;
  padding: 0;
}

[data-ui=instrument] .modal-task {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 560px;
  max-width: 100%;
  max-height: none;
  background: var(--surface);
  border: none;
  border-radius: 0;
  box-shadow: var(--shadow-3);
}

[data-ui=instrument] .modal-task .detail-head {
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
}

[data-ui=instrument] .detail-tabs {
  padding: 0 16px;
}

[data-ui=instrument] .detail-state,
[data-ui=instrument] .detail-board {
  display: none;
}

[data-ui=instrument] .detail-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 20px;
}

[data-ui=instrument] .detail-title {
  font-size: 20px;
}

[data-ui=instrument] .detail-fields {
  gap: 10px;
  padding: 0 16px 14px;
  margin-top: 14px;
}

[data-ui=instrument] .detail-block {
  margin-top: 18px;
}

[data-ui=instrument] .detail-foot {
  padding: 14px 20px;
  margin-top: 0;
  border-top: 1px solid var(--border);
}

[data-ui=instrument] .comment-composer {
  flex: none;
  padding: 14px 20px;
  border-top: 1px solid var(--border);
}

@media (max-width: 620px) {
  [data-ui=instrument] .settings-sections {
    width: auto;
  }
  [data-ui=instrument] .settings-section-link.active {
    background: none;
    box-shadow: inset 0 -2px 0 var(--accent);
  }
  [data-ui=instrument] .filterbar {
    height: auto;
  }
  [data-ui=instrument] .modal-task .detail-esc {
    display: none;
  }
}
[data-ui=ledger] .auth-title,
[data-ui=ledger] .settings-title,
[data-ui=ledger] .detail-title,
[data-ui=ledger] .title-input,
[data-ui=ledger] .panel-title,
[data-ui=ledger] .column-name,
[data-ui=ledger] .card-title,
[data-ui=ledger] .member-name {
  font-family: var(--font-display);
}
[data-ui=ledger] .settings-title {
  font-size: 22px;
}
[data-ui=ledger] .panel-title {
  font-size: 15px;
}
[data-ui=ledger] .card-title {
  font-size: 16px;
}
[data-ui=ledger] .panel {
  background: transparent;
  border: none;
  box-shadow: none;
}
[data-ui=ledger] .panel-head {
  border-bottom: 2px solid var(--rule-strong);
  padding: 0 0 10px;
}
[data-ui=ledger] .auth-card {
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
}
[data-ui=ledger] .column {
  background: transparent;
  border-radius: 0;
}
[data-ui=ledger] .column-empty {
  background: transparent;
  border-color: var(--border-soft);
}
[data-ui=ledger] .column-head {
  padding: 2px 4px 8px;
  border-bottom: 2px solid var(--rule-strong);
}
[data-ui=ledger] .card {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  box-shadow: none;
  padding: 12px 2px 14px 2px;
  transition: border-color var(--dur-fast) var(--ease);
}
[data-ui=ledger] .card:hover {
  background: transparent;
  border-bottom-color: var(--rule-strong);
}
[data-ui=ledger] .card-done {
  background: transparent;
}
[data-ui=ledger] .card-done .card-title {
  text-decoration: line-through;
}
[data-ui=ledger] .column-cards {
  gap: 0;
}
[data-ui=ledger] .rule-row {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  padding: 14px 2px;
}
[data-ui=ledger] .rule-row-off {
  background: transparent;
}
[data-ui=ledger] .tag-row {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  padding: 14px 2px;
}
[data-ui=ledger] .log-row {
  border-bottom: 1px solid var(--border);
}
[data-ui=ledger] .log-actor {
  font-family: var(--font-display);
}
[data-ui=ledger] .topbar {
  background: transparent;
  border-bottom: 1px solid var(--rule-strong);
}
[data-ui=ledger] .topbar-nav-on {
  border-bottom: 2px solid var(--rule-strong);
  box-shadow: none;
}
[data-ui=ledger] .detail-tab-on {
  border-bottom: 2px solid var(--ink);
  box-shadow: none;
}
[data-ui=ledger] .chip {
  display: inline-flex;
  align-items: baseline;
  height: auto;
  padding: 0;
  background: transparent;
  border: none;
  border-bottom: 1px dotted currentColor;
  border-radius: 0;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
[data-ui=ledger] .chip-overdue, [data-ui=ledger] .chip-blocked, [data-ui=ledger] .chip-role, [data-ui=ledger] .chip-admin, [data-ui=ledger] .chip-connected, [data-ui=ledger] .chip-off {
  background: transparent;
}
[data-ui=ledger] .chip-role, [data-ui=ledger] .chip-admin {
  border: none;
  border-bottom: 1px dotted currentColor;
}
[data-ui=ledger] .chip-role, [data-ui=ledger] .chip-admin, [data-ui=ledger] .chip-connected, [data-ui=ledger] .chip-off {
  text-transform: uppercase;
}
[data-ui=ledger] .primary {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--bg);
}
[data-ui=ledger] .primary:hover {
  background: var(--ink-soft);
  border-color: var(--ink-soft);
  color: var(--bg);
}
[data-ui=ledger] .auth-submit,
[data-ui=ledger] .edit-save,
[data-ui=ledger] .comment-post {
  background: var(--ink);
  color: var(--bg);
}
[data-ui=ledger] .auth-submit:hover,
[data-ui=ledger] .edit-save:hover,
[data-ui=ledger] .comment-post:hover {
  background: var(--ink-soft);
}
[data-ui=ledger] .quiet {
  background: transparent;
  border-color: var(--ink-soft);
}
[data-ui=ledger] .quiet:hover {
  border-color: var(--ink);
  color: var(--ink);
}
[data-ui=ledger] .quiet-danger {
  border-color: var(--danger);
}
[data-ui=ledger] .quiet-danger:hover {
  border-color: var(--danger);
  background: transparent;
}
[data-ui=ledger] .detail-delete {
  background: transparent;
  border-color: var(--danger);
}
[data-ui=ledger] .auth-input,
[data-ui=ledger] .field-input,
[data-ui=ledger] .title-input {
  background: transparent;
  border-color: var(--ink-soft);
}
[data-ui=ledger] .auth-input:focus-visible,
[data-ui=ledger] .field-input:focus-visible,
[data-ui=ledger] .title-input:focus-visible {
  background: transparent;
  border-color: var(--ink);
}
[data-ui=ledger] .auth-input:disabled,
[data-ui=ledger] .field-input:disabled,
[data-ui=ledger] .title-input:disabled {
  background: transparent;
}
[data-ui=ledger] .auth-locked,
[data-ui=ledger] .field-box,
[data-ui=ledger] .status-form {
  background: transparent;
  border-color: var(--ink-soft);
}
[data-ui=ledger] .rule-switch {
  width: 14px;
  height: 14px;
  border: 1px solid var(--ink);
  border-radius: 0;
  background: transparent;
}
[data-ui=ledger] .rule-switch .rule-switch-knob {
  display: none;
}
[data-ui=ledger] .rule-switch-on {
  background: var(--ink);
}

[data-ui=ledger] .modal-scrim:has(> .modal-task) {
  background: var(--bg);
  justify-content: center;
  padding: 0 40px;
}

[data-ui=ledger] .modal-task {
  position: static;
  width: 720px;
  max-width: 100%;
  max-height: none;
  overflow: visible;
  display: block;
  background: transparent;
  border: none;
  border-radius: 0;
  box-shadow: none;
}

[data-ui=ledger] .detail-body {
  overflow: visible;
}

[data-ui=ledger] .modal-task .detail-head {
  align-items: center;
  gap: 12px;
  padding: 0;
}

[data-ui=ledger] .detail-tabs {
  padding: 0;
  margin-top: 14px;
}

[data-ui=ledger] .detail-mast {
  position: sticky;
  top: 0;
  z-index: 2;
  padding: 36px 0 6px;
  background: var(--bg);
}

[data-ui=ledger] .modal-task .detail-esc,
[data-ui=ledger] .modal-task .detail-close,
[data-ui=ledger] .detail-body .detail-field-status {
  display: none;
}

[data-ui=ledger] .dep-row {
  border: 0;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  background: transparent;
}

[data-ui=ledger] .modal-task .detail-key {
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: underline dotted;
  text-underline-offset: 3px;
}

[data-ui=ledger] .detail-state {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

[data-ui=ledger] .detail-state .field-box,
[data-ui=ledger] .detail-state .status-form {
  height: auto;
  padding: 0;
  background: transparent;
  border: none;
  font: inherit;
  color: var(--ink);
}

[data-ui=ledger] .detail-state .status-select {
  width: auto;
  flex: none;
  font: inherit;
  text-transform: uppercase;
}

[data-ui=ledger] .detail-state .status-dot {
  display: none;
}

[data-ui=ledger] .detail-board {
  margin-left: auto;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink);
  background: transparent;
  border: none;
  height: auto;
}

[data-ui=ledger] .detail-head .detail-title,
[data-ui=ledger] .title-form {
  padding-bottom: 10px;
  border-bottom: 2px solid var(--ink);
}

[data-ui=ledger] .detail-title {
  font-family: var(--font-serif, Georgia, serif);
  font-size: 32px;
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: 0;
}

[data-ui=ledger] .title-input {
  height: auto;
  padding: 0;
  border: none;
  background: transparent;
  font-family: var(--font-serif, Georgia, serif);
  font-size: 32px;
  font-weight: 400;
}

[data-ui=ledger] .detail-fields {
  display: block;
  padding: 0;
  margin-top: 14px;
  border-top: 1px solid var(--border);
}

[data-ui=ledger] .detail-field {
  display: flex;
  flex-direction: row;
  align-items: baseline;
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

[data-ui=ledger] .detail-field > .detail-label {
  flex: none;
  width: 130px;
}

[data-ui=ledger] .detail-field .field-box,
[data-ui=ledger] .detail-field .status-form {
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
  height: auto;
}

[data-ui=ledger] .detail-field .status-dot {
  display: none;
}

[data-ui=ledger] .detail-block {
  margin-top: 24px;
}

[data-ui=ledger] .comment-list {
  border-top: 1px solid var(--border);
}

[data-ui=ledger] .detail-foot,
[data-ui=ledger] .comment-composer {
  position: sticky;
  bottom: 0;
  margin-top: 24px;
  padding: 16px 0 36px;
  background: var(--bg);
  border-top: 1px solid var(--border);
}

[data-ui=ledger] .settings-sections {
  width: 170px;
}

[data-ui=ledger] .settings-section-link.active {
  border-bottom: 2px solid var(--ink);
}

@media (max-width: 620px) {
  [data-ui=ledger] .modal-scrim:has(> .modal-task) {
    padding: 0 12px;
  }
  [data-ui=ledger] .detail-mast {
    padding: 20px 0 6px;
  }
  [data-ui=ledger] .detail-title,
[data-ui=ledger] .title-input {
    font-size: 24px;
  }
  [data-ui=ledger] .detail-field {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
  }
  [data-ui=ledger] .detail-field > .detail-label {
    width: auto;
  }
  [data-ui=ledger] .settings-sections {
    width: auto;
  }
}
:root,
[data-ui=instrument] {
  color-scheme: light;
  --bg: #f2f2f0;
  --surface: #fbfbfa;
  --border: #dcdcd8;
  --border-strong: #d0d0cb;
  --ink: #1a1b1d;
  --muted: #6b7078;
  --muted-soft: #6b7078;
  --accent: #46557b;
  --accent-tint: #eef0f5;
  --accent-ink: #2f3c5c;
  --field-bg: #f5f5f3;
  --surface-sunken: #e9e9e7;
  --surface-muted: #f5f5f3;
  --ink-soft: #3d4045;
  --row-hover: #ececea;
  --panel-sunken: #eeeeec;
  --border-soft: #d3d3ce;
  --scrim: rgba(26, 27, 29, 0.46);
  --danger: #a04a24;
  --danger-tint: #f9ece4;
  --danger-tint-soft: #fdf6f2;
  --danger-tint-alt: #fbf1ec;
  --danger-border: #e8c9b8;
  --danger-border-soft: #eddcd3;
  --danger-border-alt: #ecd0bf;
  --warn-ink: #7a5c1e;
  --warn-tint: #f7f0dd;
  --warn-tint-soft: #fdfaf1;
  --warn-border: #e6d7ae;
  --positive: #5c7b46;
  --positive-ink: #4a6636;
  --positive-tint: #eef3e9;
  --positive-border: #d3e0c6;
  --accent-strong: #5a6a94;
  --accent-border: #d6dbe8;
  --accent-border-strong: #d8dce6;
  --avatar-tone-1: #7b6846;
  --avatar-tone-3: #7b4655;
  --avatar-tone-4: #46707b;
  --violet-tint: #f1eaf7;
  --violet-border: #ddc4ec;
  --violet-ink: #6a3f82;
  --font-sans: system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;
  --font-display: var(--font-sans);
  --control-h: 32px;
  --control-h-lg: 40px;
  --rule-strong: #d0d0cb;
  --radius: 3px;
  --radius-sm: var(--radius);
  --radius-md: 3px;
  --radius-lg: 3px;
  --topbar-height: 56px;
  --shadow-1: none;
  --shadow-2: none;
  --shadow-3: none;
  --dur-fast: 120ms;
  --ease: ease-out;
}

[data-ui=instrument][data-theme=dark] {
  color-scheme: dark;
  --bg: #0d0e10;
  --surface: #14161a;
  --border: #23262c;
  --border-strong: #2e323a;
  --ink: #e6e4de;
  --muted: #7d8590;
  --muted-soft: #4a4f58;
  --accent: #8ba1e8;
  --accent-tint: rgba(139, 161, 232, 0.14);
  --accent-ink: #b9c6ee;
  --field-bg: #101216;
  --surface-sunken: #101216;
  --surface-muted: #0f1013;
  --ink-soft: #c9c7c0;
  --row-hover: #1a1d22;
  --panel-sunken: #101216;
  --border-soft: #1f2226;
  --scrim: rgba(0, 0, 0, 0.75);
  --danger: #e0906a;
  --danger-tint: rgba(224, 144, 106, 0.13);
  --danger-tint-soft: rgba(224, 144, 106, 0.07);
  --danger-tint-alt: rgba(224, 144, 106, 0.05);
  --danger-border: rgba(224, 144, 106, 0.45);
  --danger-border-soft: rgba(224, 144, 106, 0.3);
  --danger-border-alt: rgba(224, 144, 106, 0.35);
  --warn-ink: #d4b16a;
  --warn-tint: rgba(212, 177, 106, 0.14);
  --warn-tint-soft: rgba(212, 177, 106, 0.07);
  --warn-border: rgba(212, 177, 106, 0.4);
  --positive: #9db98a;
  --positive-ink: #b4cba3;
  --positive-tint: rgba(157, 185, 138, 0.13);
  --positive-border: rgba(157, 185, 138, 0.4);
  --accent-strong: #7e93d9;
  --accent-border: #3a4152;
  --accent-border-strong: #2b3b63;
  --avatar-tone-1: #937d58;
  --avatar-tone-3: #96606e;
  --avatar-tone-4: #5b93a1;
  --violet-tint: rgba(185, 138, 151, 0.14);
  --violet-border: rgba(185, 138, 151, 0.4);
  --violet-ink: #b98a97;
  --font-sans: system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;
  --font-display: var(--font-sans);
  --control-h: 32px;
  --control-h-lg: 40px;
  --rule-strong: #2e323a;
  --radius: 3px;
  --radius-sm: var(--radius);
  --radius-md: 3px;
  --radius-lg: 3px;
  --topbar-height: 56px;
  --shadow-1: none;
  --shadow-2: none;
  --shadow-3: none;
  --dur-fast: 120ms;
  --ease: ease-out;
}

[data-ui=ledger] {
  color-scheme: light;
  --bg: #f6f1e6;
  --surface: #f6f1e6;
  --border: #ddd5c2;
  --border-strong: #221f18;
  --ink: #221f18;
  --muted: #7a7466;
  --muted-soft: #a39b88;
  --accent: #46557b;
  --accent-tint: #eef0f5;
  --accent-ink: #2f3c5c;
  --field-bg: #f1ebdd;
  --surface-sunken: #efe9da;
  --surface-muted: #f2ecdf;
  --ink-soft: #4a453a;
  --row-hover: #efe9da;
  --panel-sunken: #f1ebdd;
  --border-soft: #cfc6b0;
  --scrim: rgba(34, 31, 24, 0.46);
  --danger: #a04a24;
  --danger-tint: #f9ece4;
  --danger-tint-soft: #fdf6f2;
  --danger-tint-alt: #fbf1ec;
  --danger-border: #e8c9b8;
  --danger-border-soft: #eddcd3;
  --danger-border-alt: #ecd0bf;
  --warn-ink: #7a5c1e;
  --warn-tint: #f7f0dd;
  --warn-tint-soft: #fdfaf1;
  --warn-border: #e6d7ae;
  --positive: #5c7b46;
  --positive-ink: #4a6636;
  --positive-tint: #eef3e9;
  --positive-border: #d3e0c6;
  --accent-strong: #5a6a94;
  --accent-border: #d6dbe8;
  --accent-border-strong: #d8dce6;
  --avatar-tone-1: #7b6846;
  --avatar-tone-3: #7b4655;
  --avatar-tone-4: #46707b;
  --violet-tint: #f1eaf7;
  --violet-border: #ddc4ec;
  --violet-ink: #6a3f82;
  --font-sans: system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;
  --font-display: "Newsreader", Georgia, serif;
  --control-h: 32px;
  --control-h-lg: 40px;
  --rule-strong: #221f18;
  --radius: 2px;
  --radius-sm: var(--radius);
  --radius-md: 2px;
  --radius-lg: 2px;
  --topbar-height: 56px;
  --shadow-1: none;
  --shadow-2: none;
  --shadow-3: none;
  --dur-fast: 120ms;
  --ease: ease-out;
}

[data-ui=ledger][data-theme=dark] {
  color-scheme: dark;
  --bg: #171511;
  --surface: #171511;
  --border: #3a352a;
  --border-strong: #e8e2d4;
  --ink: #e8e2d4;
  --muted: #97907f;
  --muted-soft: #6e6757;
  --accent: #9db0dd;
  --accent-tint: rgba(157, 176, 221, 0.14);
  --accent-ink: #c3cfee;
  --field-bg: #1c1915;
  --surface-sunken: #14120e;
  --surface-muted: #1c1915;
  --ink-soft: #cfc8b6;
  --row-hover: #201c16;
  --panel-sunken: #1b1814;
  --border-soft: #2e2a20;
  --scrim: rgba(0, 0, 0, 0.75);
  --danger: #d28a5a;
  --danger-tint: rgba(210, 138, 90, 0.13);
  --danger-tint-soft: rgba(210, 138, 90, 0.07);
  --danger-tint-alt: rgba(210, 138, 90, 0.05);
  --danger-border: rgba(210, 138, 90, 0.45);
  --danger-border-soft: rgba(210, 138, 90, 0.3);
  --danger-border-alt: rgba(210, 138, 90, 0.35);
  --warn-ink: #d4b16a;
  --warn-tint: rgba(212, 177, 106, 0.14);
  --warn-tint-soft: rgba(212, 177, 106, 0.07);
  --warn-border: rgba(212, 177, 106, 0.4);
  --positive: #a3bd8b;
  --positive-ink: #b8cda4;
  --positive-tint: rgba(163, 189, 139, 0.13);
  --positive-border: rgba(163, 189, 139, 0.4);
  --accent-strong: #8497c9;
  --accent-border: #3f4658;
  --accent-border-strong: #2c3550;
  --avatar-tone-1: #937d58;
  --avatar-tone-3: #96606e;
  --avatar-tone-4: #5b93a1;
  --violet-tint: rgba(201, 163, 222, 0.14);
  --violet-border: rgba(201, 163, 222, 0.4);
  --violet-ink: #c9a3de;
  --font-sans: system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;
  --font-display: "Newsreader", Georgia, serif;
  --control-h: 32px;
  --control-h-lg: 40px;
  --rule-strong: #e8e2d4;
  --radius: 2px;
  --radius-sm: var(--radius);
  --radius-md: 2px;
  --radius-lg: 2px;
  --topbar-height: 56px;
  --shadow-1: none;
  --shadow-2: none;
  --shadow-3: none;
  --dur-fast: 120ms;
  --ease: ease-out;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 13px;
}

body:has(.board-stage) {
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
body:has(.board-stage) > * {
  flex: none;
}
body:has(.board-stage) > .board-stage {
  flex: 1;
  min-height: 0;
}

body:has(.settings-shell) {
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
body:has(.settings-shell) > * {
  flex: none;
}
body:has(.settings-shell) > .settings-shell {
  flex: 1;
  min-height: 0;
}

body:has(.people-shell) {
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
body:has(.people-shell) > * {
  flex: none;
}
body:has(.people-shell) > .people-shell {
  flex: 1;
  min-height: 0;
}

body:has(.auth-stage) {
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
body:has(.auth-stage) > * {
  flex: none;
}
body:has(.auth-stage) > .auth-stage {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  scrollbar-width: none;
}
body:has(.auth-stage) > .auth-stage::-webkit-scrollbar {
  display: none;
}

a {
  color: var(--accent);
  transition: color var(--dur-fast) var(--ease);
}
a:hover {
  color: var(--accent-ink);
}

.topbar {
  height: var(--topbar-height);
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 24px;
}

.wordmark {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
}
.wordmark:hover {
  color: inherit;
}
.wordmark-mark {
  flex: none;
  display: block;
  width: 24px;
  height: 24px;
}
.wordmark-lone .wordmark-text {
  font-size: 18px;
  letter-spacing: 0.01em;
}
.wordmark-tittle {
  fill: var(--accent);
}
.wordmark-text {
  font-family: var(--font-mono);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.topbar-divider {
  width: 1px;
  height: 20px;
  background: var(--border);
}

.topbar-nav-links {
  display: flex;
  gap: 16px;
  margin-left: auto;
}

.topbar > .spacer {
  display: none;
}

.topbar-nav {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  white-space: nowrap;
  padding-bottom: 2px;
}
.topbar-nav:hover {
  color: var(--ink);
}
.topbar-nav-on {
  color: var(--ink);
  box-shadow: inset 0 -2px 0 var(--ink);
}

.scaffold-note {
  margin: 24px;
  padding: 20px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  color: var(--muted);
}

.auth-stage {
  min-height: calc(100vh - var(--topbar-height));
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 40px 40px;
}

.auth-column {
  width: 520px;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.auth-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 28px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  box-shadow: var(--shadow-2);
}
.auth-card form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.auth-head {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.auth-title {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.auth-sub {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
}

.auth-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.auth-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--muted-soft);
}

.auth-locked {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 12px;
  background: var(--panel-sunken);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
}

.auth-locked-value {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--muted);
  flex-grow: 1;
}

.auth-submit {
  height: var(--control-h-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--accent);
  color: var(--surface);
  border: 0;
  border-radius: var(--radius);
  cursor: pointer;
  font-family: var(--font-sans);
}
.auth-submit:disabled {
  opacity: 0.45;
  cursor: default;
}

.auth-submit-text {
  font-size: 13px;
  font-weight: 600;
}

.auth-key {
  font-family: var(--font-mono);
  font-size: 10px;
  background: var(--accent-strong);
  border-radius: var(--radius-sm);
  padding: 1px 4px;
}

.auth-problem {
  font-size: 13px;
  color: var(--danger);
  background: var(--danger-tint-alt);
  border: 1px solid var(--danger-border-soft);
  border-radius: var(--radius);
  padding: 10px 12px;
}

.auth-note {
  font-size: 13px;
  color: var(--muted);
  background: var(--panel-sunken);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 10px 12px;
}

.auth-alt {
  font-size: 12px;
  color: var(--muted);
  text-decoration: none;
  align-self: center;
}
.auth-alt:hover {
  color: var(--accent-ink);
}

.spacer {
  flex-grow: 1;
}

.user-menu {
  position: relative;
}

.user-menu-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0;
  background: none;
  border: none;
  font-family: inherit;
  font-size: 13px;
  color: var(--muted);
  cursor: pointer;
  transition: color var(--dur-fast) var(--ease);
}
.user-menu-trigger:hover {
  color: var(--accent-ink);
}

.user-menu-panel {
  position: absolute;
  top: 100%;
  right: 0;
  z-index: 30;
  width: 220px;
  padding: 8px 0;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-2);
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--dur-fast) var(--ease), visibility var(--dur-fast) var(--ease);
}

.user-menu:hover .user-menu-panel,
.user-menu:focus-within .user-menu-panel {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
}

.user-menu.user-menu-esc .user-menu-panel {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.user-menu-name {
  padding: 4px 14px 0;
  font-size: 13px;
  font-weight: 600;
}

.user-menu-email {
  padding: 2px 14px 0;
  font-size: 12px;
  color: var(--muted);
  word-break: break-all;
}

.user-menu-role {
  padding: 2px 14px 6px;
  font-size: 12px;
  color: var(--muted-soft);
  text-transform: capitalize;
}

.user-menu-item {
  display: flex;
  align-items: center;
  width: 100%;
  height: 32px;
  padding: 0 14px;
  border: none;
  background: none;
  font-family: inherit;
  font-size: 13px;
  color: var(--ink-soft);
  text-decoration: none;
  text-align: left;
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}
.user-menu-item:hover {
  background: var(--row-hover);
  color: var(--ink);
}

.user-menu-item-form {
  display: block;
}

.filterbar {
  min-height: 52px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  row-gap: 8px;
  gap: 14px;
  padding: 8px 24px;
}

.segmented {
  display: flex;
  align-items: center;
  background: var(--panel-sunken);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 2px;
  gap: 2px;
}

.chip {
  display: flex;
  align-items: center;
  height: 24px;
  padding: 0 10px;
  border-radius: var(--radius);
  font-size: 11px;
  font-weight: 600;
}
.chip-overdue {
  background: var(--danger-tint);
  color: var(--danger);
}
.chip-blocked {
  background: var(--warn-tint);
  color: var(--warn-ink);
}
.chip-role, .chip-admin, .chip-connected, .chip-off {
  text-transform: capitalize;
}
.chip-role {
  background: var(--surface-sunken);
  border: 1px solid var(--border-strong);
  color: var(--ink-soft);
}
.chip-admin {
  background: var(--panel-sunken);
  border: 1px solid var(--border-strong);
  color: var(--muted);
}
.chip-connected {
  background: var(--positive-tint);
  color: var(--positive-ink);
}
.chip-off {
  background: var(--warn-tint);
  color: var(--warn-ink);
}

.board-stage {
  position: relative;
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  padding: 20px 24px 24px 24px;
}

.board-columns {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
  gap: 16px;
  align-items: stretch;
}

.column {
  background: var(--surface-sunken);
  border-radius: var(--radius-lg);
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 120px;
}

.column-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 2px 4px;
}

.column-name {
  font-size: 13px;
  font-weight: 600;
}

.column-count {
  font-family: var(--font-mono);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: var(--muted-soft);
  background: var(--panel-sunken);
  border-radius: var(--radius);
  padding: 1px 6px;
}

.column-cards {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  scrollbar-width: none;
}
.column-cards::-webkit-scrollbar {
  display: none;
}

.column-empty {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 60px;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-md);
  background: var(--surface-sunken);
  font-size: 12px;
  color: var(--muted-soft);
}

.card {
  display: block;
  text-decoration: none;
  color: inherit;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  box-shadow: var(--shadow-1);
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease);
}
.card:hover {
  background: var(--row-hover);
  border-color: var(--border-strong);
}

/* Where a dragged card may land. Only columns it is not already in light up:
   the card's own column is not a destination. */
.column-drop {
  outline: 1px dashed var(--border-strong);
  outline-offset: 4px;
  border-radius: var(--radius-md);
  background: var(--accent-tint);
}

.card-done {
  background: var(--surface-muted);
  box-shadow: none;
}
.card-done .card-title {
  color: var(--muted);
}

.card-keys {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 10px;
}

.card-key {
  color: var(--muted);
}

.card-blocks,
.card-blocked-by {
  color: var(--warn-ink);
}

.card-title {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  margin-top: 4px;
}

.card-foot {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.card-deadline {
  display: flex;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  background: var(--surface-sunken);
  border-radius: var(--radius-sm);
  padding: 2px 6px;
}
.card-deadline-overdue {
  color: var(--danger);
  background: var(--danger-tint);
}
.card-deadline-none {
  color: var(--muted-soft);
  background: transparent;
  padding-left: 0;
}

.card-comments,
.card-subtasks {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
}

.card-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
  background: var(--surface-sunken);
  border-radius: var(--radius-sm);
  padding: 2px 6px;
}

.card-subtasks-open {
  color: var(--warn-ink);
}

.avatars {
  display: flex;
  align-items: center;
  min-width: 0;
  overflow: hidden;
}
.avatars:has(.avatar:hover) {
  overflow: visible;
}

.avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--surface);
  color: var(--surface);
  font-family: var(--font-mono);
  font-size: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.avatar + .avatar {
  margin-left: -8px;
}
.avatar-none {
  border: 1px dashed var(--border-strong);
  background: transparent;
}
.avatar.avatar-sm {
  width: 18px;
  height: 18px;
  border: none;
  font-size: 10px;
}
.avatar.avatar-lg {
  width: 28px;
  height: 28px;
  border: none;
  font-size: 11px;
  flex: none;
}
.avatar.avatar-xl {
  width: 92px;
  height: 92px;
  border: none;
  font-size: 30px;
  font-weight: 500;
  flex: none;
}
.avatar[data-name]:hover::after {
  content: attr(data-name);
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 3px 8px;
  font-size: 11px;
  color: var(--ink-soft);
  box-shadow: var(--shadow-2);
  white-space: nowrap;
  z-index: 30;
  pointer-events: none;
}
.avatar-tone-0 {
  background: var(--accent);
}
.avatar-tone-1 {
  background: var(--avatar-tone-1);
}
.avatar-tone-2 {
  background: var(--positive);
}
.avatar-tone-3 {
  background: var(--avatar-tone-3);
}
.avatar-tone-4 {
  background: var(--avatar-tone-4);
}

img.avatar {
  object-fit: cover;
  display: block;
}

.identity-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.avatar-upload {
  position: relative;
  flex: none;
  cursor: pointer;
}
.avatar-upload .avatar {
  width: 64px;
  height: 64px;
  font-size: 20px;
}
.avatar-upload::after {
  content: "+";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.4);
  border-radius: 50%;
  color: #fff;
  font-size: 24px;
  font-weight: 300;
  opacity: 0;
  transition: opacity var(--dur-fast) var(--ease);
  pointer-events: none;
}
.avatar-upload:hover::after, .avatar-upload:has(.file-upload-input:focus-visible)::after {
  opacity: 1;
}
.avatar-upload .avatar[data-name]:hover::after {
  content: none;
}

.card-menu {
  display: none;
  position: fixed;
  z-index: 25;
  min-width: 160px;
}
.card-menu-open {
  display: block;
}

.card-menu-move {
  position: relative;
}

.card-menu-submenu {
  display: none;
  position: absolute;
  left: 100%;
  top: 0;
  margin-left: 4px;
  min-width: 140px;
}

.card-menu-move:hover > .card-menu-submenu,
.card-menu-move-trigger:focus + .card-menu-submenu {
  display: block;
}

.card-menu-danger {
  color: var(--danger);
}

.modal-scrim {
  position: fixed;
  inset: 0;
  background: var(--scrim);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 48px 24px;
  overflow-y: auto;
  scrollbar-width: none;
  z-index: 20;
}
.modal-scrim::-webkit-scrollbar {
  display: none;
}

.modal {
  width: 780px;
  max-width: 100%;
  max-height: calc(100vh - 96px);
  overflow-y: auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-3);
  padding: 0;
  outline: none;
}

.modal-loading {
  height: 220px;
}

.modal-note,
.modal-problem {
  margin: 8px 24px 0;
  font-size: 13px;
  color: var(--danger);
}

.modal-new-task {
  width: 480px;
}

.modal-task {
  display: flex;
  flex-direction: column;
  max-height: none;
  overflow: visible;
}

.detail-mast {
  flex: none;
}

.detail-mast .dep-list {
  max-height: 160px;
  overflow-y: auto;
  scrollbar-width: none;
}
.detail-mast .dep-list::-webkit-scrollbar {
  display: none;
}

.detail-mast .detail-block {
  margin-top: 14px;
}

.detail-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  scrollbar-width: none;
}
.detail-body::-webkit-scrollbar {
  display: none;
}

.viewer-close {
  position: absolute;
  inset: 0;
  cursor: default;
}

.modal-scrim:has(~ .viewer-scrim) {
  visibility: hidden;
}

.viewer {
  position: relative;
  width: auto;
  max-width: min(90vw, 960px);
}

.viewer-body {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px 24px 24px;
}

.viewer-media {
  max-width: 100%;
  max-height: 78vh;
  border-radius: var(--radius-md);
}

.audio-player {
  display: flex;
  align-items: center;
  gap: 12px;
  width: min(480px, 80vw);
  padding: 12px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}
.audio-player .audio-el {
  display: none;
}

.audio-play {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  flex: none;
  padding: 0;
  border: 1px solid var(--accent-border);
  border-radius: 50%;
  background: var(--accent-tint);
  color: var(--accent-ink);
  cursor: pointer;
}
.audio-play .glyph-pause {
  display: none;
}
.audio-play:hover {
  border-color: var(--accent-strong);
}

.audio-playing .audio-play .glyph-play {
  display: none;
}
.audio-playing .audio-play .glyph-pause {
  display: block;
}

.audio-time {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--muted);
  min-width: 34px;
  text-align: center;
}

.audio-seek {
  flex: 1;
  appearance: none;
  height: 4px;
  margin: 0;
  background: var(--border);
  border-radius: 2px;
  cursor: pointer;
}
.audio-seek::-webkit-slider-thumb {
  appearance: none;
  width: 12px;
  height: 12px;
  border: none;
  border-radius: 50%;
  background: var(--accent);
}
.audio-seek::-moz-range-thumb {
  width: 12px;
  height: 12px;
  border: none;
  border-radius: 50%;
  background: var(--accent);
}
.audio-seek::-moz-range-track {
  height: 4px;
  background: var(--border);
  border-radius: 2px;
}
.audio-seek::-moz-range-progress {
  height: 4px;
  background: var(--accent);
  border-radius: 2px;
}

.viewer-pdf {
  width: 100%;
  height: 78vh;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}

.viewer:has(.viewer-sheet) {
  width: auto;
  max-width: min(96vw, 1400px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.viewer:has(.viewer-sheet) .viewer-body {
  flex: 1;
  min-height: 0;
  align-items: stretch;
  padding: 16px 20px 20px;
}

.viewer-sheet {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  min-width: 0;
  min-height: 0;
}

.sheet-tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
}
.sheet-tabs::-webkit-scrollbar {
  display: none;
}

.sheet-tab {
  padding: 4px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-dim);
  font-size: 12px;
  white-space: nowrap;
  text-decoration: none;
}

.sheet-tab-on {
  color: var(--text);
  border-color: var(--accent);
}

.sheet-grid {
  flex: 0 1 auto;
  min-width: 0;
  min-height: 0;
  overflow: auto;
  scrollbar-width: none;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}
.sheet-grid::-webkit-scrollbar {
  display: none;
}

.sheet-table {
  border-collapse: collapse;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.sheet-table th,
.sheet-table td {
  padding: 4px 8px;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: left;
}
.sheet-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--surface);
  color: var(--text-dim);
  font-weight: 500;
}
.sheet-table .sheet-gutter {
  position: sticky;
  left: 0;
  background: var(--surface);
  color: var(--text-dim);
  font-weight: 500;
  text-align: right;
}
.sheet-table thead .sheet-gutter {
  z-index: 2;
}

.sheet-note {
  margin: 0;
  color: var(--text-dim);
  font-size: 12px;
}

.sheet-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.sheet-pager {
  display: flex;
  align-items: center;
  gap: 4px;
}

.sheet-range {
  color: var(--text-dim);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  margin-right: 4px;
}

.sheet-step {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-dim);
}
.sheet-step:hover {
  color: var(--text);
  border-color: var(--accent);
}

.sheet-step-up .glyph {
  transform: rotate(180deg);
}

.sheet-step-left .glyph {
  transform: rotate(90deg);
}

.sheet-step-right .glyph {
  transform: rotate(-90deg);
}

.sheet-step-off {
  opacity: 0.3;
}
.sheet-step-off:hover {
  color: var(--text-dim);
  border-color: var(--border);
}

.viewer:has(.viewer-slides) {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.viewer:has(.viewer-slides) .viewer-body {
  flex: 1;
  min-height: 0;
  align-items: stretch;
  padding: 16px 20px 20px;
}

.viewer-slides {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  min-width: 0;
  min-height: 0;
}

.slides-nav {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
}
.slides-nav::-webkit-scrollbar {
  display: none;
}

.slide-tab {
  padding: 4px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-dim);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  text-decoration: none;
}

.slide-tab-on {
  color: var(--text);
  border-color: var(--accent);
}

.slide-card {
  flex: 1;
  min-width: 0;
  min-height: 0;
  overflow: auto;
  scrollbar-width: none;
  padding: 20px 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}
.slide-card::-webkit-scrollbar {
  display: none;
}

.slide-title {
  margin: 0 0 12px;
  font-size: 16px;
}

.slide-line {
  margin: 0 0 8px;
  font-size: 13px;
}

.slides-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.slides-pager {
  display: flex;
  align-items: center;
  gap: 4px;
}

.slides-range {
  color: var(--text-dim);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  margin-right: 4px;
}

.slides-step {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-dim);
}
.slides-step:hover {
  color: var(--text);
  border-color: var(--accent);
}

.slides-step-left .glyph {
  transform: rotate(90deg);
}

.slides-step-right .glyph {
  transform: rotate(-90deg);
}

.slides-step-off {
  opacity: 0.3;
}
.slides-step-off:hover {
  color: var(--text-dim);
  border-color: var(--border);
}

.new-task-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 20px 24px 24px;
}

.new-task-row {
  display: flex;
  gap: 16px;
}

.new-task-foot {
  display: flex;
  align-items: center;
  gap: 10px;
}

.edit {
  position: relative;
}

.edit-toggle {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  padding: 0;
  opacity: 0;
  pointer-events: none;
}

.edit-hit {
  cursor: text;
}

.edit-form {
  display: none;
}

.edit:not(.edit-pop) > .edit-toggle:checked ~ .edit-view {
  display: none;
}

.edit-toggle:checked ~ .edit-form {
  display: block;
}

.edit-toggle:checked ~ .title-form {
  display: flex;
}

.detail-head:has(.edit-toggle:checked) .detail-state,
.detail-head:has(.edit-toggle:checked) .spacer,
.detail-head:has(.edit-toggle:checked) .detail-esc,
.detail-head:has(.edit-toggle:checked) .detail-close,
.detail-head:has(.edit-toggle:checked) .detail-board {
  display: none;
}

.edit-toggle:focus-visible ~ .edit-view {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

.edit-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.edit-save,
.comment-post {
  height: var(--control-h);
  padding: 0 12px;
  border: none;
  border-radius: var(--radius);
  background: var(--accent);
  color: var(--surface);
  font-family: inherit;
  font-size: 12px;
  cursor: pointer;
  transition: background var(--dur-fast) var(--ease);
}
.edit-save:hover,
.comment-post:hover {
  background: var(--accent-strong);
}
.edit-save:disabled,
.comment-post:disabled {
  opacity: 0.5;
  cursor: default;
}

.edit-cancel {
  font-size: 12px;
  color: var(--muted);
  cursor: pointer;
  transition: color var(--dur-fast) var(--ease);
}
.edit-cancel:hover {
  color: var(--ink);
}

.edit-pop .edit-form {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 4;
}

.pop-panel {
  min-width: 200px;
  padding: 8px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-2);
}

.pop-panel-wide {
  min-width: 320px;
}

.pop-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.pop-list-scroll {
  max-height: 220px;
  overflow-y: auto;
}

.pop-row-form {
  display: block;
}

.pop-row {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 4px 6px;
  border: none;
  border-radius: var(--radius-sm);
  background: transparent;
  font-family: inherit;
  font-size: 13px;
  color: var(--ink);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease);
}
.pop-row:hover {
  background: var(--row-hover);
}

.pop-row-name {
  font-size: 12px;
}

.pick-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 6px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease);
}
.pick-row:hover {
  background: var(--row-hover);
}

.pick-title {
  color: var(--muted);
}

.pick-direction {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 8px 0 0;
  padding: 8px 6px 0;
  border: none;
  border-top: 1px solid var(--border);
  font-size: 12px;
}
.pick-direction label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}

.detail-head {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 22px 24px 0;
}

.detail-headline {
  flex: 1;
  min-width: 0;
}

.detail-tabs {
  display: flex;
  gap: 2px;
  flex: none;
  padding: 0 16px;
  border-bottom: 1px solid var(--border);
}

.detail-tab {
  padding: 9px 10px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.detail-tab-on {
  color: var(--ink);
}

.detail-tab-count {
  margin-left: 4px;
  color: var(--muted-soft);
}

.detail-key {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted-soft);
}

.detail-crumbs {
  display: flex;
  align-items: baseline;
  gap: 6px;
  min-width: 0;
  margin-bottom: 9px;
  flex-wrap: nowrap;
}
.detail-crumbs .detail-key {
  flex: none;
  white-space: nowrap;
}

.detail-crumb {
  display: flex;
  align-items: baseline;
  gap: 6px;
  min-width: 0;
  flex: 0 1 auto;
  color: var(--muted);
  text-decoration: none;
}
.detail-crumb:hover {
  color: var(--ink);
}
.detail-crumb:hover .detail-crumb-title {
  text-decoration: underline;
}

.detail-crumb-key {
  flex: none;
  font-family: var(--font-mono);
  font-size: 11px;
}

.detail-crumb-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 28ch;
  flex: 0 1 auto;
  min-width: 3ch;
  font-size: 12px;
  text-decoration: underline;
  text-decoration-color: var(--border-strong);
  text-underline-offset: 3px;
}

.detail-crumb:hover .detail-crumb-title {
  text-decoration-color: currentColor;
}

.detail-crumb-sep {
  flex: none;
  font-size: 11px;
  color: var(--muted-soft);
}

.detail-title {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.title-form {
  align-items: center;
  gap: 8px;
}

.title-input {
  flex: 1;
  min-width: 0;
  height: var(--control-h);
  padding: 0 8px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--surface);
  font-family: inherit;
  font-size: 18px;
  font-weight: 600;
  color: var(--ink);
}

.detail-esc {
  margin-top: 4px;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.detail-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: var(--radius);
  background: transparent;
  color: var(--muted);
  text-decoration: none;
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease);
}
.detail-close:hover {
  background: var(--row-hover);
}

.detail-state {
  display: inline-flex;
  align-items: center;
}

.detail-board {
  align-self: center;
  white-space: nowrap;
}

.detail-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
  padding: 18px 24px 0;
  margin-top: 2px;
}

.detail-field-people {
  grid-column: 1/-1;
}

.detail-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.detail-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--muted-soft);
}

.detail-count {
  font-family: var(--font-mono);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: var(--muted-soft);
}

.field-box,
.status-form {
  display: flex;
  align-items: center;
  gap: 8px;
  height: var(--control-h);
  padding: 0 10px;
  background: var(--field-bg);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  font-size: 13px;
  color: var(--ink);
  cursor: pointer;
}

.field-box {
  font-size: 13px;
  color: var(--ink);
  cursor: pointer;
}

.field-text {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.field-box-sort {
  flex: 0 1 auto;
  min-width: 0;
}
.field-box-sort .status-select {
  flex: 0 1 auto;
  width: auto;
  min-width: 0;
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.field-box-search {
  flex: 0 1 240px;
  min-width: 0;
}
.field-box-search .field-text {
  flex: none;
}
.field-box-search .dd-search {
  flex: 1;
  min-width: 0;
  width: auto;
  height: auto;
  margin-bottom: 0;
  padding: 0;
}

.glyph {
  flex: none;
  color: var(--muted-soft);
}

.status-dot {
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--muted-soft);
}

.status-dot-done {
  background: var(--positive);
}

.status-select {
  flex: 1;
  min-width: 0;
  border: none;
  background: transparent;
  appearance: none;
  font-family: inherit;
  font-size: 13px;
  color: var(--ink);
  cursor: pointer;
}

.detail-overdue {
  border-color: var(--danger-border);
  color: var(--danger);
}
.detail-overdue .glyph {
  color: var(--danger);
}

.datepick-panel {
  width: 190px;
}

.datepick-time {
  display: flex;
  gap: 4px;
  align-items: center;
  margin-top: 6px;
}

.datepick-time .field-input {
  width: 100%;
  min-width: 0;
  text-align: center;
}

.datepick-colon {
  font-family: var(--font-mono);
  color: var(--ink-soft);
}

.datepick-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.datepick-title {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink);
}

.datepick-nav {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border: none;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease);
}
.datepick-nav:hover {
  background: var(--row-hover);
}

.datepick-prev .glyph {
  transform: rotate(90deg);
}

.datepick-next .glyph {
  transform: rotate(-90deg);
}

.datepick-weekdays,
.datepick-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
}

.datepick-weekdays {
  margin-bottom: 2px;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--muted-soft);
  text-align: center;
}

.datepick-cell {
  height: 24px;
  border: none;
  background: transparent;
  font-family: inherit;
  font-size: 11px;
}

.datepick-day {
  border-radius: var(--radius-sm);
  color: var(--ink);
  cursor: pointer;
  font-variant-numeric: tabular-nums;
  transition: background-color var(--dur-fast) var(--ease);
}
.datepick-day:hover {
  background: var(--row-hover);
}

.datepick-today {
  box-shadow: inset 0 0 0 1px var(--accent);
}

.datepick-selected {
  background: var(--accent);
  color: var(--surface);
}
.datepick-selected:hover {
  background: var(--accent);
}

.datepick-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px solid var(--border);
}

.datepick-action {
  border: none;
  background: transparent;
  font-family: inherit;
  font-size: 12px;
  color: var(--muted);
  cursor: pointer;
  transition: color var(--dur-fast) var(--ease);
}
.datepick-action:hover {
  color: var(--ink);
}

.detail-assignees {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  height: 36px;
  padding: 0 6px;
  background: var(--field-bg);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
}

.assignee-chip {
  display: inline-flex;
  flex: 0 1 auto;
  min-width: 0;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  padding: 3px 6px 3px 3px;
  border-radius: var(--radius-sm);
  background: var(--surface);
  border: 1px solid var(--border);
}

.assignee-name {
  flex: 0 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
  color: var(--ink);
}

.detail-assignees:has(.assignee-chip:nth-child(5)) .assignee-name {
  display: none;
}

.assignee-drop {
  display: inline-flex;
}

.assignee-remove {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
  border: none;
  background: transparent;
  color: var(--muted-soft);
  cursor: pointer;
  transition: color var(--dur-fast) var(--ease);
}
.assignee-remove:hover {
  color: var(--danger);
}

.assignee-add {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: var(--control-h);
  height: var(--control-h);
  border: 1px dashed var(--border-strong);
  border-radius: 50%;
  color: var(--muted-soft);
  cursor: pointer;
  transition: color var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease);
}
.assignee-add:hover {
  color: var(--ink);
  border-color: var(--muted-soft);
}

.detail-assignees > .edit {
  flex: none;
}

.assignee-pop .edit-form {
  left: auto;
  right: 0;
}

.detail-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 22px 24px 0;
}

.detail-block-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: -2px;
}

.detail-prose {
  display: block;
  margin: 0;
  min-width: 0;
  font-size: 13px;
  line-height: 1.6;
  color: var(--ink-soft);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.detail-prose-empty {
  color: var(--muted-soft);
}

.detail-body {
  display: flex;
  flex-direction: column;
}

.detail-block-fill {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.detail-block-fill > .comment-list,
.detail-block-fill > .activity-list {
  flex: 1;
  min-height: 0;
  max-height: none;
}

.detail-quiet {
  margin: 0;
  font-size: 13px;
  color: var(--muted-soft);
}

.detail-textarea,
.comment-input {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--surface);
  font-family: inherit;
  font-size: 13px;
  line-height: 1.6;
  color: var(--ink);
  resize: vertical;
}

.dep-chip,
.file-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 24px;
  padding: 0 8px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  font-size: 12px;
  color: var(--muted);
}

.dep-chip {
  cursor: pointer;
  transition: color var(--dur-fast) var(--ease);
}
.dep-chip:hover {
  color: var(--ink);
}

.dep-chip-text {
  font-size: 12px;
}

.link-pop .edit-form {
  left: auto;
  right: 0;
}

.dep-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.dep-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--field-bg);
  font-size: 13px;
}

.subtask-list {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow-y: auto;
  scrollbar-width: none;
}
.subtask-list::-webkit-scrollbar {
  display: none;
}

.subtask-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 4px;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}
.subtask-row:last-child {
  border-bottom: none;
}

.subtask-open {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}
.subtask-open:hover .subtask-title {
  text-decoration: underline;
}

.subtask-mark {
  display: flex;
  color: var(--muted-soft);
}

.subtask-key {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
}

.subtask-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.subtask-status {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted-soft);
}

.subtask-row-done .subtask-title {
  color: var(--muted);
}

.subtask-new {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.subtask-new-input {
  flex: 1;
  min-width: 0;
}

.dep-row-waiting {
  background: var(--warn-tint-soft);
  border-color: var(--warn-border);
}
.dep-row-waiting .dep-tag,
.dep-row-waiting .dep-note,
.dep-row-waiting .glyph {
  color: var(--warn-ink);
}

.dep-tag {
  flex: none;
  width: 78px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  color: var(--muted-soft);
}

.dep-tick {
  color: var(--positive);
}

.dep-key {
  flex: none;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted-soft);
}

.dep-title {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dep-note {
  flex: none;
  font-size: 11px;
  color: var(--muted-soft);
}

.dep-link {
  display: flex;
  flex: 1;
  align-items: center;
  gap: 10px;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}
.dep-link:hover .dep-title {
  text-decoration: underline;
}

.dep-unlink-form {
  display: inline-flex;
}

.dep-unlink {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border: none;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--muted-soft);
  cursor: pointer;
  transition: color var(--dur-fast) var(--ease);
}
.dep-unlink:hover {
  color: var(--danger);
}

.file-list {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 6px;
}

.file-list .file-chip {
  display: flex;
  width: 100%;
  gap: 8px;
}

.file-chip-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: inherit;
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease);
}
.file-chip-name:hover {
  color: var(--ink);
}

.file-chip-size {
  flex: none;
  white-space: nowrap;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted-soft);
}

.file-chip-note {
  flex: none;
  white-space: nowrap;
  font-size: 11px;
  color: var(--muted-soft);
}

.file-chip-drop-form {
  display: inline-flex;
  flex: none;
}

.file-chip-drop {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border: none;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--muted-soft);
  cursor: pointer;
  transition: color var(--dur-fast) var(--ease);
}
.file-chip-drop:hover {
  color: var(--danger);
}

.file-upload {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
}

.file-upload-box {
  position: relative;
  flex: none;
  max-width: 220px;
  background: var(--surface);
  transition: border-color var(--dur-fast) var(--ease);
  cursor: pointer;
}
.file-upload-box:hover {
  border-color: var(--accent);
}
.file-upload-box:has(.file-upload-input:focus-visible) {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

.file-upload-name {
  max-width: 160px;
}

.file-upload-input {
  position: absolute;
  width: 1px;
  height: 1px;
  clip-path: inset(50%);
  opacity: 0;
}

.upload-progress {
  position: absolute;
  left: 1px;
  right: 22px;
  bottom: 1px;
  height: 2px;
  background: var(--border);
  border-radius: var(--radius-sm);
  pointer-events: none;
  overflow: hidden;
}

.upload-progress-fill {
  width: 0;
  height: 100%;
  background: var(--accent);
  transition: width var(--dur-fast) var(--ease);
}

.upload-progress-drop {
  position: absolute;
  right: 1px;
  bottom: 1px;
}

.comment-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-height: 320px;
  overflow-y: auto;
  scrollbar-width: none;
}
.comment-list::-webkit-scrollbar {
  display: none;
}

.comment {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.comment-said {
  min-width: 0;
  flex: 1;
}

.comment-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.comment-who {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
}

.comment-when {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted-soft);
}

.comment-body {
  margin-top: 3px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--ink-soft);
  white-space: pre-wrap;
}

.comment-composer {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 14px;
}

.comment-input {
  font-size: 13px;
}

.comment-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.activity-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 320px;
  overflow-y: auto;
  scrollbar-width: none;
}
.activity-list::-webkit-scrollbar {
  display: none;
}

.activity-line {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 10px;
  font-size: 12px;
  color: var(--muted);
}

.activity-stamp {
  flex: none;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted-soft);
}

.activity-who {
  flex: none;
  color: var(--ink);
}

.detail-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: none;
  padding: 22px 24px 24px;
  margin-top: 4px;
}

.detail-delete-form {
  display: inline-flex;
}

.detail-delete {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: var(--control-h);
  padding: 0 14px;
  border: 1px solid var(--danger-border);
  border-radius: var(--radius);
  background: var(--surface);
  font-family: inherit;
  font-size: 13px;
  color: var(--danger);
  cursor: pointer;
}
.detail-delete:disabled {
  opacity: 0.5;
  cursor: default;
}

.confirm-details[open] {
  position: relative;
  z-index: 21;
}

.modal:has(details.confirm-details[open]) {
  visibility: hidden;
}
.modal:has(details.confirm-details[open]) details.confirm-details[open],
.modal:has(details.confirm-details[open]) details.confirm-details[open]::before,
.modal:has(details.confirm-details[open]) details.confirm-details[open] .confirm {
  visibility: visible;
}
.modal:has(details.confirm-details[open]) details.confirm-details[open] > summary {
  display: none;
}

.confirm-details[open]::before {
  content: "";
  position: fixed;
  inset: 0;
  background: var(--scrim);
  z-index: 20;
}

.confirm {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 21;
  width: 420px;
  max-width: calc(100% - 48px);
  margin: 0;
  padding: 18px 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-3);
}

.confirm-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
}

.confirm-list {
  margin: 8px 0 0;
  padding-left: 18px;
  font-size: 13px;
  color: var(--ink-soft);
}

.confirm-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
}

.settings-shell {
  display: flex;
}

.settings-stage {
  flex: 1;
  min-width: 0;
  padding: 24px 32px 40px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 860px;
  overflow-y: auto;
  scrollbar-width: none;
}
.settings-stage::-webkit-scrollbar {
  display: none;
}
.settings-stage.stage-wide {
  max-width: 1200px;
}
.settings-stage > * {
  flex: none;
}

.settings-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.settings-sections {
  flex: none;
  width: 200px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 16px 0;
  border-right: 1px solid var(--border);
}

.settings-section-link {
  display: block;
  padding: 8px 16px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-soft);
  text-decoration: none;
}
.settings-section-link:hover {
  color: var(--ink);
}

.settings-title {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.panel-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}

.panel-title {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
}

.panel-body {
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.panel-lede {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}

.panel-foot {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  justify-content: flex-end;
}
.panel-foot-split {
  justify-content: space-between;
}

.foot-side {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-grow: 1;
  min-width: 0;
}

.field-row {
  display: flex;
  gap: 16px;
}

#sender-settings {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.field-narrow {
  flex-grow: 0;
  width: 120px;
}

.field-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--muted-soft);
}

.auth-input,
.field-input {
  height: 40px;
  padding: 0 12px;
  background: var(--field-bg);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  font-family: var(--font-sans);
  font-size: 13px;
  color: var(--ink);
}
.auth-input:focus-visible,
.field-input:focus-visible {
  background: var(--surface);
  border-color: var(--accent);
}
.auth-input:disabled,
.field-input:disabled {
  background: var(--panel-sunken);
  color: var(--muted);
}

.auth-input-mono {
  font-family: var(--font-mono);
}

.field-input.dd-trigger {
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  padding-right: 32px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 16 16' fill='none' stroke='%23726d61' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 6l4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}

[data-theme=dark] .field-input.dd-trigger {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 16 16' fill='none' stroke='%238b949e' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 6l4 4 4-4'/%3E%3C/svg%3E");
}

option {
  background: var(--surface);
  color: var(--ink);
}

option:checked {
  background: var(--accent-tint);
  color: var(--accent-ink);
}

option:hover {
  background: var(--panel-sunken);
}

input[type=checkbox],
input[type=radio] {
  accent-color: var(--accent);
}

.dd-native {
  display: none;
}

.dd-trigger {
  display: flex;
  align-items: center;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.status-select.dd-trigger {
  padding: 0;
}

.dd-panel {
  position: fixed;
  z-index: 60;
  max-height: 260px;
  overflow-y: auto;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-2);
  padding: 8px;
  display: none;
}

.dd-panel.dd-open {
  display: block;
}

.dd-option {
  display: block;
  width: 100%;
  padding: 6px 10px;
  border: none;
  border-radius: var(--radius-sm);
  background: none;
  font: inherit;
  font-size: 13px;
  text-align: left;
  color: var(--ink);
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease);
}
.dd-option:hover, .dd-option:focus, .dd-option.dd-option-active {
  background: var(--row-hover);
  outline: none;
}

.dd-option-selected {
  background: var(--accent-tint);
  color: var(--accent-ink);
}

.dd-option-hidden {
  display: none;
}

.dd-search {
  display: block;
  width: 100%;
  margin-bottom: 6px;
  padding: 8px 10px;
  border: none;
  border-bottom: 1px solid var(--border);
  background: none;
  font: inherit;
  font-size: 13px;
  color: var(--ink);
}

.field-stated {
  display: flex;
  align-items: center;
  height: 40px;
  padding: 0 12px;
  background: var(--panel-sunken);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius);
  font-size: 13px;
  color: var(--muted);
}

.field-note {
  font-size: 12px;
  line-height: 1.5;
  color: var(--muted);
}

.field-error {
  font-size: 12px;
  color: var(--danger);
}

.primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: var(--control-h);
  padding: 0 16px;
  background: var(--accent);
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  color: var(--surface);
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}
.primary:hover {
  background: var(--accent-ink);
  border-color: var(--accent-ink);
  color: var(--surface);
}

:is(button, a, input, select, textarea, summary, .dd-trigger, [tabindex]):focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

.modal:focus-visible {
  outline: none;
}

.dd-search:focus-visible {
  outline: none;
  border-bottom-color: var(--accent);
}

.member-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: auto;
  font-size: 13px;
}
.member-table th {
  text-align: left;
  padding: 0 12px 8px 0;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  font-weight: 400;
  color: var(--muted-soft);
  border-bottom: 1px solid var(--border);
}
.member-table td {
  padding: 10px 12px 10px 0;
  vertical-align: middle;
}
.member-table .member-col-name,
.member-table .member-col-role,
.member-table .member-col-account {
  width: 1%;
  white-space: nowrap;
}
.member-table .member-col-address {
  width: 100%;
  max-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.member-table .member-row {
  border-bottom: 1px solid var(--border);
}

.member-name-row,
.member-account-row {
  display: flex;
  align-items: center;
}

.member-name {
  font-weight: 600;
}

.member-name-row {
  gap: 8px;
}

.member-you {
  flex: none;
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--field-bg);
  border: 1px solid var(--border-strong);
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
}

.member-address {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--muted);
}

.member-account {
  color: var(--muted);
}

.member-account-row {
  gap: 10px;
}

.member-status {
  flex: none;
  white-space: nowrap;
}

.member-resend {
  display: inline-flex;
  flex: none;
}

.quiet {
  display: inline-flex;
  align-items: center;
  height: var(--control-h);
  padding: 0 10px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  font-family: var(--font-sans);
  font-size: 12px;
  color: var(--ink-soft);
  text-decoration: none;
  cursor: pointer;
  transition: border-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}
.quiet:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.quiet.quiet-danger {
  border-color: var(--danger-border);
  color: var(--danger);
}
.quiet.quiet-danger:hover {
  border-color: var(--danger);
  color: var(--danger);
  background: var(--surface-sunken);
}

.member-role {
  position: relative;
  padding: 0;
}
.member-role > .glyph {
  position: absolute;
  right: 10px;
  pointer-events: none;
  color: var(--muted);
}
.member-role .status-select {
  align-self: stretch;
  padding: 0 28px 0 10px;
}

.member-invite {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}

.field-role {
  flex-grow: 0;
  width: 140px;
}

.member-invite .field-input {
  height: var(--control-h);
}

.member-link {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 12px;
  background: var(--accent-tint);
  border: 1px solid var(--accent-border);
  border-radius: var(--radius);
}

.member-link-value {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent-ink);
  word-break: break-all;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.rules-quiet {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

.rule-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.rule-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}
.rule-row-off {
  background: var(--surface-muted);
  opacity: 0.75;
}

.rule-switch-form {
  display: flex;
  flex-shrink: 0;
}

.rule-switch {
  width: 36px;
  height: 20px;
  padding: 0;
  border: none;
  border-radius: var(--radius-lg);
  background: var(--border-soft);
  position: relative;
  cursor: pointer;
}
.rule-switch-knob {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--surface);
}
.rule-switch-on {
  background: var(--accent);
}
.rule-switch-on .rule-switch-knob {
  left: auto;
  right: 2px;
}

.rule-sentence {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  flex-grow: 1;
  min-width: 0;
  font-size: 13px;
  color: var(--ink-soft);
}

.rule-term {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  background: transparent;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  font-weight: 500;
  color: var(--ink);
}

.rule-row-off .rule-term {
  border-color: var(--border-soft);
  color: var(--muted-soft);
}

.rule-term-owed,
.rule-term-already_owed,
.rule-term-sent {
  background: var(--accent-tint);
  border-color: var(--accent-border);
  color: var(--accent-ink);
}

.rule-term-failed,
.rule-term-abandoned {
  background: var(--danger-tint);
  border-color: var(--danger-border-alt);
  color: var(--danger);
}

.rule-term-held,
.rule-term-pending {
  background: var(--warn-tint);
  border-color: var(--warn-border);
  color: var(--warn-ink);
}

.rule-term-not_matched,
.rule-term-disabled {
  background: var(--surface-sunken);
  border-color: var(--border-strong);
  color: var(--muted);
}

.rule-term-no_recipients {
  background: var(--violet-tint);
  border-color: var(--violet-border);
  color: var(--violet-ink);
}

.rule-term-task_gone {
  background: var(--danger-tint-soft);
  border-color: var(--danger-border-soft);
  color: var(--danger);
}

.decision-block {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}

.decision-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.decision-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-soft);
}

.decision-verdicts {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.decision-verdict {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 13px;
  color: var(--ink-soft);
}

.rule-stamp {
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted-soft);
}

.log-list {
  display: flex;
  flex-direction: column;
}

.log-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 8px 2px;
  border-bottom: 1px solid var(--border);
}

.log-stamp {
  flex-shrink: 0;
  min-width: 110px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.log-actor {
  flex-shrink: 0;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
}

.log-line {
  flex: 1;
  min-width: 0;
  font-size: 13px;
  color: var(--ink-soft);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.filterbar.log-filterbar {
  min-height: 0;
  padding: 0;
  background: none;
  border-bottom: none;
  flex-wrap: wrap;
  gap: 10px;
}

.log-range-dash {
  align-self: center;
  margin: 0 2px;
  color: var(--muted);
}

.log-count {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--muted);
}

.log-title {
  flex-shrink: 1;
  min-width: 0;
  font-size: 13px;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.log-key {
  flex: none;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.rule-new {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.rule-new-open {
  display: flex;
  align-items: center;
  height: var(--control-h);
  padding: 0 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-ink);
  cursor: pointer;
  list-style: none;
}
.rule-new-open::marker, .rule-new-open::-webkit-details-marker {
  display: none;
}
.rule-new-open::before {
  content: "+";
  margin-right: 8px;
  font-size: 13px;
}

.rule-new-body {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 0 16px 16px;
  border-top: 1px solid var(--border);
  padding-top: 16px;
}

.rule-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.tag-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.tag-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}

.tag-name {
  flex-grow: 1;
  min-width: 0;
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tag-count {
  flex: none;
  font-family: var(--font-mono);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: var(--muted-soft);
  background: var(--panel-sunken);
  border-radius: var(--radius);
  padding: 1px 6px;
}

.tag-new {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.tag-new-open {
  display: flex;
  align-items: center;
  height: var(--control-h);
  padding: 0 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-ink);
  cursor: pointer;
  list-style: none;
}
.tag-new-open::marker, .tag-new-open::-webkit-details-marker {
  display: none;
}
.tag-new-open::before {
  content: "+";
  margin-right: 8px;
  font-size: 13px;
}

.tag-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 0 16px 16px;
  border-top: 1px solid var(--border);
  padding-top: 16px;
}

.tag-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.people-shell {
  width: 100%;
  max-width: 860px;
  margin: 0 auto;
  padding: 24px 32px 40px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  overflow-y: auto;
  scrollbar-width: none;
}
.people-shell::-webkit-scrollbar {
  display: none;
}
.people-shell > * {
  flex: none;
}

.person-link {
  display: inline-flex;
  align-items: center;
  gap: inherit;
  color: inherit;
  text-decoration: none;
  min-width: 0;
}
.person-link:hover {
  text-decoration: underline;
}

.person-card {
  overflow: hidden;
}

.person-head {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 22px 22px 20px;
}

.person-heading {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.person-name {
  margin: 0;
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 600;
  line-height: 1.1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.person-marks {
  display: flex;
  align-items: center;
  gap: 6px;
}

.person-edit {
  margin-left: auto;
  flex: none;
}

.person-fields {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin: 0;
  border-top: 1px solid var(--border);
}

.person-field {
  padding: 12px 22px 14px;
  min-width: 0;
  border-right: 1px solid var(--border);
}
.person-field:last-child {
  border-right: none;
}
.person-field dt {
  font-size: 10px;
  letter-spacing: 0.09em;
  color: var(--muted);
}
.person-field dd {
  margin: 4px 0 0;
  font-size: 13px;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.person-field dd.person-address {
  font-family: var(--font-mono);
  font-size: 12px;
}

.person-head .avatar[data-name]:hover::after {
  content: none;
}

.person-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin: 0;
}
@media (max-width: 620px) {
  .person-stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .person-stats .person-stat {
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .person-stats .person-stat:nth-child(odd) {
    border-right: 1px solid var(--border);
  }
  .person-stats .person-stat:nth-child(n+3) {
    border-bottom: none;
  }
}

.person-stat {
  padding: 16px 22px 18px;
  border-right: 1px solid var(--border);
}
.person-stat:last-child {
  border-right: none;
}
.person-stat dd {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 26px;
  font-weight: 500;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.person-stat dt {
  margin-top: 6px;
  font-size: 10px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted);
}

.person-feed {
  list-style: none;
  margin: 0;
  padding: 0;
}

.person-line {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 9px 18px;
  border-top: 1px solid var(--border);
  min-width: 0;
}
.person-line:first-child {
  border-top: none;
}
.person-line:hover {
  background: var(--surface-muted);
}

.person-verb {
  flex: none;
  width: 88px;
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.person-task {
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}
.person-task:hover .person-title {
  text-decoration: underline;
}

.person-key {
  flex: none;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
}

.person-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
}

.person-day {
  margin-left: auto;
  flex: none;
  white-space: nowrap;
  color: var(--muted);
  font-size: 12px;
}

@media (max-width: 620px) {
  .topbar {
    gap: 10px;
    padding: 0 12px;
  }
  .topbar-nav-links {
    gap: 12px;
    min-width: 0;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .topbar-nav-links::-webkit-scrollbar {
    display: none;
  }
  .user-menu-trigger-name {
    display: none;
  }
}
@media (max-width: 620px) and (max-width: 360px) {
  .topbar {
    gap: 8px;
    padding: 0 8px;
  }
  .topbar-nav-links {
    gap: 10px;
  }
}
@media (max-width: 620px) {
  .filterbar {
    height: auto;
    min-height: 44px;
    flex-wrap: wrap;
    row-gap: 8px;
    padding: 8px 12px;
  }
}
@media (max-width: 620px) {
  .filterbar .topbar-divider {
    display: none;
  }
}
@media (max-width: 620px) {
  .filterbar .primary,
.filterbar .chip {
    flex: none;
  }
}
@media (max-width: 620px) {
  .board-stage {
    padding: 12px;
  }
}
@media (max-width: 620px) {
  .board-columns {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: min(72vw, 280px);
    overflow-x: auto;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
  }
  .board-columns::-webkit-scrollbar {
    display: none;
  }
}
@media (max-width: 620px) {
  .column {
    scroll-snap-align: start;
  }
}
@media (max-width: 620px) {
  .modal-scrim {
    padding: 16px;
  }
}
@media (max-width: 620px) {
  .modal {
    max-height: calc(100dvh - 32px);
  }
}
@media (max-width: 620px) {
  .new-task-row {
    flex-wrap: wrap;
  }
}
@media (max-width: 620px) {
  .detail-head {
    padding: 16px 16px 0;
  }
}
@media (max-width: 620px) {
  .detail-tabs {
    overflow-x: auto;
    scrollbar-width: none;
  }
  .detail-tabs::-webkit-scrollbar {
    display: none;
  }
}
@media (max-width: 620px) {
  .detail-tab {
    white-space: nowrap;
  }
}
@media (max-width: 620px) {
  .detail-crumb-title {
    max-width: 16ch;
  }
}
@media (max-width: 620px) {
  .detail-fields {
    grid-template-columns: minmax(0, 1fr);
    padding: 14px 16px 0;
  }
}
@media (max-width: 620px) {
  .detail-block {
    padding: 16px 16px 0;
  }
}
@media (max-width: 620px) {
  .detail-foot {
    padding: 14px 16px 16px;
  }
}
@media (max-width: 620px) {
  .settings-shell {
    flex-direction: column;
  }
}
@media (max-width: 620px) {
  .settings-sections {
    width: auto;
    flex-direction: row;
    padding: 0 8px;
    border-right: none;
    border-bottom: 1px solid var(--border);
    overflow-x: auto;
    scrollbar-width: none;
  }
  .settings-sections::-webkit-scrollbar {
    display: none;
  }
}
@media (max-width: 620px) {
  .settings-section-link {
    flex: none;
    padding: 12px 10px;
    white-space: nowrap;
  }
}
@media (max-width: 620px) {
  .settings-stage {
    padding: 16px 16px 32px;
  }
}
@media (max-width: 620px) {
  .table-pan {
    overflow-x: auto;
    scrollbar-width: none;
  }
  .table-pan::-webkit-scrollbar {
    display: none;
  }
  .table-pan .member-table {
    min-width: 560px;
  }
}
@media (max-width: 620px) {
  .field-row {
    flex-wrap: wrap;
  }
}
@media (max-width: 620px) {
  .people-shell {
    padding: 16px 16px 32px;
  }
}
@media (max-width: 620px) {
  .person-head {
    flex-wrap: wrap;
  }
}
@media (max-width: 620px) {
  .person-fields {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 620px) {
  .person-field {
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .person-field:last-child {
    border-right: none;
    border-bottom: none;
  }
}
@media (max-width: 620px) {
  .auth-stage {
    padding: 0 16px 24px;
  }
}
