
:root {
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 16px;
  color: #263d37;
  background: #f6f8f7;
  font-synthesis: none;
  --accent: #176c5b;
  --accent-soft: #eaf4ef;
  --surface: #fff;
  --bg: #f6f8f7;
  --text: #263d37;
  --muted: #7b8983;
  --line: #e4eae6;
  --hover: #f0f5f2;
  --blue: #eaf0f9;
  --blue-text: #527bb5;
  --peach: #faf0e9;
  --peach-text: #af7651;
  --violet: #f0edf6;
  --violet-text: #8a74a9;
  --shadow: 0 16px 60px #17392c20;
  letter-spacing: 0;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --surface: #202924;
  --bg: #171e1a;
  --text: #e0e8e3;
  --muted: #a0afa5;
  --line: #344239;
  --hover: #2c3830;
  --accent-soft: #2b4438;
  --accent: #7acbb0;
  --blue: #283648;
  --blue-text: #99b7e1;
  --peach: #41332b;
  --peach-text: #ddb18d;
  --violet: #353044;
  --violet-text: #bdb0d1;
  color-scheme: dark;
}
:root[data-accent="blue"] {
  --accent: #3868b0;
  --accent-soft: #edf2fb;
}
:root[data-accent="rose"] {
  --accent: #a14b64;
  --accent-soft: #faedf1;
}
:root[data-theme="dark"][data-accent="blue"] {
  --accent: #94b8ed;
  --accent-soft: #293b52;
}
:root[data-theme="dark"][data-accent="rose"] {
  --accent: #e1a1b4;
  --accent-soft: #49323b;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
}
button,
input,
select,
textarea {
  font: inherit;
  letter-spacing: 0;
}
button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
  color: inherit;
}
button:disabled {
  cursor: default;
  opacity: 0.5;
}
button,
a {
  touch-action: manipulation;
}
button {
  border: 0;
  background: none;
}
a {
  color: inherit;
  text-decoration: none;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid #7aafca;
  outline-offset: 3px;
}
h1,
h2,
h3,
h4,
p {
  margin: 0;
}
h1,
h2,
h3,
h4 {
  font-family: "Manrope", system-ui, sans-serif;
}
h1 {
  font-size: 30px;
  font-weight: 750;
  line-height: 1.3;
}
h2 {
  font-size: 18px;
  font-weight: 750;
  line-height: 1.4;
}
h3 {
  font-size: 18px;
  line-height: 1.4;
}
h4 {
  font-size: 15px;
}
p {
  line-height: 1.6;
}
input,
select,
textarea {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 5px;
  color: var(--text);
  padding: 10px 12px;
  min-height: 40px;
  max-width: 100%;
  width: 100%;
  transition: border-color 0.15s;
}
input:focus,
textarea:focus,
select:focus {
  border-color: var(--accent);
}
input::placeholder,
textarea::placeholder {
  color: var(--muted);
}
textarea {
  resize: vertical;
  min-height: 88px;
}
small {
  font-size: 13.5px;
  color: var(--muted);
}
.muted {
  color: var(--muted);
}
.eyebrow {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 8px;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 39px;
  padding: 9px 14px;
  font-size: 14.5px;
  font-weight: 650;
  border-radius: 5px;
  border: 1px solid transparent;
  white-space: normal;
  transition:
    background 0.15s,
    transform 0.15s;
}
.button:active {
  transform: translateY(1px);
}
.primary {
  background: var(--accent);
  color: white;
}
.primary:hover {
  filter: brightness(1.08);
}
:root[data-theme="dark"] .primary {
  color: #17231d;
}
.secondary {
  background: var(--surface);
  border-color: var(--line);
}
.secondary:hover,
.secondary.selected {
  background: var(--hover);
  border-color: var(--accent);
}
.full {
  width: 100%;
}
.icon-button {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border-radius: 5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
}
.icon-button:hover {
  background: var(--hover);
  color: var(--accent);
}
.text-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent);
  font-size: 14.5px;
  font-weight: 600;
  padding: 0;
}
.text-link:hover {
  text-decoration: underline;
}
.actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.spacer {
  flex: 1;
}
.spin {
  animation: spin 1s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  clip: rect(0, 0, 0, 0);
  overflow: hidden;
  white-space: nowrap;
}
.small-tag {
  display: inline-flex;
  align-items: center;
  background: var(--hover);
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 4px;
  font-size: 12.5px;
  font-weight: 550;
  padding: 5px 8px;
  line-height: 1.4;
}
.empty {
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 10px;
  padding: 55px 20px;
  color: var(--muted);
}
.empty h3 {
  color: var(--text);
  font-size: 17px;
}
.empty p {
  font-size: 14.5px;
  max-width: 350px;
}
.loading-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 20px;
  color: var(--accent);
}

/* Workspace shell */
.app-shell {
  min-height: 100vh;
}
.sidebar {
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  width: 232px;
  background: var(--surface);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  padding: 28px 16px 0;
  z-index: 30;
  overflow: auto;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-family: "Manrope", sans-serif;
  font-weight: 800;
  flex-shrink: 0;
}
.brand-icon {
  background: var(--accent);
  color: white;
  width: 38px;
  height: 42px;
  border-radius: 7px;
  display: grid;
  place-items: center;
}
.brand small {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin-top: 4px;
  font-family: "DM Sans", sans-serif;
  font-weight: 650;
}
.sidebar .brand {
  padding-left: 6px;
}
.workspace-label {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 14px 9px;
  border: 1px solid var(--line);
  border-radius: 6px;
  margin: 27px 0 25px;
  font-size: 14.5px;
  font-weight: 600;
}
.workspace-label small {
  display: block;
  margin-top: 3px;
  font-size: 12.5px;
  font-weight: 400;
}
.workspace-label > svg {
  margin-left: auto;
  color: var(--muted);
}
.workspace-avatar {
  width: 30px;
  height: 32px;
  display: grid;
  place-items: center;
  background: var(--accent-soft);
  color: var(--accent);
  border-radius: 4px;
  font-size: 12.5px;
  font-weight: 750;
}
.nav-label {
  display: block;
  font-size: 11px;
  color: var(--muted);
  font-weight: 650;
  padding: 0 11px;
  margin-bottom: 9px;
}
.sidebar nav > .nav-label {
  margin-top: 23px;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  min-height: 40px;
  border-radius: 5px;
  padding: 10px 12px;
  color: var(--muted);
  font-size: 14.5px;
  font-weight: 550;
  text-align: left;
  margin: 3px 0;
}
.nav-item.active {
  color: var(--accent);
  background: var(--accent-soft);
  font-weight: 700;
}
.nav-item:hover {
  background: var(--hover);
}
.nav-item b {
  margin-left: auto;
  font-size: 12.5px;
  background: var(--surface);
  padding: 2px 6px;
  border-radius: 3px;
}
.sidebar-bottom {
  margin-top: auto;
  padding-top: 35px;
}
.local-status {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  color: var(--muted);
  padding: 12px 6px;
  border-bottom: 1px solid var(--line);
}
.local-status i {
  width: 5px;
  height: 5px;
  background: #6d9b85;
  border-radius: 50%;
}
.local-status span {
  margin-left: auto;
}
.user-area {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
}
.user-area > button:first-child {
  display: flex;
  gap: 10px;
  align-items: center;
  text-align: left;
  padding: 0;
}
.avatar {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--peach);
  color: var(--peach-text);
  font-weight: 700;
  flex-shrink: 0;
}
.user-area strong {
  font-size: 14.5px;
}
.user-area small {
  display: block;
  font-size: 12.5px;
  margin-top: 2px;
}
.workspace {
  margin-left: 232px;
  min-width: 0;
}
.topbar {
  height: 74px;
  position: sticky;
  top: 0;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  padding: 0 32px;
}
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13.5px;
  color: var(--muted);
  white-space: nowrap;
}
.breadcrumb strong {
  font-weight: 550;
  color: var(--text);
}
.topbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.global-search {
  display: flex;
  align-items: center;
  color: var(--muted);
  gap: 6px;
}
.global-search input {
  background: none;
  border: 0;
  min-height: 32px;
  width: 150px;
  padding: 5px;
  font-size: 13.5px;
}
.topbar-divider {
  height: 23px;
  width: 1px;
  background: var(--line);
  margin-right: 3px;
}
.workspace main {
  max-width: 1640px;
  margin: 0 auto;
  padding: 33px 34px 0;
  min-height: calc(100vh - 74px);
}
.page-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
}
.page-heading p {
  font-size: 14.5px;
  color: var(--muted);
  margin-top: 8px;
}
.date-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  color: var(--muted);
}
.source-strip {
  background: var(--accent-soft);
  border: 1px solid color-mix(in srgb, var(--accent) 12%, transparent);
  border-radius: 5px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  color: var(--accent);
  font-size: 13.5px;
  margin-bottom: 23px;
}
.source-strip strong {
  font-size: 13.5px;
}
.source-strip > span:not(.source-dot) {
  opacity: 0.8;
}
.source-dot {
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  flex-shrink: 0;
}
.source-strip button {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 12.5px;
  font-weight: 600;
}
.app-footer {
  font-size: 12px;
  color: var(--muted);
  border-top: 1px solid var(--line);
  margin-top: 35px;
  padding: 18px 0;
  display: flex;
  justify-content: space-between;
  gap: 15px;
}
.mobile-menu {
  display: none;
}

/* Data overview */
.metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 29px;
}
.metric {
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 3px solid #9ec7b7;
  border-radius: 6px;
  padding: 17px 18px 15px;
  min-height: 137px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.metric:disabled {
  opacity: 1;
}
.metric.blue {
  border-top-color: #a9bfe1;
}
.metric.peach {
  border-top-color: #e4b99c;
}
.metric.violet {
  border-top-color: #c4b5d7;
}
.metric-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 550;
  color: var(--muted);
}
.metric-top svg {
  color: var(--accent);
  flex-shrink: 0;
}
.metric.blue svg {
  color: var(--blue-text);
}
.metric.peach svg {
  color: var(--peach-text);
}
.metric.violet svg {
  color: var(--violet-text);
}
.metric > strong {
  font-family: "Manrope", sans-serif;
  font-size: 30px;
  line-height: 1.3;
  font-weight: 750;
  margin: 13px 0 10px;
  overflow-wrap: anywhere;
}
.metric-foot {
  display: flex;
  gap: 8px;
  justify-content: space-between;
  color: var(--muted);
  font-size: 12px;
  align-items: center;
}
.metric-foot svg {
  flex-shrink: 0;
}
.dashboard-charts {
  display: grid;
  grid-template-columns: 1.65fr 1fr;
  background: var(--surface);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  margin-bottom: 30px;
}
.chart-section {
  padding: 21px 24px 15px;
  min-width: 0;
}
.chart-section + .chart-section {
  border-left: 1px solid var(--line);
}
.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
}
.section-heading p {
  font-size: 12.5px;
  color: var(--muted);
  margin-top: 5px;
}
.chart-area {
  height: 205px;
  min-width: 0;
}
.distribution {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
}
.donut {
  width: 155px;
  height: 155px;
  position: relative;
}
.donut-center {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  pointer-events: none;
}
.donut-center strong {
  font-size: 27px;
  font-family: "Manrope", sans-serif;
  font-weight: 750;
}
.donut-center span {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}
.legend {
  width: 100%;
  max-width: 290px;
}
.legend > div {
  display: flex;
  gap: 9px;
  align-items: center;
  font-size: 12.5px;
  margin: 9px 0;
}
.legend i {
  width: 7px;
  height: 7px;
  border-radius: 2px;
}
.legend span {
  flex: 1;
}
.legend strong {
  font-weight: 600;
  min-width: 20px;
  text-align: right;
}
.legend small {
  font-size: 12px;
  min-width: 30px;
  text-align: right;
}
.dashboard-bottom {
  display: grid;
  grid-template-columns: minmax(0, 2.4fr) minmax(220px, 1fr);
  gap: 30px;
}
.dashboard-bottom > section {
  min-width: 0;
}
.dashboard-bottom .section-heading h2 {
  font-size: 17px;
}
.dashboard-bottom .table-wrap {
  border-top: 1px solid var(--line);
}
.attention {
  padding-left: 23px;
  border-left: 1px solid var(--line);
}
.attention > button {
  display: flex;
  text-align: left;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}
.attention > button > span:nth-child(2) {
  flex: 1;
}
.attention > button strong {
  display: block;
  font-size: 13.5px;
}
.attention > button small {
  display: block;
  font-size: 12px;
  line-height: 1.5;
  margin-top: 5px;
}
.attention > button > svg {
  color: var(--muted);
  flex-shrink: 0;
}
.attention-count {
  display: grid;
  place-items: center;
  min-width: 33px;
  height: 35px;
  border-radius: 5px;
  font-size: 14.5px;
  font-weight: 600;
}
.peach {
  background: var(--peach);
  color: var(--peach-text);
}
.blue {
  background: var(--blue);
  color: var(--blue-text);
}
.violet {
  background: var(--violet);
  color: var(--violet-text);
}
.green {
  background: var(--accent-soft);
  color: var(--accent);
}
.metric {
  background: var(--surface);
  color: var(--text);
}
.attention-note {
  padding: 21px 0 0;
}
.attention-note h3 {
  font-size: 21px;
  font-weight: 650;
  margin-bottom: 14px;
}
.attention-note .button {
  font-size: 12.5px;
}
.quality-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  margin-top: 25px;
}
.quality-grid > div {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  font-size: 14.5px;
}
.quality-grid progress {
  grid-column: 1/-1;
  width: 100%;
  height: 6px;
  accent-color: var(--accent);
}

/* Lists, forms and operational surfaces */
.table-wrap {
  overflow-x: auto;
  width: 100%;
  background: var(--surface);
}
table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 13.5px;
}
th {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  padding: 13px 12px;
  background: var(--bg);
  white-space: nowrap;
}
td {
  padding: 13px 12px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
  line-height: 1.5;
}
tbody tr:last-child td {
  border-bottom: 0;
}
tbody tr:hover {
  background: var(--hover);
}
td small {
  display: block;
  font-size: 12px;
  margin-top: 3px;
  max-width: 240px;
  overflow-wrap: anywhere;
}
.record-link {
  padding: 0;
  font-size: 14.5px;
  font-weight: 650;
  color: var(--accent);
  white-space: nowrap;
}
.record-link:hover {
  text-decoration: underline;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 7px;
  font-size: 12px;
  font-weight: 550;
  border-radius: 4px;
  white-space: nowrap;
}
.badge i {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
}
.badge.info {
  background: var(--blue);
  color: var(--blue-text);
}
.badge.success {
  background: var(--accent-soft);
  color: var(--accent);
}
.badge.warning {
  background: var(--peach);
  color: var(--peach-text);
}
.badge.neutral {
  background: var(--hover);
  color: var(--muted);
}
.list-toolbar {
  display: flex;
  gap: 12px;
  align-items: center;
  margin: 15px 0;
}
.search-input {
  display: flex;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 5px;
  gap: 8px;
  padding-left: 12px;
  flex: 1;
  color: var(--muted);
  min-width: 150px;
}
.search-input input {
  border: 0;
  background: none;
  font-size: 14.5px;
  padding-left: 0;
}
.list-toolbar > select {
  width: 180px;
  font-size: 14.5px;
}
.list-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 12.5px;
  color: var(--muted);
  padding: 12px 0;
}
.main-table {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.main-table th {
  padding-top: 15px;
  padding-bottom: 15px;
}
.main-table td {
  height: 64px;
}
.doc-chip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 12.5px;
  border-radius: 4px;
  min-width: 36px;
  min-height: 27px;
}
.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13.5px;
  color: var(--muted);
  padding: 17px 0;
}
.pagination > div {
  display: flex;
  align-items: center;
  gap: 15px;
}
.filter-bar {
  display: flex;
  align-items: flex-end;
  gap: 16px;
  background: var(--surface);
  padding: 17px 18px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  margin: 18px 0;
  flex-wrap: wrap;
}
.filter-bar label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 12.5px;
  color: var(--muted);
}
.filter-bar input,
.filter-bar select {
  font-size: 14.5px;
  min-width: 145px;
}
.filter-bar > .muted {
  margin-left: auto;
  font-size: 13.5px;
  align-self: center;
}
.filter-bar .text-link {
  min-height: 40px;
}
.finance-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 24px 0;
  margin: 15px 0 28px;
}
.finance-summary > div + div {
  border-left: 1px solid var(--line);
  padding-left: 25px;
}
.finance-summary span {
  display: block;
  font-size: 13.5px;
  color: var(--muted);
  margin-bottom: 10px;
}
.finance-summary strong {
  font-size: 26px;
  font-family: "Manrope", sans-serif;
}
.data-section {
  padding: 25px 0;
  border-top: 1px solid var(--line);
  margin-top: 28px;
}
.data-section .table-wrap {
  margin-top: 15px;
}
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 17px;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 14.5px;
  min-width: 0;
}
.field > span {
  font-size: 13.5px;
  font-weight: 550;
  color: var(--muted);
}
.field input,
.field select,
.field textarea {
  font-size: 14.5px;
}
.span-2 {
  grid-column: 1/-1;
}
.form-section-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14.5px;
  font-weight: 650;
  margin: 26px 0 18px;
}
.form-section-label:first-child {
  margin-top: 0;
}
.form-section-label > span {
  display: grid;
  place-items: center;
  width: 23px;
  height: 23px;
  background: var(--accent-soft);
  color: var(--accent);
  border-radius: 4px;
  font-size: 12.5px;
}
.form-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 24px;
}
.error-message {
  background: #fff0ed;
  color: #9b3c30;
  padding: 12px 16px;
  font-size: 14.5px;
  border: 1px solid #efc8c0;
  border-radius: 5px;
  margin: 14px 0;
  line-height: 1.5;
}
.success-message {
  padding: 15px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 14.5px;
}
.toast {
  position: fixed;
  bottom: 25px;
  left: calc(50% + 90px);
  transform: translateX(-50%);
  z-index: 100;
  background: var(--text);
  color: var(--surface);
  padding: 10px 13px 10px 18px;
  border-radius: 6px;
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14.5px;
  max-width: 90vw;
}
.toast .icon-button {
  color: inherit;
}
.toast > svg {
  flex-shrink: 0;
}
:root[data-density="compact"] .main-table td {
  height: 45px;
  padding-top: 7px;
  padding-bottom: 7px;
}

/* Accessible dialogs and detail panel */
.overlay {
  position: fixed;
  inset: 0;
  background: #102b2475;
  backdrop-filter: blur(3px);
  z-index: 50;
  animation: fade-in 0.18s ease;
}
.modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(460px, calc(100% - 32px));
  max-height: 90dvh;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  z-index: 51;
  overflow: auto;
  animation: fade-in 0.18s ease;
}
.modal.wide {
  width: min(900px, calc(100% - 32px));
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  padding: 22px 26px;
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  background: var(--surface);
  z-index: 2;
}
.modal-header h2 {
  font-size: 20px;
  overflow-wrap: anywhere;
}
.modal-header p {
  font-size: 13.5px;
  color: var(--muted);
  margin-top: 5px;
}
.modal-body {
  padding: 25px 27px;
}
.modal-footer {
  display: flex;
  gap: 9px;
  justify-content: flex-end;
  position: sticky;
  bottom: 0;
  background: var(--surface);
  border-top: 1px solid var(--line);
  padding: 16px 26px;
}
.modal.drawer {
  inset: 0 0 0 auto;
  transform: none;
  width: min(665px, 100%);
  height: 100dvh;
  max-height: 100dvh;
  border-radius: 0;
  animation: slide-in 0.2s ease;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.drawer .modal-header {
  position: static;
  flex-shrink: 0;
}
.drawer > .error-message {
  margin: 10px 20px;
}
.detail-summary {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 16px 26px;
  font-size: 13.5px;
  color: var(--muted);
  flex-wrap: wrap;
}
.tabs {
  display: flex;
  border-bottom: 1px solid var(--line);
  padding: 0 22px;
  gap: 18px;
  overflow-x: auto;
  flex-shrink: 0;
}
.tabs button {
  padding: 13px 0;
  font-size: 13.5px;
  color: var(--muted);
  border-bottom: 2px solid transparent;
  white-space: nowrap;
}
.tabs button.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
  font-weight: 650;
}
.detail-body {
  padding: 25px 27px;
  overflow: auto;
  flex: 1;
}
.detail-title h3 {
  font-size: 23px;
  margin-bottom: 22px;
}
.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px 25px;
  margin: 0;
}
.detail-grid dt {
  font-size: 12.5px;
  color: var(--muted);
  margin-bottom: 6px;
}
.detail-grid dd {
  font-size: 15px;
  font-weight: 550;
  margin: 0;
  overflow-wrap: anywhere;
}
.detail-note {
  border-top: 1px solid var(--line);
  padding-top: 18px;
  margin-top: 25px;
}
.detail-note p {
  font-size: 14.5px;
  white-space: pre-wrap;
  margin-top: 10px;
  overflow-wrap: anywhere;
}
.provenance {
  border-top: 1px solid var(--line);
  padding-top: 20px;
  margin-top: 30px;
}
.provenance h4 {
  font-size: 14.5px;
}
.provenance p {
  font-size: 13.5px;
  color: var(--muted);
  margin: 8px 0 12px;
}
.document-row {
  display: flex;
  width: 100%;
  gap: 13px;
  align-items: center;
  text-align: left;
  padding: 17px 0;
  border-bottom: 1px solid var(--line);
}
.document-row > span:nth-child(2) {
  flex: 1;
  min-width: 0;
}
.document-row strong {
  display: block;
  font-size: 14.5px;
  overflow-wrap: anywhere;
}
.document-row small {
  display: block;
  font-size: 12.5px;
  margin-top: 5px;
}
.pdf-icon {
  width: 42px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 5px;
  background: var(--peach);
  color: var(--peach-text);
  flex-shrink: 0;
}
.document-row > svg {
  color: var(--muted);
  flex-shrink: 0;
}
.pdf-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 81px;
  z-index: 2;
  font-size: 14.5px;
}
.pdf-canvas {
  height: 65vh;
  overflow: auto;
  background: #e6ebe8;
  padding: 16px;
  text-align: center;
}
.pdf-canvas canvas {
  display: block;
  margin: auto;
  box-shadow: 0 4px 15px #0002;
  max-width: none;
}
.cost-highlight {
  padding: 10px 0 25px;
  margin-bottom: 25px;
  border-bottom: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.cost-highlight > span {
  font-size: 13.5px;
  color: var(--muted);
}
.cost-highlight strong {
  font-size: 30px;
  font-family: "Manrope", sans-serif;
}
.cost-highlight small {
  font-size: 14.5px;
}
.detail-body form > .field {
  margin-top: 18px;
}
.timeline {
  padding-left: 12px;
}
.timeline > div {
  position: relative;
  border-left: 1px solid var(--line);
  padding: 0 0 26px 23px;
}
.timeline i {
  position: absolute;
  left: -4px;
  top: 4px;
  width: 7px;
  height: 7px;
  background: var(--accent);
  border-radius: 50%;
}
.timeline strong {
  display: block;
  font-size: 14.5px;
}
.timeline small {
  display: block;
  font-size: 12.5px;
  margin-top: 7px;
}
.timeline p {
  font-size: 13.5px;
  margin-top: 8px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  color: var(--muted);
}
@keyframes fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
@keyframes slide-in {
  from {
    transform: translateX(25px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

/* Settings and integrations */
.integration-list {
  border-top: 1px solid var(--line);
}
.integration-row {
  display: flex;
  align-items: center;
  gap: 20px;
  border-bottom: 1px solid var(--line);
  padding: 27px 0;
}
.integration-icon {
  display: inline-grid;
  place-items: center;
  width: 48px;
  height: 50px;
  border-radius: 6px;
  flex-shrink: 0;
}
.integration-row > div {
  flex: 1;
}
.integration-row h2 {
  font-size: 17px;
  margin-bottom: 7px;
}
.integration-row p {
  font-size: 14.5px;
  color: var(--muted);
  max-width: 550px;
}
.integration-row .small-tag {
  margin-top: 12px;
}
.connection-state {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--accent);
  font-size: 12.5px;
  margin-top: 13px;
  flex-wrap: wrap;
}
.connection-state i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
}
.connection-state span {
  color: var(--muted);
}
.endpoint-list > div {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 17px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13.5px;
  color: var(--muted);
}
.endpoint-list > div > span:first-of-type {
  overflow-wrap: anywhere;
  flex: 1;
}
.endpoint-list svg {
  flex-shrink: 0;
}
.settings-section {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 40px;
  padding: 30px 0;
  border-top: 1px solid var(--line);
}
.settings-section > div:first-child > svg {
  color: var(--accent);
  margin-bottom: 10px;
}
.settings-section h2 {
  margin-bottom: 7px;
}
.settings-section p {
  color: var(--muted);
  font-size: 14.5px;
}
.settings-controls {
  max-width: 420px;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 24px;
}
.settings-controls .field {
  width: 100%;
}
.segmented {
  display: flex;
  background: var(--bg);
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 5px;
  width: fit-content;
}
.segmented button {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14.5px;
  padding: 9px 17px;
  border-radius: 3px;
}
.segmented button.active {
  background: var(--surface);
  box-shadow: 0 1px 4px #0001;
  color: var(--accent);
}
.swatches {
  display: flex;
  gap: 13px;
}
.swatches button {
  border-radius: 50%;
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  color: white;
  border: 3px solid var(--surface);
  outline: 1px solid var(--line);
}
.swatches button[aria-pressed="true"] {
  outline: 2px solid var(--accent);
}
.user-list > div {
  display: flex;
  gap: 12px;
  align-items: center;
  border-bottom: 1px solid var(--line);
  padding: 15px 0;
  max-width: 420px;
}
.user-list strong {
  display: block;
  font-size: 15px;
}
.user-list small {
  display: block;
  margin-top: 5px;
}
.user-list .small-tag {
  margin-left: auto;
}
.activity-list > div {
  display: flex;
  gap: 16px;
  border-top: 1px solid var(--line);
  padding: 18px 0;
}
.activity-icon {
  display: grid;
  place-items: center;
  width: 35px;
  height: 35px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  flex-shrink: 0;
}
.activity-list > div > div {
  flex: 1;
  min-width: 0;
}
.activity-list strong {
  font-size: 14.5px;
}
.activity-list p {
  color: var(--muted);
  font-size: 13.5px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  margin: 6px 0;
}
.activity-list small {
  font-size: 12.5px;
}
.notice-list > button {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 18px;
  text-align: left;
  padding: 25px 0;
  border-top: 1px solid var(--line);
}
.notice-list > button > span:nth-child(2) {
  flex: 1;
}
.notice-list strong {
  display: block;
  font-size: 16px;
}
.notice-list small {
  display: block;
  font-size: 14.5px;
  margin-top: 8px;
}

/* Public entry */
.landing {
  background: #fff;
  color: #203b32;
}
.landing-hero {
  position: relative;
  min-height: 680px;
  height: calc(100svh - 110px);
  max-height: 1100px;
  background: #233c35 url("/registry.jpg") center 52% / cover no-repeat;
  color: #fff;
  isolation: isolate;
  display: flex;
  flex-direction: column;
}
.landing-hero:before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    #0e302bec 0%,
    #12312dcc 40%,
    #112c2550 100%
  );
  z-index: -1;
}
.landing-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 32px 6%;
  gap: 20px;
  border-bottom: 1px solid #ffffff24;
}
.landing .brand {
  font-size: 23px;
}
.landing .brand-icon {
  background: #ffffff20;
}
.landing .brand small {
  color: #cedcd5;
  font-size: 12px;
}
.glass {
  background: #ffffff0d;
  border-color: #ffffff55;
  color: #fff;
  padding: 11px 17px;
}
.hero-copy {
  margin: auto 6%;
  padding: 55px 0;
  max-width: 690px;
}
.hero-copy .eyebrow {
  color: #c0d6ca;
  font-size: 13.5px;
  margin-bottom: 19px;
}
.hero-copy h1 {
  font-size: 68px;
  font-weight: 750;
  color: white;
  line-height: 1.1;
  margin-bottom: 20px;
}
.hero-copy > p {
  font-family: "Manrope", sans-serif;
  font-size: 34px;
  line-height: 1.45;
  font-weight: 400;
  color: #dbe8df;
}
.hero-description {
  font-size: 16px;
  color: #bed1c5;
  max-width: 340px;
  line-height: 1.8;
  margin: 23px 0 30px;
}
.hero-button {
  background: #f4f7f1;
  color: #184e3b;
  font-size: 15px;
  padding: 15px 20px;
}
.hero-foot {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 24px 6%;
  font-size: 13.5px;
  color: #c7d9ce;
  border-top: 1px solid #ffffff26;
}
.landing-bottom {
  padding: 30px 6%;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.landing-bottom > div {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  font-size: 14.5px;
  color: #597266;
  min-height: 45px;
}
.landing-bottom > div + div {
  border-left: 1px solid #dce6df;
}
.landing-bottom svg {
  color: #45806a;
  width: 21px;
}
.landing-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 20px 6%;
  border-top: 1px solid #e5ebe7;
  font-size: 12.5px;
  color: #829289;
}
.login-form {
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.password-field {
  display: flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--surface);
  padding-right: 5px;
}
.password-field input {
  border: 0;
  background: none;
  min-width: 0;
}
.login-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-size: 12.5px;
}
.login-form .error-message {
  margin: 0;
}

@media (min-width: 1550px) {
  .sidebar {
    width: 250px;
  }
  .workspace {
    margin-left: 250px;
  }
  .workspace main {
    padding: 40px 48px 0;
  }
  .topbar {
    padding: 0 48px;
  }
  .dashboard-charts {
    grid-template-columns: 1.8fr 1fr;
  }
  .chart-area {
    height: 240px;
  }
  .distribution {
    flex-direction: row;
    height: 240px;
    gap: 30px;
    justify-content: center;
  }
  .donut {
    width: 175px;
    height: 175px;
    flex-shrink: 0;
  }
  .legend {
    max-width: 190px;
  }
}
@media (max-width: 1150px) {
  .sidebar {
    width: 210px;
    padding-left: 12px;
    padding-right: 12px;
  }
  .workspace {
    margin-left: 210px;
  }
  .topbar {
    padding: 0 22px;
  }
  .workspace main {
    padding: 25px 23px 0;
  }
  .global-search {
    display: none;
  }
  .metric {
    padding: 14px 12px;
  }
  .metric-top {
    font-size: 12.5px;
  }
  .metric > strong {
    font-size: 26px;
  }
  .metric-foot {
    font-size: 12px;
  }
  .metrics {
    gap: 10px;
  }
  .dashboard-bottom {
    grid-template-columns: minmax(0, 1fr);
  }
  .attention {
    padding-left: 0;
    border-left: 0;
    border-top: 1px solid var(--line);
    padding-top: 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 25px;
  }
  .attention .section-heading {
    grid-column: 1/-1;
  }
  .attention-note {
    display: none;
  }
  .breadcrumb > span {
    display: none;
  }
  .chart-section {
    padding: 18px;
  }
  .integration-row {
    gap: 13px;
  }
  .integration-row .button {
    min-width: 130px;
  }
  .sidebar .brand {
    font-size: 18px;
  }
}
@media (max-width: 820px) {
  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.2s;
    width: 232px;
  }
  .sidebar.open {
    transform: translateX(0);
  }
  .workspace {
    margin-left: 0;
  }
  .mobile-menu {
    display: inline-flex;
  }
  .mobile-backdrop {
    position: fixed;
    inset: 0;
    background: #142c2580;
    z-index: 29;
    cursor: default;
  }
  .topbar {
    height: 64px;
    padding: 0 18px;
  }
  .topbar-actions {
    gap: 5px;
  }
  .topbar-divider {
    display: none;
  }
  .topbar .button {
    min-height: 35px;
    font-size: 13.5px;
    padding: 8px 11px;
  }
  .workspace main {
    padding: 26px 20px 0;
  }
  .metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }
  .metric {
    min-height: 135px;
    padding: 16px;
  }
  .metric-top {
    font-size: 13.5px;
  }
  .metric > strong {
    font-size: 29px;
  }
  .chart-area {
    height: 200px;
  }
  .dashboard-charts {
    grid-template-columns: 1.4fr 1fr;
  }
  .page-heading h1 {
    font-size: 27px;
  }
  .page-heading {
    align-items: flex-start;
  }
  .page-heading .date-label {
    display: none;
  }
  .list-toolbar {
    flex-wrap: wrap;
  }
  .search-input {
    flex-basis: 100%;
  }
  .list-toolbar > select {
    flex: 1;
  }
  .integration-row {
    flex-wrap: wrap;
  }
  .integration-row > div {
    flex-basis: calc(100% - 70px);
  }
  .integration-row > .button,
  .integration-row > .text-link {
    margin-left: 61px;
  }
  .toast {
    left: 50%;
  }
  .settings-section {
    grid-template-columns: 1fr 1.5fr;
    gap: 20px;
  }
  .landing-hero {
    min-height: 600px;
  }
  .hero-copy h1 {
    font-size: 55px;
  }
  .hero-copy > p {
    font-size: 29px;
  }
}
@media (max-width: 540px) {
  .workspace main {
    padding: 22px 16px 0;
  }
  .topbar {
    padding: 0 10px;
  }
  .breadcrumb {
    gap: 6px;
    font-size: 12.5px;
  }
  .topbar-actions > .icon-button {
    display: none;
  }
  .page-heading {
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 20px;
  }
  .page-heading h1 {
    font-size: 25px;
  }
  .page-heading p {
    font-size: 13.5px;
  }
  .metrics {
    gap: 9px;
  }
  .metric {
    padding: 13px 12px;
    min-height: 128px;
  }
  .metric-top {
    font-size: 12.5px;
    gap: 4px;
  }
  .metric-top svg {
    width: 15px;
  }
  .metric > strong {
    font-size: 25px;
  }
  .metric-foot {
    font-size: 11px;
    line-height: 1.5;
  }
  .metric-foot > svg {
    display: none;
  }
  .source-strip {
    font-size: 12.5px;
    gap: 8px;
    flex-wrap: wrap;
  }
  .source-strip > span:not(.source-dot) {
    font-size: 12px;
  }
  .source-strip button {
    font-size: 12px;
  }
  .dashboard-charts {
    grid-template-columns: 1fr;
  }
  .chart-section + .chart-section {
    border-left: 0;
    border-top: 1px solid var(--line);
  }
  .chart-section {
    padding: 20px 15px;
  }
  .distribution {
    flex-direction: row;
    justify-content: center;
    gap: 22px;
  }
  .donut {
    width: 135px;
    height: 135px;
    flex-shrink: 0;
  }
  .legend {
    max-width: 180px;
  }
  .dashboard-bottom {
    gap: 22px;
  }
  .attention {
    grid-template-columns: 1fr;
  }
  .attention .section-heading {
    grid-column: auto;
  }
  .table-wrap table {
    min-width: 570px;
  }
  .dashboard-bottom table {
    min-width: 510px;
  }
  .main-table table {
    min-width: 720px;
  }
  .pagination {
    font-size: 12.5px;
    gap: 10px;
  }
  .pagination > div {
    gap: 4px;
  }
  .pagination .icon-button {
    width: 30px;
    flex-basis: 30px;
  }
  .app-footer {
    font-size: 11px;
  }
  .app-footer span:last-child {
    display: none;
  }
  .list-meta {
    font-size: 12px;
  }
  .finance-summary {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 20px 0;
  }
  .finance-summary > div + div {
    padding: 14px 0 0;
    border-left: 0;
    border-top: 1px solid var(--line);
  }
  .finance-summary > div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
  }
  .finance-summary span {
    margin: 0;
  }
  .finance-summary strong {
    font-size: 22px;
  }
  .filter-bar {
    padding: 15px 10px;
    gap: 12px;
  }
  .filter-bar label {
    flex: 1;
    min-width: 125px;
  }
  .filter-bar input {
    min-width: 0;
  }
  .quality-grid {
    grid-template-columns: 1fr;
    gap: 22px;
  }
  .settings-section {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .integration-row {
    padding: 22px 0;
  }
  .integration-row p {
    font-size: 13.5px;
  }
  .integration-row h2 {
    font-size: 16px;
  }
  .endpoint-list > div {
    flex-wrap: wrap;
    gap: 7px;
  }
  .endpoint-list .small-tag {
    margin-left: 24px;
  }
  .modal {
    width: calc(100% - 20px);
    max-height: 94dvh;
  }
  .modal.wide {
    width: calc(100% - 20px);
  }
  .modal-header {
    padding: 18px;
  }
  .modal-header h2 {
    font-size: 18px;
  }
  .modal-body,
  .detail-body {
    padding: 20px 18px;
  }
  .modal-footer {
    padding: 14px 18px;
  }
  .detail-summary {
    padding: 15px 18px;
    font-size: 12.5px;
  }
  .tabs {
    gap: 18px;
    padding: 0 18px;
  }
  .tabs button {
    font-size: 12.5px;
  }
  .form-grid {
    gap: 16px;
    grid-template-columns: 1fr;
  }
  .span-2 {
    grid-column: auto;
  }
  .detail-grid {
    gap: 22px 18px;
  }
  .detail-grid dd {
    font-size: 14.5px;
  }
  .pdf-toolbar {
    gap: 3px;
    padding: 8px;
    top: 74px;
    font-size: 12.5px;
  }
  .pdf-toolbar .icon-button {
    width: 30px;
    flex-basis: 30px;
  }
  .pdf-canvas {
    padding: 10px;
  }
  .toast {
    bottom: 15px;
    font-size: 13.5px;
    width: max-content;
    max-width: calc(100% - 25px);
  }
  .landing-nav {
    padding: 24px 6%;
  }
  .landing .brand {
    font-size: 18.5px;
    gap: 8px;
  }
  .landing .brand-icon {
    width: 32px;
    height: 36px;
  }
  .landing .brand small {
    font-size: 11px;
  }
  .landing-nav .button {
    font-size: 12.5px;
    padding: 8px 10px;
    max-width: 110px;
    gap: 5px;
  }
  .hero-copy h1 {
    font-size: 43px;
  }
  .hero-copy > p {
    font-size: 27px;
  }
  .hero-copy .eyebrow {
    font-size: 12px;
  }
  .hero-copy {
    padding: 35px 0;
  }
  .hero-description {
    font-size: 14.5px;
    max-width: 260px;
  }
  .hero-button {
    font-size: 13.5px;
    padding: 13px 15px;
  }
  .landing-hero {
    height: calc(100svh - 85px);
    min-height: 530px;
  }
  .hero-foot {
    font-size: 11px;
    padding: 20px 6%;
    gap: 12px;
  }
  .landing-bottom {
    padding: 20px 6%;
    gap: 15px;
    grid-template-columns: 1fr;
  }
  .landing-bottom > div {
    justify-content: flex-start;
    font-size: 13.5px;
    min-height: 25px;
  }
  .landing-bottom > div + div {
    border: 0;
  }
  .landing-footer {
    font-size: 12px;
  }
  .notice-list strong {
    font-size: 14.5px;
  }
  .notice-list small {
    font-size: 12.5px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
