/* Semantic foundation shared by all customer workspaces. */
:root {
  --v1-motion-feedback: 100ms;
  --v1-motion-state: 140ms;
  --v1-motion-dialog: 190ms;
  --v1-motion-drawer: 230ms;
  --v1-ease: cubic-bezier(.19,.72,.25,1);
  --v1-control: 34px;
  --v1-row: 38px;
  --v1-sidebar: 218px;
  --v1-compact: 50px;
  --v1-gap: 8px;
  --v1-control-radius: 7px;
  --v1-dialog-radius: 13px;
}
:where(.shell,.auth-screen) {
  --radius-control: var(--v1-control-radius);
  --radius-dialog: var(--v1-dialog-radius);
  --ease: var(--v1-ease);
  font-size: 13px;
}
.shell {
  --sidebar-width: var(--v1-sidebar);
  --content-inset: clamp(12px,2.1vw,27px);
}
[data-sidebar="compact"] .shell { --sidebar-width: var(--v1-compact); }
.shell .sidebar { order: 0; padding: 12px 8px; background: var(--sidebar); border-color: var(--divider); }
.shell .brand { margin: 1px 0 12px 8px; gap: 8px; height: 26px; }
.shell .brand img { width: 19px; height: 22px; }
.shell .brand span { font-size: 17px; letter-spacing: -.045em; line-height: 1; }
.shell .brand:hover img { transform: none; }
.shell .profile-menu { margin: 0 0 12px; }
.shell .profile { min-height: 38px; border: var(--hairline) solid var(--border); border-radius: 7px; padding: 4px 7px; gap: 8px; }
.shell .profile strong { font-size: 12px; line-height: 1.2; }
.shell .profile small { font-size: 11px; line-height: 1.2; }
.shell .profile-copy { gap: 1px; }
.shell .profile .avatar { border-radius: 5px; flex-basis: 23px; height: 23px; color: var(--ink); background: var(--selection); font-size: 10px; }
.shell .profile-actions { inset: calc(100% + 5px) 0 auto auto; min-width: 158px; box-shadow: var(--shadow-menu); }
.shell .navigation { gap: 2px; }
.shell .navigation a { min-height: 32px; padding-inline: 8px; gap: 8px; font-size: 13px; font-weight: 520; line-height: 1.25; border-radius: 6px; color: var(--ink); transition-duration: var(--v1-motion-feedback); }
.shell .navigation a svg { width: 16px; height: 16px; color: var(--muted); }
.shell .navigation a:hover { background: var(--row-hover); }
.shell .navigation a[aria-current] { background: var(--selection); font-weight: 650; border-color: transparent; }
.shell .navigation a[aria-current] svg { color: var(--ink); }
.shell .topbar { flex-basis: 44px; background: var(--paper); }
.shell .topbar-context { gap: 8px; }
.shell .topbar .sidebar-toggle, .shell .topbar .sidebar-quick-actions button {
  min-height: 29px; height: 29px; width: 29px; border-color: transparent; padding: 5px;
}
.shell .topbar .sidebar-quick-actions { flex-direction: row; margin: 0; gap: 3px; }
.shell .topbar .sidebar-quick-actions button:hover { transform: none; }
.shell .content { padding-block: 16px 28px; }
.shell .workspace-header, .shell .page-heading { gap: 6px 12px; margin-block: 0 12px; }
.shell .content :is(.workspace-header,.page-heading) h1 { font-size: clamp(22px,2.25vw,28px); letter-spacing: -.033em; line-height: 1.15; }
.shell .content :is(.workspace-header,.page-heading) p { font-size: 13px; line-height: 1.45; }
.shell :is(h1,h2,h3,.breadcrumb-page) { color: var(--ink); }
:where(.shell,.auth-screen) .recon-button { min-height: var(--v1-control); border-radius: var(--radius-control); transition-duration: var(--v1-motion-feedback); }
.shell .recon-button.recon-primary, .auth-screen .recon-button.recon-primary {
  background: var(--primary); color: var(--primary-ink); border-color: transparent;
}
:where(.shell,.auth-screen) .recon-button.recon-primary:not(:disabled):hover { background: var(--primary-hover); }
.shell :is(.recon-table,.reports-table) { font-variant-numeric: tabular-nums; }
.shell .recon-table :is(th,td) { height: var(--v1-row); }
.shell .recon-table thead th { height: 34px; background: var(--table-header, var(--paper)); }
.shell .recon-table td:has(.recon-button) .recon-button { min-height: 28px; }
.shell td input[type=checkbox] { width: 14px; height: 14px; }
.shell .badge { font-size: 11px; border-radius: 5px; }
.shell .badge.warning { background: var(--warning-surface); color: var(--warning-ink); }
.shell :is(.recon-table-wrap,.clients-table,.inbox-table) { max-width: 100%; }
.shell :is(.recon-empty,.run-empty) { padding: 22px 10px; text-align: center; color: var(--muted); }
.shell :is(.recon-dialog,.run-drawer,.detail,.workbook-destination) { border: var(--hairline) solid var(--border); border-radius: var(--radius-dialog); }
.shell :where(.recon-dialog)::backdrop { background: var(--overlay); }
.shell :where(.run-drawer)[open] { animation-duration: var(--v1-motion-drawer); }
.shell :where(.recon-dialog,.detail,.workbook-destination)[open] { animation-duration: var(--v1-motion-dialog); }
.shell :where(details)[open] > :where(.profile-actions,.fr-invoice-more > div) { animation: v1-disclose var(--v1-motion-state) var(--v1-ease) both; }
.shell .profile-actions:not([hidden]) { animation: v1-disclose var(--v1-motion-state) var(--v1-ease) both; }
.shell :is(.documents-selection,.fr-selection,.excel-selection-bar):not([hidden]) { animation: v1-disclose var(--v1-motion-state) var(--v1-ease) both; }
.shell :focus-visible,.auth-screen :focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.shell :is(h1,h2)[tabindex="-1"]:focus { outline: none; }
@keyframes v1-disclose { from { opacity: 0; transform: translateY(3px); } to { opacity: 1; transform: none; } }
@media(min-width:761px) {
  .shell { transition: grid-template-columns 180ms var(--v1-ease); }
  [data-sidebar="compact"] .shell .sidebar { padding-inline: 5px; }
  [data-sidebar="compact"] .shell .brand { margin-inline: auto; }
  [data-sidebar="compact"] .shell .navigation a { justify-content: center; padding: 0; }
  [data-sidebar="compact"] .shell .profile-actions { inset-inline: calc(100% + 6px) auto; }
}
@media(max-width:760px) {
  :root .shell { --sidebar-width: var(--v1-compact); }
  :root:not([data-rail-open="true"]) .shell .sidebar { padding-inline: 5px; }
  :root:not([data-rail-open="true"]) .shell .brand { margin-inline: auto; }
  :root:not([data-rail-open="true"]) .shell .navigation a { padding: 0; }
  :root:not([data-rail-open="true"]) .shell .profile-actions { inset-inline: calc(100% + 6px) auto; }
}
@media(prefers-reduced-motion:reduce) {
  :root { --v1-motion-feedback: 0ms; --v1-motion-state: 0ms; --v1-motion-dialog: 0ms; --v1-motion-drawer: 0ms; }
  .shell, .shell .brand img { transition: none; }
}

.v1-overview { display: grid; gap: 14px; }
.v1-overview :is(h2,p,dl,ol,ul) { margin: 0; }
.overview-workspace .overview-module {
  padding: clamp(13px, 2vw, 18px);
  border: 0.5px solid var(--border);
  border-radius: 11px;
  background: var(--elevated);
}
.v1-overview section > header { margin-bottom: 11px; }
.v1-overview h2 { font-size: 15px; letter-spacing: -.016em; }
.v1-pipeline {
  display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 0; border-top: var(--hairline) solid var(--divider);
}
.v1-pipeline > div { min-width: 0; padding: 11px 12px 2px; }
.v1-pipeline dt a:hover { color: var(--link); }
.v1-pipeline > div + div { border-inline-start: var(--hairline) solid var(--border); }
.v1-pipeline dt { font-size: 12px; }
.v1-pipeline dd { text-align: start; font-weight: 675; font-size: clamp(19px,2.1vw,25px); margin: 3px 0 0; color: var(--ink); font-variant-numeric: tabular-nums; }
.v1-pipeline p { color: var(--muted); font-size: 11px; }
.v1-overview-main { min-width: 0; display: grid; gap: 14px; grid-template-columns: minmax(0,1.35fr) minmax(0,1fr); }
.v1-overview-main > :only-child { grid-column: 1 / -1; }
.v1-overview-bottom { align-items: start; }
.v1-overview .overview-onboarding a:hover { color: var(--link); text-decoration: underline; text-underline-offset: 3px; }
.overview-workspace .overview-module .overview-chevron-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  width: fit-content;
  color: var(--link);
  font-size: 12px;
  font-weight: 590;
  text-decoration: none;
}
.overview-chevron-link svg { flex: none; transition: transform var(--v1-motion-feedback) var(--v1-ease); }
.overview-chevron-link:hover svg { transform: translateX(2px); }
.overview-excel { display: flex; flex-direction: column; }
.overview-provider { display: flex; align-items: flex-start; gap: 10px; margin-block: 3px 12px; }
.overview-provider svg { flex: none; width: 23px; height: 23px; margin-top: 1px; }
.overview-provider strong { display: block; margin-bottom: 2px; }
.overview-provider p { overflow-wrap: anywhere; }
.overview-excel-footer { margin-top: auto; padding-top: 9px; border-top: var(--hairline) solid var(--divider); }
.shell .overview-module .overview-empty { display: block; padding-block: 14px 13px; }
.workspace-empty.overview-empty-clear::before,
.workspace-empty.overview-empty-clear::after { content: none; }
.overview-clear-art {
  position: relative;
  display: grid;
  place-items: center;
  width: 56px;
  height: 48px;
  margin: 0 auto 10px;
  border: var(--hairline) solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--muted);
}
.overview-clear-art svg + svg {
  position: absolute;
  inset-block-start: 4px;
  inset-inline-end: 3px;
  border-radius: 50%;
  background: var(--surface);
  box-shadow: 0 0 0 2px var(--surface);
  color: var(--ink);
}
.v1-attention { padding: 0; list-style: none; }
.v1-attention li a { display: grid; grid-template-columns: minmax(0,1fr) auto 13px; align-items: center; gap: 8px; padding: 6px 0; border-bottom: var(--hairline) solid var(--border); }
.v1-attention li a:hover { background: var(--row-hover); }
.v1-attention li:last-child a { border-bottom: 0; }
.overview-workspace .v1-inline-notice { padding: 9px 13px; background: var(--warning-surface); color: var(--warning-ink); }
.v1-inline-notice a { text-decoration: underline; }
.v1-settings-integrations { margin-block: 12px; }
.v1-settings-integrations h2 { margin-bottom: 4px; }
.v1-settings-integrations p { margin: 0 0 7px; }
.inbox-date-filters > div { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 6px; }
.inbox-date-filters[open] { grid-column: 1/-1; }
.shell .inbox-table th button { color: var(--ink); }
.shell .inbox-drawer .run-evidence-card { border: 0; border-top: var(--hairline) solid var(--border); border-radius: 0; padding-inline: 0; }
.shell .client-workflow-links { margin-block: 6px 12px; }
.shell .client-workflow-links .recon-button { min-height: 31px; }
.auth-screen :is(.auth-card,.journey-content) { max-width: 540px; border-radius: var(--radius-dialog); background: var(--elevated); }
.auth-screen :is(.auth-card,.journey-content) h1 { font-size: clamp(25px,4vw,34px); letter-spacing: -.035em; line-height: 1.15; }
.auth-screen :is(.auth-fields,.journey-form) :is(input,select):not([type=checkbox],[type=radio]) { border-color: var(--border); }
@media(max-width:850px) {
  .v1-overview-main { grid-template-columns: minmax(0,1fr); }
  .v1-pipeline { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .v1-pipeline > div:nth-child(4) { border-inline-start: 0; }
  .v1-pipeline > div:nth-child(n+4) { border-top: var(--hairline) solid var(--border); }
}
@media(max-width:540px) { .v1-pipeline { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .v1-pipeline > div:nth-child(n) { border-inline-start: 0; }
  .v1-pipeline > div:nth-child(even) { border-inline-start: var(--hairline) solid var(--border); }
  .v1-pipeline > div:nth-child(n+3) { border-top: var(--hairline) solid var(--border); }
}
.shell [data-sync-selected][hidden] { display: none; }
.v1-sync-receipt { margin-block: 8px; padding: 10px 12px; border: var(--hairline) solid var(--border); border-radius: var(--radius-control); }
.v1-sync-receipt header { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 5px 10px; }
.v1-sync-receipt header div { display: flex; flex-wrap: wrap; align-items: baseline; gap: 5px 8px; min-width: 0; overflow-wrap: anywhere; }
.v1-sync-receipt dl { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 8px 0 3px; }
.v1-sync-receipt dl div { display: flex; align-items: baseline; gap: 5px; }
.v1-sync-receipt dd { margin: 0; font-variant-numeric: tabular-nums; }
.v1-sync-receipt :is(dt,p) { font-size: 12px; }
.v1-sync-receipt .recon-button { min-height: 30px; }
.shell .fr-source-actions [data-expand-source]:not(:disabled) {
  background: transparent; color: var(--ink); border-color: var(--border);
}
.shell .fr-source-actions [data-expand-source]:not(:disabled):hover {
  background: var(--row-hover); border-color: var(--border-interactive);
}

/* Workspace filter bars and first-use states */
.shell .view-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 6px;
  padding-block: 8px;
  margin: 0 0 8px;
}
.shell .view-filters > label { flex: 0 1 180px; min-width: 110px; font-size: 11px; font-weight: 620; }
.shell .view-filters > label:has(> input[type="search"]), .shell .clients-toolbar > input {
  flex: 0 1 260px;
  max-width: 100%;
  position: relative;
}
.shell .clients-toolbar > select { flex: 0 1 130px; }
.shell .view-filters :is(input,select,summary) {
  min-height: 32px;
  height: 32px;
  border-radius: 6px;
  border-color: var(--border-interactive);
  font-size: 13px;
  font-weight: 500;
}
.shell .view-filters :is(input,select) { padding-block: 5px; }
.shell .view-filters :is(select,summary):hover { background-color: var(--row-hover); }
.shell .view-filter-menu { position: relative; align-self: end; flex: none; grid-column: auto; }
.shell .view-filter-menu > summary {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--ink);
  list-style: none;
  cursor: pointer;
}
.view-filter-menu > summary::-webkit-details-marker { display: none; }
.shell .view-filter-menu > summary::before {
  content: "";
  width: 13px;
  height: 11px;
  background: linear-gradient(currentColor 0 0) center 2px / 13px 1px,
    linear-gradient(currentColor 0 0) center 5px / 9px 1px,
    linear-gradient(currentColor 0 0) center 8px / 5px 1px;
  background-repeat: no-repeat;
  opacity: .75;
}
.shell .view-filter-menu > summary::after {
  content: "";
  width: 5px;
  height: 5px;
  margin: -2px 1px 0 2px;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  transform: rotate(45deg);
}
.shell .view-filter-menu[open] > summary { background: var(--selection); }
.shell .view-filter-menu:has(select:not(:disabled) option:checked:not([value=""])) > summary {
  background: var(--selection);
}
.shell .view-filter-menu:has(select:not(:disabled) option:checked:not([value=""])) > summary::before {
  color: var(--link);
  opacity: 1;
}
.shell .view-filter-menu[open] > summary::after { margin-top: 2px; transform: rotate(225deg); }
.shell .view-filter-menu > .view-filter-panel {
  position: absolute;
  inset: calc(100% + 5px) auto auto 0;
  z-index: 5;
  display: grid;
  gap: 9px;
  width: 260px;
  margin: 0;
  padding: 11px;
  background: var(--elevated);
  border: var(--hairline) solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow-menu);
}
.shell .view-filter-panel label { max-width: none; }
.shell .view-filter-panel label[hidden] { display: none; }
@media (max-width: 760px) {
  .shell .view-filters > label, .shell .view-filters > label:has(> input[type="search"]) { flex: 1 1 150px; }
  .shell .view-filter-menu[open] { flex-basis: 100%; }
  .shell .view-filter-menu > .view-filter-panel { position: static; width: min(100%, 350px); margin-top: 5px; box-shadow: none; }
}

.shell .workspace-empty {
  --illustration-line: color-mix(in srgb, var(--muted) 55%, var(--border));
  --illustration-detail: linear-gradient(var(--illustration-line) 0 0);
  position: relative;
  padding: 24px 14px 26px;
  text-align: center;
  color: var(--muted);
}
.workspace-empty::before, .workspace-empty::after {
  content: "";
  pointer-events: none;
  border: 1px solid var(--illustration-line);
  border-radius: 6px;
}
.workspace-empty::before {
  display: block;
  width: 44px;
  height: 35px;
  margin: 5px auto 17px;
  transform: translateX(-6px) rotate(-10deg);
  background: var(--surface);
}
.workspace-empty::after {
  position: absolute;
  inset-block-start: 34px;
  inset-inline-start: calc(50% - 16px);
  width: 44px;
  height: 35px;
  transform: rotate(7deg);
  background: var(--illustration-detail) 9px 10px / 23px 1px,
    var(--illustration-detail) 9px 16px / 19px 1px,
    var(--illustration-detail) 9px 22px / 13px 1px;
  background-repeat: no-repeat;
  background-color: var(--elevated);
}
.workspace-empty[data-empty="inbox"]::after {
  background-image: linear-gradient(35deg, transparent 47%, var(--illustration-line) 49% 52%, transparent 54%),
    linear-gradient(-35deg, transparent 47%, var(--illustration-line) 49% 52%, transparent 54%);
  background-size: 50% 62%;
  background-position: left top, right top;
}
.workspace-empty[data-empty="ledger"]::after {
  background-image: var(--illustration-detail), var(--illustration-detail), var(--illustration-detail);
  background-size: 100% 1px, 1px 100%, 100% 1px;
  background-position: center 10px, 15px center, center 21px;
}
.workspace-empty[data-empty="clients"]::after {
  background-image: radial-gradient(circle, var(--illustration-line) 0 4px, transparent 4.5px), var(--illustration-detail), var(--illustration-detail);
  background-size: 15px 100%, 13px 1px, 9px 1px;
  background-position: 4px center, 21px 13px, 21px 19px;
}
.workspace-empty[data-empty="activity"]::after {
  background-size: 4px 8px, 4px 13px, 4px 18px;
  background-position: 9px 22px, 19px 17px, 29px 12px;
}
.workspace-empty strong { display: block; color: var(--ink); font-size: 14px; font-weight: 680; }
.workspace-empty p { margin: 4px auto 0; max-width: 34ch; line-height: 1.45; }
.shell .overview-module .workspace-empty { margin-top: 0; padding-block: 12px; }
.overview-module .workspace-empty::after { inset-block-start: 22px; }
.overview-module .workspace-empty.overview-empty::after { inset-block-start: 24px; }

/* Centered dialogs share a frame while retaining workflow-specific sizing. */
.shell dialog:not(.run-drawer) {
  --modal-inset: clamp(14px, 3vw, 22px);
  --modal-rule: var(--divider);
  border: var(--hairline) solid var(--border);
  border-radius: 15px;
  background: var(--elevated);
  color: var(--ink);
  box-shadow: 0 3px 8px #1418230c, 0 22px 62px #14182330;
}
.shell dialog:not(.run-drawer)::backdrop { background: #20253412; backdrop-filter: blur(1px); }
[data-theme="dark"] .shell dialog:not(.run-drawer) { box-shadow: 0 4px 10px #0005, 0 24px 64px #0007; }
[data-theme="dark"] .shell dialog:not(.run-drawer)::backdrop { background: #0007; }
.shell dialog:is(.client-dialog,.verified-export-dialog,.fr-confirm) {
  width: min(620px, calc(100vw - 24px));
  max-width: none;
  max-height: calc(100dvh - 28px);
  padding: 0;
  overflow: hidden;
}
.shell dialog.fr-confirm { width: min(550px, calc(100vw - 24px)); }
.shell dialog:is(.client-dialog,.verified-export-dialog)[open] { display: grid; grid-template-rows: auto minmax(0,1fr); }
.shell dialog.fr-confirm[open] { display: grid; grid-template-rows: auto minmax(0,1fr) auto; }
.modal-form { min-height: 0; display: grid; grid-template-rows: minmax(0,1fr) auto; }
.shell .modal-body { min-height: 0; padding: 16px var(--modal-inset); overflow: auto; overscroll-behavior: contain; }
.modal-body > :first-child { margin-top: 0; }
.modal-body > :last-child { margin-bottom: 0; }
.shell :is(.modal-heading,.batch-header,.excel-dialog-heading,.destination-title-row) {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 10px var(--modal-inset);
  border-bottom: var(--hairline) solid var(--modal-rule);
}
.shell :is(.modal-heading,.batch-header,.excel-dialog-heading,.destination-title-row) h2 {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0;
  font-size: 17px;
  font-weight: 670;
  line-height: 1.25;
  letter-spacing: -.02em;
  overflow-wrap: anywhere;
}
.modal-symbol {
  flex: none;
  display: grid;
  place-items: center;
  width: 25px;
  height: 25px;
  border: var(--hairline) solid var(--border);
  border-radius: 7px;
  background: var(--surface);
  color: var(--ink);
}
.shell dialog:not(.run-drawer) :is(.modal-close,.excel-dialog-close) {
  position: static;
  flex: none;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-size: 20px;
  line-height: 1;
}
.shell dialog:not(.run-drawer) :is(.modal-close,.excel-dialog-close):hover { color: var(--ink); background: var(--row-hover); }
.shell :is(.modal-actions,.batch-actions,.destination-actions,.excel-sync-dialog > footer) {
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 9px var(--modal-inset);
  border-top: var(--hairline) solid var(--modal-rule);
  background: var(--surface);
}
.shell .modal-actions { display: flex; justify-content: flex-end; }
.shell .batch-actions button { min-height: var(--v1-control); }
.shell .batch-body { padding: 15px var(--modal-inset); }
.shell .excel-dialog-body { padding-inline: var(--modal-inset); }
.shell .destination-header { padding: 0; border-color: var(--modal-rule); }
.shell .destination-steps { padding: 7px var(--modal-inset); }
.shell .destination-body { padding: 16px var(--modal-inset); }

.shell .toast-host {
  position: fixed;
  z-index: 5;
  inset-inline-start: calc(var(--sidebar-width) + 16px);
  inset-block-end: max(16px, env(safe-area-inset-bottom));
  width: min(350px, calc(100vw - var(--sidebar-width) - 32px));
  pointer-events: none;
}
.toast-list { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.toast {
  display: grid;
  grid-template-columns: 21px minmax(0,1fr) 23px;
  align-items: start;
  gap: 8px;
  padding: 11px 10px 11px 12px;
  border: var(--hairline) solid var(--border);
  border-radius: 10px;
  background: var(--elevated);
  box-shadow: var(--shadow-menu);
  color: var(--ink);
  pointer-events: auto;
  animation: toast-enter 220ms var(--v1-ease) both;
}
.toast[data-leaving] { animation: toast-exit 150ms ease both; pointer-events: none; }
.toast-icon { display: grid; place-items: center; width: 21px; height: 21px; color: var(--muted); }
.toast[data-tone="success"] .toast-icon { color: var(--success-text); }
.toast[data-tone="warning"] .toast-icon { color: var(--warning-ink); }
.toast[data-tone="error"] .toast-icon { color: var(--error-ink); }
.toast-copy { min-width: 0; padding-block: 1px; overflow-wrap: anywhere; }
.toast-copy strong { display: block; font-size: 13px; font-weight: 690; line-height: 1.35; }
.toast-copy p { margin: 3px 0 0; color: var(--muted); font-size: 12px; line-height: 1.4; }
.toast-copy p:empty { display: none; }
.toast-action { display: inline-flex; align-items: center; gap: 4px; margin-top: 6px; color: var(--link); font-size: 12px; font-weight: 620; }
.toast-action:hover { text-decoration: underline; text-underline-offset: 2px; }
.toast-action svg { flex: none; }
.toast-dismiss { display: grid; place-items: center; width: 23px; height: 23px; padding: 0; border: 0; border-radius: 5px; background: transparent; color: var(--muted); }
.toast-dismiss:hover { background: var(--row-hover); color: var(--ink); }
@keyframes toast-enter { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes toast-exit { to { opacity: 0; transform: translateY(6px); } }
@media (prefers-reduced-motion: reduce) { .toast,.toast[data-leaving] { animation: none; } }

.shell .sidebar-footer { margin-top: auto; padding-top: 8px; border-top: var(--hairline) solid var(--divider); }
.sidebar-footer button {
  display: flex; align-items: center; gap: 8px; width: 100%; min-height: 32px;
  padding: 4px 8px; border: 0; border-radius: 6px; background: transparent; color: var(--ink);
  text-align: start; font-size: 13px; font-weight: 550;
}
.sidebar-footer button svg { flex: none; color: var(--muted); }
.sidebar-footer button:hover { background: var(--row-hover); }
@media (min-width:761px) {
  [data-sidebar="compact"] .sidebar-footer button { justify-content: center; }
  [data-sidebar="compact"] .sidebar-footer span { display: none; }
}
@media (max-width:760px) {
  :root:not([data-rail-open="true"]) .sidebar-footer button { justify-content: center; }
  :root:not([data-rail-open="true"]) .sidebar-footer span { display: none; }
}
.workspace-switch-list { display: grid; gap: 3px; }
.profile-actions .workspace-switch-list:not([hidden]) { padding-bottom: 5px; margin-bottom: 5px; border-bottom: var(--hairline) solid var(--divider); }
.workspace-switch-list[hidden] { display: none; }
.profile-actions .workspace-switch-list [aria-current] { background: var(--selection); }
.members-workspace [data-open-invite][hidden], .clients-page :is([data-add],[data-client],.recon-actions)[hidden] { display: none; }
.members-workspace .recon-error, .workspace-profile-form .recon-error { color: var(--error-ink); }
.workspace-profile-form { margin-top: 14px; }
.workspace-profile-form button { justify-self: start; }
.members-back { display: inline-block; margin-bottom: 7px; color: var(--link); font-size: 12px; }
.members-card { max-width: none; margin-bottom: 12px; padding: 14px; }
.members-card h2 { margin: 0 0 10px; }
.members-card table { min-width: 480px; }
.members-card th small, .members-card td small { display: block; margin-top: 3px; color: var(--muted); overflow-wrap: anywhere; }
.members-card select { width: 130px; min-height: 30px; padding-inline-start: 8px; border: var(--hairline) solid var(--border); border-radius: var(--radius-control); background-color: var(--paper); color: var(--ink); }
.members-row-actions { display: flex; gap: 5px; }
.shell .invite-members-dialog { width: min(560px, calc(100vw - 24px)); max-width: none; max-height: calc(100dvh - 28px); padding: 0; overflow: hidden; }
.invite-members-dialog[open] { display: grid; grid-template-rows: auto minmax(0, 1fr); animation: invite-enter 220ms var(--v1-ease) both; }
.invite-members-dialog[data-closing] { animation: invite-exit 155ms ease both; }
.invite-members-dialog textarea {
  width: 100%; min-height: 76px; padding: 9px; resize: vertical; background: var(--paper); color: var(--ink);
  border: var(--hairline) solid var(--border); border-radius: var(--radius-control);
}
.invite-members-dialog .run-muted { margin: -6px 0 0; font-size: 12px; }
.invite-members-dialog [data-invite-error] { margin: 0; white-space: pre-line; }
.invite-members-dialog kbd { padding: 1px 4px; border-radius: 4px; border: 1px solid #ffffff50; font: inherit; font-size: 11px; }
@keyframes invite-enter { from { opacity: 0; transform: translateY(8px) scale(.99); } to { opacity: 1; transform: none; } }
@keyframes invite-exit { to { opacity: 0; transform: translateY(5px) scale(.995); } }
@media (prefers-reduced-motion:reduce) { .invite-members-dialog[open], .invite-members-dialog[data-closing] { animation: none; } }
