/* Unipesa ID cabinet — the smartpos-portal design system, taken from the Unipesa Pro partner
   portal (portal/src/app.css there) unchanged, so every Unipesa back office reads as one product.
   Additions for this cabinet are at the end of the file. */


:root {
	/* Brand */
	--brand: #113ae1;        /* active nav, avatar — the canonical Unipesa blue */
	--brand-50: #eef3fe;
	--brand-100: #dbe4fc;
	--brand-500: #4969e9;
	--brand-600: #2a52e5;    /* buttons, links */
	--brand-700: #1f43c8;    /* hover / pressed */
	--brand-800: #1b38a2;

	/* Neutrals (slate) */
	--neutral-0: #ffffff;
	--neutral-25: #f4f7fa;
	--neutral-50: #ecf1f6;
	--neutral-100: rgba(212, 222, 233, 0.6);
	--neutral-100-solid: #d4dee9;
	--neutral-200: #bac8da;
	--neutral-300: #95a4ba;
	--neutral-400: #7d8ba4;
	--neutral-500: #667691;
	--neutral-600: #50617a;
	--neutral-700: #3c4f69;
	--neutral-800: #273951;
	--neutral-900: #1a2c44;

	/* Status pill pairs (bg / text) */
	--status-success-bg: #d1fab3;
	--status-success-text: #1c5a0d;
	--status-warning-bg: #fceeb5;
	--status-warning-text: #922700;
	--status-danger-bg: #fde9ee;
	--status-danger-text: #9b0c36;
	--status-info-bg: #cbf5fd;
	--status-info-text: #0b46ad;
	--status-neutral-bg: #ecf1f6;
	--status-neutral-text: #50617a;
	--danger: #e61947;

	/* Shadows */
	--shadow-sm: 0px 1px 1px 0px rgba(0, 0, 0, 0.12), 0px 2px 5px 0px rgba(48, 49, 61, 0.08);
	--shadow-md: 0px 3px 6px 0px rgba(0, 0, 0, 0.12), 0px 7px 14px 0px rgba(48, 49, 61, 0.08);
	--shadow-lg: 0px 5px 15px 0px rgba(0, 0, 0, 0.12), 0px 15px 35px 0px rgba(48, 49, 61, 0.08);
	--shadow-action-primary: 0px 1px 1px 0px rgba(20, 19, 78, 0.32);
	--shadow-action-secondary: 0px 1px 2px 0px rgba(16, 17, 26, 0.08);
	--shadow-action-destructive: 0px 1px 1px 0px rgba(62, 2, 26, 0.32);
	--shadow-focus: 0 0 0 3px rgba(83, 58, 253, 0.16);

	/* Radius */
	--radius-xs: 4px;
	--radius-sm: 6px;
	--radius-md: 8px;
	--radius-lg: 12px;
	--radius-xl: 16px;

	/* Typography — 14px base, like the smartpos html { font-size: 14px } */
	--font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
	--font-mono: ui-monospace, "SF Mono", Menlo, Monaco, "Cascadia Mono", "Roboto Mono", monospace;
	--fs-xs: 12px;
	--fs-sm: 13px;
	--fs-base: 14px;
	--fs-lead: 16px;

	/* Layout */
	--sidebar-w: 240px;
	--topbar-h: 56px;
	--page-w: 1120px;
	--col: 720px;

	/* Names the older stylesheet used — kept so nothing that references them breaks. */
	--ink: var(--neutral-900);
	--muted: var(--neutral-500);
	--line: var(--neutral-100);
	--r: var(--radius-md);
	--r-sm: var(--radius-sm);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
	margin: 0;
	font-family: var(--font);
	font-size: var(--fs-base);
	line-height: 20px;
	color: var(--neutral-900);
	background: var(--neutral-0);
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}
h1, h2, h3, h4 { color: var(--neutral-900); margin: 0 0 0.5em; font-weight: 700; letter-spacing: -0.01em; }
h1 { font-size: 20px; line-height: 28px; }
h2 { font-size: 16px; line-height: 24px; }
h3 { font-size: 15px; line-height: 22px; }
p { margin: 0 0 0.8em; }
a { color: var(--brand-600); text-decoration: none; }
a:hover { color: var(--brand-700); text-decoration: underline; }
code, kbd, .mono { font-family: var(--font-mono); font-size: 0.93em; }
small, .small { font-size: var(--fs-sm); }
.xs { font-size: var(--fs-xs); }
.muted { color: var(--neutral-500); }
.nowrap { white-space: nowrap; }
.hidden { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.tnum { font-variant-numeric: tabular-nums; }

/* ---------- shell: sidebar + topbar ---------- */
.shell { display: flex; min-height: 100vh; }

.sidebar {
	width: var(--sidebar-w);
	flex-shrink: 0;
	position: sticky;
	top: 0;
	height: 100vh;
	background: var(--neutral-0);
	border-right: 1px solid var(--neutral-100-solid);
	display: flex;
	flex-direction: column;
	z-index: 30;
}
.sidebar-header { padding: 12px 16px 0; }

/* brand block: avatar + name + app name, opens the account menu */
.brand-menu { position: relative; }
.brand-menu > button {
	display: flex; align-items: center; gap: 10px; width: 100%;
	padding: 6px 10px; border: 0; border-radius: var(--radius-sm); background: transparent;
	font: inherit; text-align: left; cursor: pointer; color: inherit;
	transition: background 100ms;
}
.brand-menu > button:hover, .brand-menu.open > button { background: var(--neutral-25); }
.avatar {
	width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
	background: var(--brand); color: #fff;
	display: grid; place-items: center; font-size: 14px; font-weight: 600; line-height: 1;
}
.brand-menu .name { flex: 1; min-width: 0; }
.brand-menu .name strong { display: block; font-size: 14px; font-weight: 600; color: var(--neutral-900); line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-menu .name span { display: block; font-size: 12px; color: var(--neutral-500); line-height: 1.3; }
.brand-menu .chevron { flex-shrink: 0; color: var(--neutral-500); transition: transform 150ms; }
.brand-menu.open .chevron { transform: rotate(180deg); }
.brand-menu .menu {
	position: absolute; top: calc(100% + 6px); left: 0; right: 0; min-width: 220px; z-index: 40;
	background: var(--neutral-0); border: 1px solid var(--neutral-100-solid); border-radius: var(--radius-md);
	box-shadow: var(--shadow-md); padding: 4px;
}
.brand-menu .menu .signed { padding: 10px 12px; border-bottom: 1px solid var(--neutral-50); margin-bottom: 4px; }
.brand-menu .menu .signed .label { font-size: 11px; color: var(--neutral-500); font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; line-height: 1; }
.brand-menu .menu .signed .value { font-size: 14px; color: var(--neutral-900); font-weight: 500; margin-top: 4px; word-break: break-word; }
.brand-menu .menu .signed .sub { font-size: 12px; color: var(--neutral-500); margin-top: 2px; }
.brand-menu .menu a, .brand-menu .menu button {
	width: 100%; display: flex; align-items: center; gap: 8px; padding: 8px 12px;
	border: 0; background: transparent; border-radius: var(--radius-sm);
	font: inherit; font-size: 14px; font-weight: 500; color: var(--neutral-900); cursor: pointer; text-align: left; text-decoration: none;
}
.brand-menu .menu a:hover, .brand-menu .menu button:hover { background: var(--neutral-25); }
.brand-menu .menu button.signout { color: var(--status-danger-text); }
.brand-menu .menu button.signout:hover { background: var(--status-danger-bg); }
.brand-menu .menu form { margin: 0; }
.brand-menu .menu svg { width: 14px; height: 14px; flex-shrink: 0; }

.side-nav { padding: 24px 16px 0; display: flex; flex-direction: column; gap: 1px; flex: 1; overflow-y: auto; }
.side-nav .group-label { padding: 14px 10px 4px; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: var(--neutral-500); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-nav .group-label:first-child { padding-top: 0; }
.side-nav a {
	display: flex; align-items: center; gap: 10px;
	padding: 7px 10px; border-radius: var(--radius-sm);
	font-size: 14px; line-height: 20px; font-weight: 500; color: var(--neutral-700);
	text-decoration: none; transition: background 100ms, color 100ms;
}
.side-nav a svg { width: 16px; height: 16px; flex-shrink: 0; color: var(--neutral-500); }
.side-nav a:hover { background: var(--neutral-25); color: var(--neutral-900); text-decoration: none; }
.side-nav a:hover svg { color: var(--neutral-900); }
.side-nav a[aria-current="page"] { color: var(--brand); font-weight: 600; }
.side-nav a[aria-current="page"] svg { color: var(--brand); }
.side-nav a[aria-current="page"]:hover { background: var(--brand-50); }
.sidebar-footer { padding: 12px 16px 16px; }
.sidebar-footer img { height: 20px; display: block; opacity: 0.85; }

.main-col { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.topbar {
	position: sticky; top: 0; z-index: 20;
	height: var(--topbar-h); background: var(--neutral-0); border-bottom: 1px solid var(--neutral-100-solid);
	display: flex; align-items: center; gap: 12px; padding: 0 32px;
}
.topbar .crumb { font-size: 13px; color: var(--neutral-500); display: flex; align-items: center; gap: 6px; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar .crumb strong { color: var(--neutral-900); font-weight: 600; }
.topbar .crumb .sep { color: var(--neutral-300); }
.topbar .right { margin-left: auto; display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--neutral-500); white-space: nowrap; }
.topbar .right .zone { padding: 2px 8px; border-radius: var(--radius-xs); background: var(--brand-50); color: var(--brand-700); font-size: 12px; font-weight: 500; }
.icon-btn {
	width: 32px; height: 32px; display: inline-grid; place-items: center; border: 0; background: transparent;
	border-radius: var(--radius-sm); color: var(--neutral-600); cursor: pointer; padding: 0;
}
.icon-btn:hover { background: var(--neutral-25); color: var(--neutral-900); }
.icon-btn svg { width: 18px; height: 18px; }
.nav-toggle { display: none; }
.backdrop { display: none; }

main.page { flex: 1; padding: 24px 32px 48px; max-width: calc(var(--page-w) + 64px); width: 100%; }
main.page.narrow { max-width: calc(var(--col) + 64px); }

@media (max-width: 1023px) {
	.sidebar { position: fixed; left: 0; top: 0; bottom: 0; transform: translateX(-100%); transition: transform 180ms ease; box-shadow: none; }
	.shell.nav-open .sidebar { transform: none; box-shadow: var(--shadow-lg); }
	.backdrop { display: block; position: fixed; inset: 0; background: rgba(26, 44, 68, 0.35); z-index: 25; opacity: 0; pointer-events: none; transition: opacity 180ms; }
	.shell.nav-open .backdrop { opacity: 1; pointer-events: auto; }
	.nav-toggle { display: inline-grid; margin-left: -8px; }
	.topbar { padding: 0 16px; }
	.topbar .right { display: none; }
	main.page { padding: 20px 16px 40px; }
}

/* ---------- page furniture ---------- */
.page-head { display: flex; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.page-head h1 { margin: 0; }
.page-head .lead { color: var(--neutral-500); font-size: var(--fs-sm); margin-top: 4px; }
.page-head .actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.crumbs { font-size: 13px; color: var(--neutral-500); margin-bottom: 8px; display: flex; flex-wrap: wrap; align-items: center; }
.crumbs a { color: var(--neutral-500); }
.crumbs a:hover { color: var(--neutral-900); text-decoration: none; }
.crumbs span::before { content: "/"; margin: 0 8px; color: var(--neutral-300); }
.meta { font-size: var(--fs-sm); color: var(--neutral-500); display: flex; gap: 4px 10px; flex-wrap: wrap; align-items: center; }
.meta strong { color: var(--neutral-900); font-weight: 500; }
h1 + p.muted, h1 + .muted { margin-top: -6px; margin-bottom: 20px; }

.tabs { display: flex; gap: 0; border-bottom: 1px solid var(--neutral-100-solid); margin: 0 0 20px; }
.tabs a { padding: 10px 16px; font-size: 14px; font-weight: 500; color: var(--neutral-600); border-bottom: 2px solid transparent; margin-bottom: -1px; text-decoration: none; }
.tabs a:hover { color: var(--neutral-900); }
.tabs a[aria-current="page"] { color: var(--brand-600); border-bottom-color: var(--brand-600); }
/* the same bar inside a questionnaire (Main information / In detail) — buttons, not links */
.form-tabs button { background: none; border: 0; border-bottom: 2px solid transparent; border-radius: 0; margin-bottom: -1px; padding: 10px 16px; font: inherit; font-size: 14px; font-weight: 500; color: var(--neutral-600); cursor: pointer; display: inline-flex; align-items: baseline; gap: 8px; }
.form-tabs button:hover { color: var(--neutral-900); }
.form-tabs button[aria-selected="true"] { color: var(--brand-600); border-bottom-color: var(--brand-600); }
.form-tabs .tab-note { font-size: var(--fs-xs); font-weight: 400; color: var(--neutral-500); }
.tab-intro { margin-top: -6px; }

/* ---------- cards ---------- */
.card { background: var(--neutral-0); border: 1px solid var(--neutral-100-solid); border-radius: var(--radius-md); padding: 24px; }
.card + .card { margin-top: 16px; }
.card h2, .card h3 { margin-top: 0; }
.card h3 { font-size: 16px; line-height: 24px; margin-bottom: 12px; }
.card.tint { background: var(--neutral-25); }
.card.warn { background: var(--status-warning-bg); border-color: transparent; }
.card.warn h3 { color: var(--status-warning-text); }
.card.quiet { box-shadow: none; }
.grid { display: grid; gap: 16px; }
.grid.two { grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); }
.grid.three { grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); }
.stack > * + * { margin-top: 16px; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.spread { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.divider { border: 0; border-top: 1px solid var(--neutral-100-solid); margin: 20px 0; }
@media (max-width: 720px) { .card { padding: 16px; } }

/* ---------- buttons ---------- */
.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 6px;
	font: inherit; font-size: 14px; font-weight: 500; line-height: 20px;
	padding: 7px 14px; border-radius: var(--radius-sm); border: 1px solid transparent;
	cursor: pointer; text-decoration: none; white-space: nowrap;
	transition: background 100ms, border-color 100ms, color 100ms, box-shadow 100ms;
}
.btn:hover { text-decoration: none; }
.btn:focus-visible { outline: none; box-shadow: 0 0 0 4px rgba(1, 150, 237, 0.36); }
.btn.primary, .btn.navy { background: var(--brand-600); color: #fff; box-shadow: var(--shadow-action-primary); }
.btn.primary:hover, .btn.navy:hover { background: var(--brand-700); color: #fff; }
.btn.ghost { background: var(--neutral-0); color: var(--neutral-900); border-color: var(--neutral-100-solid); box-shadow: var(--shadow-action-secondary); }
.btn.ghost:hover { border-color: var(--neutral-300); background: var(--neutral-25); color: var(--neutral-900); }
.btn.danger { background: var(--danger); color: #fff; box-shadow: var(--shadow-action-destructive); }
.btn.danger:hover { background: #c9123c; color: #fff; }
.btn.sm { padding: 4px 10px; font-size: 13px; line-height: 18px; }
.btn:disabled, .btn[aria-disabled="true"] { opacity: 0.5; cursor: not-allowed; }
.btn.block { width: 100%; }
button.link { background: none; border: 0; padding: 0; color: var(--brand-600); font: inherit; cursor: pointer; }
button.link:hover { text-decoration: underline; }

/* ---------- status pills ---------- */
.pill {
	display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px;
	border-radius: var(--radius-xs); font-size: 12px; font-weight: 500; line-height: 1; white-space: nowrap;
	background: var(--status-neutral-bg); color: var(--status-neutral-text);
}
.pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: 0.7; }
.pill.not_started { background: var(--status-neutral-bg); color: var(--status-neutral-text); }
.pill.draft { background: var(--status-info-bg); color: var(--status-info-text); }
.pill.in_review { background: var(--status-warning-bg); color: var(--status-warning-text); }
.pill.ready { background: var(--status-success-bg); color: var(--status-success-text); }
.pill.disabled { background: var(--status-neutral-bg); color: var(--neutral-400); }
.pill.stage { background: var(--brand-50); color: var(--brand-700); }
.pill.stage::before { display: none; }
.tag {
	display: inline-flex; align-items: center; height: 20px; padding: 0 6px; border-radius: var(--radius-xs);
	font-size: 12px; font-weight: 500; white-space: nowrap;
	background: var(--brand-50); color: var(--brand-700);
}
.tag.dark { background: var(--neutral-800); color: #fff; }
.tag.currency { margin-left: 8px; font-family: var(--font-mono); font-weight: 600; letter-spacing: 0.04em; vertical-align: middle; }
.tag.red { background: var(--status-danger-bg); color: var(--status-danger-text); }
.tag.green { background: var(--status-success-bg); color: var(--status-success-text); }
.tag.grey { background: var(--status-neutral-bg); color: var(--status-neutral-text); }

/* ---------- progress ---------- */
.progress { height: 6px; background: var(--neutral-50); border-radius: 999px; overflow: hidden; }
.progress > i { display: block; height: 100%; background: var(--brand-600); border-radius: 999px; transition: width 0.3s; }

/* ---------- tables ---------- */
.table-wrap { overflow-x: auto; margin: 0 -24px; padding: 0 24px; }
table.list { width: 100%; border-collapse: collapse; font-size: 14px; }
table.list th, table.list td { text-align: left; padding: 12px 16px; border-bottom: 1px solid var(--neutral-100-solid); vertical-align: middle; }
table.list th:first-child, table.list td:first-child { padding-left: 0; }
table.list th:last-child, table.list td:last-child { padding-right: 0; }
table.list th { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--neutral-500); white-space: nowrap; }
table.list tr:last-child td { border-bottom: 0; }
table.list tbody tr { transition: background 80ms; }
table.list tbody tr:hover td { background: var(--neutral-25); }
table.list td.num, table.list th.num { text-align: right; font-variant-numeric: tabular-nums; }
table.list td a strong { font-weight: 500; }
table.list tr.muted td { color: var(--neutral-400); }
@media (max-width: 720px) { .table-wrap { margin: 0 -16px; padding: 0 16px; } }

/* ---------- forms ---------- */
.field { display: grid; gap: 6px; margin-bottom: 18px; max-width: var(--col); }
.field label, .field .label { font-weight: 500; font-size: 13px; color: var(--neutral-700); }
.field .req { color: var(--danger); margin-left: 2px; }
.field .help { font-size: 12px; color: var(--neutral-500); margin-top: -2px; }
.field .help.ru { font-style: italic; }
.field .warn { font-size: var(--fs-sm); color: var(--status-danger-text); background: var(--status-danger-bg); padding: 8px 10px; border-radius: var(--radius-sm); }
input[type="text"], input[type="email"], input[type="url"], input[type="tel"], input[type="number"], input[type="date"], input[type="password"], input[type="search"], textarea, select {
	font: inherit; font-size: 14px; line-height: 20px; color: var(--neutral-900);
	padding: 7px 10px; border: 1px solid var(--neutral-200); border-radius: var(--radius-sm);
	background: var(--neutral-0); width: 100%; max-width: 100%; min-height: 36px;
	transition: border-color 100ms, box-shadow 100ms;
}
select {
	appearance: none; -webkit-appearance: none; cursor: pointer; padding-right: 30px;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23667691'%3E%3Cpath fill-rule='evenodd' d='M4.22 6.22a.75.75 0 0 1 1.06 0L8 9.94l2.72-3.72a.75.75 0 1 1 1.06 1.06l-3.25 3.25a.75.75 0 0 1-1.06 0L4.22 7.28a.75.75 0 0 1 0-1.06Z' clip-rule='evenodd'/%3E%3C/svg%3E");
	background-position: right 8px center; background-repeat: no-repeat; background-size: 14px;
}
textarea { resize: vertical; min-height: 5.5em; }
input::placeholder, textarea::placeholder { color: var(--neutral-400); }
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--brand-600); box-shadow: var(--shadow-focus); }
input:disabled, textarea:disabled, select:disabled { background: var(--neutral-25); color: var(--neutral-500); cursor: not-allowed; border-color: var(--neutral-100-solid); }
input[readonly], textarea[readonly] { background: var(--neutral-25); }
input[type="checkbox"], input[type="radio"] { accent-color: var(--brand-600); }
.choices { display: flex; flex-wrap: wrap; gap: 8px 20px; padding-top: 2px; }
.choices label { font-weight: 400; display: inline-flex; align-items: flex-start; gap: 8px; cursor: pointer; font-size: 14px; color: var(--neutral-900); line-height: 20px; }
.choices.stack { flex-direction: column; gap: 8px; }
.choices input { width: 16px; height: 16px; margin: 2px 0 0; flex-shrink: 0; }
.choices .opt { display: flex; flex-direction: column; gap: 2px; }
.choices .opt-help { font-size: 12px; line-height: 16px; color: var(--neutral-500); }
.check { display: inline-flex; align-items: center; gap: 8px; font-weight: 400; cursor: pointer; color: var(--neutral-900); }
.check input { width: 16px; height: 16px; }
.inline-fields { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.inline-fields input, .inline-fields select { width: auto; }
.form-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-top: 18px; }
.form-error { background: var(--status-danger-bg); color: var(--status-danger-text); padding: 10px 12px; border-radius: var(--radius-sm); font-size: var(--fs-sm); margin-bottom: 14px; }
.form-ok.result { display: flex; flex-direction: column; gap: 2px; margin-bottom: 0; }
.form-ok.result .help { color: inherit; opacity: 0.8; }
.form-ok { background: var(--status-success-bg); color: var(--status-success-text); padding: 10px 12px; border-radius: var(--radius-sm); font-size: var(--fs-sm); margin-bottom: 14px; }
.rule { background: var(--status-warning-bg); border-left: 3px solid var(--status-warning-text); color: var(--status-warning-text); padding: 10px 12px; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; font-size: var(--fs-sm); margin-bottom: 18px; max-width: var(--col); }
.hint .note-link { margin-top: 8px; display: inline-block; }
.hint { background: var(--brand-50); color: var(--brand-800); padding: 10px 12px; border-radius: var(--radius-sm); font-size: var(--fs-sm); max-width: var(--col); }
.intro { color: var(--neutral-500); max-width: var(--col); margin-bottom: 18px; }
fieldset.group { border: 0; padding: 0; margin: 0 0 8px; }
fieldset.group + fieldset.group { border-top: 1px solid var(--neutral-100-solid); padding-top: 20px; margin-top: 20px; }
fieldset.group legend { font-weight: 700; color: var(--neutral-900); font-size: 16px; line-height: 24px; padding: 0; margin-bottom: 4px; float: left; width: 100%; }
fieldset.group .group-intro { clear: both; font-size: var(--fs-sm); color: var(--neutral-500); margin: 0 0 14px; max-width: var(--col); }
fieldset.group .fields { clear: both; display: grid; gap: 0; grid-template-columns: 1fr; padding-top: 8px; }
.save-state { font-size: 12px; color: var(--neutral-500); display: inline-flex; align-items: center; gap: 4px; min-width: 5.5rem; justify-content: flex-end; }
.save-state.saving { color: var(--status-warning-text); }
.save-state.saved { color: var(--status-success-text); }
.save-state.error { color: var(--status-danger-text); }
.savebar { display: flex; justify-content: flex-end; align-items: center; gap: 10px; margin: -4px 0 14px; }

/* editable table */
table.grid-edit { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
table.grid-edit th, table.grid-edit td { border: 1px solid var(--neutral-100-solid); padding: 3px; vertical-align: middle; }
table.grid-edit th { background: var(--neutral-25); font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: var(--neutral-500); text-align: left; padding: 6px 8px; }
table.grid-edit input, table.grid-edit select { padding: 4px 8px; font-size: var(--fs-sm); border-color: transparent; background: transparent; min-height: 32px; }
table.grid-edit input:focus, table.grid-edit select:focus { background: #fff; border-color: var(--brand-600); }
table.grid-edit td.ctl { width: 2rem; text-align: center; }
table.grid-edit td:has(.files-cell) { vertical-align: top; padding: 6px; min-width: 280px; }
/* a table rendered as cards — one per row, with its attachments */
.rowcards { display: grid; gap: 12px; max-width: var(--col); }
.rowcard { border: 1px solid var(--neutral-100-solid); border-radius: var(--radius-md); background: var(--neutral-25); padding: 14px 16px; }
.rowcard-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 10px; }
.rowcard-head strong { font-size: 15px; }
.rowcard-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(170px, 100%), 1fr)); gap: 10px 16px; align-items: end; }
.rowcard .field { margin-bottom: 0; max-width: none; }
.rowcard .field input, .rowcard .field select, .rowcard .field textarea { background: var(--neutral-0); }
.rowcard-fields .field.full { grid-column: 1 / -1; }
table.grid-edit textarea.cell-text { min-height: 32px; padding: 4px 8px; font-size: var(--fs-sm); border-color: transparent; background: transparent; resize: none; }
table.grid-edit textarea.cell-text:focus { background: #fff; border-color: var(--brand-600); }
.rowcard-files { margin-top: 12px; }
.rowcard-files .files { max-width: none; }
.files-cell .files { gap: 6px; max-width: none; }
.files-cell .file-row { padding: 6px 8px; font-size: 12px; }
.files-cell .file-row .meta { display: none; }
.files-cell .dropzone { padding: 7px 10px; font-size: 12px; }

/* files */
.files { display: grid; gap: 8px; max-width: var(--col); }
.file-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 8px 12px; border: 1px solid var(--neutral-100-solid); border-radius: var(--radius-sm); background: var(--neutral-25); font-size: var(--fs-sm); }
.file-row .thumb { width: 40px; height: 40px; object-fit: contain; border-radius: var(--radius-xs); background: var(--neutral-0); border: 1px solid var(--neutral-100-solid); display: block; }
.file-row .name { font-weight: 500; word-break: break-all; }
.file-row .meta { color: var(--neutral-500); font-size: 12px; }
.file-row .spacer { flex: 1; }
.dropzone { border: 1.5px dashed var(--neutral-200); border-radius: var(--radius-sm); padding: 14px 16px; text-align: center; font-size: var(--fs-sm); color: var(--neutral-500); background: var(--neutral-0); cursor: pointer; transition: border-color 100ms, background 100ms; }
.dropzone:hover, .dropzone.drag { border-color: var(--brand-600); background: var(--brand-50); color: var(--brand-800); }
.dropzone input { display: none; }
.upload-progress { height: 6px; background: var(--neutral-50); border-radius: 999px; overflow: hidden; margin-top: 6px; }
.upload-progress > i { display: block; height: 100%; background: var(--brand-600); }
.versions { font-size: 12px; color: var(--neutral-500); margin: 4px 0 0 6px; padding-left: 16px; }
details summary { cursor: pointer; color: var(--brand-600); font-size: var(--fs-sm); }

/* attachments inside the form card */
.attach-block { border-top: 1px solid var(--neutral-100-solid); margin-top: 20px; padding-top: 20px; max-width: var(--col); }
.attach-block h3 { margin-bottom: 4px; }
.help-p { color: var(--neutral-500); font-size: var(--fs-sm); margin: 0 0 12px; }

/* comments */
.comments { display: grid; gap: 8px; max-width: var(--col); }
.comment { padding: 10px 12px; border-radius: var(--radius-sm); background: var(--neutral-25); border: 1px solid var(--neutral-100-solid); }
.comment.internal { background: #fffbeb; border-color: #f5e6a6; }
.comment.system { background: var(--brand-50); border-color: transparent; }
.comment.returned { background: var(--status-danger-bg); border-color: transparent; }
.comment.accepted { background: var(--status-success-bg); border-color: transparent; }
.comment .who { font-size: 12px; color: var(--neutral-500); display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-bottom: 4px; }
.comment .who strong { color: var(--neutral-900); font-weight: 600; }
.comment .body { white-space: pre-wrap; font-size: 14px; }

/* ---------- launch path ---------- */
.partner-head { margin-bottom: 20px; }
.partner-head h1 { margin: 0 0 4px; font-size: 22px; line-height: 30px; }
.todo { border-left: 3px solid var(--brand-600); }
.todo h2 { margin-bottom: 8px; }
.todo ol { margin: 0; padding-left: 20px; }
.todo li { margin: 6px 0; }
.todo li a { font-weight: 500; }
.todo .note { color: var(--neutral-500); font-size: var(--fs-sm); margin: 14px 0 0; }
.track { padding: 0; }
.track > :last-child { border-bottom-left-radius: inherit; border-bottom-right-radius: inherit; }
.track-head { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; padding: 16px 24px; border-bottom: 1px solid var(--neutral-100-solid); }
.track-head h2 { margin: 0; }
.track-head .prog { width: 140px; }
.track-head .count { color: var(--neutral-500); font-size: var(--fs-sm); }
.track-head .actions { margin-left: auto; }
.steps { display: block; }
.step-row { display: grid; grid-template-columns: 3.4rem 1fr auto; gap: 2px 16px; align-items: center; padding: 12px 24px; border-bottom: 1px solid var(--neutral-100-solid); color: inherit; transition: background 80ms; }
.step-row:last-child { border-bottom: 0; }
.step-row:hover { background: var(--neutral-25); text-decoration: none; color: inherit; }
.step-row.entry { grid-template-columns: 1fr auto; }
.step-row .code { font-weight: 600; color: var(--brand-600); font-size: 13px; font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.step-row .title { font-weight: 500; }
.step-row .sub { font-size: 12px; color: var(--neutral-500); margin-top: 2px; }
.step-row .sub .kam { color: var(--neutral-900); }
.step-row .status { display: flex; gap: 6px; align-items: center; justify-content: flex-end; }
.track .empty { padding: 14px 24px; color: var(--neutral-500); font-size: var(--fs-sm); margin: 0; }
/* hub: one card per provider type */
.hub-groups { display: grid; gap: 16px; }
/* currency filter on the tabs row */
.tabs .seg { margin-left: auto; align-self: center; display: inline-flex; gap: 2px; padding: 3px; margin-bottom: 6px; background: var(--neutral-25); border: 1px solid var(--neutral-100-solid); border-radius: 999px; }
.tabs .seg a { padding: 4px 12px; margin: 0; border: 0; border-radius: 999px; font-size: 13px; font-weight: 600; line-height: 20px; color: var(--neutral-600); }
.tabs .seg a:hover { color: var(--neutral-900); }
.tabs .seg a[aria-current="page"] { background: var(--brand-600); color: #fff; }
@media (max-width: 720px) {
	.track-head, .step-row, .track .empty { padding-left: 16px; padding-right: 16px; }
	.step-row { grid-template-columns: 3rem 1fr; }
	.step-row .status { grid-column: 2; justify-content: flex-start; margin-top: 4px; }
	.track-head .prog { width: 100px; }
}

/* kv */
dl.kv { display: grid; grid-template-columns: max-content 1fr; gap: 8px 20px; margin: 0; font-size: 14px; align-items: baseline; }
dl.kv dt { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: var(--neutral-500); }
dl.kv dd { margin: 0; font-weight: 500; }

.notice { font-size: var(--fs-sm); color: var(--neutral-500); }
.password-box { display: inline-block; font-family: var(--font-mono); font-size: 15px; letter-spacing: 0.08em; background: var(--neutral-0); border: 1px solid var(--neutral-100-solid); padding: 6px 10px; border-radius: var(--radius-sm); user-select: all; color: var(--neutral-900); }
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 16px; }
.filters input, .filters select { width: auto; }
.filters input[type="search"] { width: 260px; max-width: 100%; }
.filters label { display: inline-flex; align-items: center; gap: 6px; }

/* ---------- login ---------- */
/* A fixed WebGL gradient canvas (static/js/brand-gradient.js, the same shader as the
   smartpos login) sits behind the page; the CSS gradient below is the frame shown until it
   paints, and the whole picture for reduced-motion, mobile and no-WebGL visitors. */
.login-shell {
	min-height: 100vh; min-height: 100dvh; display: flex; align-items: center; justify-content: center; padding: 24px; position: relative;
	background:
		radial-gradient(ellipse 800px 600px at 15% 85%, #88b8ff 0%, rgba(136, 184, 255, 0) 60%),
		radial-gradient(ellipse 1200px 1000px at 25% 50%, #ff8c42 0%, rgba(255, 140, 66, 0) 55%),
		radial-gradient(ellipse 1000px 800px at 90% 20%, #1f3eb6 0%, rgba(31, 62, 182, 0) 55%),
		linear-gradient(135deg, #4569e3 0%, #1f3eb6 100%);
}
html.login-route, html.login-route body { background: #1f3eb6; overscroll-behavior: none; }
#gradient-canvas { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 0; pointer-events: none; --gradient-color-1: #1f3eb6; --gradient-color-2: #4569e3; --gradient-color-3: #ff8c42; --gradient-color-4: #88b8ff; }
.login-blue-tint { position: fixed; inset: 0; z-index: 1; pointer-events: none; background: radial-gradient(circle 620px at top left, #1f3eb6 0%, rgba(31, 62, 182, 0.45) 40%, transparent 80%); will-change: opacity; }
.login-brand-logo { position: fixed; top: 32px; left: 40px; width: 120px; z-index: 3; pointer-events: none; }
.login-brand-logo img { width: 100%; height: auto; display: block; }
#gradient-canvas, .login-blue-tint, .login-brand-logo { opacity: 0; transition: opacity 240ms ease-out; }
html.login-canvas-ready #gradient-canvas, html.login-canvas-ready .login-blue-tint, html.login-canvas-ready .login-brand-logo { opacity: 1; }
.login-card {
	position: relative; z-index: 2; width: 100%; max-width: 512px;
	background: var(--neutral-0); border: 1px solid rgba(255, 255, 255, 0.7); border-radius: var(--radius-lg);
	box-shadow: 0 2px 6px 0 rgba(26, 44, 68, 0.06), 0 12px 40px -8px rgba(26, 44, 68, 0.18);
	padding: 40px 48px;
}
.login-card h1 { font-size: 22px; line-height: 30px; letter-spacing: -0.3px; margin-bottom: 24px; }
.login-card .field { max-width: none; margin-bottom: 20px; }
.login-card .field input { height: 44px; font-size: 15px; }
.login-card .btn { height: 44px; font-size: 15px; font-weight: 600; margin-top: 4px; }
.login-card .btn:disabled:hover { background: var(--brand-600); }
.login-card .notice { margin-top: 20px; }
.login-card.is-shaking { animation: login-card-shake 0.55s cubic-bezier(0.36, 0.07, 0.19, 0.97); }
@keyframes login-card-shake {
	10%, 90% { transform: translate3d(-2px, 0, 0); }
	20%, 80% { transform: translate3d(4px, 0, 0); }
	30%, 50%, 70% { transform: translate3d(-8px, 0, 0); }
	40%, 60% { transform: translate3d(8px, 0, 0); }
}
@media (max-width: 640px) {
	/* the hero band + bottom sheet the smartpos login uses on phones */
	.login-shell { align-items: flex-end; padding: 0; }
	.login-card { max-width: none; border: 0; border-radius: 24px 24px 0 0; padding: 80px 32px 48px; min-height: calc(100dvh - 96px); box-shadow: 0 -4px 16px rgba(26, 44, 68, 0.08), 0 -1px 0 rgba(255, 255, 255, 0.5); }
	.login-brand-logo { top: 32px; left: 50%; transform: translateX(-50%); width: 144px; }
	.login-card h1 { font-size: 20px; line-height: 28px; }
	.login-card .field input, .login-card .btn { font-size: 14px; }
}

/* Two-step verification setup: numbered steps with store links */
.mfa-steps { padding-left: 1.25rem; margin: 0 0 18px; display: grid; gap: 14px; }
.mfa-steps li { line-height: 1.5; }
.mfa-steps img { display: block; margin: 10px 0 6px; }
.mfa-steps .store-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }

/* a product (Platform, POS, …) shown as a tag: partner list, partner card, Products page */
.product-tag { display: inline-block; padding: 1px 7px; border-radius: 4px; font-size: var(--fs-xs); font-weight: 600; line-height: 18px; background: var(--brand-50); color: var(--brand-800); white-space: nowrap; }
.product-tags { display: inline-flex; flex-wrap: wrap; gap: 4px; }

/* Narrow room (phones, tablets, a narrow window): list tables marked .stack become one card per
   row; each cell shows its column title (data-label, set by the stackLabels action). Cells without a
   title — action buttons — span the card. Measured on the table's own box, not the screen. */
.table-wrap:has(table.list.stack) { container-type: inline-size; }
@container (max-width: 760px) {
	table.list.stack, table.list.stack tbody, table.list.stack tr, table.list.stack td { display: block; width: 100%; }
	table.list.stack thead { display: none; }
	table.list.stack tr { padding: 12px 0; border-bottom: 1px solid var(--neutral-100-solid); }
	table.list.stack tr:last-child { border-bottom: 0; }
	table.list.stack td { padding: 3px 0; border: 0; text-align: left !important; white-space: normal; }
	table.list.stack td[data-label] { display: grid; grid-template-columns: 38% 1fr; gap: 10px; align-items: baseline; }
	table.list.stack td[data-label]::before { content: attr(data-label); font-size: var(--fs-xs); color: var(--neutral-500); }
	table.list.stack td:first-child { font-weight: 600; }
	table.list.stack td:first-child[data-label] { display: block; }
	table.list.stack td:first-child[data-label]::before { display: none; }
}

/* ============================================================
   Unipesa ID additions
   ============================================================ */

/* The account menu opens without script: a <details> styled as the portal's brand button. */
details.brand-menu > summary {
	display: flex; align-items: center; gap: 10px; width: 100%; list-style: none;
	padding: 6px 10px; border-radius: var(--radius-sm); cursor: pointer; color: inherit;
	transition: background 100ms;
}
details.brand-menu > summary::-webkit-details-marker { display: none; }
details.brand-menu > summary:hover, details.brand-menu[open] > summary { background: var(--neutral-25); }
details.brand-menu[open] .chevron { transform: rotate(180deg); }
details.brand-menu .menu { display: block; }

/* No script, so no slide-in drawer: on narrow screens the sidebar becomes a band at the top. */
@media (max-width: 1023px) {
	.shell { flex-direction: column; }
	.sidebar { position: static; transform: none; width: 100%; height: auto; border-right: 0; border-bottom: 1px solid var(--neutral-100-solid); }
	.side-nav { flex-direction: row; flex-wrap: wrap; padding: 8px 16px 12px; gap: 4px; }
	.sidebar-footer { display: none; }
	.topbar { display: none; }
}

/* Messages after an action: one box, four tones. */
.msg { padding: 10px 12px; border-radius: var(--radius-sm); font-size: var(--fs-sm); margin-bottom: 16px; }
.msg.ok { background: var(--status-success-bg); color: var(--status-success-text); }
.msg.error { background: var(--status-danger-bg); color: var(--status-danger-text); }
.msg.warn { background: var(--status-warning-bg); color: var(--status-warning-text); }
.msg.info { background: var(--brand-50); color: var(--brand-800); }

/* Status pills in the vocabulary of this cabinet. */
.pill.ok { background: var(--status-success-bg); color: var(--status-success-text); }
.pill.bad { background: var(--status-danger-bg); color: var(--status-danger-text); }
.pill.warn { background: var(--status-warning-bg); color: var(--status-warning-text); }
.pill.info { background: var(--status-info-bg); color: var(--status-info-text); }
.pill.brand { background: var(--brand-50); color: var(--brand-700); }

/* "Ready to verify" checklist on the settings page. */
.checklist { padding: 0; }
.checklist .track-head { padding: 16px 24px; }
.check-row { display: grid; grid-template-columns: 28px 1fr auto; gap: 2px 14px; align-items: start; padding: 14px 24px; border-bottom: 1px solid var(--neutral-100-solid); }
.check-row:last-child { border-bottom: 0; }
.check-row .mark { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 700; line-height: 1; }
.check-row .mark.done { background: var(--status-success-bg); color: var(--status-success-text); }
.check-row .mark.need { background: var(--status-warning-bg); color: var(--status-warning-text); }
.check-row .mark.later { background: var(--neutral-50); color: var(--neutral-500); }
.check-row .title { font-weight: 500; }
.check-row .sub { font-size: var(--fs-sm); color: var(--neutral-500); margin-top: 2px; }
@media (max-width: 720px) { .check-row { padding: 12px 16px; } }

/* A secret shown once (an API key, a webhook signing secret). */
.secret { background: var(--status-warning-bg); color: var(--status-warning-text); border-radius: var(--radius-sm); padding: 12px 14px; margin-bottom: 16px; font-size: var(--fs-sm); }
.secret .password-box { display: block; margin-top: 8px; word-break: break-all; font-size: 13px; letter-spacing: 0; }

/* Card header with a title, a line under it and actions on the right. */
.card-head { display: flex; align-items: flex-start; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.card-head h2 { margin: 0; }
.card-head .lead { color: var(--neutral-500); font-size: var(--fs-sm); margin-top: 2px; }
.card-head .actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* Forms laid out in a row of fields. */
.form-row { display: grid; gap: 12px 16px; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); align-items: end; }
.form-row .field { margin-bottom: 0; max-width: none; }
.settings-grid { display: grid; gap: 16px 24px; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); }
.settings-grid .field { margin-bottom: 0; max-width: none; }

/* What a business is asked: one line per requirement. */
.req-list { display: grid; gap: 0; }
.req-list .req { display: grid; grid-template-columns: 24px 1fr auto; gap: 12px; align-items: baseline; padding: 10px 0; border-bottom: 1px solid var(--neutral-100-solid); }
.req-list .req:last-child { border-bottom: 0; }
.req-list .n { color: var(--neutral-400); font-variant-numeric: tabular-nums; font-size: var(--fs-sm); }
.req-list .what { font-size: var(--fs-sm); color: var(--neutral-500); margin-top: 2px; }

/* Developer details at the bottom of a page. */
details.dev { margin-top: 16px; }
details.dev > summary { font-size: var(--fs-sm); color: var(--neutral-500); padding: 8px 0; }
details.dev[open] > summary { margin-bottom: 8px; }

/* Signal strip on a case card. */
.signals { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(min(210px, 100%), 1fr)); margin-top: 4px; }
/* Each signal its own tile: its own frame and air, so neighbouring texts never run together. */
.signals > div { background: var(--neutral-25); border: 1px solid var(--neutral-100-solid); border-radius: var(--radius-sm); padding: 10px 12px; }
.signals .label { font-size: 10.5px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: var(--neutral-500); margin-bottom: 6px; }
.signals .val { font-size: 13px; line-height: 1.4; }
.signals .signal-note { margin-top: 6px; font-size: 12px; }

/* Login without the WebGL shader (the cabinet runs no script): the CSS frame is the picture. */
.login-shell .login-brand-logo { opacity: 1; }
.qr svg { width: 200px; height: 200px; display: block; margin: 8px auto; }
.codes { font-family: var(--font-mono); columns: 2; padding-left: 0; list-style: none; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
form.inline { display: inline; margin: 0; }
.empty { color: var(--neutral-500); font-size: var(--fs-sm); padding: 8px 0; }

/* Page-level pieces of the cabinet pages. */
.seg { display: inline-flex; gap: 2px; padding: 3px; background: var(--neutral-25); border: 1px solid var(--neutral-100-solid); border-radius: 999px; flex-wrap: wrap; }
.seg a { padding: 4px 12px; border-radius: 999px; font-size: 13px; font-weight: 600; line-height: 20px; color: var(--neutral-600); }
.seg a:hover { color: var(--neutral-900); text-decoration: none; }
.seg a[aria-current="page"] { background: var(--brand-600); color: #fff; }
.section-title { margin: 32px 0 12px; font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--neutral-500); }
a.card { display: block; color: inherit; transition: border-color 100ms, box-shadow 100ms; }
a.card:hover { text-decoration: none; color: inherit; border-color: var(--brand-600); box-shadow: var(--shadow-action-secondary); }
a.card h2 { color: var(--brand-600); }
a.card p { margin: 0; }
.grid > .card + .card { margin-top: 0; }
.btn.danger-text { color: var(--status-danger-text); }
.btn.danger-text:hover { background: var(--status-danger-bg); color: var(--status-danger-text); border-color: transparent; }
table.list td.row-actions { text-align: right; white-space: nowrap; }
table.list td.row-actions > * + * { margin-left: 6px; }
.role-help { margin: 14px 0 0; padding-left: 18px; display: grid; gap: 2px; }
.history { margin: 0; padding-left: 18px; display: grid; gap: 4px; font-size: var(--fs-sm); }
.history + .msg { margin: 12px 0 0; }
.finding-form { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; justify-content: flex-end; }
.finding-form input { width: 180px; }
.return-row { display: grid; grid-template-columns: minmax(160px, 1fr) minmax(180px, 1fr) minmax(200px, 1.6fr); gap: 8px 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--neutral-100-solid); }
.return-row + .field { margin-top: 16px; }
@media (max-width: 720px) { .return-row { grid-template-columns: 1fr; } }
.key-form { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 8px; max-width: var(--col); }
.key-form input { flex: 1; min-width: 200px; }
.form-row .field.wide { grid-column: span 2; }
@media (max-width: 720px) { .form-row .field.wide { grid-column: auto; } }
details.dev.card { margin-top: 16px; }
details.dev.card > summary { padding: 0; }
details.dev.card[open] > summary { margin-bottom: 16px; }
details.dev h3 { margin-top: 20px; }
details.dev textarea { font-size: 12px; }
.login-card form + .notice, .login-card form + form .notice { margin-top: 16px; }
.login-card form .notice { margin: 16px 0 0; }
.login-card .field .help { margin-top: 0; }
.mfa-steps .qr svg { margin: 10px 0 6px; width: 180px; height: 180px; }
.codes.password-box { display: block; columns: 2; margin: 0 0 20px; padding: 12px 16px; line-height: 1.8; }
.check-row .key-form { margin-top: 10px; }
details.pick { position: relative; }
details.pick > summary { list-style: none; display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border: 1px solid var(--neutral-100-solid); border-radius: 999px; background: var(--neutral-0); color: var(--neutral-900); font-size: 13px; font-weight: 600; line-height: 20px; box-shadow: var(--shadow-action-secondary); }
details.pick > summary::-webkit-details-marker { display: none; }
details.pick > summary::after { content: "▾"; color: var(--neutral-500); font-size: 11px; }
details.pick .pick-menu { position: absolute; right: 0; top: calc(100% + 4px); z-index: 20; min-width: 220px; max-height: 320px; overflow-y: auto; padding: 4px; background: var(--neutral-0); border: 1px solid var(--neutral-100-solid); border-radius: var(--radius-sm); box-shadow: var(--shadow-lg); display: grid; }
details.pick .pick-menu a { padding: 7px 10px; border-radius: var(--radius-xs); font-size: 14px; color: var(--neutral-900); }
details.pick .pick-menu a:hover { background: var(--neutral-25); text-decoration: none; }
details.pick .pick-menu a[aria-current="page"] { color: var(--brand-600); font-weight: 600; }
@container (max-width: 760px) {
	table.list.stack td[data-label] > .pill { justify-self: start; }
	table.list.stack td.row-actions { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-start; padding-top: 8px; }
	table.list.stack td.row-actions > * + * { margin-left: 0; }
}

/* Sandbox / production switch (like Stripe's test mode) and the sandbox stripe. */
.env-switch { display: flex; gap: 2px; margin: 12px 16px 4px; padding: 3px; background: var(--neutral-25); border: 1px solid var(--neutral-100-solid); border-radius: 999px; }
.env-switch button { flex: 1; border: 0; background: transparent; border-radius: 999px; padding: 4px 10px; font: inherit; font-size: 13px; font-weight: 600; color: var(--neutral-600); cursor: pointer; }
.env-switch button:hover { color: var(--neutral-900); }
.env-switch button[aria-pressed="true"][value="sandbox"] { background: var(--status-warning-bg); color: var(--status-warning-text); }
.env-switch button[aria-pressed="true"][value="production"] { background: var(--brand-600); color: #fff; }
.env-stripe { background: var(--status-warning-bg); color: var(--status-warning-text); border: 1px solid rgba(146, 39, 0, 0.12); border-radius: var(--radius-sm); margin: 12px 24px 0; font-size: 12px; font-weight: 500; text-align: center; padding: 6px 12px; letter-spacing: 0.02em; }
.env-card { border-left: 3px solid var(--status-warning-bg); }
.env-card.live { border-left-color: var(--brand-600); }
@media (max-width: 1023px) { .env-switch { margin: 8px 16px; } .env-stripe { margin: 8px 16px 0; } }

/* The case card's photographs, drawn at once. */
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.photo { margin: 0; border: 1px solid var(--neutral-100-solid); border-radius: var(--radius-sm); overflow: hidden; background: var(--neutral-25); }
.photo a { display: block; }
.photo img { display: block; width: 100%; height: 200px; object-fit: contain; background: #f4f5f7; }
.photo.older { opacity: 0.55; }
.photo-none { height: 200px; display: flex; align-items: center; justify-content: center; color: var(--neutral-600); font-size: 13px; }
.photo figcaption { padding: 8px 10px; font-size: 13px; }

/* What the business told us: sections one under another, label above value. */
.facts { padding: 20px 0 4px; border-top: 1px solid var(--neutral-100-solid); }
.card-head + .facts { border-top: 0; padding-top: 4px; }
.facts h3 { margin: 0 0 14px; font-size: 13px; font-weight: 600; color: var(--neutral-900); }
.facts-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(220px, 100%), 1fr)); gap: 12px; margin: 0 0 16px; }
/* Each field its own tile, like the signals above. */
.fact { background: var(--neutral-25); border: 1px solid var(--neutral-100-solid); border-radius: var(--radius-sm); padding: 12px 16px; }
.fact dt { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: var(--neutral-500); margin-bottom: 6px; }
.fact dd { margin: 0; font-size: 15px; color: var(--neutral-900); overflow-wrap: anywhere; }

/* A signal that needs nothing from the reviewer: plain words, no badge. */
.fine { color: var(--status-success-text); font-weight: 600; }

/* The line under a signal's tag. */
.signal-note { margin-top: 6px; }

/* The two groups of signals on the case card: a clear gap above each group's heading. */
.card .signals-head { margin: 24px 0 10px; font-size: 14px; font-weight: 600; color: var(--neutral-900); }
.card .signals-head:first-of-type { margin-top: 16px; }
/* Four tiles a row on a wide screen, so seven tiles sit as four and three, not three, three and one. */
@media (min-width: 1280px) { .signals { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* ── Case card pictures: face against the document, registry cards, the map — compact, in the cabinet's own look ── */
.registry-pair { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr)); gap: 16px; margin-top: 16px; }
.registry-pair:empty { display: none; }
.registry-pair + .card { margin-top: 16px; }

.face-pair { display: grid; grid-template-columns: 140px minmax(160px, 320px) 140px; gap: 20px; align-items: center; justify-content: start; }
.face-shot { margin: 0; }
.face-shot img, .face-none { display: block; width: 100%; height: 170px; object-fit: cover; border-radius: var(--radius-md); background: #eef0f4; border: 1px solid var(--neutral-100-solid); }
.face-none { display: flex; align-items: center; justify-content: center; color: var(--neutral-500); font-size: 13px; }
.face-shot figcaption { margin-top: 8px; font-size: 12px; font-weight: 600; color: var(--neutral-600); text-align: center; }
.face-verdict { text-align: center; padding: 0 8px; }
.face-verdict p { margin: 10px 0 0; }
@media (max-width: 760px) { .face-pair { grid-template-columns: 1fr 1fr; } .face-verdict { grid-column: 1 / -1; grid-row: 2; } }

.id-card { background: var(--neutral-0); border: 1px solid var(--neutral-100-solid); border-top: 3px solid #12805c; border-radius: var(--radius-md); overflow: hidden; display: flex; flex-direction: column; }
.id-card.pacra { border-top-color: var(--brand-600); }
.id-top { display: flex; align-items: center; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--neutral-100-solid); }
.id-crest { flex: none; width: 32px; height: 32px; border-radius: 50%; background: #e7f6ef; color: #12805c; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 11px; letter-spacing: 0.04em; }
.pacra .id-crest { background: var(--brand-50); color: var(--brand-600); }
.id-country { font-size: 10.5px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--neutral-500); }
.id-title { font-size: 15px; font-weight: 600; color: var(--neutral-900); }
.id-status { margin-left: auto; padding: 3px 10px; border-radius: 999px; background: var(--status-success-bg); color: var(--status-success-text); font-size: 12px; font-weight: 600; }
.id-status.off { background: var(--status-danger-bg); color: var(--status-danger-text); }
.id-body { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 18px; padding: 16px 18px; flex: 1; }
.id-body.single { grid-template-columns: minmax(0, 1fr); }
.id-photo { width: 84px; height: 108px; border-radius: var(--radius-sm); overflow: hidden; border: 1px solid var(--neutral-100-solid); background: #eef0f4; display: flex; align-items: center; justify-content: center; font-size: 11px; color: var(--neutral-500); text-align: center; }
.id-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.id-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 20px; align-content: start; }
.id-field.wide { grid-column: 1 / -1; }
.id-label { font-size: 10.5px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--neutral-500); margin-bottom: 3px; }
.id-value { font-size: 14px; color: var(--neutral-900); overflow-wrap: anywhere; }
.id-field.big .id-value { font-size: 16px; font-weight: 600; }
.id-field.gold .id-value, .id-field.mono .id-value { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 14px; font-weight: 600; }
.id-empty { margin: 0; font-size: 14px; color: var(--neutral-600); }
.id-foot { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 8px 18px; background: var(--neutral-25); border-top: 1px solid var(--neutral-100-solid); font-size: 11px; color: var(--neutral-500); }
@media (max-width: 520px) { .id-fields { grid-template-columns: 1fr; } .id-body { grid-template-columns: 1fr; } }

.place-card .actions { display: flex; gap: 10px; align-items: center; }
.map-zoom { position: relative; }
.mz { position: absolute; opacity: 0; pointer-events: none; }
.map { position: relative; height: 420px; border-radius: var(--radius-md); overflow: hidden; border: 1px solid var(--neutral-100-solid); background: #e5e7eb; }
.mz-img { display: none; width: 100%; height: 100%; object-fit: cover; }
.mz-11:checked ~ .map .mz-img-11, .mz-13:checked ~ .map .mz-img-13, .mz-15:checked ~ .map .mz-img-15, .mz-17:checked ~ .map .mz-img-17 { display: block; }
.map-scale { position: absolute; top: 12px; right: 12px; display: flex; gap: 2px; padding: 3px; background: rgba(255, 255, 255, 0.95); border-radius: 999px; box-shadow: var(--shadow-sm); }
.mz-lbl { padding: 5px 12px; border-radius: 999px; font-size: 12px; font-weight: 600; color: var(--neutral-600); cursor: pointer; user-select: none; }
.mz-lbl:hover { color: var(--neutral-900); }
.mz-11:checked ~ .map .mz-lbl-11, .mz-13:checked ~ .map .mz-lbl-13, .mz-15:checked ~ .map .mz-lbl-15, .mz-17:checked ~ .map .mz-lbl-17 { background: var(--brand-600); color: #fff; }
.mz:focus-visible ~ .map .map-scale { box-shadow: var(--shadow-focus); }
.map-credit { position: absolute; right: 0; bottom: 0; padding: 2px 8px; background: rgba(255, 255, 255, 0.85); font-size: 11px; color: var(--neutral-600); border-top-left-radius: var(--radius-sm); }
@media (max-width: 700px) { .map { height: 300px; } .map-scale { left: 12px; right: auto; } }

/* Check tiles coloured by their result — green all well, red wrong, yellow look, grey not checked — with an icon. */
.signals > div { border-left-width: 3px; }
.signals > div:has(.pill.ok) { background: #f4fbf1; border-color: #d4efc7; border-left-color: #3f9a2a; }
.signals > div:has(.pill.bad) { background: #fdf4f5; border-color: #f6d3d8; border-left-color: #c8263f; }
.signals > div:has(.pill.warn) { background: #fffaeb; border-color: #f5e3a8; border-left-color: #c07a00; }
.signals .label { display: flex; align-items: center; gap: 6px; }
.check-ico { width: 15px; height: 15px; flex: none; color: var(--neutral-500); }
.signals > div:has(.pill.ok) .check-ico { color: #3f9a2a; }
.signals > div:has(.pill.bad) .check-ico { color: #c8263f; }
.signals > div:has(.pill.warn) .check-ico { color: #c07a00; }
.signals > div:has(.pill.ok) .pill.ok { background: #dcf5cf; }

/* The Ban block: closed until opened on purpose. */
.ban-card { padding: 0; }
.ban-card summary { display: flex; align-items: baseline; gap: 12px; padding: 16px 24px; cursor: pointer; list-style: none; }
.ban-card summary::-webkit-details-marker { display: none; }
.ban-card summary::before { content: '▸'; color: var(--neutral-500); font-size: 12px; transition: transform 120ms; }
.ban-card[open] summary::before { transform: rotate(90deg); }
.ban-title { font-size: 16px; font-weight: 600; color: var(--status-danger-text); }
.ban-body { padding: 0 24px 20px; border-top: 1px solid var(--neutral-100-solid); padding-top: 16px; }
.ban-choice { align-items: flex-start; gap: 10px; padding: 10px 12px; border: 1px solid var(--neutral-100-solid); border-radius: var(--radius-sm); background: var(--neutral-25); }
.ban-choice span { font-size: 13px; line-height: 1.45; }
.ban-standing { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--neutral-100-solid); font-size: 13px; }
.ban-standing:last-of-type { margin-bottom: 12px; }
