:root {
  --bg: #f7f8fa;
  --panel: #ffffff;
  --panel-2: #fbfcfd;
  --text: #161b22;
  --text-strong: #0f172a;
  --muted: #667085;
  --line: #e6e9ef;
  --soft-line: #f1f3f6;
  --accent: #f26a00;
  --accent-2: #14715f;
  --accent-soft: #fff3e8;
  --success: #2f8a78;
  --success-hover: #287466;
  --success-shadow: rgba(47, 138, 120, .12);
  --reject: #c06456;
  --reject-hover: #aa5145;
  --reject-shadow: rgba(192, 100, 86, .12);
  --control: #f3f5f8;
  --control-hover: #e9edf3;
  --danger: #b42318;
  --radius: 7px;
  --font-sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --text-xs: 12px;
  --text-sm: 13px;
  --text-md: 14px;
  --text-lg: 15px;
  --text-xl: 20px;
  --text-2xl: 24px;
  --leading-tight: 1.2;
  --leading-snug: 1.32;
  --leading-normal: 1.45;
  --leading-relaxed: 1.6;
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-semibold: 600;
  --weight-bold: 700;
  --glass-fill: linear-gradient(180deg, rgba(255, 255, 255, .56), rgba(255, 255, 255, .28));
  --glass-fill-strong: linear-gradient(180deg, rgba(255, 255, 255, .74), rgba(255, 255, 255, .40));
  --glass-border: rgba(255, 255, 255, .54);
  --glass-shadow: 0 16px 36px rgba(15, 23, 42, .10), inset 0 1px 0 rgba(255, 255, 255, .72), inset 0 -1px 0 rgba(255, 255, 255, .14);
  --glass-shadow-strong: 0 22px 48px rgba(15, 23, 42, .14), inset 0 1px 0 rgba(255, 255, 255, .78), inset 0 -1px 0 rgba(255, 255, 255, .18);
  --glass-blur: blur(24px) saturate(175%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { font-family: var(--font-sans); }
body {
  position: relative;
  margin: 0;
  color: var(--text);
  background: var(--bg);
  font-family: var(--font-sans);
  font-size: var(--text-md);
  line-height: var(--leading-normal);
  font-weight: var(--weight-regular);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
}
body::before {
  z-index: -2;
  background:
    radial-gradient(circle at 14% 18%, rgba(242, 106, 0, .16), transparent 30%),
    radial-gradient(circle at 82% 12%, rgba(20, 113, 95, .12), transparent 28%),
    radial-gradient(circle at 74% 78%, rgba(59, 130, 246, .10), transparent 26%),
    linear-gradient(180deg, #f8fafc 0%, #eff4f7 100%);
}
body::after {
  z-index: -1;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .42), transparent 30%),
    radial-gradient(circle at 26% 34%, rgba(255, 255, 255, .45), transparent 18%),
    radial-gradient(circle at 78% 62%, rgba(255, 255, 255, .30), transparent 20%);
}
a { color: var(--accent-2); text-decoration: none; }
a:hover { color: #0f5e50; }
p {
  margin: 0;
  font-size: var(--text-md);
  line-height: var(--leading-normal);
  color: #475467;
}
strong { font-weight: var(--weight-semibold); color: var(--text-strong); }
h1, h2, h3, h4 {
  margin: 0;
  color: var(--text-strong);
  letter-spacing: -0.01em;
}
h1 {
  font-size: clamp(22px, 3vw, 28px);
  line-height: 1.08;
  font-weight: var(--weight-bold);
}
h2 {
  font-size: var(--text-lg);
  line-height: var(--leading-tight);
  font-weight: var(--weight-semibold);
}
h3 {
  font-size: var(--text-md);
  line-height: var(--leading-snug);
  font-weight: var(--weight-semibold);
}
button, input, select, textarea { font: inherit; }
.toast-stack {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 1000;
  display: grid;
  gap: 8px;
  pointer-events: none;
}
.toast {
  min-width: 280px;
  max-width: min(380px, calc(100vw - 32px));
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  color: #fff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, .18);
  pointer-events: auto;
}
.toast-success { background: #1f8f62; }
.toast-error { background: #c24141; }
.toast-message {
  font-size: var(--text-md);
  line-height: var(--leading-normal);
  font-weight: var(--weight-medium);
}
.toast-close {
  min-height: auto;
  min-width: auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font-size: 18px;
  line-height: 1;
  box-shadow: none;
  opacity: .8;
}
.toast-close:hover { background: transparent; opacity: 1; }
button, .button {
  min-height: 30px;
  border: 1px solid transparent;
  background: var(--control);
  color: #263241;
  border-radius: 8px;
  padding: 5px 10px;
  cursor: pointer;
  font-weight: var(--weight-medium);
  font-size: var(--text-sm);
  line-height: var(--leading-tight);
  letter-spacing: .01em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
button:hover, .button:hover { background: var(--control-hover); }
.primary { background: var(--text-strong); color: #fff; border-color: var(--text-strong); box-shadow: 0 8px 18px rgba(15, 23, 42, .12); }
.primary:hover { background: #273244; border-color: #273244; }
.danger { color: var(--danger); background: #fff1f2; }
.danger:hover { background: #ffe4e6; }
.soft-action { background: #fff7ed; color: #9a3412; border-color: #fed7aa; }
.soft-action:hover { background: #ffedd5; border-color: #fdba74; }
.table-status-action {
  min-height: 0;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 10px;
  line-height: 1.1;
  letter-spacing: .02em;
}
.decision-actions {
  display: grid;
  gap: 6px;
}
.decision-approve {
  background: var(--success);
  color: #fff;
  border-color: var(--success);
  box-shadow: 0 8px 18px var(--success-shadow);
}
.decision-approve:hover {
  background: var(--success-hover);
  border-color: var(--success-hover);
}
.decision-reject {
  background: var(--reject);
  color: #fff;
  border-color: var(--reject);
  box-shadow: 0 8px 18px var(--reject-shadow);
}
.decision-reject:hover {
  background: var(--reject-hover);
  border-color: var(--reject-hover);
}
.verification-result {
  display: grid;
  gap: 6px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-2);
  color: #475467;
  font-size: var(--text-sm);
  line-height: var(--leading-normal);
}
.verification-result > .row > span:first-child {
  color: #667085;
  font-weight: var(--weight-medium);
}
.verification-result p {
  margin: 0;
}
.verification-result.is-approved {
  border-color: #cde9dc;
  background: #f3fbf6;
}
.verification-result.is-rejected {
  border-color: #efd0ca;
  background: #fff7f5;
}
.decision-note {
  display: grid;
  gap: 2px;
  padding-top: 3px;
  border-top: 1px solid rgba(102, 112, 133, .14);
}
.decision-note strong {
  color: #344054;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
}
.link-button { background: transparent; border-color: transparent; color: #9a3412; box-shadow: none; }
.link-button:hover { background: #fff7ed; }
.field-label {
  display: inline-flex;
  align-items: baseline;
  gap: 3px;
  color: #344054;
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  line-height: var(--leading-snug);
}
.required-marker { color: #b42318; font-weight: var(--weight-semibold); }
input, select, textarea {
  width: 100%;
  border: 1px solid #d9dee7;
  border-radius: 8px;
  padding: 8px 9px;
  background: #fff;
  color: var(--text);
  min-height: 34px;
  font-size: var(--text-md);
  line-height: var(--leading-normal);
  font-weight: var(--weight-regular);
}
select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9' fill='none'%3E%3Cpath d='M1 1.25L7 7.25L13 1.25' stroke='%23263141' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 14px 9px;
  padding-right: 40px;
}
input:focus, select:focus, textarea:focus { outline: 3px solid var(--accent-soft); border-color: #ffb36b; }
.custom-select {
  position: relative;
  width: 100%;
  z-index: 1;
}
.custom-select.is-open {
  z-index: 220;
}
.custom-select-native {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  width: 100% !important;
  min-width: 0 !important;
}
.custom-select-trigger {
  width: 100%;
  min-height: 34px;
  justify-content: flex-start;
  padding: 8px 40px 8px 9px;
  border: 1px solid #d9dee7;
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  font-size: var(--text-md);
  line-height: var(--leading-normal);
  font-weight: var(--weight-regular);
  box-shadow: none;
  position: relative;
  z-index: 2;
}
.custom-select-trigger:hover {
  background: #fff;
  border-color: #cfd6e2;
}
.custom-select-trigger::after {
  content: "";
  position: absolute;
  right: 14px;
  top: 50%;
  width: 14px;
  height: 9px;
  margin-top: -4px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9' fill='none'%3E%3Cpath d='M1 1.25L7 7.25L13 1.25' stroke='%23263141' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  transition: transform .18s ease;
}
.custom-select.is-open .custom-select-trigger {
  outline: 3px solid var(--accent-soft);
  border-color: #ffb36b;
}
.custom-select.is-open .custom-select-trigger::after {
  transform: rotate(180deg);
}
.custom-select-trigger-text {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.custom-select-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 230;
  display: none;
  max-height: min(320px, calc(100vh - 96px));
  padding: 6px;
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 1px solid rgba(15, 23, 42, .1);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 18px 44px rgba(15, 23, 42, .18), 0 4px 12px rgba(15, 23, 42, .08);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.custom-select.is-open .custom-select-menu {
  display: grid;
  gap: 4px;
}
.custom-select-option {
  width: 100%;
  min-height: 40px;
  justify-content: flex-start;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  color: #344054;
  font-size: var(--text-md);
  line-height: var(--leading-normal);
  font-weight: var(--weight-regular);
  box-shadow: none;
  text-align: left;
  white-space: nowrap;
}
.toolbar-filter:has(select[name="sort"]) .custom-select-menu { min-width: 230px; right: auto; }
.toolbar-filter:has(select[name="status"]) .custom-select-menu {
  left: auto;
  right: 0;
  width: max-content;
  min-width: 280px;
  max-width: min(340px, calc(100vw - 32px));
}
.custom-select-option:hover {
  background: #fff7ed;
  border-color: #fed7aa;
}
.custom-select-option.is-selected {
  background: #fff7ed;
  border-color: #fdba74;
  color: #9a3412;
  font-weight: var(--weight-semibold);
}
.custom-select-option:disabled {
  opacity: .55;
  cursor: not-allowed;
}

.entity-switcher:has(.custom-select.is-open),
.toolbar-filter:has(.custom-select.is-open),
.toolbar-search:has(.custom-select.is-open),
.panel:has(.custom-select.is-open),
.sidebar-footer:has(.custom-select.is-open) {
  position: relative;
  z-index: 210;
}
.panel:has(.custom-select.is-open) > .table-toolbar {
  position: relative;
  z-index: 500;
}

.panel,
.sidebar,
.sidebar-footer,
.entity-switcher,
.table-toolbar,
.toolbar-filters,
.app-dialog-card,
.modal-subpanel {
  overflow: visible;
}
input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  display: inline-grid;
  place-content: center;
  width: 16px;
  min-width: 16px;
  height: 16px;
  min-height: 16px;
  margin: 0;
  padding: 0;
  border: 1px solid #d9dee7;
  border-radius: 4px;
  background: #fff;
  color: #fff;
  vertical-align: top;
}
input[type="checkbox"]::before {
  content: "";
  width: 8px;
  height: 5px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  opacity: 0;
  transform: translateY(-1px) rotate(-45deg);
}
input[type="checkbox"]:checked {
  border-color: var(--accent);
  background: var(--accent);
}
input[type="checkbox"]:checked::before {
  opacity: 1;
}
input[type="checkbox"]:focus {
  outline: 2px solid #fed7aa;
  outline-offset: 2px;
}
label {
  display: grid;
  gap: 5px;
  font-size: var(--text-sm);
  line-height: var(--leading-snug);
  font-weight: var(--weight-medium);
  color: #303948;
}

.shell { min-height: 100vh; }
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 220px;
  height: 100dvh;
  padding: 18px 14px;
  border-right: 1px solid rgba(255, 255, 255, .42);
  display: flex;
  flex-direction: column;
  gap: 14px;
  z-index: 20;
}
.sidebar-scroll {
  min-height: 0;
  display: grid;
  align-content: start;
  gap: 10px;
  overflow-y: auto;
  padding-right: 2px;
}
.mobile-sidebar-head { display: block; }
.mobile-nav-toggle { display: none; }
.brand { display: flex; justify-content: center; margin-bottom: 16px; }
.brand img { width: 108px; height: auto; display: block; object-fit: contain; }
.nav { display: grid; gap: 2px; }
.nav a,
.nav-group summary {
  color: #4b5565;
  padding: 7px 9px;
  font-weight: 500;
  border-radius: 8px;
  min-height: 32px;
  display: flex;
  align-items: center;
  list-style: none;
  cursor: pointer;
}
.nav-group summary::-webkit-details-marker { display: none; }
.nav-group summary::after {
  content: "";
  margin-left: auto;
  width: 10px;
  height: 10px;
  border-right: 1.6px solid currentColor;
  border-bottom: 1.6px solid currentColor;
  transform: rotate(45deg) translateY(-1px);
  transition: transform .18s ease;
}
.nav-group[open] summary::after {
  transform: rotate(225deg) translateY(-1px);
}
.nav a.active,
.nav-group summary.active { background: #fff7ed; color: #9a3412; font-weight: 600; }
.nav a:hover,
.nav-group summary:hover { background: #f7f8fa; }
.nav-submenu {
  display: grid;
  gap: 2px;
  padding: 4px 0 0 10px;
}
.nav-submenu a {
  min-height: 30px;
  font-size: var(--text-sm);
}
.sidebar-footer {
  margin-top: auto;
  padding-top: 14px;
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  border-top: 1px solid rgba(102, 112, 133, .12);
}
.user-meta {
  display: grid;
  gap: 2px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}
.user-meta strong {
  color: #1f2937;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
}
.user-meta span {
  color: #667085;
  font-size: var(--text-xs);
}
.entity-switcher {
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fbfcfd;
}
.entity-switcher select {
  width: 100%;
  min-height: 34px;
}
.sidebar-logout {
  width: 100%;
  justify-content: center;
}
.django-admin-fab {
  position: fixed;
  right: 10px;
  bottom: 8px;
  z-index: 35;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  min-height: 18px;
  padding: 2px 6px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .46);
  background: linear-gradient(180deg, rgba(255, 255, 255, .28), rgba(255, 255, 255, .14));
  color: rgba(71, 84, 103, .52);
  font-size: 9px;
  line-height: 1;
  font-weight: var(--weight-medium);
  letter-spacing: .04em;
  text-transform: lowercase;
  box-shadow: 0 8px 18px rgba(15, 23, 42, .06);
  backdrop-filter: blur(12px) saturate(130%);
  -webkit-backdrop-filter: blur(12px) saturate(130%);
  opacity: .58;
}
.django-admin-fab:hover {
  color: rgba(71, 84, 103, .76);
  opacity: .84;
  background: linear-gradient(180deg, rgba(255, 255, 255, .42), rgba(255, 255, 255, .22));
}
.main { margin-left: 220px; padding: 16px 18px 24px; min-width: 0; }
.page { max-width: 1480px; margin: 0; }
.topbar { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.eyebrow { margin: 0 0 6px; color: #d35400; font-size: 11px; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; }
.title { margin: 0 0 4px; font-size: var(--text-xl); letter-spacing: -0.02em; line-height: 1.12; font-weight: var(--weight-bold); color: var(--text-strong); }
.subtitle { margin: 0; color: var(--muted); line-height: var(--leading-normal); font-size: var(--text-sm); max-width: 760px; }
.topbar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex: 0 0 auto;
  padding-top: 2px;
}
.header-create-action {
  min-height: 30px;
  border-color: #fdba74;
  background: #fff7ed;
  color: #9a3412;
  border-radius: 8px;
  padding: 5px 10px;
  font-weight: var(--weight-medium);
  white-space: nowrap;
  box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
}
.header-create-action:hover {
  background: #ffedd5;
  border-color: #fb923c;
}
.panel {
  border-radius: var(--radius);
  padding: 12px;
}
.stack { display: grid; gap: 10px; }
.row { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.between { justify-content: space-between; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.form-block {
  display: grid;
  gap: 8px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--soft-line);
}
.form-block-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.form-step-label {
  flex: 0 0 auto;
  padding: 3px 8px;
  border-radius: 999px;
  background: #eef1f5;
  color: #586174;
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
}
.form-disclosure {
  border-top: 1px solid var(--soft-line);
  padding-top: 10px;
}
.form-disclosure summary,
.disclosure-panel > summary {
  cursor: pointer;
  color: var(--text-strong);
  font-weight: var(--weight-semibold);
}
.form-disclosure summary:focus-visible,
.disclosure-panel > summary:focus-visible {
  outline: 3px solid var(--accent-soft);
  outline-offset: 3px;
  border-radius: 6px;
}
.disclosure-content { margin-top: 10px; }
.form-block:last-of-type { border-bottom: 0; padding-bottom: 0; }
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-bottom: 10px; }
.metric-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 8px 10px;
  display: grid;
  gap: 4px;
  color: #475467;
}
.metric-card span { font-size: var(--text-xs); line-height: var(--leading-snug); color: #667085; }
.metric-card strong { color: var(--text-strong); font-size: var(--text-xl); line-height: 1.05; font-weight: var(--weight-bold); }
.metric-card.warn { border-color: #fed7aa; background: #fffaf5; }
.metric-card.ok { border-color: #bbf7d0; background: #f7fef9; }
.metric-card.bad { border-color: #fecaca; background: #fffafa; }
.status-card-sent { border-color: #bae6fd; background: #f0f9ff; }
.status-card-viewed { border-color: #fed7aa; background: #fffaf5; }
.status-card-signed { border-color: #ddd6fe; background: #faf8ff; }
.status-card-approved { border-color: #bbf7d0; background: #f7fef9; }
.table-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.section-heading {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.toolbar-filters {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  flex-wrap: nowrap;
  justify-content: flex-end;
}
.toolbar-filter,
.toolbar-search {
  display: grid;
  gap: 6px;
}
.toolbar-label {
  color: #586174;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-snug);
}
.toolbar-filter select {
  width: 180px;
  min-width: 180px;
}
.toolbar-search input {
  width: 260px;
  min-width: 260px;
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
table { width: 100%; border-collapse: separate; border-spacing: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
th, td { border-bottom: 1px solid var(--soft-line); padding: 9px 10px; text-align: left; vertical-align: middle; font-size: var(--text-sm); line-height: var(--leading-snug); }
th { background: #fbfcfd; font-weight: var(--weight-semibold); color: #586174; font-size: var(--text-xs); letter-spacing: .02em; text-transform: uppercase; }
tbody tr:hover { background: #fffaf5; }
tr:last-child td { border-bottom: 0; }
.clickable-row,
.clickable-card {
  cursor: pointer;
}
.clickable-row:focus-visible,
.clickable-card:focus-visible {
  outline: 3px solid var(--accent-soft);
  outline-offset: 2px;
}
.clickable-row:hover td {
  background: #fffaf5;
}
.clickable-card:hover {
  border-color: #fdba74;
  background: #fffaf5;
}
.small { font-size: var(--text-xs); color: var(--muted); line-height: var(--leading-snug); }
.badge, .status-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 2px 7px;
  font-size: 10px;
  font-weight: var(--weight-semibold);
  line-height: 1.1;
  letter-spacing: .02em;
  white-space: nowrap;
}
.badge { background: #eef1f5; color: #414b5a; }
.status-pill { background: #eef1f5; color: #414b5a; }
.status-signed_pending_verification, .status-documents_pending_signature, .status-identity_evidence_pending { background: #fff2cc; color: #8a4b00; }
.status-verification_approved { background: #dcfce7; color: #166534; }
.status-verification_rejected, .status-changes_requested { background: #fee2e2; color: #991b1b; }
.document-status-sent { background: #e0f2fe; color: #075985; }
.document-status-viewed { background: #fff2cc; color: #8a4b00; }
.document-status-signed { background: #ede9fe; color: #5b21b6; }
.document-status-approved { background: #dcfce7; color: #166534; }
.admission-allowed { background: #dcfce7; color: #166534; }
.admission-pending_company_verification { background: #fff2cc; color: #8a4b00; }
.admission-blocked { background: #fee2e2; color: #991b1b; }
.admission-not_allowed { background: #eef1f5; color: #414b5a; }
.flash-stack { display: grid; gap: 4px; margin-bottom: 10px; }
.segmented {
  display: inline-flex;
  gap: 4px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}
.segmented a {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 5px 10px;
  border-radius: 8px;
  color: #4b5565;
  font-weight: var(--weight-medium);
  font-size: var(--text-sm);
  line-height: var(--leading-tight);
}
.segmented a.active {
  background: #fff7ed;
  color: #9a3412;
}
.error, .success, .warning { border-radius: 6px; padding: 6px 8px; font-size: var(--text-sm); line-height: var(--leading-normal); }
.error { background: #fee2e2; color: #991b1b; }
.success { background: #dcfce7; color: #166534; }
.warning { background: #fef3c7; color: #92400e; }
.detail-grid { display: grid; grid-template-columns: minmax(0, 1fr) 292px; gap: 10px; align-items: start; }
.sticky-aside { position: sticky; top: 16px; }
.workflow-summary {
  display: grid;
  grid-template-columns: minmax(300px, 1.5fr) minmax(150px, .7fr) minmax(150px, .7fr) minmax(190px, .8fr);
  gap: 1px;
  margin-bottom: 10px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--line);
}
.workflow-summary > div {
  min-width: 0;
  padding: 12px;
  background: rgba(255, 255, 255, .92);
}
.workflow-summary-main,
.workflow-summary-item,
.workflow-summary-progress { display: grid; align-content: center; gap: 4px; }
.workflow-summary-main strong { font-size: var(--text-lg); }
.workflow-summary-main p { color: var(--muted); font-size: var(--text-sm); }
.workflow-kicker,
.workflow-summary-item > span,
.workflow-summary-progress span { color: var(--muted); font-size: var(--text-xs); font-weight: var(--weight-medium); }
.workflow-summary-item strong { font-size: var(--text-sm); }
.progress-track { height: 6px; overflow: hidden; border-radius: 999px; background: #e8ecf2; }
.progress-track span { display: block; height: 100%; border-radius: inherit; background: var(--accent-2); }
.admission-state-allowed { color: #166534; }
.admission-state-pending { color: #8a4b00; }
.admission-state-blocked { color: #991b1b; }
.admission-state-not-allowed { color: #475467; }
.page-anchor-nav {
  position: sticky;
  top: 0;
  z-index: 12;
  display: flex;
  gap: 4px;
  width: fit-content;
  margin-bottom: 10px;
  padding: 4px;
  border: 1px solid rgba(255,255,255,.7);
  border-radius: 10px;
  background: rgba(255,255,255,.82);
  box-shadow: 0 8px 20px rgba(15,23,42,.07);
  backdrop-filter: blur(18px);
}
.page-anchor-nav a { padding: 5px 9px; border-radius: 7px; color: #475467; font-size: var(--text-sm); font-weight: var(--weight-medium); }
.page-anchor-nav a:hover { background: #fff7ed; color: #9a3412; }
.disclosure-panel { padding: 0; }
.disclosure-panel > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  list-style: none;
}
.disclosure-panel > summary::-webkit-details-marker { display: none; }
.disclosure-panel > summary::after { content: "+"; color: var(--muted); font-size: 18px; font-weight: 400; }
.disclosure-panel[open] > summary::after { content: "−"; }
.disclosure-panel[open] > summary { border-bottom: 1px solid var(--soft-line); }
.disclosure-panel > :not(summary) { margin: 12px; }
.summary-meta { margin-left: auto; color: var(--muted); font-size: var(--text-xs); font-weight: var(--weight-medium); }
.next-action-card { display: grid; gap: 5px; padding: 10px; border: 1px solid var(--line); border-radius: 8px; background: #fbfcfd; }
.next-action-card > span { color: var(--muted); font-size: var(--text-xs); font-weight: var(--weight-semibold); text-transform: uppercase; letter-spacing: .04em; }
.next-action-card p { font-size: var(--text-sm); }
.next-action-warning { border-color: #fed7aa; background: #fffaf5; }
.next-action-urgent { border-color: #fecaca; background: #fffafa; }
.next-action-success { border-color: #bbf7d0; background: #f7fef9; }
.next-action-danger { border-color: #fecaca; background: #fff5f5; }
.audit-scroll { max-height: min(58vh, 560px); overflow-y: auto; padding-right: 2px; }
.table-next-action { display: block; max-width: 240px; color: #344054; font-size: var(--text-sm); line-height: var(--leading-snug); }
.workflow-alert { display: grid; gap: 3px; margin-bottom: 10px; border-radius: 8px; padding: 10px 12px; font-size: var(--text-sm); }
.form-footer-between { justify-content: space-between; }
.status-summary {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #586174;
  font-size: var(--text-md);
  line-height: var(--leading-normal);
}
.audit-list { display: grid; gap: 1px; }
.document-card, .file-item, .audit-item {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 8px;
}
.document-title { font-size: var(--text-md); font-weight: var(--weight-semibold); margin-bottom: 3px; line-height: var(--leading-tight); }
.document-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; color: #667085; font-size: var(--text-xs); font-weight: var(--weight-medium); margin-top: 4px; line-height: var(--leading-snug); }
.document-preview {
  margin: 8px 0 0;
  padding: 10px;
  border: 1px solid #eef1f5;
  border-radius: 8px;
  background: #fcfcfd;
  color: #344054;
  white-space: pre-wrap;
  line-height: var(--leading-relaxed);
  font-family: inherit;
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
  max-height: 460px;
  overflow: auto;
}
.pdf-frame {
  width: 100%;
  min-height: 500px;
  margin-top: 8px;
  border: 1px solid #eef1f5;
  border-radius: 8px;
  background: #f8fafc;
}
.template-pdf-frame {
  min-height: 480px;
}
.public-pdf-frame {
  min-height: 400px;
}
.hash-value {
  display: inline-block;
  max-width: 100%;
  min-width: 0;
  color: #475467;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.45;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.document-detail-grid h2 {
  font-size: 16px;
  font-weight: var(--weight-semibold);
}
.document-detail-grid .data-list dd a {
  font-weight: 600;
}
.document-detail-grid .document-card,
.document-detail-grid .audit-item {
  background: #fff;
  border-color: #eef1f5;
}
.document-detail-grid .document-title {
  color: #344054;
  font-weight: 600;
}
.document-detail-grid .document-meta {
  color: #667085;
  font-weight: 400;
}
.document-detail-grid .document-preview {
  color: #475467;
  font-size: 13px;
  line-height: 1.62;
  max-height: 460px;
}
.document-detail-grid .audit-item strong {
  color: #344054;
  font-size: var(--text-md);
  font-weight: var(--weight-medium);
}
.document-detail-grid .hash-value {
  font-weight: 500;
}
.template-picker {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.template-option {
  position: relative;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px;
  color: var(--text);
}
.template-option:has(input:checked) {
  border-color: #fdba74;
  background: #fffaf5;
}
.template-option input {
  width: 18px;
  height: 18px;
  min-height: 18px;
  margin: 2px 0 0;
  accent-color: var(--accent);
}
.template-option-body {
  display: grid;
  gap: 5px;
  min-width: 0;
}
.template-option-title {
  color: #1f2937;
  font-size: var(--text-md);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-tight);
}
.template-option-meta,
.template-option-note {
  color: #667085;
  font-size: var(--text-sm);
  font-weight: var(--weight-regular);
  line-height: var(--leading-normal);
}
.send-documents-form {
  display: grid;
  gap: 6px;
  padding: 8px;
  border: 1px solid #fed7aa;
  border-radius: var(--radius);
}
.send-documents-form .soft-action {
  min-height: 26px;
  padding: 4px 8px;
  font-size: 12px;
}
.choice-grid {
  display: grid;
  gap: 8px;
}
.choice-card {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid #d9dee7;
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  transition: border-color .18s ease, box-shadow .18s ease, background-color .18s ease;
}
.choice-card:has(input:checked) {
  border-color: #ffb36b;
  background: #fff7ed;
  box-shadow: 0 0 0 3px rgba(255, 179, 107, .18);
}
.choice-card span {
  color: #1f2937;
  font-size: var(--text-md);
  font-weight: var(--weight-medium);
  line-height: var(--leading-normal);
}
.compact-user-form {
  gap: 8px;
}
.compact-choice-grid {
  gap: 6px;
}
.compact-choice-card {
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 8px;
  padding: 6px 12px;
  min-height: 52px;
  border-radius: 12px;
}
.compact-choice-card span {
  font-size: var(--text-sm);
  line-height: 1.3;
}
.compact-submit {
  min-height: 0;
  padding: 7px 12px;
  border-radius: 12px;
  font-size: var(--text-md);
}
.file-picker {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid #d9dee7;
  border-radius: 12px;
  background: #fff;
}
.file-picker input[type="file"] {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.file-picker-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 16px;
  border: 1px solid #cfd6e2;
  border-radius: 10px;
  background: #f8fafc;
  color: #1f2937;
  font-size: var(--text-md);
  font-weight: var(--weight-semibold);
  line-height: 1;
  cursor: pointer;
}
.file-picker-button:hover {
  background: #eef2f7;
}
.file-picker-name {
  min-width: 0;
  color: #667085;
  font-size: var(--text-md);
  line-height: var(--leading-normal);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.send-documents-form h3 {
  margin: 0;
  color: #344054;
  font-size: var(--text-md);
  line-height: var(--leading-snug);
  font-weight: var(--weight-semibold);
}
.compact-template-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 5px;
}
.compact-template-option {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr);
  gap: 7px;
  align-items: center;
  padding: 5px 7px;
  border: 1px solid #f1d8c2;
  border-radius: 8px;
  font-size: var(--text-sm);
  font-weight: var(--weight-regular);
}
.compact-template-option input {
  align-self: center;
}
.compact-template-option span {
  display: block;
  min-width: 0;
}
.compact-template-option strong {
  display: block;
  color: #344054;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-tight);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.compact-template-option small {
  display: none;
}
.compact-consent span {
  color: #667085;
  font-size: var(--text-xs);
  font-weight: var(--weight-regular);
  line-height: var(--leading-snug);
}
.compact-consent {
  grid-template-columns: 16px minmax(0, 1fr);
  gap: 7px;
  align-items: center;
  font-weight: 500;
}
.app-dialog {
  width: min(1180px, calc(100vw - 40px));
  max-width: none;
  padding: 0;
  border: 0;
  background: transparent;
}
.app-dialog::backdrop {
  background: rgba(15, 23, 42, .42);
  backdrop-filter: blur(3px);
}
.app-dialog-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 28px 60px rgba(15, 23, 42, .18);
}
.legal-entity-dialog-card {
  width: min(640px, calc(100vw - 40px));
  margin: 0 auto;
}
.app-dialog-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}
.icon-button {
  min-width: 32px;
  min-height: 32px;
  padding: 0;
  border-radius: 999px;
  font-size: 20px;
  line-height: 1;
}
.send-documents-modal {
  display: grid;
  gap: 12px;
}
.send-documents-layout {
  display: grid;
  grid-template-columns: minmax(320px, 420px) minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}
.modal-subpanel {
  padding: 10px;
}
.modal-subpanel h3 {
  margin: 0;
  font-size: var(--text-md);
  color: #344054;
  line-height: var(--leading-snug);
  font-weight: var(--weight-semibold);
}
.single-column {
  grid-template-columns: 1fr;
}
.preview-template-option {
  grid-template-columns: 18px minmax(0, 1fr) auto;
  align-items: center;
}
.preview-template-option .button {
  min-width: 104px;
}
.document-multiselect {
  position: relative;
  display: grid;
  gap: 6px;
}
.document-multiselect-trigger {
  width: 100%;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  color: #344054;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
  transition-property: border-color, box-shadow, background-color;
  transition-duration: 160ms;
}
.document-multiselect-trigger:hover {
  border-color: #d5d9e1;
  background: #fcfcfd;
}
.document-multiselect-trigger:focus-visible {
  outline: 3px solid rgba(242, 106, 0, .18);
  outline-offset: 2px;
  border-color: #f26a00;
}
.document-multiselect-trigger-copy {
  display: grid;
  gap: 1px;
  min-width: 0;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-snug);
}
.document-multiselect-summary {
  color: #667085;
  font-size: var(--text-xs);
  font-weight: var(--weight-regular);
}
.document-multiselect-chevron {
  width: 9px;
  height: 9px;
  flex: 0 0 auto;
  border-right: 2px solid #667085;
  border-bottom: 2px solid #667085;
  transform: rotate(45deg) translate(-2px, -2px);
  transition-property: transform;
  transition-duration: 160ms;
}
.document-multiselect-trigger[aria-expanded="true"] .document-multiselect-chevron {
  transform: rotate(225deg) translate(-1px, -1px);
}
.document-multiselect-panel {
  display: grid;
  gap: 6px;
  padding: 8px;
  border: 1px solid #e2e6ec;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, .12);
}
.document-multiselect-panel[hidden] {
  display: none;
}
.document-multiselect-search {
  min-height: 40px;
}
.document-multiselect-list {
  display: grid;
  grid-auto-rows: max-content;
  gap: 8px;
  align-content: start;
  max-height: 280px;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.document-multiselect-option {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  min-height: 52px;
  padding: 10px;
  border-radius: 9px;
}
.document-multiselect-option:hover,
.document-multiselect-option:has(input:checked) {
  background: #fff7ed;
}
.document-multiselect-option[hidden] {
  display: none;
}
.document-multiselect-label {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 9px;
  align-items: start;
  min-width: 0;
  cursor: pointer;
}
.document-multiselect-label input {
  width: 18px;
  height: 18px;
  min-height: 18px;
  margin: 2px 0 0;
  accent-color: var(--accent);
}
.document-multiselect-label .template-option-body { min-width: 0; }
.document-multiselect-label .template-option-title,
.document-multiselect-label .template-option-meta { display: block; overflow-wrap: anywhere; }
.document-preview-button {
  align-self: center;
  min-width: 104px;
  min-height: 40px;
}
.document-picker-empty {
  padding: 12px 8px;
  color: #667085;
  font-size: var(--text-sm);
  text-align: center;
}
.preview-panel {}
.send-preview-frame {
  min-height: 720px;
  margin-top: 0;
}
.template-editor {
  align-items: start;
}
.template-autosave-note {
  color: #667085;
  font-size: var(--text-xs);
  line-height: var(--leading-snug);
}
.template-body-editor {
  min-height: 420px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: var(--text-md);
  line-height: var(--leading-relaxed);
}
.template-body-editor[readonly] {
  background: #fbfcfd;
  color: #475467;
}
.mapping-table {
  display: grid;
  gap: 6px;
}
.mapping-row {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(220px, 1.2fr) auto;
  gap: 6px;
  align-items: center;
}
.custom-field-row {
  grid-template-columns: minmax(150px, 1fr) minmax(180px, 1.1fr) 140px auto;
}
.mapping-row-head {
  color: #667085;
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  text-transform: uppercase;
  letter-spacing: .03em;
}
.mapping-row-head span:last-child {
  grid-column: span 2;
}
.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.tag-button {
  min-height: 24px;
  border-color: #e6e9ef;
  background: #fff;
  color: #475467;
  padding: 4px 8px;
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  cursor: default;
}
.template-preview {
  max-height: 520px;
}
.kanban-board {
  display: grid;
  grid-template-columns: repeat(4, minmax(220px, 1fr));
  gap: 8px;
  align-items: start;
  overflow-x: auto;
  padding-bottom: 4px;
}
.kanban-column {
  min-height: 300px;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 8px;
}
.kanban-column header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.kanban-list {
  display: grid;
  align-content: start;
  gap: 6px;
}
.kanban-card {
  display: grid;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  padding: 8px;
}
.client-filter-empty[hidden] {
  display: none !important;
}
.compact-empty { padding: 8px; }
.settings-help { padding: 8px 10px; border: 1px solid #fed7aa; border-radius: 8px; background: #fff7ed; color: #475467; font-size: var(--text-sm); line-height: var(--leading-normal); }
.settings-help strong { display: block; margin-bottom: 6px; color: #1f2937; font-weight: var(--weight-semibold); }
.empty { padding: 12px; border: 1px dashed var(--line); border-radius: var(--radius); color: var(--muted); text-align: center; background: #fff; font-size: var(--text-sm); line-height: var(--leading-normal); }

.login { max-width: 380px; margin: 40px auto; padding: 0 16px; }
.login-logo { width: 120px; height: auto; justify-self: center; }
.public-shell { max-width: 820px; margin: 0 auto; padding: 14px 14px 26px; }
.public-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.public-header img { width: 116px; height: auto; display: block; object-fit: contain; }
.public-hero { margin-bottom: 12px; }
.public-hero h1 { margin: 0; color: var(--text-strong); font-size: clamp(24px, 3.7vw, 32px); line-height: 1.04; letter-spacing: -0.02em; font-weight: var(--weight-bold); }
.public-hero p:not(.eyebrow) { max-width: 620px; margin: 6px 0 0; color: #667085; font-size: var(--text-md); line-height: var(--leading-normal); }
.public-process-status { background: #fff7ed; color: #9a3412; }
.telegram-steps { margin: 12px 0; padding-left: 22px; color: var(--text); }
.telegram-steps li + li { margin-top: 8px; }
.telegram-restart-form { margin-top: 12px; }
.confirmation-method-button { min-width: 100%; }
.telegram-waiting-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
}
.telegram-waiting-actions form {
  margin: 0;
}
.confirmation-channel-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}
.confirmation-channel-options form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbfcfd;
}
.confirmation-channel-options button { width: 100%; }
.confirmation-channel-options .section-note { margin: 0; }
.manual-document-upload { display: grid; gap: 8px; padding-top: 4px; }
.manual-document-upload > label { display: grid; gap: 3px; color: #344054; font-size: var(--text-sm); }
.manual-document-upload > label span { color: #667085; font-size: var(--text-xs); line-height: var(--leading-normal); }
.manual-document-list { display: grid; gap: 7px; }
.manual-document-list:empty { display: none; }
.manual-document-list label { display: grid; grid-template-columns: minmax(0, 1fr) minmax(160px, .7fr); gap: 8px; align-items: center; padding: 8px 10px; border: 1px solid #e4e7ec; border-radius: 8px; background: #fff; color: #475467; font-size: var(--text-xs); }
.manual-document-list span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.confirmation-channel-switch {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  margin-top: 18px;
}
.confirmation-channel-switch form { margin: 0; }
.telegram-refresh-button {
  min-height: 40px;
  padding: 8px 12px;
  color: #475467;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
}
.telegram-refresh-button:hover {
  color: #344054;
}
.button-link { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
.locked-data { margin-bottom: 16px; }
.public-data-edit-form { margin-top: 16px; }
.public-data-actions { margin-top: 18px; }
.public-custom-fields { margin-top: 14px; }
.support-disclosure { margin-top: 18px; padding: 0; border-radius: 14px; background: rgba(255, 255, 255, .66); box-shadow: inset 0 0 0 1px #e6e9ef, 0 4px 14px rgba(16, 24, 40, .04); overflow: hidden; }
.support-disclosure summary { min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 14px 16px; color: #344054; cursor: pointer; list-style: none; transition-property: background-color; transition-duration: 160ms; }
.support-disclosure summary::-webkit-details-marker { display: none; }
.support-disclosure summary:hover { background: #f8fafc; }
.support-disclosure summary:focus-visible { outline: 3px solid rgba(234, 88, 12, .28); outline-offset: -3px; }
.support-summary-copy { display: grid; gap: 3px; min-width: 0; }
.support-summary-copy strong { color: #344054; font-size: var(--text-md); }
.support-summary-copy > span { color: #667085; font-size: var(--text-xs); font-weight: var(--weight-regular); }
.support-summary-action { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 8px; color: #b54708; font-size: var(--text-sm); font-weight: var(--weight-semibold); }
.support-summary-action svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition-property: transform; transition-duration: 160ms; }
.support-close-label { display: none; }
.support-disclosure[open] .support-open-label { display: none; }
.support-disclosure[open] .support-close-label { display: inline; }
.support-disclosure[open] .support-summary-action svg { transform: rotate(180deg); }
.support-disclosure[open] summary { background: #f8fafc; }
.support-disclosure-copy { display: grid; gap: 4px; margin-top: 8px; }
.support-disclosure > :not(summary) { margin-right: 16px; margin-left: 16px; }
.support-disclosure > form:last-child { margin-bottom: 16px; }
.support-disclosure-copy h3 { margin: 0; color: var(--text-strong); font-size: var(--text-md); }
.support-disclosure-copy p { color: #667085; font-size: var(--text-sm); text-wrap: pretty; }
.manager-help-form { display: grid; gap: 8px; margin-top: 12px; }
.manager-help-form textarea { min-height: 92px; resize: vertical; }
.manager-help-form .form-footer button { min-height: 40px; }
.document-open-link { width: fit-content; margin-top: 10px; }
.stepper { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 4px; margin: 10px 0; }
.stepper > :is(a, span) { min-height: 32px; display: flex; align-items: center; justify-content: center; border-radius: 999px; background: #eef1f5; color: #596579; font-size: 10px; font-weight: var(--weight-semibold); letter-spacing: .02em; text-decoration: none; }
.stepper > a { transition-property: background-color, color, box-shadow; transition-duration: 160ms; }
.stepper > a:hover { background: #e7ebf1; color: #344054; }
.stepper > .active { background: #fff7ed; color: #9a3412; }
.stepper > .complete { background: #ecfdf3; color: #166534; }
.stepper > .selected { box-shadow: inset 0 0 0 2px rgba(242, 106, 0, .34); }
.stepper > :is(a, span) > span { min-height: auto; margin-right: 3px; padding: 0; background: transparent; color: inherit; font-size: inherit; }
.form-section {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(16, 24, 40, .035);
}
.form-section.single { margin-top: 6px; }
.form-section.no-number { grid-template-columns: 1fr; }
.section-number { width: 28px; height: 28px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; background: #fff7ed; color: #c2410c; font-weight: 900; font-size: 12px; }
.section-content { display: grid; gap: 8px; }
.section-note { margin: 0; color: #667085; line-height: 1.3; font-size: 12px; }
.legal-step-card .section-content { gap: 16px; }
.pep-step-card { padding-top: 18px; padding-bottom: 20px; }
.pep-step-card .section-content { gap: 22px; max-width: 820px; }
.pep-step-card .legal-step-heading { gap: 8px; max-width: 620px; }
.pep-step-card .legal-step-heading p { font-size: var(--text-sm); }
.pep-flow { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.pep-flow li { position: relative; display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 14px; min-height: 76px; padding: 0 0 20px; }
.pep-flow li:last-child { min-height: auto; padding-bottom: 0; }
.pep-flow li:not(:last-child)::after { content: ""; position: absolute; top: 40px; bottom: 4px; left: 19px; width: 2px; border-radius: 2px; background: #e7eaf0; }
.pep-flow-number { position: relative; z-index: 1; width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; background: #fff7ed; color: #c2410c; box-shadow: inset 0 0 0 1px #fed7aa; font-size: var(--text-sm); font-weight: var(--weight-bold); font-variant-numeric: tabular-nums; }
.pep-flow li > div { display: grid; align-content: start; gap: 4px; padding-top: 2px; }
.pep-flow strong { color: #1d2939; font-size: var(--text-md); }
.pep-flow li > div > span { color: #667085; font-size: var(--text-sm); line-height: var(--leading-normal); text-wrap: pretty; }
.pep-code-warning { margin: 0; padding: 13px 15px; border-radius: 12px; background: #fff7ed; color: #7c2d12; font-size: var(--text-sm); line-height: var(--leading-normal); }
.pep-rules { display: grid; gap: 8px; padding: 15px; border-radius: 14px; background: #f8fafc; box-shadow: inset 0 0 0 1px #e6e9ef; }
.pep-rules h3 { margin: 0; color: #344054; font-size: var(--text-sm); }
.pep-rules .legal-text { padding: 0; }
.pep-consent-state { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 4px; }
.pep-consent-state > div { display: grid; gap: 3px; }
.pep-consent-state strong { color: #166534; }
.pep-consent-state span { color: #667085; font-size: var(--text-xs); }
.pep-consent-state form { margin: 0; }
.legal-step-heading { display: grid; gap: 6px; }
.legal-step-heading h2,
.evidence-guide h2 { margin: 0; color: var(--text-strong); text-wrap: balance; }
.legal-step-heading p,
.evidence-guide p { color: #667085; text-wrap: pretty; }
.legal-step-kicker { color: #c2410c; font-size: var(--text-xs); font-weight: var(--weight-bold); letter-spacing: .05em; text-transform: uppercase; }
.legal-facts-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.legal-facts-grid.two-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.legal-facts-grid article { display: grid; gap: 5px; padding: 12px; border-radius: 10px; background: #f8fafc; box-shadow: inset 0 0 0 1px #eef1f5; }
.legal-facts-grid strong { color: #344054; font-size: var(--text-sm); }
.legal-facts-grid span { color: #667085; font-size: var(--text-xs); line-height: var(--leading-normal); }
.legal-text-disclosure { border-radius: 10px; background: #fff; box-shadow: inset 0 0 0 1px #e6e9ef; overflow: hidden; }
.legal-text-disclosure summary { min-height: 44px; display: flex; align-items: center; padding: 10px 12px; color: #344054; cursor: pointer; font-weight: var(--weight-semibold); }
.legal-text-static { border-radius: 10px; background: #fff; box-shadow: inset 0 0 0 1px #e6e9ef; overflow: hidden; }
.legal-text-static h3 { margin: 0; padding: 12px; color: #344054; font-size: var(--text-sm); font-weight: var(--weight-semibold); }
.legal-text { padding: 0 12px 12px; color: #475467; font-size: var(--text-sm); line-height: var(--leading-relaxed); }
.legal-text p + p { margin-top: 8px; }
.legal-consent-form { display: grid; gap: 12px; }
.consent-state { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px; border-radius: 10px; }
.consent-state.success { background: #ecfdf3; box-shadow: inset 0 0 0 1px #c6eadc; }
.consent-state > div { display: grid; gap: 2px; }
.consent-state .consent-state-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.consent-state-actions form { margin: 0; }
.consent-state strong { color: #166534; }
.consent-state span { color: #3f6858; font-size: var(--text-xs); }
.danger-link { color: #b42318; }
.danger-link:hover { color: #912018; background: #fff1f0; }
.previous-step-return { width: fit-content; min-height: 40px; }
.evidence-upload-card .section-content { gap: 16px; }
.evidence-guide { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 20px; align-items: center; }
.evidence-guide-copy { display: grid; gap: 7px; }
.photo-requirements { display: grid; gap: 7px; margin: 6px 0 0; padding-left: 20px; color: #475467; font-size: var(--text-sm); }
.passport-photo-guide { margin: 0; padding: 10px; border-radius: 14px; background: #fffaf5; box-shadow: inset 0 0 0 1px #f1d8c2; }
.passport-photo-guide svg { display: block; width: 100%; height: auto; }
.passport-photo-guide figcaption { margin-top: 4px; color: #667085; font-size: var(--text-xs); text-align: center; }
.upload-fields { display: grid; gap: 8px; padding: 14px; border-radius: 12px; background: #f8fafc; }
.replacement-note { display: grid; gap: 3px; padding: 10px 12px; border-radius: 9px; background: #fff7ed; box-shadow: inset 0 0 0 1px #f1d8c2; }
.replacement-note strong { color: #9a3412; font-size: var(--text-sm); }
.replacement-note span { color: #667085; font-size: var(--text-xs); line-height: var(--leading-normal); }
.identity-photo-card .section-content { gap: 18px; }
.identity-photo-intro { display: grid; gap: 6px; max-width: 760px; }
.identity-photo-intro h2 { margin: 0; color: var(--text-strong); text-wrap: balance; }
.identity-photo-intro p { color: #667085; text-wrap: pretty; }
.identity-photo-guide { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 22px; align-items: center; padding: 18px; border-radius: 18px; background: linear-gradient(135deg, #f8fafc, #fffaf5); box-shadow: inset 0 0 0 1px rgba(71, 84, 103, .08); }
.identity-photo-requirements { display: grid; gap: 8px; }
.identity-photo-requirements h3 { margin: 0; color: #344054; font-size: var(--text-md); }
.identity-photo-requirements .photo-requirements { margin-top: 4px; }
.identity-photo-requirements .photo-requirements li::marker { color: #ea580c; }
.identity-photo-form { display: grid; gap: 14px; }
.photo-dropzone { min-height: 150px; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 5px; padding: 20px; border: 2px dashed #f0b27f; border-radius: 16px; background: #fffaf5; color: #344054; text-align: center; cursor: pointer; transition-property: background-color, border-color, box-shadow; transition-duration: 160ms; }
.photo-dropzone:hover { border-color: #ea580c; background: #fff7ed; }
.photo-dropzone:focus-within { box-shadow: 0 0 0 4px rgba(234, 88, 12, .14); }
.photo-dropzone-icon { width: 42px; height: 42px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; background: #ffedd5; color: #c2410c; font-size: 28px; font-weight: 400; line-height: 1; }
.photo-dropzone strong { font-size: var(--text-md); }
.photo-dropzone span:last-child { color: #667085; font-size: var(--text-xs); }
.photo-dropzone-copy { display: grid; gap: 4px; min-width: 0; }
.photo-dropzone-copy strong { overflow: hidden; max-width: 100%; text-overflow: ellipsis; white-space: nowrap; }
.selected-photo-preview { width: 112px; height: 84px; object-fit: cover; border-radius: 10px; outline: 1px solid rgba(0, 0, 0, .1); }
.selected-photo-preview[hidden] { display: none; }
.photo-dropzone.has-preview { min-height: 112px; flex-direction: row; text-align: left; }
.photo-dropzone.has-preview .photo-dropzone-icon { display: none; }
.visually-hidden-file { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.identity-photo-form:has(.visually-hidden-file:focus-visible) .photo-dropzone,
.identity-photo-form:has(.visually-hidden-file:focus-visible) .replace-photo-control { outline: 3px solid rgba(234, 88, 12, .28); outline-offset: 3px; }
.current-photo { display: grid; grid-template-columns: 112px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 12px; border-radius: 16px; background: #f8fafc; box-shadow: inset 0 0 0 1px #e6e9ef; }
.current-photo img { width: 112px; height: 84px; display: block; object-fit: cover; border-radius: 10px; outline: 1px solid rgba(0, 0, 0, .1); }
.current-photo-copy { display: grid; gap: 3px; min-width: 0; }
.current-photo-copy strong { color: #344054; }
.current-photo-copy span { overflow: hidden; color: #667085; font-size: var(--text-xs); text-overflow: ellipsis; white-space: nowrap; }
.replace-photo-control { width: fit-content; min-height: 40px; display: inline-flex; align-items: center; margin-top: 3px; color: #b54708; font-size: var(--text-sm); font-weight: var(--weight-semibold); cursor: pointer; }
.replace-photo-control:hover { color: #9a3412; }
.current-photo-delete { min-height: 40px; padding: 8px 10px; }
.photo-consent-block { display: grid; gap: 10px; padding: 16px; border-radius: 16px; background: #fff; box-shadow: inset 0 0 0 1px #e6e9ef; }
.photo-consent-block h3 { margin: 0; color: #344054; font-size: var(--text-sm); }
.photo-consent-block .legal-text { padding: 0; }
.accepted-consent-line { width: fit-content; display: inline-flex; align-items: center; gap: 7px; padding: 8px 11px; border-radius: 999px; background: #ecfdf3; color: #166534; font-size: var(--text-sm); font-weight: var(--weight-semibold); }
.identity-photo-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.identity-photo-actions .primary { min-width: 160px; }
.identity-photo-actions button:active,
.photo-dropzone:active { scale: .96; }
.field-validation-error { margin: 6px 0 0; padding: 9px 11px; border-radius: 8px; background: #fff1f0; color: #b42318; box-shadow: inset 0 0 0 1px #f5c2bd; font-size: var(--text-sm); font-weight: var(--weight-medium); line-height: var(--leading-normal); }
.final-status-card { padding-top: 18px; padding-bottom: 18px; }
.final-status-card .section-content { gap: 7px; }
.final-status-heading { display: grid; gap: 4px; }
.final-status-heading h2 { margin: 0; color: #1d2939; text-wrap: balance; }
.signed-documents-section { display: grid; gap: 14px; margin-top: 14px; padding: 18px; border-radius: 16px; background: rgba(255, 255, 255, .78); box-shadow: 0 10px 28px rgba(16, 24, 40, .07), inset 0 0 0 1px rgba(71, 84, 103, .08); }
.signed-section-heading { display: grid; gap: 4px; }
.signed-section-heading h2 { margin: 0; color: #1d2939; font-size: var(--text-lg); }
.signed-section-heading p { color: #667085; font-size: var(--text-sm); }
.signed-document-list { display: grid; gap: 10px; }
.signed-document-card { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px 20px; align-items: center; padding: 14px; border-radius: 12px; background: #f8fafc; box-shadow: inset 0 0 0 1px #e6e9ef; }
.signed-document-main { display: flex; align-items: center; gap: 11px; }
.signed-document-mark { width: 36px; height: 36px; display: inline-flex; flex: 0 0 auto; align-items: center; justify-content: center; border-radius: 50%; background: #ecfdf3; color: #16744f; font-weight: var(--weight-bold); }
.signed-document-main h3 { margin: 0; color: #1d2939; font-size: var(--text-md); }
.signed-document-main p { margin-top: 3px; color: #667085; font-size: var(--text-xs); }
.signature-facts { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px 24px; margin: 0; padding-left: 47px; }
.signature-facts div { display: flex; gap: 6px; }
.signature-facts dt { color: #667085; font-size: var(--text-xs); }
.signature-facts dd { margin: 0; color: #344054; font-size: var(--text-xs); font-weight: var(--weight-semibold); font-variant-numeric: tabular-nums; }
.signed-document-link { min-height: 40px; padding: 8px 12px; }
.company-contacts-box { min-height: 112px; display: grid; align-content: start; margin-top: 14px; padding: 18px; border-radius: 16px; background: rgba(255, 255, 255, .58); box-shadow: inset 0 0 0 1px #e6e9ef; }
.company-contacts-box h2 { margin: 0; color: #344054; font-size: var(--text-lg); }
[aria-invalid="true"] { border-color: #d92d20 !important; box-shadow: 0 0 0 3px rgba(217, 45, 32, .10) !important; }
.resend-section {
  align-items: center;
}
.resend-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
}
.resend-copy {
  display: grid;
  gap: 6px;
}
.resend-copy h2 {
  margin: 0;
}
.resend-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
}
.resend-actions .soft-action {
  min-width: 156px;
}
.consent-row { display: grid; grid-template-columns: 16px minmax(0, 1fr); gap: 10px; align-items: start; font-weight: 650; line-height: 1.45; }
.consent-row input { margin-top: 2px; }
.send-documents-form .compact-consent {
  align-items: start;
  gap: 7px;
  font-weight: 500;
  line-height: 1.25;
}
.send-documents-form .compact-consent input {
  margin-top: 0;
  align-self: start;
}
.document-choice small {
  display: block;
  margin-top: 4px;
  color: #667085;
  font-weight: var(--weight-regular);
  font-size: var(--text-xs);
  line-height: var(--leading-snug);
}
.form-footer { display: flex; justify-content: flex-end; align-items: center; padding-top: 2px; }
.data-list { display: grid; gap: 2px; margin: 0; }
.data-list div { display: grid; grid-template-columns: 128px minmax(0, 1fr); gap: 8px; min-width: 0; padding: 5px 0; border-bottom: 1px solid var(--soft-line); }
.data-list.dense { gap: 0; }
.data-list.dense div { grid-template-columns: 164px minmax(0, 1fr); }
.data-list dt { color: #667085; font-size: var(--text-xs); font-weight: var(--weight-medium); line-height: var(--leading-snug); }
.data-list dd { margin: 0; min-width: 0; color: #344054; font-size: var(--text-sm); font-weight: var(--weight-regular); line-height: var(--leading-normal); overflow-wrap: break-word; }
.split-actions { display: grid; grid-template-columns: 184px minmax(0, 1fr); gap: 8px; align-items: end; }
.issue-form { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px; align-items: end; }
.public-doc { max-height: 360px; overflow: auto; }
.public-doc-list { display: grid; gap: 12px; }
.public-document-card {
  padding: 14px;
  border: 0;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(16, 24, 40, .06), 0 8px 24px rgba(16, 24, 40, .06);
}
.public-document-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.public-document-header .document-title { margin: 0; text-wrap: balance; }
.public-document-actions { display: flex; align-items: center; flex: 0 0 auto; gap: 0; }
.document-text-action { min-height: 36px; display: inline-flex; align-items: center; padding: 5px 9px; border: 0; border-radius: 6px; background: transparent; box-shadow: none; font-family: inherit; font-size: var(--text-xs); font-weight: var(--weight-semibold); line-height: var(--leading-snug); text-decoration: none; cursor: pointer; transition-property: color, background-color; transition-duration: 160ms; }
.document-text-action.preview-action { color: #9a3412; }
.document-text-action.open-action { position: relative; margin-left: 7px; padding-left: 16px; color: #475467; }
.document-text-action.open-action::before { content: ""; position: absolute; left: 0; top: 8px; bottom: 8px; width: 1px; background: #d9dee7; }
.document-text-action:hover { background: #f8fafc; }
.document-text-action.preview-action:hover { color: #7c2d12; }
.document-text-action.open-action:hover { color: #1f2937; }
.document-text-action:focus-visible { outline: 3px solid rgba(242, 106, 0, .18); outline-offset: 1px; }
.public-document-card .document-preview {
  max-height: none;
  margin: 12px 0 0;
  padding: 0;
  overflow: visible;
  border: 0;
  background: transparent;
  white-space: normal;
}
.public-document-card .document-preview summary {
  min-height: 40px;
  display: flex;
  align-items: center;
  width: fit-content;
  padding: 8px 12px;
  border-radius: 8px;
  background: #fff7ed;
  color: #9a3412;
  box-shadow: inset 0 0 0 1px #f1d8c2;
  cursor: pointer;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
}
.public-document-card .public-pdf-frame { min-height: 520px; margin-top: 8px; }
.document-preview-panel { margin-top: 10px; }
.document-preview-panel[hidden] { display: none; }
.document-workflow-action { scroll-margin-top: 20px; }
.document-workflow-action {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  margin-top: 14px;
  padding: 16px;
  border-radius: 14px;
  background: #fff7ed;
  box-shadow: inset 0 0 0 1px rgba(234, 88, 12, .14), 0 8px 24px rgba(16, 24, 40, .06);
}
.document-workflow-action.signature-mode { grid-template-columns: 1fr; }
.document-workflow-copy { display: grid; gap: 4px; }
.document-workflow-copy h3 { margin: 0; color: var(--text-strong); text-wrap: balance; }
.document-workflow-copy p,
.document-workflow-footer p { margin: 0; color: #667085; font-size: var(--text-sm); line-height: var(--leading-normal); text-wrap: pretty; }
.document-workflow-action > button { min-height: 44px; }
.document-workflow-action .consent-row { grid-template-columns: 20px minmax(0, 1fr); gap: 12px; padding: 14px; border-radius: 10px; background: rgba(255, 255, 255, .72); font-weight: var(--weight-medium); }
.document-workflow-action .consent-row input { width: 18px; height: 18px; margin-top: 1px; }
.document-workflow-footer { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 18px; }
.document-workflow-footer button { min-height: 48px; line-height: 1.25; }
.document-workflow-footer button:active { transform: scale(.96); }
.compact-document-action { width: auto; min-width: 0; padding-inline: 18px; justify-self: end; white-space: nowrap; }
.document-confirmation-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 20px;
  margin-top: 14px;
  padding: 16px;
  border-radius: 14px;
  background: #fff7ed;
  box-shadow: inset 0 0 0 1px rgba(234, 88, 12, .12);
}
.document-confirmation-card h3,
.signature-action-card h3 { margin: 0; color: var(--text-strong); text-wrap: balance; }
.document-confirmation-card p,
.signature-action-heading p,
.signature-action-footer p { margin: 4px 0 0; color: #667085; font-size: var(--text-sm); line-height: var(--leading-normal); text-wrap: pretty; }
.document-confirmation-card button { min-height: 44px; }
.signature-action-card {
  display: grid;
  gap: 16px;
  margin-top: 14px;
  padding: 18px;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 2px 4px rgba(16, 24, 40, .06), 0 16px 40px rgba(16, 24, 40, .1);
}
.signature-step-label { color: #c2410c; font-size: var(--text-xs); font-weight: var(--weight-bold); letter-spacing: .04em; text-transform: uppercase; }
.signature-action-heading { display: grid; gap: 5px; }
.signature-action-card .consent-row {
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 12px;
  padding: 14px;
  border-radius: 10px;
  background: #f8fafc;
  font-weight: var(--weight-medium);
}
.signature-action-card .consent-row input { width: 18px; height: 18px; margin-top: 1px; }
.signature-action-footer { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, 360px); align-items: center; gap: 18px; }
.signature-action-footer button { min-height: 48px; line-height: 1.25; }
.signature-action-footer button:active { transform: scale(.96); }

:is(
  .sidebar,
  .panel,
  .metric-card,
  table,
  .document-card,
  .file-item,
  .audit-item,
  .template-option,
  .compact-template-option,
  .entity-switcher,
  .app-dialog-card,
  .kanban-column,
  .kanban-card,
  .verification-result,
  .settings-help,
  .empty,
  .form-section,
  .public-doc,
  .send-documents-form,
  .segmented
) {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background: var(--glass-fill);
  border-color: var(--glass-border);
  box-shadow: var(--glass-shadow);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
}

:is(.sidebar, .app-dialog-card, .form-section, .public-doc) {
  background: var(--glass-fill-strong);
  box-shadow: var(--glass-shadow-strong);
}

.sidebar {
  position: fixed;
}

:is(
  .sidebar,
  .panel,
  .metric-card,
  table,
  .document-card,
  .file-item,
  .audit-item,
  .template-option,
  .compact-template-option,
  .entity-switcher,
  .app-dialog-card,
  .kanban-column,
  .kanban-card,
  .verification-result,
  .settings-help,
  .empty,
  .form-section,
  .public-doc,
  .send-documents-form,
  .segmented
)::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .55), rgba(255, 255, 255, .16) 38%, rgba(255, 255, 255, 0) 62%),
    radial-gradient(circle at top left, rgba(255, 255, 255, .46), transparent 34%);
  opacity: .92;
}

:is(
  .sidebar,
  .panel,
  .metric-card,
  .document-card,
  .file-item,
  .audit-item,
  .template-option,
  .compact-template-option,
  .entity-switcher,
  .app-dialog-card,
  .kanban-column,
  .kanban-card,
  .verification-result,
  .settings-help,
  .empty,
  .form-section,
  .public-doc,
  .send-documents-form,
  .segmented
) > * {
  position: relative;
  z-index: 1;
}

table thead,
table tbody,
table tr,
table th,
table td {
  position: relative;
  z-index: 1;
}

th {
  background: rgba(255, 255, 255, .30);
}

tbody tr:hover,
.clickable-row:hover td,
.clickable-card:hover {
  background: rgba(255, 255, 255, .24);
}

.button,
.soft-action,
.link-button,
.segmented a,
.icon-button {
  backdrop-filter: blur(18px) saturate(165%);
  -webkit-backdrop-filter: blur(18px) saturate(165%);
}

.button,
.soft-action,
.link-button,
.icon-button {
  background: linear-gradient(180deg, rgba(255, 255, 255, .62), rgba(255, 255, 255, .34));
  border-color: rgba(255, 255, 255, .58);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .68), 0 8px 18px rgba(15, 23, 42, .08);
}

.primary {
  background: linear-gradient(180deg, rgba(15, 23, 42, .92), rgba(15, 23, 42, .78));
  border-color: rgba(255, 255, 255, .16);
}

.soft-action {
  background: linear-gradient(180deg, rgba(255, 247, 237, .78), rgba(255, 237, 213, .54));
}

/* Dense work surfaces stay opaque and quiet; glass is reserved for navigation and framing. */
table,
.kanban-card,
.audit-item,
.file-item,
.empty {
  background: rgba(255, 255, 255, .94);
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
table::before,
.kanban-card::before,
.audit-item::before,
.file-item::before,
.empty::before { display: none; }

@media (max-width: 1000px) {
  .shell { min-height: auto; }
  .sidebar {
    position: sticky;
    top: 0;
    inset: auto;
    width: auto;
    height: auto;
    padding: 8px 12px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .mobile-sidebar-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
  .mobile-nav-toggle { display: inline-flex; min-width: 76px; }
  .brand { justify-content: flex-start; margin: 0; }
  .brand img { width: 70px; }
  .sidebar-scroll,
  .sidebar-footer { display: none; }
  .sidebar.is-open .sidebar-scroll,
  .sidebar.is-open .sidebar-footer { display: grid; }
  .sidebar.is-open .sidebar-scroll { margin-top: 8px; }
  .sidebar.is-open .sidebar-footer { margin-top: 10px; }
  .sidebar-scroll {
    overflow: visible;
    padding-right: 0;
  }
  .main { margin-left: 0; padding: 12px; }
  .topbar, .table-toolbar { align-items: flex-start; flex-direction: column; }
  .toolbar-filters {
    width: 100%;
    justify-content: stretch;
    gap: 10px;
    flex-wrap: wrap;
  }
  .toolbar-filter,
  .toolbar-search,
  .toolbar-filter select,
  .toolbar-search input {
    width: 100%;
    min-width: 0;
  }
  .topbar-actions,
  .header-create-action { width: 100%; }
  .workflow-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .workflow-summary-main { grid-column: 1 / -1; }
  .sticky-aside { position: static; }
  .grid-2, .grid-3, .metric-grid, .detail-grid, .split-actions, .issue-form, .template-picker, .compact-template-list, .mapping-row, .send-documents-layout { grid-template-columns: 1fr; }
  .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mapping-row-head { display: none; }
  table.responsive-table,
  table.responsive-table thead,
  table.responsive-table tbody,
  table.responsive-table tr,
  table.responsive-table th,
  table.responsive-table td { display: block; }
  table.responsive-table thead { display: none; }
  table.responsive-table { border: 0; background: transparent; box-shadow: none; }
  table.responsive-table tr {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    padding: 8px 0;
    margin-bottom: 8px;
  }
  table.responsive-table td {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 10px;
    border-bottom: 1px solid var(--soft-line);
    padding: 8px 10px;
    text-align: left;
  }
  table.responsive-table td::before {
    content: attr(data-label);
    color: #667085;
    font-size: 12px;
    font-weight: 800;
  }
  table.responsive-table td:last-child { border-bottom: 0; }
  table.responsive-table .status-pill { justify-self: start; }
  .form-section { grid-template-columns: 1fr; }
  .resend-layout { grid-template-columns: 1fr; }
  .resend-actions { justify-content: flex-start; }
  .data-list div,
  .data-list.dense div { grid-template-columns: 1fr; gap: 4px; }
  .form-footer { justify-content: stretch; }
  .form-footer button, .form-footer .button { width: 100%; }
  .stepper { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pdf-frame { min-height: 460px; }
  .public-pdf-frame { min-height: 420px; }
  .app-dialog { width: calc(100vw - 20px); }
  .app-dialog-card { padding: 10px; }
  .send-preview-frame { min-height: 460px; }
  .django-admin-fab {
    right: 8px;
    bottom: 8px;
    min-width: 30px;
    min-height: 16px;
    padding: 2px 5px;
    font-size: 8px;
  }
}

@media (max-width: 560px) {
  .confirmation-channel-options { grid-template-columns: 1fr; }
  .workflow-summary { grid-template-columns: 1fr; }
  .metric-grid { grid-template-columns: 1fr; }
  .workflow-summary-main { grid-column: auto; }
  .page-anchor-nav { width: 100%; overflow-x: auto; }
  .page-anchor-nav a { white-space: nowrap; }
  .form-block-heading { flex-direction: column; gap: 6px; }
  .public-document-header,
  .document-confirmation-card,
  .document-workflow-action { align-items: stretch; flex-direction: column; grid-template-columns: 1fr; }
  .public-document-header { display: flex; }
  .public-document-actions { width: 100%; align-items: stretch; flex-direction: column; }
  .document-text-action { width: 100%; justify-content: flex-start; }
  .document-text-action.open-action { margin: 0; padding-left: 9px; }
  .document-text-action.open-action::before { display: none; }
  .public-document-card .public-pdf-frame { min-height: 360px; }
  .legal-facts-grid,
  .legal-facts-grid.two-columns,
  .evidence-guide,
  .identity-photo-guide { grid-template-columns: 1fr; }
  .passport-photo-guide { max-width: 320px; justify-self: center; }
  .identity-photo-guide { padding: 14px; }
  .current-photo { grid-template-columns: 76px minmax(0, 1fr); }
  .current-photo img { width: 76px; height: 76px; }
  .current-photo-delete { grid-column: 1 / -1; justify-self: start; }
  .identity-photo-actions { align-items: stretch; flex-direction: column; }
  .identity-photo-actions .primary { width: 100%; }
  .support-disclosure summary { align-items: flex-start; }
  .support-summary-action > span { display: none; }
  .document-multiselect-option { grid-template-columns: 1fr; }
  .document-preview-button { width: 100%; }
  .signed-document-card { grid-template-columns: 1fr; }
  .signed-document-link { width: 100%; }
  .signature-facts { padding-left: 0; }
  .consent-state { align-items: flex-start; flex-direction: column; }
  .pep-step-card .section-content { gap: 18px; }
  .pep-consent-state { align-items: flex-start; flex-direction: column; }
  .document-workflow-footer { grid-template-columns: 1fr; }
  .document-workflow-footer button { width: 100%; }
  .compact-document-action { width: 100%; justify-self: stretch; }
  .signature-action-card { padding: 14px; }
  .signature-action-footer { grid-template-columns: 1fr; }
  .signature-action-footer button { width: 100%; }
}

/* Keep custom dropdown menus visible above glass cards that default to overflow clipping. */
.entity-switcher,
.toolbar-filter,
.toolbar-search,
.sidebar-footer,
.table-toolbar,
.toolbar-filters,
.panel {
  overflow: visible;
}
