:root {
  --bg: #f4f1ea;
  --bg-soft: #ebe5d8;
  --panel: #fffdf8;
  --panel-strong: #ffffff;
  --text: #172127;
  --muted: #65717a;
  --line: #d9d1c3;
  --line-soft: rgba(23, 33, 39, 0.08);
  --primary: #247a55;
  --primary-dark: #19583d;
  --primary-soft: #e7f3ec;
  --ghost: #eee7da;
  --warning: #fff1d6;
  --alert: #fbe0d9;
  --info: #e5eef7;
  --shadow: 0 18px 46px rgba(69, 56, 34, 0.10);
  --shadow-soft: 0 10px 28px rgba(69, 56, 34, 0.07);
  --radius-lg: 20px;
  --radius-md: 14px;
  --ease: 180ms ease;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  min-height: 100%;
  background: #f3f0e8;
}

body {
  margin: 0;
  min-height: 100dvh;
  font-family: "Aptos", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 12% 0%, rgba(255, 255, 255, 0.9) 0, rgba(255, 255, 255, 0) 34rem),
    linear-gradient(135deg, #f8f5ed 0%, var(--bg) 42%, var(--bg-soft) 100%);
  font-size: 16px;
  line-height: 1.5;
  font-variant-numeric: tabular-nums;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.36;
  background-image:
    linear-gradient(rgba(23, 33, 39, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23, 33, 39, 0.022) 1px, transparent 1px);
  background-size: 28px 28px;
}

a {
  color: var(--primary-dark);
  text-underline-offset: 3px;
  overflow-wrap: anywhere;
}

.skip-link {
  position: fixed;
  left: 16px;
  top: 12px;
  z-index: 4;
  transform: translateY(-140%);
  border-radius: 10px;
  padding: 10px 12px;
  background: var(--text);
  color: white;
  text-decoration: none;
  transition: transform var(--ease);
}

.skip-link:focus {
  transform: translateY(0);
}

.shell-inner {
  width: calc(100% - 32px);
  max-width: 1440px;
  margin: 0 auto;
}

.shell-header {
  border-bottom: 1px solid rgba(0,0,0,0.06);
  backdrop-filter: blur(14px);
  background: rgba(255,253,248,0.86);
  position: sticky;
  top: 0;
  z-index: 3;
}

.shell-header .shell-inner {
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 16px 0;
  justify-content: space-between;
}

.brand {
  font-weight: 700;
  font-size: 20px;
  color: var(--text);
  text-decoration: none;
  letter-spacing: 0;
  white-space: nowrap;
}

.brand-wrap {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  white-space: nowrap;
}

.app-version {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}

.brand-note, .muted { color: var(--muted); }

.top-nav {
  margin-left: auto;
  display: flex;
  gap: 6px;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.top-nav::-webkit-scrollbar { display: none; }

.top-nav a {
  color: var(--text);
  text-decoration: none;
  font-weight: 650;
  font-size: 14px;
  white-space: nowrap;
  border-radius: 999px;
  padding: 8px 11px;
  transition: background var(--ease), color var(--ease), transform var(--ease);
}

.top-nav a:hover,
.top-nav a.active {
  background: var(--ghost);
  color: var(--primary-dark);
}

.top-nav a:active {
  transform: translateY(1px);
}

.auth-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: max-content;
  padding: 5px 6px 5px 10px;
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  background: rgba(255,255,255,0.62);
}

.auth-chip span,
.auth-profile-link {
  font-weight: 750;
  font-size: 13px;
}

.auth-profile-link {
  color: var(--text);
  text-decoration: none;
}

.auth-profile-link:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}

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

.auth-chip form { margin: 0; }

.auth-chip button {
  border: 0;
  border-radius: 999px;
  padding: 6px 9px;
  background: var(--ghost);
  color: var(--text);
  font: inherit;
  font-size: 12px;
  font-weight: 750;
  cursor: pointer;
}

.shell-main { padding: 28px 0 48px; }

.dashboard-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: end;
  margin-bottom: 18px;
}

.dashboard-head h1 {
  margin: 0;
  font-size: 34px;
  line-height: 1.05;
}

.dashboard-refresh {
  display: flex;
  gap: 10px;
  align-items: center;
  color: var(--muted);
  font-size: 13px;
}

.dashboard-metrics {
  display: grid;
  grid-template-columns: repeat(8, minmax(110px, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.metric-card {
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  background: rgba(255,253,248,0.84);
  padding: 14px;
}

.metric-card span,
.dashboard-timer span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.metric-card strong {
  display: block;
  margin-top: 4px;
  font-size: 24px;
}

.dashboard-list {
  display: grid;
  gap: 14px;
}

.dashboard-tender {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255,253,248,0.92);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.dashboard-tender > header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line-soft);
}

.dashboard-tender h2 {
  margin: 0 0 4px;
  font-size: 21px;
}

.dashboard-timer {
  min-width: 110px;
  text-align: right;
}

.dashboard-tender-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: flex-end;
}

.dashboard-timer strong {
  font-size: 22px;
}

.dashboard-tender-stats {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px 20px;
  border-bottom: 1px solid var(--line-soft);
}

.dashboard-tender-stats span {
  border-radius: 999px;
  background: var(--ghost);
  padding: 6px 10px;
}

.dashboard-tender details {
  padding: 12px 20px;
}

.dashboard-table-wrap {
  overflow-x: auto;
  margin-top: 10px;
}

.dashboard-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1100px;
  font-size: 13px;
}

.dashboard-table th,
.dashboard-table td {
  border: 1px solid var(--line-soft);
  padding: 8px;
  vertical-align: top;
}

.dashboard-table th {
  background: #f0eadf;
  color: var(--muted);
  text-align: left;
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: .05em;
}

.processing-cost-lines {
  display: grid;
  gap: 4px;
  min-width: 150px;
}

.processing-cost-lines span {
  display: grid;
  grid-template-columns: max-content max-content 1fr;
  align-items: baseline;
  gap: 4px;
  white-space: nowrap;
}

.processing-cost-lines em {
  font-style: normal;
  font-size: 12px;
  color: var(--text);
}

.processing-cost-lines b {
  color: var(--muted);
  font-weight: 400;
}

.processing-cost-lines strong {
  justify-self: start;
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
}

.processing-cost-lines .total {
  margin-top: 2px;
  padding-top: 4px;
  border-top: 1px solid var(--line-soft);
}

.processing-cost-lines .total strong {
  color: var(--primary-dark);
}

.dashboard-time-lines {
  display: grid;
  gap: 2px;
}

.dashboard-time-lines strong {
  font-size: 12px;
  font-weight: 600;
}

.dashboard-time-lines small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.2;
}

.status-pill {
  display: inline-flex;
  border-radius: 999px;
  padding: 4px 8px;
  background: var(--ghost);
  font-size: 12px;
  font-weight: 700;
}

.status-done { background: var(--primary-soft); }
.status-failed { background: var(--alert); }
.status-stopped { background: #f7ddd6; color: #7d2b1f; }
.status-processing,
.status-searching_web,
.status-matching { background: var(--warning); }

.dashboard-subgrid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid var(--line-soft);
}

.dashboard-table.compact {
  min-width: 760px;
}

.dashboard-table.compact th,
.dashboard-table.compact td {
  padding: 6px 8px;
}

.dashboard-table.candidate-rejections {
  min-width: 1800px;
}

.dashboard-table.candidate-rejections td {
  max-width: 320px;
  overflow-wrap: anywhere;
}

.event-list {
  display: grid;
  gap: 8px;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
  font-size: 13px;
}

.event-list li {
  display: grid;
  gap: 4px;
  border: 1px solid var(--line-soft);
  border-radius: 10px;
  padding: 8px;
  background: rgba(255,255,255,.45);
}

.event-list span {
  color: var(--muted);
}

.event-list small {
  display: block;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.event-list pre {
  max-height: 220px;
  overflow: auto;
  margin: 2px 0 0;
  padding: 8px;
  border-radius: 8px;
  background: rgba(255,255,255,.64);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 12px;
  line-height: 1.45;
}

.error-list li {
  border-color: rgba(168, 69, 50, .28);
  background: rgba(251, 224, 217, .46);
}

.detail-hero-grid,
.detail-risk-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
  margin-bottom: 24px;
}

.detail-side-stack,
.risk-stack {
  display: grid;
  gap: 18px;
  align-content: start;
}

.hero {
  padding: 30px;
  border: 1px solid rgba(23, 33, 39, 0.07);
  border-radius: 24px;
  background:
    radial-gradient(circle at 86% 16%, rgba(36, 122, 85, 0.13), transparent 19rem),
    linear-gradient(135deg, #fffdf8, #f6f0e4);
  box-shadow: var(--shadow-soft);
  margin-bottom: 24px;
}

.detail-hero-grid .hero,
.detail-risk-grid .alert-panel,
.detail-dashboard {
  margin-bottom: 0;
}

.tender-brief {
  min-height: 100%;
}

.operator-card .actions {
  gap: 10px;
}

.files-card .files li {
  padding-top: 8px;
  padding-bottom: 8px;
}

.hero.compact { padding: 22px 28px; }

.tender-overview {
  margin-bottom: 16px;
}

.tender-overview-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(270px, 340px) minmax(360px, 0.52fr);
  gap: 24px;
  align-items: start;
}

.tender-overview-main h1 {
  max-width: 980px;
  margin-bottom: 12px;
  font-size: clamp(28px, 2.4vw, 38px);
}

.tender-overview-side {
  display: grid;
  gap: 14px;
  align-content: start;
  justify-items: stretch;
}

.tender-cost-summary {
  align-self: center;
  display: grid;
  gap: 12px;
  min-width: 0;
  padding: 16px;
  border: 1px solid rgba(36, 122, 85, 0.16);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(36, 122, 85, 0.08), rgba(255, 255, 255, 0) 92px),
    rgba(255, 255, 255, 0.76);
  box-shadow: 0 14px 34px rgba(22, 38, 32, 0.07);
}

.tender-cost-summary .eyebrow {
  margin-bottom: 0;
  font-size: 10px;
}

.tender-cost-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line-soft);
}

.tender-cost-total span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.tender-cost-total strong {
  font-family: "Cascadia Mono", "Consolas", "SFMono-Regular", monospace;
  font-size: clamp(20px, 1.7vw, 28px);
  line-height: 1;
  color: var(--primary-dark);
}

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

.tender-cost-grid > div {
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid rgba(23, 33, 39, 0.07);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.68);
}

.tender-cost-grid strong {
  display: block;
  margin-top: 5px;
  font-family: "Cascadia Mono", "Consolas", "SFMono-Regular", monospace;
  font-size: 14px;
  line-height: 1.15;
  color: var(--text);
}

.actions.tender-overview-actions {
  width: 100%;
  display: grid;
  gap: 10px;
  justify-items: stretch;
  max-width: 360px;
  margin-left: auto;
}

.tender-actions-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  align-items: stretch;
  width: 100%;
}

.tender-actions-grid form {
  margin: 0;
  min-width: 0;
}

.tender-actions-grid form:not(.price-threshold-form) {
  display: flex;
}

.tender-actions-grid .span-2,
.tender-actions-grid .price-threshold-form {
  grid-column: 1 / -1;
}

.tender-actions-grid .button,
.tender-actions-grid .report-button {
  width: 100%;
  justify-content: center;
}

.tender-overview-actions .button {
  min-height: 38px;
  padding: 9px 14px;
  border-radius: 14px;
  font-size: 13px;
  white-space: nowrap;
}

.tender-overview-actions .report-button {
  min-width: 64px;
}

.price-threshold-form {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 42px;
  padding: 4px 5px 4px 10px;
  border: 1px solid var(--line-soft);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.68);
}

.price-threshold-form .button {
  width: auto;
  flex: 0 0 auto;
}

.price-threshold-form label {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 7px;
  min-width: 0;
  flex: 1 1 auto;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.price-threshold-form input {
  width: 64px;
  min-height: 32px;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 5px 7px;
  font: inherit;
  font-size: 13px;
  background: white;
}

.online-only-form {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  min-height: 42px;
  padding: 8px 12px;
  border: 1px solid var(--line-soft);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.68);
}

.toggle-field {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
}

.toggle-field input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.toggle-switch {
  width: 38px;
  height: 22px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: #d8d2c7;
  border: 1px solid rgba(23, 33, 39, 0.1);
  position: relative;
  transition: background var(--ease), border-color var(--ease);
}

.toggle-switch::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 1px 3px rgba(23, 33, 39, 0.18);
  transition: transform var(--ease);
}

.toggle-field input:checked + .toggle-switch {
  background: var(--primary);
  border-color: rgba(36, 122, 85, 0.24);
}

.toggle-field input:checked + .toggle-switch::after {
  transform: translateX(16px);
}

.toggle-field.is-disabled {
  cursor: not-allowed;
  color: #87958d;
}

.toggle-field.is-disabled .toggle-switch {
  background: #e5e9e5;
  filter: saturate(0.65);
}

.cost-hint {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 999px;
  background: #7a3828;
  color: #fff;
  font-size: 11px;
  line-height: 1;
}

.tender-overview-note {
  margin: 0;
  padding: 2px 0;
}

.tender-overview-files {
  margin-top: 0;
  padding-top: 14px;
}

.eyebrow {
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 12px;
  color: var(--primary-dark);
}

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

section,
article,
.card,
.grid,
.stack {
  min-width: 0;
}

strong {
  overflow-wrap: anywhere;
}
h1 {
  margin-bottom: 10px;
  font-size: clamp(30px, 3.3vw, 46px);
  line-height: 1.05;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

h2 {
  font-size: 20px;
  line-height: 1.18;
  letter-spacing: -0.018em;
}

h3 {
  letter-spacing: -0.012em;
}

.lead {
  font-size: 17px;
  max-width: 70ch;
  line-height: 1.65;
  text-wrap: pretty;
}

.grid.two {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  margin-bottom: 24px;
}

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-soft);
}

.new-tender-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.new-tender-head h2 {
  margin: 0;
}

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

.help-tooltip-trigger {
  width: 28px;
  height: 28px;
  border: 1px solid rgba(36, 122, 85, 0.18);
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary-dark);
  cursor: help;
  font: inherit;
  font-size: 15px;
  font-weight: 900;
  line-height: 1;
}

.help-tooltip-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 5;
  display: none;
  width: min(340px, calc(100vw - 56px));
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel-strong);
  box-shadow: var(--shadow);
  color: var(--text);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.42;
}

.help-tooltip-panel strong,
.help-tooltip-panel span {
  display: block;
}

.help-tooltip-panel strong {
  margin-bottom: 8px;
  font-size: 13px;
}

.help-tooltip-panel span + span {
  margin-top: 6px;
}

.help-tooltip:hover .help-tooltip-panel,
.help-tooltip:focus-within .help-tooltip-panel {
  display: block;
}

.stack { display: grid; gap: 14px; }

.field {
  display: grid;
  gap: 8px;
  font-weight: 600;
}

.field input[type="text"],
.field input[type="number"],
.field input[type="password"],
.field input[type="file"],
.field select,
.field textarea,
.config-field input,
.config-field select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  font: inherit;
  background: white;
  color: var(--text);
  transition: border-color var(--ease), box-shadow var(--ease), background var(--ease);
}

.field input[type="text"]:focus,
.field input[type="number"]:focus,
.field input[type="password"]:focus,
.field input[type="file"]:focus,
.field select:focus,
.field textarea:focus,
.config-field input:focus,
.config-field select:focus {
  border-color: rgba(36, 122, 85, 0.58);
  box-shadow: 0 0 0 4px rgba(36, 122, 85, 0.12);
  outline: none;
}

.upload-field {
  padding: 12px;
  border: 1px dashed #b7b09f;
  border-radius: 16px;
  background: #fcfaf3;
  min-height: 126px;
  align-content: center;
}

.check-field {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-weight: 600;
  line-height: 1.4;
}

.check-field input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: var(--primary);
}

.compact-check {
  display: inline-flex;
  align-items: center;
  font-size: 14px;
}

.button {
  appearance: none;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 12px 18px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  transition: background var(--ease), border-color var(--ease), color var(--ease), transform var(--ease), box-shadow var(--ease);
}

.button.primary {
  background: var(--primary);
  color: white;
  box-shadow: 0 10px 22px rgba(36, 122, 85, 0.18);
}

.button.primary:hover { background: var(--primary-dark); }

.button.ghost {
  background: var(--ghost);
  color: var(--text);
  border-color: rgba(23, 33, 39, 0.06);
}

.button.danger {
  background: #f7ddd6;
  color: #7d2b1f;
}

.button.danger-soft {
  background: #f7e8df;
  color: #7a3828;
  border-color: rgba(122, 56, 40, 0.16);
}

.button.compact-button,
.compact-button {
  min-height: 36px;
  padding: 8px 11px;
  font-size: 13px;
}

.button:hover,
.icon-button:hover {
  transform: translateY(-1px);
}

.button:active,
.icon-button:active {
  transform: translateY(1px) scale(0.99);
}

.button:focus-visible,
.icon-button:focus-visible,
a:focus-visible,
summary:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid rgba(36, 122, 85, 0.26);
  outline-offset: 3px;
}

.button:disabled,
.button.is-disabled,
.button[aria-disabled="true"],
.icon-button:disabled {
  cursor: not-allowed;
  opacity: 1;
  transform: none;
  box-shadow: none;
  filter: saturate(0.65);
}

.button:disabled,
.button.is-disabled,
.button[aria-disabled="true"] {
  border-color: rgba(115, 132, 124, 0.2);
  background: rgba(238, 242, 238, 0.88);
  color: #87958d;
}

.button.primary:disabled,
.button.primary.is-disabled,
.button.primary[aria-disabled="true"] {
  border-color: rgba(36, 122, 85, 0.13);
  background: #dfe8e1;
  color: #6f897b;
}

.button.danger-soft:disabled,
.button.danger-soft.is-disabled,
.button.danger-soft[aria-disabled="true"] {
  border-color: rgba(168, 69, 50, 0.16);
  background: #f3e8e3;
  color: #9a7d72;
}

.button:disabled .cost-hint,
.button.is-disabled .cost-hint,
.button[aria-disabled="true"] .cost-hint {
  background: #b7a6a0;
  color: rgba(255, 255, 255, 0.86);
}

.icon-button {
  appearance: none;
  width: 32px;
  height: 32px;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 50%;
  background: #fffefb;
  color: var(--text);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  padding: 0;
  align-self: start;
  justify-self: end;
  transition: background var(--ease), border-color var(--ease), color var(--ease), transform var(--ease);
}

.icon-button.danger {
  color: #8d281b;
}

.icon-button.danger:hover {
  background: #f7ddd6;
}

.manager-form {
  display: grid;
  gap: 12px;
}

.manager-toolbar {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  padding: 10px 0;
  border-top: 1px solid rgba(0,0,0,0.06);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

.manager-toolbar .button {
  padding: 10px 16px;
}

.manager-list li,
.manager-row {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) 36px;
  gap: 10px;
  align-items: start;
  justify-content: stretch;
  justify-items: start;
  text-align: left;
}

.manager-item-main {
  min-width: 0;
  width: 100%;
  overflow-wrap: anywhere;
  text-align: left;
}

.row-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-top: 2px;
  justify-self: start;
}

.row-check input {
  width: 18px;
  height: 18px;
  accent-color: var(--primary);
}

.actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(120px, 160px) minmax(120px, 170px) minmax(120px, 150px) auto auto;
  gap: 12px;
  align-items: end;
  margin-bottom: 12px;
}

.compact-filter {
  grid-template-columns: minmax(180px, 1fr) auto;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid rgba(36, 122, 85, 0.22);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.34), rgba(255, 255, 255, 0)),
    linear-gradient(135deg, #eefaf2, #cbe8d7 56%, #b9dcc8);
  color: #1c523b;
  font-size: 14px;
  font-weight: 700;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), 0 4px 12px rgba(36, 122, 85, 0.08);
}

.discovery-only-candidates {
  margin-top: 8px;
}

.discovery-only-badge {
  display: inline-block;
  padding: 5px 8px;
  border: 1px solid #d4a845;
  border-radius: 8px;
  background: #fff1c7;
  color: #704b00;
  font-size: 12px;
  font-weight: 700;
}

.manual-conflict-badge,
.manual-unconfirmed-badge {
  display: block;
  margin-top: 6px;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 800;
}

.manual-conflict-badge {
  border: 2px solid #b42318;
  background: #fff0ee;
  color: #7a1711;
}

.manual-conflict-badge span {
  display: block;
  margin-top: 3px;
  font-weight: 600;
}

.manual-unconfirmed-badge {
  border: 1px solid #d4a845;
  background: #fff1c7;
  color: #704b00;
}

.discovery-only-list {
  margin: 8px 0 0;
  padding-left: 18px;
}

.discovery-only-list li + li {
  margin-top: 8px;
}

.discovery-only-list span,
.discovery-only-list a {
  display: block;
  overflow-wrap: anywhere;
}

.regime-badge {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  border-radius: 999px;
  padding: 5px 8px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.2;
}

.regime-ban {
  background: #fde3dc;
  color: #8d281b;
}

.regime-restriction {
  background: #fff1d8;
  color: #7b4b00;
}

.regime-preference {
  background: #e7f5ec;
  color: #166b43;
}

.regime-unknown {
  background: #e8f1fb;
  color: #315f85;
}

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

.narrow-page {
  width: min(980px, 100%);
  margin: 0 auto;
}

.narrow-page .hero,
.narrow-page .card {
  border-radius: 18px;
}

.quick-check {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  gap: 12px;
  align-items: end;
  max-width: 620px;
}

.quick-check .button {
  padding: 10px 16px;
  min-width: 112px;
}

.quick-check-result {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 14px;
}

.appendix-panel {
  margin-top: 24px;
}

.appendix-table-wrap {
  max-height: 620px;
  overflow: auto;
}

.appendix-table {
  table-layout: fixed;
}

.appendix-table th,
.appendix-table td {
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: normal;
}

.appendix-table th:first-child,
.appendix-table td:first-child {
  width: 64px;
}

.appendix-table th:last-child,
.appendix-table td:last-child {
  width: auto;
}

.appendix-table th:nth-child(2),
.appendix-table td:nth-child(2) {
  width: 220px;
}

.tender-list, .files {
  list-style: none;
  padding: 0;
  margin: 0;
}

.tender-list li,
.files li {
  padding: 12px 0;
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

.tender-list li:last-child,
.files li:last-child { border-bottom: 0; }

.tender-list li {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.tender-list.manager-list li {
  display: grid;
  justify-content: stretch;
  justify-items: start;
}

.tender-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
}

.tender-meta span {
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 999px;
  padding: 3px 8px;
  background: rgba(255, 255, 255, 0.62);
}

.tender-meta .work-state-pill {
  border-color: rgba(145, 38, 26, 0.22);
  background: #fde9e4;
  color: #8f2f20;
  font-weight: 700;
}

.work-toggle {
  min-width: 132px;
  justify-content: center;
  border-color: rgba(36, 122, 85, 0.22);
  background: rgba(238, 248, 242, 0.9);
  color: var(--primary);
}

.work-toggle.active {
  border-color: rgba(145, 38, 26, 0.28);
  background: #fde9e4;
  color: #8f2f20;
}

.work-toggle.active:hover {
  background: #fbded7;
}

.pagination {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-top: 18px;
}

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

.dataset-item {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 16px;
  border-radius: 16px;
  border: 1px solid rgba(0,0,0,0.08);
  background: var(--panel-strong);
}

.dataset-item.manager-row {
  display: grid;
  justify-content: stretch;
  justify-items: start;
  align-items: start;
}

.domain-tabs {
  margin-bottom: 16px;
}

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

.domain-list li {
  padding: 10px 0;
  border-bottom: 1px solid rgba(0,0,0,0.06);
  justify-content: stretch;
  justify-items: start;
}

.domain-list li:last-child {
  border-bottom: 0;
}

.audit-list {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.audit-item {
  padding: 16px 18px;
  border-radius: 16px;
  border: 1px solid rgba(0,0,0,0.06);
}

.severity-info { background: var(--info); }
.severity-warning { background: var(--warning); }
.severity-alert { background: var(--alert); }

.overall-card p:last-child {
  margin-bottom: 0;
}

.flash {
  margin-bottom: 24px;
  font-weight: 600;
  box-shadow: none;
}

.flash.success {
  background: #e7f5ec;
}

.flash.error {
  background: #fde3dc;
}

.config-page {
  width: min(100%, 1120px);
  margin: 0 auto;
}

.config-heading {
  margin-bottom: 20px;
}

.config-path {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.config-path code {
  color: var(--text);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.config-form {
  display: grid;
  gap: 18px;
}

.config-card {
  display: grid;
  gap: 24px;
  border-radius: 18px;
}

.config-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  border-bottom: 1px solid var(--line-soft);
  padding-bottom: 18px;
}

.config-card-header h2 {
  margin-bottom: 0;
}

.config-section {
  display: grid;
  gap: 10px;
}

.config-section + .config-section {
  padding-top: 18px;
  border-top: 1px solid var(--line-soft);
}

.config-section h3 {
  margin: 0;
  color: #33423d;
  font-size: 15px;
  letter-spacing: 0;
}

.rs24-sync-panel {
  display: grid;
  gap: 10px;
  border: 1px solid rgba(23, 33, 39, 0.09);
  border-radius: 14px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.68);
}

.rs24-sync-panel.is-running {
  border-color: rgba(36, 122, 85, 0.28);
  background: rgba(235, 249, 241, 0.72);
}

.rs24-sync-panel.is-success {
  border-color: rgba(36, 122, 85, 0.2);
}

.rs24-sync-panel.is-failed {
  border-color: rgba(178, 62, 62, 0.28);
  background: rgba(255, 241, 238, 0.72);
}

.rs24-sync-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
}

.rs24-sync-head span {
  color: var(--muted);
  font-size: 12px;
}

.rs24-progress-bar {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(23, 33, 39, 0.08);
}

.rs24-progress-bar span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2f8d62, #8dcf78);
  transition: width 0.35s ease;
}

.rs24-sync-panel.is-running .rs24-progress-bar span {
  min-width: 42px;
}

.rs24-sync-details {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.rs24-sync-details span {
  border-radius: 999px;
  padding: 6px 9px;
  background: rgba(23, 33, 39, 0.055);
  color: var(--muted);
  font-size: 12px;
}

.rs24-sync-details b {
  color: var(--text);
}

.config-grid,
.config-grid.compact {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.config-field {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(260px, 380px);
  align-items: center;
  gap: 18px;
  min-width: 0;
  border: 1px solid rgba(23, 33, 39, 0.09);
  border-radius: 10px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.72);
  transition: border-color var(--ease), background var(--ease);
}

.config-field:hover {
  border-color: rgba(36, 122, 85, 0.22);
  background: rgba(255, 255, 255, 0.9);
}

.config-field-copy {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.config-field-label {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px;
}

.config-field-label strong {
  font-size: 14px;
  line-height: 1.25;
}

.config-field-label code {
  color: var(--muted);
  font-size: 11px;
  overflow-wrap: anywhere;
}

.config-field small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.config-field-control {
  min-width: 0;
}

.config-field.is-hidden,
.config-field[hidden] {
  display: none;
}

.is-hidden {
  display: none !important;
}

.config-field.is-inactive {
  opacity: 0.56;
}

.config-field.is-inactive input,
.config-field.is-inactive select,
.config-field.is-inactive textarea {
  cursor: not-allowed;
  background: #f3f2ed;
}

.toggle-control {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-height: 34px;
  width: 100%;
}

.config-field .toggle-control input[type="checkbox"] {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.toggle-track {
  position: relative;
  display: inline-flex;
  width: 54px;
  height: 30px;
  flex: 0 0 auto;
  border: 1px solid rgba(23, 33, 39, 0.14);
  border-radius: 999px;
  background: #d9d7ce;
  box-shadow: inset 0 1px 3px rgba(23, 33, 39, 0.12);
  transition: background var(--ease), border-color var(--ease), box-shadow var(--ease);
}

.toggle-track::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #fffdf8;
  box-shadow: 0 2px 6px rgba(23, 33, 39, 0.22);
  transition: transform var(--ease);
}

.toggle-control input[type="checkbox"]:checked + .toggle-track {
  border-color: rgba(20, 105, 74, 0.35);
  background: #197a55;
  box-shadow: inset 0 1px 3px rgba(6, 53, 36, 0.2);
}

.toggle-control input[type="checkbox"]:checked + .toggle-track::after {
  transform: translateX(24px);
}

.toggle-control input[type="checkbox"]:focus-visible + .toggle-track {
  outline: 3px solid rgba(36, 122, 85, 0.18);
  outline-offset: 2px;
}

.toggle-text {
  width: 78px;
  color: var(--muted);
  font-size: 12px;
  text-align: left;
}

.toggle-text::before {
  content: "Выключено";
}

.toggle-control input[type="checkbox"]:checked ~ .toggle-text::before {
  content: "Включено";
  color: #12543c;
  font-weight: 700;
}

.advanced-config-form .config-field {
  grid-template-columns: minmax(340px, 1fr) minmax(300px, 430px);
  padding: 10px 12px;
}

.secret-field {
  background: #fff9ee;
}

.config-advanced {
  display: grid;
  gap: 18px;
}

.config-advanced summary {
  cursor: pointer;
  list-style-position: outside;
  border-bottom: 1px solid var(--line-soft);
  padding-bottom: 18px;
}

.config-advanced summary span {
  display: inline-grid;
  gap: 3px;
  margin-left: 4px;
}

.config-advanced summary small {
  color: var(--muted);
}

.advanced-config-form {
  margin-top: 18px;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
}

.alert-panel {
  margin-bottom: 24px;
  background: #fff8ec;
  border-color: rgba(123, 75, 0, 0.18);
}

.critical-banner {
  margin: 0 0 16px;
  padding: 18px 22px;
  border: 1px solid rgba(168, 45, 32, 0.34);
  border-left: 6px solid #a82d20;
  border-radius: 16px;
  background: #fff0ec;
  box-shadow: var(--shadow-soft);
}

.critical-banner h2 {
  margin: 0 0 8px;
  color: #7d1f16;
  font-size: 1rem;
}

.critical-banner p {
  margin: 0;
  color: #502018;
}

.critical-banner .technical-error {
  margin-top: 8px;
  color: #7b3b32;
  font-size: 0.88rem;
}

.table-review-warning {
  margin: 0 0 16px;
  padding: 18px 22px;
  border: 1px solid rgba(174, 116, 8, 0.3);
  border-left: 6px solid #c18413;
  border-radius: 16px;
  background: #fff8e8;
  box-shadow: var(--shadow-soft);
}

.table-review-warning h2 {
  margin: 0 0 8px;
  color: #704b08;
  font-size: 1rem;
}

.table-review-warning p {
  margin: 6px 0 0;
  color: #523a11;
}

.budget-limit-banner {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(280px, 0.8fr) auto;
  gap: 22px;
  align-items: center;
  margin: 0 0 16px;
  padding: 22px;
  border: 1px solid rgba(174, 116, 8, 0.32);
  border-left: 6px solid #c18413;
  border-radius: 18px;
  background: #fff8e8;
  box-shadow: var(--shadow-soft);
}

.budget-limit-copy h2 {
  margin: 4px 0 8px;
  color: #704b08;
  font-size: 1.12rem;
}

.budget-limit-copy p {
  margin: 5px 0 0;
  color: #523a11;
}

.budget-limit-hint a {
  color: #704b08;
  font-weight: 800;
}

.budget-limit-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(120px, 1fr));
  gap: 8px;
}

.budget-limit-metrics > div {
  padding: 10px 12px;
  border: 1px solid rgba(174, 116, 8, 0.18);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.62);
}

.budget-limit-metrics span,
.budget-limit-metrics strong {
  display: block;
}

.budget-limit-metrics span {
  color: #765c2d;
  font-size: 0.74rem;
}

.budget-limit-metrics strong {
  margin-top: 4px;
  color: #3d2d10;
}

@media (max-width: 980px) {
  .budget-limit-banner {
    grid-template-columns: 1fr;
  }
}

.table-review-dialog {
  width: min(680px, calc(100vw - 32px));
  padding: 0;
  border: 0;
  border-radius: 22px;
  color: var(--ink);
  background: transparent;
  box-shadow: 0 26px 80px rgba(28, 31, 25, 0.28);
}

.table-review-dialog::backdrop {
  background: rgba(25, 28, 23, 0.56);
  backdrop-filter: blur(4px);
}

.table-review-dialog-card {
  display: grid;
  gap: 16px;
  padding: 28px;
  background: #fffdf8;
}

.table-review-dialog-card h2,
.table-review-dialog-card p,
.table-review-dialog-card ul {
  margin: 0;
}

.table-review-dialog-card ul {
  display: grid;
  gap: 8px;
  padding-left: 20px;
  color: var(--muted);
}

.table-review-confirmation {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: start;
  padding: 14px;
  border: 1px solid rgba(174, 116, 8, 0.22);
  border-radius: 14px;
  background: #fff7df;
  cursor: pointer;
}

.table-review-confirmation input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
}

.table-review-dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

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

.warning-list li {
  display: grid;
  gap: 4px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(0,0,0,0.08);
}

.warning-list li:last-child {
  border-bottom: 0;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1px;
  margin-bottom: 24px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--line);
  box-shadow: var(--shadow-soft);
}

.detail-dashboard {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-self: start;
  margin-bottom: 0;
}

.dashboard-card {
  border-radius: 0;
  border: 0;
  padding: 18px;
  background: rgba(255, 253, 248, 0.94);
  min-height: 120px;
}

.dashboard-card strong {
  display: block;
  font-family: "Cascadia Mono", "Consolas", "SFMono-Regular", monospace;
  font-size: clamp(20px, 2vw, 27px);
  line-height: 1.15;
  letter-spacing: -0.035em;
  margin-top: 8px;
  overflow-wrap: anywhere;
}

.dashboard-card .metric-label {
  display: block;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.35;
}

.dashboard-card .muted:has(+ .metric-label) {
  display: none;
}

.collapsible {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--panel);
  box-shadow: var(--shadow-soft);
  margin-bottom: 24px;
}

.collapsible summary {
  cursor: pointer;
  list-style: none;
  padding: 24px;
  font-weight: 700;
}

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

.collapsible-body {
  padding: 0 24px 24px;
}

.recommendation {
  margin-top: 18px;
  padding: 16px 18px;
  border-radius: 18px;
  background: #eef7ef;
}

.section-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.section-toolbar h2 {
  margin-bottom: 0;
}

.positions-section {
  transition: width var(--ease), transform var(--ease);
}

.positions-section.is-wide {
  position: relative;
  left: 50%;
  width: calc(100vw - 32px);
  transform: translateX(-50%);
}

.expand-table-button {
  width: 36px;
  height: 36px;
  font-size: 19px;
  background: var(--ghost);
}

.expand-table-button[aria-pressed="true"] {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

.positions-table {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--panel-strong);
}

table {
  width: 100%;
  border-collapse: collapse;
}

.positions-table table {
  table-layout: fixed;
  min-width: 2400px;
  border: 0;
}

th, td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid rgba(0,0,0,0.08);
  vertical-align: top;
}

.positions-table th,
.positions-table td {
  font-size: 13px;
  line-height: 1.4;
  padding: 9px 10px;
  border-right: 1px solid rgba(0,0,0,0.08);
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.positions-table th:last-child,
.positions-table td:last-child {
  border-right: 0;
}

.positions-table tbody tr:nth-child(even) {
  background: rgba(255,255,255,0.38);
}

thead th {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.055em;
  color: var(--muted);
  background: #f2ecdf;
  position: sticky;
  top: 0;
  z-index: 1;
}

.positions-table thead tr:not(.positions-header) {
  display: none;
}

.inline-details summary {
  cursor: pointer;
  color: var(--primary-dark);
  font-weight: 700;
}

.inline-details div {
  margin-top: 8px;
  color: var(--text);
}

.char-details {
  margin-bottom: 6px;
}

.char-details[open] + .char-preview {
  display: none;
}

.char-preview {
  color: var(--text);
}

.ai-char-details {
  margin-top: 8px;
}

.candidate-evidence-list {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  max-height: 320px;
  overflow: auto;
}

.candidate-evidence-list li {
  padding: 8px 0;
  border-top: 1px solid var(--border);
  white-space: normal;
  overflow-wrap: anywhere;
}

.candidate-evidence-list strong,
.candidate-evidence-list span {
  display: block;
  margin-bottom: 4px;
}

.ai-char-json {
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 280px;
  overflow: auto;
  margin: 8px 0 0;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #fbfaf6;
  color: var(--text);
  font: 12px/1.45 ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
}

.ai-char-empty {
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
}

@media (max-width: 840px) {
  .shell-inner {
    width: calc(100% - 24px);
  }

  .shell-header .shell-inner {
    align-items: flex-start;
    gap: 10px;
    padding: 12px 0;
  }

  .brand {
    padding-top: 6px;
  }

  .top-nav {
    max-width: 100%;
    padding-bottom: 4px;
  }

  .top-nav a {
    padding: 7px 10px;
  }

  .shell-main {
    padding-top: 18px;
  }

  .detail-hero-grid,
  .detail-risk-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .detail-side-stack,
  .risk-stack {
    gap: 14px;
  }

  .hero,
  .hero.compact,
  .card {
    padding: 18px;
    border-radius: 18px;
  }

  .positions-section.is-wide {
    position: static;
    left: auto;
    width: auto;
    transform: none;
  }

  .grid.two { grid-template-columns: minmax(0, 1fr); }
  .filter-bar,
  .compact-filter,
  .quick-check { grid-template-columns: 1fr; }
  .dashboard-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .positions-table { overflow-x: auto; }
  .positions-table table { table-layout: auto; }
}

@media (max-width: 640px) {
  .shell-header .shell-inner {
    display: grid;
  }

  .top-nav {
    margin-left: 0;
    width: 100%;
  }

  .actions,
  .pagination {
    align-items: stretch;
  }

  .actions .button,
  .actions form,
  .pagination .button {
    width: 100%;
  }

  .dashboard-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-card {
    min-height: 0;
    padding: 16px;
  }

  .manager-list li,
  .manager-row {
    grid-template-columns: 24px minmax(0, 1fr);
  }

  .manager-list .icon-button,
  .manager-row .icon-button {
    grid-column: 2;
    justify-self: start;
  }

  .positions-table {
    overflow-x: visible;
    border: 0;
    border-radius: 0;
    background: transparent;
  }

  .positions-table table,
  .positions-table thead,
  .positions-table tbody,
  .positions-table tr,
  .positions-table th,
  .positions-table td {
    display: block;
    width: 100%;
  }

  .positions-table table {
    min-width: 0;
    border: 0;
    background: transparent;
  }

  .positions-table thead {
    display: none;
  }

  .positions-table tbody {
    display: grid;
    gap: 12px;
  }

  .positions-table tbody tr {
    border: 1px solid var(--line);
    border-radius: 16px;
    background: var(--panel-strong);
    box-shadow: var(--shadow-soft);
    overflow: hidden;
  }

  .positions-table th,
  .positions-table td {
    border-right: 0;
  }

  .positions-table td {
    display: grid;
    grid-template-columns: minmax(104px, 38%) minmax(0, 1fr);
    gap: 12px;
    padding: 10px 12px;
    border-bottom: 1px solid var(--line-soft);
    overflow-wrap: anywhere;
  }

  .positions-table td:last-child {
    border-bottom: 0;
  }

  .positions-table td::before {
    color: var(--muted);
    font-size: 11px;
    font-weight: 750;
    letter-spacing: 0.045em;
    text-transform: uppercase;
  }

  .tender-positions-table td:nth-child(1)::before { content: "№"; }
  .tender-positions-table td:nth-child(2)::before { content: "Позиция"; }
  .tender-positions-table td:nth-child(3)::before { content: "Характеристики"; }
  .tender-positions-table td:nth-child(4)::before { content: "ОКПД2"; }
  .tender-positions-table td:nth-child(5)::before { content: "Нацрежим"; }
  .tender-positions-table td:nth-child(6)::before { content: "Статус"; }
  .tender-positions-table td:nth-child(7)::before { content: "Кандидат"; }
  .tender-positions-table td:nth-child(8)::before { content: "Страна"; }
  .tender-positions-table td:nth-child(9)::before { content: "Количество"; }
  .tender-positions-table td:nth-child(10)::before { content: "Ед."; }
  .tender-positions-table td:nth-child(11)::before { content: "Цена"; }
  .tender-positions-table td:nth-child(12)::before { content: "Стоимость"; }
  .tender-positions-table td:nth-child(13)::before { content: "НМЦК ед."; }
  .tender-positions-table td:nth-child(14)::before { content: "НМЦК поз."; }
  .tender-positions-table td:nth-child(15)::before { content: "Свой поставщик"; }
  .tender-positions-table td:nth-child(16)::before { content: "Цена своего"; }
  .tender-positions-table td:nth-child(17)::before { content: "Whitelist"; }
  .tender-positions-table td:nth-child(18)::before { content: "Ссылка"; }
  .tender-positions-table td:nth-child(19)::before { content: "Попытка"; }
  .tender-positions-table td:nth-child(20)::before { content: "Аналог"; }
  .tender-positions-table td:nth-child(21)::before { content: "Комментарий"; }
  .tender-positions-table td:nth-child(22)::before { content: "Действия"; }

  .catalog-table td:nth-child(1)::before { content: "Поставщик"; }
  .catalog-table td:nth-child(2)::before { content: "Товар"; }
  .catalog-table td:nth-child(3)::before { content: "Производитель"; }
  .catalog-table td:nth-child(4)::before { content: "Артикул"; }
  .catalog-table td:nth-child(5)::before { content: "Цена"; }
}

/* UI lab: procurement cockpit direction */
:root {
  --bg: #eff3ef;
  --bg-soft: #e6ebe7;
  --panel: #fcfdfb;
  --panel-strong: #ffffff;
  --text: #162119;
  --muted: #5f6d64;
  --line: #d8e0d8;
  --line-soft: rgba(22, 33, 25, 0.08);
  --primary: #1f5f49;
  --primary-dark: #174636;
  --primary-soft: #e4efe9;
  --ghost: #edf1ee;
  --warning: #f7efe0;
  --alert: #f4e3dc;
  --info: #e7edf0;
  --shadow: 0 18px 44px rgba(33, 42, 35, 0.08);
  --shadow-soft: 0 8px 24px rgba(33, 42, 35, 0.055);
}

body {
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.9) 0, rgba(255, 255, 255, 0) 34rem),
    radial-gradient(circle at 88% 10%, rgba(31, 95, 73, 0.06) 0, rgba(31, 95, 73, 0) 24rem),
    linear-gradient(180deg, #f7faf7 0%, #eef2ef 42%, #e6ebe7 100%);
}

body::before {
  display: none;
}

.shell-inner {
  max-width: 1600px;
}

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

.work-title,
.work-actions,
.decision-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.66), var(--shadow-soft);
}

.work-title {
  border-top: 3px solid #8f9a91;
  background:
    linear-gradient(180deg, rgba(135, 148, 138, 0.08), rgba(255,255,255,0) 90px),
    rgba(255, 255, 255, 0.94);
}

.work-actions {
  border-top: 3px solid #1f5f49;
  background:
    linear-gradient(180deg, rgba(31, 95, 73, 0.08), rgba(255,255,255,0) 84px),
    rgba(255, 255, 255, 0.94);
}

.work-title {
  padding: 20px 22px;
}

.work-title h1 {
  max-width: 980px;
  margin-bottom: 12px;
  font-size: clamp(28px, 2.4vw, 38px);
}

.status-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 12px;
}

.meta-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  border: 1px solid rgba(114, 128, 120, 0.22);
  border-radius: 999px;
  padding: 4px 11px;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.4), rgba(255,255,255,0)),
    linear-gradient(135deg, #fcfdfb, #edf2ee 58%, #e3ebe4);
  color: #57655e;
  font-size: 13px;
  font-weight: 700;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.46), 0 3px 10px rgba(74, 89, 80, 0.05);
}

.meta-pill-mode {
  background:
    linear-gradient(135deg, rgba(255,255,255,0.42), rgba(255,255,255,0)),
    linear-gradient(135deg, #fffdf7, #eff2ea 58%, #e5e9df);
  border-color: rgba(140, 145, 128, 0.2);
  color: #60695d;
}

.meta-pill-online {
  background:
    linear-gradient(135deg, rgba(255,255,255,0.4), rgba(255,255,255,0)),
    linear-gradient(135deg, #f2faf4, #dceee3 58%, #cfe5d7);
  border-color: rgba(92, 133, 109, 0.24);
  color: #446554;
}

.meta-pill-count {
  background:
    linear-gradient(135deg, rgba(255,255,255,0.38), rgba(255,255,255,0)),
    linear-gradient(135deg, #fdf7ea, #f2e3c2 58%, #ead5a9);
  border-color: rgba(168, 139, 80, 0.26);
  color: #7a6435;
}

.source-line {
  max-width: 100%;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.work-actions {
  padding: 18px;
}

.work-actions h2 {
  margin-bottom: 12px;
}

.work-actions .actions {
  gap: 8px;
}

.work-actions .button {
  min-height: 38px;
  padding: 9px 13px;
  font-size: 14px;
}

.file-strip {
  display: grid;
  gap: 5px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line-soft);
  font-size: 13px;
  color: var(--muted);
}

.file-strip span:not(.metric-label) {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.decision-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.78fr) minmax(320px, 0.82fr);
  gap: 16px;
  align-items: stretch;
  margin-bottom: 16px;
}

.analysis-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 0.95fr) minmax(360px, 1.1fr);
  gap: 16px;
  margin-bottom: 16px;
}

.analysis-card {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-soft);
  padding: 16px;
}

.analysis-card p {
  margin: 0;
  color: var(--text);
  font-size: 14px;
  line-height: 1.58;
}

.analysis-card p + p {
  margin-top: 10px;
}

.analysis-card-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.analysis-card-header span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.analysis-card-header strong {
  color: var(--primary-dark);
  font-family: "Cascadia Mono", "Consolas", "SFMono-Regular", monospace;
  font-size: 15px;
  letter-spacing: -0.02em;
}

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

.auditor-list li {
  display: grid;
  gap: 3px;
  border-left: 3px solid var(--line);
  padding-left: 10px;
}

.auditor-list li.severity-alert { border-left-color: #a84532; }
.auditor-list li.severity-warning { border-left-color: #a66a12; }
.auditor-list li.severity-info { border-left-color: #496879; }

.auditor-list strong {
  font-size: 13px;
}

.auditor-list span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.auditor-more {
  margin-top: 12px;
}

.auditor-more summary {
  color: var(--primary-dark);
  cursor: pointer;
  font-size: 13px;
  font-weight: 800;
}

.decision-card {
  padding: 18px;
}

.finance-card {
  border-top: 3px solid #2f7455;
  background:
    linear-gradient(180deg, rgba(47, 116, 85, 0.08), rgba(255,255,255,0) 92px),
    rgba(255, 255, 255, 0.94);
}

.coverage-card {
  border-top: 3px solid #738c88;
  background:
    linear-gradient(180deg, rgba(115, 140, 136, 0.08), rgba(255,255,255,0) 92px),
    rgba(255, 255, 255, 0.94);
}

.risk-card {
  border-top: 3px solid #b18143;
  background:
    linear-gradient(180deg, rgba(177, 129, 67, 0.08), rgba(255,255,255,0) 92px),
    rgba(255, 255, 255, 0.94);
}

.decision-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.decision-heading-label {
  display: flex;
  align-items: center;
  gap: 9px;
}

.calculation-refresh-form {
  display: inline-flex;
  margin: 0;
}

.calculation-refresh-button {
  width: 30px;
  height: 30px;
  align-self: center;
  justify-self: auto;
  border-color: rgba(47, 116, 85, 0.2);
  background: rgba(255, 255, 255, 0.82);
  color: #246145;
}

.calculation-refresh-button:hover {
  border-color: rgba(47, 116, 85, 0.36);
  background: #fff;
}

.calculation-refresh-button svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.decision-kpi {
  display: grid;
  justify-items: end;
  gap: 4px;
}

.decision-kpi-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.decision-heading span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.decision-heading strong,
.finance-grid strong,
.coverage-list strong {
  font-family: "Cascadia Mono", "Consolas", "SFMono-Regular", monospace;
  letter-spacing: -0.04em;
}

.decision-heading strong {
  font-size: clamp(20px, 1.8vw, 30px);
}

.negative {
  color: #a84532;
}

.review-required {
  color: #93631d;
}

.finance-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: min(100%, 580px);
  margin: 0 auto;
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--line);
}

.finance-grid > div {
  min-height: 86px;
  padding: 13px;
  background: #fff;
}

.finance-grid strong {
  display: block;
  margin-top: 8px;
  font-size: clamp(20px, 1.8vw, 28px);
  line-height: 1.05;
}

.found-finance-block {
  width: min(100%, 580px);
  margin: 14px auto 0;
}

.found-finance-title {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.found-finance-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--line);
}

.found-finance-grid > div {
  min-height: 74px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.96);
}

.found-finance-grid strong {
  display: block;
  margin-top: 7px;
  font-family: "Cascadia Mono", "Consolas", "SFMono-Regular", monospace;
  font-size: clamp(18px, 1.45vw, 24px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.coverage-list,
.risk-list {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.coverage-list div,
.risk-list li {
  display: grid;
  gap: 4px;
  padding: 10px 0;
  border-top: 1px solid var(--line-soft);
}

.coverage-list div:first-child,
.risk-list li:first-child {
  border-top: 0;
  padding-top: 0;
}

.coverage-list span,
.risk-list span {
  color: var(--muted);
  font-size: 13px;
}

.coverage-list strong {
  font-size: 20px;
}

.risk-card {
  border-left: 1px solid var(--line);
}

.risk-list strong {
  color: #563d13;
  font-size: 14px;
}

.positions-section {
  padding: 0;
  overflow: hidden;
}

.summary-card-block {
  border-top: 3px solid #819188;
  background:
    linear-gradient(180deg, rgba(129, 145, 136, 0.07), rgba(255,255,255,0) 88px),
    rgba(255, 255, 255, 0.94);
}

.overall-card {
  border-top: 3px solid #9b8862;
  background:
    linear-gradient(180deg, rgba(155, 136, 98, 0.07), rgba(255,255,255,0) 88px),
    rgba(255, 255, 255, 0.94);
}

.positions-toolbar {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(160px, 0.22fr) minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.94);
}

.positions-toolbar .eyebrow {
  margin-bottom: 4px;
}

.positions-toolbar h2 {
  margin: 0;
}

.position-conflict-banner {
  display: grid;
  gap: 12px;
  margin: 14px 18px;
  padding: 14px 16px;
  border: 2px solid #a82d20;
  border-radius: 12px;
  background: #fff3ef;
  color: #502018;
}

.position-conflict-banner strong {
  color: #7d1f16;
}

.position-conflict-banner p {
  margin: 4px 0 0;
  line-height: 1.5;
}

.position-conflict-banner details summary {
  color: #7d1f16;
  cursor: pointer;
  font-weight: 800;
}

.position-conflict-banner ul {
  display: grid;
  gap: 6px;
  margin: 10px 0 0;
  padding-left: 20px;
}

.table-tools {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  align-items: end;
}

.table-search {
  display: grid;
  gap: 4px;
  min-width: min(320px, 100%);
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.table-search input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 9px 11px;
  font: inherit;
  background: #fff;
}

.segmented-control {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 11px;
  overflow: hidden;
  background: #fff;
}

.segmented-control button {
  border: 0;
  border-left: 1px solid var(--line);
  padding: 9px 10px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  font-weight: 750;
}

.segmented-control button:first-child {
  border-left: 0;
}

.segmented-control button[aria-pressed="true"] {
  background: var(--primary);
  color: #fff;
}

.positions-table {
  border: 0;
  border-radius: 0;
  max-height: min(72vh, 860px);
  overflow: auto;
}

.positions-table table {
  min-width: 2280px;
}

.positions-table th,
.positions-table td {
  padding: 8px 9px;
  font-size: 12px;
  line-height: 1.35;
}

.positions-table thead th {
  position: sticky;
  top: 0;
  z-index: 3;
  box-shadow: inset 0 -1px 0 var(--line);
}

.positions-table tbody tr[data-over="true"] {
  box-shadow: inset 4px 0 0 #a84532;
}

.positions-table tbody tr[data-missing="true"] {
  box-shadow: inset 4px 0 0 #a66a12;
}

.positions-table tbody tr[hidden] {
  display: none;
}

.positions-section.actions-hidden [data-actions-cell],
.positions-section.actions-hidden col.position-actions-col {
  display: none;
}

.positions-table th.position-actions-col,
.positions-table td.position-actions-col {
  position: sticky;
  right: 0;
  min-width: 178px;
  width: 178px;
  border-left: 1px solid var(--line);
  border-right: 0;
  background: #fbfaf6;
  box-shadow: -14px 0 22px rgba(46, 39, 25, 0.10), inset 1px 0 0 rgba(23, 33, 39, 0.08);
}

.positions-table th.position-actions-col {
  z-index: 7;
  background: #f2ecdf;
}

.positions-table td.position-actions-col {
  z-index: 2;
}

.row-actions {
  display: grid;
  gap: 6px;
  min-width: 158px;
}

.row-actions form {
  margin: 0;
}

.row-action-button {
  width: 100%;
  min-height: 30px;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 6px 8px;
  background: #fff;
  color: var(--text);
  font: inherit;
  font-size: 12px;
  font-weight: 750;
  cursor: pointer;
  text-align: center;
  white-space: nowrap;
}

.row-action-button:hover {
  border-color: rgba(36, 122, 85, 0.35);
  background: var(--primary-soft);
}

.row-action-button.danger-soft {
  background: #fff4ed;
  color: #7a3828;
  border-color: rgba(122, 56, 40, 0.2);
}

.insight-section,
.collapsible {
  margin-top: 16px;
}

@media (max-width: 1120px) {
  .config-page {
    width: 100%;
  }

  .config-field,
  .advanced-config-form .config-field {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .work-header,
  .decision-panel,
  .analysis-panel {
    grid-template-columns: 1fr;
  }

  .tender-overview-layout {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .tender-overview-actions {
    justify-items: stretch;
    max-width: none;
    margin-left: 0;
  }

  .tender-actions-grid {
    grid-template-columns: 1fr;
  }

  .tender-actions-grid .span-2,
  .tender-actions-grid .price-threshold-form {
    grid-column: auto;
  }

  .positions-toolbar {
    grid-template-columns: 1fr;
    position: static;
  }

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

@media (max-width: 640px) {
  .config-card-header {
    align-items: stretch;
    flex-direction: column;
  }

  .config-field,
  .advanced-config-form .config-field {
    padding: 12px;
  }

  .form-actions {
    justify-content: stretch;
  }

  .form-actions .button,
  .config-card-header .button {
    width: 100%;
  }

  .work-title,
  .work-actions,
  .decision-card {
    border-radius: 14px;
    padding: 16px;
  }

  .finance-grid {
    grid-template-columns: 1fr;
    width: 100%;
  }

  .found-finance-block {
    width: 100%;
  }

  .found-finance-grid {
    grid-template-columns: 1fr;
  }

  .segmented-control {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
  }

  .segmented-control button:nth-child(odd) {
    border-left: 0;
  }

  .positions-toolbar {
    position: static;
    padding: 14px;
  }

  .positions-table {
    max-height: none;
  }

  .positions-table table {
    display: table;
    min-width: 2280px;
  }

  .positions-table thead {
    display: table-header-group;
  }

  .positions-table tbody {
    display: table-row-group;
  }

  .positions-table tr {
    display: table-row;
  }

  .positions-table th,
  .positions-table td {
    display: table-cell;
    width: auto;
    min-height: 0;
    padding: 8px 9px;
  }

  .positions-table td {
    justify-content: initial;
    gap: 0;
  }

  .positions-table td::before {
    content: none;
    display: none;
  }

  .positions-table tbody tr {
    margin: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }
}

.auth-page {
  min-height: calc(100dvh - 180px);
  display: grid;
  place-items: center;
}

.auth-panel {
  width: min(420px, 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: rgba(255,253,248,0.92);
  box-shadow: var(--shadow-soft);
  padding: 28px;
}

.auth-panel h1 {
  margin: 2px 0 20px;
  font-size: 32px;
  line-height: 1.08;
}

.auth-form {
  display: grid;
  gap: 14px;
}

.auth-form label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.auth-form input,
.users-table select,
.user-create-form input,
.user-create-form select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 11px;
  background: var(--panel-strong);
  color: var(--text);
  font: inherit;
}

.users-card {
  padding: 0;
  overflow: hidden;
}

.users-create-card,
.profile-card {
  margin-bottom: 16px;
}

.user-create-form {
  display: grid;
  grid-template-columns: minmax(180px, 1.2fr) minmax(180px, 1.2fr) minmax(160px, 0.8fr) auto;
  gap: 12px;
  align-items: end;
}

.user-create-form label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.profile-password-form {
  max-width: 440px;
}

.table-scroll {
  overflow-x: auto;
}

.users-table {
  width: 100%;
  min-width: 820px;
  border-collapse: collapse;
}

.users-table th,
.users-table td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--line-soft);
  text-align: left;
  vertical-align: middle;
}

.users-table th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .06em;
  background: rgba(235,229,216,0.42);
}

.users-table tr:last-child td {
  border-bottom: 0;
}

.inline-form {
  display: flex;
  gap: 8px;
  align-items: center;
  margin: 0;
}

.inline-form select {
  max-width: 180px;
}

@media (max-width: 900px) {
  .user-create-form {
    grid-template-columns: 1fr;
  }
}
