:root {
  --bg: #f4f6f5;
  --surface: #ffffff;
  --surface-2: #eef3f1;
  --line: #dde4e1;
  --line-strong: #c8d4d0;
  --text: #1d2523;
  --muted: #64716d;
  --soft: #8b9894;
  --teal: #0f766e;
  --teal-soft: #d9f1ed;
  --green: #1f8a5b;
  --green-soft: #dff3e8;
  --amber: #a76100;
  --amber-soft: #f8ecd2;
  --red: #b42318;
  --red-soft: #f8dddd;
  --blue: #2f5f98;
  --blue-soft: #e2ecf7;
  --shadow: 0 16px 38px rgba(23, 35, 31, 0.08);
  --shadow-soft: 0 8px 22px rgba(23, 35, 31, 0.06);
  font-family:
    Inter, "Segoe UI", "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--text);
  background: var(--bg);
}

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

button {
  border: 0;
  cursor: pointer;
}

.ui-icon,
.nav-icon,
.automation-icon,
.node-icon {
  flex: 0 0 auto;
  width: 17px;
  height: 17px;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.nav-icon {
  width: 18px;
  height: 18px;
}

.automation-icon {
  width: 20px;
  height: 20px;
  color: var(--green);
}

.node-icon {
  width: 13px;
  height: 13px;
}

.app-shell {
  display: grid;
  grid-template-columns: 264px minmax(0, 1fr);
  height: 100vh;
  min-height: 100vh;
  overflow: hidden;
}

.is-logged-out .app-shell {
  grid-template-columns: 1fr;
}

.is-logged-out .sidebar {
  display: none;
}

.sidebar {
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 22px 18px;
  background: #17231f;
  color: #f4f7f5;
}

.sidebar::-webkit-scrollbar {
  width: 8px;
}

.sidebar::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
}

.brand-block {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 4px 4px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 8px;
  color: #d7f4ef;
  font-weight: 800;
}

.brand-title {
  font-size: 17px;
  font-weight: 760;
}

.brand-subtitle {
  margin-top: 2px;
  color: #b7c6c1;
  font-size: 12px;
}

.nav-group {
  display: grid;
  gap: 4px;
}

.nav-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 38px;
  padding: 0 10px;
  border-radius: 8px;
  color: #d7dfdc;
  background: transparent;
  text-align: left;
}

.nav-label {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  gap: 10px;
}

.nav-label span,
.nav-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav-item:hover,
.nav-item.active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
}

.nav-count {
  min-width: 24px;
  padding: 2px 7px;
  border-radius: 999px;
  color: #ccded9;
  background: rgba(255, 255, 255, 0.1);
  font-size: 12px;
  text-align: center;
}

.sidebar-footer {
  margin-top: auto;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
}

.mini-label,
.eyebrow {
  color: var(--soft);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
}

.icon-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.icon-label .ui-icon {
  width: 15px;
  height: 15px;
  color: var(--teal);
}

.sidebar-footer .mini-label {
  color: #b7c6c1;
}

.sidebar-footer p {
  margin: 8px 0 0;
  color: #e8efec;
  font-size: 13px;
  line-height: 1.55;
}

.sidebar-panels {
  display: grid;
  gap: 12px;
}

.sidebar-card {
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
}

.sidebar-card-title {
  margin-bottom: 10px;
  color: #cbd9d5;
  font-size: 12px;
  font-weight: 780;
}

.avatar-list {
  display: grid;
  gap: 7px;
}

.avatar-row {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  min-height: 28px;
  color: #dce7e3;
  background: transparent;
  text-align: left;
}

.avatar-row:hover {
  color: #ffffff;
}

.avatar-row.static {
  cursor: default;
}

.avatar-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.avatar-count {
  min-width: 24px;
  padding: 2px 7px;
  border-radius: 999px;
  color: #dbe8e4;
  background: rgba(255, 255, 255, 0.1);
  font-size: 12px;
  text-align: center;
}

.pp-total {
  margin-bottom: 10px;
  color: #ffffff;
  font-size: 28px;
  font-weight: 820;
}

.pp-row {
  display: flex;
  justify-content: space-between;
  color: #b7c6c1;
  font-size: 12px;
}

.pp-row + .pp-row {
  margin-top: 6px;
}

.pp-row strong {
  color: #9de0c1;
}

.pp-leaderboard-grid {
  grid-template-columns: minmax(0, 1fr) minmax(300px, 360px);
}

.leaderboard-table th:first-child,
.leaderboard-table td:first-child {
  width: 72px;
  text-align: center;
}

.rank-badge {
  display: inline-grid;
  place-items: center;
  min-width: 28px;
  height: 28px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  font-weight: 780;
}

.rank-badge.top {
  border-color: rgba(20, 129, 112, 0.32);
  background: var(--green-soft);
  color: var(--green);
}

.person-cell,
.podium-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.podium-row {
  width: 100%;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.podium-row div {
  display: grid;
  gap: 3px;
}

.podium-row span:last-child {
  color: var(--muted);
  font-size: 12px;
}

.person-avatar {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
}

.person-avatar.xs {
  width: 20px;
  height: 20px;
  font-size: 10px;
}

.person-avatar.sm {
  width: 26px;
  height: 26px;
}

.person-avatar.lg {
  width: 44px;
  height: 44px;
  font-size: 16px;
}

.tone-reid {
  background: #315b54;
}

.tone-zhenxing {
  background: #6f62c9;
}

.tone-viea {
  background: #c99a14;
}

.tone-kevin {
  background: #1f5fae;
}

.tone-romi {
  background: #2a9d78;
}

.tone-amaro {
  background: #7e49bd;
}

.tone-default {
  background: var(--muted);
}

.workspace {
  min-width: 0;
  height: 100vh;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 24px;
  border-bottom: 1px solid var(--line);
  background: rgba(247, 248, 247, 0.94);
  backdrop-filter: blur(10px);
}

.topbar > div:first-child {
  flex: 1 1 auto;
  max-width: 520px;
  min-width: 0;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  overflow: hidden;
  font-size: 20px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

h2 {
  margin-bottom: 14px;
  font-size: 18px;
}

h3 {
  margin-bottom: 8px;
  font-size: 15px;
}

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

.user-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
  flex-wrap: nowrap;
}

.user-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--muted);
  font-size: 13px;
  white-space: nowrap;
}

.user-pill .person-avatar {
  margin-left: -2px;
}

.user-pill .ui-icon {
  width: 16px;
  height: 16px;
}

.user-pill.admin {
  color: var(--teal);
  border-color: #a8d8d0;
  background: var(--teal-soft);
}

.notification-dot {
  display: inline-grid;
  width: 22px;
  height: 22px;
  place-items: center;
  border-radius: 999px;
  color: #ffffff;
  background: var(--red);
  font-size: 11px;
  font-weight: 820;
}

.is-logged-out .search,
.is-logged-out #statusFilter,
.is-logged-out #quickImportBtn {
  display: none;
}

.is-logged-out .topbar {
  padding: 22px 32px;
}

.is-logged-out .topbar > div:first-child {
  max-width: none;
}

.search {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 220px;
  height: 38px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--muted);
  font-size: 13px;
}

.icon-only-action {
  width: 38px;
  padding: 0;
}

.search > span {
  display: inline-flex;
  align-items: center;
  color: var(--soft);
}

.search .ui-icon {
  width: 16px;
  height: 16px;
}

.search input {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--text);
}

select,
.input,
textarea {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
}

select,
.input {
  height: 38px;
  padding: 0 10px;
}

.primary,
.secondary,
.ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  height: 38px;
  padding: 0 13px;
  border-radius: 8px;
  font-weight: 700;
  white-space: nowrap;
}

.topbar-actions .primary,
.topbar-actions .secondary {
  padding: 0 11px;
}

.icon-button .ui-icon,
.primary .ui-icon,
.secondary .ui-icon {
  width: 16px;
  height: 16px;
}

.primary {
  color: #ffffff;
  background: var(--teal);
}

.secondary {
  color: var(--text);
  border: 1px solid var(--line);
  background: var(--surface);
}

.secondary.danger {
  color: var(--red);
  border-color: #efb6b1;
  background: #fff7f6;
}

.ghost {
  color: var(--muted);
  background: transparent;
}

.content {
  padding: 22px 24px 34px;
}

.grid {
  display: grid;
  gap: 16px;
}

.grid.overview {
  grid-template-columns: minmax(0, 1fr) minmax(420px, 460px);
  align-items: start;
}

.band,
.panel,
.table-wrap {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.band {
  padding: 16px;
}

.login-panel {
  width: min(460px, 100%);
  margin: 8vh auto 0;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.login-page {
  display: grid;
  min-height: calc(100vh - 104px);
  place-items: center;
  padding: 42px 24px 72px;
  background:
    linear-gradient(90deg, rgba(15, 118, 110, 0.05) 0 1px, transparent 1px) 0 0 / 72px 72px,
    linear-gradient(180deg, rgba(15, 118, 110, 0.05) 0 1px, transparent 1px) 0 0 / 72px 72px,
    var(--bg);
}

.login-shell {
  display: grid;
  grid-template-columns: minmax(360px, 460px) minmax(420px, 560px);
  gap: 18px;
  width: min(1040px, 100%);
}

.login-card,
.login-brief {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.login-card {
  display: grid;
  gap: 16px;
  padding: 24px;
}

.login-card-head,
.login-brief-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.login-card-head {
  justify-content: flex-start;
}

.login-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 8px;
  color: #e4fbf6;
  background: #17231f;
  font-weight: 860;
}

.login-card h2,
.login-brief h2 {
  margin-bottom: 0;
  font-size: 22px;
}

.login-copy {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.login-user-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.login-user-chip {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 7px;
  align-items: center;
  min-width: 0;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfb;
  text-align: left;
}

.login-user-chip:hover,
.login-user-chip.admin {
  border-color: #a8d8d0;
  background: var(--teal-soft);
}

.login-user-chip span,
.login-user-chip small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.login-user-chip span {
  font-weight: 760;
}

.login-user-chip small {
  grid-column: 2;
  color: var(--muted);
  font-size: 11px;
}

.login-form.enhanced {
  padding-top: 4px;
}

.login-form.enhanced .primary {
  width: 100%;
}

.login-hint {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid #cfe1dd;
  border-radius: 8px;
  background: #f8fbfa;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.login-hint strong {
  color: var(--teal);
}

.login-brief {
  display: grid;
  align-content: start;
  gap: 16px;
  overflow: hidden;
  padding: 24px;
  background:
    linear-gradient(135deg, rgba(15, 118, 110, 0.08), transparent 42%),
    var(--surface);
}

.sync-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 9px;
  border: 1px solid #cfe1dd;
  border-radius: 999px;
  color: var(--teal);
  background: #f4fbf9;
  font-size: 12px;
  font-weight: 760;
  white-space: nowrap;
}

.sync-badge .ui-icon {
  width: 14px;
  height: 14px;
}

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

.login-metrics .metric {
  background: rgba(255, 255, 255, 0.72);
}

.login-flow {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.login-flow div {
  display: grid;
  gap: 7px;
  min-height: 82px;
  place-items: center;
  padding: 10px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfb;
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
  text-align: center;
}

.login-flow .ui-icon {
  width: 20px;
  height: 20px;
  color: var(--teal);
}

.login-schedule-preview {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(15, 118, 110, 0.26) 0 2px, transparent 2px) 0 0 / 25% 100%,
    #fbfcfb;
}

.preview-lane {
  display: grid;
  grid-template-columns: 22px 64px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-height: 30px;
}

.preview-lane span {
  overflow: hidden;
  color: var(--text);
  font-size: 12px;
  font-weight: 760;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.preview-lane i {
  position: relative;
  height: 18px;
  border-radius: 5px;
  background: #eaf1ee;
}

.preview-lane i::after {
  position: absolute;
  inset: 2px auto 2px var(--offset);
  width: var(--width);
  border-radius: 4px;
  background: var(--blue);
  content: "";
}

.login-form,
.modal-panel {
  display: grid;
  gap: 14px;
}

.login-form label,
.modal-panel label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(17, 26, 23, 0.38);
}

.modal-panel {
  width: min(480px, 100%);
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.modal-panel.wide {
  width: min(720px, 100%);
}

.permission-note {
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 13px;
}

.summary-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.metric {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.metric-value {
  margin-top: 6px;
  font-size: 26px;
  font-weight: 780;
}

.ops-command {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 12px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.ops-title h2 {
  display: none;
}

.ops-actions,
.planner-toolbar,
.board-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.ops-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.ops-metrics {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.ops-metrics .metric {
  box-shadow: none;
}

.automation-strip {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
  padding: 12px 14px;
  border: 1px solid #cfe1dd;
  border-radius: 8px;
  background: #f8fbfa;
}

.planning-controlbar {
  display: grid;
  grid-template-columns: 260px minmax(320px, 1fr) auto auto 230px;
  gap: 10px;
  align-items: center;
  margin-bottom: 12px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.date-stepper {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 34px;
  align-items: center;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.date-stepper strong {
  overflow: hidden;
  padding: 0 10px;
  border-right: 1px solid var(--line);
  border-left: 1px solid var(--line);
  font-size: 13px;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.icon-only {
  width: 34px;
  padding: 0;
}

.flip-icon {
  transform: rotate(180deg);
}

.worktime-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 720;
  white-space: nowrap;
}

.worktime-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.worktime-toggle i {
  position: relative;
  width: 34px;
  height: 20px;
  border-radius: 999px;
  background: var(--teal);
}

.worktime-toggle i::after {
  position: absolute;
  top: 3px;
  right: 3px;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: #ffffff;
  content: "";
}

.sync-state {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.sync-state .ui-icon {
  width: 14px;
  height: 14px;
  color: var(--teal);
}

.automation-head {
  display: grid;
  gap: 4px;
}

.automation-head strong {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--teal);
}

.automation-head span,
.automation-item small {
  color: var(--muted);
  font-size: 12px;
}

.automation-items {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.automation-item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.automation-item .automation-icon {
  padding: 3px;
  border-radius: 999px;
  background: var(--green-soft);
}

.automation-item strong,
.automation-item small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sync-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--green);
  box-shadow: 0 0 0 4px var(--green-soft);
}

.planner-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 12px;
  align-items: start;
}

.planner-main,
.planner-inspector,
.recommendation-board {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.planner-main {
  min-width: 0;
  overflow: hidden;
}

.planner-toolbar {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  background: #fbfcfb;
}

.dependency-rail {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 10px;
  align-items: stretch;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  background: #fbfcfb;
}

.rail-label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border-right: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  font-weight: 780;
}

.rail-label .ui-icon {
  color: var(--teal);
}

.dependency-flow {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  overflow-x: auto;
  padding-bottom: 2px;
}

.dependency-node {
  display: grid;
  gap: 4px;
  min-width: 154px;
  max-width: 190px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  text-align: left;
}

.dependency-node span,
.dependency-node small {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 760;
}

.dependency-node strong {
  overflow: hidden;
  color: var(--text);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dependency-node.status-doing {
  border-color: #9dbce3;
  background: var(--blue-soft);
}

.dependency-node.status-review {
  border-color: #e7c785;
  background: var(--amber-soft);
}

.dependency-node.status-done {
  border-color: #a7d9c0;
  background: var(--green-soft);
}

.dependency-node.status-blocked,
.dependency-node.status-returned {
  border-color: #e9a5a1;
  background: var(--red-soft);
}

.dependency-arrow {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  color: var(--soft);
  font-weight: 800;
}

.dependency-arrow .ui-icon {
  width: 15px;
  height: 15px;
}

.planner-inspector {
  position: sticky;
  top: 92px;
  padding: 14px;
}

.inspector-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
}

.inspector-head h2 {
  margin-bottom: 0;
  font-size: 18px;
  line-height: 1.35;
}

.inspector-progress {
  display: grid;
  gap: 8px;
  padding: 12px;
  border-radius: 8px;
  background: #f7faf9;
}

.inspector-progress div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.inspector-progress strong {
  font-size: 22px;
}

.inspector-progress span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 740;
}

progress {
  width: 100%;
  height: 8px;
  overflow: hidden;
  border: 0;
  border-radius: 999px;
  background: var(--surface-2);
}

progress::-webkit-progress-bar {
  background: var(--surface-2);
}

progress::-webkit-progress-value {
  border-radius: 999px;
  background: var(--teal);
}

.inspector-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 12px 0;
}

.inspector-grid div {
  display: grid;
  gap: 4px;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfb;
}

.inspector-grid span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 760;
}

.inspector-grid strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.inspector-section {
  padding: 12px 0;
  border-top: 1px solid var(--line);
}

.inspector-section h3 {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 6px;
}

.inspector-section h3 .ui-icon {
  width: 15px;
  height: 15px;
  color: var(--teal);
}

.inspector-section p,
.inspector-section ul {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.inspector-section ul {
  padding-left: 18px;
}

.inspector-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.recommendation-board {
  margin-top: 12px;
  padding: 14px;
}

.board-title {
  margin-bottom: 12px;
}

.board-title h2 {
  margin-bottom: 0;
}

.recommendation-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.recommendation-column {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfb;
}

.recommendation-column h3 {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  margin-bottom: 10px;
}

.recommendation-column h3 span {
  display: grid;
  min-width: 24px;
  height: 24px;
  place-items: center;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 12px;
}

.recommendation-column h3 > .ui-icon {
  width: 17px;
  height: 17px;
  color: var(--teal);
}

.recommendation-column h3 .column-title {
  display: inline;
  flex: 1;
  min-width: 0;
  height: auto;
  overflow: hidden;
  place-items: initial;
  border-radius: 0;
  background: transparent;
  color: var(--text);
  font-size: 15px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recommendation-column.hot {
  border-color: #f0c7c2;
}

.recommendation-column.review {
  border-color: #eed79d;
}

.recommendation-column.blocked {
  border-color: #d8c1f0;
}

.recommendation-column.free {
  border-color: #adddcc;
}

.recommendation-item {
  display: grid;
  gap: 5px;
  width: 100%;
  margin-top: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  text-align: left;
}

.recommendation-item:hover {
  border-color: #9fd2cb;
  background: #f6fbfa;
}

.recommendation-item strong,
.recommendation-item span,
.recommendation-item small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recommendation-item span {
  color: var(--teal);
  font-size: 12px;
  font-weight: 740;
}

.recommendation-item small {
  color: var(--muted);
  font-size: 12px;
}

.people-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.person-card {
  display: grid;
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfb;
  text-align: left;
}

.person-card:hover {
  border-color: #a8d8d0;
  background: #f5fbfa;
}

.person-card-head {
  display: flex;
  align-items: center;
  gap: 10px;
}

.person-card-head strong,
.person-card-head span {
  display: block;
}

.person-card-head span {
  display: -webkit-box;
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.person-card-metrics,
.settings-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.person-card-metrics span,
.settings-card {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--muted);
  font-size: 12px;
}

.person-card-metrics strong {
  display: block;
  margin-top: 4px;
  color: var(--text);
  font-size: 18px;
}

.automation-log {
  display: grid;
  gap: 8px;
}

.log-entry {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfb;
  color: var(--muted);
}

.log-entry .ui-icon {
  width: 16px;
  height: 16px;
  color: var(--green);
}

.export-center {
  max-width: 720px;
}

.settings-page {
  display: grid;
  gap: 14px;
}

.settings-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.settings-card {
  display: grid;
  gap: 10px;
  color: var(--text);
}

.settings-card h3 {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.settings-card h3 .ui-icon {
  width: 16px;
  height: 16px;
  color: var(--teal);
}

.timeline {
  display: grid;
  grid-template-columns: repeat(5, minmax(120px, 1fr));
  gap: 10px;
}

.milestone {
  position: relative;
  min-height: 112px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfb;
}

.milestone strong {
  display: block;
  margin-bottom: 8px;
  color: var(--teal);
}

.milestone p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.schedule-hero {
  overflow: hidden;
}

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

.schedule-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}

.schedule-tabs {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfb;
}

.schedule-legend {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px 12px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 740;
}

.timeline-key {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
  padding: 0;
  background: transparent;
}

.timeline-key .schedule-legend {
  justify-content: flex-start;
}

.level-legend {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 740;
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.legend-dot {
  width: 10px;
  height: 10px;
  border: 1px solid rgba(23, 35, 31, 0.14);
  border-radius: 3px;
}

.legend-dot.status-todo {
  border-color: rgba(100, 113, 109, 0.24);
  background: #eaf1ee;
}

.legend-dot.status-doing {
  border-color: rgba(47, 95, 152, 0.46);
  background: var(--blue);
}

.legend-dot.status-review {
  border-color: rgba(167, 97, 0, 0.46);
  background: var(--amber);
}

.legend-dot.status-done {
  border-color: rgba(31, 138, 91, 0.46);
  background: var(--green);
}

.legend-dot.status-blocked {
  border-color: rgba(180, 35, 24, 0.46);
  background: var(--red);
}

.tab-button {
  min-height: 32px;
  padding: 0 12px;
  border-radius: 6px;
  color: var(--muted);
  background: transparent;
  font-size: 13px;
  font-weight: 760;
}

.tab-button:hover,
.tab-button.active {
  color: #ffffff;
  background: var(--teal);
}

.schedule-chart {
  display: grid;
  gap: 8px;
  overflow-x: auto;
}

.schedule-axis {
  display: grid;
  grid-template-columns: repeat(8, minmax(70px, 1fr));
  min-width: var(--chart-min-width, 820px);
  padding-left: 150px;
  color: var(--soft);
  font-size: 11px;
  font-weight: 700;
}

.schedule-axis span {
  min-height: 22px;
  padding-left: 8px;
  border-left: 3px solid rgba(15, 118, 110, 0.52);
}

.schedule-chart.compact .schedule-axis {
  grid-template-columns: repeat(7, minmax(58px, 1fr));
  min-width: 620px;
  padding-left: 132px;
}

.schedule-lanes {
  display: grid;
  gap: 8px;
  min-width: var(--chart-min-width, 820px);
}

.schedule-chart.compact .schedule-lanes {
  min-width: 620px;
}

.schedule-lane {
  display: grid;
  grid-template-columns: 140px minmax(420px, 1fr);
  gap: 10px;
  align-items: center;
  min-height: 46px;
  padding: 0;
}

.schedule-chart.compact .schedule-lane {
  grid-template-columns: 122px minmax(360px, 1fr);
  min-height: 42px;
}

.lane-person {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfb;
}

.lane-person > div {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.lane-person strong,
.lane-person small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lane-person small {
  color: var(--muted);
  font-size: 12px;
}

.lane-track {
  position: relative;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(15, 118, 110, 0.52) 0 3px, transparent 3px) 0 0 / calc(100% / var(--axis-count, 7)) 100%,
    linear-gradient(90deg, rgba(15, 118, 110, 0.08) 1px, transparent 1px) 0 0 / calc(100% / var(--axis-count, 7)) 100%,
    #fbfcfb;
}

.schedule-lane.empty .lane-track {
  opacity: 0.55;
}

.schedule-block {
  position: absolute;
  top: 6px;
  bottom: 6px;
  min-width: 28px;
  border: 1px solid rgba(23, 35, 31, 0.22);
  border-radius: 6px;
  color: #ffffff;
  font-size: 11px;
  font-weight: 760;
  line-height: 20px;
  overflow: hidden;
  text-align: center;
  white-space: nowrap;
  box-shadow:
    inset -3px 0 rgba(23, 35, 31, 0.22),
    inset 1px 0 rgba(255, 255, 255, 0.38),
    0 1px 2px rgba(23, 35, 31, 0.16);
}

.schedule-block + .schedule-block {
  box-shadow:
    -2px 0 0 #ffffff,
    inset -3px 0 rgba(23, 35, 31, 0.22),
    inset 1px 0 rgba(255, 255, 255, 0.38),
    0 1px 2px rgba(23, 35, 31, 0.16);
}

.schedule-block:hover {
  filter: brightness(0.95);
  outline: 2px solid rgba(15, 118, 110, 0.22);
  outline-offset: 1px;
}

.schedule-block.status-todo {
  color: var(--muted);
  border-color: rgba(100, 113, 109, 0.24);
  background: #eaf1ee;
  box-shadow:
    inset -2px 0 rgba(100, 113, 109, 0.24),
    inset 1px 0 rgba(255, 255, 255, 0.75),
    0 1px 2px rgba(23, 35, 31, 0.12);
}

.schedule-block.status-doing {
  border-color: rgba(47, 95, 152, 0.46);
  background: var(--blue);
}

.schedule-block.status-review {
  border-color: rgba(167, 97, 0, 0.46);
  background: var(--amber);
}

.schedule-block.status-done {
  border-color: rgba(31, 138, 91, 0.46);
  background: var(--green);
}

.schedule-block.status-returned,
.schedule-block.status-blocked {
  border-color: rgba(180, 35, 24, 0.46);
  background: var(--red);
}

.schedule-block span {
  display: block;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  padding: 0 6px;
  text-overflow: ellipsis;
}

.schedule-tooltip {
  position: fixed;
  z-index: 30;
  display: none;
  max-width: min(420px, calc(100vw - 24px));
  padding: 10px 12px;
  border: 1px solid rgba(15, 118, 110, 0.24);
  border-radius: 8px;
  color: #f7fbf9;
  background: rgba(23, 35, 31, 0.96);
  box-shadow: 0 12px 32px rgba(23, 35, 31, 0.22);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.55;
  pointer-events: none;
}

.schedule-tooltip.visible {
  display: block;
}

.empty-state {
  padding: 18px;
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
  color: var(--muted);
  background: #fbfcfb;
  font-size: 13px;
}

.toolbar {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.segment {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 0 9px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}

.chip.active {
  background: var(--teal-soft);
  color: var(--teal);
}

.chip.level {
  min-width: 64px;
  max-width: 88px;
  padding: 0 8px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chip.level.core {
  background: var(--teal-soft);
  color: var(--teal);
}

.chip.level.key {
  background: var(--blue-soft);
  color: var(--blue);
}

.chip.level.standard {
  background: var(--surface-2);
  color: var(--muted);
}

.chip.level.support {
  background: var(--amber-soft);
  color: var(--amber);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

th,
td {
  padding: 12px 11px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--muted);
  background: #fbfcfb;
  font-size: 12px;
  font-weight: 780;
}

tr:hover td {
  background: #f9fbfa;
}

tr.selected td {
  background: #eef7f5;
}

.task-title {
  font-weight: 740;
}

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

.small {
  font-size: 12px;
}

.status {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 760;
  white-space: nowrap;
}

.status.未开始,
.status.待办 {
  color: var(--muted);
  background: var(--surface-2);
}

.status.进行中 {
  color: var(--blue);
  background: var(--blue-soft);
}

.status.待验收,
.status.待审核 {
  color: var(--amber);
  background: var(--amber-soft);
}

.status.已完成 {
  color: var(--green);
  background: var(--green-soft);
}

.status.阻塞,
.status.退回 {
  color: var(--red);
  background: var(--red-soft);
}

.detail-panel {
  position: sticky;
  top: 94px;
  display: flex;
  flex-direction: column;
  max-height: calc(100vh - 118px);
  min-width: 0;
  padding: 0;
  overflow: hidden;
}

.detail-panel > .mini-label,
.detail-panel > h2,
.detail-panel > .status,
.detail-panel > dl {
  margin-right: 16px;
  margin-left: 16px;
}

.detail-panel > .mini-label {
  margin-top: 16px;
}

.detail-panel > h2 {
  margin-top: 4px;
  margin-bottom: 10px;
  overflow-wrap: anywhere;
  line-height: 1.35;
}

.detail-panel > .status {
  width: fit-content;
}

.detail-panel dl {
  display: grid;
  flex: 0 0 auto;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 14px;
  max-height: 280px;
  margin-top: 14px;
  margin-bottom: 12px;
  padding-right: 6px;
  overflow-y: auto;
}

.detail-panel dl div:nth-child(n + 5) {
  grid-column: 1 / -1;
}

.detail-panel dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 780;
}

.detail-panel dd {
  margin: 4px 0 0;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.detail-actions {
  position: sticky;
  bottom: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 0 -16px -14px;
  padding: 12px 16px 14px;
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), var(--surface));
  box-shadow: 0 -10px 22px rgba(23, 35, 31, 0.06);
}

.acceptance-page {
  display: grid;
  gap: 14px;
}

.acceptance-head,
.acceptance-controls,
.acceptance-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.acceptance-head h2 {
  margin: 0;
  font-size: 24px;
}

.acceptance-controls {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.acceptance-controls label {
  display: grid;
  min-width: 140px;
  gap: 4px;
  color: var(--muted);
  font-size: 12px;
}

.acceptance-controls select {
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
}

.date-stepper.compact {
  width: 260px;
}

.acceptance-metrics {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.acceptance-metric {
  display: grid;
  gap: 8px;
  min-height: 76px;
  padding: 14px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--line-strong);
  border-radius: 8px;
  background: var(--surface);
}

.acceptance-metric span {
  color: var(--muted);
  font-size: 13px;
}

.acceptance-metric strong {
  font-size: 26px;
}

.acceptance-metric.due {
  border-left-color: var(--blue);
}

.acceptance-metric.review {
  border-left-color: var(--amber);
}

.acceptance-metric.done {
  border-left-color: var(--green);
}

.acceptance-metric.returned,
.acceptance-metric.overdue {
  border-left-color: var(--red);
}

.acceptance-timeline {
  padding: 14px;
}

.acceptance-section-head h3 {
  margin: 2px 0 0;
  font-size: 16px;
}

.acceptance-axis {
  display: grid;
  grid-template-columns: repeat(10, minmax(64px, 1fr));
  margin: 14px 0 6px 130px;
  color: var(--muted);
  font-size: 12px;
}

.acceptance-lanes {
  display: grid;
  gap: 8px;
}

.acceptance-lane {
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.acceptance-lane-person {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
  font-size: 13px;
}

.acceptance-track {
  position: relative;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    repeating-linear-gradient(90deg, transparent 0, transparent calc(11.111% - 1px), rgba(15, 118, 110, 0.14) calc(11.111% - 1px), rgba(15, 118, 110, 0.14) 11.111%),
    #fbfcfc;
  overflow: hidden;
}

.acceptance-time-block {
  position: absolute;
  top: 6px;
  height: 22px;
  padding: 0 8px;
  border: 1px solid transparent;
  border-radius: 6px;
  color: var(--text);
  font-size: 12px;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.acceptance-time-block span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
}

.acceptance-due,
.legend-dot.acceptance-due {
  border-color: rgba(47, 95, 152, 0.35);
  background: var(--blue-soft);
  color: var(--blue);
}

.acceptance-review,
.legend-dot.acceptance-review {
  border-color: rgba(167, 97, 0, 0.35);
  background: var(--amber-soft);
  color: var(--amber);
}

.acceptance-done,
.legend-dot.acceptance-done {
  border-color: rgba(31, 138, 91, 0.32);
  background: var(--green-soft);
  color: var(--green);
}

.acceptance-returned,
.legend-dot.acceptance-returned {
  border-color: rgba(180, 35, 24, 0.32);
  background: var(--red-soft);
  color: var(--red);
}

.acceptance-empty {
  display: inline-flex;
  align-items: center;
  height: 100%;
  padding-left: 12px;
  color: var(--soft);
  font-size: 12px;
}

.acceptance-workspace {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr) minmax(360px, 410px);
  gap: 12px;
  align-items: start;
}

.acceptance-inbox,
.acceptance-list,
.acceptance-inspector {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.acceptance-inbox {
  display: grid;
  gap: 6px;
  padding: 12px;
  position: sticky;
  top: 14px;
}

.inbox-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 34px;
  padding: 0 9px;
  border-radius: 8px;
  background: transparent;
  color: var(--text);
}

.inbox-row span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.inbox-row.active {
  background: var(--teal-soft);
  color: var(--teal);
}

.inbox-row strong {
  font-size: 13px;
}

.acceptance-list {
  display: grid;
  gap: 12px;
  padding: 12px;
}

.acceptance-group {
  border-left: 3px solid var(--line-strong);
}

.acceptance-group.blue {
  border-left-color: var(--blue);
}

.acceptance-group.amber {
  border-left-color: var(--amber);
}

.acceptance-group.green {
  border-left-color: var(--green);
}

.acceptance-group.red {
  border-left-color: var(--red);
}

.acceptance-group-title {
  display: flex;
  justify-content: space-between;
  width: 100%;
  padding: 8px 10px;
  background: transparent;
  color: var(--text);
  text-align: left;
}

.acceptance-group-title span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 760;
}

.acceptance-group-title strong {
  min-width: 22px;
  padding: 2px 7px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.acceptance-group-title small {
  color: var(--muted);
}

.acceptance-table {
  font-size: 13px;
}

.acceptance-table tr.selected {
  background: rgba(15, 118, 110, 0.08);
}

.acceptance-table td:first-child {
  width: 30%;
}

.compact-action {
  min-height: 30px;
  padding: 0 10px;
  border-radius: 7px;
  font-size: 13px;
}

.acceptance-inspector {
  position: sticky;
  top: 14px;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  max-height: calc(100vh - 120px);
  overflow: hidden;
}

.acceptance-inspector-scroll {
  display: grid;
  gap: 14px;
  padding: 16px;
  overflow-y: auto;
}

.acceptance-inspector-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.acceptance-inspector-head h2 {
  margin: 2px 0 0;
  font-size: 18px;
  line-height: 1.35;
}

.acceptance-detail-list {
  display: grid;
  gap: 10px;
  margin: 0;
}

.acceptance-detail-list div {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}

.acceptance-detail-list dt {
  color: var(--muted);
  font-size: 12px;
}

.acceptance-detail-list dd {
  margin: 0;
  line-height: 1.45;
}

.acceptance-detail-section {
  display: grid;
  gap: 8px;
}

.acceptance-detail-section h3 {
  margin: 0;
  font-size: 14px;
}

.acceptance-detail-section ul {
  display: grid;
  gap: 6px;
  margin: 0;
  padding-left: 18px;
  color: var(--text);
  font-size: 13px;
  line-height: 1.45;
}

.acceptance-detail-section li span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.acceptance-detail-section textarea {
  min-height: 78px;
}

.acceptance-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  padding: 12px;
  border-top: 1px solid var(--line);
  background: var(--surface);
}

.acceptance-actions .secondary:first-child {
  grid-column: 1 / -1;
}

.danger {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid rgba(180, 35, 24, 0.25);
  border-radius: 8px;
  background: var(--red);
  color: #fff;
  font-weight: 720;
}

.person-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 16px;
  margin-bottom: 16px;
}

.responsibility-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.output-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.output-item {
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.output-item h3 {
  margin-bottom: 6px;
}

.timeline-page {
  display: grid;
  gap: 14px;
}

.timeline-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 14px;
  align-items: stretch;
}

.timeline-node {
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  font-weight: 780;
  text-align: center;
}

.timeline-content {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.doc-import {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 16px;
  align-items: start;
}

textarea {
  width: 100%;
  min-height: 320px;
  padding: 12px;
  resize: vertical;
  line-height: 1.55;
}

.field-stack {
  display: grid;
  flex: 1 1 auto;
  gap: 9px;
  min-height: 0;
  padding: 0 16px 14px;
  overflow-y: auto;
}

.role-edit-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.role-edit-grid label {
  display: grid;
  gap: 5px;
}

.role-edit-grid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 780;
}

.field-stack textarea {
  min-height: 84px;
}

.field-stack .permission-note {
  margin-top: 2px;
  padding-bottom: 2px;
}

.code-block {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f0f4f2;
  color: var(--text);
  overflow: auto;
}

.dropzone {
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
  background: #fbfcfb;
}

.analysis-log {
  display: grid;
  gap: 8px;
}

.log-line {
  padding: 10px;
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 13px;
}

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

.list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.list li {
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  line-height: 1.45;
}

@media (max-width: 1440px) {
  .grid.overview {
    grid-template-columns: minmax(0, 1fr) minmax(390px, 420px);
  }

  .detail-panel dl {
    grid-template-columns: 1fr;
    max-height: 230px;
  }

  .role-edit-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1120px) {
  .app-shell,
  .grid.overview,
  .planner-shell,
  .acceptance-workspace,
  .person-header,
  .doc-import,
  .login-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
    overflow: visible;
  }

  .app-shell {
    height: auto;
    overflow: visible;
  }

  .workspace {
    height: auto;
    overflow: visible;
  }

  .detail-panel {
    position: static;
    max-height: none;
    overflow: visible;
  }

  .detail-panel dl,
  .field-stack {
    max-height: none;
    overflow: visible;
  }

  .detail-actions {
    position: static;
    margin: 0;
    padding: 0;
    border-top: 0;
    background: transparent;
    box-shadow: none;
  }

  .timeline,
  .summary-row,
  .ops-metrics,
  .acceptance-head,
  .acceptance-controls,
  .acceptance-metrics,
  .planning-controlbar,
  .automation-strip,
  .automation-items,
  .people-grid,
  .settings-grid,
  .recommendation-grid,
  .output-grid,
  .risk-grid,
  .timeline-content,
  .role-edit-grid,
  .login-metrics,
  .login-flow {
    grid-template-columns: 1fr;
  }

  .login-user-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ops-command,
  .planner-toolbar,
  .board-title {
    align-items: flex-start;
    flex-direction: column;
  }

  .planner-inspector {
    position: static;
  }

  .acceptance-inbox,
  .acceptance-inspector {
    position: static;
    max-height: none;
  }

  .acceptance-lane {
    grid-template-columns: 90px minmax(720px, 1fr);
  }

  .dependency-rail {
    grid-template-columns: 1fr;
  }

  .rail-label {
    justify-content: start;
    place-items: start;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding-bottom: 8px;
  }

  .schedule-controls {
    align-items: flex-start;
    flex-direction: column;
  }

  .schedule-legend {
    justify-content: flex-start;
  }

  .topbar {
    align-items: stretch;
    flex-direction: column;
  }

  .topbar-actions {
    flex-wrap: wrap;
  }
}
