:root {
  color-scheme: light;
  --bg: #eef1f4;
  --panel: #ffffff;
  --panel-2: #eef2f4;
  --ink: #172126;
  --muted: #66737c;
  --line: #d8dee2;
  --line-strong: #bdc7cd;
  --accent: #5b46bf;
  --accent-ink: #ffffff;
  --danger: #b5393b;
  --warning: #a15c00;
  --success: #23764d;
  --nav: #08111d;
  --nav-2: #111c2c;
  --nav-ink: #d6dde8;
  --hot: #ec3d73;
  --shadow: 0 16px 48px rgba(28, 40, 46, 0.14);
  --radius: 8px;
  /* Shared by the shell columns and their floating collapse controls. */
  --projects-pane-width: 292px;
  --overview-pane-width: 292px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.collaboration-session-page {
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  padding: 24px;
}

.collaboration-empty-page {
  display: grid;
  place-items: center;
}

.collaboration-session-card {
  width: min(560px, 100%);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 28px;
  box-shadow: var(--shadow);
}

.collaboration-session-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin: 0 auto 20px;
  max-width: 1800px;
}

.collaboration-session-header h1 {
  margin: 4px 0;
  font-size: clamp(30px, 3vw, 54px);
  line-height: 1;
}

.collaboration-session-header p {
  margin: 0;
  color: var(--muted);
}

.public-calendar-page {
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  padding: 18px;
}

.public-calendar-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  max-width: 1800px;
  margin: 0 auto 12px;
}

.public-calendar-header h1 {
  margin: 2px 0 4px;
  font-size: clamp(28px, 3vw, 46px);
  line-height: 1;
}

.public-calendar-header p {
  margin: 0;
  color: var(--muted);
}

.public-calendar-frame-shell {
  max-width: 1800px;
  height: calc(100vh - 118px);
  margin: 0 auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  box-shadow: var(--shadow);
}

.public-calendar-frame {
  width: 100%;
  height: 100%;
  border: 0;
  background: #fff;
}

.collaboration-session-header .collaboration-created-by,
.collaboration-created-by {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.collaboration-session-actions,
.inline-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.collaboration-session-layout {
  max-width: 1800px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 430px);
  gap: 18px;
  align-items: start;
}

.collaboration-compare-panel,
.collaboration-panel-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow: var(--shadow-soft);
}

.collaboration-compare-panel {
  padding: 16px;
  min-width: 0;
}

.collaboration-compare-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: end;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.collaboration-compare-toolbar h2,
.collaboration-panel-card h3 {
  margin: 0;
}

.collaboration-compare-toolbar p {
  margin: 4px 0 0;
  color: var(--muted);
}

.collaboration-compare-toolbar .compact-field {
  width: min(420px, 45%);
}

.collaboration-display-controls {
  display: flex;
  flex-wrap: nowrap;
  gap: 6px;
  align-items: center;
  justify-content: flex-end;
}

.collaboration-display-controls label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  padding: 4px 7px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--text);
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.collaboration-display-controls input {
  width: 12px;
  height: 12px;
}

.collaboration-compare-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.collaboration-calendar {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  min-width: 0;
}

.collaboration-calendar-head {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  background: #f7f9fb;
}

.collaboration-calendar-head h3 {
  margin: 0;
  font-size: 18px;
}

.collaboration-calendar-month {
  display: grid;
  grid-template-rows: auto auto;
  min-width: 0;
}

.collaboration-calendar-header {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.collaboration-calendar-header div {
  padding: 7px 8px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #f2f5f8;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.collaboration-calendar-header div:last-child {
  border-right: 0;
}

.collaboration-calendar-body {
  display: grid;
  min-width: 0;
}

.collaboration-calendar-row {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  grid-template-rows: 30px repeat(var(--collaboration-lanes, 1), minmax(0, 1fr));
  min-height: max(112px, calc(30px + (var(--collaboration-lanes, 1) * 30px)));
  overflow: hidden;
  position: relative;
  background: #fbfcfc;
  border-bottom: 1px solid var(--line);
}

.collaboration-calendar-row:last-child {
  border-bottom: 0;
}

.collaboration-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.collaboration-calendar-weekday,
.collaboration-calendar-day {
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.collaboration-calendar-weekday:nth-child(7n),
.collaboration-calendar-day:nth-child(7n) {
  border-right: 0;
}

.collaboration-calendar-weekday {
  padding: 7px 8px;
  font-weight: 800;
  color: var(--muted);
  background: #f2f5f8;
  font-size: 13px;
}

.collaboration-calendar-day {
  min-height: 112px;
  padding: 7px;
  position: relative;
}

.collaboration-calendar-row .collaboration-calendar-day {
  min-height: 0;
  border-bottom: 0;
  padding: 7px;
}

.collaboration-calendar-row .collaboration-calendar-day:last-of-type {
  border-right: 0;
}

.collaboration-calendar-day.muted-day {
  background: #f6f7f8;
  color: var(--muted);
}

.collaboration-date {
  display: block;
  font-weight: 800;
  font-size: 14px;
  margin-bottom: 6px;
}

.collaboration-day-activities {
  display: grid;
  gap: 4px;
}

.collaboration-activity-block {
  min-height: 38px;
  padding: 5px 6px;
  gap: 1px;
}

.collaboration-calendar-row .collaboration-activity-block {
  align-self: stretch;
  margin: 0;
  min-height: 0;
  max-height: none;
  overflow: hidden;
  z-index: 2;
}

.collaboration-activity-block.changed {
  outline: 2px solid rgba(91, 70, 191, 0.7);
  outline-offset: 1px;
}

.collaboration-activity-block.proposed {
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.55), inset 0 0 0 1px rgba(47, 143, 91, 0.35);
}

.collaboration-activity-block strong {
  font-size: 11px;
}

.collaboration-activity-block span {
  font-size: 10px;
}

.collaboration-activity-block .activity-tags {
  margin-top: 1px;
}

.collaboration-activity-block .activity-tags i {
  font-size: 9px;
  padding: 1px 5px;
}

.collaboration-activity-chip {
  width: 100%;
  border: 1px solid rgba(15, 124, 128, 0.2);
  border-radius: 6px;
  background: #d9efef;
  color: #10202b;
  text-align: left;
  padding: 5px 6px;
  min-width: 0;
  cursor: pointer;
}

.collaboration-activity-chip b,
.collaboration-activity-chip small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collaboration-activity-chip b {
  font-size: 12px;
}

.collaboration-activity-chip small {
  font-size: 11px;
  color: #4f6171;
}

.collaboration-activity-chip.changed {
  border-color: #5b46bf;
  background: #eee9ff;
}

.collaboration-activity-chip.proposed {
  border-color: #2f8f5b;
  background: #def7e9;
}

.collaboration-more {
  font-size: 12px;
  color: var(--muted);
  font-weight: 800;
}

.collaboration-side-panel {
  display: grid;
  gap: 14px;
}

.collaboration-panel-card {
  padding: 14px;
}

.collaboration-session-patch-form,
.collaboration-message-compose,
.collaboration-link-create {
  display: grid;
  gap: 10px;
}

.collaboration-message-list,
.collaboration-request-stack,
.collaboration-link-list {
  display: grid;
  gap: 10px;
  max-height: 360px;
  overflow: auto;
  padding-right: 4px;
}

.collaboration-message {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  background: #fbfcfd;
}

.collaboration-message div {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.collaboration-message p {
  margin: 6px 0 0;
  white-space: pre-wrap;
}

.collaboration-link-create {
  grid-template-columns: 1fr;
}

.collaboration-link-row {
  display: grid;
  grid-template-columns: minmax(90px, 130px) 1fr;
  gap: 8px;
  align-items: center;
}

.collaboration-link-row span {
  min-width: 0;
}

.collaboration-link-row b,
.collaboration-link-row small {
  display: block;
}

.collaboration-link-row small {
  color: var(--muted);
  font-size: 12px;
}

.collaboration-link-row input {
  font-size: 12px;
}

.public-collaboration-page .collaboration-panel-card:first-child {
  background: #f7f5ff;
  border-color: rgba(91, 70, 191, 0.25);
}

@media (max-width: 1180px) {
  .collaboration-session-layout,
  .collaboration-compare-grid {
    grid-template-columns: 1fr;
  }

  .collaboration-compare-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .collaboration-compare-toolbar .compact-field {
    width: 100%;
  }
}

@media (max-width: 760px) {
  .collaboration-session-page {
    padding: 14px;
  }

  .collaboration-session-header {
    flex-direction: column;
  }

  .collaboration-session-actions {
    justify-content: flex-start;
  }

  .collaboration-calendar-day {
    min-height: 92px;
    padding: 5px;
  }
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  min-width: 320px;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

button:disabled,
input:disabled,
select:disabled,
textarea:disabled {
  cursor: not-allowed;
  opacity: 0.65;
}

.app-shell {
  --projects-pane-track: var(--projects-pane-width);
  --overview-pane-track: var(--overview-pane-width);
  position: relative;
  display: grid;
  grid-template-columns: var(--projects-pane-track) minmax(0, 1fr) var(--overview-pane-track);
  height: 100vh;
  min-height: 100vh;
  overflow: hidden;
}

.app-shell.role-previewing {
  height: calc(100vh - 44px);
  min-height: calc(100vh - 44px);
}

.app-shell.role-previewing .sidebar,
.app-shell.role-previewing .inspector {
  height: calc(100vh - 44px);
}

.role-preview-banner {
  position: relative;
  z-index: 120;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: 44px;
  padding: 6px 12px 6px 16px;
  border-bottom: 1px solid #a890f2;
  background: #ede8ff;
  color: #241858;
}

.role-preview-banner > span,
.role-preview-banner > span > span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.role-preview-banner .icon {
  width: 18px;
  height: 18px;
}

.role-preview-banner small {
  margin-left: 4px;
  color: #665b8f;
}

.role-preview-banner .button {
  min-height: 30px;
  background: #fff;
}

.role-preview-banner + .client-review-screen {
  min-height: calc(100vh - 44px);
}

.app-shell.left-collapsed {
  --projects-pane-track: 0px;
}

.app-shell.right-collapsed {
  --overview-pane-track: 0px;
}

.app-shell.left-collapsed .sidebar,
.app-shell.right-collapsed .inspector {
  overflow: hidden;
  padding: 0;
  border: 0;
  pointer-events: none;
}

.sidebar,
.inspector {
  background: var(--panel);
  border-right: 1px solid var(--line);
  height: 100vh;
  min-height: 0;
  overflow: auto;
  position: relative;
}

.sidebar {
  background: var(--nav);
  color: var(--nav-ink);
  border-right: 0;
  overflow-x: hidden;
  overflow-y: auto;
  z-index: 30;
  isolation: isolate;
  contain: paint;
  box-shadow: 1px 0 0 var(--nav);
}

.inspector {
  border-left: 1px solid var(--line);
  border-right: 0;
}

.pane-restore {
  position: fixed;
  top: 50%;
  width: 16px;
  height: 96px;
  transform: translateY(-50%);
  border: 1px solid var(--line-strong);
  background: var(--panel);
  color: #5d6874;
  z-index: 110;
  box-shadow: 0 8px 20px rgba(17, 24, 39, 0.18);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.pane-restore-left {
  border-radius: 0 10px 10px 0;
}

.pane-restore-right {
  border-radius: 10px 0 0 10px;
}

.pane-restore-left.open {
  left: var(--projects-pane-width);
}

.pane-restore-left.collapsed {
  left: 0;
}

.pane-restore-right.open {
  right: var(--overview-pane-width);
}

.pane-restore-right.collapsed {
  right: 0;
}

.pane-restore .icon {
  width: 14px;
  height: 36px;
}

.brand {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.brand h1 {
  font-size: 22px;
  line-height: 1;
  margin: 0;
  letter-spacing: 0;
}

.brand-logo {
  display: block;
  width: 142px;
  max-width: calc(100% - 96px);
  height: auto;
}

.brand-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

.brand .icon-button {
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.04);
  color: var(--nav-ink);
}

.brand .notification-bell {
  background: #ffffff;
  border-color: #ffffff;
  color: var(--nav);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.28);
}

.brand .icon-button.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}

.brand .notification-bell.has-unread {
  background: #ffd84d;
  border-color: #ffd84d;
  color: #172126;
}

.brand .toolbar-badge {
  border-color: var(--nav);
}

.session {
  padding: 12px 16px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--nav-ink);
}

.session-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
  min-width: 0;
}

.workspace-switcher {
  display: grid;
  gap: 6px;
  margin-bottom: 10px;
  min-width: 0;
}

.workspace-switcher span {
  color: #9aa7b8;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.workspace-switcher select {
  width: 100%;
  min-width: 0;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: var(--nav-2);
  color: var(--nav-ink);
  font-weight: 800;
}

.session small,
.field small,
.muted,
.task-meta,
.report-meta {
  color: var(--muted);
}

.project-list {
  padding: 12px;
  min-width: 0;
  overflow: hidden;
}

.nav-section,
.settings-item {
  display: grid;
  grid-template-columns: 22px 1fr auto;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 46px;
  padding: 0 12px;
  border-radius: 8px;
  background: transparent;
  color: var(--nav-ink);
  text-align: left;
  font-weight: 750;
  min-width: 0;
}

.nav-section:hover,
.settings-item:hover {
  background: rgba(255, 255, 255, 0.08);
}

.nav-section b {
  min-width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  color: #dbe3ef;
  font-size: 12px;
}

.nav-children {
  display: grid;
  gap: 4px;
  margin: 4px 0 12px;
  padding-left: 8px;
  min-width: 0;
  overflow: hidden;
}

.project-selector-list {
  max-height: min(52vh, 560px);
  overflow-y: auto;
  padding-right: 4px;
}

.project-selector-list::-webkit-scrollbar {
  width: 8px;
}

.project-selector-list::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.16);
  border-radius: 999px;
}

.project-list-label {
  padding: 8px 8px 2px 24px;
  color: #7f8da0;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
}

.project-health-sidebar-button {
  min-height: 38px;
  margin-bottom: 3px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
}

.project-health-sidebar-button .icon {
  color: #79d0bf;
}

.sidebar .section-title h2,
.sidebar .session small,
.sidebar .project-group {
  color: #9aa7b8;
}

.sidebar .button {
  background: var(--nav-2);
  color: var(--nav-ink);
  border-color: rgba(255, 255, 255, 0.1);
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 4px 4px 10px;
}

.section-title-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.section-title h2,
.inspector h2,
.dialog h2 {
  font-size: 15px;
  margin: 0;
  letter-spacing: 0;
}

.project-item {
  display: grid;
  grid-template-columns: 16px 1fr auto;
  align-items: center;
  gap: 10px;
  width: 100%;
  background: transparent;
  color: var(--ink);
  padding: 9px 8px;
  border-radius: var(--radius);
  text-align: left;
  min-width: 0;
  max-width: 100%;
}

.sidebar .project-item {
  color: var(--nav-ink);
  border-radius: 8px;
  min-height: 52px;
}

.project-item:hover,
.project-item.active {
  background: var(--panel-2);
}

.sidebar .project-item:hover {
  background: rgba(255, 255, 255, 0.08);
}

.sidebar .project-item.active {
  background: var(--accent);
  color: #fff;
}

.sidebar .pill {
  background: rgba(255, 255, 255, 0.1);
  color: #dbe3ef;
  justify-self: end;
  max-width: 48px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.color-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.16);
}

.project-name {
  display: inline-block;
  max-width: 100%;
  font-weight: 650;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.project-group {
  color: var(--muted);
  font-size: 12px;
}

.project-item > span:nth-child(2),
.settings-item span,
.nav-section span,
.session-row > div {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.main {
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-rows: auto 1fr;
  overflow: hidden;
}

.toolbar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 6px 10px;
  background: #f8fafc;
  border-bottom: 1px solid var(--line);
}

.toolbar-date-nav {
  display: grid;
  gap: 2px;
  align-items: center;
  justify-items: center;
}

.toolbar h2 {
  font-size: 18px;
  line-height: 1;
  margin: 0;
  text-align: center;
  color: #172126;
  font-weight: 450;
  letter-spacing: 0;
  min-height: 20px;
  white-space: nowrap;
}

.calendar-view-switch > button {
  width: 36px;
  min-width: 36px;
  padding-inline: 0;
  font-weight: 850;
}

.toolbar h2 strong {
  font-weight: 850;
}

.toolbar-cluster,
.button-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  min-width: 0;
}

.toolbar-compact {
  gap: 4px;
}

.toolbar-tools {
  justify-content: flex-start;
}

.tool-divider {
  width: 1px;
  height: 26px;
  background: var(--line-strong);
  margin: 0 4px;
}

.toolbar-filter {
  width: 150px;
  margin-left: auto;
}

.toolbar-filter summary {
  min-height: 34px;
  padding: 5px 8px;
  gap: 6px;
}

.toolbar-filter summary .icon {
  flex: 0 0 auto;
}

.toolbar-filter .multi-select-menu {
  min-width: 240px;
}

.calendar-people-filter {
  flex: 0 0 150px;
}

.calendar-people-filter[open] {
  z-index: 90;
}

.calendar-people-filter summary span {
  display: none;
}

.calendar-people-filter summary b {
  max-width: 86px;
}

.toolbar-resource-filter {
  margin-left: auto;
  min-height: 34px;
  padding: 0 10px;
  gap: 6px;
  white-space: nowrap;
}

.toolbar-resource-filter b {
  min-width: 20px;
  padding: 2px 6px;
  border-radius: 999px;
  background: rgba(23, 33, 38, 0.1);
  color: inherit;
  font-size: 12px;
  line-height: 1;
}

.toolbar-resource-filter.primary b {
  background: rgba(255, 255, 255, 0.2);
}

.help-menu {
  position: relative;
  flex: 0 0 auto;
}

.help-menu {
  margin-left: auto;
}

.help-menu summary {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-weight: 850;
  list-style: none;
  cursor: pointer;
}

.help-menu summary::-webkit-details-marker {
  display: none;
}

.help-menu summary::after {
  content: "";
  width: 7px;
  height: 7px;
  margin-left: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
}

.help-menu[open] {
  z-index: 95;
}

.help-menu[open] summary::after {
  transform: translateY(2px) rotate(225deg);
}

.help-menu-panel {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 180px;
  display: grid;
  gap: 4px;
  padding: 6px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.help-menu-panel button {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 10px;
  border-radius: 6px;
  background: transparent;
  color: var(--ink);
  font-weight: 850;
  text-align: left;
}

.help-menu-panel button:hover {
  background: #f3f6f8;
}

.help-menu-panel .icon {
  width: 16px;
  height: 16px;
  color: var(--accent);
}

.toolbar-action-menu {
  position: relative;
  flex: 0 0 auto;
}

.toolbar-action-menu > summary {
  list-style: none;
  cursor: pointer;
}

.toolbar-action-menu > summary::-webkit-details-marker {
  display: none;
}

.toolbar-action-menu[open] {
  z-index: 96;
}

.toolbar-action-menu[open] > summary {
  border-color: var(--accent);
  background: #eef0ff;
  color: var(--accent);
}

.toolbar-action-menu-panel {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 220px;
  display: grid;
  gap: 3px;
  padding: 6px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.toolbar-action-menu-panel button {
  min-height: 34px;
  width: 100%;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 10px;
  border-radius: 6px;
  background: transparent;
  color: var(--ink);
  font-weight: 700;
  text-align: left;
}

.toolbar-action-menu-panel button:hover,
.toolbar-action-menu-panel button.selected {
  background: #f0f3f6;
}

.toolbar-action-menu-panel button.selected {
  box-shadow: inset 3px 0 0 var(--accent);
}

.toolbar-action-menu-panel button.danger {
  color: var(--danger);
}

.toolbar-action-menu-panel button:disabled {
  opacity: 0.42;
  cursor: not-allowed;
}

.toolbar-action-menu-panel .icon {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  color: var(--accent);
}

.toolbar-action-menu-panel button.danger .icon {
  color: currentColor;
}

.toolbar-action-menu-divider {
  height: 1px;
  margin: 3px 6px;
  background: var(--line);
}

.toolbar-action-menu-label {
  min-height: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 2px 7px 0;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.toolbar-action-menu-label small {
  font-size: 10px;
  font-weight: 650;
}

.toolbar-block-color-switch {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0 3px 3px;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  background: var(--panel);
}

.toolbar-action-menu-panel .toolbar-block-color-switch button {
  min-height: 30px;
  width: auto;
  justify-content: center;
  padding: 0 6px;
  border-radius: 0;
  border-right: 1px solid var(--line);
  font-size: 11px;
  text-align: center;
}

.toolbar-action-menu-panel .toolbar-block-color-switch button:last-child {
  border-right: 0;
}

.toolbar-action-menu-panel .toolbar-block-color-switch button.selected {
  background: var(--ink);
  box-shadow: none;
  color: #fff;
}

.dialog-action-menu {
  margin-right: auto;
}

.dialog-action-menu .toolbar-action-menu-panel {
  top: auto;
  right: auto;
  bottom: calc(100% + 6px);
  left: 0;
}

.day-mode-button {
  position: relative;
  width: 42px;
  padding: 0;
}

.day-mode-button .icon {
  width: 26px;
  height: 26px;
}

.day-mode-button span {
  position: absolute;
  left: 50%;
  top: 58%;
  transform: translate(-50%, -50%);
  font-size: 10px;
  font-weight: 900;
  line-height: 1;
}

.family-mode-button {
  width: 38px;
  padding: 0;
}

.family-mode-button .icon {
  width: 22px;
  height: 22px;
}

.button,
.icon-button,
.segmented button {
  min-height: 36px;
  border-radius: var(--radius);
  border: 1px solid var(--line-strong);
  background: var(--panel);
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 12px;
  font-weight: 650;
  transition: transform 90ms ease, box-shadow 90ms ease, background-color 120ms ease, border-color 120ms ease, opacity 120ms ease;
}

.button:active,
.icon-button:active,
.segmented button:active {
  transform: translateY(1px) scale(0.985);
  box-shadow: inset 0 2px 5px rgba(23, 33, 38, 0.16);
}

.button.is-saving,
.button[aria-busy="true"] {
  transform: translateY(1px);
  box-shadow: inset 0 2px 6px rgba(23, 33, 38, 0.22);
}

.button.primary,
.icon-button.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}

.button.danger {
  color: var(--danger);
  border-color: #e3b8b9;
}

.danger-icon {
  color: var(--danger);
}

.icon-button.warn {
  color: var(--warning);
  border-color: rgba(161, 92, 0, 0.35);
  background: #fff7ed;
}

.icon-button {
  width: 36px;
  padding: 0;
  flex: 0 0 36px;
  position: relative;
}

.zoom-reset-button {
  min-width: 48px;
  padding: 0 9px;
}

.calendar-view-reset-button {
  width: 32px;
  min-height: 32px;
  flex-basis: 32px;
  padding: 0;
  opacity: 0.84;
}

.calendar-view-reset-button .icon {
  width: 14px;
  height: 14px;
}

.toolbar-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  border: 2px solid #f8fafc;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 850;
}

.tracker-view,
.tracker-theme-scope {
  --tracker-canvas: transparent;
  --tracker-surface: #fff;
  --tracker-surface-raised: #f8fafc;
  --tracker-surface-summary: #fbfcfd;
  --tracker-surface-hover: #f9fbfc;
  --tracker-text: #172126;
  --tracker-text-soft: #37444b;
  --tracker-muted: #657381;
  --tracker-line: var(--line);
  --tracker-line-strong: var(--line-strong);
}

.tracker-view {
  height: 100%;
  min-height: 0;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto;
  gap: 7px;
  padding: 8px 10px 10px;
  overflow: hidden;
  background: var(--tracker-canvas);
  color: var(--tracker-text);
}

.tracker-view.tracker-theme-dark,
.tracker-theme-scope.tracker-theme-dark {
  --panel: #20282e;
  --panel-2: #1b2328;
  --ink: #eef2f4;
  --ink-soft: #d4dce1;
  --muted: #9eabb4;
  --line: #354149;
  --line-strong: #4b5963;
  --tracker-canvas: #11171b;
  --tracker-surface: #182025;
  --tracker-surface-raised: #212a30;
  --tracker-surface-summary: #1d252a;
  --tracker-surface-hover: #232d33;
  --tracker-text: #eef2f4;
  --tracker-text-soft: #d4dce1;
  --tracker-muted: #9eabb4;
  --tracker-line: #354149;
  --tracker-line-strong: #4b5963;
  color-scheme: dark;
}

.tracker-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 32px;
}

.tracker-presence {
  display: flex;
  align-items: center;
  gap: 3px;
  flex-shrink: 0;
}

.tracker-presence[hidden] { display: none; }

.tracker-presence-person {
  display: grid;
  place-items: center;
  width: 25px;
  height: 25px;
  border-radius: 50%;
  background: var(--presence-color);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
}

.tracker-presence-more { font-size: 11px; color: var(--tracker-muted); }

.tracker-table tbody tr[data-tracker-row-id] > td {
  padding-bottom: 24px;
}

.tracker-table tbody tr[data-tracker-row-id] > td:not([data-tracker-frozen]) {
  position: relative;
}

.tracker-table td.tracker-presence-cell[data-tracker-column-id] {
  outline: 1px dashed var(--presence-color);
  outline-offset: -2px;
}

.tracker-table td.tracker-presence-editing[data-tracker-column-id] {
  outline-width: 2px;
  outline-style: solid;
}

.tracker-table tbody tr[data-tracker-row-id] > td.editing[data-tracker-column-id] {
  padding-bottom: 24px;
}

.tracker-table td[data-tracker-column-id] > .tracker-presence-label {
  display: block;
  -webkit-line-clamp: unset;
  position: absolute;
  bottom: 3px;
  right: 6px;
  max-width: calc(100% - 12px);
  padding: 1px 4px;
  border-radius: 3px;
  background: var(--presence-color);
  color: #fff;
  font-size: 10px;
  line-height: 14px;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  user-select: none;
}

.tracker-title-group {
  display: flex;
  align-items: baseline;
  gap: 10px;
  min-width: 0;
}

.tracker-head-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  flex-wrap: wrap;
  min-width: 0;
  max-width: 100%;
}

.tracker-head-actions .tracker-column-menu {
  width: auto;
  flex: 0 0 auto;
}

.tracker-head-actions .compact-button {
  min-height: 30px;
  height: 30px;
  padding: 3px 8px;
  font-size: 12px;
}

.tracker-head-actions .icon-button.compact-button {
  width: 30px;
  min-width: 30px;
  flex-basis: 30px;
  padding: 0;
}

.tracker-named-view-controls {
  display: flex;
  align-items: center;
  gap: 4px;
}

.tracker-named-view-controls select {
  width: 146px;
  min-height: 30px;
  height: 30px;
  padding: 3px 24px 3px 8px;
  border: 1px solid var(--tracker-line-strong);
  border-radius: 5px;
  background: var(--tracker-surface);
  color: var(--tracker-text);
  font: inherit;
  font-size: 12px;
  font-weight: 750;
}

.tracker-head h3 {
  margin: 0;
  font-size: 16px;
  line-height: 1.2;
}

.tracker-theme-toggle {
  position: relative;
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 8px;
  border: 1px solid var(--tracker-line-strong);
  border-radius: 5px;
  background: var(--tracker-surface);
  color: var(--tracker-text-soft);
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
}

.tracker-theme-toggle input {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

.tracker-theme-toggle i {
  position: relative;
  width: 25px;
  height: 14px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--tracker-muted) 34%, var(--tracker-surface));
  transition: background-color 120ms ease;
}

.tracker-theme-toggle i::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--tracker-surface);
  box-shadow: 0 1px 2px rgba(13, 21, 28, 0.26);
  transition: transform 120ms ease;
}

.tracker-theme-toggle input:checked + i {
  background: var(--accent);
}

.tracker-theme-toggle input:checked + i::after {
  transform: translateX(11px);
}

.tracker-theme-toggle:has(input:focus-visible) {
  outline: 2px solid color-mix(in srgb, var(--accent) 55%, transparent);
  outline-offset: 1px;
}

.tracker-filter-region {
  display: grid;
  gap: 6px;
}

.tracker-filters {
  --tracker-filter-select-count: 4;
  display: grid;
  grid-template-columns: repeat(var(--tracker-filter-select-count), minmax(112px, 1fr)) minmax(170px, 1.15fr) minmax(116px, auto);
  gap: 6px;
  align-items: end;
}

.activity-completion-suggestion {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  margin-bottom: 12px;
}

.tracker-filters-with-activity-status {
  --tracker-filter-select-count: 5;
}

.tracker-filters label,
.tracker-filter-field {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.tracker-filters span {
  font-size: 10px;
  font-weight: 800;
  color: var(--tracker-text-soft);
}

.tracker-filters select,
.tracker-filters input {
  min-height: 30px;
  height: 30px;
  padding: 3px 8px;
  border: 1px solid var(--tracker-line-strong);
  border-radius: 5px;
  background: var(--tracker-surface);
  color: var(--tracker-text);
  font: inherit;
  font-size: 12px;
}

.tracker-status-filter .multi-select-dropdown summary {
  min-height: 30px;
  height: 30px;
  padding: 3px 8px;
  border-color: var(--tracker-line-strong);
  border-radius: 5px;
  background: var(--tracker-surface);
  color: var(--tracker-text);
}

.tracker-status-filter .multi-select-dropdown summary b {
  color: inherit;
}

.tracker-status-filter .multi-select-dropdown[open] {
  z-index: 95;
}

.tracker-status-filter .multi-select-menu {
  min-width: 210px;
  max-height: min(360px, calc(100vh - 170px));
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-color: var(--tracker-line-strong);
  background: var(--tracker-surface);
}

.tracker-status-filter-options {
  min-height: 0;
  max-height: 270px;
  overflow: auto;
}

.tracker-status-group-presets {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  flex-shrink: 0;
  margin-bottom: 6px;
  border: 1px solid var(--tracker-line-strong);
  border-radius: 4px;
  overflow: hidden;
}

.tracker-status-group-presets button,
.tracker-status-custom-group,
.tracker-status-group-name {
  min-width: 0;
  min-height: 30px;
  border: 0;
  padding: 5px 8px;
  background: transparent;
  color: var(--tracker-text);
  font: inherit;
  cursor: pointer;
}

.tracker-status-group-presets button + button {
  border-left: 1px solid var(--tracker-line-strong);
}

.tracker-status-group-presets button[aria-pressed="true"],
.tracker-status-custom-group[aria-pressed="true"],
.tracker-status-group-name[aria-pressed="true"] {
  background: var(--tracker-surface-raised);
  font-weight: 700;
  box-shadow: inset 0 -2px var(--accent);
}

.tracker-status-custom-group,
.tracker-status-group-name {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  text-align: left;
}

.tracker-status-custom-group span,
.tracker-status-group-name span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.tracker-status-custom-group svg,
.tracker-status-group-name svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.tracker-status-filter-options hr {
  border: 0;
  border-top: 1px solid var(--tracker-line);
  margin: 6px 0;
}

.tracker-status-filter-actions {
  position: sticky;
  bottom: -6px;
  display: flex;
  flex-shrink: 0;
  justify-content: flex-end;
  gap: 6px;
  margin: 6px -6px -6px;
  padding: 6px;
  border-top: 1px solid var(--tracker-line);
  background: var(--tracker-surface);
}

.tracker-status-filter-actions > .icon-button {
  margin-right: auto;
}

.dialog.tracker-status-groups-dialog {
  width: min(460px, calc(100vw - 24px));
}

.tracker-status-groups-dialog .dialog-header h2 {
  margin: 0;
  font-size: 18px;
}

.tracker-status-group-list {
  display: grid;
  gap: 4px;
  margin-bottom: 16px;
}

.tracker-status-group-list > button {
  justify-self: start;
}

.tracker-status-group-entry {
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--tracker-line);
}

.tracker-status-group-entry > .icon-button {
  flex-shrink: 0;
}

.tracker-status-group-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px 12px;
  margin-top: 12px;
}

.tracker-status-group-options label {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 32px;
  min-width: 0;
  color: var(--tracker-text);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.tracker-status-group-options input[type="checkbox"] {
  width: 16px;
  height: 16px;
  margin: 0;
  flex-shrink: 0;
}

.tracker-status-group-options i {
  width: 10px;
  height: 10px;
  border-radius: 2px;
  flex-shrink: 0;
}

@media (max-width: 420px) {
  .tracker-status-group-options { grid-template-columns: minmax(0, 1fr); }
}

.tracker-theme-dark .tracker-status-filter .multi-select-menu label {
  color: var(--tracker-text);
}

.tracker-theme-dark .tracker-status-filter .multi-select-menu label:hover {
  background: var(--tracker-surface-raised);
}

.tracker-filter-toggle {
  position: relative;
  height: 30px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 3px 8px;
  border: 1px solid var(--tracker-line-strong);
  border-radius: 5px;
  background: var(--tracker-surface);
  color: var(--tracker-text);
  cursor: pointer;
}

.tracker-filter-toggle input {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

.tracker-filter-toggle i {
  position: relative;
  flex: 0 0 auto;
  width: 25px;
  height: 14px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--tracker-muted) 34%, var(--tracker-surface));
  transition: background-color 120ms ease;
}

.tracker-filter-toggle i::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--tracker-surface);
  box-shadow: 0 1px 2px rgba(13, 21, 28, 0.26);
  transition: transform 120ms ease;
}

.tracker-filter-toggle input:checked + i {
  background: var(--accent);
}

.tracker-filter-toggle input:checked + i::after {
  transform: translateX(11px);
}

.tracker-filter-toggle b {
  font-size: 10px;
  white-space: nowrap;
}

.tracker-filter-toggle:has(input:focus-visible) {
  outline: 2px solid color-mix(in srgb, var(--accent) 55%, transparent);
  outline-offset: 1px;
}

.tracker-search-field {
  min-width: 190px;
}

.tracker-summary {
  display: flex;
  gap: 6px;
  align-items: baseline;
  color: var(--tracker-muted);
  font-size: 11px;
  white-space: nowrap;
}

.tracker-summary b {
  color: var(--tracker-text-soft);
}

.tracker-table-wrap {
  min-height: 0;
  overflow: auto;
  border: 1px solid var(--tracker-line);
  border-radius: 6px;
  background: var(--tracker-surface);
}

.tracker-table-wrap:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--accent) 58%, transparent);
  outline-offset: -2px;
}

.tracker-table {
  width: 100%;
  min-width: 1180px;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 12px;
}

.tracker-table th,
.tracker-table td {
  padding: 6px 8px;
  border-bottom: 0;
  border-right: 0;
  text-align: left;
  vertical-align: middle;
  background: var(--tracker-surface);
  color: var(--tracker-text);
}

.tracker-table th {
  position: sticky;
  top: 0;
  z-index: 5;
  background: var(--tracker-surface-raised);
  color: var(--tracker-text-soft);
  font-size: 11px;
  font-weight: 850;
  white-space: nowrap;
}

.tracker-table td[data-tracker-column-id="startDate"],
.tracker-table td[data-tracker-column-id="dueDate"] {
  min-width: 98px;
  white-space: nowrap;
}

.tracker-aggregate-row td {
  position: sticky;
  top: var(--tracker-header-height, 39px);
  z-index: 4;
  background: var(--tracker-surface-summary);
  color: var(--tracker-muted);
  font-size: 12px;
}

.tracker-aggregate-cell {
  display: grid;
  gap: 2px;
  min-width: 0;
  white-space: nowrap;
}

.tracker-aggregate-cell b {
  color: var(--tracker-text-soft);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.tracker-aggregate-cell span {
  color: var(--tracker-text);
  font-size: 12px;
  font-weight: 850;
}

.tracker-sort-button {
  width: 100%;
  min-height: 20px;
  border: 0;
  padding: 0;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: transparent;
  color: inherit;
  font: inherit;
  font-weight: inherit;
  cursor: pointer;
  text-align: left;
}

.tracker-sort-button b {
  color: var(--accent);
  font-size: 11px;
}

.tracker-table [data-tracker-frozen] {
  position: sticky;
  left: var(--tracker-frozen-left, 0);
  z-index: 3;
}

.tracker-table td[data-tracker-frozen] {
  background: var(--tracker-surface);
}

.tracker-table th[data-tracker-frozen] {
  z-index: 7;
  background: var(--tracker-surface-raised);
}

.tracker-table .tracker-aggregate-row td[data-tracker-frozen] {
  z-index: 6;
  background: var(--tracker-surface-summary);
}

.tracker-table [data-tracker-frozen-edge] {
  box-shadow: 1px 0 0 var(--tracker-line-strong);
}

.tracker-table tbody tr:hover td {
  background: var(--tracker-surface-hover);
}

.tracker-thumb-cell {
  width: 96px;
}

.tracker-thumb-cell-inner,
.tracker-thumbnail-heading {
  display: flex;
  align-items: center;
  gap: 7px;
}

.tracker-row-select {
  flex: 0 0 auto;
  width: 16px;
  height: 16px;
  display: grid;
  place-items: center;
}

.tracker-row-select input {
  width: 14px;
  height: 14px;
  margin: 0;
  accent-color: #5c46c7;
  cursor: pointer;
}

.tracker-table tbody tr.tracker-row-selected td {
  background: color-mix(in srgb, #5c46c7 9%, var(--tracker-surface));
}

.tracker-table tbody tr.tracker-row-selected:hover td {
  background: color-mix(in srgb, #5c46c7 13%, var(--tracker-surface));
}

.tracker-table tbody tr.tracker-row-omitted td,
.tracker-table tbody tr.tracker-row-omitted:hover td {
  background: color-mix(in srgb, #7d878e 18%, var(--tracker-surface));
  color: color-mix(in srgb, var(--tracker-text) 76%, var(--tracker-muted));
}

.tracker-table tbody tr.tracker-row-omitted .tracker-thumb img {
  filter: grayscale(0.7);
  opacity: 0.78;
}

.tracker-table td.tracker-editable-cell {
  position: relative;
  cursor: text;
  outline: 0;
}

.tracker-table td.tracker-editable-cell[data-tracker-frozen] {
  position: sticky;
}

.tracker-table td.tracker-editable-cell::after {
  content: "";
  position: absolute;
  inset: 2px;
  border: 1px solid transparent;
  border-radius: 4px;
  pointer-events: none;
}

.tracker-table td.tracker-editable-cell:hover::after,
.tracker-table td.tracker-editable-cell:focus-visible::after {
  border-color: color-mix(in srgb, var(--accent) 42%, var(--tracker-line));
}

.tracker-table td.tracker-editable-cell.editing {
  padding: 3px 4px;
}

.tracker-inline-editor {
  width: 100%;
  min-width: 108px;
  min-height: 30px;
  height: 30px;
  margin: 0;
  padding: 3px 7px;
  border: 1px solid var(--accent);
  border-radius: 4px;
  background: var(--tracker-surface);
  color: var(--tracker-text);
  font: inherit;
  font-size: 12px;
  outline: 2px solid color-mix(in srgb, var(--accent) 16%, transparent);
}

.tracker-table td[data-tracker-column-id="department"] .tracker-inline-editor {
  width: 84px;
  min-width: 84px;
  max-width: 84px;
}

textarea.tracker-inline-editor {
  min-height: 72px;
  height: 72px;
  line-height: 1.3;
  resize: vertical;
}

.tracker-editable-cell.saving .tracker-inline-editor {
  opacity: 0.68;
}

.tracker-thumb {
  width: 64px;
  height: 36px;
  border: 1px solid var(--tracker-line);
  border-radius: 4px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: var(--tracker-surface-raised);
  color: var(--tracker-muted);
}

.tracker-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.tracker-thumb[data-tracker-thumbnail-preview] {
  cursor: zoom-in;
}

.tracker-thumb[data-download-tracker-thumbnail] {
  cursor: pointer;
}

.tracker-thumbnail-preview {
  position: fixed;
  z-index: 140;
  width: 360px;
  max-width: calc(100vw - 24px);
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 44px rgba(13, 21, 28, 0.22);
  opacity: 0;
  transform: translateY(3px) scale(0.985);
  pointer-events: none;
  transition: opacity 120ms ease, transform 120ms ease;
}

.tracker-thumbnail-preview.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.tracker-thumbnail-preview img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #0f171c;
}

.tracker-thumbnail-preview div {
  display: grid;
  gap: 2px;
  padding: 8px 10px 9px;
}

.tracker-thumbnail-preview b,
.tracker-thumbnail-preview span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tracker-thumbnail-preview b {
  color: #172126;
  font-size: 13px;
  line-height: 1.2;
}

.tracker-thumbnail-preview span {
  color: var(--muted);
  font-size: 12px;
}

.tracker-project-cell,
.tracker-title-cell {
  min-width: 170px;
}

.tracker-project-cell b,
.tracker-title-cell b {
  display: block;
  max-width: 240px;
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tracker-project-cell span,
.tracker-title-cell span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  margin-top: 2px;
  max-width: 240px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tracker-task-toggle {
  margin-top: 5px;
  border: 0;
  padding: 0;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 11px;
  font-weight: 850;
  cursor: pointer;
}

.tracker-task-toggle .icon {
  width: 13px;
  height: 13px;
  transition: transform 120ms ease;
}

.tracker-task-toggle.expanded .icon {
  transform: rotate(90deg);
}

.tracker-task-list {
  margin-top: 6px;
  display: grid;
  gap: 3px;
}

.tracker-task-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  max-width: 280px;
  padding: 3px 5px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--tracker-surface-raised);
}

.tracker-task-row b,
.tracker-task-row span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
}

.tracker-task-row b {
  color: var(--tracker-text);
}

.tracker-task-row span {
  color: var(--tracker-muted);
}

.tracker-task-row.completed b {
  text-decoration: line-through;
  color: var(--muted);
}

.tracker-comment-cell {
  min-width: 220px;
  max-width: 300px;
}

.tracker-comment-meta {
  display: flex;
  align-items: baseline;
  gap: 4px;
  max-width: 280px;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  font-size: 11px;
}

.tracker-comment-meta b {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
  color: var(--tracker-text-soft);
}

.tracker-comment-meta span {
  flex-shrink: 0;
  color: var(--tracker-muted);
  font-weight: 400;
}

.tracker-comment-cell > span {
  display: -webkit-box;
  max-width: 280px;
  overflow: hidden;
  color: var(--tracker-muted);
  font-size: 11px;
  line-height: 1.25;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.tracker-text-cell {
  min-width: 180px;
  max-width: 280px;
}

.tracker-text-cell > span {
  display: -webkit-box;
  overflow: hidden;
  color: var(--tracker-text-soft);
  font-size: 11px;
  line-height: 1.25;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.tracker-vfx-qc-cell {
  min-width: 140px;
}

.tracker-vfx-qc-cell.saving {
  opacity: 0.62;
  pointer-events: none;
}

.tracker-vfx-qc-switch {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) 28px;
  align-items: stretch;
  width: 124px;
  min-height: 23px;
  overflow: hidden;
  border: 1px solid var(--tracker-line-strong);
  border-radius: 4px;
  background: var(--tracker-surface);
}

.tracker-vfx-qc-switch > span {
  display: grid;
  place-items: center;
  min-width: 0;
  padding: 2px 3px;
  border-inline: 1px solid var(--tracker-line);
  color: var(--tracker-text-soft);
  font-size: 10px;
  font-weight: 800;
  white-space: nowrap;
}

.tracker-vfx-qc-switch button {
  min-width: 0;
  padding: 2px 3px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--tracker-muted);
  font: inherit;
  font-size: 9px;
  font-weight: 850;
  cursor: pointer;
}

.tracker-vfx-qc-switch button:hover:not(:disabled) {
  background: var(--tracker-surface-raised);
}

.tracker-vfx-qc-switch .qc-fail.selected {
  background: #cf4138;
  color: #fff;
}

.tracker-vfx-qc-switch .qc-pass.selected {
  background: #2f9655;
  color: #fff;
}

.tracker-vfx-qc-switch button:disabled {
  cursor: default;
  opacity: 0.52;
}

.tracker-status,
.tracker-shot-status,
.tracker-team,
.tracker-version {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 1px 7px;
  white-space: nowrap;
  font-size: 11px;
}

.tracker-status,
.tracker-shot-status,
.tracker-team {
  border-radius: 4px;
  color: var(--tracker-text);
}

.tracker-status {
  background: color-mix(in srgb, var(--status-color, #d8e0e6) 22%, var(--tracker-surface));
  border: 1px solid color-mix(in srgb, var(--status-color, #d8e0e6) 45%, var(--tracker-surface));
}

.tracker-shot-status {
  width: 116px;
  max-width: 116px;
  box-sizing: border-box;
  justify-content: center;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--shot-status-ink, var(--tracker-text));
  background: var(--shot-status-color, #d8e0e6);
  border: 1px solid color-mix(in srgb, var(--shot-status-color, #d8e0e6) 78%, #172126);
}

.tracker-team {
  width: 72px;
  max-width: 72px;
  box-sizing: border-box;
  justify-content: center;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--team-ink, var(--tracker-text));
  background: var(--team-color, #d8e0e6);
  border: 1px solid color-mix(in srgb, var(--team-color, #d8e0e6) 78%, #172126);
}

.tracker-version {
  border-radius: 4px;
  background: var(--tracker-surface-raised);
  border: 1px solid var(--tracker-line);
  font-weight: 800;
}

.tracker-version.approved {
  color: #177245;
  background: #e2f3ea;
  border-color: #b9dfc8;
}

.tracker-progress {
  min-width: 130px;
  display: grid;
  grid-template-columns: 1fr 42px;
  align-items: center;
  gap: 8px;
}

.tracker-progress span {
  height: 7px;
  border-radius: 999px;
  background: var(--tracker-surface-raised);
  overflow: hidden;
}

.tracker-progress i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #5c46c7;
}

.tracker-progress i.warning {
  background: #b7791f;
}

.tracker-progress i.over {
  background: #c63d3d;
}

.tracker-progress b {
  font-size: 11px;
  text-align: right;
}

.tracker-empty {
  height: 170px;
  text-align: center;
  color: var(--muted);
}

.tracker-column-menu {
  width: 128px;
}

.tracker-head-actions .tracker-column-menu summary {
  min-height: 30px;
  height: 30px;
  padding: 4px 8px;
  border-radius: 5px;
  font-size: 12px;
  font-weight: 800;
}

.tracker-column-menu .multi-select-menu {
  left: auto;
  right: 0;
  width: 260px;
}

.tracker-column-option {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 6px;
  align-items: center;
  min-height: 32px;
}

.tracker-column-option label {
  grid-template-columns: 18px minmax(0, 1fr);
  min-height: 30px;
}

.tracker-column-menu .tracker-column-freeze {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 126px;
  gap: 3px 8px;
  align-items: center;
  padding: 8px 0 3px;
  border-top: 1px solid var(--line);
  border-radius: 0;
}

.tracker-column-menu .tracker-column-freeze:hover {
  background: transparent;
}

.tracker-column-menu .tracker-column-freeze > span {
  font-size: 11px;
  font-weight: 800;
}

.tracker-column-menu .tracker-column-freeze select {
  width: 126px;
  min-width: 0;
  height: 30px;
  padding: 3px 24px 3px 7px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  background: var(--tracker-surface);
  color: var(--tracker-text);
  font: inherit;
  font-size: 11px;
}

.tracker-column-menu .tracker-column-freeze small {
  grid-column: 1 / -1;
  color: var(--tracker-muted);
  font-size: 10px;
}

.tracker-column-reorder {
  display: flex;
  gap: 3px;
}

.tracker-column-reorder button {
  width: 24px;
  height: 24px;
  border: 1px solid var(--line);
  border-radius: 5px;
  display: grid;
  place-items: center;
  background: var(--tracker-surface);
  color: var(--tracker-text-soft);
  cursor: pointer;
}

.tracker-column-reorder button:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.tracker-column-reorder .icon {
  width: 14px;
  height: 14px;
}

.tracker-column-menu .multi-select-menu .button {
  width: 100%;
  margin-top: 6px;
  justify-content: center;
}

.tracker-open-actions {
  display: flex;
  align-items: center;
  gap: 5px;
}

.tracker-open-cell .icon-button {
  width: 34px;
  min-width: 34px;
  height: 34px;
}

.tracker-bulk-link-button,
.tracker-bulk-edit-button {
  white-space: nowrap;
}

.tracker-attention-button {
  position: relative;
  white-space: nowrap;
}

.tracker-attention-button.has-attention {
  border-color: #d1a64b;
  background: #fff8df;
  color: #65490d;
}

.tracker-attention-button b {
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 3px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #d49a20;
  color: #fff;
  font-size: 10px;
  line-height: 1;
}

.tracker-theme-dark .tracker-bulk-link-button,
.tracker-theme-dark .tracker-bulk-edit-button {
  background: var(--tracker-surface-raised);
  border-color: var(--tracker-line-strong);
  color: var(--tracker-text);
  opacity: 1;
}

.tracker-theme-dark .tracker-attention-button.has-attention {
  border-color: #c79c43;
  background: #3a321f;
  color: #f5dda0;
}

.tracker-theme-dark .tracker-head-actions .button:not(.primary),
.tracker-theme-dark .tracker-head-actions .icon-button,
.tracker-theme-dark .tracker-named-view-controls select,
.tracker-theme-dark .tracker-column-menu summary,
.tracker-theme-dark .tracker-column-menu .multi-select-menu {
  background: var(--tracker-surface);
  border-color: var(--tracker-line-strong);
  color: var(--tracker-text);
}

.tracker-theme-dark .tracker-column-menu .multi-select-menu {
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.34);
}

.tracker-theme-dark .muted,
.tracker-theme-dark .tracker-project-cell span,
.tracker-theme-dark .tracker-title-cell span,
.tracker-theme-dark .tracker-task-toggle,
.tracker-theme-dark .tracker-empty {
  color: var(--tracker-muted);
}

@media (max-width: 1280px) {
  .tracker-filters {
    grid-template-columns: repeat(3, minmax(140px, 1fr));
  }
}

@media (max-width: 820px) {
  .tracker-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: flex-start;
  }

  .tracker-head-actions {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: nowrap;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    padding-bottom: 3px;
  }

  .tracker-head-actions > * {
    flex: 0 0 auto;
  }

  .tracker-filters {
    display: flex;
    align-items: flex-end;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    padding-bottom: 3px;
    scroll-snap-type: inline proximity;
  }

  .tracker-filters > label,
  .tracker-filters > .tracker-filter-field {
    flex: 0 0 164px;
    scroll-snap-align: start;
  }

  .tracker-filters > .tracker-search-field {
    flex-basis: 200px;
  }

  .tracker-filters > .tracker-omitted-filter {
    flex-basis: 132px;
  }

  .tracker-head-actions .compact-button,
  .tracker-head-actions .icon-button.compact-button,
  .tracker-named-view-controls select,
  .tracker-theme-toggle,
  .tracker-head-actions .tracker-column-menu summary,
  .tracker-filters select,
  .tracker-filters input,
  .tracker-status-filter .multi-select-dropdown summary,
  .tracker-filter-toggle {
    min-height: 34px;
    height: 34px;
  }
}

.tracker-item-dialog {
  width: min(880px, calc(100vw - 36px));
  max-height: min(860px, calc(100vh - 36px));
}

.tracker-note-draft {
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.tracker-note-draft h3 {
  margin: 0 0 12px;
  font-size: 14px;
  overflow-wrap: anywhere;
}

.tracker-note-draft label {
  display: grid;
  gap: 6px;
  margin-bottom: 12px;
}

.tracker-note-draft textarea {
  width: 100%;
  min-height: 120px;
  resize: vertical;
}

.tracker-schedule-link-panel {
  display: grid;
  gap: 10px;
  margin: 0;
}

.tracker-schedule-link-heading {
  align-items: flex-start;
}

.tracker-schedule-link-heading h3,
.tracker-schedule-link-heading span {
  margin: 0;
}

.tracker-link-totals {
  display: flex;
  align-items: center;
  gap: 12px;
  white-space: nowrap;
}

.tracker-link-totals span {
  color: var(--muted);
  font-size: 11px;
}

.tracker-link-totals b {
  color: var(--ink);
  font-size: 13px;
}

.tracker-linked-activity-add-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 7px;
}

.tracker-linked-activity-list {
  display: grid;
  gap: 6px;
}

.tracker-linked-activity-row {
  min-height: 64px;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) 118px 34px 34px;
  align-items: center;
  gap: 7px;
  padding: 7px 8px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #fff;
}

.tracker-primary-activity-control {
  width: 22px;
  height: 34px;
  display: grid;
  place-items: center;
  margin: 0;
  cursor: pointer;
}

.tracker-primary-activity-control input {
  margin: 0;
}

.tracker-linked-activity-copy {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.tracker-linked-activity-copy > div {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 7px;
}

.tracker-linked-activity-copy b,
.tracker-linked-activity-copy small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tracker-linked-activity-copy b {
  font-size: 12px;
}

.tracker-linked-activity-copy small {
  color: var(--muted);
  font-size: 10px;
}

.tracker-link-role {
  flex: 0 0 auto;
  padding: 2px 5px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  line-height: 1.2;
}

.tracker-link-role.primary {
  border-color: color-mix(in srgb, var(--accent) 35%, var(--line));
  background: color-mix(in srgb, var(--accent) 8%, #fff);
  color: var(--accent);
}

.tracker-linked-activity-hours {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
}

.tracker-linked-activity-hours span {
  display: grid;
  gap: 1px;
  color: var(--muted);
  font-size: 9px;
  text-transform: uppercase;
}

.tracker-linked-activity-hours b {
  color: var(--ink);
  font-size: 12px;
  text-transform: none;
}

.tracker-linked-activity-empty {
  display: grid;
  gap: 2px;
  padding: 10px;
  border: 1px dashed var(--line);
  border-radius: 5px;
}

.tracker-linked-activity-empty b {
  font-size: 12px;
}

.tracker-linked-activity-empty span {
  color: var(--muted);
  font-size: 11px;
}

.tracker-linked-activity-create-actions {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  align-items: center;
  gap: 8px;
}

.tracker-linked-activity-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  padding-bottom: 1px;
}

.tracker-linked-activity-actions .button {
  white-space: nowrap;
}

.tracker-named-view-dialog {
  width: min(460px, calc(100vw - 36px));
}

.tracker-paste-dialog {
  width: min(1120px, calc(100vw - 36px));
  max-height: min(880px, calc(100vh - 36px));
}

.tracker-paste-input-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  color: var(--ink-soft);
}

.tracker-paste-input-head small {
  overflow: hidden;
  color: var(--muted);
  font-size: 10px;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tracker-paste-input {
  width: 100%;
  min-height: 96px;
  margin: 0;
  border-radius: 5px;
  resize: vertical;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
  line-height: 1.45;
}

.tracker-paste-preview-wrap {
  max-height: 270px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 5px;
}

.tracker-paste-preview {
  width: 100%;
  min-width: 940px;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 11px;
}

.tracker-paste-preview th,
.tracker-paste-preview td {
  max-width: 210px;
  padding: 5px 7px;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tracker-paste-preview th {
  position: sticky;
  top: 0;
  background: #f5f7f9;
  color: var(--ink-soft);
}

.tracker-paste-empty,
.tracker-paste-more {
  padding: 12px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.tracker-paste-errors {
  display: grid;
  gap: 3px;
}

.tracker-history-panel {
  display: block;
  margin: 0;
}

.tracker-history-panel > summary {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 34px;
  padding-right: 24px;
  cursor: pointer;
  list-style: none;
}

.tracker-history-panel > summary::-webkit-details-marker {
  display: none;
}

.tracker-history-panel > summary::after {
  content: "";
  position: absolute;
  right: 3px;
  width: 7px;
  height: 7px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
  transition: transform 120ms ease;
}

.tracker-history-panel[open] > summary::after {
  transform: rotate(225deg) translate(-1px, -1px);
}

.tracker-history-panel > summary h3 {
  margin: 0;
}

.tracker-history-panel > summary span {
  display: block;
  margin-top: 2px;
}

.tracker-history-content {
  display: grid;
  gap: 9px;
  padding-top: 9px;
}

.tracker-history-toolbar {
  display: flex;
  justify-content: flex-end;
}

.tracker-history-list {
  position: relative;
  display: grid;
  gap: 0;
}

.tracker-history-entry {
  position: relative;
  display: grid;
  grid-template-columns: 14px minmax(0, 1fr);
  gap: 8px;
  padding: 7px 0;
}

.tracker-history-entry::before {
  content: "";
  position: absolute;
  top: 20px;
  bottom: -7px;
  left: 5px;
  width: 1px;
  background: var(--line);
}

.tracker-history-entry:last-child::before {
  display: none;
}

.tracker-history-entry > i {
  position: relative;
  z-index: 1;
  width: 11px;
  height: 11px;
  margin-top: 3px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #73808a;
  box-shadow: 0 0 0 1px var(--line-strong);
}

.tracker-history-entry.tone-review > i {
  background: #5c46c7;
}

.tracker-history-entry.tone-schedule > i {
  background: #2474a6;
}

.tracker-history-entry.tone-google-sheet > i {
  background: #2f855a;
}

.tracker-history-entry.tone-warning > i {
  background: #c07a1a;
}

.tracker-history-entry > div {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.tracker-history-entry-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.tracker-history-entry-head b {
  color: var(--ink);
  font-size: 12px;
}

.tracker-history-entry-head span {
  color: var(--muted);
  font-size: 9px;
  font-weight: 850;
  text-transform: uppercase;
}

.tracker-history-entry p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 11px;
  line-height: 1.35;
}

.tracker-history-entry small,
.tracker-history-empty {
  color: var(--muted);
  font-size: 10px;
}

.tracker-history-empty {
  padding: 10px 0;
}

.tracker-bulk-link-dialog {
  width: min(880px, calc(100vw - 36px));
  max-height: min(820px, calc(100vh - 36px));
}

.tracker-bulk-edit-dialog {
  width: min(780px, calc(100vw - 36px));
  max-height: min(820px, calc(100vh - 36px));
}

.tracker-bulk-edit-dialog .dialog-header h2,
.tracker-bulk-edit-dialog .dialog-header p {
  margin: 0;
}

.tracker-bulk-edit-dialog .dialog-header p {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
}

.tracker-bulk-edit-list {
  display: grid;
  gap: 7px;
}

.tracker-bulk-edit-row {
  min-height: 58px;
  display: grid;
  grid-template-columns: minmax(210px, 0.8fr) minmax(260px, 1.2fr);
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #fff;
  transition: border-color 120ms ease, background-color 120ms ease;
}

.tracker-bulk-edit-row.enabled {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
  background: color-mix(in srgb, var(--accent) 4%, #fff);
}

.tracker-bulk-edit-toggle {
  min-width: 0;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  column-gap: 8px;
  cursor: pointer;
}

.tracker-bulk-edit-toggle input {
  grid-row: 1 / span 2;
  margin: 0;
}

.tracker-bulk-edit-toggle span,
.tracker-bulk-edit-toggle small {
  min-width: 0;
}

.tracker-bulk-edit-toggle span {
  font-size: 13px;
  font-weight: 850;
}

.tracker-bulk-edit-toggle small {
  margin-top: 1px;
  color: var(--muted);
  font-size: 11px;
}

.tracker-bulk-edit-row textarea {
  min-height: 62px;
  resize: vertical;
}

.tracker-bulk-edit-row :is(input, select, textarea):disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.tracker-bulk-link-dialog .dialog-header h2,
.tracker-bulk-link-dialog .dialog-header p {
  margin: 0;
}

.tracker-bulk-link-dialog .dialog-header p {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
}

.tracker-bulk-link-list {
  display: grid;
  gap: 7px;
}

.tracker-bulk-link-row {
  display: grid;
  grid-template-columns: minmax(180px, 0.7fr) minmax(260px, 1.3fr);
  align-items: center;
  gap: 10px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #fff;
}

.tracker-bulk-link-row > div {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.tracker-bulk-link-row b,
.tracker-bulk-link-row span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tracker-bulk-link-row span {
  color: var(--muted);
  font-size: 11px;
}

@media (max-width: 720px) {
  .tracker-bulk-link-row,
  .tracker-bulk-edit-row {
    grid-template-columns: 1fr;
  }

  .tracker-schedule-link-heading {
    align-items: flex-start;
    gap: 8px;
  }

  .tracker-link-totals {
    width: 100%;
  }

  .tracker-linked-activity-row {
    grid-template-columns: 22px minmax(0, 1fr) 34px 34px;
  }

  .tracker-linked-activity-hours {
    grid-column: 2 / -1;
    grid-row: 2;
  }

  .tracker-linked-activity-actions {
    justify-content: flex-start;
  }

  .tracker-linked-activity-add-row {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .tracker-linked-activity-add-row select {
    grid-column: 1 / -1;
  }

  .tracker-linked-activity-create-actions {
    grid-template-columns: 1fr;
  }
}

.tracker-item-dialog .dialog-header h2,
.tracker-item-dialog .dialog-header p {
  margin: 0;
}

.tracker-item-dialog .dialog-header p {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.tracker-intake-notes-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.tracker-intake-notes-grid > .field {
  align-content: start;
  align-self: start;
}

.tracker-intake-notes-grid textarea {
  min-height: 82px;
}

.tracker-vfx-qc-choice {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.tracker-vfx-qc-choice legend {
  margin-bottom: 5px;
  padding: 0;
  font-size: 12px;
  font-weight: 800;
}

.tracker-vfx-qc-choice > div {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  min-height: 38px;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
}

.tracker-vfx-qc-choice label {
  position: relative;
  display: grid;
  place-items: center;
  border-right: 1px solid var(--line);
  cursor: pointer;
}

.tracker-vfx-qc-choice label:last-child {
  border-right: 0;
}

.tracker-vfx-qc-choice input {
  position: absolute;
  opacity: 0;
}

.tracker-vfx-qc-choice span {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.tracker-vfx-qc-choice .neutral input:checked + span {
  background: #edf1f3;
  color: #38464f;
}

.tracker-vfx-qc-choice .fail input:checked + span {
  background: #cf4138;
  color: #fff;
}

.tracker-vfx-qc-choice .pass input:checked + span {
  background: #2f9655;
  color: #fff;
}

.tracker-status-fields {
  grid-template-columns: minmax(0, 1fr) 92px;
}

.tracker-status-color-field input[type="color"] {
  min-height: 38px;
  padding: 4px;
}

.tracker-managed-status-field .field-help {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
}

.tracker-bookings-dialog {
  width: min(1180px, calc(100vw - 24px));
  max-height: calc(100dvh - 24px);
}

.tracker-bookings-dialog h2 { font-size: 20px; }
.tracker-booking-controls, .tracker-booking-entries { border: 0; padding: 0; margin: 0; min-width: 0; }
.tracker-booking-controls { display: grid; grid-template-columns: minmax(210px, 2fr) minmax(150px, 1fr) 110px 130px auto 38px; align-items: end; gap: 10px; }
.tracker-bookings-dialog .field { min-width: 0; margin: 0; gap: 4px; }
.tracker-bookings-dialog .field > span { font-size: 12px; font-weight: 700; }
.tracker-bookings-dialog :is(input:not([type=checkbox]), select) { min-width: 0; width: 100%; min-height: 36px; padding: 6px 8px; font-size: 13px; }
.tracker-booking-entries { margin: 12px 0; }
.tracker-booking-entry { display: grid; grid-template-columns: minmax(180px, 1fr) 115px 80px; align-items: center; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--tracker-line); }
.tracker-booking-entry:has(.tracker-booking-source) { grid-template-columns: minmax(180px, 1fr) 115px 80px minmax(230px, 1fr); }
.tracker-booking-entry .check-row { align-items: center; min-width: 0; }
.tracker-booking-entry .check-row span { min-width: 0; overflow-wrap: anywhere; }
.tracker-booking-entry .check-row b { display: block; font-size: 13px; }
.tracker-booking-entry small, .tracker-booking-day-heading small { display: block; font-size: 11px; color: var(--tracker-muted); }
.tracker-booking-day-scroll { max-height: 400px; overflow: auto; border: 1px solid var(--tracker-line); isolation: isolate; }
.tracker-booking-day { display: grid; grid-template-columns: 64px repeat(var(--booking-lanes), minmax(190px, 1fr)); min-width: calc(64px + var(--booking-lanes) * 190px); }
.tracker-booking-day-heading { position: sticky; top: 0; z-index: 3; min-height: 58px; padding: 8px; border-right: 1px solid var(--tracker-line); border-bottom: 1px solid var(--tracker-line); background: var(--tracker-surface-raised); color: var(--tracker-text); font-size: 12px; overflow-wrap: anywhere; }
.tracker-booking-hours, .tracker-booking-lane { height: 960px; position: relative; }
.tracker-booking-hours { background: var(--tracker-surface); border-right: 1px solid var(--tracker-line); }
.tracker-booking-hours span { position: absolute; right: 8px; font-size: 11px; color: var(--tracker-muted); }
.tracker-booking-lane { border-right: 1px solid var(--tracker-line); background: repeating-linear-gradient(to bottom, transparent 0 39px, var(--tracker-line) 39px 40px); }
.tracker-booking-existing { position: absolute; left: 3px; right: 3px; padding: 1px 5px; font-size: 10px; border-radius: 3px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; background: var(--tracker-line); color: var(--tracker-text-soft); opacity: 0.85; }
.tracker-booking-proposed { position: absolute; left: 8px; right: 8px; z-index: 2; background: #176f83; border: 1px solid #0b5264; border-radius: 4px; color: #fff; cursor: grab; touch-action: none; user-select: none; box-sizing: border-box; }
.tracker-booking-proposed > span { display: block; padding: 0 6px; font-size: 11px; line-height: 14px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.tracker-booking-proposed.has-conflict { background: #91620b; border-color: #b57c13; }
.tracker-booking-proposed:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.tracker-booking-resize { position: absolute; bottom: 0; left: 0; width: 100%; height: 6px; border: 0; border-bottom: 2px solid rgba(255,255,255,.65); background: transparent; padding: 0; cursor: ns-resize; touch-action: none; }
.tracker-booking-total { display: grid; gap: 2px; margin-right: auto; font-size: 13px; color: var(--tracker-text); }
.tracker-booking-conflicts { font-size: 12px; color: var(--tracker-text); border-left: 3px solid #b57c13; padding-left: 10px; margin-top: 12px; }
.tracker-bookings-dialog .dialog-footer { flex-wrap: wrap; gap: 8px; }
@media (max-width: 900px) {
  .tracker-booking-controls { grid-template-columns: minmax(160px, 1fr) minmax(140px, 1fr); }
  .tracker-booking-entry:has(.tracker-booking-source) { grid-template-columns: minmax(0, 1fr) 110px 75px; }
  .tracker-booking-source { grid-column: 1 / -1; }
}
@media (max-width: 500px) {
  .tracker-bookings-dialog .dialog-body { padding: 12px; }
  .tracker-booking-controls > .field:has([data-booking-mode]) { grid-column: 1 / -1; }
  .tracker-booking-controls { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .tracker-booking-entry, .tracker-booking-entry:has(.tracker-booking-source) { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .tracker-booking-entry > .check-row { grid-column: 1 / -1; }
  .tracker-booking-total { width: 100%; }
}

.tracker-statuses-dialog {
  width: min(1100px, calc(100vw - 36px));
}

.tracker-teams-dialog {
  width: min(720px, calc(100vw - 36px));
}

.tracker-status-maintenance-list {
  display: grid;
  gap: 7px;
}

.tracker-team-maintenance-list {
  display: grid;
  gap: 7px;
}

.tracker-team-maintenance-row {
  display: grid;
  grid-template-columns: 26px 42px minmax(180px, 1fr) 34px 34px 34px;
  gap: 7px;
  align-items: center;
}

.tracker-team-maintenance-row > input[type="color"] {
  width: 42px;
  min-height: 36px;
  padding: 3px;
}

.tracker-status-maintenance-row {
  display: grid;
  grid-template-columns: 26px 42px minmax(180px, 0.9fr) minmax(240px, 1.25fr) minmax(132px, auto) 34px 34px 34px;
  gap: 7px;
  align-items: center;
}

.tracker-status-order {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.tracker-status-maintenance-row > input[type="color"] {
  width: 42px;
  min-height: 36px;
  padding: 3px;
}

.tracker-status-done-toggle {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 36px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.tracker-status-done-toggle input {
  width: 16px;
  height: 16px;
}

.tracker-status-arrow.up .icon {
  transform: rotate(-90deg);
}

.tracker-status-arrow.down .icon {
  transform: rotate(90deg);
}

@media (max-width: 700px) {
  .tracker-team-maintenance-row {
    grid-template-columns: 26px 42px minmax(0, 1fr) 34px 34px 34px;
  }

  .tracker-status-maintenance-row {
    grid-template-columns: 26px 42px minmax(0, 1fr) 34px 34px 34px;
  }

  .tracker-status-maintenance-row > [data-tracker-status-description] {
    grid-column: 3 / -1;
  }

  .tracker-status-done-toggle {
    grid-column: 1 / -1;
    grid-row: 2;
  }
}

/* Tracker dialogs are mounted outside .tracker-view, so they carry this shared theme scope. */
.tracker-theme-scope.tracker-theme-dark {
  background-color: rgba(5, 9, 12, 0.68);
  color: var(--tracker-text);
}

.tracker-theme-scope.tracker-theme-dark .dialog {
  border-color: var(--tracker-line);
  background: var(--tracker-surface);
  color: var(--tracker-text);
  box-shadow: 0 20px 54px rgba(0, 0, 0, 0.48);
}

.tracker-theme-scope.tracker-theme-dark :is(.dialog-header, .dialog-footer, .activity-tabs-sticky) {
  border-color: var(--tracker-line);
  background: var(--tracker-surface);
}

.tracker-theme-scope.tracker-theme-dark .dialog-body {
  background: var(--tracker-surface);
}

.tracker-theme-scope.tracker-theme-dark :is(.dialog h2, .dialog h3, .dialog b, .dialog strong, .field label, .tracker-vfx-qc-choice legend) {
  color: var(--tracker-text);
}

.tracker-theme-scope.tracker-theme-dark :is(.muted, .field-help, .field small, .tracker-status-order, .tracker-status-done-toggle) {
  color: var(--tracker-muted);
}

.tracker-theme-scope.tracker-theme-dark :is(.field input, .field select, .field textarea, .dialog input[type="text"], .dialog input[type="date"], .dialog select, .dialog textarea, .multi-select-dropdown summary, .multi-select-menu) {
  border-color: var(--tracker-line-strong);
  background: var(--tracker-surface-raised);
  color: var(--tracker-text);
}

.tracker-theme-scope.tracker-theme-dark :is(input, textarea)::placeholder {
  color: color-mix(in srgb, var(--tracker-muted) 82%, transparent);
}

.tracker-theme-scope.tracker-theme-dark .dialog :focus-visible {
  outline-color: color-mix(in srgb, var(--accent) 72%, #fff);
}

.tracker-theme-scope.tracker-theme-dark :is(.button:not(.primary), .icon-button:not(.primary), .segmented button) {
  border-color: var(--tracker-line-strong);
  background: var(--tracker-surface-raised);
  color: var(--tracker-text);
}

.tracker-theme-scope.tracker-theme-dark .button.danger {
  border-color: #75464a;
  color: #f2a7aa;
}

.tracker-theme-scope.tracker-theme-dark :is(.panel-block, .tracker-linked-activity-row, .tracker-bulk-link-row, .tracker-bulk-edit-row) {
  border-color: var(--tracker-line);
  background: var(--tracker-surface-raised);
}

.tracker-theme-scope.tracker-theme-dark .tracker-bulk-edit-row.enabled {
  border-color: color-mix(in srgb, var(--accent) 65%, var(--tracker-line));
  background: color-mix(in srgb, var(--accent) 11%, var(--tracker-surface-raised));
}

.tracker-theme-scope.tracker-theme-dark .tracker-link-role.primary {
  background: color-mix(in srgb, var(--accent) 18%, var(--tracker-surface-raised));
}

.tracker-theme-scope.tracker-theme-dark .tracker-paste-preview th {
  background: var(--tracker-surface-raised);
  color: var(--tracker-text-soft);
}

.tracker-theme-scope.tracker-theme-dark :is(.tracker-paste-preview-wrap, .tracker-paste-preview th, .tracker-paste-preview td) {
  border-color: var(--tracker-line);
}

.tracker-theme-scope.tracker-theme-dark .tracker-paste-preview td {
  background: var(--tracker-surface);
  color: var(--tracker-text);
}

.tracker-theme-scope.tracker-theme-dark .tracker-vfx-qc-choice .neutral input:checked + span {
  background: #39444b;
  color: var(--tracker-text);
}

.tracker-theme-scope.tracker-theme-dark .tracker-review-state.approved {
  border-color: #4f9552;
  background: #213c2a;
  color: #9ed6a4;
}

.tracker-theme-scope.tracker-theme-dark .tracker-history-entry > i {
  border-color: var(--tracker-surface-raised);
}

.tracker-theme-scope.tracker-theme-dark .tracker-sheet-attention-body {
  background: var(--tracker-canvas);
}

.tracker-theme-scope.tracker-theme-dark :is(.tracker-sheet-attention-summary, .tracker-sheet-attention-project) {
  border-color: var(--tracker-line);
  background: var(--tracker-surface);
}

.tracker-theme-scope.tracker-theme-dark :is(.tracker-sheet-attention-summary > div, .tracker-sheet-attention-project > header, .tracker-sheet-attention-run + .tracker-sheet-attention-run, .tracker-sheet-attention-item) {
  border-color: var(--tracker-line);
}

.tracker-theme-scope.tracker-theme-dark .tracker-sheet-attention-project > header {
  background: var(--tracker-surface-raised);
}

.tracker-theme-scope.tracker-theme-dark .tracker-sheet-attention-run-head {
  background: var(--panel-2);
}

.tracker-theme-scope.tracker-theme-dark .tracker-sheet-attention-kind {
  border-color: #9a762f;
  background: #3a301d;
  color: #f2d58a;
}

.tracker-theme-scope.tracker-theme-dark .tracker-sheet-attention-item.retryable .tracker-sheet-attention-kind {
  border-color: #955657;
  background: #3d2527;
  color: #f0aaaa;
}

.tracker-theme-scope.tracker-theme-dark .tracker-sheet-attention-empty.success b {
  color: #9ed6a4;
}

.tracker-theme-scope.tracker-theme-dark .form-error {
  border-color: #955657;
  background: #3d2527;
  color: #f0aaaa;
}

.tracker-thumbnail-preview.tracker-theme-dark {
  border-color: var(--tracker-line-strong);
  background: var(--tracker-surface);
  color: var(--tracker-text);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.52);
}

.tracker-thumbnail-preview.tracker-theme-dark b {
  color: var(--tracker-text);
}

.tracker-thumbnail-preview.tracker-theme-dark span {
  color: var(--tracker-muted);
}

.tracker-review-panel {
  display: grid;
  gap: 12px;
  margin: 0;
}

.activity-review-player-empty.tracker-version-placeholder {
  gap: 6px;
  text-align: center;
}

.activity-review-player-empty.tracker-version-placeholder b {
  color: var(--accent);
  font-size: 10px;
  letter-spacing: 0;
}

.activity-review-player-empty.tracker-version-placeholder strong {
  font-size: 16px;
}

.tracker-review-state {
  align-self: center;
  padding: 4px 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.tracker-review-state.approved {
  border-color: #4daa31;
  color: #2f7621;
  background: #e8f6e4;
}

.tracker-review-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.tracker-review-summary > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.tracker-review-summary span,
.tracker-review-actions .field > span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.tracker-review-actions {
  display: grid;
  grid-template-columns: minmax(150px, 1fr) auto;
  gap: 8px;
  align-items: end;
}

.tracker-review-action-buttons {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

@media (max-width: 700px) {
  .tracker-review-summary,
  .tracker-review-actions {
    grid-template-columns: 1fr;
  }

  .tracker-review-action-buttons {
    justify-content: stretch;
  }

  .tracker-review-action-buttons .button {
    flex: 1 1 auto;
  }
}

.notification-bell.has-unread {
  border-color: var(--accent);
  color: var(--accent);
}

.icon {
  width: 18px;
  height: 18px;
  display: block;
}

.segmented {
  display: inline-flex;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel);
}

.segmented button {
  border: 0;
  border-radius: 0;
  min-height: 34px;
}

.segmented button.active {
  background: var(--ink);
  color: white;
}

[data-tooltip] {
  position: relative;
}

.pane-restore[data-tooltip] {
  position: fixed;
}

[data-tooltip]:hover::after {
  content: attr(data-tooltip);
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 50;
  margin-left: 0;
  border: 0;
  white-space: normal;
  width: max-content;
  max-width: 280px;
  background: #172126;
  color: #fff;
  border-radius: 6px;
  padding: 6px 8px;
  font-size: 12px;
  font-weight: 650;
  line-height: 1.25;
  text-align: center;
  box-shadow: var(--shadow);
  pointer-events: none;
}

.calendar-scroll-shell {
  min-height: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  background: #e9edf1;
}

.calendar-scroll-shell.has-schedule-filterbar {
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.calendar-scroll-shell.has-gantt-filterbar .calendar-wrap {
  padding: 0;
  scrollbar-gutter: stable;
}

.calendar-wrap {
  overflow: auto;
  padding: 14px;
  background: #e9edf1;
  min-height: 0;
  scrollbar-gutter: stable both-edges;
}

.calendar-scroll-shell.has-calendar-x-scroll .calendar-wrap {
  overflow-x: hidden;
  overflow-y: auto;
}

.calendar-wrap::-webkit-scrollbar,
.calendar-x-scrollbar::-webkit-scrollbar {
  width: 14px;
  height: 14px;
}

.calendar-wrap::-webkit-scrollbar-track,
.calendar-x-scrollbar::-webkit-scrollbar-track {
  background: #dfe5eb;
  border-radius: 999px;
}

.calendar-wrap::-webkit-scrollbar-thumb,
.calendar-x-scrollbar::-webkit-scrollbar-thumb {
  background: #9aa6b2;
  border: 3px solid #dfe5eb;
  border-radius: 999px;
}

.calendar-wrap::-webkit-scrollbar-thumb:hover,
.calendar-x-scrollbar::-webkit-scrollbar-thumb:hover {
  background: #73808d;
}

.calendar-x-scroll-panel[hidden] {
  display: none !important;
}

.calendar-x-scroll-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 36px;
  gap: 8px;
  align-items: center;
  padding: 5px 10px 7px;
  border-top: 1px solid var(--line);
  background: #eef2f6;
}

.calendar-x-scrollbar {
  min-width: 0;
  height: 18px;
  overflow-x: scroll;
  overflow-y: hidden;
}

.calendar-x-scrollbar-content {
  height: 1px;
}

.calendar-x-reset-button {
  min-height: 30px;
  width: 30px;
  flex-basis: 30px;
  border-color: #c8d0d8;
  background: #fff;
}

.calendar-x-reset-button .icon {
  width: 14px;
  height: 14px;
}

.calendar {
  min-width: 780px;
  background: #fbfcfc;
  border: 1px solid #b9c0c8;
  border-radius: var(--radius);
  overflow: hidden;
}

.calendar-month {
  --month-row-zoom: 1;
  --month-visible-row-height: max(82px, calc(((100vh - 190px) / 6) * var(--month-row-zoom)));
  min-height: 100%;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: visible;
}

.calendar-body {
  min-height: 0;
}

.calendar-month .calendar-body {
  display: grid;
  grid-auto-rows: var(--month-visible-row-height);
}

.calendar-header {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.calendar-month .calendar-header {
  position: sticky;
  top: 0;
  z-index: 56;
  background: #f4f7f9;
  box-shadow:
    inset 1px 0 0 #f4f7f9,
    inset -1px 0 0 #f4f7f9,
    -16px 0 0 #e9edf1,
    16px 0 0 #e9edf1,
    0 -16px 0 #e9edf1,
    0 1px 0 #aeb7c1;
}

.calendar-month.with-week-numbers .calendar-header {
  grid-template-columns: 54px repeat(7, minmax(0, 1fr));
}

.calendar-header div {
  min-height: 34px;
  display: flex;
  align-items: center;
  padding: 0 10px;
  font-size: 12px;
  color: var(--muted);
  font-weight: 700;
  border-right: 1px solid var(--line);
  background: #f4f7f9;
  color: #1b2633;
}

.calendar-header div:last-child {
  border-right: 0;
}

.calendar-row {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  grid-template-rows: 30px repeat(var(--month-lanes, 1), minmax(0, 1fr));
  height: 100%;
  min-height: 0;
  overflow: hidden;
  position: relative;
  border-top: 1px solid #b9c0c8;
  background: #fbfcfc;
}

.calendar-month.with-week-numbers .calendar-row {
  grid-template-columns: 54px repeat(7, minmax(0, 1fr));
}

.day-cell {
  border-right: 1px solid #b9c0c8;
  padding: 8px;
  background: #fbfcfc;
  position: relative;
}

.day-cell.other-month {
  background: #fbfcfc;
}

.day-cell.other-month .day-number {
  color: #657381;
}

.calendar-header .weekend-day,
.day-cell.weekend-day,
.week-head.weekend-day,
.week-cell.weekend-day,
.cascade-date-cell.weekend-day,
.cascade-cell.weekend-day,
.gantt-day-head.weekend-day,
.gantt-hour-head.weekend-day,
.gantt-cell.weekend-day {
  background: #eef1f4;
  color: #7b8794;
}

.day-cell.today {
  box-shadow: inset 0 0 0 2px var(--accent);
}

.day-cell.weekend-day.bank-holiday-day,
.week-cell.weekend-day.bank-holiday-day,
.week-head.weekend-day.bank-holiday-head,
.cascade-date-cell.weekend-day.bank-holiday-day,
.cascade-cell.weekend-day.bank-holiday-day,
.gantt-cell.weekend-day.bank-holiday-day,
.gantt-day-head.weekend-day.bank-holiday-head {
  background: #fde8e8;
  color: #172126;
}

.day-cell.bank-holiday-day,
.week-cell.bank-holiday-day,
.cascade-date-cell.bank-holiday-day,
.cascade-cell.bank-holiday-day,
.gantt-cell.bank-holiday-day {
  background: #fde8e8;
}

.month-inline-label {
  z-index: 5;
  align-self: start;
  justify-self: start;
  margin: 8px 0 0 8px;
  color: #172126;
  font-size: 26px;
  font-weight: 450;
  letter-spacing: 0;
  line-height: 1;
  opacity: 0;
  pointer-events: none;
  transform: translateY(6px);
  transition: opacity 280ms ease, transform 280ms ease;
}

.month-inline-label strong {
  font-weight: 850;
}

.calendar-wrap.is-month-scrolling .month-inline-label {
  opacity: 1;
  transform: translateY(0);
}

.cascade-month-label {
  position: sticky;
  left: 160px;
  align-self: start;
  z-index: 7;
  width: max-content;
  margin-top: 6px;
  color: #172126;
  font-size: 26px;
  font-weight: 450;
  letter-spacing: 0;
  line-height: 1;
  opacity: 0;
  pointer-events: none;
  transform: translateY(6px);
  transition: opacity 280ms ease, transform 280ms ease;
}

.cascade-month-label strong {
  font-weight: 850;
}

.calendar-wrap.is-month-scrolling .cascade-month-label {
  opacity: 1;
  transform: translateY(0);
}

.day-cell.trim-target {
  box-shadow: inset 0 0 0 3px var(--warning);
}

.cascade-view {
  min-width: 980px;
  border: 1px solid #b9c0c8;
  border-radius: var(--radius);
  background: #fbfcfc;
  overflow: hidden;
}

.cascade-board {
  min-width: max-content;
}

.cascade-header,
.cascade-grid {
  display: grid;
}

.cascade-header {
  position: sticky;
  top: 0;
  z-index: 8;
  grid-template-columns: var(--cascade-columns);
}

.cascade-date-head,
.cascade-column-head {
  min-height: 48px;
  display: grid;
  align-content: center;
  gap: 2px;
  padding: 8px 10px;
  background: #f4f7f9;
  border-right: 1px solid #b9c0c8;
  border-bottom: 1px solid #aeb7c1;
  color: #172126;
}

.cascade-date-head {
  position: sticky;
  left: 0;
  z-index: 9;
  font-weight: 850;
}

.cascade-column-head b {
  font-size: 14px;
  line-height: 1.1;
}

.cascade-column-head span {
  color: #657381;
  font-size: 11px;
  font-weight: 750;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cascade-grid {
  position: relative;
  grid-template-columns: var(--cascade-columns);
}

.cascade-milestone-marker {
  align-self: start;
  display: flex;
  gap: 4px;
  padding: 4px 8px;
  pointer-events: none;
  z-index: 4;
}

.cascade-milestone-pill {
  box-shadow: 0 1px 4px rgba(23, 33, 38, 0.12);
}

.cascade-date-cell,
.cascade-cell {
  min-height: var(--cascade-row-height, 64px);
  background: #fbfcfc;
  border-right: 1px solid #b9c0c8;
  border-bottom: 1px solid #b9c0c8;
}

.cascade-date-cell {
  position: sticky;
  left: 0;
  z-index: 5;
  display: grid;
  align-content: start;
  gap: 2px;
  padding: 8px 10px;
  color: #172126;
  background: #f4f7f9;
}

.cascade-date-cell.today {
  box-shadow: inset 0 0 0 2px var(--accent);
}

.cascade-date-cell b {
  font-size: 13px;
}

.cascade-date-cell span {
  color: #53616e;
  font-size: 20px;
  font-weight: 850;
  line-height: 1;
}

.cascade-date-cell em {
  font-size: 10px;
  font-style: normal;
  font-weight: 750;
  color: #172126;
}

.cascade-cell {
  position: relative;
}

.cascade-cell.trim-target {
  box-shadow: inset 0 0 0 3px var(--warning);
}

.cascade-activity {
  align-self: stretch;
  min-height: 0;
  margin-top: 0;
  margin-bottom: 0;
  border-radius: 4px;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12);
}

.cascade-activity .trim-handle {
  left: 0;
  right: 0;
  width: auto;
  height: 14px;
  cursor: ns-resize;
}

.cascade-activity .trim-start {
  top: 0;
  bottom: auto;
}

.cascade-activity .trim-end {
  top: auto;
  bottom: 0;
}

.cascade-activity.expanded-slot {
  width: 100% !important;
  margin-left: 0 !important;
}

.day-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 22px;
  font-size: 12px;
  line-height: 1;
  color: #1b2633;
  font-weight: 750;
  margin-bottom: 6px;
}

.bank-holiday-label {
  max-width: 100%;
  display: inline-block;
  padding: 3px 6px;
  border-radius: 4px;
  background: #f8bcbc;
  color: #172126;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.15;
}

.activity-block {
  display: grid;
  align-content: start;
  grid-auto-rows: max-content;
  gap: 2px;
  width: 100%;
  text-align: left;
  border-radius: 6px;
  color: white;
  padding: 7px 8px;
  margin-bottom: 0;
  min-height: 42px;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08);
  transition: opacity 120ms ease, box-shadow 120ms ease, outline-color 120ms ease;
}

.activity-block.block-ink-dark,
.gantt-bar.block-ink-dark {
  color: #172126;
}

.activity-block.block-ink-dark .block-week-badge,
.gantt-bar.block-ink-dark .block-week-badge,
.activity-block.block-ink-dark .block-split-badge,
.gantt-bar.block-ink-dark .block-split-badge,
.activity-block.block-ink-dark .activity-internal-badge,
.gantt-bar.block-ink-dark .activity-internal-badge {
  background: rgba(23, 33, 38, 0.12);
  box-shadow: inset 0 0 0 1px rgba(23, 33, 38, 0.14);
  color: #172126;
}

.activity-block.block-ink-dark .task-mini-block,
.gantt-bar.block-ink-dark .task-mini-block {
  background: rgba(255, 255, 255, 0.48);
  box-shadow: inset 0 0 0 1px rgba(23, 33, 38, 0.12);
  color: #172126;
}

.activity-block.focus-dimmed {
  opacity: 0.28;
}

.activity-block.selected {
  outline: 3px solid rgba(23, 33, 38, 0.35);
  outline-offset: 1px;
  z-index: 14;
}

.activity-block.linked {
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.75), inset 0 0 0 1px rgba(0, 0, 0, 0.18);
}

.schedule-drop-preview,
.schedule-trim-preview,
.schedule-paste-preview {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: stretch;
  justify-self: stretch;
  margin: 2px;
  border: 3px solid var(--accent);
  border-radius: 7px;
  background: color-mix(in srgb, var(--accent) 10%, transparent);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.8), 0 8px 22px rgba(23, 33, 38, 0.18);
  pointer-events: none;
  z-index: 30;
}

.schedule-paste-preview {
  border-style: dashed;
}

.date-drop-preview,
.date-paste-preview {
  position: absolute;
  inset: 5px;
}

.gantt-drop-preview,
.gantt-trim-preview,
.gantt-paste-preview {
  position: relative;
  align-self: stretch;
  margin: 6px 3px;
}

.activity-block.task-child-block {
  background: color-mix(in srgb, var(--accent) 72%, #ffffff 28%) !important;
  border-left: 4px solid rgba(23, 33, 38, 0.45);
  padding-left: 10px;
}

.activity-block.child-activity-block,
.gantt-bar.child-activity-block {
  background:
    repeating-linear-gradient(
      90deg,
      color-mix(in srgb, var(--bar-color) 62%, #ffffff 38%) 0 6px,
      color-mix(in srgb, var(--bar-color) 40%, #ffffff 60%) 6px 11px
    ) !important;
  border-left: 4px solid rgba(23, 33, 38, 0.52);
  padding-left: 10px;
  filter: saturate(0.84) brightness(1.04);
  box-shadow: inset 6px 0 0 rgba(255, 255, 255, 0.22), inset 0 0 0 1px rgba(0, 0, 0, 0.14);
}

.activity-child-badge {
  flex: 1 1 auto;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  width: fit-content;
  max-width: 100%;
  min-height: 18px;
  padding: 2px 7px 2px 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.48);
  box-shadow: inset 0 0 0 1px rgba(23, 33, 38, 0.12);
  color: #172126;
  font-style: normal;
  line-height: 1;
}

.activity-child-badge i {
  flex: 0 0 auto;
  width: 13px;
  height: 13px;
  display: inline-grid;
  place-items: center;
  border: 1.5px solid var(--danger);
  border-radius: 999px;
  color: var(--danger);
  font-style: normal;
  font-weight: 950;
  font-size: 9px;
  line-height: 1;
  text-transform: uppercase;
}

.activity-child-badge small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: inherit;
  font-weight: 900;
  line-height: 1.05;
}

.activity-internal-badge {
  flex: 0 0 auto;
  width: 15px;
  height: 15px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.36);
  box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.72);
  color: #fff;
  font-style: normal;
  font-size: 10px;
  font-weight: 950;
  line-height: 1;
  text-transform: lowercase;
}

.activity-block.has-child-activities,
.gantt-bar.has-child-activities {
  box-shadow: inset 0 -3px 0 rgba(255, 255, 255, 0.28), inset 0 0 0 1px rgba(0, 0, 0, 0.14);
}

.activity-child-mark {
  flex: 0 0 auto;
  width: 13px;
  height: 18px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  opacity: 0.82;
}

.child-activity-block .activity-tags {
  opacity: 0.64;
}

.activity-block.child-activity-block.child-text-dark > span:not(.trim-handle):not(.trim-time-handle),
.gantt-bar.child-activity-block.child-text-dark > span:not(.trim-handle):not(.trim-time-handle) {
  color: #172126;
  font-weight: 650;
  opacity: 0.86;
}

.activity-block.child-activity-block.child-text-dark .task-mini-block,
.gantt-bar.child-activity-block.child-text-dark .task-mini-block {
  background: rgba(255, 255, 255, 0.48);
  box-shadow: inset 0 0 0 1px rgba(23, 33, 38, 0.12);
  color: #172126;
}

.activity-block.child-activity-block.child-text-dark .task-mini-title,
.activity-block.child-activity-block.child-text-dark .task-mini-status,
.activity-block.child-activity-block.child-text-dark .task-mini-meta,
.gantt-bar.child-activity-block.child-text-dark .task-mini-title,
.gantt-bar.child-activity-block.child-text-dark .task-mini-status,
.gantt-bar.child-activity-block.child-text-dark .task-mini-meta {
  color: #172126;
  font-weight: 650;
}

.activity-block.child-activity-block.child-text-dark .task-mini-status,
.gantt-bar.child-activity-block.child-text-dark .task-mini-status {
  background: rgba(23, 33, 38, 0.12);
  font-weight: 750;
}

.activity-block.child-activity-block.child-text-light > span:not(.trim-handle):not(.trim-time-handle),
.gantt-bar.child-activity-block.child-text-light > span:not(.trim-handle):not(.trim-time-handle) {
  color: #fff;
  font-weight: 650;
  opacity: 0.94;
}

.activity-block.child-activity-block.child-text-light .activity-child-badge,
.gantt-bar.child-activity-block.child-text-light .activity-child-badge {
  background: rgba(23, 33, 38, 0.2);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.24);
  color: #fff;
}

.activity-block.child-activity-block.child-text-light .activity-child-badge i,
.gantt-bar.child-activity-block.child-text-light .activity-child-badge i {
  border-color: rgba(255, 255, 255, 0.86);
  color: #fff;
}

.activity-block.child-activity-block.child-text-light .task-mini-block,
.gantt-bar.child-activity-block.child-text-light .task-mini-block {
  background: rgba(255, 255, 255, 0.2);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.16);
  color: #fff;
}

.activity-block.child-activity-block.child-text-light .task-mini-title,
.activity-block.child-activity-block.child-text-light .task-mini-status,
.activity-block.child-activity-block.child-text-light .task-mini-meta,
.gantt-bar.child-activity-block.child-text-light .task-mini-title,
.gantt-bar.child-activity-block.child-text-light .task-mini-status,
.gantt-bar.child-activity-block.child-text-light .task-mini-meta {
  color: #fff;
  font-weight: 650;
}

.activity-block.child-activity-block.child-text-light .task-mini-status,
.gantt-bar.child-activity-block.child-text-light .task-mini-status {
  background: rgba(255, 255, 255, 0.24);
  font-weight: 750;
}

.activity-task-preview {
  display: grid;
  gap: 2px;
  min-width: 0;
  margin-top: 3px;
  font-style: normal;
}

.task-mini-block {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 6px;
  min-width: 0;
  padding: 2px 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.24);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
  color: #fff;
  line-height: 1.15;
}

.task-mini-block.done {
  opacity: 0.62;
}

.task-mini-block.running {
  background: rgba(255, 255, 255, 0.34);
}

.task-mini-block.more {
  justify-content: center;
  opacity: 0.8;
}

.task-mini-title,
.task-mini-status,
.task-mini-meta {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 10px;
  font-weight: 750;
}

.task-mini-status {
  flex: 0 0 auto;
  padding: 1px 5px;
  border-radius: 999px;
  background: rgba(23, 33, 38, 0.2);
  font-size: 9px;
}

.task-mini-meta {
  flex: 0 0 auto;
  opacity: 0.82;
  font-weight: 700;
}

.task-link-mark {
  flex: 0 0 auto;
  width: 12px;
  height: 18px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  opacity: 0.75;
}

.month-activity {
  align-self: stretch;
  margin: 0;
  min-height: 0;
  max-height: none;
  padding: calc(3px * var(--zoom, 1)) calc(7px * var(--zoom, 1));
  position: relative;
  z-index: 2;
  overflow: hidden;
}

.month-activity.day-slot {
  align-self: start;
}

.month-milestones {
  position: absolute;
  left: 42px;
  right: 8px;
  top: 8px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 3px;
  z-index: 6;
  pointer-events: none;
}

.month-milestone-pill {
  max-width: 100%;
}

.cascade-activity.has-day-milestone:not(.expanded-slot) {
  padding-top: 28px;
}

.milestone-pill {
  --milestone-soft: color-mix(in srgb, var(--milestone-color, #657381) 18%, #ffffff 82%);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: 100%;
  min-height: 18px;
  padding: 2px 6px;
  border-radius: 999px;
  background: var(--milestone-soft);
  border: 1px solid color-mix(in srgb, var(--milestone-color, #657381) 28%, #ffffff 72%);
  color: #172126;
  font-size: 11px;
  font-weight: 850;
  line-height: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.milestone-pill svg {
  width: 12px;
  height: 12px;
  color: var(--milestone-color, #657381);
  flex: 0 0 auto;
}

.milestone-pill > span {
  display: block;
  flex: 0 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.milestone-more {
  min-height: 18px;
  padding: 2px 6px;
  border-radius: 999px;
  background: #edf2f6;
  color: #657381;
  font-size: 11px;
  font-weight: 850;
}

.milestone-project-code {
  font-size: 0.5em;
  font-weight: 950;
  letter-spacing: 0;
  vertical-align: middle;
}

.month-activity.full-slot {
  min-height: 0;
  max-height: none;
  margin: 0;
  padding: 8px;
  z-index: 3;
}

.month-activity.expanded-slot {
  z-index: 16;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12), 0 8px 22px rgba(17, 24, 39, 0.18);
}

.trim-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 18px;
  cursor: ew-resize;
  z-index: 3;
  display: block;
}

.month-activity:hover .trim-handle {
  background: rgba(255, 255, 255, 0.18);
}

.trim-start {
  left: 0;
}

.trim-end {
  right: 0;
}

.trim-handle:hover {
  background: rgba(255, 255, 255, 0.35);
}

.trim-time-handle {
  position: absolute;
  left: 0;
  right: 0;
  height: 16px;
  cursor: ns-resize;
  z-index: 3;
  display: block;
}

.trim-time-start {
  top: 0;
}

.trim-time-end {
  bottom: 0;
}

.trim-time-handle:hover {
  background: rgba(255, 255, 255, 0.35);
}

.is-trimming,
.is-trimming * {
  cursor: ew-resize !important;
}

.is-time-trimming,
.is-time-trimming * {
  cursor: ns-resize !important;
}

.month-activity.continues-before {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}

.month-activity.continues-after {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.activity-block strong {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  font-size: calc(11px * var(--zoom, 1));
  line-height: 1.1;
}

.activity-block .block-title-text,
.gantt-bar .block-title-text {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.activity-block .block-week-badge,
.gantt-bar .block-week-badge,
.activity-block .block-split-badge,
.gantt-bar .block-split-badge {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 15px;
  padding: 1px 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.26);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: calc(9px * var(--zoom, 1));
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  opacity: 1;
}

.activity-block .block-split-badge,
.gantt-bar .block-split-badge {
  background: rgba(23, 33, 38, 0.24);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.24);
}

.activity-block.assigned-to-me strong,
.activity-block.assigned-to-me span:not(.trim-handle):not(.trim-time-handle),
.gantt-bar.assigned-to-me b,
.gantt-bar.assigned-to-me span {
  font-weight: 850;
}

.activity-block span {
  font-size: calc(11px * var(--zoom, 1));
  opacity: 0.9;
}

.month-activity span:not(.trim-handle):not(.block-title-text):not(.block-week-badge):not(.block-split-badge) {
  display: none;
}

.month-activity.full-slot span:not(.trim-handle):not(.block-split-badge):not(.block-week-badge),
.month-activity.expanded-slot span:not(.trim-handle):not(.block-split-badge):not(.block-week-badge) {
  display: block;
}

.month-activity .block-title-text {
  display: inline;
}

.month-activity .block-week-badge,
.month-activity.full-slot .block-week-badge,
.month-activity.expanded-slot .block-week-badge,
.month-activity .block-split-badge,
.month-activity.full-slot .block-split-badge,
.month-activity.expanded-slot .block-split-badge {
  display: inline-flex;
}

.month-activity:not(.full-slot):not(.expanded-slot) strong {
  gap: 3px;
}

.month-activity:not(.full-slot):not(.expanded-slot) .activity-child-badge {
  min-height: 14px;
  padding: 1px 5px 1px 4px;
  gap: 3px;
}

.month-activity:not(.full-slot):not(.expanded-slot) .activity-child-badge small {
  font-size: 9px;
}

.month-activity:not(.full-slot):not(.expanded-slot) .activity-child-badge i {
  width: 11px;
  height: 11px;
  font-size: 7px;
}

.month-activity:not(.full-slot):not(.expanded-slot) .block-week-badge,
.month-activity:not(.full-slot):not(.expanded-slot) .block-split-badge {
  min-height: 11px;
  padding: 0 3px;
  font-size: 7px;
  line-height: 1;
}

.month-activity:not(.full-slot):not(.expanded-slot) .activity-internal-badge {
  width: 11px;
  height: 11px;
  font-size: 7px;
}

.month-activity.full-slot .block-week-badge,
.month-activity.expanded-slot .block-week-badge,
.month-activity.full-slot .block-split-badge,
.month-activity.expanded-slot .block-split-badge {
  min-height: 15px;
  padding: 1px 5px;
  font-size: 9px;
}

.month-activity .activity-task-preview {
  display: none;
}

.month-activity.full-slot .activity-task-preview,
.month-activity.expanded-slot .activity-task-preview {
  display: grid;
}

.month-activity.full-slot .task-mini-block,
.month-activity.expanded-slot .task-mini-block {
  display: flex;
}

.month-activity.full-slot .task-mini-title,
.month-activity.full-slot .task-mini-meta,
.month-activity.expanded-slot .task-mini-title,
.month-activity.expanded-slot .task-mini-meta {
  display: block;
}

.activity-tags {
  display: flex;
  align-self: start;
  align-items: flex-start;
  gap: 4px;
  flex-wrap: wrap;
  font-style: normal;
  min-height: 0;
  max-width: 100%;
  overflow: hidden;
}

.activity-tags[hidden] {
  display: none !important;
}

.activity-tags i {
  display: inline-flex;
  align-items: center;
  flex: 0 1 auto;
  height: 18px;
  min-width: 0;
  border-radius: 999px;
  color: #fff;
  font-size: 10px;
  line-height: 1;
  padding: 3px 6px;
  font-style: normal;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.week-activity .activity-tags {
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 6px;
  max-height: 18px;
  overflow: hidden;
}

.more-activities {
  align-self: center;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  padding: 0 10px;
  z-index: 2;
}

.week-number-head,
.week-number-cell {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  justify-content: center;
  text-align: center;
  background: #fbfcfc;
  border-right: 1px solid var(--line);
}

.week-number-cell {
  display: flex;
  align-items: flex-start;
  padding-top: 10px;
}

.week-view {
  min-width: 900px;
}

.day-view {
  min-width: 900px;
}

.week-grid {
  display: grid;
  grid-template-columns: 70px repeat(7, minmax(110px, 1fr));
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
}

.resizable-calendar-grid {
  overflow: visible;
}

.calendar-column-resize-handle {
  appearance: none;
  position: relative;
  align-self: stretch;
  justify-self: end;
  z-index: 42;
  width: 16px;
  min-width: 16px;
  margin-right: -8px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: col-resize;
  display: flex;
  align-items: center;
  justify-content: center;
}

.calendar-column-resize-handle span {
  width: 3px;
  height: calc(100% - 8px);
  border-radius: 999px;
  background: #8d98a4;
  opacity: 0;
  transition: opacity 120ms ease, background 120ms ease;
}

.calendar-column-resize-handle:hover span,
.calendar-column-resize-handle:active span {
  opacity: 1;
  background: var(--accent);
}

.is-resizing-calendar-columns,
.is-resizing-calendar-columns * {
  cursor: col-resize !important;
  user-select: none;
}

.calendar-hour-resize-handle {
  appearance: none;
  position: sticky;
  left: 0;
  align-self: end;
  justify-self: stretch;
  z-index: 58;
  height: 14px;
  margin-bottom: -7px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: row-resize;
  display: flex;
  align-items: center;
  justify-content: center;
}

.calendar-hour-resize-handle span {
  width: 38px;
  height: 3px;
  border-radius: 999px;
  background: #8d98a4;
  opacity: 0;
  transition: opacity 120ms ease, background 120ms ease;
}

.calendar-hour-resize-handle:hover span,
.calendar-hour-resize-handle:active span {
  opacity: 1;
  background: var(--accent);
}

.is-resizing-calendar-hours,
.is-resizing-calendar-hours * {
  cursor: row-resize !important;
  user-select: none;
}

.day-grid {
  min-width: max-content;
}

.day-resource-view {
  display: grid;
  gap: 0;
}

.week-view .week-head {
  position: sticky;
  top: 0;
  z-index: 62;
  --sticky-fill: #fbfcfc;
  background: var(--sticky-fill);
  border-bottom-color: transparent;
  box-shadow:
    0 -16px 0 #e9edf1,
    inset 0 -1px 0 var(--line);
}

.week-view .week-head:first-child {
  left: 0;
  z-index: 68;
  border-right-color: transparent;
  box-shadow:
    -16px 0 0 #e9edf1,
    0 -16px 0 #e9edf1,
    inset -1px 0 0 var(--line),
    inset 0 -1px 0 var(--line);
}

.week-view .time-slot {
  position: sticky;
  left: 0;
  z-index: 54;
  --sticky-fill: #fbfcfc;
  background: var(--sticky-fill);
  border-right-color: transparent;
  box-shadow:
    -16px 0 0 #e9edf1,
    inset -1px 0 0 var(--line);
}

.week-view .calendar-column-resize-handle {
  position: sticky;
  top: 0;
  z-index: 74;
}

.day-resource-head {
  border: 0;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  color: #344150;
  min-width: 0;
  padding-inline: 6px;
  justify-items: center;
}

.day-resource-head strong {
  display: block;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: center;
}

.day-resource-head span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
}

.day-resource-head.highlighted {
  background: var(--accent);
  color: var(--accent-ink);
}

.day-resource-head.highlighted span {
  color: rgba(255, 255, 255, 0.78);
}

.week-head,
.time-slot,
.week-cell {
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.week-head {
  min-height: 44px;
  display: grid;
  align-items: center;
  align-content: center;
  justify-content: center;
  font-weight: 750;
  color: var(--muted);
  font-size: 12px;
  background: #fbfcfc;
}

.header-milestones {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 3px;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  padding: 2px 4px 0;
  overflow: hidden;
}

.header-milestone-pill {
  flex: 0 1 auto;
  width: fit-content;
  min-width: 0;
  max-width: calc(100% - 8px);
  font-size: 10px;
}

.day-milestone-rail {
  align-self: end;
  display: flex;
  gap: 4px;
  padding: 0 8px 5px;
  overflow: hidden;
  pointer-events: none;
  z-index: 10;
}

.day-milestone-pill {
  box-shadow: 0 1px 4px rgba(23, 33, 38, 0.12);
}

.week-head.bank-holiday-head,
.gantt-day-head.bank-holiday-head {
  --sticky-fill: #f8bcbc;
  background: #f8bcbc;
  color: #172126;
}

.week-head small,
.gantt-day-head em {
  max-width: calc(100% - 8px);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #172126;
  font-size: 10px;
  font-style: normal;
  font-weight: 800;
}

.time-slot {
  min-height: var(--calendar-hour-row-height, 64px);
  padding: 8px;
  color: var(--muted);
  font-size: 12px;
  background: #fbfcfc;
}

.time-slot.out-of-hours {
  background: #eef1f4;
  color: #7b8794;
}

.week-cell {
  min-height: var(--calendar-hour-row-height, 64px);
  padding: 4px;
}

.week-cell.out-of-hours {
  background: #f0f2f4;
}

.week-cell.out-of-hours.bank-holiday-day {
  background: #fde8e8;
}

.week-head.weekend-day,
.week-cell.weekend-day {
  --sticky-fill: #eef1f4;
  background: #eef1f4;
  color: #7b8794;
}

.week-head.today {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}

.week-head.weekend-day.bank-holiday-head,
.week-cell.weekend-day.bank-holiday-day {
  --sticky-fill: #fde8e8;
  background: #fde8e8;
  color: #172126;
}

.week-cell.trim-target {
  box-shadow: inset 0 0 0 3px var(--warning);
}

.week-activity {
  align-self: stretch;
  min-height: 44px;
  height: auto;
  margin: 0;
  position: relative;
  z-index: 2;
  overflow: hidden;
  padding-bottom: 28px;
}

.week-activity .activity-task-preview {
  align-self: end;
}

.week-activity.expanded-slot {
  z-index: 16;
  overflow: visible;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12), 0 8px 22px rgba(17, 24, 39, 0.18);
}

.week-activity.expanded-slot strong,
.week-activity.expanded-slot span:not(.trim-time-handle) {
  max-width: 100%;
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  line-height: 1.15;
}

.week-activity.expanded-slot .activity-tags {
  max-width: 100%;
  flex-wrap: nowrap;
  overflow: hidden;
}

.week-activity:hover .trim-time-handle {
  background: rgba(255, 255, 255, 0.18);
}

.gantt-view {
  min-width: 980px;
  width: max-content;
  overflow: clip;
  border: 1px solid #b9c0c8;
  border-radius: var(--radius);
  background: #fbfcfc;
}

.gantt-view::-webkit-scrollbar {
  height: 14px;
  width: 14px;
}

.gantt-view::-webkit-scrollbar-track {
  background: #e6ebef;
  border-radius: 999px;
}

.gantt-view::-webkit-scrollbar-thumb {
  background: #8995a1;
  border: 3px solid #e6ebef;
  border-radius: 999px;
}

.gantt-view::-webkit-scrollbar-thumb:hover {
  background: #657381;
}

.gantt-filterbar {
  position: relative;
  z-index: 88;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  width: 100%;
  box-sizing: border-box;
  min-height: 26px;
  padding: 2px 6px;
  background: #f4f7f9;
  border-bottom: 1px solid #b9c0c8;
  box-shadow: 0 1px 0 #b9c0c8;
}

.schedule-filterbar {
  position: relative;
  z-index: 88;
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  min-height: 26px;
  padding: 2px 6px;
  box-sizing: border-box;
  background: #f4f7f9;
  border-bottom: 1px solid #b9c0c8;
  box-shadow: 0 1px 0 #b9c0c8;
}

.schedule-filterbar > span,
.schedule-resource-select > span {
  color: #657381;
  font-size: 11px;
  font-weight: 650;
}

.schedule-resource-select {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.schedule-resource-select select {
  width: 156px;
  min-height: 22px;
  height: 22px;
  padding: 1px 24px 1px 7px;
  font-size: 11px;
  font-weight: 650;
}

.schedule-filterbar .schedule-inline-resource-filter,
.schedule-filterbar .schedule-resource-filter-picker {
  width: 156px;
  min-height: 22px;
  height: 22px;
  margin-left: auto;
  font-size: 11px;
  font-weight: 650;
}

.schedule-filterbar .schedule-inline-resource-filter {
  padding: 1px 7px;
  justify-content: center;
}

.schedule-filterbar .schedule-inline-resource-filter span {
  color: inherit;
  font: inherit;
}

.schedule-filterbar .schedule-inline-resource-filter b,
.schedule-resource-filter-picker > summary b {
  min-width: 17px;
  padding: 1px 4px;
  border-radius: 999px;
  background: rgba(23, 33, 38, 0.1);
  color: inherit;
  font-size: 10px;
  line-height: 1;
}

.schedule-resource-filter-picker > summary {
  min-height: 22px;
  height: 22px;
  padding: 1px 7px;
  border-radius: 6px;
  justify-content: center;
  font-size: 11px;
  font-weight: 650;
}

.schedule-resource-filter-picker > summary::after {
  display: none;
}

.schedule-resource-filter-picker.active > summary {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

.schedule-resource-filter-picker .multi-select-menu {
  left: auto;
  right: 0;
  width: 260px;
  max-height: min(360px, 60vh);
}

.schedule-resource-filter-picker .multi-select-menu label {
  grid-template-columns: 18px minmax(0, 1fr) auto;
}

.schedule-resource-filter-actions {
  position: sticky;
  bottom: -6px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin: 4px -6px -6px;
  padding: 6px;
  border-top: 1px solid var(--line);
  background: #fff;
}

.month-people-filterbar {
  justify-content: flex-end;
}

.month-people-filterbar .calendar-people-filter {
  width: 156px;
  flex-basis: 156px;
  margin-left: auto;
}

.month-people-filterbar .calendar-people-filter summary {
  min-height: 22px;
  height: 22px;
  padding: 1px 7px;
  font-size: 11px;
}

.month-people-filterbar .calendar-people-filter .multi-select-menu {
  right: 0;
  left: auto;
}

.schedule-resource-count {
  padding-right: 4px;
}

.gantt-filterbar span {
  color: #657381;
  font-size: 11px;
  font-weight: 650;
}

.gantt-group-select {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.gantt-group-select select {
  width: 156px;
  min-height: 22px;
  height: 22px;
  padding: 1px 24px 1px 7px;
  font-size: 11px;
  font-weight: 650;
}

.gantt-filterbar .gantt-inline-resource-filter {
  width: 156px;
  min-height: 22px;
  height: 22px;
  margin-left: auto;
  padding: 1px 7px;
  justify-content: center;
  font-size: 11px;
  font-weight: 650;
}

.gantt-filterbar .gantt-inline-resource-filter span {
  color: inherit;
  font: inherit;
}

.gantt-filterbar .gantt-inline-resource-filter b {
  min-width: 17px;
  padding: 1px 4px;
  font-size: 10px;
}

.gantt-filterbar .gantt-resource-count {
  padding-right: 4px;
}

.gantt-board {
  min-width: max-content;
  position: relative;
  display: grid;
  grid-template-columns: var(--gantt-group-nav-width, 32px) max-content 16px;
  align-items: start;
}

.gantt-board-content {
  grid-column: 2;
  min-width: max-content;
  position: relative;
}

.gantt-group-navigator {
  grid-column: 1;
  position: sticky;
  left: 0;
  top: 0;
  z-index: 84;
  display: flex;
  align-items: stretch;
  width: var(--gantt-group-nav-width, 32px);
  height: calc(100vh - 136px);
  max-height: 100%;
  min-height: 180px;
  background: #eef2f5;
  border-right: 1px solid #aeb7c1;
  border-bottom: 1px solid #aeb7c1;
  box-shadow: 1px 0 0 rgba(23, 33, 38, 0.06);
  overflow: hidden;
}

.gantt-group-pane {
  flex: 0 0 16px;
  min-width: 0;
  display: flex;
  background: #f4f7f9;
  border-right: 1px solid #c6cdd4;
  box-sizing: border-box;
}

.gantt-group-pane.expanded {
  flex-basis: calc(16px + var(--gantt-category-width, 148px));
}

.gantt-group-pane[data-gantt-group-pane="type"].expanded {
  flex-basis: calc(16px + var(--gantt-type-width, 148px));
}

.gantt-group-rail {
  flex: 0 0 15px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 6px 0;
  background: #eef2f5;
  border-right: 1px solid #c6cdd4;
  box-sizing: border-box;
}

.gantt-group-rail button {
  appearance: none;
  width: 14px;
  height: 20px;
  flex: 0 0 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid #bcc5ce;
  border-radius: 3px;
  background: #ffffff;
  color: #344150;
  cursor: pointer;
}

.gantt-group-rail button:hover:not(:disabled) {
  border-color: var(--accent);
  color: var(--accent);
}

.gantt-group-rail button:disabled {
  opacity: 0.34;
  cursor: default;
}

.gantt-group-rail .icon {
  width: 10px;
  height: 10px;
}

.gantt-select-square {
  width: 8px;
  height: 8px;
  border: 1px solid currentColor;
  background: transparent;
  box-sizing: border-box;
}

.gantt-select-square.filled {
  background: currentColor;
}

.gantt-group-options {
  position: relative;
  min-width: 0;
  flex: 1;
  display: grid;
  grid-template-rows: 32px minmax(0, 1fr);
  background: #f8fafb;
}

.gantt-group-options > strong {
  display: flex;
  align-items: center;
  padding: 0 9px;
  border-bottom: 1px solid #c6cdd4;
  color: #344150;
  font-size: 12px;
}

.gantt-group-options > div {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.gantt-group-options button {
  appearance: none;
  width: 100%;
  min-height: 26px;
  display: flex;
  align-items: center;
  padding: 3px 8px;
  border: 0;
  border-bottom: 1px solid #e1e6ea;
  background: transparent;
  color: #344150;
  font-size: 12px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: background 120ms ease, box-shadow 120ms ease;
}

.gantt-group-options button:hover {
  background: #eef2f5;
}

.gantt-group-options button.selected {
  background: color-mix(in srgb, var(--accent) 12%, #ffffff);
  box-shadow: inset 3px 0 0 color-mix(in srgb, var(--accent) 72%, #ffffff);
  color: #172126;
}

.gantt-group-options p {
  margin: 10px 8px;
  color: #657381;
  font-size: 11px;
}

.gantt-group-resize-handle {
  position: absolute;
  top: 0;
  right: -5px;
  bottom: 0;
  z-index: 4;
  width: 10px !important;
  min-height: 100% !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  cursor: col-resize !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

.gantt-group-resize-handle span {
  width: 3px;
  height: 18px;
  border-radius: 2px;
  opacity: 0.45;
  background: radial-gradient(circle, #657381 1px, transparent 1.2px) center / 3px 5px repeat-y;
  transition: opacity 120ms ease;
}

.gantt-group-resize-handle:hover span,
.is-resizing-gantt-group .gantt-group-resize-handle span {
  opacity: 1;
}

.is-resizing-gantt-group,
.is-resizing-gantt-group * {
  cursor: col-resize !important;
  user-select: none;
}

.gantt-header,
.gantt-row {
  display: grid;
  grid-template-columns: var(--gantt-resource-width, 165px) 1fr;
}

.gantt-header {
  position: sticky;
  top: 0;
  z-index: 78;
  isolation: isolate;
  background: #f4f7f9;
  box-shadow: 0 1px 0 #aeb7c1;
}

.gantt-header::before {
  content: "";
  position: absolute;
  inset: 0 0 0 -72px;
  z-index: 0;
  background: #f4f7f9;
  pointer-events: none;
}

.gantt-resource-head,
.gantt-resource {
  position: sticky;
  left: var(--gantt-group-nav-width, 32px);
  z-index: 48;
  background: #f4f7f9;
  border-right: 1px solid #aeb7c1;
  overflow: visible;
}

.gantt-resource-head {
  grid-column: 1;
  grid-row: 1;
  z-index: 72;
  min-height: 44px;
  display: grid;
  grid-template-rows: 27px 17px;
  padding: 0;
  font-weight: 600;
  color: #344150;
  border-bottom: 1px solid #aeb7c1;
}

.gantt-resource-title {
  display: flex;
  align-items: center;
  min-width: 0;
  padding: 0 8px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  border-bottom: 1px solid #c6cdd4;
  font-size: 12px;
}

.gantt-header-nav-cell {
  display: flex;
  align-items: center;
  min-width: 0;
  padding: 1px 4px;
}

.gantt-header-nav-controls {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 2px;
}

.gantt-header-nav-button {
  appearance: none;
  min-width: 0;
  width: auto;
  height: 14px;
  flex: 1 1 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #b9c0c8;
  border-radius: 3px;
  background: #ffffff;
  color: #344150;
  cursor: pointer;
  padding: 0;
}

.gantt-header-nav-button:not(.medium):not(.strong) {
  flex-grow: 1.25;
}

.gantt-header-nav-button:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 8%, #ffffff);
}

.gantt-header-nav-button .icon {
  width: 10px;
  height: 10px;
}

.gantt-header-nav-button.medium .icon {
  filter: drop-shadow(0 0 0.35px currentColor);
}

.gantt-header-nav-button.strong .icon {
  filter: drop-shadow(0 0 0.7px currentColor);
}

.gantt-resource-head::before,
.gantt-resource::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: -72px;
  width: 72px;
  background: inherit;
  pointer-events: none;
}

.gantt-days,
.gantt-cells {
  grid-column: 2;
  grid-row: 1;
  display: grid;
  position: relative;
}

.gantt-days {
  z-index: 64;
}

.gantt-milestone-marker {
  align-self: stretch;
  justify-self: stretch;
  border-left: 2px solid var(--milestone-color, #657381);
  background: transparent;
  pointer-events: none;
  z-index: 18;
  display: flex;
  align-items: end;
  padding: 4px 2px;
}

.gantt-milestone-marker span {
  max-width: 100%;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 5px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--milestone-color, #657381) 18%, #ffffff 82%);
  color: #172126;
  font-size: 10px;
  font-weight: 850;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.gantt-milestone-marker svg {
  width: 11px;
  height: 11px;
  color: var(--milestone-color, #657381);
}

.gantt-day-head {
  min-height: 44px;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 1px;
  background: #f4f7f9;
  border-right: 1px solid #b9c0c8;
  border-bottom: 1px solid #aeb7c1;
  color: #1b2633;
  font-size: 12px;
  cursor: grab;
  touch-action: none;
  user-select: none;
}

.gantt-day-head:focus-visible {
  position: relative;
  z-index: 83;
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}

.gantt-open-day-view-button {
  appearance: none;
  z-index: 84;
  align-self: start;
  justify-self: end;
  width: 24px;
  height: 24px;
  margin: 4px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #bac4ce;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.96);
  color: #344150;
  box-shadow: 0 1px 2px rgba(23, 33, 43, 0.14);
  cursor: pointer;
}

.gantt-open-day-view-button:hover,
.gantt-open-day-view-button:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
  outline: none;
}

.gantt-open-day-view-button .icon {
  width: 13px;
  height: 13px;
}

.week-view:not(.day-view) .week-head[data-week-anchor-date] {
  cursor: grab;
  user-select: none;
  touch-action: pan-y;
}

.is-panning-week-header,
.is-panning-week-header *,
.is-panning-gantt-header,
.is-panning-gantt-header * {
  cursor: grabbing !important;
  user-select: none;
}

.gantt-hourly .gantt-resource-head {
  min-height: 65px;
  grid-template-rows: 44px 21px;
}

.gantt-hourly .gantt-days {
  grid-template-rows: 44px 21px;
}

.gantt-day-span {
  min-height: 44px;
}

.gantt-hour-head {
  min-height: 21px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #eef3f6;
  border-right: 1px solid #c4cbd2;
  border-bottom: 1px solid #aeb7c1;
  color: #53616e;
  font-size: 11px;
  font-weight: 750;
}

.gantt-day-head.today {
  background: #d7edf0;
  box-shadow: inset 0 0 0 2px var(--accent);
}

.gantt-day-head.today.weekend-day {
  background: #eef1f4;
}

.gantt-day-head.today.bank-holiday-head {
  background: #f8bcbc;
}

.gantt-day-head span {
  color: #53616e;
  white-space: nowrap;
}

.gantt-row {
  position: relative;
  height: var(--gantt-row-height, 96px);
  min-height: var(--gantt-row-height, 96px);
  box-shadow: inset 0 -1px 0 #b9c0c8;
}

.gantt-row-resize-handle {
  appearance: none;
  position: sticky;
  left: var(--gantt-group-nav-width, 32px);
  grid-column: 1;
  grid-row: 1;
  align-self: end;
  justify-self: stretch;
  z-index: 58;
  height: 12px;
  margin-bottom: -6px;
  padding: 0;
  border: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  cursor: row-resize;
  background: transparent;
}

.gantt-timeline-zoom-handle {
  appearance: none;
  position: relative;
  align-self: stretch;
  justify-self: end;
  z-index: 82;
  width: 16px;
  min-width: 16px;
  height: 100%;
  min-height: 42px;
  margin-right: -8px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: col-resize;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gantt-hourly .gantt-timeline-zoom-handle {
  min-height: 48px;
}

.gantt-timeline-zoom-handle span {
  width: 3px;
  height: calc(100% - 8px);
  border-radius: 999px;
  background: #aeb7c1;
  opacity: 0;
  transition: opacity 120ms ease, background 120ms ease;
}

.gantt-timeline-zoom-handle:hover span,
.is-resizing-gantt-timeline .gantt-timeline-zoom-handle span {
  opacity: 1;
  background: var(--accent);
}

.is-resizing-gantt-timeline,
.is-resizing-gantt-timeline * {
  cursor: col-resize !important;
  user-select: none;
}

.gantt-row-resize-handle span {
  width: 56px;
  height: 3px;
  border-radius: 999px;
  background: #aeb7c1;
  opacity: 0;
  transition: opacity 120ms ease, background 120ms ease;
}

.gantt-row-resize-handle:hover span,
.is-resizing-gantt-rows .gantt-row-resize-handle span {
  opacity: 1;
  background: var(--accent);
}

.is-resizing-gantt-rows,
.is-resizing-gantt-rows * {
  cursor: row-resize !important;
  user-select: none;
}

.gantt-resource {
  grid-column: 1;
  grid-row: 1;
  appearance: none;
  font: inherit;
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;
  padding: 5px 8px;
  border-bottom: 1px solid #b9c0c8;
  border-top: 0;
  border-left: 0;
  text-align: left;
  cursor: pointer;
  overflow: hidden;
  transition: background 120ms ease, color 120ms ease, box-shadow 120ms ease;
}

.gantt-resource.highlighted {
  background: color-mix(in srgb, var(--accent) 12%, #ffffff);
  color: #172126;
  box-shadow: inset 3px 0 0 color-mix(in srgb, var(--accent) 72%, #ffffff), inset -1px 0 0 rgba(0, 0, 0, 0.08);
}

.gantt-resource-name {
  display: block;
  width: 100%;
  font-size: 12px;
  font-weight: 600;
  color: #172126;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.gantt-resource.highlighted .gantt-resource-name {
  color: inherit;
}

.gantt-visible-resource-rail {
  grid-column: 3;
  position: sticky;
  right: 0;
  top: 0;
  z-index: 86;
  align-self: stretch;
  width: 16px;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 6px 0;
  box-sizing: border-box;
  background: #eef2f5;
  border-left: 1px solid #aeb7c1;
  border-bottom: 1px solid #aeb7c1;
}

.gantt-visible-resource-rail button {
  appearance: none;
  width: 14px;
  height: 20px;
  flex: 0 0 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid #bcc5ce;
  border-radius: 3px;
  background: #ffffff;
  color: #344150;
  cursor: pointer;
}

.gantt-visible-resource-rail button:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.gantt-cells {
  grid-template-rows: minmax(var(--gantt-row-height, 96px), 1fr);
  grid-auto-rows: minmax(var(--gantt-row-height, 96px), 1fr);
  height: var(--gantt-row-height, 96px);
  min-height: var(--gantt-row-height, 96px);
  overflow: hidden;
  border-bottom: 1px solid #b9c0c8;
  background:
    repeating-linear-gradient(
      to right,
      transparent 0 calc(var(--gantt-column-width) - 1px),
      #b9c0c8 calc(var(--gantt-column-width) - 1px) var(--gantt-column-width)
    ),
    #fbfcfc;
}

.gantt-cells.trim-target {
  box-shadow: inset 0 0 0 3px rgba(99, 75, 199, 0.28);
}

.gantt-cells.hourly {
  background:
    repeating-linear-gradient(
      to right,
      #f0f2f4 0 var(--gantt-business-start),
      transparent var(--gantt-business-start) var(--gantt-business-end),
      #f0f2f4 var(--gantt-business-end) var(--gantt-day-width)
    ),
    repeating-linear-gradient(
      to right,
      transparent 0 calc(var(--gantt-column-width) - 1px),
      #d6dce1 calc(var(--gantt-column-width) - 1px) var(--gantt-column-width)
    ),
    #fbfcfc;
}

.gantt-cells.weekends-visible.week-start-monday {
  --gantt-weekend-shading: repeating-linear-gradient(
    to right,
    transparent 0 calc(var(--gantt-day-width) * 5),
    #eef1f4 calc(var(--gantt-day-width) * 5) calc(var(--gantt-day-width) * 7)
  );
}

.gantt-cells.weekends-visible.week-start-sunday {
  --gantt-weekend-shading: repeating-linear-gradient(
    to right,
    #eef1f4 0 var(--gantt-day-width),
    transparent var(--gantt-day-width) calc(var(--gantt-day-width) * 6),
    #eef1f4 calc(var(--gantt-day-width) * 6) calc(var(--gantt-day-width) * 7)
  );
}

.gantt-cells.weekends-visible {
  background:
    repeating-linear-gradient(
      to right,
      transparent 0 calc(var(--gantt-column-width) - 1px),
      #b9c0c8 calc(var(--gantt-column-width) - 1px) var(--gantt-column-width)
    ),
    var(--gantt-weekend-shading),
    #fbfcfc;
}

.gantt-cells.hourly.weekends-visible {
  background:
    repeating-linear-gradient(
      to right,
      #f0f2f4 0 var(--gantt-business-start),
      transparent var(--gantt-business-start) var(--gantt-business-end),
      #f0f2f4 var(--gantt-business-end) var(--gantt-day-width)
    ),
    repeating-linear-gradient(
      to right,
      transparent 0 calc(var(--gantt-column-width) - 1px),
      #d6dce1 calc(var(--gantt-column-width) - 1px) var(--gantt-column-width)
    ),
    var(--gantt-weekend-shading),
    #fbfcfc;
}

.gantt-hour-head.out-of-hours {
  background: #f0f2f4;
  color: #7b8794;
}

.gantt-grid-shade {
  align-self: stretch;
  justify-self: stretch;
  border-right: 1px solid #b9c0c8;
  pointer-events: none;
  z-index: 1;
}

.gantt-day-head.weekend-day,
.gantt-hour-head.weekend-day,
.gantt-grid-shade.weekend-day {
  background: #eef1f4;
  color: #7b8794;
}

.gantt-day-head.weekend-day.bank-holiday-head,
.gantt-grid-shade.weekend-day.bank-holiday-day,
.gantt-grid-shade.bank-holiday-day {
  background: #fde8e8;
  color: #172126;
}

.out-of-office-block {
  --ooo-color: #d97706;
  pointer-events: none;
  min-width: 0;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--ooo-color) 38%, #ffffff);
  background: color-mix(in srgb, var(--ooo-color) 16%, #ffffff);
  color: #6d3f06;
  box-shadow: inset 3px 0 0 color-mix(in srgb, var(--ooo-color) 80%, #1f2933);
}

.out-of-office-block strong,
.out-of-office-block span {
  position: relative;
  z-index: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.day-out-of-office {
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
  margin: 3px;
  padding: 6px 8px;
  border-radius: 6px;
  font-size: 12px;
}

.day-out-of-office span {
  font-size: 11px;
  color: #7a5b21;
}

.gantt-out-of-office {
  z-index: 2;
  align-self: stretch;
  justify-self: stretch;
  display: flex;
  align-items: flex-start;
  margin: 2px 1px;
  padding: 6px 8px;
  border-radius: 5px;
  font-size: 12px;
  opacity: 0.86;
}

.gantt-bar {
  position: absolute;
  height: 24px;
  left: 0;
  right: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 8px;
  overflow: hidden;
  border-radius: 5px;
  background: var(--bar-color);
  color: #fff;
  padding: 0 8px;
  text-align: left;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12);
  transition: opacity 120ms ease, box-shadow 120ms ease, outline-color 120ms ease;
}

.gantt-bar.focus-dimmed {
  opacity: 0.28;
}

.gantt-bar.full-slot,
.gantt-bar.expanded-slot {
  align-items: flex-start;
  align-content: flex-start;
  flex-direction: column;
  justify-content: flex-start;
  gap: 4px;
  padding: 8px;
}

.gantt-bar.expanded-slot {
  z-index: 16;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12), 0 8px 22px rgba(17, 24, 39, 0.18);
}

.gantt-bar.hourly {
  min-width: 28px;
}

.gantt-bar .trim-handle {
  width: 14px;
}

.gantt-bar:hover .trim-handle {
  background: rgba(255, 255, 255, 0.2);
}

.gantt-bar.selected {
  outline: 3px solid rgba(23, 33, 38, 0.35);
  outline-offset: 1px;
  z-index: 14;
}

.gantt-bar.task-child-block {
  --bar-color: color-mix(in srgb, var(--accent) 72%, #ffffff 28%);
  border-left: 4px solid rgba(23, 33, 38, 0.45);
}

.month-activity.selected,
.week-activity.selected,
.gantt-bar.selected {
  z-index: 14;
}

.month-activity.expanded-slot,
.week-activity.expanded-slot,
.gantt-bar.expanded-slot {
  z-index: 16;
}

.activity-block.pencil-status-block {
  position: relative;
  padding-left: 16px;
}

.gantt-bar.pencil-status-block,
.gantt-bar.pencil-status-block.full-slot,
.gantt-bar.pencil-status-block.expanded-slot {
  padding-left: 16px;
}

.activity-block.pencil-status-block::before,
.gantt-bar.pencil-status-block::before {
  content: "";
  position: absolute;
  top: 2px;
  bottom: 2px;
  left: 2px;
  width: 7px;
  border-radius: 2px;
  background-color: color-mix(in srgb, var(--bar-color) 62%, #172126 38%);
  background-image:
    linear-gradient(45deg, transparent 36%, rgba(255, 255, 255, 0.96) 37% 57%, transparent 58%),
    linear-gradient(-45deg, transparent 36%, rgba(255, 255, 255, 0.96) 37% 57%, transparent 58%);
  background-position: center;
  background-size: 7px 7px;
  box-shadow: 0 0 0 1px rgba(23, 33, 38, 0.2);
  pointer-events: none;
  z-index: 2;
}

.gantt-bar b {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1 1 auto;
}

.gantt-bar.full-slot b,
.gantt-bar.expanded-slot b {
  max-width: 100%;
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  line-height: 1.15;
}

.gantt-bar span {
  font-size: 11px;
  opacity: 0.88;
  flex: 0 0 auto;
}

.gantt-bar > .gantt-time-meta {
  min-width: 0;
  max-width: 82px;
  flex: 0 10 82px;
  overflow: hidden;
  text-overflow: clip;
  white-space: nowrap;
  font-size: 10px;
  opacity: 0.68;
}

.gantt-bar.full-slot > .gantt-time-meta,
.gantt-bar.expanded-slot > .gantt-time-meta {
  max-width: 100%;
  flex: 0 0 auto;
  margin-top: auto;
  margin-left: 0;
}

.activity-block.block-text-small strong,
.activity-block.block-text-small .block-title-text {
  font-size: 10px;
}

.activity-block.block-text-small span {
  font-size: 10px;
}

.activity-block.block-text-medium strong,
.activity-block.block-text-medium .block-title-text {
  font-size: calc(11px * var(--zoom, 1));
}

.activity-block.block-text-medium span {
  font-size: calc(11px * var(--zoom, 1));
}

.activity-block.block-text-large strong,
.activity-block.block-text-large .block-title-text {
  font-size: 13px;
}

.activity-block.block-text-large span {
  font-size: 12px;
}

.gantt-bar .activity-task-preview {
  width: 100%;
}

.gantt-bar .task-mini-block {
  width: 100%;
  display: flex;
}

.gantt-bar .task-mini-title,
.gantt-bar .task-mini-meta {
  font-size: 10px;
}

.gantt-bar .task-mini-title {
  flex: 1 1 auto;
}

.gantt-bar .activity-tags {
  flex: 0 0 auto;
  max-width: 35%;
  overflow: hidden;
  flex-wrap: nowrap;
}

.gantt-bar.expanded-slot .activity-tags,
.gantt-bar.full-slot .activity-tags {
  max-width: 100%;
  flex-wrap: wrap;
  overflow: visible;
}

.block-preview {
  min-height: 72px;
  display: grid;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #f4f7f9;
}

.block-preview .activity-block {
  max-width: 420px;
  margin: 0;
}

.gantt-empty {
  min-height: 140px;
  display: grid;
  place-items: center;
  color: #53616e;
  background: #f4f7f9;
}

.inspector {
  padding: 0;
  overflow: hidden;
  background: #f4f6f8;
}

.inspector-panel {
  display: grid;
  grid-template-rows: auto auto auto minmax(0, 1fr);
  gap: 12px;
  height: 100%;
  min-height: 0;
  padding: 16px;
}

.inspector-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.inspector-search {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  min-width: 0;
  height: 38px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfc;
  color: #657381;
}

.inspector-search .icon {
  width: 16px;
  height: 16px;
}

.inspector-search input {
  min-width: 0;
  height: 34px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-size: 14px;
  outline: 0;
}

.inspector-search:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(91, 68, 194, 0.16);
}

.stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.stat {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px;
  background: #fbfcfc;
}

.stat b {
  display: block;
  font-size: 18px;
}

.stat span {
  color: var(--muted);
  font-size: 12px;
}

.stat.quote-total-match {
  border-color: rgba(41, 128, 85, 0.28);
  background: #f0faf4;
}

.stat.quote-total-match b,
.stat.quote-total-match span {
  color: var(--success);
}

.stat.quote-total-mismatch {
  border-color: rgba(176, 59, 59, 0.28);
  background: #fff5f5;
}

.quote-import-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.62);
  padding: 6px 8px;
  min-width: 0;
}

.quote-import-stack {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: -4px;
}

.quote-import-summary span,
.quote-import-summary em {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
  line-height: 1.25;
}

.quote-import-summary strong {
  display: block;
  color: #344150;
  font-size: 12px;
  line-height: 1.25;
  margin-top: 1px;
  max-width: 420px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 760px) {
  .quote-import-stack {
    grid-template-columns: 1fr;
  }

  .activity-kit-summary,
  .activity-kit-billing-stats,
  .activity-kit-source-toolbar,
  .activity-kit-source-card,
  .activity-kit-row-head,
  .activity-inhouse-grid,
  .activity-kit-grid,
  .activity-kit-bottom {
    grid-template-columns: 1fr;
  }

  .activity-kit-delete {
    justify-self: start;
    margin-top: 0;
  }
}

.stat.quote-total-mismatch b,
.stat.quote-total-mismatch span {
  color: var(--danger);
}

.stat.variance-over b,
.variance-over {
  color: var(--danger);
}

.stat.variance-under b,
.variance-under {
  color: #23764d;
}

.quote-baseline {
  display: grid;
  gap: 10px;
  margin-top: 10px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.quote-baseline h4 {
  margin: 0;
  font-size: 13px;
}

.activity-kit-panel {
  gap: 14px;
}

.activity-kit-summary,
.activity-kit-billing-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.activity-kit-summary-counts {
  grid-template-columns: minmax(0, 220px);
}

.billing-preparation-summary .activity-kit-summary {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
}

.billing-preparation-summary b {
  overflow-wrap: anywhere;
}

.activity-kit-summary > div,
.activity-kit-billing-stats > div {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  padding: 8px 10px;
}

.activity-kit-summary span,
.activity-kit-billing-stats span,
.activity-kit-total span,
.activity-kit-billing-head span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.activity-kit-summary b,
.activity-kit-billing-stats b,
.activity-kit-total b {
  display: block;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.25;
  margin-top: 2px;
}

.activity-kit-list {
  display: grid;
  gap: 7px;
}

.activity-kit-source-picker {
  display: grid;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafb;
  padding: 10px;
}

.activity-kit-source-toolbar {
  display: grid;
  grid-template-columns: minmax(160px, 1.4fr) repeat(3, minmax(120px, 1fr));
  gap: 8px;
  align-items: end;
}

.activity-kit-source-status {
  font-size: 12px;
}

.activity-kit-source-results {
  display: grid;
  gap: 6px;
  max-height: 260px;
  overflow: auto;
}

.activity-kit-source-card {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) minmax(80px, 130px) auto;
  gap: 8px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  padding: 7px;
}

.activity-kit-source-card.is-manual-external {
  background: #fbfcfd;
}

.activity-kit-source-card b,
.activity-kit-source-card span {
  display: block;
  min-width: 0;
}

.activity-kit-source-card b {
  font-size: 13px;
  line-height: 1.2;
}

.activity-kit-source-card span,
.activity-kit-source-card small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.activity-kit-source-thumb,
.activity-kit-thumb {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #eef3f6;
  color: var(--muted);
  text-decoration: none;
}

.activity-kit-type-icon .icon {
  width: 28px;
  height: 28px;
}

.activity-kit-type-icon-external-labour {
  background: #eef6ff;
  color: #356aa0;
}

.activity-kit-type-icon-external-hire,
.activity-kit-type-icon-seqncer-asset {
  background: #eef8f5;
  color: #23745f;
}

.activity-kit-type-icon-software {
  background: #f5f1ff;
  color: #6547b8;
}

.activity-kit-type-icon-client-owned {
  background: #fff7e8;
  color: #a25b00;
}

.activity-kit-type-icon-purchase {
  background: #f7f3ee;
  color: #7a5738;
}

.activity-kit-source-thumb img,
.activity-kit-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.activity-kit-row {
  display: grid;
  gap: 7px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  padding: 8px;
}

.activity-kit-row-head {
  display: grid;
  gap: 6px;
  align-items: end;
  min-width: 0;
}

.activity-kit-row-head-manual {
  grid-template-columns: minmax(170px, 260px) minmax(132px, 170px) 30px;
}

.activity-kit-row-head-source-details {
  grid-template-columns: minmax(0, 1fr) 30px;
}

.activity-kit-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(112px, 156px));
  gap: 6px;
  align-items: start;
  min-width: 0;
}

.activity-inhouse-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(112px, 156px));
  gap: 6px;
  align-items: end;
  min-width: 0;
}

.activity-inhouse-source-field[hidden],
.activity-inhouse-person-field[hidden] {
  display: none;
}

.activity-inhouse-name-field {
  grid-column: span 2;
  min-width: 0;
}

.activity-inhouse-icon {
  background: #eef1ff;
  color: var(--accent);
}

.activity-row-compact-check {
  display: inline-flex;
  width: max-content;
  max-width: 100%;
  justify-self: start;
  align-self: start;
  gap: 5px;
  min-height: 0;
  margin-top: 1px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #39464d;
  font-size: 11px;
  font-weight: 750;
  line-height: 1.1;
}

.activity-row-compact-check input {
  width: 12px;
  height: 12px;
}

.activity-kit-row .field.activity-follow-billing-quantity-field {
  gap: 2px;
}

.activity-kit-row .field.activity-follow-billing-quantity-field .activity-row-follow-check {
  gap: 4px;
  margin-top: -6px;
  font-size: 10.5px;
}

.activity-kit-row .field.activity-follow-billing-quantity-field .activity-row-follow-check input {
  width: 10px;
  height: 10px;
}

.activity-row-compact-check span {
  white-space: nowrap;
}

.activity-kit-row input.readonly,
.activity-inhouse-row input.readonly {
  background: #eef2f5;
  color: var(--muted);
}

.activity-kit-public-grid {
  grid-template-columns: minmax(90px, 140px) minmax(0, 1fr);
}

.activity-kit-bottom {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(104px, 128px);
  gap: 6px;
  align-items: end;
  min-width: 0;
}

.activity-kit-public-row .activity-kit-row-head {
  grid-template-columns: minmax(0, 1fr) 34px;
}

.activity-kit-public-row .activity-kit-bottom {
  grid-template-columns: minmax(0, 1fr);
}

.activity-kit-total {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fafb;
  padding: 6px 7px;
}

.activity-kit-delete {
  align-self: center;
  width: 30px;
  height: 30px;
  margin-top: 13px;
}

.activity-inhouse-row .activity-kit-source-details {
  position: relative;
}

.activity-inhouse-row .activity-kit-source-details[open] {
  padding-right: 36px;
}

.activity-inhouse-delete {
  position: absolute;
  top: 0;
  right: 0;
  margin-top: 0;
}

.activity-kit-row:not(.activity-inhouse-row) .activity-kit-row-head {
  margin-bottom: 0;
}

.activity-kit-row:not(.activity-inhouse-row) .activity-kit-grid {
  margin-top: 8px;
}

.activity-kit-row .field,
.activity-kit-row input,
.activity-kit-row select,
.activity-kit-row textarea {
  min-width: 0;
}

.activity-kit-preset-field {
  grid-column: span 2;
}

.activity-kit-row .field {
  gap: 3px;
  align-content: start;
  align-self: start;
}

.activity-kit-row .field label {
  font-size: 11px;
  line-height: 1.1;
}

.activity-kit-row input,
.activity-kit-row select,
.activity-kit-row textarea {
  min-height: 28px;
  padding: 4px 7px;
  border-radius: 6px;
  font-size: 12px;
  line-height: 1.2;
}

.activity-kit-grid input,
.activity-kit-grid select {
  height: 28px;
}

.activity-kit-row textarea {
  min-height: 50px;
}

.activity-kit-row .activity-kit-total span {
  font-size: 11px;
}

.activity-kit-row .activity-kit-total b {
  font-size: 14px;
}

.activity-kit-source-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 4px;
  color: var(--accent);
  font-size: 11px;
  text-decoration: none;
}

.activity-kit-delivery-fields {
  display: grid;
  grid-column: 1 / -1;
  gap: 6px;
  align-self: center;
  min-width: 0;
}

.activity-kit-delivery-toggle {
  min-height: 30px;
}

.activity-kit-delivery-fields textarea {
  min-height: 72px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 12px;
}

.activity-kit-attached-card {
  background: #fbfdfd;
}

.activity-kit-attached-card.is-source-unavailable {
  background: #fff8ef;
  border-color: #e8c08b;
}

.activity-kit-source-card .activity-kit-summary-amount {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  justify-self: end;
  min-height: 26px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
}

.activity-kit-attached-card .pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  justify-self: end;
  width: auto;
  min-width: 0;
  height: 24px;
  min-height: 24px;
  padding: 0 12px;
  border-radius: 999px;
  line-height: 1;
  white-space: nowrap;
}

.activity-kit-source-availability {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--warning);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.25;
}

.activity-kit-source-availability .icon {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
}

.activity-kit-source-row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.activity-kit-source-details {
  display: grid;
  gap: 8px;
}

.activity-kit-source-details > summary {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  width: fit-content;
  border-radius: 4px;
  cursor: pointer;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.25;
  list-style-position: inside;
}

.activity-kit-source-details > summary:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--accent) 35%, transparent);
  outline-offset: 2px;
}

.activity-kit-source-details[open] {
  padding-top: 2px;
}

.activity-kit-billing-summary {
  display: grid;
  gap: 8px;
  margin-top: 10px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.activity-kit-billing-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.activity-kit-billing-head h4 {
  margin: 0;
  font-size: 13px;
}

.external-preset-top {
  display: grid;
  grid-template-columns: auto minmax(180px, 1fr) minmax(160px, 220px) minmax(90px, 120px) auto;
  gap: 10px;
  align-items: center;
}

.external-preset-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.external-preset-notes {
  grid-column: span 2;
}

.list {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.activity-summary,
.task-row,
.message-row,
.proposal-card,
.proposal-activity-line,
.quote-row {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  padding: 10px;
}

.activity-mini-list,
.proposal-list {
  display: grid;
  gap: 8px;
}

.proposal-activity-line {
  display: grid;
  gap: 3px;
}

.proposal-activity-line span,
.proposal-card-head span {
  color: var(--muted);
  font-size: 12px;
}

.proposal-card {
  display: grid;
  gap: 10px;
}

.change-requests-dialog {
  max-width: min(820px, calc(100vw - 40px));
}

.change-request-form .section-title {
  align-items: flex-start;
}

.change-request-tabs {
  margin-bottom: 0;
}

.change-request-tabs button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.change-request-tabs .toolbar-badge {
  position: static;
  min-width: 19px;
  height: 19px;
  border: 0;
  background: var(--accent);
  color: #fff;
  font-size: 10px;
}

.change-request-tabs button.active .toolbar-badge {
  background: #fff;
  color: var(--ink);
}

.change-request-section {
  min-height: 260px;
}

.change-request-recipient {
  color: var(--muted);
  font-size: 13px;
}

.change-request-recipient b {
  color: var(--ink);
}

.change-request-collaboration-section {
  display: grid;
  gap: 14px;
}

.compact-empty-state {
  min-height: 150px;
  align-content: center;
  justify-items: center;
  text-align: center;
}

.change-request-list {
  max-height: 46vh;
  overflow: auto;
  padding-right: 4px;
}

.change-request-card p {
  margin: 0;
  overflow-wrap: anywhere;
}

.change-request-card .compact-field {
  margin: 0;
}

.collaboration-dialog {
  max-width: min(1180px, calc(100vw - 40px));
}

.collaboration-create-grid {
  display: grid;
  grid-template-columns: minmax(150px, 1.1fr) minmax(180px, 1.2fr) minmax(160px, 1fr) minmax(160px, 1fr) auto;
  gap: 8px;
  align-items: end;
}

.collaboration-workspace-list,
.collaboration-activity-list,
.collaboration-patches {
  display: grid;
  gap: 8px;
}

.collaboration-workspace-card,
.collaboration-activity-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  color: var(--ink);
  padding: 9px 10px;
  text-align: left;
}

.collaboration-workspace-card.selected,
.collaboration-activity-card.selected {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(91, 68, 194, 0.16);
}

.collaboration-workspace-card span,
.collaboration-activity-card {
  min-width: 0;
}

.collaboration-workspace-card b,
.collaboration-workspace-card small,
.collaboration-workspace-card em,
.collaboration-activity-card b,
.collaboration-activity-card span {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collaboration-workspace-card small,
.collaboration-workspace-card em,
.collaboration-activity-card span {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.collaboration-detail-grid {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(360px, 1.1fr);
  gap: 12px;
  align-items: start;
}

.collaboration-snapshot,
.collaboration-patch-form {
  min-width: 0;
}

.collaboration-activity-list {
  max-height: 360px;
  overflow: auto;
  padding: 2px 4px 2px 2px;
}

.collaboration-patch-fields {
  display: grid;
  gap: 8px;
}

.collaboration-patch-card p {
  margin: 0;
  overflow-wrap: anywhere;
}

.collaboration-counter-proposal {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
  background: #f7f9fb;
}

.collaboration-counter-proposal > div:first-child {
  display: grid;
  gap: 2px;
}

.collaboration-counter-proposal > div:first-child span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.collaboration-counter-proposal label {
  display: grid;
  gap: 4px;
  min-width: 0;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.collaboration-counter-proposal input,
.collaboration-counter-proposal select {
  min-width: 0;
  height: 34px;
  padding: 5px 8px;
  font-size: 13px;
}

.collaboration-counter-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.collaboration-counter-check {
  align-self: end;
  min-height: 34px;
  padding: 0;
  color: var(--ink) !important;
  font-size: 12px !important;
}

.collaboration-counter-check input {
  width: 14px;
  height: 14px;
  padding: 0;
}

.compact-section-title {
  padding: 0 0 6px;
}

.inline-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  color: var(--ink);
  font-weight: 700;
}

.proposal-card-head,
.proposal-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.proposal-actions {
  justify-content: flex-end;
}

@media (max-width: 900px) {
  .collaboration-create-grid,
  .collaboration-detail-grid {
    grid-template-columns: 1fr;
  }
}

.agenda-list {
  display: flex;
  flex-direction: column;
  align-content: start;
  justify-content: flex-start;
  gap: 10px;
  min-height: 0;
  overflow: auto;
  padding-right: 4px;
}

.agenda-day {
  border-top: 1px solid var(--line-strong);
}

.agenda-day header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 34px;
  color: #53616e;
  font-weight: 750;
}

.agenda-day header b {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 22px;
  border-radius: 999px;
  background: #485465;
  color: #fff;
  font-size: 12px;
}

.agenda-item {
  position: relative;
  display: grid;
  gap: 2px;
  width: 100%;
  padding: 12px 12px 12px 16px;
  border-bottom: 1px solid var(--line);
  background: transparent;
  text-align: left;
}

.agenda-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 5px;
  background: var(--item-color);
}

.agenda-item:hover {
  background: #e9edf2;
}

.agenda-item span,
.agenda-item small {
  color: #657381;
  font-size: 12px;
}

.agenda-item b {
  font-size: 15px;
  color: #111827;
}

.agenda-item em {
  color: #1f2937;
  font-style: normal;
  font-size: 13px;
}

.activity-summary {
  display: grid;
  grid-template-columns: 5px 1fr;
  gap: 10px;
}

.activity-summary > i {
  border-radius: 999px;
}

.activity-summary b,
.task-row b,
.quote-row b {
  display: block;
  font-size: 13px;
}

.activity-summary span,
.quote-row span {
  color: var(--muted);
  display: block;
  font-size: 12px;
  margin-top: 2px;
}

.activity-warning {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  border: 1px solid rgba(161, 92, 0, 0.28);
  border-radius: 6px;
  background: #fff7ed;
  color: var(--warning);
  padding: 9px 10px;
  font-size: 12px;
  line-height: 1.35;
}

.activity-warning .icon {
  width: 18px;
  height: 18px;
}

.activity-warning > div {
  display: grid;
  gap: 8px;
}

.task-lock-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.button.compact {
  min-height: 30px;
  padding: 0 10px;
  font-size: 12px;
}

.button.compact .icon {
  width: 14px;
  height: 14px;
}

.task-control-overlay {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  z-index: 120;
  pointer-events: none;
}

.task-control-card {
  width: min(420px, calc(100vw - 32px));
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
  pointer-events: auto;
}

.task-control-card h3,
.task-control-card p {
  margin: 0;
}

.task-control-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.room-conflict-overlay {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  z-index: 130;
  padding: 20px;
  background: rgba(12, 18, 22, 0.42);
}

.room-conflict-card {
  width: min(560px, calc(100vw - 32px));
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.room-conflict-card h3,
.room-conflict-card p {
  margin: 0;
}

.room-conflict-preview {
  display: grid;
  gap: 8px;
  max-height: 260px;
  overflow: auto;
}

.room-conflict-row {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: #f8fafb;
}

.room-conflict-row strong,
.room-conflict-row small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.room-conflict-row small {
  color: var(--muted);
  font-weight: 700;
}

.room-conflict-chip {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  background: var(--bar-color, #657381);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .12);
}

.room-conflict-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.activity-project-status-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
  align-items: end;
}

.activity-internal-field {
  min-height: 38px;
  margin: 0;
  align-self: end;
}

.child-activity-field {
  display: grid;
  gap: 6px;
}

.child-activity-field > span:first-child {
  font-size: 12px;
  font-weight: 750;
  color: #39464d;
  text-align: center;
}

.child-activity-toggle {
  min-height: 38px;
  width: 44px;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.child-activity-toggle input {
  width: 24px;
  height: 24px;
  min-height: 0;
  margin: 0;
  padding: 0;
}

.child-inherited-note {
  display: block;
  margin-top: -2px;
}

.billing-lock-row {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.units-from-tasks-row,
.actuals-from-booked-row,
.deduct-lunch-row {
  margin-top: -4px;
  color: var(--muted);
  font-size: 13px;
}

.login-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px;
  background: var(--bg);
}

.login-shell {
  width: min(760px, 100%);
  min-height: min(460px, calc(100vh - 64px));
  display: grid;
  grid-template-columns: 238px minmax(0, 1fr);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.login-rail {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
  background: var(--nav);
  color: var(--nav-ink);
}

.login-brand {
  display: grid;
  justify-items: center;
  gap: 14px;
  max-width: 100%;
  transform: translateY(-42px);
}

.login-rail-logo {
  width: 168px;
  max-width: 100%;
  height: auto;
}

.brand-tagline {
  margin: 0;
  font-size: 13px;
  font-weight: 450;
  line-height: 1.4;
  letter-spacing: 0;
  text-align: center;
  color: inherit;
}

.login-rail-footer {
  display: grid;
  gap: 4px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: #98a4b5;
  font-size: 13px;
}

.login-rail-footer b {
  color: var(--nav-ink);
  font-size: 14px;
}

.login-workspace {
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(90deg, rgba(8, 17, 29, 0.035) 1px, transparent 1px),
    linear-gradient(0deg, rgba(8, 17, 29, 0.035) 1px, transparent 1px),
    #f5f7f8;
  background-size: 38px 38px;
}

.login-card {
  width: min(350px, 100%);
  display: grid;
  gap: 14px;
  padding: 18px;
  background: var(--panel);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 12px 34px rgba(28, 40, 46, 0.1);
}

.login-card-head {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}

.login-card-logo {
  width: 42px;
  height: 42px;
  object-fit: contain;
}

.login-card h1 {
  margin: 0;
  color: var(--ink);
  font-size: 22px;
  letter-spacing: 0;
}

.login-card p {
  margin: 2px 0 0;
  color: var(--muted);
  font-weight: 650;
}

.login-card label {
  color: var(--ink);
}

.login-card select {
  background: #ffffff;
}

.login-card .button {
  min-height: 40px;
}

.login-link-row,
.signup-login,
.signup-terms {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.login-link-row a,
.signup-login a,
.signup-terms a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 850;
}

.signup-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px;
  background: var(--bg);
  color: var(--ink);
}

.signup-shell {
  width: min(960px, 100%);
  min-height: min(520px, calc(100vh - 64px));
  display: grid;
  grid-template-columns: minmax(360px, 1fr) minmax(0, 1fr);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.signup-form-pane {
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 18px;
  padding: 24px;
  background:
    linear-gradient(90deg, rgba(8, 17, 29, 0.035) 1px, transparent 1px),
    linear-gradient(0deg, rgba(8, 17, 29, 0.035) 1px, transparent 1px),
    #f5f7f8;
  background-size: 38px 38px;
}

.signup-brand {
  width: min(226px, 100%);
  display: grid;
  justify-items: center;
  gap: 14px;
  color: var(--ink);
  text-decoration: none;
}

.signup-brand img {
  width: 158px;
  max-width: 100%;
  height: auto;
}

.signup-card {
  width: min(350px, 100%);
  display: grid;
  gap: 14px;
  padding: 18px;
  background: var(--panel);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 12px 34px rgba(28, 40, 46, 0.1);
}

.signup-heading {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}

.signup-card-logo {
  width: 42px;
  height: 42px;
  object-fit: contain;
}

.signup-heading h1 {
  margin: 0;
  color: var(--ink);
  font-size: 22px;
  line-height: 1.05;
  letter-spacing: 0;
}

.signup-heading p {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 650;
  line-height: 1.25;
}

.signup-card .two {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.signup-card .field {
  display: grid;
  gap: 6px;
}

.signup-card .field span {
  color: var(--ink);
  font-size: 13px;
  font-weight: 850;
}

.signup-card input {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  padding: 0 12px;
  background: #ffffff;
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
  box-shadow: 0 2px 7px rgba(15, 23, 42, 0.05);
}

.signup-card input::placeholder {
  color: #c4c9d3;
}

.password-field {
  position: relative;
}

.password-field input {
  padding-right: 48px;
}

.password-toggle {
  width: 36px;
  height: 36px;
  position: absolute;
  right: 4px;
  bottom: 3px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #858b95;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.signup-submit {
  min-height: 42px;
  border-radius: 8px;
  font-size: 15px;
}

.signup-login {
  color: #47536a;
  font-size: 14px;
}

.signup-feature-pane {
  display: grid;
  align-content: center;
  gap: 28px;
  padding: 30px;
  background:
    linear-gradient(135deg, rgba(91, 70, 191, 0.2), transparent 42%),
    linear-gradient(0deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0)),
    var(--nav);
  color: var(--nav-ink);
}

.signup-feature-head {
  display: grid;
  justify-items: start;
  text-align: left;
}

.signup-feature-head .eyebrow {
  margin: 0 0 6px;
  color: #70d7d1;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 900;
}

.signup-feature-head h2 {
  margin: 0;
  max-width: 420px;
  color: #ffffff;
  font-size: 30px;
  line-height: 1.12;
  letter-spacing: 0;
}

.signup-feature-list {
  position: relative;
  min-height: 148px;
}

.signup-feature-card {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  position: absolute;
  inset: 0;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.06);
  opacity: 0;
  transform: translateY(10px) scale(0.985);
  animation: signup-feature-cycle 25s ease-in-out infinite;
  animation-delay: calc(var(--feature-index, 0) * 5s);
  pointer-events: none;
}

.signup-feature-card > span {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  color: #08111d;
  background: #78d8d0;
}

.signup-feature-card .icon {
  width: 20px;
  height: 20px;
}

.signup-feature-card h3 {
  margin: 0 0 3px;
  color: #ffffff;
  font-size: 18px;
  line-height: 1.15;
  letter-spacing: 0;
}

.signup-feature-card p {
  margin: 0;
  color: #afbac8;
  font-size: 14px;
  line-height: 1.35;
  font-weight: 650;
}

@keyframes signup-feature-cycle {
  0%,
  18% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }

  22%,
  100% {
    opacity: 0;
    transform: translateY(-8px) scale(0.985);
  }
}

@media (prefers-reduced-motion: reduce) {
  .signup-feature-card {
    animation: none;
  }

  .signup-feature-card:first-child {
    opacity: 1;
    transform: none;
  }
}

.session-loading-card {
  width: min(360px, 100%);
  display: grid;
  justify-items: center;
  gap: 14px;
  padding: 24px;
  color: var(--muted);
}

.session-loading-wordmark {
  width: 226px;
  max-width: 100%;
  height: auto;
}

.session-loading-status {
  width: 226px;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 750;
  line-height: 1.2;
  text-align: center;
  white-space: nowrap;
}

.session-loading-copy {
  position: relative;
}

.session-loading-dots {
  position: absolute;
  top: 0;
  left: 100%;
  display: flex;
  width: 1.45em;
  justify-content: flex-start;
}

.session-loading-dots i {
  font: inherit;
  opacity: 0.2;
  animation: session-loading-dot 1.2s ease-in-out infinite;
}

.session-loading-dots i:nth-child(2) {
  animation-delay: 0.16s;
}

.session-loading-dots i:nth-child(3) {
  animation-delay: 0.32s;
}

@keyframes session-loading-dot {
  0%,
  55%,
  100% {
    opacity: 0.2;
  }

  25% {
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .session-loading-dots i {
    opacity: 1;
    animation: none;
  }
}

.client-review-screen {
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr;
  background:
    radial-gradient(circle at 50% 18%, rgba(97, 73, 203, 0.18), transparent 30%),
    var(--nav);
  color: var(--nav-ink);
}

.client-review-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 22px 28px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.client-review-topbar img {
  width: 176px;
  height: auto;
}

.client-review-card {
  align-self: center;
  justify-self: center;
  width: min(560px, calc(100vw - 40px));
  display: grid;
  gap: 18px;
  padding: 30px;
  background: #ffffff;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.28);
}

.client-review-mark {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f6f8fa;
}

.client-review-mark img {
  width: 42px;
  height: 42px;
}

.client-review-card h1 {
  margin: -6px 0 0;
  font-size: 34px;
  letter-spacing: 0;
}

.client-review-card p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.45;
}

.client-review-link {
  justify-self: start;
  min-height: 44px;
}

.client-review-projects {
  display: grid;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.client-review-projects h2 {
  margin: 0;
  font-size: 16px;
  letter-spacing: 0;
}

.client-review-project-list {
  display: grid;
  gap: 8px;
}

.client-review-project {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafb;
}

.client-review-project small {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-weight: 700;
}

.form-grid {
  display: grid;
  gap: 12px;
}

.user-password-help {
  display: block;
  margin-top: 4px;
  color: var(--danger);
  font-size: 12px;
}

.form-error {
  padding: 9px 10px;
  border: 1px solid #d36b5c;
  border-radius: var(--radius);
  background: #fff2ef;
  color: #8b2f24;
  font-size: 13px;
  font-weight: 750;
}

.field {
  display: grid;
  gap: 6px;
}

.field-note {
  align-content: end;
  min-height: 74px;
}

.field label {
  font-size: 12px;
  font-weight: 750;
  color: #39464d;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  min-height: 38px;
  padding: 8px 10px;
  background: #fff;
  color: var(--ink);
}

.activity-date-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
  gap: 10px;
  align-items: end;
}

.include-weekends-control {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 10px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: #fff;
  white-space: nowrap;
  align-self: end;
}

.include-weekends-control input {
  width: 15px;
  min-height: 15px;
  margin: 0;
  padding: 0;
}

.include-weekends-control span {
  font-size: 12px;
  font-weight: 800;
  color: var(--ink);
}

.split-activity-section {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.split-activity-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.split-activity-heading b {
  display: block;
  font-size: 13px;
}

.split-activity-heading small {
  display: block;
  margin-top: 2px;
  color: #657381;
  font-size: 11px;
  line-height: 1.25;
}

.split-segment-list {
  display: grid;
  gap: 8px;
  max-height: 204px;
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 4px;
}

.split-segment-row {
  display: grid;
  grid-template-columns: 48px 96px 96px 82px 82px 30px;
  grid-template-areas: "index start end start-time end-time remove";
  gap: 6px;
  align-items: end;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfc;
  min-width: 0;
}

.split-segment-row.has-weekends-option {
  grid-template-columns: 44px 90px 90px 78px 78px 84px 30px;
  grid-template-areas: "index start end start-time end-time weekends remove";
  gap: 5px;
}

.schedule-hiatus-row {
  grid-template-columns: 48px 120px 120px 30px;
  grid-template-areas: "index start end remove";
  max-width: 352px;
}

.split-segment-index {
  grid-area: index;
  align-self: center;
  color: #657381;
  font-size: 10px;
  font-weight: 800;
  white-space: nowrap;
}

.split-segment-start {
  grid-area: start;
}

.split-segment-end {
  grid-area: end;
}

.split-segment-start-time {
  grid-area: start-time;
}

.split-segment-end-time {
  grid-area: end-time;
}

.split-segment-remove {
  grid-area: remove;
  align-self: end;
  width: 30px;
  height: 24px;
  min-height: 24px;
  max-height: 24px;
  min-width: 30px;
  flex: 0 0 30px;
  border-radius: 7px;
}

.split-segment-remove .icon {
  width: 12px;
  height: 12px;
}

.split-segment-row .field {
  min-width: 0;
}

.split-segment-row .field label {
  font-size: 9px;
  white-space: nowrap;
}

.split-segment-row input {
  width: 100%;
  min-width: 0;
  min-height: 32px;
  padding: 5px;
  font-size: 11px;
}

.split-segment-row input[type="date"] {
  padding-right: 3px;
}

.split-segment-row input[type="time"] {
  font-size: 12px;
  letter-spacing: 0;
}

.split-include-weekends {
  grid-area: weekends;
  justify-content: center;
  align-self: end;
  height: 24px;
  min-height: 24px;
  max-height: 24px;
  padding: 0 5px;
  gap: 3px;
  border-radius: 7px;
}

.split-include-weekends input {
  width: 11px;
  height: 11px;
  min-height: 11px;
  max-height: 11px;
  padding: 0;
  flex: 0 0 11px;
}

.split-include-weekends span {
  font-size: 9px;
  line-height: 1;
}

.inline-select-action {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px;
  gap: 8px;
  align-items: center;
}

.inline-select-action .icon-button {
  width: 42px;
  height: 42px;
}

.project-color-field input[type="color"] {
  width: 54px;
  height: 38px;
  min-height: 38px;
  padding: 3px;
  border-radius: 10px;
  cursor: pointer;
  justify-self: start;
}

.project-color-field input[type="color"]::-webkit-color-swatch-wrapper {
  padding: 0;
}

.project-color-field input[type="color"]::-webkit-color-swatch {
  border: 0;
  border-radius: 7px;
}

.project-color-field input[type="color"]::-moz-color-swatch {
  border: 0;
  border-radius: 7px;
}

.theme-color-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

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

.theme-asset-row .button {
  white-space: nowrap;
}

.theme-color-field input[type="color"] {
  width: 100%;
  height: 38px;
  min-height: 38px;
  padding: 3px;
  cursor: pointer;
}

.theme-color-field input[type="color"]::-webkit-color-swatch-wrapper {
  padding: 0;
}

.theme-color-field input[type="color"]::-webkit-color-swatch {
  border: 0;
  border-radius: 6px;
}

.theme-color-field input[type="color"]::-moz-color-swatch {
  border: 0;
  border-radius: 6px;
}

.quick-client-menu {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px;
  background: #f8fbfd;
  display: grid;
  gap: 8px;
  box-shadow: var(--shadow-soft);
}

.quick-client-menu[hidden] {
  display: none;
}

.quick-client-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.check-row {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 38px;
  font-size: 14px;
  font-weight: 750;
  color: #172126;
}

.check-row input {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
}

.check-row.is-disabled {
  color: #9aa7ad;
  cursor: not-allowed;
}

.check-row input:disabled {
  cursor: not-allowed;
}

.multi-select-dropdown {
  position: relative;
  width: 100%;
}

.multi-select-dropdown.disabled {
  pointer-events: none;
  opacity: 0.75;
}

.multi-select-dropdown summary {
  min-height: 38px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
}

.multi-select-dropdown summary::-webkit-details-marker {
  display: none;
}

.multi-select-dropdown summary::after {
  content: "";
  margin-left: auto;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid #657381;
}

.multi-select-dropdown[open] summary::after {
  transform: rotate(180deg);
}

.multi-select-dropdown summary span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.multi-select-dropdown summary b {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
  color: #657381;
}

.multi-select-menu {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 80;
  max-height: 220px;
  overflow: auto;
  padding: 6px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
}

.multi-select-menu label {
  display: grid;
  grid-template-columns: 18px auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  padding: 5px 6px;
  border-radius: 6px;
  font-size: 13px;
  color: #172126;
}

.multi-select-menu label:hover {
  background: #f0f4f7;
}

.multi-select-menu input {
  width: 15px;
  height: 15px;
  accent-color: var(--accent);
}

.multi-select-menu i {
  width: 10px;
  height: 10px;
  border-radius: 999px;
}

.multi-select-menu small {
  color: #657381;
  font-weight: 750;
}

.field textarea {
  min-height: 88px;
  resize: vertical;
}

.overlay {
  position: fixed;
  inset: 0;
  background: rgba(12, 18, 22, 0.42);
  display: grid;
  place-items: center;
  padding: 20px;
  z-index: 120;
}

.dialog {
  width: min(980px, 100%);
  max-width: calc(100vw - 40px);
  max-height: min(880px, calc(100vh - 40px));
  overflow: auto;
  background: var(--panel);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
}

.movable-dialog {
  position: fixed;
}

.movable-dialog:not([style]) {
  position: relative;
}

[data-dialog-drag-handle] {
  cursor: move;
}

.finder-dialog {
  width: min(1180px, calc(100vw - 40px));
}

.project-settings-dialog {
  width: min(1180px, calc(100vw - 40px));
  container-type: inline-size;
}

.users-dialog {
  width: min(1180px, calc(100vw - 40px));
}

.user-availability-table th,
.user-availability-table td {
  vertical-align: middle;
}

.user-availability-table input,
.user-availability-table select {
  min-height: 36px;
  font-size: 13px;
}

.user-availability-table .user-availability-all-day input[type="checkbox"] {
  width: 16px;
  height: 16px;
  min-height: 0;
  padding: 0;
}

.availability-time-cell {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 6px;
  min-width: 190px;
}

.availability-time-cell span {
  color: var(--muted);
  font-size: 12px;
}

.project-settings-dialog .dialog-body {
  padding: 14px;
}

.project-save-fields {
  border: 0;
  margin: 0;
  min-width: 0;
}

.project-settings-dialog .panel-block { min-width: 0; }
.project-quote-table-scroll { max-width: 100%; overflow-x: auto; }
.project-quote-table-scroll table { min-width: 700px; }

@container (max-width: 600px) {
  .project-settings-dialog .section-title,
  .project-settings-dialog .vfx-bid-panel { flex-direction: column; align-items: stretch; }
  .project-settings-dialog .rate-card-import { min-width: 0; max-width: 100%; }
}

.notification-test-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 6px;
}

.project-settings-dialog .button {
  min-height: 34px;
  padding: 0 10px;
  font-size: 13px;
}

.project-settings-dialog .field input,
.project-settings-dialog .field select,
.project-settings-dialog .field textarea {
  min-height: 36px;
  padding: 7px 10px;
}

.project-settings-dialog table input,
.project-settings-dialog table select {
  min-height: 30px;
  padding: 5px 7px;
  font-size: 13px;
}

.project-settings-dialog .section-title {
  align-items: flex-start;
  gap: 14px;
}

.project-settings-dialog .section-title p {
  margin: 3px 0 0;
}

.project-settings-dialog .rate-card-import {
  gap: 8px;
  flex-wrap: wrap;
}

.tracker-import-preview {
  display: grid;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  background: #fff;
}

.tracker-column-mapping {
  border-top: 1px solid var(--line);
  padding-top: 9px;
}

.tracker-column-mapping summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  list-style-position: inside;
}

.tracker-column-mapping summary small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.tracker-column-mapping-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(110px, 1fr));
  gap: 8px;
  padding-top: 10px;
}

.tracker-column-mapping-grid input,
.tracker-sheet-publish-row > input {
  text-transform: uppercase;
}

.tracker-sheet-config-section {
  display: grid;
  gap: 8px;
  padding-top: 12px;
}

.project-thumbnail-extractor-panel {
  display: grid;
  gap: 10px;
}

.thumbnail-extractor-connection[hidden],
.thumbnail-extractor-connection-list[hidden] {
  display: none;
}

.thumbnail-extractor-connection-actions,
.thumbnail-extractor-connection-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.thumbnail-extractor-connection-actions > small {
  max-width: 760px;
}

.thumbnail-extractor-connection-list {
  display: grid;
  gap: 6px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

.thumbnail-extractor-connection-row {
  min-height: 38px;
}

.thumbnail-extractor-connection-row > div {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.thumbnail-extractor-connection-row small,
.thumbnail-extractor-empty {
  color: var(--muted);
  font-size: 11px;
}

.thumbnail-extractor-connection-row.is-inactive {
  opacity: 0.62;
}

.tracker-sheet-config-section + .tracker-sheet-config-section {
  margin-top: 12px;
  border-top: 1px solid var(--line);
}

.tracker-sheet-publish-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.tracker-sheet-publish-heading {
  display: flex;
  align-items: center;
  gap: 8px;
}

.tracker-sheet-publish-copy {
  display: grid;
  gap: 2px;
}

.tracker-sheet-help-button {
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--panel);
  color: var(--muted);
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: help;
}

.tracker-sheet-help-button:hover,
.tracker-sheet-help-button:focus-visible {
  color: var(--ink);
  border-color: var(--ink);
}

.tracker-sheet-publish-head small {
  color: var(--muted);
  font-size: 11px;
}

.tracker-sheet-publish-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px 10px;
}

.tracker-sheet-publish-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 58px;
  align-items: center;
  gap: 6px;
}

.tracker-sheet-publish-row .check-row {
  min-width: 0;
  font-size: 12px;
}

.tracker-sheet-publish-row > input {
  min-width: 0;
  height: 32px;
  padding: 5px 7px;
  text-align: center;
}

.tracker-sheet-history {
  display: grid;
  gap: 8px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.tracker-sheet-history-head,
.tracker-sheet-history-run-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.tracker-sheet-history-head > div,
.tracker-sheet-history-run-head > div {
  display: grid;
  gap: 2px;
}

.tracker-sheet-history-head small,
.tracker-sheet-history-run-head small {
  color: var(--muted);
  font-size: 11px;
}

.tracker-sheet-history-empty {
  min-height: 34px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  background: var(--panel-2);
  font-size: 12px;
}

.tracker-sheet-history-list {
  display: grid;
  gap: 6px;
}

.tracker-sheet-history-run {
  display: grid;
  gap: 5px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  background: var(--panel-2);
}

.tracker-sheet-history-run p {
  margin: 0;
  font-size: 12px;
}

.tracker-sheet-run-status {
  flex: none;
  padding: 3px 6px;
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  background: var(--panel);
  color: var(--ink);
  font-size: 10px;
  font-weight: 800;
}

.tracker-sheet-run-status.succeeded {
  border-color: #8cbd98;
  background: #e4f3e7;
  color: #245c31;
}

.tracker-sheet-run-status.resolved {
  border-color: #8cbd98;
  background: #edf6ef;
  color: #245c31;
}

.tracker-sheet-run-status.needs_attention {
  border-color: #d5b66c;
  background: #fff3c9;
  color: #6b4d08;
}

.tracker-sheet-run-status.failed {
  border-color: #d69b9b;
  background: #fbe7e7;
  color: #7a2222;
}

.tracker-sheet-run-issues summary {
  cursor: pointer;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
}

.tracker-sheet-run-issue-list {
  display: grid;
  gap: 5px;
  padding-top: 7px;
}

.tracker-sheet-run-issue {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  padding-left: 8px;
  border-left: 2px solid #d5b66c;
  font-size: 11px;
}

.tracker-sheet-run-issue-copy {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.tracker-sheet-run-issue-copy span {
  color: var(--muted);
}

.tracker-sheet-run-issue-actions,
.tracker-sheet-run-footer-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 5px;
}

.tracker-sheet-run-issue-actions .compact-button,
.tracker-sheet-run-footer-actions .compact-button {
  min-height: 28px;
  padding: 4px 7px;
  font-size: 10px;
}

.tracker-sheet-attention-dialog {
  width: min(980px, calc(100vw - 40px));
  max-height: min(780px, calc(100vh - 40px));
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.tracker-sheet-attention-dialog .dialog-header h2,
.tracker-sheet-attention-dialog .dialog-header p {
  margin: 0;
}

.tracker-sheet-attention-dialog .dialog-header p {
  margin-top: 2px;
  font-size: 12px;
}

.tracker-sheet-attention-body {
  min-height: 0;
  max-height: calc(100vh - 170px);
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #eef2f5;
}

.tracker-sheet-attention-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
  background: var(--panel);
}

.tracker-sheet-attention-summary > div {
  min-height: 58px;
  padding: 9px 14px;
  border-right: 1px solid var(--line);
  display: grid;
  align-content: center;
  gap: 1px;
}

.tracker-sheet-attention-summary > div:last-child {
  border-right: 0;
}

.tracker-sheet-attention-summary strong {
  font-size: 19px;
}

.tracker-sheet-attention-summary span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.tracker-sheet-attention-error {
  margin: 10px 12px 0;
}

.tracker-sheet-attention-list {
  flex: 0 1 auto;
  min-height: 0;
  max-height: 590px;
  padding: 10px 12px 16px;
  overflow: auto;
}

.tracker-sheet-attention-project {
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  overflow: hidden;
  background: var(--panel);
}

.tracker-sheet-attention-project + .tracker-sheet-attention-project {
  margin-top: 10px;
}

.tracker-sheet-attention-project > header,
.tracker-sheet-attention-run-head {
  min-height: 38px;
  padding: 7px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.tracker-sheet-attention-project > header {
  border-bottom: 1px solid var(--line-strong);
  background: #f7f9fb;
}

.tracker-sheet-attention-project h3 {
  margin: 0;
  font-size: 13px;
}

.tracker-sheet-attention-project > header > span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.tracker-sheet-attention-run + .tracker-sheet-attention-run {
  border-top: 1px solid var(--line-strong);
}

.tracker-sheet-attention-run-head {
  background: var(--panel-2);
}

.tracker-sheet-attention-run-head > div:first-child {
  min-width: 0;
  display: grid;
  gap: 1px;
}

.tracker-sheet-attention-run-head b {
  font-size: 11px;
}

.tracker-sheet-attention-run-head small {
  color: var(--muted);
  font-size: 10px;
}

.tracker-sheet-attention-run-actions,
.tracker-sheet-attention-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 5px;
  flex-wrap: wrap;
}

.tracker-sheet-attention-run-actions .compact-button,
.tracker-sheet-attention-actions .compact-button {
  min-height: 27px;
  padding: 3px 7px;
  font-size: 10px;
}

.tracker-sheet-attention-item {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  min-height: 56px;
  padding: 8px 10px;
  border-top: 1px solid var(--line);
}

.tracker-sheet-attention-kind {
  width: fit-content;
  padding: 3px 5px;
  border: 1px solid #d5b66c;
  border-radius: 3px;
  background: #fff3c9;
  color: #6b4d08;
  font-size: 9px;
  font-weight: 850;
  text-transform: uppercase;
}

.tracker-sheet-attention-item.retryable .tracker-sheet-attention-kind {
  border-color: #d69b9b;
  background: #fbe7e7;
  color: #7a2222;
}

.tracker-sheet-attention-copy {
  min-width: 0;
  display: grid;
  gap: 1px;
}

.tracker-sheet-attention-copy b {
  font-size: 11px;
}

.tracker-sheet-attention-copy span,
.tracker-sheet-attention-copy small {
  color: var(--muted);
  font-size: 10px;
  overflow-wrap: anywhere;
}

.tracker-sheet-attention-empty {
  min-height: 180px;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 4px;
  text-align: center;
}

.tracker-sheet-attention-empty.success b {
  color: #245c31;
}

.tracker-sheet-attention-footer {
  justify-content: space-between;
}

@media (max-width: 720px) {
  .tracker-sheet-attention-dialog {
    width: calc(100vw - 20px);
    max-height: calc(100vh - 20px);
  }

  .tracker-sheet-attention-item {
    grid-template-columns: 1fr;
  }

  .tracker-sheet-attention-actions,
  .tracker-sheet-attention-run-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 720px) {
  .tracker-sheet-run-issue {
    grid-template-columns: 1fr;
  }

  .tracker-sheet-run-issue-actions,
  .tracker-sheet-run-footer-actions {
    justify-content: flex-start;
  }
}

.tracker-import-preview-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.tracker-import-team-review {
  display: grid;
  grid-template-columns: minmax(230px, 1fr) minmax(190px, 0.75fr) minmax(190px, 0.75fr);
  gap: 8px;
  align-items: end;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #f8fafb;
}

.tracker-import-team-review > div,
.tracker-import-team-review label,
.tracker-import-team-existing {
  display: grid;
  gap: 2px;
}

.tracker-import-team-review > div span,
.tracker-import-team-review label > span,
.tracker-import-team-existing small {
  color: var(--muted);
  font-size: 11px;
}

.tracker-import-team-review select {
  min-height: 30px;
  padding: 3px 28px 3px 7px;
  font-size: 12px;
}

.tracker-import-note-seed {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(300px, auto);
  align-items: center;
  gap: 5px 14px;
  padding: 8px;
  border: 1px solid #b8addf;
  border-radius: 5px;
  background: #f6f3fd;
}

.tracker-import-note-seed > div {
  display: grid;
  gap: 2px;
}

.tracker-import-note-seed span,
.tracker-import-note-seed small {
  color: var(--muted);
  font-size: 11px;
}

.tracker-import-note-seed > small {
  grid-column: 1 / -1;
}

.tracker-import-preview-head > div:first-child {
  display: grid;
  gap: 2px;
}

.tracker-import-preview-head > div:first-child span,
.tracker-import-result span {
  color: var(--muted);
  font-size: 12px;
}

.tracker-import-counts {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 5px;
}

.tracker-import-count {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  min-height: 26px;
  padding: 4px 7px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: #43515d;
  background: #f5f7f8;
  font-size: 11px;
  font-family: inherit;
  white-space: nowrap;
  cursor: pointer;
}

.tracker-import-count.is-active {
  box-shadow: inset 0 0 0 1px currentColor;
  font-weight: 800;
}

.tracker-import-count:disabled {
  cursor: default;
  opacity: 0.48;
}

.tracker-import-count.is-create,
.tracker-import-action.is-create {
  border-color: #9fc8ae;
  background: #e7f4eb;
  color: #27633d;
}

.tracker-import-count.is-update,
.tracker-import-action.is-update {
  border-color: #aabbe5;
  background: #edf1fb;
  color: #365188;
}

.tracker-import-count.is-conflict,
.tracker-import-action.is-conflict {
  border-color: #e0a9a2;
  background: #fff0ee;
  color: #8a3028;
}

.tracker-import-count.is-unchanged,
.tracker-import-action.is-unchanged {
  border-color: #bdc7ce;
  background: #f2f4f5;
  color: #50606c;
}

.tracker-import-count.is-skipped,
.tracker-import-action.is-skipped {
  border-color: #d7c999;
  background: #faf6e8;
  color: #6f5c1f;
}

.tracker-import-count.is-missing,
.tracker-import-action.is-missing {
  border-color: #d1ad79;
  background: #fff5e7;
  color: #71491d;
}

.tracker-import-table-wrap {
  max-height: 330px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 6px;
}

.tracker-import-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 12px;
}

.tracker-import-table th,
.tracker-import-table td {
  padding: 7px 8px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.tracker-import-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f4f6f7;
  color: #465560;
  font-size: 11px;
}

.tracker-import-table tr:last-child td {
  border-bottom: 0;
}

.tracker-import-table td:first-child,
.tracker-import-table td:nth-child(3),
.tracker-import-table td:nth-child(4) {
  white-space: nowrap;
}

.tracker-import-table td:nth-child(2) small {
  display: block;
  margin-top: 2px;
  color: var(--muted);
}

.tracker-import-table tr.is-conflict td {
  background: #fffafa;
}

.tracker-import-table tr.is-missing td {
  background: #fffaf2;
}

.tracker-import-table [data-tracker-removal-decision] {
  width: min(190px, 100%);
  min-height: 28px;
  padding: 3px 26px 3px 7px;
  font-size: 11px;
}

.tracker-import-action {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 2px 6px;
  border: 1px solid var(--line);
  border-radius: 4px;
  font-size: 11px;
  font-weight: 800;
}

.tracker-import-preview-limit,
.tracker-import-warning {
  margin: 0;
  font-size: 12px;
}

.tracker-import-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 11px;
}

.tracker-import-pagination > div {
  display: flex;
  align-items: center;
  gap: 7px;
}

.tracker-import-pagination b {
  color: var(--ink);
  white-space: nowrap;
}

.tracker-import-empty {
  height: 90px;
  color: var(--muted);
  text-align: center;
}

.tracker-import-warning {
  color: #8a3028;
  font-weight: 750;
}

.tracker-import-guidance {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 8px;
  align-items: baseline;
  margin: 0;
  padding: 7px 9px;
  border: 1px solid #e0a9a2;
  border-radius: 4px;
  background: #fff7f5;
  color: #65342f;
  font-size: 11px;
}

.tracker-import-guidance span {
  color: #75514d;
}

.tracker-import-result .tracker-import-warning {
  color: #8a3028;
}

.tracker-import-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 7px;
}

.tracker-import-result {
  display: grid;
  gap: 3px;
  padding: 9px 10px;
  border-left: 3px solid #6d56cc;
  background: #f5f3fc;
}

@media (max-width: 760px) {
  .tracker-import-preview-head {
    display: grid;
  }

  .tracker-import-counts {
    justify-content: flex-start;
  }

  .tracker-import-pagination {
    align-items: flex-start;
    flex-direction: column;
  }

  .tracker-import-guidance {
    grid-template-columns: 1fr;
  }

  .tracker-column-mapping-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .tracker-import-team-review,
  .tracker-import-note-seed,
  .tracker-intake-notes-grid {
    grid-template-columns: 1fr;
  }

  .tracker-sheet-publish-grid {
    grid-template-columns: 1fr;
  }
}

.project-milestone-list,
.milestone-type-list {
  display: grid;
  gap: 8px;
}

.milestone-dialog {
  width: min(860px, calc(100vw - 40px));
}

.milestone-dialog .section-title {
  align-items: center;
}

.project-milestone-row {
  display: grid;
  grid-template-columns: 34px minmax(120px, 0.8fr) minmax(150px, 1fr) 136px 96px 118px minmax(140px, 1fr) auto;
  gap: 8px;
  align-items: center;
}

@container (max-width: 1000px) {
  .project-milestone-row {
    grid-template-columns: 34px repeat(2, minmax(0, 1fr));
  }
  .project-milestone-row > * { min-width: 0; max-width: 100%; }
}

@container (max-width: 480px) {
  .project-milestone-row {
    grid-template-columns: minmax(0, 1fr);
    border: 1px solid var(--line);
    padding: 10px;
    border-radius: var(--radius);
  }
}

.milestone-type-row {
  display: grid;
  grid-template-columns: 26px 58px minmax(130px, 1fr) 130px minmax(120px, 0.8fr) 40px;
  gap: 8px;
  align-items: center;
  min-width: 0;
}

.project-milestone-row input,
.project-milestone-row select,
.milestone-type-row input,
.milestone-type-row select {
  min-height: 34px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 6px 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

.milestone-type-preview {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--milestone-color, #657381);
  font-weight: 850;
  white-space: nowrap;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.milestone-type-preview svg {
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
}

.milestone-type-row .icon-button {
  width: 38px;
  min-width: 38px;
}

.finder-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--line);
  margin-bottom: 10px;
}

.finder-tabs button {
  background: #fbfcfc;
  border: 1px solid var(--line);
  border-bottom: 0;
  min-height: 34px;
  padding: 0 14px;
}

.finder-tabs button.active {
  background: var(--panel);
  font-weight: 750;
}

.finder-search {
  grid-template-columns: auto minmax(220px, 1fr);
  align-items: center;
}

.finder-table {
  border: 1px solid var(--line);
}

.finder-select-column {
  width: 34px;
  text-align: center;
}

.finder-select-column input[type="checkbox"] {
  width: 14px;
  height: 14px;
  margin: 0;
}

.finder-sort-button {
  width: 100%;
  min-height: 28px;
  padding: 0;
  background: transparent;
  color: inherit;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  font-weight: 850;
  text-align: left;
}

.finder-sort-button span {
  min-width: 10px;
  color: var(--accent);
}

.finder-table tbody tr:nth-child(even) {
  background: #f8fbfd;
}

.finder-limit-row td {
  color: var(--muted);
  font-weight: 700;
  text-align: center;
}

.bulk-import-card {
  margin-bottom: 0;
  background: #fff;
}

.bulk-standard-import-card {
  max-width: 680px;
}

.bulk-standard-import-card > .two {
  max-width: 520px;
}

.bulk-import-card[hidden] {
  display: none;
}

.bulk-import-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--line);
}

.bulk-import-tabs button {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-bottom: 0;
  background: #fbfcfc;
  color: var(--muted);
  font-weight: 850;
}

.bulk-import-tabs button + button {
  border-left: 0;
}

.bulk-import-tabs button.active {
  background: #fff;
  color: var(--ink);
  box-shadow: inset 0 3px 0 var(--accent);
}

.bulk-child-import-card {
  border-color: color-mix(in srgb, var(--accent) 30%, var(--line) 70%);
}

.bulk-task-import-card {
  max-width: 780px;
}

.bulk-task-import-card .bulk-child-section {
  max-width: 560px;
}

.bulk-task-import-card .bulk-name-tools {
  max-width: 660px;
}

.bulk-import-kicker {
  display: block;
  margin-bottom: 3px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.bulk-child-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.bulk-child-steps span {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 8px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #f8fafb;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  text-align: center;
}

.bulk-child-section {
  display: grid;
  gap: 10px;
  max-width: 560px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfc;
}

.bulk-child-import-card > .two {
  max-width: 420px;
}

.bulk-parent-search-field,
.bulk-task-search-field {
  position: relative;
}

.bulk-parent-selected {
  min-height: 34px;
  display: flex;
  align-items: center;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #f8fafb;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.bulk-parent-results {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 6px);
  z-index: 75;
  display: none;
  gap: 6px;
  max-height: 260px;
  overflow: auto;
  padding: 8px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(28, 40, 46, 0.16);
}

.bulk-parent-results.open {
  display: grid;
}

.bulk-parent-result {
  display: grid;
  gap: 2px;
  width: 100%;
  min-width: 0;
  min-height: 50px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  color: var(--ink);
  text-align: left;
}

.bulk-parent-result:hover,
.bulk-parent-result:focus-visible {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
}

.bulk-parent-result strong {
  display: block;
  min-width: 0;
  max-width: 100%;
  overflow: visible;
  line-height: 1.18;
  overflow-wrap: anywhere;
  white-space: normal;
}

.bulk-parent-result span {
  display: block;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bulk-parent-result span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.bulk-name-tools {
  display: grid;
  gap: 8px;
  max-width: 660px;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafb;
}

.bulk-name-tools > .two {
  gap: 8px;
  align-items: start;
}

.compact-section-title {
  margin-bottom: 0;
}

.compact-section-title h4 {
  margin: 0;
  font-size: 14px;
}

.selection-count {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  margin-left: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 10%, #ffffff 90%);
  color: var(--accent);
  font-size: 11px;
  font-weight: 900;
  vertical-align: middle;
  white-space: nowrap;
}

.bulk-name-tool {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
}

.bulk-name-tool .field {
  gap: 4px;
}

.bulk-name-tool .field label {
  font-size: 11px;
}

.bulk-name-tool .check-row {
  min-height: 28px;
  gap: 7px;
  font-size: 13px;
}

.bulk-name-tool .check-row input {
  width: 14px;
  height: 14px;
}

.bulk-name-tool input {
  min-height: 34px;
  padding: 5px 8px;
}

.tight-fields {
  gap: 6px;
  align-items: end;
}

.compact-check {
  min-height: 28px;
  align-items: center;
}

.bulk-name-preview {
  display: grid;
  gap: 8px;
  grid-column: 1 / -1;
  padding: 10px;
  border: 1px dashed var(--line-strong);
  border-radius: 7px;
  background: #fff;
  position: relative;
}

.bulk-name-preview-result {
  min-height: 34px;
  display: flex;
  align-items: center;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #f8fafb;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.bulk-name-preview-result.has-preview {
  background: color-mix(in srgb, var(--accent) 9%, #ffffff 91%);
  color: var(--ink);
  border-color: color-mix(in srgb, var(--accent) 35%, var(--line) 65%);
}

.bulk-rename-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 8px;
}

.bulk-rename-actions .button {
  min-height: 34px;
  padding-left: 10px;
  padding-right: 10px;
}

.bulk-child-review {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.bulk-child-review[hidden] {
  display: none;
}

.bulk-child-review-rows,
.bulk-task-review-rows {
  display: grid;
  gap: 6px;
  max-height: 320px;
  overflow: auto;
  padding-right: 3px;
}

.bulk-child-review-tools {
  display: grid;
  grid-template-columns: minmax(82px, 1fr) 126px 76px 132px 76px 132px 76px;
  gap: 6px;
  align-items: end;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #f8fafb;
}

.bulk-child-review-tools .button {
  min-height: 32px;
  width: 100%;
  padding-left: 8px;
  padding-right: 8px;
  font-size: 12px;
  white-space: nowrap;
}

.bulk-child-review-tools .field {
  gap: 3px;
}

.bulk-child-review-tools .field label {
  font-size: 11px;
  line-height: 1.1;
}

.bulk-child-review-tools input,
.bulk-child-review-tools select {
  min-height: 32px;
  padding: 4px 7px;
  font-size: 13px;
}

.bulk-child-review-tools .check-row {
  min-height: 32px;
  gap: 6px;
  font-size: 12px;
  line-height: 1.05;
}

.bulk-child-review-tools .check-row input {
  width: 14px;
  height: 14px;
}

.bulk-task-review-tools {
  display: grid;
  grid-template-columns: minmax(82px, 1fr) 150px 76px;
  gap: 6px;
  align-items: end;
  justify-content: end;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #f8fafb;
}

.bulk-task-review-tools .button {
  min-height: 32px;
  width: 100%;
  padding-left: 8px;
  padding-right: 8px;
  font-size: 12px;
  white-space: nowrap;
}

.bulk-task-review-tools .field {
  gap: 3px;
}

.bulk-task-review-tools .field label {
  font-size: 11px;
  line-height: 1.1;
}

.bulk-task-review-tools select {
  min-height: 32px;
  padding: 4px 7px;
  font-size: 13px;
}

.bulk-task-review-tools .check-row {
  min-height: 32px;
  gap: 6px;
  font-size: 12px;
  line-height: 1.05;
}

.bulk-task-review-tools .check-row input {
  width: 14px;
  height: 14px;
}

.bulk-child-review-row {
  display: grid;
  grid-template-columns: 24px minmax(220px, 1fr) 126px 132px 132px;
  gap: 6px;
  align-items: center;
  padding: 4px 6px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #f8fafb;
}

.bulk-task-review-row {
  grid-template-columns: 24px minmax(220px, 1fr) 150px;
}

.bulk-child-review-row.is-preview {
  background: color-mix(in srgb, var(--accent) 8%, #ffffff 92%);
  border-color: color-mix(in srgb, var(--accent) 30%, var(--line) 70%);
}

.bulk-child-review-row .field {
  gap: 0;
}

.bulk-child-review-row input[type="date"],
.bulk-child-review-row select {
  min-height: 32px;
  padding: 4px 7px;
  font-size: 13px;
}

.bulk-child-review-select {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.bulk-child-review-select input {
  width: 14px;
  height: 14px;
  min-height: 0;
  margin: 0;
}

.bulk-child-review-name {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 6px;
  align-items: center;
  min-height: 32px;
}

.bulk-child-review-name span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 22px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 12%, #ffffff 88%);
  color: var(--accent);
  font-size: 11px;
  font-weight: 900;
}

.bulk-child-review-name strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bulk-visual-assist-window {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 80;
  width: min(520px, calc(100vw - 36px));
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 18px 48px rgba(17, 24, 39, 0.24);
}

.bulk-visual-assist-window[hidden] {
  display: none;
}

.bulk-visual-assist-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.bulk-visual-assist-head strong {
  font-size: 14px;
}

.bulk-visual-assist-window textarea {
  width: 100%;
  min-height: 74px;
  resize: vertical;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.bulk-visual-assist-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.bulk-visual-assist-stats span {
  min-height: 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #f8fafb;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.bulk-visual-assist-stats b {
  color: var(--ink);
  font-size: 14px;
}

.finder-footer {
  justify-content: space-between;
}

.client-editor-row {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
  display: grid;
  gap: 10px;
  background: var(--panel);
}

.compact-dialog {
  width: min(560px, 100%);
}

.audit-history-dialog {
  width: min(920px, calc(100vw - 36px));
  max-height: min(820px, calc(100vh - 36px));
}

.project-health-dialog {
  width: min(1260px, calc(100vw - 48px));
  height: min(820px, calc(100vh - 48px));
  overflow: hidden;
}

.project-health-dialog .dialog-header h2,
.project-health-dialog .dialog-header p {
  margin: 0;
}

.project-health-dialog .dialog-header p {
  margin-top: 2px;
}

.project-health-body {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  min-height: 0;
  height: calc(100% - 65px);
  padding: 0;
  overflow: hidden;
  background: #eef2f5;
}

.project-health-error {
  margin: 12px 14px 0;
}

.project-health-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
  background: var(--panel);
}

.project-health-summary button {
  display: grid;
  gap: 2px;
  min-height: 74px;
  padding: 13px 16px;
  border-right: 1px solid var(--line);
  border-bottom: 3px solid transparent;
  background: transparent;
  color: var(--ink);
  text-align: left;
}

.project-health-summary button:last-child {
  border-right: 0;
}

.project-health-summary button:hover,
.project-health-summary button.active {
  background: #f7f9fb;
}

.project-health-summary button.active.status-at_risk {
  border-bottom-color: #c73d3d;
}

.project-health-summary button.active.status-attention {
  border-bottom-color: #d89a20;
}

.project-health-summary button.active.status-healthy {
  border-bottom-color: #2f9e58;
}

.project-health-summary button.active.status-all {
  border-bottom-color: var(--accent);
}

.project-health-summary span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.project-health-summary strong {
  font-size: 23px;
}

.project-health-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 150px auto minmax(290px, auto);
  align-items: center;
  gap: 10px;
  min-height: 58px;
  padding: 9px 14px;
  border-bottom: 1px solid var(--line);
  background: #f7f9fb;
}

.project-health-toolbar .field {
  margin: 0;
}

.project-health-toolbar input,
.project-health-toolbar select {
  min-height: 36px;
  background: #fff;
}

.project-health-archived {
  min-height: 36px;
  padding-inline: 8px;
  white-space: nowrap;
}

.project-health-freshness {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  min-width: 0;
}

.project-health-integration,
.project-health-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.project-health-integration {
  color: var(--muted);
}

.project-health-integration i,
.project-health-status i,
.project-health-signals i {
  flex: 0 0 auto;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #a8b2bc;
}

.project-health-integration.connected i,
.project-health-status.status-healthy i,
.project-health-signals .severity-healthy i {
  background: #2f9e58;
}

.project-health-status.status-attention i,
.project-health-signals .severity-attention i,
.project-health-signals .severity-info i {
  background: #d89a20;
}

.project-health-status.status-at_risk i,
.project-health-signals .severity-at_risk i {
  background: #c73d3d;
}

.project-health-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  min-height: 0;
  overflow: hidden;
}

.project-health-list {
  min-width: 0;
  min-height: 0;
  overflow: auto;
  background: #fff;
}

.project-health-table {
  width: 100%;
  min-width: 830px;
  border-collapse: collapse;
  table-layout: fixed;
}

.project-health-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  height: 38px;
  padding: 8px 10px;
  border-bottom: 1px solid var(--line-strong);
  background: #f7f9fb;
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  text-align: left;
  text-transform: uppercase;
}

.project-health-table th:first-child {
  width: 24%;
}

.project-health-table th:nth-child(2) {
  width: 12%;
}

.project-health-table th:nth-child(3) {
  width: 17%;
}

.project-health-table th:nth-child(4) {
  width: 17%;
}

.project-health-table th:nth-child(5) {
  width: 18%;
}

.project-health-table td {
  height: 66px;
  padding: 9px 10px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
  font-size: 12px;
}

.project-health-table tbody tr {
  outline: none;
  cursor: pointer;
}

.project-health-table tbody tr:hover,
.project-health-table tbody tr:focus,
.project-health-table tbody tr.selected {
  background: #f2f7f8;
}

.project-health-table tbody tr.selected {
  box-shadow: inset 3px 0 var(--accent);
}

.project-health-table td > b,
.project-health-table td > small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.project-health-table td > small,
.project-health-project-name small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.project-health-project-name {
  display: grid;
  grid-template-columns: 5px minmax(0, 1fr);
  align-items: stretch;
  gap: 9px;
  min-width: 0;
}

.project-health-project-name > i {
  min-height: 34px;
  border-radius: 3px;
}

.project-health-project-name > span,
.project-health-project-name b,
.project-health-project-name small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.project-health-progress {
  display: inline-block;
  width: 62px;
  height: 6px;
  margin-right: 7px;
  overflow: hidden;
  border-radius: 3px;
  background: #dfe5e9;
  vertical-align: middle;
}

.project-health-progress span {
  display: block;
  height: 100%;
  background: var(--accent);
}

.project-health-table .project-health-progress + b {
  display: inline;
}

.project-health-detail {
  min-width: 0;
  min-height: 0;
  overflow: auto;
  border-left: 1px solid var(--line-strong);
  background: #f7f9fb;
}

.project-health-detail-head,
.project-health-detail-actions,
.project-health-detail-section {
  padding: 16px;
  border-bottom: 1px solid var(--line);
}

.project-health-detail-head h3,
.project-health-detail-head p,
.project-health-detail-section h4,
.project-health-metrics {
  margin: 0;
}

.project-health-detail-head h3 {
  margin-top: 8px;
  font-size: 17px;
}

.project-health-detail-head p {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.project-health-detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-block: 12px;
}

.project-health-detail-section h4 {
  margin-bottom: 10px;
  font-size: 11px;
  text-transform: uppercase;
}

.project-health-signals {
  display: grid;
  gap: 7px;
}

.project-health-signals > div {
  display: grid;
  grid-template-columns: 8px minmax(0, 1fr);
  align-items: start;
  gap: 8px;
  color: #46525e;
  font-size: 12px;
  line-height: 1.35;
}

.project-health-signals i {
  margin-top: 4px;
}

.project-health-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 14px;
}

.project-health-metrics div {
  min-width: 0;
}

.project-health-metrics dt {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
}

.project-health-metrics dd {
  margin: 3px 0 0;
  font-size: 13px;
  font-weight: 850;
}

.project-health-metrics dd.negative {
  color: #ad2f34;
}

.project-health-loading,
.project-health-empty {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 7px;
  min-height: 280px;
  color: var(--muted);
  text-align: center;
}

.project-health-loading {
  grid-row: 1 / -1;
}

.project-health-loading .icon {
  width: 34px;
  height: 34px;
  color: var(--accent);
}

.project-health-empty span,
.project-health-loading span {
  font-size: 12px;
}

@media (max-width: 980px) {
  .project-health-toolbar {
    grid-template-columns: minmax(180px, 1fr) 145px auto;
  }

  .project-health-freshness {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }

  .project-health-workspace {
    grid-template-columns: minmax(0, 1fr) 290px;
  }
}

@media (max-width: 760px) {
  .project-health-dialog {
    width: calc(100vw - 20px);
    height: calc(100vh - 20px);
  }

  .project-health-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .project-health-summary button:nth-child(2) {
    border-right: 0;
  }

  .project-health-toolbar {
    grid-template-columns: 1fr 1fr;
  }

  .project-health-search,
  .project-health-freshness {
    grid-column: 1 / -1;
  }

  .project-health-workspace {
    grid-template-columns: 1fr;
    overflow: auto;
  }

  .project-health-list,
  .project-health-detail {
    overflow: visible;
  }

  .project-health-detail {
    border-top: 1px solid var(--line-strong);
    border-left: 0;
  }
}

.role-preview-dialog .panel-block {
  display: grid;
  gap: 16px;
}

.role-preview-intro {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  align-items: start;
  gap: 11px;
}

.role-preview-intro h3,
.role-preview-intro p {
  margin: 0;
}

.role-preview-intro p {
  margin-top: 3px;
}

.role-preview-intro-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line-strong);
  border-radius: 7px;
  background: #f4f1ff;
  color: var(--accent);
}

.role-preview-safety {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 11px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #f7f9fb;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.role-preview-safety .icon {
  flex: 0 0 auto;
  width: 16px;
  height: 16px;
}

@media (max-width: 620px) {
  .role-preview-banner small {
    display: none;
  }
}

.audit-history-dialog .dialog-header h2,
.audit-history-dialog .dialog-header p {
  margin: 0;
}

.audit-history-dialog .dialog-header p {
  margin-top: 2px;
}

.audit-history-body {
  display: grid;
  min-height: 360px;
  gap: 14px;
  overflow: hidden;
}

.audit-history-filters {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(145px, 0.48fr) minmax(145px, 0.48fr) auto;
  align-items: end;
  gap: 10px;
}

.audit-history-filters .field {
  margin: 0;
}

.audit-history-list {
  display: grid;
  align-content: start;
  min-height: 280px;
  max-height: min(540px, calc(100vh - 260px));
  overflow: auto;
  border-block: 1px solid var(--line);
}

.audit-history-entry {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 11px;
  padding: 13px 4px;
  border-bottom: 1px solid var(--line);
}

.audit-history-entry:last-child {
  border-bottom: 0;
}

.audit-history-mark {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 1px solid var(--line-strong);
  border-radius: 7px;
  color: var(--muted);
  background: var(--panel);
}

.audit-history-content {
  display: grid;
  min-width: 0;
  gap: 5px;
}

.audit-history-entry-head,
.audit-history-meta,
.audit-history-fields,
.audit-history-footer,
.audit-history-footer > div {
  display: flex;
  align-items: center;
  gap: 8px;
}

.audit-history-entry-head {
  justify-content: space-between;
}

.audit-history-entry-head div {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
}

.audit-history-entry-head span,
.audit-history-entry-head time,
.audit-history-meta,
.audit-history-no-fields {
  color: var(--muted);
  font-size: 12px;
}

.audit-history-entry-head time {
  white-space: nowrap;
}

.audit-history-meta {
  flex-wrap: wrap;
}

.audit-history-meta span + span::before {
  content: "\00b7";
  margin-right: 8px;
}

.audit-history-id {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.audit-history-fields {
  flex-wrap: wrap;
}

.audit-history-fields span {
  padding: 3px 7px;
  border-radius: 5px;
  color: var(--muted);
  background: var(--surface, #eef2f5);
  font-size: 11px;
  font-weight: 700;
}

.audit-history-empty {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 4px;
  min-height: 240px;
  text-align: center;
}

.audit-history-footer {
  justify-content: space-between;
}

@media (max-width: 760px) {
  .audit-history-filters {
    grid-template-columns: 1fr 1fr;
  }

  .audit-history-search,
  .audit-history-filters > button {
    grid-column: 1 / -1;
  }

  .audit-history-entry-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 3px;
  }
}

.connections-dialog {
  width: min(760px, calc(100vw - 36px));
}

.connections-dialog .dialog-header h2,
.connections-dialog .dialog-header p,
.connection-service-name h3,
.connection-service-name p,
.connection-check-message {
  margin: 0;
}

.connections-dialog .dialog-header p {
  margin-top: 2px;
}

.connections-body {
  display: grid;
  gap: 0;
  padding: 0;
}

.connections-body > .error-message,
.connections-body > .success-message {
  margin: 14px 16px 0;
}

.connection-service-row {
  display: grid;
  gap: 12px;
  padding: 18px;
  border-bottom: 1px solid var(--line);
}

.connection-service-row:last-child {
  border-bottom: 0;
}

.connection-service-heading,
.connection-service-name,
.connection-service-meta,
.connection-service-actions {
  display: flex;
  align-items: center;
}

.connection-service-heading {
  justify-content: space-between;
  gap: 16px;
}

.connection-service-name {
  min-width: 0;
  gap: 10px;
}

.connection-service-name p,
.connection-service-meta,
.connection-replace-form small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.connection-service-icon {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 34px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--panel-2);
  color: var(--ink);
}

.connection-service-meta {
  flex-wrap: wrap;
  gap: 6px 16px;
}

.connection-service-meta span {
  white-space: nowrap;
}

.connection-service-actions {
  flex-wrap: wrap;
  gap: 8px;
}

.connection-replace-form {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--panel-2);
}

.connection-replace-form .field {
  margin: 0;
}

.connection-check-message {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.connection-check-message.success {
  color: var(--success);
}

.connection-check-message.error {
  color: var(--danger);
}

.public-calendar-share-panel {
  display: grid;
  gap: 10px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.issued-schedule-panel {
  display: grid;
  gap: 8px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.issued-schedule-list {
  display: grid;
  gap: 6px;
}

.issued-schedule-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.issued-schedule-row b,
.issued-schedule-row small {
  display: block;
}

.issued-schedule-row b {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.issued-schedule-row small {
  color: var(--muted);
  font-size: 12px;
}

.public-calendar-created-link,
.public-calendar-share-url {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 8px;
  align-items: center;
}

.public-calendar-created-link {
  grid-template-columns: minmax(0, 1fr) auto;
}

.public-calendar-share-list {
  display: grid;
  gap: 8px;
}

.public-calendar-share-row {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.public-calendar-share-row.is-disabled {
  opacity: .72;
}

.public-calendar-share-row-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.public-calendar-share-row-head b,
.public-calendar-share-row-head small {
  display: block;
}

.public-calendar-share-row-head small {
  color: var(--muted);
  font-size: 12px;
}

.public-calendar-view-details summary {
  cursor: pointer;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.public-calendar-view-list {
  display: grid;
  gap: 6px;
  margin-top: 6px;
}

.public-calendar-view-list div {
  display: grid;
  gap: 1px;
  padding: 6px 8px;
  border-radius: 6px;
  background: var(--panel);
}

.public-calendar-view-list span,
.public-calendar-view-list small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.compact-button {
  min-height: 34px;
  padding: 6px 10px;
  font-size: 13px;
}

.bulk-import-dialog {
  width: min(1180px, calc(100vw - 24px));
}

.child-activity-create-dialog {
  width: min(860px, calc(100vw - 32px));
}

.child-activity-create-card {
  display: grid;
  gap: 12px;
}

.child-activity-paste-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.child-activity-create-card textarea {
  min-height: 116px;
  resize: vertical;
}

.child-activity-parent-section {
  max-width: none;
}

.child-activity-create-row {
  display: grid;
  grid-template-columns: minmax(145px, 180px) minmax(130px, 155px) minmax(120px, 145px) minmax(180px, 1fr);
  gap: 12px;
  align-items: end;
}

.child-activity-start-field,
.child-activity-start-time-field,
.child-activity-duration-field,
.child-activity-assignee-field {
  min-width: 0;
}

@media (max-width: 760px) {
  .child-activity-paste-grid,
  .child-activity-create-row {
    grid-template-columns: 1fr;
  }
}

.bulk-import-body {
  display: grid;
  gap: 16px;
  background: #eef2f5;
}

.stage-mapping-dialog {
  width: min(980px, calc(100vw - 40px));
}

.dialog-header,
.dialog-footer {
  position: sticky;
  background: var(--panel);
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
}

.dialog-header {
  top: 0;
}

.dialog-header h2 {
  min-width: 0;
}

.dialog-header-actions {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  gap: 8px;
}

.dialog-footer {
  bottom: 0;
  border-top: 1px solid var(--line);
  border-bottom: 0;
  justify-content: flex-end;
}

.dialog-body {
  padding: 16px;
}

.billing-hub-overlay {
  background: rgba(78, 86, 92, 0.64);
}

.billing-hub-dialog {
  width: min(1180px, calc(100vw - 80px));
  min-height: min(540px, calc(100vh - 120px));
}

.billing-hub-body {
  min-height: 430px;
  background: #e5eaee;
}

.billing-hub-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 16px;
  align-content: start;
}

.project-billing-navigation {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.project-billing-navigation button {
  min-height: 36px;
  padding: 6px 10px;
  border: 1px solid transparent;
  border-radius: 4px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}

.project-billing-navigation button[aria-current="page"] {
  background: var(--ink);
  color: var(--panel);
}

.project-billing-navigation button:hover:not(:disabled):not([aria-current]) {
  border-color: var(--line-strong);
}

.project-billing-navigation button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.project-billing-navigation button:disabled { cursor: default; opacity: .55; }
.project-billing-navigation .icon-button { width: 36px; padding: 6px; }

.billing-hub-card {
  display: grid;
  justify-items: start;
  gap: 10px;
  min-height: 150px;
  padding: 18px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: #f9fbfc;
  color: var(--ink);
  text-align: left;
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.08);
  cursor: pointer;
}

.billing-hub-card:hover {
  border-color: #8f99a3;
  background: #fff;
  transform: translateY(-1px);
}

.billing-hub-card strong {
  font-size: 18px;
}

.billing-hub-card span:last-child {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.billing-hub-icon {
  color: var(--accent);
}

.billing-hub-icon {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--accent);
}

.billing-hub-icon .icon {
  width: 24px;
  height: 24px;
}

.ops-dashboard-dialog {
  width: min(1240px, calc(100vw - 72px));
  min-height: min(620px, calc(100vh - 96px));
}

.ops-portal {
  min-height: 100vh;
  background: #eef2f5;
  color: var(--ink);
}

.ops-portal-topbar {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 12px 28px;
  background: var(--nav);
  color: var(--nav-ink);
}

.ops-portal-brand,
.ops-portal-user,
.ops-portal-heading,
.ops-health-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.ops-portal-brand img {
  width: 138px;
  max-height: 38px;
  object-fit: contain;
}

.ops-portal-brand span {
  padding-left: 14px;
  border-left: 1px solid rgba(255, 255, 255, 0.22);
  font-size: 14px;
  font-weight: 900;
  text-transform: uppercase;
}

.ops-portal-user > span {
  display: grid;
  gap: 1px;
  text-align: right;
}

.ops-portal-user small {
  color: #aeb9c7;
}

.ops-portal-main {
  width: min(1320px, calc(100% - 48px));
  margin: 0 auto;
  padding: 28px 0 48px;
}

.ops-portal-heading {
  margin-bottom: 18px;
}

.ops-portal-heading h1,
.ops-portal-heading p {
  margin: 0;
}

.ops-portal-heading h1 {
  font-size: 26px;
}

.ops-portal-heading p {
  margin-top: 3px;
  color: var(--muted);
  font-weight: 700;
}

.ops-environment-label {
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: capitalize;
}

.ops-portal-content {
  margin-top: 14px;
}

.ops-access-card {
  width: min(430px, calc(100vw - 40px));
}

.ops-dashboard-body {
  display: grid;
  gap: 14px;
  background: #eef2f5;
}

.ops-tabs {
  width: fit-content;
  max-width: 100%;
  overflow-x: auto;
  background: #fff;
}

.ops-tabs > button {
  flex-shrink: 0;
}

.ops-kit-panel {
  min-width: 0;
}

.ops-kit-panel [data-ops-kit-create-form],
.ops-kit-panel [data-ops-kit-signup-form] {
  display: grid;
  gap: 12px;
  width: 100%;
  max-width: 520px;
  margin: 12px 0 20px;
}

.ops-kit-panel [data-ops-kit-create-form] { max-width: 760px; }

.ops-kit-panel [data-ops-kit-create-form] h4,
.ops-kit-panel [data-ops-kit-signup-form] h4 {
  margin: 0;
}

.ops-kit-panel [data-ops-kit-create-form] > button,
.ops-kit-panel [data-ops-kit-signup-form] > button {
  justify-self: start;
  white-space: normal;
}

.ops-kit-table-scroll {
  max-width: 100%;
  overflow-x: auto;
}

.ops-kit-table-scroll table {
  width: 100%;
  min-width: 520px;
}

.ops-backups {
  min-width: 0;
  padding: 16px;
  background: var(--panel);
  color: var(--ink);
  font-size: 13px;
}

.ops-backups :is(h3, h4, p, dl) {
  margin: 0;
}

.ops-backups h3 {
  font-size: 16px;
}

.ops-backups h4 {
  margin-bottom: 12px;
  font-size: 14px;
}

.ops-backups-heading,
.ops-backups-actions,
.ops-backups-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
}

.ops-backups-heading {
  justify-content: space-between;
}

.ops-backups-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  padding: 18px 0;
}

.ops-backups dt {
  color: var(--muted);
  font-size: 12px;
}

.ops-backups dd {
  margin: 4px 0 0;
}

.ops-backups :is(dd, dt, p, a, th, td) {
  overflow-wrap: anywhere;
}

.ops-backups-status {
  font-weight: 800;
  color: var(--muted);
}

.ops-backups-status.healthy {
  color: var(--success);
}

.ops-backups-status.issue,
.ops-backups .ops-backups-error {
  color: var(--danger);
}

.ops-backups > p[role] {
  margin-top: 12px;
}

.ops-backups-section {
  min-width: 0;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.ops-backups-details {
  display: grid;
  gap: 10px;
}

.ops-backups-details > div {
  display: grid;
  grid-template-columns: minmax(90px, 1fr) minmax(0, 2fr);
  gap: 12px;
}

.ops-backups-details dd {
  margin: 0;
}

.ops-backups-links,
.ops-backups-section > p {
  margin-top: 14px;
}

.ops-backups a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.ops-backups-table-scroll {
  max-width: 100%;
  overflow-x: auto;
}

.ops-backups-table {
  width: 100%;
  min-width: 850px;
  table-layout: fixed;
  border-collapse: collapse;
  text-align: left;
}

.ops-backups-table :is(th, td) {
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
  white-space: normal;
}

.ops-backups-table thead {
  background: var(--panel-2);
  color: var(--muted);
}

.ops-backups-table thead th {
  background: var(--panel-2);
  color: var(--muted);
}

.ops-backups-table tbody th {
  background: var(--panel);
  color: var(--ink);
}

.ops-backups-evidence {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.tracker-theme-dark .ops-backups {
  --success: #78d4a0;
  --danger: #ff9b9d;
  --accent: #b8acff;
  --accent-ink: #20202c;
}

@media (max-width: 700px) {
  .ops-backups-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ops-backups-evidence {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
  }

  .ops-backups {
    padding: 12px;
  }
}

.ops-health {
  display: grid;
  gap: 14px;
}

.ops-health-empty {
  min-height: 180px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.ops-health-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.ops-health-check {
  min-height: 88px;
  display: grid;
  grid-template-columns: 10px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.ops-health-check p {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.ops-health-check > b {
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
}

.ops-health-indicator {
  width: 8px;
  height: 34px;
  border-radius: 4px;
  background: #c4cdd5;
}

.ops-health-check.healthy .ops-health-indicator {
  background: #2f9e58;
}

.ops-health-check.warning .ops-health-indicator {
  background: #d89a20;
}

.ops-health-check.issue .ops-health-indicator {
  background: #c73d3d;
}

.ops-health-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  padding: 0;
  overflow: hidden;
}

.ops-health-summary > div {
  display: grid;
  gap: 3px;
  padding: 16px;
  border-right: 1px solid var(--line);
}

.ops-health-summary > div:last-child {
  border-right: 0;
}

.ops-health-summary span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.ops-health-summary strong {
  font-size: 24px;
}

.ops-integration-panel {
  padding: 0;
  overflow: hidden;
}

.ops-integration-heading {
  padding: 16px;
  border-bottom: 1px solid var(--line);
}

.ops-integration-heading h3,
.ops-integration-heading p {
  margin: 0;
}

.ops-integration-heading p {
  margin-top: 3px;
}

.ops-integration-list {
  display: grid;
  max-height: min(520px, calc(100vh - 310px));
  overflow: auto;
}

.ops-integration-empty {
  margin: 0;
  padding: 18px 16px;
}

.ops-integration-row {
  display: grid;
  grid-template-columns: minmax(150px, 0.7fr) minmax(230px, 1fr) minmax(230px, 1fr) auto;
  align-items: stretch;
  border-bottom: 1px solid var(--line);
  background: #ffffff;
}

.ops-integration-row:last-child {
  border-bottom: 0;
}

.ops-integration-organization,
.ops-integration-service {
  min-width: 0;
  padding: 14px 16px;
}

.ops-integration-organization {
  display: grid;
  align-content: start;
  gap: 3px;
}

.ops-integration-organization span,
.ops-integration-service > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.ops-integration-service {
  display: grid;
  align-content: start;
  gap: 4px;
  border-left: 1px solid var(--line);
}

.ops-integration-service-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 2px;
}

.ops-connection-status {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 2px 7px;
  border-radius: 999px;
  background: #edf2f5;
  color: #596673;
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
  white-space: nowrap;
}

.ops-connection-status.healthy {
  background: #eaf6ef;
  color: #1f7a3c;
}

.ops-connection-status.issue {
  background: #fff1f1;
  color: #9b1c1c;
}

.ops-integration-service > .ops-integration-success {
  color: #1f7a3c;
}

.ops-integration-service > .ops-integration-failure {
  color: #9b1c1c;
}

.ops-integration-check {
  align-self: center;
  margin: 14px;
  white-space: nowrap;
}

.ops-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.95fr);
  gap: 14px;
  align-items: start;
}

.ops-whats-new-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}

.ops-whats-new-panel,
.ops-whats-new-form {
  display: grid;
  gap: 14px;
}

.ops-whats-new-schedule-fields,
.ops-shared-organization-fields {
  align-items: start;
}

.ops-whats-new-schedule-fields .field,
.ops-shared-organization-fields .field {
  grid-template-rows: auto 38px;
  align-content: start;
}

.ops-whats-new-schedule-fields select,
.ops-whats-new-schedule-fields input[type="time"],
.ops-whats-new-schedule-fields .seqncer-time-display,
.ops-shared-organization-fields input {
  height: 38px;
  min-height: 38px;
}

.ops-whats-new-timezone,
.ops-shared-slug-note {
  margin-top: -8px;
  color: var(--muted);
}

.ops-whats-new-details {
  display: grid;
  gap: 0;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.ops-whats-new-details > div {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 12px;
  padding: 9px 11px;
  border-bottom: 1px solid var(--line);
  background: #f9fbfc;
}

.ops-whats-new-details > div:last-child {
  border-bottom: 0;
}

.ops-whats-new-details dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.ops-whats-new-details dd {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
  font-size: 13px;
  font-weight: 750;
}

.ops-whats-new-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ops-panel {
  margin-bottom: 0;
  background: #fff;
}

.ops-org-list {
  display: grid;
  gap: 10px;
  max-height: min(460px, calc(100vh - 320px));
  overflow: auto;
}

.ops-org-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f9fbfc;
}

.ops-org-row.supervisor-org {
  border-color: color-mix(in srgb, var(--accent) 35%, var(--line));
}

.ops-org-title {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  min-width: 0;
}

.ops-org-row strong,
.ops-org-row span,
.ops-org-row small {
  display: block;
}

.ops-org-row span,
.ops-org-row small {
  color: var(--muted);
}

.ops-org-row small {
  grid-column: 1 / -1;
  font-size: 12px;
}

.ops-pill {
  display: inline-flex !important;
  align-items: center;
  min-height: 22px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #edf2f5;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  text-transform: capitalize;
}

.ops-pill.supervisor {
  background: color-mix(in srgb, var(--accent) 13%, #ffffff);
  color: var(--accent);
}

.ops-pill.facility,
.ops-pill.status-active {
  background: #eaf6ef;
  color: #1f7a3c;
}

.ops-pill.status-trialing {
  background: #fff7df;
  color: #946200;
}

.ops-pill.status-paused,
.ops-pill.status-cancelled,
.ops-pill.status-past_due {
  background: #fff1f1;
  color: #9b1c1c;
}

.ops-trial-line {
  margin-top: 3px;
  font-weight: 800;
}

.ops-org-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(62px, auto));
  align-items: stretch;
  align-self: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  overflow: hidden;
}

.ops-org-stats > div {
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 2px;
  min-height: 48px;
  padding: 6px 10px;
  border-left: 1px solid var(--line);
}

.ops-org-stats > div:first-child {
  border-left: 0;
}

.ops-org-stats b {
  color: var(--ink);
  font-size: 16px;
  line-height: 1;
}

.ops-org-stats span {
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
  text-transform: uppercase;
}

.ops-org-actions {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ops-form {
  display: grid;
  gap: 12px;
}

.ops-form-actions {
  display: flex;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
}

.ops-form-actions .muted {
  max-width: 440px;
}

.ops-message {
  margin: 0;
  padding: 10px 12px;
  border-radius: 8px;
  font-weight: 800;
}

.ops-message.error-message {
  border: 1px solid #f3a9a9;
  background: #fff1f1;
  color: #9b1c1c;
}

.ops-message.success-message {
  border: 1px solid #bfe5ca;
  background: #eefaf1;
  color: #1f7a3c;
}

.panel-block > .error-message,
.panel-block > .success-message {
  margin: 0;
  padding: 10px 12px;
  border-radius: 8px;
  font-weight: 800;
}

.panel-block > .error-message {
  border: 1px solid #f3a9a9;
  background: #fff1f1;
  color: #9b1c1c;
}

.panel-block > .success-message {
  border: 1px solid #bfe5ca;
  background: #eefaf1;
  color: #1f7a3c;
}

.ops-dedicated {
  display: grid;
  gap: 14px;
}

.ops-checklist {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 24px;
}

.ops-command {
  overflow: auto;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #121820;
  color: #eef5f5;
}

.ops-command code {
  white-space: nowrap;
}

.ops-handoff-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
}

.ops-handoff-grid span {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  font-weight: 800;
}

.ops-handoff-grid .icon {
  color: var(--accent);
}

.rate-card-title {
  align-items: center;
  margin-bottom: 10px;
}

.rate-card-title p {
  margin: 4px 0 0;
}

.rate-card-import {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

.rate-card-import input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.rate-card-table .rate-card-grip-column {
  width: 38px;
  padding-left: 0;
  padding-right: 4px;
}

.rate-card-grip {
  width: 30px;
  height: 38px;
  min-width: 30px;
  display: inline-grid;
  place-items: center;
  border: 1px solid transparent;
  border-radius: 7px;
  background: transparent;
  color: #657381;
  cursor: grab;
}

.rate-card-grip:hover,
.rate-card-grip:focus-visible {
  border-color: var(--line-strong);
  background: #eef3f7;
  color: var(--ink);
}

.rate-card-grip:active {
  cursor: grabbing;
}

.rate-card-grip .icon {
  width: 18px;
  height: 18px;
}

.rate-card-row-dragging {
  opacity: 0.48;
}

.rate-card-row-drop-before {
  box-shadow: inset 0 3px 0 var(--accent);
}

.rate-card-row-drop-after {
  box-shadow: inset 0 -3px 0 var(--accent);
}

.rate-card-non-unit .rate-card-default-quantity {
  opacity: 0.48;
}

.rate-card-non-unit .rate-card-default-quantity input {
  background: #eef2f5;
  cursor: not-allowed;
}

.rate-card-actions {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
}

.project-quote-panel {
  margin-top: 14px;
}

.project-time-defaults {
  margin-top: 14px;
  display: grid;
  gap: 12px;
}

.project-time-defaults h3,
.project-time-defaults p {
  margin: 0;
}

.project-time-default {
  display: grid;
  gap: 4px;
}

.project-time-default small {
  padding-left: 24px;
  line-height: 1.45;
}

.project-structure-panel {
  margin-top: 6px;
}

.project-scheduling-panel {
  margin-top: 12px;
}

.unit-day-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.vfx-bid-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 14px 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #f7f9fb;
}

.vfx-bid-panel h4 {
  margin: 0 0 4px;
}

.vfx-bid-panel p {
  margin: 0;
}

.quote-schedule-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: end;
}

.quote-schedule-actions .field {
  width: min(180px, 100%);
}

.quote-actual-project-filter {
  max-width: 360px;
}

.security-option {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.security-option h3,
.security-option p {
  margin: 0;
}

.security-option-icon {
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: var(--accent);
  background: #f7f9fb;
}

.activity-tabs {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--panel);
  margin-bottom: 14px;
}

.activity-dialog {
  max-height: min(920px, calc(100vh - 16px));
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.activity-dialog .dialog-header,
.activity-dialog .dialog-footer {
  position: relative;
  flex: 0 0 auto;
  z-index: 3;
}

.activity-dialog .dialog-body {
  min-height: 0;
  flex: 1 1 auto;
  overflow: auto;
}

.activity-tabs-sticky {
  position: sticky;
  top: -16px;
  z-index: 2;
  margin: -16px -16px 4px;
  padding: 16px 16px 10px;
  background: var(--panel);
  box-shadow: 0 1px 0 var(--line);
}

.activity-tabs-sticky .activity-tabs {
  margin-bottom: 0;
}

.activity-tabs-sticky .activity-billing-tabs {
  display: flex;
  width: fit-content;
  max-width: 100%;
  margin-top: 8px;
}

.activity-main-service-controls {
  display: flex;
  align-items: end;
  gap: 8px;
  flex-wrap: wrap;
}

.activity-main-service-fields {
  display: grid;
  gap: 12px;
  min-width: 0;
  margin-top: 10px;
}

.service-discount-fields .field > span {
  font-size: 12px;
  font-weight: 750;
}

.service-discount-summary {
  display: block;
  overflow-wrap: anywhere;
}

.service-discount-policy {
  display: grid;
  gap: 8px;
  padding-bottom: 16px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.service-discount-policy button { justify-self: start; }

[data-project-billing-settings] .service-discount-policy {
  margin-top: 20px;
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: 0;
  gap: 12px;
}

[data-project-billing-settings] .service-discount-policy p { margin: 0; }


.invoice-preparation-table td small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
}

.payment-plan-table { min-width: 940px; }
.payment-plan-table input { width: 100%; min-width: 90px; }
.payment-plan-table td { min-width: 120px; }
.payment-plan-table td:last-child { min-width: 44px; }
.payment-plan-lock { display: flex; align-items: center; gap: 4px; margin-top: 4px; font-size: 12px; color: var(--muted); }
.payment-plan-lock svg { width: 14px; height: 14px; flex: 0 0 14px; }
[data-payment-plan-form] .dialog-body { min-width: 0; }
[data-payment-plan-form] .invoice-preparation-table input { max-width: 100%; }
[data-invoice-batches] input[type="checkbox"],
[data-payment-plan-form] [data-plan-activity] input[type="checkbox"] {
  width: 16px;
  height: 16px;
  min-width: 16px;
  min-height: 16px;
  padding: 0;
  margin: 0;
  vertical-align: middle;
}

.invoice-preparation-dialog { width: min(1100px, calc(100vw - 32px)); }
[data-invoice-batches] .section-title,
[data-invoice-batches] .dialog-footer { flex-wrap: wrap; }
[data-invoice-batches] .section-title > * { min-width: 0; overflow-wrap: anywhere; }
.quote-draft-heading { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
.quote-draft-toolbar { display:flex; flex-wrap:wrap; gap:10px; align-items:center; margin-top:16px; }
.quote-draft-toolbar select { width:260px; max-width:100%; }
.quote-draft-toolbar strong { margin-left:auto; }
.quote-draft-table { table-layout:fixed; min-width:950px; }
.quote-draft-table th:first-child { width:30%; }
.quote-draft-table th:last-child { width:48px; }
.quote-draft-table input, .quote-draft-table select, .quote-draft-table textarea { width:100%; min-width:0; max-width:100%; }
.quote-draft-table textarea { resize:vertical; min-height:64px; }
.quote-draft-table textarea, .quote-draft-toolbar select { font:inherit; padding:8px; border:1px solid var(--line); border-radius:6px; background:var(--panel); color:var(--text); }
[data-quote-editor-form] .dialog-body { min-width:0; }
.quote-workflow-section { margin-top:18px; padding-top:16px; border-top:1px solid var(--line); }
.quote-workflow-section > summary { font-weight:700; cursor:pointer; margin-bottom:12px; }
.quote-brand-logo { display:block; max-width:180px; max-height:80px; object-fit:contain; margin:8px 0; }
.quote-workflow-section .check-row input { width:16px; height:16px; min-width:16px; padding:0; }
.quote-budget-map { margin-top:16px; }
.quote-budget-map select { max-width:320px; }
.quote-workflow-section .field { min-width:0; }
@media (max-width:600px) {
  [data-quote-editor-form] .dialog-footer { flex-wrap:wrap; }
  [data-quote-editor-form] .dialog-footer .button { flex:1 0 130px; }
}
.invoice-preparation-filters { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 16px 0; }
.invoice-preparation-filters .check-row { grid-column: 1 / -1; }
.invoice-preparation-filters .field, .invoice-preparation-filters input, .invoice-preparation-filters select { min-width: 0; max-width: 100%; }
.invoice-preparation-table-wrap { overflow-x: auto; margin-top: 16px; }
.invoice-preparation-table { width: 100%; min-width: 620px; border-collapse: collapse; }
.invoice-preparation-table th, .invoice-preparation-table td { padding: 10px; border-bottom: 1px solid var(--line); text-align: left; }
.invoice-preparation-table .right { text-align: right; white-space: nowrap; }
.invoice-preparation-activity { background: var(--surface-2, #edf1f3); }
.invoice-preparation-activity small { display: block; font-weight: 400; color: var(--muted); margin-top: 4px; }
@media (max-width: 600px) {
  .invoice-preparation-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.activity-main-service-controls .field {
  flex: 1 1 200px;
  min-width: 0;
}

.activity-kit-operational .activity-kit-source-details {
  display: none;
}

.activity-expense-comparison {
  overflow-x: auto;
  min-width: 0;
}

.activity-expense-comparison table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.activity-expense-comparison :is(th, td) {
  padding: 8px;
  border-bottom: 1px solid var(--line);
  text-align: right;
  white-space: nowrap;
}

.activity-expense-comparison :is(th, td):first-child {
  text-align: left;
  white-space: normal;
  min-width: 130px;
}

.activity-tabs button {
  min-height: 36px;
  border: 0;
  border-right: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  padding: 0 14px;
  font-weight: 800;
  position: relative;
}

.activity-tabs button:last-child {
  border-right: 0;
}

.activity-tabs button.active {
  background: var(--ink);
  color: #fff;
}

.activity-tabs button.has-unread {
  padding-right: 26px;
}

.activity-note-row {
  border-left: 4px solid var(--accent);
}

.activity-note-row.internal-note {
  border-left-color: #d69e2e;
  background: #fff8e8;
}

.activity-note-row.internal-note > b {
  color: #b36b00;
}

.activity-note-lock {
  display: inline-flex;
  align-items: center;
  margin-right: 5px;
  color: #b36b00;
  vertical-align: -2px;
}

.activity-note-lock .icon {
  width: 13px;
  height: 13px;
}

.activity-note-row p {
  font-size: 15px;
  line-height: 1.35;
  color: var(--ink);
}

.activity-note-timecode {
  font-size: inherit;
  line-height: inherit;
  font-weight: 800;
}

.activity-note-row .task-meta {
  font-size: 11px;
  line-height: 1.25;
  color: #657381;
}

.activity-note-review-link {
  min-height: 24px;
  padding: 0 7px;
  font-size: 10.5px;
  font-weight: 800;
  white-space: nowrap;
}

.activity-note-review-link .icon {
  width: 12px;
  height: 12px;
}

.tab-unread-dot {
  position: absolute;
  top: 8px;
  right: 9px;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #ffd84d;
  box-shadow: 0 0 0 2px #fff;
}

.dialog-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 16px;
  align-items: start;
}

.dialog-grid.activity-kit-layout {
  grid-template-columns: minmax(0, 1fr);
}

@media (max-width: 600px) {
  .activity-kit-panel .activity-kit-attached-card {
    grid-template-columns: 42px minmax(0, 1fr);
  }

  .activity-kit-panel .activity-kit-attached-card > small {
    grid-column: 2;
  }

  .activity-kit-panel .activity-kit-attached-card > :is(.pill, .activity-kit-summary-amount) {
    grid-column: 2;
    justify-self: start;
  }
}

.panel-block {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbfcfc;
  margin-bottom: 12px;
}

.panel-block h3 {
  margin: 0;
  font-size: 14px;
}

.two {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.inline-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 92px;
  gap: 8px;
}

.static-field {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--muted);
  font-weight: 800;
}

.three {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.activity-task-dialog {
  width: min(1180px, calc(100vw - 28px));
}

.activity-notes-dialog {
  width: min(1240px, calc(100vw - 28px));
}

.activity-task-dialog .dialog-grid {
  grid-template-columns: 1fr;
}

.activity-notes-dialog .dialog-grid {
  grid-template-columns: 1fr;
}

.activity-task-dialog aside,
.activity-notes-dialog aside {
  display: none;
}

.task-view-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.segmented-control {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #f8fafb;
}

.segmented-control button {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0 10px;
  border: 0;
  border-right: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-weight: 850;
}

.segmented-control button:last-child {
  border-right: 0;
}

.segmented-control button.active {
  background: var(--accent);
  color: #fff;
}

.task-board-wrap {
  display: grid;
  gap: 8px;
}

.task-board-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  flex-wrap: wrap;
}

.task-board-toolbar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.task-tool-button {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-weight: 850;
  cursor: grab;
}

.task-tool-button:active {
  cursor: grabbing;
}

.task-tool-button .icon {
  width: 16px;
  height: 16px;
  color: var(--accent);
}

.task-board-display-toggle {
  min-height: 30px;
  padding: 0 6px;
  border: 0;
  background: transparent;
}

.task-board-display-toggle span {
  white-space: nowrap;
}

.task-snap-toggle {
  min-height: 30px;
  padding: 0 10px;
  font-size: 12px;
}

.task-board-surface {
  position: relative;
  min-width: 0;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(#f8fafb, #f8fafb),
    repeating-linear-gradient(0deg, transparent 0 23px, rgba(48, 61, 70, 0.05) 23px 24px),
    repeating-linear-gradient(90deg, transparent 0 23px, rgba(48, 61, 70, 0.05) 23px 24px);
  background-blend-mode: normal;
}

.task-board-canvas {
  width: 980px;
  min-height: inherit;
  pointer-events: none;
}

.task-board-lasso {
  position: absolute;
  z-index: 10000;
  border: 1px solid var(--accent);
  background: color-mix(in srgb, var(--accent) 16%, transparent);
  pointer-events: none;
}

.task-board-surface.snap-grid {
  background:
    repeating-linear-gradient(0deg, #f8fafb 0 23px, rgba(99, 72, 190, 0.13) 23px 24px),
    repeating-linear-gradient(90deg, transparent 0 23px, rgba(99, 72, 190, 0.13) 23px 24px);
}

.task-row {
  display: grid;
  gap: 8px;
}

.task-board-card {
  position: absolute;
  width: 252px;
  min-height: 118px;
  padding: 10px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(28, 40, 46, 0.12);
  cursor: grab;
  touch-action: none;
}

.task-board-card .field,
.task-board-card .task-top,
.task-board-card .task-controls {
  min-width: 0;
}

.task-board-card .field textarea,
.task-board-card textarea {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  display: block;
}

.task-board-card-tool {
  min-height: 92px;
}

.link-board-card {
  padding: 14px;
}

.todo-board-card {
  width: 210px;
  min-height: 72px;
  padding: 8px;
  gap: 6px;
}

.standalone-comment-card {
  width: 260px;
  min-height: 62px;
  gap: 6px;
  padding: 8px;
  background: #f1f4fc;
}

.standalone-comment-thread {
  display: grid;
  gap: 6px;
}

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

.board-comment-copy {
  min-width: 0;
  cursor: text;
}

.board-comment-copy p {
  margin: 0;
  color: var(--text);
  font-size: 12px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.board-comment-time {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 750;
}

.task-board-card.standalone-comment-card textarea {
  min-height: 30px;
  resize: vertical;
  border: 0;
  border-radius: 6px;
  background: #fff;
  padding: 6px 8px;
  font-size: 12px;
  line-height: 1.25;
}

.standalone-comment-card textarea::placeholder {
  color: #b6bdc8;
}

.standalone-comment-reply {
  justify-self: end;
}

.board-comment-marker {
  position: absolute;
  right: -7px;
  top: -7px;
  z-index: 3;
  width: 21px;
  height: 21px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #0b1328;
  border-radius: 999px 999px 999px 4px;
  background: var(--accent);
  color: #fff;
  font-size: 10px;
  font-weight: 900;
  box-shadow: 0 4px 12px rgba(20, 28, 34, 0.22);
}

.board-comment-marker.selected {
  outline: 2px solid #0b1328;
  outline-offset: 2px;
  transform: scale(1.05);
}

.task-board-card.selected {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 38%, transparent), 0 8px 22px rgba(28, 40, 46, 0.14);
}

.task-board-card.dragging {
  z-index: 10001 !important;
  cursor: grabbing;
  box-shadow: 0 16px 34px rgba(28, 40, 46, 0.2);
}

.task-list-row.dragging {
  opacity: 0.58;
}

.task-board-card textarea {
  min-height: 58px;
  resize: vertical;
}

.board-card-tool-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 28px;
}

.board-card-tool-head b {
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.todo-card-layout {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr);
  align-items: stretch;
  gap: 5px;
  min-width: 0;
}

.todo-select-handle {
  width: 16px;
  min-height: 54px;
  align-self: stretch;
  border: 1px solid transparent;
  border-radius: 6px;
  cursor: grab;
  background:
    radial-gradient(circle, #9aa4ad 1.2px, transparent 1.4px) center 8px / 6px 6px,
    transparent;
  opacity: 0.55;
}

.todo-select-handle:hover,
.todo-select-handle:focus-visible {
  opacity: 1;
  background-color: #eef2f5;
}

.todo-select-handle:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

.todo-card-content,
.todo-card-head {
  display: grid;
  min-width: 0;
}

.todo-card-content {
  gap: 3px;
}

.todo-title-display {
  min-width: 0;
  max-width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: #7a8490;
  font-size: 9px;
  font-weight: 750;
  line-height: 1.1;
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: text;
}

.todo-title-display:disabled {
  cursor: default;
}

.todo-title-input.task-title-input {
  min-width: 0;
  width: 100%;
  min-height: 18px;
  height: 18px;
  padding: 0 2px;
  border: 0;
  border-bottom: 1px solid transparent;
  border-radius: 0;
  background: transparent;
  color: #5f6974;
  font-size: 9px;
  font-weight: 750;
  line-height: 1.1;
}

.todo-title-input.task-title-input:focus {
  border-bottom-color: var(--line-strong);
  outline: 0;
}

.todo-list {
  display: grid;
  gap: 3px;
}

.todo-item {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  gap: 6px;
}

.todo-item input[type="checkbox"] {
  width: 14px;
  height: 14px;
  accent-color: var(--accent);
}

.todo-item input[type="text"] {
  min-height: 22px;
  border: 0;
  border-bottom: 1px solid transparent;
  border-radius: 0;
  padding: 0;
  background: transparent;
  font-size: 13px;
  line-height: 1.2;
}

.todo-item input[type="text"]:focus {
  border-bottom-color: var(--line-strong);
  outline: 0;
}

.todo-item.completed input[type="text"] {
  color: var(--muted);
  text-decoration: line-through;
}

.todo-item:has([data-todo-check]:checked) input[type="text"] {
  color: var(--muted);
  text-decoration: line-through;
}

.link-board-card {
  gap: 10px;
}

.link-board-card.has-link {
  width: max-content;
  min-width: 150px;
  max-width: 320px;
  min-height: 44px;
  padding: 8px 10px;
}

.link-board-card:not(.has-link) {
  width: 260px;
  min-height: 64px;
}

.image-board-card {
  padding: 0;
  overflow: visible;
  background: #fff;
}

.image-board-frame {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: 7px;
  background: #fff;
}

.image-board-frame img,
.image-board-empty {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: 7px;
  object-fit: contain;
}

.image-board-empty {
  display: grid;
  place-items: center;
  gap: 8px;
  color: var(--muted);
  font-weight: 850;
}

.board-image-resize {
  position: absolute;
  z-index: 4;
  background: transparent;
}

.board-image-resize.resize-n,
.board-image-resize.resize-s {
  left: 14px;
  right: 14px;
  height: 10px;
  cursor: ns-resize;
}

.board-image-resize.resize-n {
  top: -5px;
}

.board-image-resize.resize-s {
  bottom: -5px;
}

.board-image-resize.resize-e,
.board-image-resize.resize-w {
  top: 14px;
  bottom: 14px;
  width: 10px;
  cursor: ew-resize;
}

.board-image-resize.resize-e {
  right: -5px;
}

.board-image-resize.resize-w {
  left: -5px;
}

.board-image-resize.resize-se {
  right: -6px;
  bottom: -6px;
  width: 18px;
  height: 18px;
  cursor: nwse-resize;
}

.board-comment-panel {
  position: absolute;
  z-index: 10002;
  width: min(260px, calc(100% - 24px));
  display: grid;
  gap: 7px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f1f4fc;
  box-shadow: 0 18px 44px rgba(20, 28, 34, 0.22);
}

.board-comment-row {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  gap: 7px;
  align-items: start;
}

.board-comment-avatar {
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--comment-avatar, var(--accent));
  color: #fff;
  font-size: 9px;
  font-weight: 900;
}

.board-comment-row textarea {
  min-height: 28px;
  resize: vertical;
  border: 0;
  background: transparent;
  padding: 0;
  font-size: 12px;
  line-height: 1.25;
}

.board-comment-row textarea:focus {
  outline: 0;
}

.link-input-row {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-height: 52px;
}

.link-input-row .icon {
  color: var(--muted);
}

.link-input-row input {
  border: 0;
  background: transparent;
  padding: 0;
}

.link-input-row input:focus {
  outline: 0;
}

.link-preview {
  display: grid;
  grid-template-columns: 20px minmax(70px, max-content);
  gap: 8px;
  align-items: center;
}

.link-preview img {
  width: 18px;
  height: 18px;
  border-radius: 4px;
}

.link-favicon-placeholder {
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
}

.link-favicon-placeholder .icon {
  width: 14px;
  height: 14px;
}

.link-title-wrap {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  gap: 6px;
}

.link-title-display,
.link-preview input {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.link-title-display {
  min-width: 70px;
  max-width: 230px;
  color: var(--accent);
  font-size: 14px;
  font-weight: 900;
  text-decoration: none;
}

.link-title-display:hover {
  text-decoration: underline;
}

.link-preview input {
  width: min(210px, 36vw);
  border: 0;
  border-bottom: 1px solid transparent;
  border-radius: 0;
  background: transparent;
  padding: 0;
  color: var(--accent);
  font-weight: 850;
}

.link-preview input:focus {
  border-bottom-color: var(--line-strong);
  outline: 0;
}

.link-title-edit {
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: color-mix(in srgb, var(--muted) 70%, transparent);
  padding: 0;
}

.link-title-edit .icon {
  width: 11px;
  height: 11px;
}

.link-title-edit:hover {
  color: var(--muted);
  background: rgba(32, 43, 52, 0.06);
}

.comment-text-action {
  border: 0;
  background: transparent;
  color: var(--accent);
  padding: 0;
  font-size: 11px;
  font-weight: 850;
  line-height: 1.2;
  cursor: pointer;
}

.comment-text-action:hover {
  text-decoration: underline;
}

.comment-text-action:disabled {
  color: var(--muted);
  cursor: default;
  opacity: 0.55;
  text-decoration: none;
}

.task-list-compact {
  display: grid;
  gap: 4px;
}

.task-template-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0 0 8px;
  padding: 7px 8px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fbfcfd;
}

.task-template-picker,
.task-template-admin-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.task-template-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.task-template-bar select {
  width: min(220px, 34vw);
  min-height: 30px;
  padding: 3px 26px 3px 8px;
  font-size: 13px;
}

.task-template-bar .button.compact {
  min-height: 30px;
  padding: 4px 10px;
  font-size: 12px;
}

.task-list-bulk-bar {
  display: flex;
  justify-content: flex-end;
  margin: -2px 0 8px;
}

.task-list-bulk-bar label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.task-list-bulk-bar select {
  width: min(210px, 34vw);
  min-height: 30px;
  padding: 3px 26px 3px 8px;
  font-size: 13px;
}

.task-list-row {
  grid-template-columns: 34px minmax(120px, 1.2fr) minmax(140px, 1.4fr) 128px auto auto auto auto auto;
  align-items: center;
  gap: 6px;
  padding: 5px 6px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #f8fafb;
}

.task-list-row.unit-task-mode {
  grid-template-columns: 34px minmax(120px, 1.2fr) minmax(140px, 1.4fr) 128px auto auto auto auto;
}

.task-list-row.selected {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent) 38%, transparent);
  background: color-mix(in srgb, var(--accent) 7%, #ffffff 93%);
}

.task-sequence {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 22px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 10%, #ffffff 90%);
  color: var(--accent);
  font-size: 11px;
  font-weight: 900;
}

.task-list-drag-handle {
  cursor: grab;
  user-select: none;
}

.task-list-drag-handle:active {
  cursor: grabbing;
}

.task-list-drop-before {
  box-shadow: inset 0 3px 0 var(--accent);
}

.task-list-drop-after {
  box-shadow: inset 0 -3px 0 var(--accent);
}

.task-card-sequence {
  margin-right: 6px;
  vertical-align: middle;
}

.task-list-row .task-title-display {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-instruction-compact {
  min-height: 30px;
  padding: 4px 8px;
  border: 1px solid var(--line-strong);
  border-radius: 7px;
}

.task-list-row select {
  min-height: 30px;
  padding: 3px 7px;
}

.task-list-row .manual-time-control input {
  min-height: 30px;
}

.task-list-row .button,
.task-list-row .icon-button {
  min-height: 30px;
}

.task-row.locked {
  opacity: 0.72;
}

.task-row.locked textarea,
.task-row.locked select,
.task-row.locked input {
  background: #f4f6f7;
}

.task-top {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.task-board-card .task-top {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 3px 6px;
}

.task-board-card .task-title-block,
.task-board-card .task-meta {
  min-width: 0;
}

.task-board-card .task-meta {
  grid-column: 1 / -1;
}

.task-board-card.long-task-title .task-top {
  grid-template-columns: minmax(0, 1fr);
}

.task-board-card.long-task-title .task-status-chip {
  justify-self: end;
}

.task-title-display {
  display: block;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 13px;
  font-weight: 800;
  text-align: left;
  cursor: text;
}

.task-board-card .task-title-display {
  max-width: 100%;
  overflow-wrap: anywhere;
  line-height: 1.12;
}

.task-title-display:disabled {
  cursor: default;
}

.task-title-input {
  width: min(360px, 100%);
  min-height: 34px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 4px 8px;
  font-weight: 750;
}

.task-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.task-board-card .task-controls {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr) 34px;
  gap: 7px 8px;
  align-items: center;
  font-size: 14px;
}

.task-board-card .task-controls select {
  grid-column: 1;
  grid-row: 1;
  min-width: 0;
  width: 74px;
  max-width: 74px;
  overflow: hidden;
  text-overflow: clip;
}

.task-board-card .task-controls .manual-time-control {
  grid-column: 2 / 4;
  grid-row: 1;
  width: 100%;
  display: grid;
  grid-template-columns: 34px 54px minmax(0, 1fr);
  gap: 6px;
  align-items: center;
}

.task-board-card .task-controls .manual-time-control input {
  width: 50px;
}

.task-board-card .task-controls .icon-button,
.task-board-card .task-controls .button {
  min-height: 34px;
}

.task-board-card .task-controls .icon-button {
  width: 34px;
  flex-basis: 34px;
}

.task-board-card .task-controls [data-toggle-task-timer] {
  grid-column: 1;
  grid-row: 2;
  justify-self: start;
}

.task-board-card .task-controls [data-toggle-task-complete] {
  grid-column: 1 / 3;
  grid-row: 2;
  justify-self: stretch;
  min-width: 0;
  margin-left: 42px;
  padding-inline: 12px;
}

.task-board-card .task-controls [data-delete-task] {
  grid-column: 3;
  grid-row: 2;
  justify-self: end;
}

.manual-time-control {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.manual-time-control input {
  width: 58px;
  min-height: 34px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 4px 8px;
}

.manual-time-control span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border-radius: 999px;
  padding: 0 8px;
  font-size: 12px;
  background: var(--panel-2);
  color: #334047;
  font-weight: 650;
}

.pill.success {
  background: #dff0e8;
  color: var(--success);
}

.pill.warn {
  background: #f8ead8;
  color: var(--warning);
}

.pill.danger {
  background: #f7dede;
  color: var(--danger);
}

.task-board-card .task-status-chip {
  min-height: 20px;
  padding: 0 7px;
  font-size: 10.5px;
  line-height: 1;
}

.message-row {
  display: grid;
  gap: 3px;
  min-width: 0;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.activity-message-list > .message-row:not(.message-deleted) {
  grid-template-columns: minmax(0, 1fr);
  justify-self: start;
  width: fit-content;
  max-width: min(88%, 720px);
  text-align: left;
  border: 0;
  padding: 0;
  background: transparent;
  gap: 4px;
}

.activity-message-list .message-images { grid-template-columns: minmax(0, 1fr); }

.activity-message-list > .message-row.message-own { justify-self: end; }
.activity-message-list .message-bubble {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 3px;
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}
.activity-message-list .message-own > .message-bubble {
  background: color-mix(in srgb, #8064df 16%, var(--panel));
  border-color: color-mix(in srgb, #8064df 28%, var(--line));
}
.activity-message-list .message-head { gap: 2px 8px; color: var(--muted); padding-inline: 2px; }
.activity-message-list .message-head b { color: var(--ink); font-weight: 650; }
.activity-message-list .message-head time { font-size: 11px; }
.activity-message-list .message-own > .message-head { justify-content: flex-end; }
.message-actions {
  position: absolute;
  top: -28px;
  left: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 2px;
  width: max-content;
  max-width: 100%;
  padding: 3px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: 0 3px 12px rgba(20, 28, 34, .14);
  opacity: 0;
  pointer-events: none;
  transition: opacity 120ms ease;
}
.message-own .message-actions { left: auto; right: 0; }
.message-row:is(:hover, :focus-within, :has(.message-more-menu[open])) .message-actions { opacity: 1; pointer-events: auto; }
.message-row:has(.message-more-menu[open]) { position: relative; z-index: 3; }
.message-actions button { flex-shrink: 0; min-width: 28px; height: 28px; padding: 0 6px; border: 0; border-radius: 999px; background: transparent; color: var(--ink); font: inherit; font-size: 11px; font-weight: 650; text-decoration: none; cursor: pointer; }
.message-actions .message-quick-reaction { padding: 0; font-size: 16px; }
.message-actions button .icon { width: 14px; height: 14px; }
.message-actions button:is(:hover, [aria-pressed="true"]) { background: color-mix(in srgb, var(--accent) 12%, var(--panel)); }
.message-actions button:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.message-actions .message-delete-action:hover { color: var(--danger); }
.message-actions button:disabled { opacity: .5; cursor: wait; }
.message-actions-divider { align-self: stretch; width: 1px; margin: 4px 2px; background: var(--line); }
.message-more-menu { position: relative; flex-shrink: 0; }
.message-more-menu > summary { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; list-style: none; cursor: pointer; }
.message-more-menu > summary::-webkit-details-marker { display: none; }
.message-more-menu > summary .icon { width: 16px; height: 16px; }
.message-more-menu > summary:hover, .message-more-menu[open] > summary { background: color-mix(in srgb, var(--accent) 12%, var(--panel)); }
.message-more-menu > summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.message-more-panel { position: absolute; top: calc(100% + 8px); right: 0; display: grid; gap: 2px; width: max-content; padding: 4px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--panel); box-shadow: var(--shadow); }
.message-actions .message-more-panel button { display: flex; align-items: center; justify-content: flex-start; gap: 8px; width: 100%; height: 32px; padding: 0 8px; border-radius: 5px; font-size: 12px; text-align: left; }
.message-actions .message-more-panel .message-delete-action { color: var(--danger); }
@media (hover: none), (pointer: coarse) {
  .activity-message-list > .message-row:not(.message-deleted) { padding-bottom: 0; }
  .activity-message-list .message-bubble { padding-top: 10px; }
  .message-actions { position: static; grid-row: 1; opacity: 1; pointer-events: auto; margin-bottom: 6px; max-width: 100%; justify-self: start; }
  .message-own .message-actions { justify-self: end; }
}
@media (prefers-reduced-motion: reduce) { .message-actions { transition: none; } }

@media (max-width: 600px) {
  .activity-message-list > .message-row:not(.message-deleted) { max-width: 94%; }
}

.message-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
  flex-wrap: wrap;
}

.message-head b {
  font-size: 12px;
  min-width: 0;
  overflow-wrap: anywhere;
}

.message-emoji-action,
.message-delete-action,
.message-edit-action {
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--accent);
  font: inherit;
  font-size: 11px;
  font-weight: 850;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}

.message-emoji-action {
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: var(--muted);
  text-decoration: none;
}

.message-emoji-action .icon {
  width: 14px;
  height: 14px;
}

.message-emoji-action:hover,
.message-compose-emoji:hover,
.message-compose-attach:hover,
.message-compose-format:hover,
.message-compose-format.active,
.message-compose-format[aria-expanded="true"] {
  background: color-mix(in srgb, var(--accent) 10%, transparent);
  color: var(--accent);
}

.message-compose-wrap {
  position: relative;
}

.message-edit-wrap {
  position: relative;
}

.message-edit-format-scope {
  width: 100%;
}

.message-compose-editor,
.message-edit-editor {
  width: 100%;
  min-width: 0;
  min-height: 86px;
  max-height: min(50vh, 480px);
  overflow-y: auto;
  padding: 9px 116px 9px 11px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  font: inherit;
  line-height: 1.45;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.message-edit-editor {
  min-height: 72px;
  padding-right: 46px;
}

.message-compose-editor:focus,
.message-edit-editor:focus {
  border-color: var(--accent);
  outline: 2px solid color-mix(in srgb, var(--accent) 18%, transparent);
  outline-offset: 1px;
}

.message-compose-editor:empty::before {
  content: attr(data-placeholder);
  color: var(--muted);
  pointer-events: none;
}

.message-compose-emoji,
.message-compose-attach,
.message-compose-format {
  position: absolute;
  top: 9px;
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.message-compose-emoji {
  right: 9px;
}

.message-compose-attach {
  right: 77px;
}

.message-compose-format {
  right: 43px;
  gap: 0;
}

.message-edit-format {
  right: 9px;
}

.message-compose-format > span {
  font-size: 13px;
  font-weight: 850;
  line-height: 1;
}

.message-compose-format .icon {
  width: 10px;
  height: 10px;
  margin: 7px 0 0 -2px;
}

.message-compose-emoji .icon {
  width: 16px;
  height: 16px;
}

.message-format-toolbar {
  --message-format-color: #172126;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 3px;
  width: 100%;
  min-width: 0;
  min-height: 40px;
  margin-top: 6px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  overflow-x: auto;
}

.message-format-toolbar[hidden] {
  display: none;
}

.message-format-toolbar button,
.message-format-color {
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--ink);
  font-size: 15px;
  line-height: 1;
  cursor: pointer;
}

.message-format-toolbar button:hover,
.message-format-toolbar button.active,
.message-format-color:hover {
  background: color-mix(in srgb, var(--accent) 10%, transparent);
  color: var(--accent);
}

.message-format-toolbar button.active {
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 38%, var(--line));
}

.message-format-underline {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.message-format-strike {
  text-decoration: line-through;
  text-decoration-thickness: 2px;
}

.message-format-divider {
  flex: 0 0 1px;
  width: 1px;
  height: 22px;
  margin: 0 3px;
  background: var(--line);
}

.message-format-list-glyph {
  display: grid;
  grid-template-columns: 7px 13px;
  align-items: center;
  width: 20px;
  height: 18px;
}

.message-format-list-glyph i {
  color: currentColor;
  font-style: normal;
  font-size: 16px;
  line-height: 5px;
}

.message-format-list-glyph.numbers i {
  font-size: 7px;
  font-weight: 850;
  line-height: 5px;
}

.message-format-list-glyph b {
  width: 13px;
  height: 13px;
  background: repeating-linear-gradient(to bottom, currentColor 0 1px, transparent 1px 5px);
}

.message-format-color {
  position: relative;
  --message-format-color: #172126;
}

.message-format-color-group {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  flex: 0 0 auto;
}

.message-format-color.highlight {
  --message-format-color: #fff176;
}

.message-format-color > span {
  position: relative;
  z-index: 1;
  font-size: 14px;
  font-weight: 800;
}

.message-format-color.foreground::after {
  content: "";
  position: absolute;
  right: 7px;
  bottom: 5px;
  left: 7px;
  height: 3px;
  border-radius: 1px;
  background: var(--message-format-color);
}

.message-format-color.highlight > span {
  padding: 1px 3px;
  background: var(--message-format-color);
}

.message-format-color-options {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  flex: 0 0 auto;
}

.message-format-color-options[hidden] {
  display: none;
}

.message-format-toolbar .message-format-color-swatch {
  position: relative;
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  border: 1px solid color-mix(in srgb, var(--message-format-swatch) 70%, #172126);
  border-radius: 50%;
  background: var(--message-format-swatch);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.45);
}

.message-format-toolbar .message-format-color-swatch.reset {
  border-color: var(--line-strong, #95a1aa);
  background: #fff;
  box-shadow: none;
}

.message-format-toolbar .message-format-color-swatch.reset::after {
  content: "";
  position: absolute;
  left: 1px;
  top: 8px;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: #dc2626;
  transform: rotate(-45deg);
  transform-origin: center;
}

.message-format-toolbar .message-format-color-swatch:hover,
.message-format-toolbar .message-format-color-swatch:focus-visible {
  background: var(--message-format-swatch);
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

.message-format-toolbar .message-format-color-swatch.reset:hover,
.message-format-toolbar .message-format-color-swatch.reset:focus-visible,
.message-format-toolbar .message-format-color-swatch.reset.selected {
  background: #fff;
}

.message-format-toolbar .message-format-color-swatch.selected {
  background: var(--message-format-swatch);
  box-shadow: inset 0 0 0 2px #fff, 0 0 0 2px var(--accent);
}

.message-emoji-menu {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
  width: fit-content;
  max-width: 100%;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 8px 18px rgba(20, 28, 34, 0.1);
}

.compose-emoji-menu {
  margin-top: 6px;
}

.message-emoji-menu button {
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
}

.message-emoji-menu button:hover {
  background: color-mix(in srgb, var(--accent) 10%, transparent);
}

.message-row [data-message-body] {
  margin: 0;
  font-size: 13px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  word-break: break-word;
  user-select: text;
  cursor: text;
}

.message-row [data-message-body] > :first-child {
  margin-top: 0;
}

.message-row [data-message-body] > :last-child {
  margin-bottom: 0;
}

.message-row [data-message-body] ul,
.message-row [data-message-body] ol {
  margin: 4px 0;
  padding-left: 24px;
  white-space: normal;
}

.message-row [data-message-body] a {
  color: var(--accent);
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 2px;
  overflow-wrap: anywhere;
  word-break: break-word;
  cursor: pointer;
}

.message-images {
  display: grid;
  gap: 8px;
  margin-top: 6px;
}

:is(.message-body, .message-compose-editor, .message-edit-editor) table {
  border-collapse: collapse;
  table-layout: fixed;
  width: 100%;
  margin: 8px 0;
  font: inherit;
  color: inherit;
  background: transparent;
}

:is(.message-body, .message-compose-editor, .message-edit-editor) :is(td, th) {
  border: 1px solid var(--line-strong, #89959e);
  padding: 6px 8px;
  min-width: 32px;
  vertical-align: top;
  overflow-wrap: anywhere;
  font-family: inherit;
  font-size: inherit;
  text-align: inherit;
  background: transparent;
  color: inherit;
}

.message-table-size {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
}

.message-table-size input {
  width: 48px;
  min-width: 0;
  padding: 3px;
}

.message-image-link {
  display: block;
  white-space: normal;
  line-height: 0;
  width: fit-content;
  max-width: min(100%, 520px);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: transparent;
  box-shadow: 0 8px 22px rgba(20, 28, 34, 0.08);
  cursor: zoom-in;
}

.message-image-link img {
  display: block;
  max-width: min(100%, 520px);
  max-height: 320px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.message-inline-image {
  position: relative;
  display: block;
  width: fit-content;
  max-width: min(100%, 520px);
  min-width: 42px;
  min-height: 34px;
  margin: 7px 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 8px 22px rgba(20, 28, 34, 0.08);
  user-select: none;
}

.message-inline-image.pending {
  background: linear-gradient(90deg, #f3f5f7, #fff, #f3f5f7);
  background-size: 200% 100%;
  animation: message-image-loading 1.1s linear infinite;
}

.message-inline-image img {
  display: block;
  max-width: 100%;
  max-height: 260px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.message-compose-editor .message-inline-image,
.message-edit-editor .message-inline-image {
  max-width: min(100%, 320px);
}

.message-compose-editor img,
.message-edit-editor img {
  display: block;
  max-width: min(100%, 320px);
  max-height: 180px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.message-inline-image button {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 25px;
  height: 25px;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(23, 33, 38, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--ink);
  font-size: 17px;
  line-height: 1;
  cursor: pointer;
}

.message-inline-image button:hover {
  color: var(--danger);
}

.message-row [data-message-body] .message-inline-image-link {
  margin: 7px 0;
  cursor: zoom-in;
}

@keyframes message-image-loading {
  to { background-position: -200% 0; }
}

.message-compose-images {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.message-compose-image {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) 26px;
  align-items: center;
  gap: 8px;
  max-width: min(100%, 360px);
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.message-compose-image img {
  display: block;
  max-width: 52px;
  max-height: 42px;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 5px;
}

.message-compose-image span {
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.message-compose-image button {
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
}

.message-compose-image button:hover {
  border-color: color-mix(in srgb, var(--danger) 45%, var(--line));
  color: var(--danger);
}

.message-image-preview-overlay {
  z-index: 180;
}

.message-image-preview-dialog {
  width: fit-content;
  max-width: calc(100vw - 40px);
  max-height: calc(100vh - 40px);
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #101820;
  box-shadow: var(--shadow);
}

.message-image-preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  color: #fff;
}

.message-image-preview-header b {
  min-width: 0;
  overflow: hidden;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.message-image-preview-header div {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.message-image-preview-dialog > img {
  display: block;
  max-width: calc(100vw - 64px);
  max-height: calc(100vh - 120px);
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 6px;
}

.message-reactions {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 2px;
}

.message-reactions button {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f7f9fb;
  padding: 2px 7px;
  color: var(--text);
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
}

.message-reactions button.active {
  border-color: color-mix(in srgb, var(--accent) 55%, var(--line));
  background: color-mix(in srgb, var(--accent) 12%, #ffffff);
  color: var(--accent);
}

.message-reactions span {
  font-size: 14px;
  line-height: 1;
}

.message-reactions b {
  font-size: 10px;
}

.message-notified {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  max-width: 100%;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.message-notified .icon {
  width: 13px;
  height: 13px;
}

.message-row textarea {
  width: 100%;
  min-height: 72px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 8px 10px;
  font: inherit;
  color: var(--ink);
  background: #fff;
}

.toast-stack {
  position: fixed;
  right: 16px;
  bottom: 16px;
  display: grid;
  gap: 8px;
  z-index: 30;
}

.notification-popups {
  position: fixed;
  right: 16px;
  top: 76px;
  display: grid;
  gap: 10px;
  z-index: 90;
  pointer-events: none;
}

.notification-popup {
  width: min(360px, calc(100vw - 32px));
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 12px;
  border: 1px solid color-mix(in srgb, var(--accent) 58%, var(--line-strong));
  border-left: 5px solid var(--accent);
  border-radius: var(--radius);
  background: #fffdf5;
  box-shadow: var(--shadow);
  color: var(--ink);
  pointer-events: auto;
  text-align: left;
  font: inherit;
}

.notification-popup.clickable {
  cursor: pointer;
}

.notification-popup.clickable:hover {
  border-color: var(--accent);
  box-shadow: 0 18px 44px rgba(20, 28, 34, 0.22);
}

.notification-popup.clickable:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent) 28%, transparent);
  outline-offset: 2px;
}

.notification-popup .icon {
  color: var(--accent);
}

.notification-popup b,
.notification-popup p {
  margin: 0;
}

.notification-popup p {
  color: var(--muted);
  font-size: 13px;
  margin-top: 3px;
}

.notification-list {
  display: grid;
  gap: 8px;
}

.notification-pref-list {
  display: grid;
  gap: 10px;
}

.notification-desktop-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  margin: 12px 0 16px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.notification-desktop-row > div {
  display: grid;
  gap: 3px;
}

.notification-desktop-row span,
.notification-desktop-row small {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.notification-defaults {
  display: grid;
  gap: 8px;
  margin: 12px 0 16px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

.notification-defaults ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

.desktop-notification-steps {
  display: grid;
  gap: 8px;
  margin: 12px 0;
  padding-left: 22px;
  color: var(--ink);
  line-height: 1.45;
}

.notification-pref-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.notification-pref-copy {
  display: grid;
  gap: 3px;
}

.notification-pref-copy span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.notification-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  padding: 10px;
}

.notification-row.unread {
  border-color: var(--accent);
  box-shadow: inset 4px 0 0 var(--accent);
}

.notification-row b,
.notification-row p {
  margin: 0;
}

.notification-row p,
.notification-row span {
  color: var(--muted);
  font-size: 13px;
}

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

.notifications-dialog [data-dialog-drag-handle] { touch-action: none; user-select: none; }
.notification-tabs.segmented { display: grid; grid-template-columns: 1fr 1fr; flex-shrink: 0; margin: 0 20px 12px; }
.notification-tabs button { min-width: 0; min-height: 44px; white-space: normal; line-height: 1.25; font-size: 14px; padding: 8px 10px; }
.notification-tabs b { font-variant-numeric: tabular-nums; margin-left: 5px; }
.tracker-theme-scope.tracker-theme-dark .notification-tabs.segmented button.active { background: #dfe8ed; color: #172126; }
.tracker-theme-scope.tracker-theme-dark .notification-tabs.segmented button.active b { color: inherit; }
.completion-scan-toolbar { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; margin-bottom: 12px; }
.completion-scan-toolbar small { color: var(--muted); flex: 1; min-width: 0; overflow-wrap: anywhere; }
.completion-scan-toolbar .button { flex-shrink: 0; }
.completion-scan-toolbar [data-scan-completion-suggestions] { width: 34px; height: 34px; flex: 0 0 34px; }
.completion-scan-error { color: var(--danger, #ad3535); overflow-wrap: anywhere; }
.completion-scan-error:empty { display: none; }
.completion-suggestion-copy { min-width: 0; overflow-wrap: anywhere; }
.completion-suggestion-copy small { color: var(--muted); }
.completion-suggestion-row .icon-button { width: 34px; height: 34px; flex: 0 0 34px; }
.completion-pagination { margin-top: 16px; margin-bottom: 0; }
.completion-notification-settings { border-bottom: 1px solid var(--line); padding-bottom: 12px; margin-bottom: 16px; }
.completion-notification-settings h3 { margin-top: 0; }
@media (max-width: 540px) {
  .notification-tabs.segmented { margin-right: 12px; margin-left: 12px; }
  .completion-suggestion-row { grid-template-columns: minmax(0, 1fr); }
  .completion-suggestion-row .notification-row-actions { justify-content: flex-end; }
}

.toast {
  background: #172126;
  color: #fff;
  border-radius: var(--radius);
  padding: 10px 12px;
  min-width: 220px;
  box-shadow: var(--shadow);
  font-size: 13px;
}

.reports {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 16px;
}

.report-dialog .dialog-body {
  background: #dfe5ea;
}

.report-controls {
  display: grid;
  grid-template-columns: minmax(145px, 1fr) minmax(145px, 1fr) minmax(110px, 0.6fr) minmax(135px, 0.7fr) auto;
  gap: 12px;
  align-items: end;
  margin-bottom: 16px;
}

.report-usage-option-control {
  grid-column: 1 / -2;
  align-self: center;
  min-height: 34px;
}

.report-entity-filter {
  grid-column: 1 / -2;
}

.report-entity-filter > small {
  display: block;
  margin-top: 4px;
}

.report-dialog-footer {
  justify-content: space-between;
  align-items: end;
}

.report-logo-control .inline-fields {
  grid-template-columns: minmax(96px, 1fr) auto auto;
}

.report-dialog-footer .report-logo-control {
  width: min(100%, 360px);
}

.dialog-footer-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.report-preview-shell {
  overflow: auto;
  padding: 18px;
  background: #cbd3da;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.management-report-page {
  width: min(100%, 900px);
  min-height: 1040px;
  margin: 0 auto;
  padding: 44px;
  background: #fff;
  color: var(--ink);
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.18);
}

.management-report-header {
  display: grid;
  gap: 36px;
  align-items: start;
  padding-bottom: 28px;
  margin-bottom: 28px;
  border-bottom: 2px solid var(--ink);
}

.management-report-header.has-logo {
  grid-template-columns: minmax(160px, 1fr) minmax(240px, 1.2fr) minmax(160px, 1fr);
}

.management-report-header.no-logo {
  grid-template-columns: minmax(0, 1fr) auto;
}

.management-report-header.has-logo .management-report-title {
  text-align: center;
}

.management-report-logo {
  display: block;
  max-width: 190px;
  max-height: 58px;
  object-fit: contain;
}

.management-report-header span,
.management-report-header em {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 750;
  text-transform: uppercase;
}

.management-report-header h1 {
  margin: 8px 0 0;
  font-size: 34px;
}

.management-report-header strong {
  display: block;
}

.management-report-meta {
  text-align: right;
}

.management-report-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

.management-report-summary div {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 14px;
  background: #f8fafb;
}

.management-report-summary b {
  display: block;
  font-size: 24px;
}

.management-report-summary span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  text-transform: uppercase;
}

.management-report-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.management-report-table th,
.management-report-table td {
  border-bottom: 1px solid var(--line);
  padding: 9px 8px;
  text-align: left;
  vertical-align: top;
}

.management-report-table th {
  color: var(--muted);
  background: #f6f7f8;
  font-size: 10px;
  text-transform: uppercase;
}

.management-report-table .right {
  text-align: right;
}

.management-report-table span {
  color: var(--muted);
  font-size: 11px;
}

.post-delivery-intro {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

.post-delivery-intro div,
.post-delivery-master,
.post-delivery-media {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
}

.post-delivery-intro div {
  padding: 12px;
  background: #f8fafb;
}

.post-delivery-intro b {
  display: block;
  font-size: 18px;
}

.post-delivery-intro span,
.post-delivery-master-head span,
.post-delivery-meta dt,
.post-delivery-media-head span,
.post-delivery-no-tree {
  color: var(--muted);
  font-size: 11px;
}

.post-delivery-intro span,
.post-delivery-meta dt {
  font-weight: 750;
  text-transform: uppercase;
}

.post-delivery-list {
  display: grid;
  gap: 14px;
}

.post-delivery-master {
  padding: 14px;
  break-inside: avoid;
}

.post-delivery-master-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
}

.post-delivery-master-head h2 {
  margin: 3px 0 0;
  font-size: 18px;
}

.post-delivery-master-head strong {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  background: #eef3f6;
  font-size: 12px;
}

.post-delivery-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 12px 0;
}

.post-delivery-meta div {
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #fbfcfd;
}

.post-delivery-meta dt,
.post-delivery-meta dd {
  margin: 0;
}

.post-delivery-meta dd {
  margin-top: 2px;
  font-size: 12px;
  font-weight: 750;
}

.post-delivery-media-list {
  display: grid;
  gap: 10px;
}

.post-delivery-media {
  padding: 10px;
  background: #fbfcfd;
}

.post-delivery-media-head {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  margin-bottom: 8px;
}

.post-delivery-media-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #eef3f6;
  color: #344150;
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0;
}

.post-delivery-media-head b,
.post-delivery-media-head span {
  display: block;
  min-width: 0;
}

.delivery-directory-tree {
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #fff;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 11px;
}

.delivery-directory-tree ul {
  margin: 0;
  padding-left: 16px;
  list-style: none;
  border-left: 1px solid #d8dee2;
}

.delivery-directory-tree > ul {
  padding-left: 0;
  border-left: 0;
}

.delivery-directory-tree li {
  position: relative;
  margin: 3px 0;
}

.delivery-directory-tree li::before {
  content: "";
  position: absolute;
  top: 0.72em;
  left: -14px;
  width: 10px;
  border-top: 1px solid #d8dee2;
}

.delivery-directory-tree > ul > li::before {
  display: none;
}

.delivery-directory-tree span::before {
  content: "□";
  display: inline-block;
  width: 14px;
  color: var(--muted);
}

.delivery-directory-tree .is-folder::before {
  content: "▸";
}

.post-delivery-empty,
.post-delivery-no-tree {
  margin: 0;
  padding: 10px;
  border: 1px dashed var(--line);
  border-radius: 5px;
  background: #fbfcfd;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

td input,
td select {
  width: 100%;
  min-height: 34px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 6px 8px;
  background: #fff;
}

th,
td {
  text-align: left;
  border-bottom: 1px solid var(--line);
  padding: 9px 7px;
  vertical-align: top;
}

th {
  color: var(--muted);
  font-size: 12px;
  background: #fbfcfc;
}

.quote-total-foot th {
  font-size: 13px;
  font-weight: 800;
}

.quote-total-foot .icon {
  width: 14px;
  height: 14px;
  vertical-align: -2px;
}

.quote-total-match th {
  color: var(--success);
  background: #f0faf4;
}

.quote-total-mismatch th {
  color: var(--danger);
  background: #fff5f5;
}

.quote-total-combined th {
  color: var(--ink);
  background: #f3f6f8;
}

.quote-mismatch-warning {
  border-color: rgba(181, 57, 59, 0.28);
  background: #fff5f5;
  color: var(--danger);
}

.right {
  text-align: right;
}

.hidden {
  display: none !important;
}

.context-menu {
  position: fixed;
  z-index: 160;
  min-width: 220px;
  background: var(--panel);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 6px;
}

.context-menu.has-time-editor {
  width: 304px;
}

.context-time-editor {
  display: grid;
  gap: 8px;
  padding: 8px;
  margin-bottom: 5px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #f8fafc;
}

.context-time-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.context-time-heading b {
  font-size: 12px;
  font-weight: 850;
  color: #172126;
}

.context-time-heading span {
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.context-time-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.context-time-grid label {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.context-time-grid span {
  color: #37444b;
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.context-time-grid input {
  width: 100%;
  min-width: 0;
  height: 30px;
  padding: 3px 6px;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  background: #fff;
  color: #172126;
  font: inherit;
  font-size: 12px;
}

.context-time-editor .context-time-apply {
  min-height: 30px;
  justify-content: center;
  background: #fff;
  border: 1px solid var(--line-strong);
  font-size: 12px;
  font-weight: 850;
}

.context-menu button {
  width: 100%;
  min-height: 34px;
  display: flex;
  align-items: center;
  gap: 8px;
  border-radius: 6px;
  background: transparent;
  color: var(--ink);
  padding: 0 10px;
  text-align: left;
}

.context-menu button:hover {
  background: var(--panel-2);
}

.tag-editor-row {
  display: grid;
  grid-template-columns: 44px 1fr auto auto;
  gap: 8px;
  align-items: center;
}

[data-stage-tags-form] .tag-editor-row { grid-template-columns: 44px minmax(0, 1fr); }
[data-stage-tags-form] > button { margin-top: 12px; }

.room-editor-row {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
  display: grid;
  gap: 12px;
  background: var(--panel);
}

.room-assignment-dialog {
  width: min(920px, calc(100vw - 36px));
}

.resource-groups-dialog {
  width: min(1120px, calc(100vw - 36px));
  height: min(720px, calc(100vh - 36px));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  overflow: hidden;
}

.departments-dialog {
  width: min(1080px, calc(100vw - 36px));
  height: min(720px, calc(100vh - 36px));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  overflow: hidden;
}

.departments-body {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(240px, 0.7fr) minmax(520px, 1.6fr);
  gap: 12px;
  overflow: hidden;
}

.department-maintenance,
.department-assignments {
  min-height: 0;
  margin: 0;
  overflow: hidden;
}

.department-maintenance {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.department-assignments {
  display: flex;
  flex-direction: column;
}

.department-assignments > .section-title {
  flex-shrink: 0;
}

.department-access-heading {
  align-items: center;
}

.department-access-heading h3 {
  margin: 0;
}

.department-help-button {
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  min-height: 30px;
  padding: 0;
  border-radius: 50%;
  font-weight: 800;
}

.department-help-button[data-tooltip]:hover::after {
  left: auto;
  right: 0;
  transform: none;
}

.department-help-button[aria-expanded="true"]::after {
  display: none;
}

.department-access-help {
  flex-shrink: 0;
  max-height: 240px;
  overflow: auto;
  padding: 10px 0;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.department-access-help:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}

.department-access-help dl,
.department-access-help p {
  margin: 0 0 10px;
}

.department-access-help dt {
  font-weight: 700;
}

.department-access-help dd {
  margin: 0 0 8px;
}

.department-name-list,
.department-user-table-wrap {
  min-height: 0;
  overflow: auto;
}

.department-name-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 36px;
  gap: 6px;
  margin-bottom: 6px;
}

.department-name-row input,
.department-user-table select {
  width: 100%;
  min-height: 36px;
  padding: 7px 9px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
}

.department-user-table {
  table-layout: fixed;
}

.department-user-table th:first-child,
.department-user-table td:first-child {
  width: 28%;
}

.department-user-table th:last-child,
.department-user-table td:last-child {
  width: 36%;
}

[data-department-visible-selection] {
  margin-top: 6px;
}

.department-included,
.department-extra-label {
  display: block;
  margin: 6px 0 4px;
  font-size: 12px;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.department-extra-label {
  font-weight: 700;
}

.department-included[hidden],
[data-department-visible-selection] label:has(input:disabled) {
  display: none;
}

.department-user-table .multi-select-dropdown {
  min-width: 0;
  width: 100%;
}

.department-user-table .multi-select-dropdown summary span {
  overflow-wrap: anywhere;
  white-space: normal;
}

.department-user-table .multi-select-menu {
  position: static;
  margin-top: 4px;
  max-height: 180px;
  box-shadow: none;
}

.department-user-table .multi-select-menu label {
  grid-template-columns: 18px minmax(0, 1fr);
  overflow-wrap: anywhere;
}

.department-user-table td {
  overflow: visible;
  vertical-align: top;
}

.department-user-table td > small {
  display: block;
  margin-top: 2px;
  color: var(--muted);
}

.department-user-table .multi-select-dropdown[open] {
  z-index: 90;
}

.schedule-ui-settings-dialog {
  width: min(620px, calc(100vw - 36px));
}

.schedule-ui-settings-body {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(210px, 0.75fr);
  gap: 12px;
}

.schedule-ui-settings-body .panel-block {
  margin: 0;
}

.schedule-ui-settings-body h3 {
  margin: 0 0 10px;
}

.schedule-view-order-list {
  display: grid;
  gap: 6px;
}

.schedule-view-order-row {
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 5px 6px 5px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
}

.schedule-view-order-row label,
.schedule-view-order-row > div {
  display: flex;
  align-items: center;
  gap: 8px;
}

.schedule-view-order-row input {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
}

.schedule-view-order-row b {
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  background: #f4f6f8;
}

@media (max-width: 820px) {
  .departments-body,
  .schedule-ui-settings-body {
    grid-template-columns: 1fr;
    overflow: auto;
  }

  .departments-body {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: max-content max-content;
    align-content: start;
  }

  .department-maintenance,
  .department-assignments {
    display: block;
    overflow: visible;
  }

  .department-name-list,
  .department-user-table-wrap {
    overflow: visible;
  }
}

@media (max-width: 600px) {
  .department-user-table-wrap {
    overflow: visible;
  }

  .department-user-table thead {
    display: none;
  }

  .department-user-table tbody,
  .department-user-table tr,
  .department-user-table td {
    display: block;
  }

  .department-user-table tr {
    padding: 10px 0;
    border-bottom: 1px solid var(--line);
  }

  .department-user-table td,
  .department-user-table td:first-child,
  .department-user-table td:last-child {
    width: 100%;
    padding: 6px 0;
    border: 0;
  }

  .department-user-table td:nth-child(2)::before,
  .department-user-table td:nth-child(3)::before {
    display: block;
    margin-bottom: 4px;
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
  }

  .department-user-table td:nth-child(2)::before { content: "Member of"; }
  .department-user-table td:nth-child(3)::before { content: "Can view"; }
}

.resource-groups-body {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(210px, 0.8fr) minmax(210px, 0.8fr) minmax(300px, 1.4fr);
  gap: 0;
  padding: 0;
  overflow: hidden;
  border-top: 1px solid var(--line);
}

.resource-group-editor-column {
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  border-right: 1px solid var(--line);
  background: #f8fafb;
}

.resource-group-editor-column:last-child {
  border-right: 0;
}

.resource-group-editor-head {
  position: relative;
  z-index: 3;
  min-height: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 10px;
  background: #f2f5f7;
  border-bottom: 1px solid var(--line);
}

.resource-groups-dialog .resource-group-editor-column:has(.resource-group-editor-head [data-tooltip]:hover) {
  position: relative;
  z-index: 20;
}

.resource-groups-dialog .resource-group-editor-head [data-tooltip]:hover::after {
  z-index: 220;
}

.resource-group-editor-head h3,
.resource-group-editor-head p {
  margin: 0;
}

.resource-group-editor-head p {
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
}

.resource-group-editor-head > div:last-child {
  display: flex;
  gap: 4px;
}

.resource-group-types-head {
  display: grid;
  align-content: center;
  gap: 6px;
}

.resource-group-resources-head {
  grid-template-columns: minmax(0, auto) minmax(132px, 190px);
}

.resource-group-resources-heading {
  min-width: 0;
  display: block !important;
}

.resource-group-resource-search {
  min-width: 0;
  height: 32px;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  gap: 4px;
  padding: 0 7px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  background: #fff;
  color: var(--muted);
}

.resource-group-resource-search .icon {
  width: 15px;
  height: 15px;
}

.resource-group-resource-search input {
  min-width: 0;
  width: 100%;
  height: 28px;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 11px;
}

.resource-group-types-title {
  min-width: 0;
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.resource-group-types-title > div {
  display: flex;
  align-items: center;
  gap: 4px;
}

.resource-group-select-all {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 750;
  cursor: pointer;
}

.resource-group-select-all input,
.resource-group-type-checkbox {
  width: 14px;
  height: 14px;
  margin: 0;
  accent-color: var(--accent);
}

.resource-group-move-button {
  min-height: 28px;
  padding: 3px 7px;
}

.resource-group-move-button .icon {
  width: 14px;
  height: 14px;
}

.resource-group-move-controls {
  min-width: 0;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 5px;
}

.resource-group-move-controls select {
  min-width: 0;
  min-height: 28px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  padding: 3px 24px 3px 7px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 11px;
}

.resource-group-editor-list,
.resource-group-resource-list {
  min-height: 0;
  overflow-y: auto;
  padding: 8px;
}

.resource-group-resource-list {
  padding: 0 8px 8px;
}

.resource-group-resource-section {
  display: grid;
}

.resource-group-resource-section[hidden],
.resource-group-resource[hidden],
.resource-group-search-empty[hidden] {
  display: none;
}

.resource-group-resource-section-head {
  position: sticky;
  top: 0;
  z-index: 2;
  min-height: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 5px 8px;
  border-bottom: 1px solid var(--line-strong);
  background: #eef2f5;
  color: #44515e;
  font-size: 11px;
  font-weight: 800;
}

.resource-group-resource-section-head small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 750;
}

.resource-group-resource-section-actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.resource-group-resource-section-actions .icon-button {
  width: 24px;
  height: 24px;
  min-height: 24px;
  border-color: transparent;
  background: transparent;
}

.resource-group-resource-section-actions .icon-button:hover,
.resource-group-resource-section-actions .icon-button:focus-visible {
  border-color: var(--line-strong);
  background: #fff;
}

.resource-group-resource-section-actions .icon {
  width: 14px;
  height: 14px;
}

.resource-groups-quick-overlay {
  position: fixed;
  inset: 0;
  z-index: 240;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(12, 18, 22, 0.3);
}

.resource-groups-quick-dialog {
  width: min(560px, calc(100vw - 40px));
  max-height: calc(100vh - 40px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  overflow: hidden;
  box-shadow: 0 22px 60px rgba(12, 18, 22, 0.28);
}

.resource-groups-quick-dialog .dialog-header > div {
  min-width: 0;
}

.resource-groups-quick-dialog .dialog-header p {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.resource-groups-quick-body {
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  overflow-y: auto;
}

.resource-groups-quick-body .field {
  min-width: 0;
}

.resource-groups-quick-body .field input,
.resource-groups-quick-body .field select {
  width: 100%;
}

.resource-groups-quick-password {
  grid-column: 1 / -1;
}

@media (max-width: 620px) {
  .resource-groups-quick-body {
    grid-template-columns: 1fr;
  }

  .resource-groups-quick-password {
    grid-column: auto;
  }
}

.resource-group-editor-item {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 6px;
  min-height: 42px;
  margin-bottom: 5px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
}

.resource-group-editor-item.resource-group-type-item {
  grid-template-columns: 16px minmax(0, 1fr) 24px;
}

.resource-group-editor-item.selected {
  border-color: var(--accent);
  box-shadow: inset 3px 0 0 var(--accent);
}

.resource-group-edit-name {
  position: relative;
  z-index: 1;
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--muted);
  opacity: 0.62;
  cursor: pointer;
}

.resource-group-edit-name:hover,
.resource-group-edit-name:focus-visible {
  background: color-mix(in srgb, var(--accent) 8%, #fff);
  color: var(--accent);
  opacity: 1;
  outline: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
}

.resource-group-edit-name .icon {
  width: 13px;
  height: 13px;
}

.resource-group-item-name {
  min-width: 0;
  overflow: hidden;
  padding: 4px 6px;
  color: var(--ink);
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.resource-group-editor-item input,
.resource-group-lock {
  position: relative;
  z-index: 1;
}

.resource-group-editor-item input {
  min-width: 0;
  min-height: 30px;
  padding: 4px 6px;
  border: 1px solid transparent;
  border-radius: 4px;
  background: transparent;
  font: inherit;
  font-weight: 750;
}

.resource-group-editor-item .resource-group-type-checkbox {
  min-width: 14px;
  min-height: 14px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  cursor: pointer;
}

.resource-group-type-item:not(:has(input[data-resource-type-name])) {
  cursor: grab;
}

.resource-group-type-item.dragging {
  opacity: 0.48;
  cursor: grabbing;
}

.resource-group-editor-item.accepts-type-drop {
  transition: border-color 100ms ease, background 100ms ease, box-shadow 100ms ease;
}

.resource-group-editor-item.drop-target {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 10%, #fff);
  box-shadow: inset 0 0 0 1px var(--accent);
}

.resource-group-editor-item input:not([readonly]):focus {
  border-color: var(--accent);
  background: #fff;
  outline: none;
}

.resource-group-lock {
  color: var(--muted);
  font-size: 10px;
  font-weight: 750;
}

.resource-group-resource {
  display: grid;
  grid-template-columns: auto 30px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 6px 8px;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}

.resource-group-resource.selected {
  background: color-mix(in srgb, var(--accent) 6%, #fff);
}

.resource-group-resource input {
  width: 15px;
  height: 15px;
  margin: 0;
}

.resource-kind-icon {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #fff;
  color: #53616e;
}

.resource-kind-icon .icon {
  width: 16px;
  height: 16px;
}

.resource-group-resource > span:last-child {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.resource-group-resource strong,
.resource-group-resource small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.resource-group-resource small {
  color: var(--muted);
}

.room-editor-main {
  display: grid;
  grid-template-columns: 20px minmax(160px, 1fr) minmax(120px, 0.55fr) auto;
  gap: 8px;
  align-items: center;
}

.room-editor-main input,
.room-assignment-row input,
.room-assignment-row select {
  min-height: 36px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 6px 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

.room-assignment-section {
  display: grid;
  gap: 8px;
  padding-left: 28px;
}

.room-assignment-section h4 {
  margin: 0 0 2px;
  font-size: 0.95rem;
}

.room-assignment-section p {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.section-title.tight {
  align-items: end;
}

.activity-notes-actions {
  display: flex;
  align-items: end;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.review-notes-order-field {
  display: grid;
  gap: 3px;
  min-width: 104px;
}

.review-notes-order-field span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.review-notes-order-field select {
  min-height: 34px;
  padding: 5px 28px 5px 9px;
  font-size: 13px;
}

.activity-notes-sync-button {
  min-height: 28px;
  padding: 0 8px;
  font-size: 11px;
  font-weight: 750;
}

.activity-notes-sync-button .icon {
  width: 13px;
  height: 13px;
}

.activity-review-workspace {
  display: grid;
  grid-template-columns: minmax(300px, 0.95fr) minmax(320px, 1.05fr);
  gap: 12px;
  align-items: start;
}

.activity-review-player-panel,
.activity-review-comments-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 12px;
  min-width: 0;
}

.activity-review-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.activity-review-panel-head b {
  font-size: 14px;
  line-height: 1.2;
}

.activity-review-panel-head span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.activity-review-version-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: end;
  margin-bottom: 10px;
}

.activity-review-version-row label {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.activity-review-version-row label span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.activity-review-version-row select {
  min-height: 34px;
  padding: 5px 28px 5px 9px;
  font-size: 13px;
}

.activity-review-open-link {
  min-height: 34px;
  white-space: nowrap;
}

.activity-review-player-frame {
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 16 / 9;
  min-height: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #111923;
}

.activity-review-player-video,
.activity-review-player-embed,
.activity-review-player-poster,
.activity-review-player-poster img {
  display: block;
  width: 100%;
  height: 100%;
}

.activity-review-player-video,
.activity-review-player-poster img {
  object-fit: contain;
}

.activity-review-player-shell {
  position: relative;
  width: 100%;
  height: 100%;
  min-width: 0;
  background: #050b12;
}

.activity-review-player-shell .activity-review-player-video {
  position: absolute;
  inset: 0;
}

.activity-review-player-controls {
  position: absolute;
  right: 8px;
  bottom: 8px;
  left: 8px;
  display: grid;
  grid-template-columns: 26px auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 6px;
  min-width: 0;
  padding: 4px 6px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 7px;
  background: rgba(5, 10, 17, 0.74);
  color: #eef5ff;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(10px);
  opacity: 1;
  transform: translateY(0);
  transition: opacity 160ms ease, transform 160ms ease;
}

.activity-review-player-shell.is-playing.controls-idle:not(:focus-within) .activity-review-player-controls {
  pointer-events: none;
  opacity: 0;
  transform: translateY(7px);
}

.activity-review-player-control-button,
.activity-review-player-loop {
  display: inline-grid;
  place-items: center;
  min-width: 0;
  min-height: 0;
  border: 0;
  border-radius: 6px;
  color: #eef5ff;
  background: rgba(255, 255, 255, 0.1);
  cursor: pointer;
}

.activity-review-player-control-button {
  width: 26px;
  height: 24px;
  padding: 0;
}

.activity-review-player-control-button .icon {
  width: 14px;
  height: 14px;
}

.activity-review-player-loop {
  height: 24px;
  padding: 0 8px;
  font-size: 10px;
  font-weight: 800;
}

.activity-review-player-control-button:hover,
.activity-review-player-loop:hover,
.activity-review-player-loop.active {
  background: var(--accent);
  color: #fff;
}

.activity-review-player-time {
  min-width: 30px;
  color: #d9e0e7;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
}

.activity-review-player-scrub {
  --review-player-progress: 0%;
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  min-width: 42px;
  height: 14px;
  margin: 0;
  background: transparent;
  color: var(--accent);
  cursor: pointer;
}

.activity-review-player-scrub::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(
    to right,
    var(--accent) 0 var(--review-player-progress),
    rgba(255, 255, 255, 0.9) var(--review-player-progress) 100%
  );
}

.activity-review-player-scrub::-webkit-slider-thumb {
  width: 8px;
  height: 8px;
  margin-top: -2px;
  border: 0;
  border-radius: 999px;
  background: var(--accent);
  -webkit-appearance: none;
  appearance: none;
}

.activity-review-player-scrub::-moz-range-track {
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
}

.activity-review-player-scrub::-moz-range-progress {
  height: 4px;
  border-radius: 999px;
  background: var(--accent);
}

.activity-review-player-scrub::-moz-range-thumb {
  width: 8px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: var(--accent);
}

.activity-review-player-scrub:focus-visible {
  outline: 2px solid rgba(98, 72, 199, 0.55);
  outline-offset: 2px;
}

.activity-review-player-scrub:disabled {
  cursor: default;
  opacity: 0.48;
}

.activity-review-player-embed {
  border: 0;
}

.activity-review-player-poster {
  display: grid;
  place-items: center;
  background: #111923;
}

.activity-review-player-empty {
  display: grid;
  place-items: center;
  gap: 8px;
  width: 100%;
  height: 100%;
  min-height: 0;
  padding: 18px;
  color: #d9e0e7;
  text-align: center;
}

.activity-review-player-empty .icon {
  width: 24px;
  height: 24px;
  color: #9aa8b6;
}

.activity-review-player-empty p {
  margin: 0;
  max-width: 240px;
  font-size: 13px;
  line-height: 1.35;
}

.activity-review-notes-list {
  max-height: 460px;
  overflow: auto;
  padding-right: 2px;
}

.activity-note-version-group {
  display: grid;
  gap: 8px;
}

.activity-note-version-group summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 2px 0 6px;
  border-bottom: 1px solid var(--line);
  color: #344150;
  cursor: pointer;
  font-weight: 850;
  list-style: none;
}

.activity-note-row > b {
  font-size: 12px;
  line-height: 1.25;
}

.activity-note-version-group summary::-webkit-details-marker {
  display: none;
}

.activity-note-version-group summary::before {
  content: ">";
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  transform: rotate(0deg);
  transition: transform 0.16s ease;
}

.activity-note-version-group[open] summary::before {
  transform: rotate(90deg);
}

.activity-note-version-group .version-title {
  flex: 1;
  font-size: 13px;
  line-height: 1.25;
}

.activity-note-version-actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.activity-note-version-group summary b {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 22px;
  border-radius: 999px;
  background: #eef2f5;
  color: #5d6874;
  font-size: 11px;
}

.activity-note-version-items {
  display: grid;
  gap: 8px;
}

.activity-note-version-group.approved-version .version-title {
  color: var(--success);
}

.activity-note-version-group.approved-version summary b {
  background: rgba(35, 118, 77, 0.12);
  color: var(--success);
}

@media (max-width: 980px) {
  .activity-review-workspace {
    grid-template-columns: 1fr;
  }

  .activity-review-notes-list {
    max-height: none;
    overflow: visible;
  }
}

.room-default-people {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.room-person-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
  padding: 4px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel-2);
  font-weight: 800;
}

.room-person-chip input {
  width: 16px;
  height: 16px;
}

.room-assignment-list {
  display: grid;
  gap: 8px;
}

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

.tag-editor-row input {
  min-height: 36px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 6px 8px;
}

.stage-mapping-list {
  display: grid;
  gap: 12px;
}

.stage-mapping-row {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.stage-mapping-top {
  display: grid;
  grid-template-columns: 26px 44px minmax(160px, 1fr) 130px 180px 82px auto;
  gap: 8px;
  align-items: center;
}

.activity-room-mapping-top {
  display: grid;
  grid-template-columns: 26px minmax(180px, 1fr) minmax(180px, 0.8fr) 82px auto;
  gap: 8px;
  align-items: center;
}

.stage-order-field {
  display: grid;
  gap: 2px;
}

.stage-order-field span {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1;
}

.stage-active-toggle {
  display: grid;
  place-items: center;
}

.stage-mapping-row input,
.stage-mapping-row select,
.stage-mapping-row textarea {
  width: 100%;
  min-height: 36px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 6px 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

.stage-mapping-row textarea {
  min-height: 88px;
  resize: vertical;
  font-size: 13px;
}

@media (max-width: 1180px) {
  :root {
    --projects-pane-width: 250px;
    --overview-pane-width: 0px;
  }

  .inspector,
  .pane-restore-right {
    display: none;
  }
}

@media (max-width: 760px) {
  .connection-service-heading {
    align-items: flex-start;
  }

  .connection-service-meta {
    display: grid;
  }

  .ops-portal-topbar,
  .ops-portal-heading,
  .ops-health-empty {
    align-items: flex-start;
    flex-direction: column;
  }

  .ops-portal-topbar {
    padding: 16px 18px;
  }

  .ops-portal-user {
    width: 100%;
  }

  .ops-portal-user > span {
    text-align: left;
  }

  .ops-portal-main {
    width: min(100% - 28px, 1320px);
    padding-top: 20px;
  }

  .ops-health-grid,
  .ops-health-summary,
  .ops-grid,
  .ops-whats-new-grid {
    grid-template-columns: 1fr;
  }

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

  .ops-integration-service {
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .ops-integration-check {
    justify-self: start;
    margin-top: 2px;
  }

  .ops-health-summary > div {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .ops-health-summary > div:last-child {
    border-bottom: 0;
  }

  .login-screen {
    padding: 0;
  }

  .login-shell {
    min-height: 100vh;
    grid-template-columns: 1fr;
    border: 0;
    border-radius: 0;
  }

  .login-rail {
    min-height: 120px;
    padding: 24px 20px;
  }

  .login-brand {
    transform: none;
  }

  .login-workspace {
    padding: 20px;
  }

  .signup-screen {
    padding: 0;
    place-items: stretch;
  }

  .signup-shell {
    width: 100%;
    min-height: 100vh;
    grid-template-columns: 1fr;
    border: 0;
    border-radius: 0;
  }

  .signup-form-pane {
    padding: 20px;
    align-content: start;
  }

  .signup-brand {
    margin-top: 6px;
  }

  .signup-card {
    width: min(350px, 100%);
  }

  .signup-card .two {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .signup-heading h1 {
    font-size: 22px;
  }

  .signup-heading p,
  .signup-card input {
    font-size: 15px;
  }

  .signup-feature-pane {
    padding: 22px 20px 28px;
  }

  .signup-feature-head h2 {
    font-size: 24px;
  }

  .signup-feature-list {
    min-height: 138px;
  }

  .signup-feature-card {
    padding: 14px;
  }

  :root {
    --projects-pane-width: min(250px, calc(100vw - 32px));
  }

  .app-shell {
    --projects-pane-track: 0px;
  }

  .sidebar {
    /* Overlay the calendar on phones, retaining a reachable edge handle. */
    position: absolute;
    inset: 0 auto 0 0;
    width: var(--projects-pane-width);
    z-index: 105;
    min-height: 0;
    border-right: 0;
  }

  .app-shell.left-collapsed .sidebar {
    visibility: hidden;
  }

  .main {
    grid-column: 2;
  }

  .project-list {
    max-height: 220px;
    overflow: auto;
  }

  .toolbar {
    grid-template-columns: 1fr;
  }

  .toolbar h2 {
    text-align: center;
  }

  .dialog-grid,
  .reports,
  .report-controls,
  .activity-date-fields,
  .split-segment-row,
  .bulk-child-review-row,
  .bulk-child-review-tools,
  .bulk-task-review-row,
  .bulk-task-review-tools,
  .bulk-rename-actions,
  .task-list-row,
  .two,
  .three,
  .theme-color-grid,
  .theme-asset-row {
    grid-template-columns: 1fr;
  }

  .split-segment-row {
    grid-template-areas:
      "index"
      "start"
      "end"
      "start-time"
      "end-time"
      "weekends"
      "remove";
  }

  .split-segment-remove {
    width: 100%;
    min-height: 38px;
  }
}
.workspace-save-failure {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 16px;
  border-top: 1px solid currentColor;
  color: #a53c32;
  background: #fff2ef;
  font-size: 13px;
  line-height: 1.4;
}
.tracker-theme-dark .workspace-save-failure {
  color: #ffb5aa;
  background: #392824;
}
.tracker-sync-panel {
  border-top: 1px solid var(--line, #cbd3d8);
  padding: 12px 0;
  font-size: 13px;
}
.tracker-sync-panel summary { cursor: pointer; font-weight: 700; }
.tracker-sync-toolbar { display: flex; justify-content: flex-end; margin: 8px 0; }
.tracker-sync-facts { display: grid; gap: 8px; margin: 0; }
.tracker-sync-facts > div { display: grid; grid-template-columns: minmax(90px, 1fr) minmax(0, 2fr); gap: 12px; }
.tracker-sync-facts dt { font-weight: 600; }
.tracker-sync-facts dd { margin: 0; overflow-wrap: anywhere; }

.activity-kit-source-toolbar .field { min-width: 0; }
.activity-kit-source-toolbar input,
.activity-kit-source-toolbar select {
  box-sizing: border-box;
  width: 100%;
  height: 32px;
  min-height: 32px;
  padding: 4px 8px;
  font-size: 13px;
  margin: 0;
}
@media (max-width: 760px) {
  .activity-kit-source-toolbar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 440px) {
  .activity-kit-source-toolbar { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 760px) {
  .activity-kit-source-results .activity-kit-source-card {
    grid-template-columns: 42px minmax(0, 1fr) auto;
  }
  .activity-kit-source-results .activity-kit-source-card > div { min-width: 0; overflow-wrap: anywhere; }
  .activity-kit-source-results .activity-kit-source-card > small { grid-column: 2; grid-row: 2; }
  .activity-kit-source-results .activity-kit-source-card > button { grid-column: 3; grid-row: 1 / span 2; }
  .activity-kit-source-results .activity-kit-source-thumb { grid-row: 1 / span 2; }
}

/* UI consistency: keep supporting controls together and totals below the work. */
.tracker-summary-footer { display:flex; flex-wrap:wrap; gap:8px 24px; padding:10px 12px; background:var(--tracker-surface-raised); color:var(--tracker-text-soft); border-radius:6px; font-size:12px; }
.tracker-empty strong { display:block; font-size:16px; color:var(--tracker-text); }
.tracker-empty-actions, .billing-hub-project-actions { display:flex; flex-wrap:wrap; gap:8px; }
.tracker-empty-actions { margin-top:16px; }
.tracker-column-menu .tracker-theme-toggle { margin-bottom:8px; }
.billing-hub-project-actions { margin:12px 0 24px; }
.activity-save-help { margin-right:auto; max-width:280px; font-size:12px; }
@media (max-width: 600px) {
  .activity-dialog .dialog-footer { flex-wrap: wrap; gap: 8px; }
  .activity-dialog .activity-save-help { order: -1; flex: 1 0 100%; max-width: none; }
  .activity-dialog .dialog-footer [data-toggle-activity-complete] { margin-right: auto; }
}

/* Activity services share one line-item layout; secondary billing rules stay in Details. */
.activity-services-panel { container-type: inline-size; }
.activity-service-row { border: 1px solid var(--line); border-radius: 10px; padding: 14px; margin-top: 12px; min-width: 0; }
.activity-service-grid { display: grid; grid-template-columns: minmax(180px, 2.4fr) minmax(112px, 1fr) minmax(112px, 1fr) minmax(100px, 1fr) minmax(100px, 1fr); gap: 12px; align-items: start; }
.activity-service-row .field { min-width: 0; margin: 0; gap: 6px; }
.activity-service-row .field > :is(label, span:first-child), .activity-service-row .field > label { font-size: 12px; font-weight: 650; color: var(--muted); line-height: 18px; }
.activity-service-row :is(input:not([type=checkbox]):not([type=hidden]), select, .activity-service-value) { width: 100%; min-width: 0; height: 38px; min-height: 38px; box-sizing: border-box; font-size: 13px; padding: 8px 10px; }
.activity-service-row input[type=number] { text-align: right; font-variant-numeric: tabular-nums; }
.activity-service-row textarea { width: 100%; min-height: 64px; box-sizing: border-box; }
.activity-service-value { display: flex; align-items: center; justify-content: flex-end; font-variant-numeric: tabular-nums; background: var(--panel-soft, #f7f9fa); border-radius: 6px; }
.activity-service-amount .activity-service-value { background: transparent; font-weight: 750; padding-right: 0; }
.activity-service-amount > label { text-align: right; }
.activity-service-badge { margin-left: 6px; padding: 2px 6px; border-radius: 4px; background: color-mix(in srgb, var(--accent) 10%, var(--panel)); color: #5946b2; font-size: 10px; }
.activity-service-quantity > small { display: block; margin-top: 6px; line-height: 1.4; font-size: 11px; }
.activity-service-status { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; margin: 10px 0; }
.activity-service-status .billing-lock-row { margin: 0; font-size: 11px; }
.activity-service-status .billing-lock-row .icon-button { width: 28px; height: 28px; min-height: 28px; padding: 5px; }
.activity-service-status .activity-warning { flex-basis: 100%; margin: 0; }
.activity-service-status > small { font-size: 11px; }
.activity-service-details > summary { cursor: pointer; color: var(--accent); font-size: 12px; font-weight: 650; width: fit-content; padding: 6px 0; }
.activity-service-details[open] > summary { margin-bottom: 10px; }
.activity-service-detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.activity-service-rules { display: flex; flex-wrap: wrap; gap: 12px 24px; margin: 12px 0; }
.activity-service-row .activity-row-compact-check { font-size: 12px; line-height: 1.4; }
.activity-service-row .service-discount-fields { margin: 12px 0; max-width: 440px; }
.activity-service-row .quote-baseline { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; border-top: 1px solid var(--line); padding-top: 14px; }
.activity-service-row .quote-baseline > :is(h4, small, .activity-warning) { grid-column: 1 / -1; margin: 0; }
.activity-service-row .quote-baseline > .two { grid-column: 1 / -1; }
.activity-service-remove { margin-top: 8px; }
.activity-service-footer { display: flex; justify-content: space-between; align-items: center; gap: 12px; border-top: 1px solid var(--line); margin-top: 16px; padding: 16px 0 0; font-size: 14px; }
.activity-service-footer b { font-size: 18px; font-variant-numeric: tabular-nums; }
.activity-service-add > summary { display: flex; gap: 6px; list-style: none; }
.activity-service-add > summary::-webkit-details-marker { display: none; }
.activity-service-add .toolbar-action-menu-panel { z-index: 5; }
.activity-service-row [hidden] { display: none !important; }
@container (max-width: 740px) {
  .activity-service-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .activity-service-name { grid-column: 1 / -1; }
  .activity-service-amount > label { text-align: left; }
  .activity-service-amount .activity-service-value { justify-content: flex-start; padding-left: 0; }
}
@container (max-width: 400px) {
  .activity-service-row { padding: 12px; }
  .activity-service-grid, .activity-service-detail-grid, .activity-service-row .quote-baseline { grid-template-columns: minmax(0, 1fr); }
  .activity-service-row .quote-baseline > .two { grid-template-columns: minmax(0, 1fr); }
  .activity-service-row .service-discount-fields { grid-template-columns: minmax(0, 1fr); }
}

/* Quote workspace: stable columns for fast entry, with an on-demand A4 preview. */
.quote-editor-dialog { --quote-control-height: 32px; --quote-paper-accent: var(--accent); display: flex; flex-direction: column; overflow: hidden; width: min(1480px, calc(100vw - 32px)); height: min(1080px, calc(100dvh - 24px)); max-height: calc(100dvh - 24px); }
.quote-editor-dialog .dialog-body { flex: 1; min-height: 0; overflow: auto; }
.quote-editor-dialog :is(.dialog-header,.dialog-footer) { flex-shrink: 0; position: static; }
.quote-builder-switch { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.quote-builder-switch .active { background: var(--ink); color: white; border-color: var(--ink); }
.quote-builder-switch .muted { margin-left: auto; font-size: 12px; }
.quote-editor-dialog :is(.field, .invoice-preparation-filters > *) { min-width: 0; }
.quote-editor-dialog :is(input:not([type=checkbox]):not([type=file]), select, textarea) { min-width: 0; min-height: var(--quote-control-height); height: var(--quote-control-height); padding: 5px 10px; font: inherit; font-size: 13px; line-height: 20px; border: 1px solid var(--line-strong); border-radius: 6px; box-sizing: border-box; background: var(--panel); color: var(--ink); }
.quote-editor-dialog textarea { resize: vertical; }
.quote-editor-dialog input[type=color] { padding: 3px; }
.quote-editor-dialog :is(.field > span, .field > label) { font-size: 12px; font-weight: 650; line-height: 18px; }
.quote-editor-dialog .invoice-preparation-filters { align-items: start; margin-bottom: 14px; }
.quote-editor-dialog .quote-draft-toolbar { align-items: center; }
.quote-builder-toolbar { position: sticky; top: 0; z-index: 2; padding: 12px 0; margin-bottom: 4px; background: var(--panel); }
.quote-builder-toolbar [data-quote-rate-service] { width: min(320px, 100%); }
.quote-builder-toolbar .button { height: var(--quote-control-height); min-height: var(--quote-control-height); padding-block: 5px; box-sizing: border-box; }
.quote-editor-dialog .quote-draft-table { width: 100%; min-width: 900px; }
.quote-editor-dialog .quote-draft-table th { font-size: 11px; padding: 10px 6px; }
.quote-editor-dialog .quote-draft-table th:first-child, .quote-editor-dialog .quote-draft-table th:last-child { width: auto; }
.quote-draft-table .quote-move-column { width: 36px; }
.quote-draft-table .quote-service-column { width: auto; }
.quote-draft-table .quote-unit-column { width: 114px; }
.quote-draft-table .quote-number-column { width: 106px; }
.quote-draft-table .quote-actions-column { width: 116px; }
.quote-editor-dialog .quote-draft-table td { padding: 10px 6px; vertical-align: top; }
.quote-editor-dialog .quote-draft-table textarea { height: var(--quote-control-height); min-height: var(--quote-control-height); padding: 5px 10px; font-size: 13px; line-height: 20px; border-color: var(--line-strong); box-sizing: border-box; }
.quote-editor-dialog .quote-draft-table :is(input[type=number], .quote-row-total) { text-align: right; font-variant-numeric: tabular-nums; }
.quote-row-total output { display: block; min-height: var(--quote-control-height); padding: 6px 0; box-sizing: border-box; font-size: 13px; font-weight: 700; white-space: nowrap; }
.quote-row-actions { display: flex; gap: 3px; padding-top: 0; }
.quote-editor-dialog .quote-draft-table .icon-button { width: 30px; min-width: 30px; flex: 0 0 30px; height: 32px; min-height: 32px; padding: 6px; }
.quote-row-grip .icon-button { cursor: grab; margin-top: 0; border-color: transparent; }
.quote-row-grip .icon-button:active { cursor: grabbing; }
.quote-row-actions [data-quote-move=up] svg { transform: rotate(-90deg); }
.quote-row-actions [data-quote-move=down] svg { transform: rotate(90deg); }
.quote-rate-link { border: 0; background: transparent; color: var(--muted); cursor: pointer; padding: 5px 0 0; font-size: 11px; }
.quote-rate-link:hover { color: var(--accent); text-decoration: underline; }
.quote-section-row { background: #f0eef9; }
.quote-section-title label { display: flex; align-items: center; gap: 12px; }
.quote-section-title label > span { font-weight: 700; font-size: 11px; color: #5946b2; }
.quote-section-title input { flex: 1; font-weight: 650 !important; }
.quote-row-dragging { opacity: 0.45; }
.quote-drop-before > td { box-shadow: inset 0 3px var(--accent); }
.quote-drop-after > td { box-shadow: inset 0 -3px var(--accent); }
.quote-builder-empty { padding: 16px; text-align: center; }
.quote-preview-frame { width: 100%; height: clamp(280px, calc(100dvh - 330px), 780px); border: 1px solid var(--line); border-radius: 8px; background: #e4e7ea; }
.quote-builder-preview > .muted { font-size: 12px; margin: 8px 0 0; }
.quote-editor-dialog .dialog-footer { flex-wrap: wrap; gap: 8px; }
.quote-editor-dialog [hidden] { display: none !important; }
@media (max-width: 720px) {
  .quote-editor-dialog { width: calc(100vw - 16px); height: calc(100dvh - 16px); max-height: calc(100dvh - 16px); }
  .quote-builder-switch .muted { flex-basis: 100%; margin-left: 0; }
  .quote-builder-toolbar { position: static; }
  .quote-builder-toolbar strong { flex-basis: 100%; margin-left: 0; }
  .quote-editor-dialog .quote-draft-table { min-width: 0; display: block; }
  .quote-draft-table :is(colgroup, thead) { display: none; }
  .quote-draft-table tbody { display: grid; gap: 12px; }
  .quote-draft-table tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 8px; border: 1px solid var(--line); border-radius: 8px; }
  .quote-editor-dialog .quote-draft-table td { display: block; padding: 6px; min-width: 0; border: 0; }
  .quote-draft-table td[data-label]::before { content: attr(data-label); display: block; font-size: 11px; font-weight: 650; margin-bottom: 6px; color: var(--muted); }
  .quote-draft-table .quote-row-grip { grid-column: 1; grid-row: 1; }
  .quote-draft-table .quote-row-action-cell { grid-column: 2; grid-row: 1; justify-self: end; }
  .quote-draft-table :is(.quote-row-description, .quote-section-title) { grid-column: 1 / -1; }
  .quote-section-title label { display: grid; gap: 6px; }
  .quote-editor-dialog .dialog-footer .button { font-size: 12px; padding: 8px 10px; }
  .quote-preview-frame { height: max(280px, calc(100dvh - 410px)); }
}

.quote-header-row { background: #e2dfef; border-top: 2px solid #b8afd4; }
.quote-header-row .quote-section-title input { font-size: 14px; }
.quote-section-title label > span { min-width: 44px; }
.quote-row-description > .quote-rate-link + .quote-rate-link { margin-left: 12px; }
.quote-editor-dialog .quote-item-description textarea { height: var(--quote-control-height); margin-top: 6px; font-size: 12px; color: var(--muted); background: var(--panel); }
.quote-item-description .quote-rate-link { font-size: 10px; }
.quote-production-details { margin-top: 14px; }
.quote-production-details summary { cursor: pointer; font-weight: 650; font-size: 12px; }
.quote-production-details summary .muted { font-weight: 400; }
.quote-production-fields { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; padding-top: 12px; }
.quote-pdf-library h3,.quote-pdf-generate h4 { margin: 0; }
.quote-pdf-library > .muted,.quote-pdf-generate p { font-size: 12px; }
.quote-pdf-generate { border: 1px solid var(--line); border-radius: 8px; background: var(--panel); padding: 16px; margin: 16px 0; }
.quote-pdf-generate .field { max-width: 240px; }
.quote-pdf-entry { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.quote-pdf-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.quote-pdf-final { color: #167448; background: #dff1e8; padding: 3px 8px; border-radius: 12px; font-size: 11px; margin-left: 8px; }
@media(max-width:720px){.quote-production-fields { grid-template-columns: minmax(0,1fr); }.quote-production-details summary .muted { display: block; margin-top: 5px; }.quote-section-row .quote-row-total { grid-column: 1/-1; }.quote-section-row .quote-row-total output { padding: 0; min-height: 0; text-align: left; }}

/* Editable quote sheets follow the PDF's cover and breakdown hierarchy. */
.quote-editor-dialog .quote-paper-stack { padding: 24px; background: #e9edef; border-radius: 10px; margin: 18px 0; }
.quote-paper { max-width: 1160px; margin: 0 auto 24px; padding: 38px; background: var(--panel); color: var(--ink); border: 1px solid var(--line); box-shadow: 0 3px 14px #1823280d; }
.quote-paper:last-child { margin-bottom: 0; }
.quote-paper h3 { color: var(--quote-paper-accent); font-size: 20px; margin: 0 0 18px; }
.quote-paper-masthead { display: grid; grid-template-columns: minmax(0,1fr) minmax(180px,0.55fr); gap: 60px; margin-bottom: 26px; }
.quote-paper-reference h3 { font-size: 28px; text-align: right; }
.quote-paper-reference .muted { font-size: 11px; text-align: right; }
.quote-paper .field { margin-bottom: 8px; }
.quote-paper :is(input:not([type=checkbox]):not([type=file]),textarea,select) { background: var(--panel); color: var(--ink); border-color: var(--line-strong); border-radius: 3px; }
.quote-paper :is(input,textarea,select):hover { border-color: var(--accent); }
.quote-paper :is(input,textarea,select):focus { border-color: var(--quote-paper-accent); outline: 2px solid color-mix(in srgb, var(--accent) 35%, transparent); outline-offset: 1px; }
.quote-paper .quote-production-details { margin: 18px 0 26px; }
.quote-paper-summary-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.quote-paper-summary-table :is(th,td) { padding: 10px 8px; border-bottom: 1px solid #cbd2d5; text-align: left; }
.quote-paper-summary-table th { background: var(--quote-paper-accent); color: var(--accent-ink); font-size: 12px; }
.quote-paper-summary-table :is(th,td):last-child { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.quote-summary-subtotal { font-weight: 700; }
.quote-summary-jump { border: 0; background: none; color: inherit; font: inherit; padding: 0; text-align: left; cursor: pointer; }
.quote-summary-jump:hover { text-decoration: underline; }
.quote-paper-grand-total { text-align: right; color: var(--quote-paper-accent); font-size: 17px; margin: 18px 0 0; }
.quote-paper-grand-total strong { margin-left: 12px; font-variant-numeric: tabular-nums; }
.quote-discount-controls { padding: 14px 16px; border: 1px solid var(--line); border-radius: 8px; }
.quote-global-discount-entry,.quote-discount-visibility { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.quote-global-discount-entry { align-items: end; }
.quote-global-discount-entry .field { width: 160px; margin: 0; }
.quote-discount-controls .muted { font-size: 12px; }
.quote-discount-visibility { font-size: 12px; }
.quote-paper .quote-builder-toolbar { position: static; padding: 8px 0; gap: 6px; margin: 0 0 12px; }
.quote-paper .quote-builder-toolbar select { width: 220px; }
.quote-paper .quote-builder-toolbar strong { font-size: 12px; }
.quote-editor-dialog .quote-paper .quote-draft-table { min-width: 760px; }
.quote-paper .quote-draft-table .quote-move-column { width: 28px; }
.quote-paper .quote-draft-table .quote-unit-column { width: 88px; }
.quote-paper .quote-draft-table .quote-number-column { width: 80px; }
.quote-paper .quote-draft-table .quote-actions-column { width: 94px; }
.quote-editor-dialog .quote-paper .quote-draft-table :is(th,td) { padding: 5px 3px; }
.quote-paper .quote-draft-table thead th { background: var(--quote-paper-accent); color: var(--accent-ink); font-weight: 600; }
.quote-editor-dialog .quote-paper .quote-draft-table :is(input,textarea,select) { padding-inline: 5px; font-size: 12px; }
.quote-editor-dialog .quote-paper .quote-draft-table .icon-button { width: 27px; min-width: 27px; flex-basis: 27px; padding: 5px; }
.quote-paper .quote-section-row { background: #edf1f3; }
.quote-paper .quote-header-row { background: #fff; border-top: 2px solid var(--quote-paper-accent); }
.quote-paper .quote-section-title label > span { color: var(--quote-paper-accent); }
.quote-paper .quote-row-total output { font-size: 12px; }
@media(max-width:1100px){
  .quote-editor-dialog .quote-paper-stack { padding: 14px; }
  .quote-paper { padding: 22px; }
  .quote-paper-masthead { gap: 24px; }
}
@media(max-width:720px){
  .quote-editor-dialog .quote-paper-stack { padding: 6px; }
  .quote-paper { padding: 12px; }
  .quote-paper-masthead { grid-template-columns: minmax(0,1fr); gap: 16px; }
  .quote-paper-reference h3,.quote-paper-reference .muted { text-align: left; }
  .quote-editor-dialog .quote-paper .quote-draft-table { min-width: 0; }
  .quote-paper .quote-draft-heading { grid-template-columns: minmax(0,1fr); }
  .quote-paper-grand-total { font-size: 14px; }
  .quote-discount-visibility { align-items: start; flex-direction: column; gap: 8px; }
}

/* Compact quote workspace: use the document hierarchy, leave A4 to preview. */
.quote-editor-dialog .quote-paper-stack { padding: 0; background: transparent; border-radius: 0; margin: 12px 0; }
.quote-editor-dialog .quote-paper { max-width: none; margin: 0; padding: 0; border: 0; box-shadow: none; }
.quote-builder-editor > .invoice-preparation-filters { grid-template-columns: minmax(140px,1fr) minmax(160px,1fr) minmax(200px,1.5fr); gap: 12px; margin-bottom: 8px; }
.quote-builder-switch { position: static; background: var(--panel); padding: 8px 0; margin: 0; }
.quote-editor-navigation { flex-shrink: 0; padding: 0 16px; border-bottom: 1px solid var(--line); background: var(--panel); }
.quote-editor-navigation .project-billing-navigation { margin-bottom: 0; }
.quote-access-status { margin: 0 0 10px; color: var(--muted); font-size: 12px; }
.quote-shortcuts-panel { margin: 0 0 10px; padding: 12px; border: 1px solid var(--line); border-radius: 8px; font-size: 12px; max-height: 35vh; overflow: auto; }
.quote-shortcuts-panel[hidden] { display: none; }
.quote-shortcuts-panel dl { display: grid; grid-template-columns: auto minmax(0,1fr); gap: 8px 16px; margin: 10px 0; }
.quote-shortcuts-panel dt,.quote-shortcuts-panel dd { margin: 0; }
.quote-shortcuts-panel kbd { font: inherit; font-weight: 650; }
.quote-shortcuts-panel p { margin: 0; color: var(--muted); }
.quote-header-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.quote-focus-label { margin-left: 12px; color: var(--muted); font-size: 12px; font-weight: 500; }
.quote-focus-label[hidden] { display: none; }
.quote-editor-dialog.quote-focus-mode { position: fixed; inset: 0; margin: 0; width: 100vw; max-width: none; height: 100dvh; max-height: 100dvh; border-radius: 0; }
.quote-focus-mode .project-billing-navigation,
.quote-focus-mode .quote-builder-switch,
.quote-focus-mode .quote-header-actions [data-close],
.quote-focus-mode .quote-builder-editor > :not(.quote-paper-stack),
.quote-focus-mode .quote-workflow-section,
.quote-focus-mode .quote-approval-details,
.quote-focus-mode .quote-summary-details,
.quote-focus-mode .quote-notes-details,
.quote-focus-mode .quote-builder-preview { display: none; }
.quote-focus-mode .quote-paper-stack { margin: 0; }
.quote-focus-mode .quote-builder-editor { max-width: 1448px; margin: 0 auto; }
.quote-focus-mode .quote-builder-toolbar { position: sticky; top: -1px; z-index: 2; background: var(--panel); padding: 8px 0; }
.quote-focus-mode .dialog-footer [data-quote-pdf],.quote-focus-mode .dialog-footer .quote-more-menu { display: none; }
@media (max-width: 600px) { .quote-shortcuts-panel dl { grid-template-columns: minmax(0,1fr); gap: 4px; } .quote-shortcuts-panel dd { margin-bottom: 8px; } }
.quote-detail-panel,.quote-summary-details,.quote-notes-details,.quote-approval-details { border-bottom: 1px solid var(--line); margin: 0 0 10px; padding: 8px 0; }
.quote-editor-dialog details > summary { cursor: pointer; font-size: 13px; font-weight: 650; }
.quote-detail-panel > summary .muted { font-size: 12px; font-weight: 400; margin-left: 8px; }
.quote-detail-panel .quote-paper-masthead { margin: 16px 0; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 24px; }
.quote-detail-panel .quote-production-details { margin-bottom: 12px; }
.quote-editor-dialog .quote-discount-controls { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 8px 0; border: 0; border-radius: 0; }
.quote-global-discount-entry { align-items: center; gap: 8px; flex: 1; }
.quote-global-discount-entry .field { display: flex; align-items: center; gap: 8px; width: auto; }
.quote-global-discount-entry .field > span { white-space: nowrap; }
.quote-global-discount-entry input { width: 82px; }
.quote-global-discount-entry .muted { margin-left: 8px; }
.quote-display-menu { margin-left: auto; position: relative; }
.quote-display-menu > summary { list-style: none; padding: 7px 12px; border: 1px solid var(--line-strong); border-radius: 6px; }
.quote-display-menu[open] > summary { background: var(--ink); color: white; }
.quote-display-menu[open] { flex-basis: 100%; }
.quote-display-menu[open] > summary { display: inline-block; }
.quote-display-menu .quote-discount-visibility { margin-top: 12px; }
.quote-display-menu .check-row { padding: 6px 10px; border: 1px solid var(--line); border-radius: 6px; transition: background-color 120ms, border-color 120ms; }
.quote-display-menu .check-row:has(input:checked) { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, var(--panel)); }
.quote-editor-dialog .quote-builder-toolbar { position: static; margin: 0 0 10px; padding: 4px 0; }
.quote-editor-dialog .quote-draft-table thead { position: sticky; top: 52px; z-index: 2; }
.quote-editor-dialog .quote-draft-table .quote-actions-column { width: 38px; }
.quote-editor-dialog .quote-draft-table :is(.quote-section-title,.quote-row-description) { padding-left: calc(4px + var(--quote-row-depth,0)*16px); }
.quote-editor-dialog .quote-header-row { border-top: 2px solid var(--accent); background: var(--accent); color: var(--accent-ink); }
.quote-editor-dialog .quote-header-row .quote-section-title input { font-size: 14px; font-weight: 750; }
.quote-editor-dialog .quote-section-row:not(.quote-header-row) { background: color-mix(in srgb, var(--accent) 15%, var(--panel)); }
.quote-add-in-group { display: inline-flex; align-items: center; gap: 4px; flex-shrink: 0; background: transparent; border: 1px solid currentColor; border-radius: 5px; padding: 5px 8px; font-size: 11px; color: inherit; cursor: pointer; white-space: nowrap; }
.quote-add-in-group svg { width: 12px; height: 12px; }
.quote-add-in-group:hover { background: color-mix(in srgb, currentColor 12%, transparent); }
.quote-ungrouped-label { display: block; color: #8a6124; font-size: 10px; padding: 3px 0 0; }
.quote-action-menu > summary { list-style: none; display: inline-flex; align-items: center; gap: 5px; justify-content: center; min-width: 30px; height: 32px; padding: 5px; border: 1px solid var(--line-strong); border-radius: 6px; box-sizing: border-box; }
.quote-action-menu > summary::-webkit-details-marker,.quote-display-menu > summary::-webkit-details-marker { display: none; }
.quote-action-menu > summary svg { width: 16px; height: 16px; }
.quote-action-menu[open] > summary,.quote-action-menu > summary:hover { background: color-mix(in srgb, currentColor 10%, transparent); }
.quote-action-panel { position: fixed; width: 190px; max-height: min(320px,80dvh); overflow: auto; z-index: 100; padding: 5px; background: var(--panel); border: 1px solid var(--line-strong); border-radius: 8px; box-shadow: 0 6px 20px #18232826; }
.quote-action-panel button { width: 100%; display: flex; align-items: center; gap: 8px; background: transparent; border: 0; text-align: left; padding: 9px; color: var(--ink); border-radius: 4px; cursor: pointer; font: inherit; font-size: 12px; }
.quote-action-panel button:hover:not(:disabled),.quote-action-panel button:focus-visible { background: var(--panel-2); }
.quote-action-panel button.danger { color: #b13636; }
.quote-action-panel button svg { width: 14px; height: 14px; }
.quote-action-panel [data-quote-move=up] svg { transform: rotate(-90deg); }
.quote-action-panel [data-quote-move=down] svg { transform: rotate(90deg); }
.quote-save-feedback { margin-right: auto; display: grid; gap: 3px; }
.quote-save-feedback strong { font-size: 14px; font-variant-numeric: tabular-nums; }
.quote-save-feedback [role=status] { font-size: 11px; color: var(--muted); }
.quote-save-feedback .is-unsaved { color: #936018; }
.quote-save-feedback .is-saved { color: #18744c; }
.quote-summary-details > div { max-width: 850px; padding: 14px 0; }
.quote-summary-details h3 { display: none; }
.quote-row-inserted { animation: quote-insert 700ms ease-out; }
@keyframes quote-insert { from { background-color: #e0f0df; } }
@media(prefers-reduced-motion:reduce){.quote-row-inserted{animation:none;}.quote-display-menu .check-row{transition:none;}}
@media(max-width:720px){
 .quote-builder-editor > .invoice-preparation-filters { grid-template-columns: repeat(2,minmax(0,1fr)); }
 .quote-builder-editor > .invoice-preparation-filters > :last-child { grid-column: 1/-1; }
 .quote-detail-panel .quote-paper-masthead { grid-template-columns: minmax(0,1fr); }
 .quote-global-discount-entry { flex-wrap: wrap; }
 .quote-global-discount-entry .muted { flex-basis: 100%; margin-left: 0; }
 .quote-save-feedback { flex: 1 1 100%; }
 .quote-save-feedback strong { font-size: 12px; }
 .quote-editor-dialog .quote-draft-table .quote-section-title label { display: flex; flex-wrap: wrap; }
 .quote-section-title input { flex-basis: 65%; }
 .quote-add-in-group { margin-left: auto; }
 .quote-builder-switch .muted { display: none; }
 .quote-editor-dialog .quote-draft-table thead { display: none; }
}
.quote-editor-dialog .quote-draft-table thead { position: static; }
.quote-editor-dialog .quote-paper .quote-draft-table :is(.quote-section-title,.quote-row-description) { padding-left: calc(4px + var(--quote-row-depth,0)*16px); }

/* Theme belongs to the editor; document branding remains in the A4 preview. */
.quote-editor-dialog .quote-paper .quote-section-title input:not(:focus) { background: transparent; border-color: transparent; box-shadow: none; color: inherit; }
.quote-editor-dialog .quote-paper .quote-section-title input:focus { background: var(--panel); color: var(--ink); border-color: var(--accent); }
.quote-editor-dialog .quote-header-row .quote-section-title label > span,
.quote-editor-dialog .quote-header-row td[data-label]::before { color: inherit; }
.quote-editor-dialog .quote-section-row .quote-row-grip .icon-button { background: transparent; color: inherit; }
.quote-editor-dialog .quote-header-row .quote-action-menu > summary { border-color: color-mix(in srgb, currentColor 45%, transparent); }
.quote-editor-dialog .quote-approval-fields { grid-template-columns: repeat(3,minmax(0,1fr)) auto; align-items: end; gap: 12px; }
.quote-editor-dialog .quote-approval-fields .field { margin: 0; }
.quote-editor-dialog .quote-approval-fields > .button { height: var(--quote-control-height); min-height: var(--quote-control-height); margin: 0; padding: 5px 12px; white-space: nowrap; }
@media(max-width:900px){.quote-editor-dialog .quote-approval-fields { grid-template-columns: repeat(2,minmax(0,1fr)); }}
@media(max-width:480px){.quote-editor-dialog .quote-approval-fields { grid-template-columns: minmax(0,1fr); }.quote-editor-dialog .quote-approval-fields > .button { justify-self: start; }}

/* Row-linked working notes: share the table’s row alignment and scroll position. */
.quote-header-actions [data-quote-notes-toggle] { display: none; }
.quote-focus-mode .quote-header-actions [data-quote-notes-toggle] { display: inline-flex; }
.quote-header-actions [data-quote-notes-toggle][aria-expanded="true"] { background: var(--accent); border-color: var(--accent); color: #fff; }
.quote-focus-notes { display: none; }
.quote-focus-mode .quote-focus-notes:not([hidden]) { display: block; margin: 0 0 10px; }
.quote-editor-dialog:not(.quote-row-notes-open) [data-quote-note-column] { display: none !important; }
.quote-draft-table .quote-notes-column { width: 310px; }
.quote-row-notes-open .quote-draft-table { min-width: 1100px; }
.quote-editor-dialog .quote-row-notes-cell { padding-block: 5px; border-left: 1px solid var(--line); }
.quote-row-note-preview { width: 100%; height: 32px; border: 1px dashed var(--line-strong); border-radius: 5px; background: transparent; text-align: left; color: var(--muted); font: inherit; font-size: 12px; padding: 2px 8px; cursor: pointer; overflow: hidden; display: flex; flex-direction: column; justify-content: center; }
.quote-row-note-preview.has-notes { color: #27313b; background: #fff1b8; border-style: solid; border-color: #27313b15; }
.quote-row-note-preview[data-colour="1"] { background: #ffdec7; }
.quote-row-note-preview[data-colour="2"] { background: #d7eee1; }
.quote-row-note-preview[data-colour="3"] { background: #e8dff4; }
.quote-row-note-preview[data-colour="4"] { background: #d8ebfa; }
.quote-row-note-preview[data-colour="5"] { background: #f8dce6; }
.quote-row-note-meta,.quote-row-note-excerpt { display: block; max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 13px; }
.quote-row-note-meta { font-size: 9px; font-weight: 650; }
.quote-row-note-excerpt { font-size: 11px; }
.quote-row-note-preview:disabled { cursor: default; opacity: .6; }
.quote-row-note-preview:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.quote-notes-thread:not([hidden]) { display: flex; flex-direction: column; position: fixed; top: var(--quote-note-thread-top,180px); right: max(16px,calc((100vw - 1448px)/2)); bottom: 100px; width: 310px; max-width: calc(100vw - 24px); z-index: 6; background: var(--panel); border: 1px solid var(--line-strong); border-radius: 12px; box-shadow: 0 8px 30px #17212b25; overflow: hidden; animation: quote-notes-in 130ms ease-out; }
.quote-notes-thread > .quote-notes-title { padding: 12px; margin: 0; border-bottom: 1px solid var(--line); }
.quote-notes-thread .quote-notes-title strong { overflow-wrap: anywhere; }
.quote-removed-note-label { display: block; margin-bottom: 5px; font-size: 11px; }
@media(max-width:720px){ .quote-row-notes-open .quote-draft-table { min-width: 0; } .quote-row-notes-cell { grid-column: 1/-1; } .quote-notes-thread:not([hidden]) { bottom: 120px; right: 12px; } }

.quote-notes-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 12px; }
.quote-notes-tools > label { width: 180px; }
.quote-notes-tools .quote-notes-feedback { margin: 0 0 0 auto; }
.quote-notes-title { display: flex; align-items: center; gap: 6px; margin-bottom: 10px; }
.quote-notes-title > strong { flex: 1; font-size: 14px; }
.quote-notes-title button,.quote-notes-feedback button,.quote-sticky-heading button { display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 6px; background: transparent; color: inherit; width: 28px; height: 28px; padding: 0; cursor: pointer; font-size: 21px; }
.quote-notes-title button:hover,.quote-notes-feedback button:hover,.quote-sticky-heading button:hover { background: #17212b12; }
.quote-notes-tools select { width: 100%; min-width: 0; }
.quote-notes-feedback { display: flex; align-items: center; gap: 6px; margin-top: 8px; color: var(--muted); }
.quote-notes-feedback small { flex: 1; font-size: 11px; line-height: 1.4; }
.quote-note-list { padding: 12px; overflow-y: auto; overscroll-behavior: contain; min-height: 0; }
.quote-sticky { --sticky: #fff1b8; padding: 10px; border-radius: 3px 3px 12px 3px; background: var(--sticky); color: #27313b; box-shadow: 0 2px 4px #17212b12; margin-bottom: 12px; }
.quote-sticky[data-colour="1"] { --sticky: #ffdec7; }
.quote-sticky[data-colour="2"] { --sticky: #d7eee1; }
.quote-sticky[data-colour="3"] { --sticky: #e8dff4; }
.quote-sticky[data-colour="4"] { --sticky: #d8ebfa; }
.quote-sticky[data-colour="5"] { --sticky: #f8dce6; }
.quote-sticky-heading { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.quote-sticky-heading strong { flex: 1; font-size: 12px; overflow-wrap: anywhere; }
.quote-sticky-heading button { flex-shrink: 0; }
.quote-editor-dialog .quote-focus-notes .quote-sticky textarea { display: block; width: 100%; min-height: 110px; height: 110px; max-height: 260px; padding: 4px; background: transparent; color: inherit; border: 1px solid transparent; box-shadow: none; border-radius: 4px; font: inherit; font-size: 13px; line-height: 1.5; resize: vertical; }
.quote-editor-dialog .quote-focus-notes .quote-sticky textarea:not([readonly]):focus { border-color: #27313b55; outline: none; background: #ffffff30; }
.quote-sticky-footer { font-size: 11px; line-height: 1.4; overflow-wrap: anywhere; }
.quote-sticky-footer button { margin-top: 6px; background: #ffffff70; border: 1px solid #27313b30; color: inherit; border-radius: 4px; cursor: pointer; }
.quote-sticky-footer [hidden] { display: none; }
.quote-notes-empty { margin: 4px 0; font-size: 13px; color: var(--muted); }
@keyframes quote-notes-in { from { opacity: 0; transform: translateX(8px); } to { opacity: 1; transform: translateX(0); } }
@media (prefers-reduced-motion: reduce) { .quote-notes-thread:not([hidden]) { animation: none; } }
@media (max-width: 600px) { .quote-focus-mode .quote-focus-label { display: none; } .quote-header-actions { gap: 4px; } }
.quote-header-row .quote-row-note-preview:not(.has-notes) { color: inherit; border-color: #ffffff60; }

/* Budget, payment plans, charges and preparation only. Quote editor styles stay independent. */
.billing-workspace-overlay { align-items: start; }
.billing-workspace { --billing-control-height: 38px; }
.billing-workspace .dialog-body { min-width: 0; }
.billing-workspace :is(input:not([type="checkbox"]),select) {
  box-sizing: border-box;
  height: var(--billing-control-height);
  min-height: var(--billing-control-height);
  max-height: var(--billing-control-height);
  min-width: 0;
  max-width: 100%;
  padding: 6px 10px;
  font: inherit;
  line-height: 1.25;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--panel, #fff);
  color: var(--ink);
}
.billing-workspace .field { align-content: start; }
.billing-workspace .invoice-preparation-filters { align-items: end; }
.billing-workspace:is([data-project-budget-form],[data-payment-plan-form]) .invoice-preparation-filters { grid-template-columns: repeat(2,minmax(0,1fr)); }
.billing-workspace .invoice-preparation-table :is(th,td) { padding: 8px 10px; vertical-align: top; }
.billing-workspace .invoice-preparation-table th { font-size: 12px; color: var(--muted); }
.billing-workspace .invoice-preparation-table input:not([type="checkbox"]) { width: 100%; }
.billing-workspace .activity-kit-summary { margin: 16px 0; grid-template-columns: repeat(3,minmax(0,1fr)); }
.billing-workspace .activity-kit-summary > div { min-width: 0; }
.billing-help { color: var(--muted); font-size: 13px; line-height: 1.5; margin: 8px 0 16px; }
.billing-workspace .billing-preparation-summary > .muted { font-size: 12px; line-height: 1.5; }
.billing-help strong { color: var(--ink); font-weight: 600; }
.billing-section-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin: 18px 0 8px; }
.billing-section-heading h3, .billing-section-heading p { margin: 0; }
.billing-section-heading > .billing-help { flex: 1 1 350px; }
.billing-result-total { display: grid; gap: 4px; text-align: right; }
.billing-result-total span, .billing-result-total small { font-size: 12px; color: var(--muted); }
.billing-result-total strong { font-size: 20px; font-variant-numeric: tabular-nums; }
.billing-coverage { margin-top: 24px; border-top: 1px solid var(--line); padding-top: 16px; }
.billing-coverage > summary { cursor: pointer; font-weight: 650; }
.billing-coverage > summary span { color: var(--muted); font-weight: 400; font-size: 12px; margin-left: 8px; }
.billing-coverage > .billing-help { margin-top: 12px; }
.billing-disclosure { display: inline-flex; align-items: center; gap: 5px; border: 0; border-radius: 5px; background: transparent; color: var(--accent); font: inherit; font-size: 13px; padding: 5px 0; cursor: pointer; text-align: left; }
.billing-disclosure svg { width: 16px; height: 16px; }
.billing-disclosure:hover { text-decoration: underline; }
.billing-disclosure:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.billing-status { display: inline-block; font-size: 12px; line-height: 1.4; font-weight: 600; border-radius: 6px; padding: 4px 8px; }
.billing-status-ready { background: #e1f2e9; color: #226442; }
.billing-status-prepared { background: #ece8fa; color: #574098; }
.billing-status-muted { background: var(--panel-2, #f0f2f4); color: var(--muted); }
.billing-workspace input[type="checkbox"] { width: 16px; height: 16px; min-width: 16px; min-height: 16px; padding: 0; margin: 3px 0; }
.billing-charges-table > thead th:first-child { width: 36px; }
.billing-charges-table > thead th:nth-child(2) { width: 52%; }
.billing-charges-table > tbody > tr:first-child td { padding-top: 12px; padding-bottom: 12px; }
.billing-workspace .billing-charges-table [data-charge-details] > td { background: var(--panel-2, #f7f8fa); padding: 0; }
.billing-service-breakdown { width: 100%; min-width: 560px; margin: 0; font-size: 13px; }
.billing-workspace .billing-service-breakdown th { background: var(--panel-2, #f7f8fa); }
.billing-workspace .billing-action-footer { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; }
.billing-workspace [data-batch-create] { margin-left: auto; }
.billing-action-footer > span { margin-left: auto; color: var(--muted); font-size: 13px; }
.billing-reference { max-width: 400px; margin: 16px 0 8px; }
.billing-empty { padding: 24px 16px; background: var(--panel-2, #f7f8fa); border: 1px dashed var(--line); border-radius: var(--radius); color: var(--muted); font-size: 14px; }
@media (max-width: 850px) {
  .billing-workspace .invoice-preparation-filters { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 600px) {
  .billing-workspace .activity-kit-summary { grid-template-columns: 1fr; }
  .billing-workspace .invoice-preparation-filters,
  .billing-workspace:is([data-project-budget-form],[data-payment-plan-form]) .invoice-preparation-filters { grid-template-columns: minmax(0,1fr); }
  .billing-result-total { text-align: left; }
  .billing-coverage > summary span { display: block; margin: 6px 0 0; }
  .billing-action-footer > span { margin-left: 0; }
  .billing-action-footer > .primary { width: 100%; }
}

.budget-quote-list { margin-block: 16px; }
.budget-quote-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.budget-quote-entry { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.budget-quote-entry button { border: 0; padding: 4px 0; background: transparent; color: var(--accent); font: inherit; text-align: left; cursor: pointer; }
.budget-quote-entry button:hover { text-decoration: underline; }
.budget-quote-entry strong { white-space: nowrap; }
.billing-workspace[data-project-budget-form] .budget-source-fields { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.billing-workspace .budget-summary { grid-template-columns: repeat(5, minmax(0, 1fr)); }
@media (max-width: 800px) {
  .billing-workspace[data-project-budget-form] .budget-source-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .billing-workspace .budget-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 520px) {
  .billing-workspace[data-project-budget-form] .budget-source-fields { grid-template-columns: minmax(0, 1fr); }
  .billing-workspace .budget-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Billing overview uses the workspace theme; quote editor controls remain scoped separately. */
.billing-settings-button { margin-left: auto; }
.invoicing-views { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 16px; }
.invoicing-views [aria-current="page"] { background: var(--accent); color: white; border-color: var(--accent); }
.billing-workspace .billing-primary-summary { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); }
.billing-notice { padding: 10px 12px; border-left: 3px solid var(--accent); background: var(--panel-2); font-size: 13px; }
.budget-extra-menu > summary { cursor: pointer; list-style: none; }
.budget-extra-menu > div { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 8px; }
.budget-variance-list { margin-top: 18px; }
.budget-action-card { padding: 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); margin: 14px 0; }
.budget-action-fields { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; margin-bottom: 14px; }
.budget-action-fields input,.budget-action-fields select { width: 100%; min-width: 0; }
.budget-confirm { display:flex; gap:8px; align-items:center; margin:12px 0; font-size:13px; }
.billing-workspace .budget-confirm input { width:16px; height:16px; min-height:0; }
.budget-adjustment-entry { border-top:1px solid var(--line); padding:12px 0; }
.budget-adjustment-entry strong,.budget-adjustment-entry small { display:block; }
.budget-adjustment-entry small { color:var(--muted); margin-top:4px; }
.budget-adjustment-entry p { margin:6px 0; }
@media(max-width:600px) {
  .budget-action-fields { grid-template-columns:minmax(0,1fr); }
  .billing-workspace .billing-primary-summary { grid-template-columns:minmax(0,1fr); }
}

/* Compact project context and on-demand help in the billing workspace. */
.billing-project-context { margin: 12px 0; max-width: 360px; }
.billing-project-context .field { margin: 0; }
.billing-workspace [hidden] { display: none !important; }
.billing-context-help { margin: 8px 0; min-width: 0; }
.billing-context-help > summary { display: flex; align-items: center; justify-content: center; width: 26px; height: 26px; padding: 0; border: 1px solid var(--line); border-radius: 50%; color: var(--muted); background: var(--panel); font-size: 14px; font-weight: 650; cursor: pointer; list-style: none; }
.billing-context-help > summary::-webkit-details-marker { display: none; }
.billing-context-help > summary:hover, .billing-context-help[open] > summary { color: var(--accent); border-color: var(--accent); }
.billing-context-help > summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.billing-context-help > .billing-help { max-width: 720px; margin: 8px 0 12px; padding: 10px 12px; border-left: 2px solid var(--accent); background: var(--panel-2, #f7f8fa); border-radius: 4px; }
.billing-section-heading > .billing-context-help { flex: 1 1 240px; }
.billing-workspace [data-plan-setup] .invoice-preparation-filters { max-width: 480px; grid-template-columns: minmax(0,1fr); }
.billing-workspace [data-budget-setup] .invoice-preparation-filters { margin-top: 12px; }

.billing-plan-delete { margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--line); }

.message-row.message-deleted { border: 0; border-radius: 0; background: transparent; padding: 6px 0; color: var(--muted); font-size: 12px; font-style: italic; }
.message-delete-action:disabled { opacity: .5; cursor: wait; }

/* Time and charging use a native modal so the activity draft stays intact. */
.activity-work-dialog{width:min(1180px,96vw);max-width:96vw;max-height:92dvh;margin:auto;padding:0;border:1px solid var(--line,#d6dce0);border-radius:12px;color:var(--ink,#172126);background:var(--panel,#fff);box-shadow:0 18px 70px #0004}
.activity-work-dialog::backdrop{background:#10182080}
.activity-work-dialog .dialog-header{position:sticky;top:0;background:var(--panel,#fff);z-index:2}
.activity-work-dialog .dialog-header{justify-content:flex-start;gap:10px}.activity-work-dialog .dialog-header h2{flex:1;margin-right:auto}
.activity-work-dialog .dialog-body{max-height:calc(92dvh - 70px);overflow:auto}
.activity-work-dialog input:not([type=checkbox]),.activity-work-dialog select{height:34px;min-height:34px;box-sizing:border-box;padding:4px 8px;width:100%;min-width:0;font:inherit}
.activity-work-dialog [hidden]{display:none!important}
.activity-work-dialog h3{margin:0 0 12px}
.work-settings-grid,.work-entry-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:14px 0}
.work-entry-main{grid-template-columns:minmax(0,2fr) repeat(2,minmax(0,1fr))}
.work-summary{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:12px}
.work-summary>div{border:1px solid var(--line,#d6dce0);border-radius:8px;padding:12px;display:grid;gap:6px}
.work-summary b{font-size:20px;font-variant-numeric:tabular-nums}
.work-summary small,.work-entry-table small{display:block;color:var(--muted,#667680)}
.work-views{display:flex;gap:6px;flex-wrap:wrap;border-bottom:1px solid var(--line,#d6dce0);padding:16px 0;margin-bottom:20px}
.work-views .button{background:transparent;border-color:transparent;color:var(--muted,#667680)}
.work-views .button[aria-pressed=true]{background:var(--accent,#5b43b5);border-color:var(--accent,#5b43b5);color:white}
.work-views .button:hover{border-color:var(--line,#d6dce0)}
.work-count{border-radius:12px;background:var(--panel,#fff);color:var(--ink,#172126);padding:1px 6px;font-size:11px}
.work-entry-context{margin:0;color:var(--muted,#667680);font-size:12px}
.work-options{margin:16px 0;border:1px solid var(--line,#d6dce0);border-radius:8px;padding:12px}
.work-options>summary,.work-filter-options>summary{cursor:pointer;font-size:13px;font-weight:600}
.work-options>summary span{font-weight:400;margin-left:8px}
.work-options .check-row{margin-top:12px}
.work-booking-hint{display:flex;gap:12px;align-items:center;flex-wrap:wrap;font-size:12px}
.work-history-heading{display:flex;align-items:baseline;justify-content:space-between;gap:12px;flex-wrap:wrap}
.work-history-heading .muted{font-size:12px}
.work-filter-options{margin:0 0 12px}
.work-billing-review{display:flex;align-items:center;justify-content:space-between;gap:16px;padding-top:16px;font-size:13px}
.work-billing-review button{flex-shrink:0}.work-billing-review small{display:block}.work-billing-review p{margin:6px 0}.work-confirmation{margin-top:18px;padding:16px;border:1px solid var(--line);border-radius:8px;background:var(--panel,#fff)}.work-confirmation>p{font-size:13px;line-height:1.5}.work-confirmation .work-summary{margin-bottom:12px}
.work-entry-actions,.work-filters,.work-row-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.work-entry-actions{margin:12px 0 20px}.work-filters{padding:12px 0}.work-filters label{display:flex;align-items:center;gap:8px}
.work-period-controls{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:14px 0}.work-period-tabs{display:flex;padding:3px;border-radius:8px;background:var(--surface-muted,#f0f2f4)}.work-period-tabs .button[aria-pressed=true]{background:var(--accent,#6146c6);color:#fff;border-color:transparent}.work-period-controls .icon-button{height:34px;width:34px;min-width:34px}.work-period-tabs .button{transition:background-color 120ms ease,color 120ms ease;border-color:transparent}.work-period-controls .work-review-date{width:160px;margin:0}.work-review-date input{border:1px solid var(--line-strong);border-radius:6px;background:var(--panel);color:var(--ink)}.work-period-summary{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}.work-period-summary p{margin:5px 0}.work-period-hint{font-size:12px;line-height:1.5;margin:8px 0 14px}
.work-filters label{white-space:nowrap}.work-filters select,.work-filters input{border:1px solid var(--line);border-radius:6px;background:var(--panel,#fff);color:inherit}
.work-help{border-top:1px solid var(--line,#d6dce0);padding-top:12px;margin-top:20px;color:var(--muted)}.work-help summary{cursor:pointer;font-size:12px}
.work-entry-table-wrap{overflow:auto}.work-entry-table{width:100%;border-collapse:collapse}.work-entry-table th,.work-entry-table td{padding:10px 8px;text-align:left;border-bottom:1px solid var(--line,#d6dce0);vertical-align:top}.work-entry-table th{white-space:nowrap}
.work-policy-status{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 0;flex-wrap:wrap}.work-policy-status small{display:block}
@media(max-width:800px){.work-entry-main{grid-template-columns:repeat(2,minmax(0,1fr))}.work-entry-main>.field:first-child{grid-column:1/-1}.work-billing-review{align-items:flex-start;flex-direction:column}}
@media(max-width:480px){.work-settings-grid,.work-entry-grid{grid-template-columns:minmax(0,1fr)}.work-filters label{width:100%;flex-wrap:wrap}.work-summary{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.work-summary>div{padding:8px}.work-options>summary span{display:block;margin:4px 0 0}.work-views{gap:2px}.work-views .button{padding-inline:8px}.work-summary b{font-size:17px}}

.activity-work-enabled .activity-service-grid{grid-template-columns:minmax(0,1fr) max-content;padding-right:36px;align-items:center}
.activity-work-enabled .activity-service-grid>:not(.activity-service-name):not(.activity-service-amount),.activity-work-enabled .activity-service-status{display:none}
.activity-work-enabled .activity-service-name{grid-column:auto}
.activity-work-enabled .activity-service-amount{display:flex;align-items:center;justify-content:flex-end}
.activity-work-enabled .activity-service-amount>label{display:none}
.activity-work-enabled .activity-service-amount .activity-service-value{width:auto;white-space:nowrap;padding-inline:0;justify-content:flex-end}
.activity-work-enabled .activity-main-service-fields>:not(.quote-baseline){display:none}
.activity-work-enabled .activity-service-detail-grid>.field:first-child{display:none}

/* One charge editor in Services; the time review stays focused on entries. */
.client-charge-actions{display:flex;gap:8px;flex-wrap:wrap}
.client-charge-editor{padding:16px;border:1px solid var(--line);border-radius:10px;background:var(--panel);margin:12px 0}
.client-charge-editor-heading{display:flex;flex-direction:column;gap:4px;margin-bottom:16px}
.client-charge-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;align-items:start}
.client-charge-grid>div>.field{margin:0}
.client-charge-editor fieldset{border:0;padding:0;margin:0;min-width:0}
.client-charge-editor input,.client-charge-editor select{box-sizing:border-box;width:100%;height:38px;min-height:38px;padding:4px 9px;font:inherit}
.client-charge-editor .field{min-width:0;display:flex;flex-direction:column;gap:5px}
.client-charge-editor .field>span{font-size:12px;font-weight:600;color:var(--muted)}
.client-charge-options{margin:14px 0;border-top:1px solid var(--line);padding-top:12px}
.client-charge-options>summary{cursor:pointer;font-weight:600;margin-bottom:10px}
.client-charge-preview{margin:14px 0;padding:14px;border:1px solid var(--line);border-radius:8px;background:var(--panel-2)}
.client-charge-preview h4{margin:0 0 12px}
.client-charge-comparison{display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:16px}
.client-charge-comparison div{display:flex;flex-direction:column;gap:5px}
.client-charge-comparison strong{font-size:22px}.client-charge-comparison small{color:var(--muted)}
.client-charge-editing .client-charge-existing{display:none}
.client-charge-editing .work-policy-status{opacity:.65}
.client-charge-save-hint{margin-bottom:0;font-size:12px}
.quote-baseline>summary{font-weight:700;cursor:pointer}.quote-baseline[open]>summary{margin-bottom:14px}
.work-configure-link{margin-top:14px;padding:0;border:0;background:none;color:var(--accent);font:inherit;font-size:13px;cursor:pointer;text-align:left}.work-configure-link:hover{text-decoration:underline}
@media(max-width:760px){.client-charge-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:480px){.client-charge-grid{grid-template-columns:minmax(0,1fr)}.client-charge-editor{padding:12px}.client-charge-actions{width:100%}.client-charge-comparison strong{font-size:18px}}

/* Independent activity billing windows keep their drafts when switching focus. */
.billing-floating-window{position:fixed;margin:0;inset:auto;padding:0;display:flex;flex-direction:column;max-height:calc(100dvh - 16px);max-width:calc(100vw - 16px);border:1px solid var(--line-strong);border-radius:12px;background:var(--panel);color:var(--ink);box-shadow:0 16px 64px #0005;overflow:hidden}
.billing-floating-window[hidden]{display:none!important}
.billing-floating-window.activity-work-dialog{width:min(880px,calc(100vw - 48px))}
.client-charge-window{width:min(680px,calc(100vw - 48px))}
.billing-floating-window>.dialog-header{position:relative;flex-shrink:0;display:flex;align-items:center;gap:10px;background:var(--panel);padding:14px 16px;cursor:grab;touch-action:none}
.billing-floating-window>.dialog-header h2{flex:1;min-width:0;font-size:16px;margin:0}
.billing-floating-window>.dialog-header:active{cursor:grabbing}
.billing-floating-window .dialog-body{overflow:auto;min-height:0;max-height:none;padding:16px}
.billing-floating-window form[data-charge-form]{display:flex;flex-direction:column;overflow:hidden;min-height:0}
.billing-floating-window .dialog-footer{flex-shrink:0;padding:12px 16px;display:flex;gap:8px;justify-content:flex-end}
.client-charge-window .client-charge-editor{border:0;margin:0;padding:0}
.client-charge-window .client-charge-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
.billing-window-tabs{display:flex;gap:6px;padding:8px 16px;overflow:auto;border-bottom:1px solid var(--line);flex-shrink:0}
.billing-window-tabs .button{white-space:nowrap;font-size:12px}
.billing-window-tabs [aria-pressed=true]{color:var(--accent);border-color:var(--accent)}
.billing-floating-window .charge-source-note{grid-column:1/-1;font-size:12px;color:var(--muted);margin:0}
.billing-floating-window .charge-source-note button{margin-left:8px}
.billing-floating-window .charge-live-total{font-size:13px;margin:0 0 12px;color:var(--muted)}
@media(max-width:999px){.billing-floating-window{left:8px!important;top:8px!important;width:calc(100vw - 16px)!important;max-height:calc(100dvh - 16px)}.billing-floating-window>.dialog-header{cursor:default}}
@media(max-width:480px){.client-charge-window .client-charge-grid{grid-template-columns:1fr}.billing-floating-window>.dialog-header{flex-wrap:wrap}.billing-floating-window>.dialog-header h2{flex-basis:70%}}

/* Paired booking boundaries; time inputs share one application-wide display format. */
.activity-room-location { width: min(100%, 260px); }
.activity-room-location input { height: 36px; min-height: 36px; }
.seqncer-time-control { position: relative; display: inline-flex; min-width: 0; width: 100%; }
.seqncer-time-control > input[type="time"][hidden] { display: none !important; }
.seqncer-time-control .seqncer-time-display { width: 100%; min-width: 0; padding-right: 29px; font-variant-numeric: tabular-nums; }
.time-control-clock { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; pointer-events: none; color: var(--muted, #657381); }
.time-control-clock svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }
.booking-period { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 12px; min-width: 0; }
.booking-date-pair { min-width: 0; }
.booking-date-pair > label { display: block; font-size: 12px; font-weight: 700; margin-bottom: 5px; }
.booking-date-time { display: grid; grid-template-columns: minmax(120px, 1.2fr) minmax(112px, 1fr); align-items: center; gap: 6px; }
.booking-date-time input { width: 100%; min-width: 0; height: 36px; min-height: 36px; padding-top: 6px; padding-bottom: 6px; }
.booking-period > .include-weekends-control { grid-column: 1 / -1; width: fit-content; }
.split-segment-row.booking-split-row, .split-segment-row.booking-split-row.has-weekends-option { grid-template-columns: 40px minmax(0, 1fr) 30px; grid-template-areas: "index period remove"; align-items: start; }
.booking-split-row .booking-period { grid-area: period; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.booking-split-row .split-segment-remove { align-self: start; margin-top: 20px; min-height: 24px; }
.booking-split-row .booking-date-time { grid-template-columns: minmax(90px, 1.15fr) minmax(80px, 1fr); gap: 4px; }
.booking-split-row .booking-date-time input { height: 32px; min-height: 32px; padding: 5px; }
.booking-split-row .booking-date-time .seqncer-time-display { padding-right: 20px; font-size: 11px; }
.booking-split-row .time-control-clock { right: 5px; width: 12px; height: 12px; }
.booking-split-row .booking-date-pair > label { font-size: 10px; }
.booking-split-row .split-segment-index { align-self: start; margin-top: 30px; }
@media (max-width: 1150px) {
  .booking-period { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .split-segment-row.booking-split-row { grid-template-columns: 28px minmax(0, 1fr) 28px; gap: 4px; }
  .booking-date-time { grid-template-columns: minmax(105px, 1fr) minmax(102px, 1fr); }
  .split-segment-list { overflow-x: auto; }
  .split-segment-row.booking-split-row { min-width: 420px; }
}

.booking-hours-options { grid-column: 1 / -1; min-width: 0; font-size: 11px; }
.booking-hours-options > summary { cursor: pointer; color: var(--muted); width: fit-content; }
.booking-hours-panel { display: grid; gap: 8px; padding: 10px; margin-top: 6px; border: 1px solid var(--line); border-radius: 8px; }
.booking-hours-panel .booking-date-time { max-width: 280px; }
.booking-hours-panel .booking-date-time input { border: 1px solid var(--line); border-radius: 8px; padding-left: 8px; }
.booking-hours-panel [hidden], .segment-daily-hours-label[hidden] { display: none; }
.booking-hours-panel small { line-height: 1.4; }
.booking-split-row { position: relative; min-width: 448px; }
[data-schedule-segment-list] { overflow-x: auto; }
@media (max-width: 1000px) { .dialog-grid.activity-details-layout { grid-template-columns: 1fr; } }
.segment-hours-options > summary { position: absolute; left: 12px; top: 8px; list-style: none; padding: 0; line-height: 14px; }
.segment-hours-options > summary::-webkit-details-marker { display: none; }
.segment-hours-options > summary .icon { width: 14px; height: 14px; }
.segment-hours-options:not([open]) { height: 0; margin-top: -6px; }
.segment-daily-hours-label { grid-column: 1 / -1; font-size: 10px; }

/* Activity forms use one control rhythm, with smaller controls only in dense rows. */
.activity-dialog { --activity-control-height: 36px; --activity-control-font: 13px; }
.activity-dialog .dialog-body :is(input:not([type]), input[type="text"], input[type="number"], input[type="date"], input[type="time"], input[type="search"], input[type="url"], select, .activity-service-value, .static-field) {
  box-sizing: border-box;
  height: var(--activity-control-height);
  min-height: var(--activity-control-height);
  min-width: 0;
  max-width: 100%;
  padding-block: 6px;
  font-size: var(--activity-control-font);
  line-height: 20px;
}
.activity-dialog .dialog-body select {
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background-color: var(--panel);
  color: var(--ink);
}
.activity-dialog .field { min-width: 0; gap: 5px; align-content: start; }
.activity-dialog .field > :is(label, span:first-child) { font-size: 12px; line-height: 18px; font-weight: 650; color: var(--muted); }
.activity-dialog .multi-select-dropdown > summary { box-sizing: border-box; min-height: 36px; height: 36px; padding-block: 6px; font-size: 13px; }
.activity-dialog .field textarea { font-size: 13px; line-height: 1.45; padding: 8px 10px; resize: vertical; }
.activity-dialog .dialog-grid > div { min-width: 0; }
.activity-dialog .panel-block { min-width: 0; gap: 12px; margin-bottom: 0; }
.activity-dialog .section-title { padding: 0; gap: 8px 12px; flex-wrap: wrap; }
.activity-dialog .section-title p { margin: 4px 0 0; font-size: 12px; line-height: 1.4; }
.activity-dialog :is(.section-title, .client-charge-actions, .split-activity-heading) .button,
.activity-dialog .task-board-toolbar .button { min-height: 32px; padding: 5px 10px; font-size: 12px; line-height: 20px; }
.activity-dialog .task-view-toggle { height: 32px; box-sizing: border-box; }
.activity-dialog .task-view-toggle button { min-height: 30px; height: 30px; font-size: 12px; }
.activity-dialog .task-template-bar { flex-wrap: wrap; }
.activity-dialog .task-template-picker { flex: 1 1 260px; }
.activity-dialog .task-template-admin-actions { flex-wrap: wrap; }
.activity-dialog :is(.task-template-bar, .task-list-bulk-bar, .task-list-row) { --activity-control-height: 32px; }
.activity-dialog .task-template-bar .button { min-height: 32px; }
.activity-dialog .task-board-card { --activity-control-height: 30px; --activity-control-font: 12px; }
.activity-dialog .task-board-card .manual-time-control .icon-button { height: 30px; min-height: 30px; width: 30px; }
.activity-dialog .task-list-row :is(.button, .icon-button) { height: 32px; min-height: 32px; }
.activity-dialog .booking-split-row { --activity-control-height: 32px; --activity-control-font: 11px; }
.activity-dialog [data-booking-overrides] > .booking-period { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.activity-dialog .booking-date-pair { gap: 0; }
.activity-dialog .booking-date-pair > label { margin-bottom: 5px; }
.activity-dialog .booking-split-row .booking-date-pair > label { font-size: 10px; line-height: 15px; }
.activity-dialog .split-activity-heading .button { flex-shrink: 0; white-space: nowrap; }
.activity-dialog .activity-internal-field { min-height: 36px; font-size: 13px; }
.activity-dialog .activity-service-row { margin-top: 0; padding: 12px; }
.activity-dialog .activity-inhouse-row { position: relative; }
.activity-dialog .activity-inhouse-row :is(.activity-service-name, .activity-service-amount) > label { padding-right: 28px; }
.activity-dialog .activity-service-remove { position: absolute; top: 5px; right: 8px; width: 28px; height: 28px; min-height: 28px; margin: 0; padding: 5px; border: 0; background: transparent; color: color-mix(in srgb, var(--danger) 45%, transparent); }
.activity-dialog .activity-service-remove:is(:hover, :focus-visible):not(:disabled) { color: var(--danger); background: transparent; }
.activity-dialog .activity-service-name input { font-weight: 650; }
.activity-dialog .activity-service-name input:not(:focus) { background: transparent; border-color: transparent; box-shadow: none; color: var(--ink); }
.activity-dialog .activity-service-name input:focus { background: var(--panel); border-color: var(--accent); color: var(--ink); }
.activity-service-details > summary > .icon { display: none; }
.activity-work-enabled .activity-service-editor { position: relative; }
.activity-work-enabled .activity-service-name { display: flex; align-items: center; gap: 6px; padding-left: 28px; }
.activity-work-enabled .activity-service-name > label,
.activity-work-enabled .activity-service-label { display: none; }
.activity-work-enabled .activity-service-name > span { display: contents; }
.activity-work-enabled .activity-service-name .activity-service-badge { margin: 0; flex-shrink: 0; }
.activity-work-enabled .activity-service-name input { flex: 1; width: 0; }
.activity-work-enabled .activity-service-remove { top: 16px; right: 12px; }
.activity-work-enabled .activity-service-editor > .activity-service-details > summary { position: absolute; top: 4px; left: 0; display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; margin: 0; padding: 0; border-radius: 6px; list-style: none; }
.activity-work-enabled .activity-service-editor > .activity-service-details > summary::-webkit-details-marker { display: none; }
.activity-work-enabled .activity-service-editor > .activity-service-details > summary > span { display: none; }
.activity-work-enabled .activity-service-editor > .activity-service-details > summary > .icon { display: block; width: 16px; height: 16px; }
.activity-work-enabled .activity-service-editor > .activity-service-details[open] > summary > .icon { transform: rotate(90deg); }
.activity-work-enabled .activity-service-editor > .activity-service-details[open] { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.activity-work-enabled .activity-service-editor > .activity-service-details > summary:is(:hover, :focus-visible) { background: color-mix(in srgb, var(--accent) 8%, transparent); }
.activity-dialog .activity-service-list { display: grid; gap: 12px; }
.activity-dialog .activity-service-details[open] > summary { margin-bottom: 6px; }
.activity-dialog .activity-service-rules { margin-block: 8px; }
.activity-dialog .activity-service-rules .check-row { min-height: 28px; font-size: 12px; }
.activity-dialog .activity-service-detail-grid .button { height: 36px; min-height: 36px; }
.activity-dialog .activity-service-footer { margin-top: 0; padding-top: 12px; }
.activity-dialog .work-policy-status { padding: 0 0 10px; }
.activity-dialog .work-summary { gap: 8px; margin-bottom: 12px; }
.activity-dialog .work-summary > div { padding: 10px; gap: 4px; align-content: start; }
.activity-dialog .work-summary b { font-size: 17px; line-height: 22px; }
.activity-dialog .work-summary small { font-size: 12px; line-height: 16px; }
.activity-dialog .activity-charge-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.activity-dialog .activity-charge-summary > div { padding: 8px 10px; gap: 3px; }
.activity-dialog .activity-charge-quantity { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 6px; }
.activity-dialog [data-billing-destination] { justify-self: start; }
.activity-dialog .activity-kit-grid { grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; }
.activity-dialog .activity-kit-row-head-manual { grid-template-columns: minmax(0, 1.5fr) minmax(120px, 1fr) 36px; gap: 10px; }
.activity-dialog .activity-kit-delete { align-self: end; width: 36px; height: 36px; min-height: 36px; margin: 0; }
.activity-dialog .activity-kit-bottom { gap: 10px; }
.activity-dialog .activity-kit-total { min-height: 52px; }
.activity-dialog .activity-kit-row textarea { min-height: 64px; }
/* Messages scroll independently so the composer stays beside the modal footer. */
.activity-messages-dialog { height: min(920px, calc(100dvh - 24px)); }
.activity-messages-dialog .dialog-body { display: flex; flex-direction: column; overflow: hidden; }
.activity-messages-dialog .activity-tabs-sticky { flex: 0 0 auto; }
.activity-messages-dialog .dialog-grid,
.activity-messages-dialog .dialog-grid > div { display: flex; flex-direction: column; align-items: stretch; flex: 1; min-height: 0; min-width: 0; }
.activity-messages-dialog .activity-messages-panel { display: flex; flex-direction: column; flex: 1; min-height: 0; margin: 0; gap: 8px; }
.activity-messages-dialog .activity-message-list { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-gutter: stable; grid-template-columns: minmax(0, 1fr); align-content: start; margin-right: -10px; padding: 8px 12px 12px 2px; overflow-anchor: none; }
.activity-messages-dialog .activity-message-list:has(.message-more-menu[open]) { padding-bottom: 64px; }
.activity-message-composer { position: relative; flex: 0 0 auto; min-width: 0; }
.activity-message-composer .message-compose-wrap { --compose-controls-width: 140px; --compose-scrollbar-space: 16px; border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--panel); }
.activity-message-composer .message-compose-wrap:focus-within { border-color: var(--accent); outline: 2px solid color-mix(in srgb, var(--accent) 18%, transparent); outline-offset: 1px; }
/* Scroll the full-width editor, reserving room for the fixed controls and scrollbar. */
.activity-dialog .message-compose-editor { min-height: 36px; max-height: min(25dvh, 180px); padding: 8px 10px; padding-right: calc(var(--compose-controls-width) + var(--compose-scrollbar-space) + 10px); scrollbar-gutter: stable; border: 0; background: transparent; font-size: 13px; line-height: 20px; }
.activity-message-composer .message-compose-editor:focus { outline: 0; }
.activity-message-composer .message-compose-editor:empty::before { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.message-compose-controls { position: absolute; top: 0; right: var(--compose-scrollbar-space); width: var(--compose-controls-width); display: flex; align-items: center; gap: 2px; padding: 3px 4px 3px 0; }
.message-compose-controls > button { position: relative; top: auto; right: auto; flex: 0 0 30px; display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; padding: 0; border: 0; border-radius: 5px; background: transparent; cursor: pointer; }
.message-compose-controls > .message-compose-send { color: var(--accent); }
.message-compose-send:hover { background: color-mix(in srgb, var(--accent) 10%, transparent); }
.message-compose-send:disabled { opacity: .45; cursor: wait; }
.message-compose-divider { width: 1px; height: 18px; margin: 0 3px; background: var(--line-strong); }
.message-compose-controls [data-tooltip]:is(:hover, :focus-visible)::after { content: attr(data-tooltip); position: absolute; top: auto; bottom: calc(100% + 8px); left: auto; right: 0; transform: none; width: max-content; max-width: 180px; padding: 6px 8px; border-radius: 6px; background: #172126; color: #fff; font: 650 12px/1.25 var(--font-ui, sans-serif); z-index: 50; pointer-events: none; }
.message-compose-bottom-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 5px; }
.message-notify { display: flex; align-items: center; gap: 5px; min-width: 0; max-width: calc(100% - 34px); color: var(--muted); font-size: 11px; }
.message-notify .multi-select-dropdown { width: auto; min-width: 0; }
.activity-dialog .message-notify .multi-select-dropdown > summary { min-height: 26px; height: 26px; max-width: 260px; padding: 3px 6px; border-color: transparent; background: transparent; color: var(--muted); font-size: 11px; }
.message-notify .multi-select-dropdown > summary:hover { border-color: var(--line); background: var(--panel); }
.message-notify .multi-select-dropdown > summary::after { border-left-width: 4px; border-right-width: 4px; border-top-width: 4px; }
.message-notify .multi-select-menu { top: auto; bottom: calc(100% + 4px); right: auto; width: min(260px, calc(100vw - 110px)); max-height: min(220px, 30dvh); }
.message-compose-help { position: relative; flex: 0 0 auto; }
.message-compose-help > summary { display: flex; align-items: center; justify-content: center; width: 24px; height: 24px; list-style: none; border: 1px solid var(--line); border-radius: 50%; color: var(--muted); font-size: 12px; font-weight: 650; cursor: pointer; }
.message-compose-help > summary::-webkit-details-marker { display: none; }
.message-compose-help-content { position: absolute; bottom: calc(100% + 8px); right: 0; z-index: 50; width: min(290px, calc(100vw - 80px)); padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); color: var(--muted); box-shadow: var(--shadow); font-size: 12px; line-height: 1.5; }
.activity-message-composer .compose-emoji-menu { position: absolute; bottom: calc(100% + 6px); right: 0; z-index: 5; border-radius: var(--radius); }

.activity-dialog .activity-notes-actions { align-items: end; }
.activity-dialog .activity-notes-actions .button { height: 36px; min-height: 36px; padding: 6px 10px; font-size: 12px; }
.activity-dialog .review-notes-order-field { gap: 5px; }
.activity-dialog .review-notes-order-field span { line-height: 18px; font-size: 12px; font-weight: 650; }
.activity-dialog .dialog-footer { gap: 8px; padding-block: 12px; }
.activity-dialog .dialog-footer > .button { min-height: 36px; padding: 6px 12px; font-size: 13px; white-space: nowrap; }
.activity-dialog .dialog-footer > .dialog-action-menu { margin-right: 0; }
.activity-dialog .activity-save-help { margin-right: 0; }
.activity-dialog .dialog-footer > [data-close] { margin-left: auto; }
.activity-dialog .activity-save-help:empty { display: none; }
@media (max-width: 1000px) {
  .activity-dialog .dialog-grid { grid-template-columns: minmax(0, 1fr); }
  .activity-dialog .task-list-row { display: flex; flex-wrap: wrap; }
  .activity-dialog .task-list-row :is(.task-title-display, .task-title-input) { flex: 1; min-width: 100px; }
  .activity-dialog .task-list-row .task-instruction-compact { flex: 1 0 100%; order: 1; }
  .activity-dialog .task-list-row > :is(select, .manual-time-control, [data-toggle-task-timer], [data-toggle-task-complete], [data-delete-task]) { order: 2; }
  .activity-dialog .task-list-row select { flex: 1 1 140px; }
}
@media (max-width: 760px) {
  .activity-dialog .dialog-footer { flex-wrap: wrap; }
  .activity-dialog .activity-save-help { order: -1; flex-basis: 100%; max-width: none; font-size: 11px; }
}
@media (max-width: 600px) {
  .activity-dialog [data-booking-overrides] > .booking-period { grid-template-columns: minmax(0, 1fr); }
  .activity-dialog .activity-charge-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .activity-dialog .activity-charge-summary > div:last-child { grid-column: 1 / -1; }
}
@media (max-width: 480px) {
  .activity-dialog .task-view-actions { justify-content: flex-start; width: 100%; }
  .activity-dialog .task-view-toggle { order: 1; }
  .activity-dialog .activity-notes-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; }
  .activity-dialog .activity-notes-sync-button { grid-column: 1 / -1; justify-self: end; }
  .activity-dialog .review-notes-order-field { min-width: 0; }
  .activity-dialog .activity-kit-row-head-manual { grid-template-columns: minmax(0, 1fr) 36px; }
  .activity-dialog .activity-kit-row-head-manual > .field:first-child { grid-column: 1 / -1; }
  .activity-dialog .task-template-picker { flex-wrap: wrap; }
  .activity-dialog .task-template-picker select { flex: 1; width: auto; }
  .activity-dialog .dialog-footer > [data-toggle-activity-complete] { font-size: 12px; padding-inline: 8px; }
  .activity-dialog .dialog-footer:has(> button[type="submit"]) > [data-toggle-activity-complete] { flex: 1 0 calc(100% - 44px); }
}
