:root {
  --ink: #16231f;
  --muted: #66736e;
  --line: #dce4e0;
  --paper: #ffffff;
  --wash: #f4f7f5;
  --green: #087653;
  --green-dark: #075840;
  --green-soft: #e5f4ed;
  --blue-soft: #eaf2f8;
  --api: #1d5f9a;
  --api-dark: #174a78;
  --api-soft: #eaf2f8;
  --document: #6b4db5;
  --document-dark: #553991;
  --document-soft: #f1ecfa;
  --amber: #a96008;
  --amber-soft: #fff4df;
  --red: #b4232b;
  --red-soft: #feebec;
  --shadow: 0 14px 40px rgba(27, 55, 45, .07);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  color: var(--ink);
  background: var(--wash);
}

.login-page { display: grid; place-items: center; padding: 24px; }
.login-card { width: min(100%, 440px); padding: 32px; }
.login-card h1 { margin-top: 32px; }
.login-form { display: grid; gap: 18px; }
.login-form label { display: grid; gap: 8px; }
.login-form input { width: 100%; }
.password-card { max-width: 580px; margin: 24px auto; }
.account-menu { display: flex; align-items: center; gap: 12px; }
.account-menu form { margin: 0; }

* { box-sizing: border-box; }
html { min-height: 100%; }
body { margin: 0; min-height: 100vh; background: radial-gradient(circle at 95% 0, #e7f1ed 0, transparent 28rem), var(--wash); }
a { color: inherit; }
button, input, select, textarea { font: inherit; }
button, .button { -webkit-tap-highlight-color: transparent; }

.topbar { min-height: 72px; display: flex; align-items: center; gap: 34px; padding: 12px max(24px, calc((100vw - 1280px) / 2)); background: rgba(255,255,255,.94); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; backdrop-filter: blur(14px); }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; min-width: max-content; }
.brand-mark { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 11px; background: var(--ink); color: #fff; font-weight: 800; }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 15px; letter-spacing: .01em; }
.brand small { color: var(--muted); font-size: 10px; margin-top: 1px; }
nav { display: flex; gap: 2px; flex: 1; overflow-x: auto; }
nav a { padding: 9px 9px; border-radius: 8px; text-decoration: none; color: #41504a; font-size: 12px; white-space: nowrap; }
nav a:hover { background: var(--wash); color: var(--ink); }
.env { border-radius: 999px; padding: 7px 11px; font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; }
.env-local { color: #225b8c; background: var(--blue-soft); }
.env-sandbox { color: var(--amber); background: var(--amber-soft); }
.env-production { color: var(--red); background: var(--red-soft); }
.profile-context { display: grid; gap: 1px; max-width: 235px; text-decoration: none; text-transform: none; letter-spacing: 0; }
.profile-context span { overflow: hidden; text-overflow: ellipsis; font-size: 10px; }
.profile-context strong { font-size: 9px; text-transform: uppercase; letter-spacing: .05em; }

.page { width: min(1280px, calc(100% - 48px)); margin: 0 auto; padding: 42px 0 64px; }
footer { width: min(1280px, calc(100% - 48px)); margin: 0 auto; padding: 22px 0 30px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; color: var(--muted); font-size: 12px; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(30px, 4vw, 48px); letter-spacing: -.045em; line-height: 1.05; margin-bottom: 14px; }
h2 { font-size: 21px; letter-spacing: -.025em; line-height: 1.25; margin-bottom: 14px; }
h3 { line-height: 1.35; }
p { color: var(--muted); line-height: 1.65; }
.eyebrow { color: var(--green); font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; margin: 0 0 8px; }
.eyebrow.light { color: #9fe3ca; }
.mono { font-family: "Cascadia Mono", Consolas, monospace; letter-spacing: .015em; }
.text-link, .row-link { color: var(--green-dark); font-weight: 700; text-decoration: none; }
.text-link:hover, .row-link:hover { text-decoration: underline; }
.breadcrumbs { display: flex; gap: 8px; color: var(--muted); font-size: 12px; margin-bottom: 15px; }

.hero { min-height: 255px; padding: 48px; border-radius: 25px; color: #fff; background: linear-gradient(120deg, #132721 0%, #0a5943 65%, #087653 100%); display: flex; align-items: end; justify-content: space-between; gap: 30px; box-shadow: var(--shadow); overflow: hidden; position: relative; }
.hero::after { content: "00"; position: absolute; right: 8%; top: -46px; color: rgba(255,255,255,.045); font-weight: 900; font-size: 210px; line-height: 1; }
.hero > * { position: relative; z-index: 1; }
.hero h1 { max-width: 780px; }
.hero p { max-width: 700px; color: #c5d8d1; margin-bottom: 0; }
.hero .eyebrow { color: #9fe3ca; }

.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 15px; margin: 20px 0; }
.stat { background: var(--paper); border: 1px solid var(--line); border-radius: 15px; padding: 22px; box-shadow: 0 4px 15px rgba(27,55,45,.03); }
.stat strong { font-size: 32px; letter-spacing: -.04em; display: block; }
.stat span { color: var(--muted); font-size: 12px; }

.card { background: var(--paper); border: 1px solid var(--line); border-radius: 18px; padding: 26px; box-shadow: 0 5px 20px rgba(27,55,45,.035); margin-bottom: 20px; }
.section-head { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 18px; }
.section-head h2, .section-head h3, .section-head p { margin-bottom: 0; }
.page-head { display: flex; justify-content: space-between; align-items: end; margin: 0 0 30px; }
.page-head p { max-width: 760px; margin-bottom: 0; }
.page-head h1 { margin-bottom: 12px; }
.session-head { display: flex; align-items: center; justify-content: space-between; gap: 30px; margin-bottom: 28px; }
.session-head h1 { margin-bottom: 10px; }
.session-head p { margin-bottom: 0; }
.count-badge { min-width: 30px; padding: 6px 9px; text-align: center; border-radius: 999px; background: var(--wash); color: var(--muted); font-size: 12px; font-weight: 700; }
.step { display: inline-grid; place-items: center; min-width: 29px; height: 29px; padding: 0 7px; margin-right: 9px; border-radius: 8px; background: var(--green-soft); color: var(--green); font-weight: 800; font-size: 12px; vertical-align: middle; }

.button { border: 0; border-radius: 9px; padding: 11px 16px; min-height: 42px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; font-size: 13px; font-weight: 750; text-decoration: none; cursor: pointer; transition: transform .12s, background .12s, opacity .12s; }
.button:hover:not(:disabled) { transform: translateY(-1px); }
.button:disabled { cursor: not-allowed; opacity: .42; }
.button-primary { color: #fff; background: var(--green); }
.button-primary:hover { background: var(--green-dark); }
.button-secondary { color: var(--green-dark); background: var(--green-soft); }
.button-api { color: #fff; background: var(--api); }
.button-api:hover { background: var(--api-dark); }
.button-api-soft { color: var(--api-dark); background: var(--api-soft); border: 1px solid #cadeec; }
.button-api-soft:hover { background: #dcebf5; }
.button-document { color: #fff; background: var(--document); }
.button-document:hover { background: var(--document-dark); }
.button-document-soft { color: var(--document-dark); background: var(--document-soft); border: 1px solid #ddd2f2; }
.button-document-soft:hover { background: #e7def6; }
.button-ghost { color: var(--ink); background: #fff; border: 1px solid var(--line); }
.button-danger { color: var(--red); background: var(--red-soft); }
.button-light { color: var(--green-dark); background: #fff; }
.button-test { color: #d7f9ec; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.2); }
.button-dark-ghost { color: #d7e4df; background: transparent; border: 1px solid rgba(255,255,255,.2); }
.button-accent { color: #0c4636; background: #9fe3ca; }
.button-small { min-height: 32px; padding: 6px 9px; font-size: 11px; }
.button-wide { width: 100%; margin-top: 6px; }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }
.form-actions.centered { justify-content: center; }

[hidden] { display: none !important; }
label { display: grid; gap: 7px; color: #33423c; font-size: 13px; line-height: 1.4; font-weight: 700; }
input, select, textarea { width: 100%; min-height: 43px; border: 1px solid #cad5d0; border-radius: 9px; background: #fff; color: var(--ink); padding: 9px 11px; outline: none; }
input:focus, select:focus, textarea:focus { border-color: var(--green); box-shadow: 0 0 0 3px rgba(8,118,83,.1); }
label small, .form-card > small, .upload-card > small { color: var(--muted); font-size: 11px; font-weight: 400; line-height: 1.5; }
.check { display: flex; align-items: center; gap: 9px; min-height: 43px; }
.check input { min-height: auto; width: 17px; height: 17px; accent-color: var(--green); }
.form-card { display: grid; gap: 17px; align-content: start; margin: 0; }
.form-card .section-head { margin-bottom: 2px; }
.settings-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.settings-grid > .form-actions { grid-column: 1 / -1; }
.local-settings-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.field-pair { display: grid; grid-template-columns: 1fr 1.6fr; gap: 11px; }
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 17px; padding-top: 25px; }
.form-grid.single { grid-template-columns: 1fr; }
.span-2 { grid-column: 1 / -1; }
.narrow { max-width: 680px; margin-left: auto; margin-right: auto; }
.create-panel { padding: 0; overflow: hidden; }
.create-panel summary { display: flex; align-items: center; justify-content: space-between; padding: 22px 26px; cursor: pointer; list-style: none; }
.create-panel summary::-webkit-details-marker { display: none; }
.create-panel[open] summary { border-bottom: 1px solid var(--line); }
.create-panel form { padding: 5px 26px 26px; }
.summary-hint { color: var(--muted); font-size: 12px; }

.split-layout { display: grid; grid-template-columns: minmax(300px, .8fr) minmax(460px, 1.2fr); gap: 20px; align-items: start; }
.upload-card { display: grid; gap: 17px; }
.file-drop { border: 1px dashed #a9bcb4; border-radius: 12px; background: var(--wash); padding: 18px; cursor: pointer; }
.file-drop input { min-height: auto; border: 0; padding: 0 0 10px; background: transparent; }
.file-drop span { color: var(--muted); font-weight: 400; }
.list-stack { display: grid; }
.list-item { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 0; border-top: 1px solid var(--line); }
.list-item:first-child { border-top: 0; padding-top: 0; }
.list-item:last-child { padding-bottom: 0; }
.list-item p { margin: 4px 0 0; font-size: 12px; }

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th { padding: 10px 12px; color: var(--muted); border-bottom: 1px solid var(--line); font-size: 10px; text-transform: uppercase; letter-spacing: .07em; }
td { padding: 14px 12px; border-bottom: 1px solid #edf1ef; font-size: 13px; vertical-align: middle; }
tbody tr:last-child td { border-bottom: 0; }
td small { display: block; margin-top: 4px; color: var(--muted); font-size: 10px; }
.compact td { padding-top: 9px; padding-bottom: 9px; font-size: 11px; }

.status, .validation { display: inline-flex; align-items: center; width: max-content; padding: 5px 8px; border-radius: 999px; font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .035em; }
.status-open { color: var(--green-dark); background: var(--green-soft); }
.status-closed { color: #52605b; background: #edf1ef; }
.status-working { color: var(--green-dark); background: var(--green-soft); }
.status-reserved { color: var(--amber); background: var(--amber-soft); }
.status-printed { color: var(--api-dark); background: var(--api-soft); }
.status-cancelled { color: var(--red); background: var(--red-soft); }
.catalog-status-matches { color: var(--green-dark); background: var(--green-soft); }
.catalog-status-local-changes { color: var(--amber); background: var(--amber-soft); }
.catalog-status-not-synced { color: #52605b; background: #edf1ef; }
.status-large { padding: 8px 12px; }
.validation-valid, .validation-allowed { color: var(--green-dark); background: var(--green-soft); }
.validation-invalid, .validation-missing { color: var(--red); background: var(--red-soft); }
.validation-not_checked { color: #52605b; background: #edf1ef; }
.validation-success, .validation-sent, .validation-connected, .validation-accepted { color: var(--green-dark); background: var(--green-soft); }
.validation-error { color: var(--red); background: var(--red-soft); }
.validation-not_sent, .validation-draft { color: #52605b; background: #edf1ef; }

.scanner-card { border-radius: 20px; background: linear-gradient(115deg, #122b23, #075840); color: #fff; display: grid; grid-template-columns: 1fr 300px; box-shadow: var(--shadow); margin-bottom: 20px; overflow: hidden; }
.scanner-main { padding: 30px; }
.scanner-aside { padding: 30px 25px; background: rgba(0,0,0,.12); display: flex; flex-direction: column; gap: 10px; }
.scanner-aside form, .scanner-aside .button { width: 100%; }
.scanner-title { display: flex; justify-content: space-between; align-items: baseline; gap: 20px; }
.scanner-title h2 { font-size: 27px; margin-bottom: 12px; }
.scanner-title > span { color: #b7d8cc; }
.scanner-title > span strong { color: #fff; font-size: 25px; }
.progress { height: 6px; background: rgba(255,255,255,.15); border-radius: 99px; margin-bottom: 23px; overflow: hidden; }
.progress span { display: block; height: 100%; background: #9fe3ca; border-radius: inherit; transition: width .2s; }
.scanner-main label { color: #b7d8cc; }
.scan-input-row { display: grid; grid-template-columns: 1fr auto; gap: 8px; }
.scan-input-row input { height: 53px; border: 0; font-family: "Cascadia Mono", Consolas, monospace; }
.scan-message { min-height: 20px; color: #b7d8cc; font-size: 12px; padding-top: 10px; }
.scan-message.ok { color: #9fe3ca; }
.scan-message.error { color: #ffb9bd; }
.temporary-scanner-card .scanner-aside small { color: #cfe5dd; line-height: 1.45; }
.temporary-scan-table table { min-width: 1380px; }
.temporary-duplicate-row { background: #fff9e8; }
.temporary-duplicate-row:hover { background: #fff3cf; }
.import-group-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px; }
.import-code-list { display: grid; gap: 5px; padding-top: 10px; font-size: 11px; }
.import-issues ul { margin: 10px 0 0 20px; display: grid; gap: 5px; }
.import-session-origin small { display: block; margin-top: 6px; overflow-wrap: anywhere; }
.mini-label { color: #a9c9be; font-size: 10px; text-transform: uppercase; letter-spacing: .07em; }
.scanner-aside > strong { font-size: 10px; word-break: break-all; min-height: 31px; color: #e6f2ee; }

.workspace-grid { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 20px; align-items: start; }
.print-workspace { grid-template-columns: minmax(330px, .75fr) minmax(0, 1.25fr); }
.tab-row { display: flex; gap: 8px; margin: -12px 0 20px; }
.filter-bar, .filter-grid { display: grid; grid-template-columns: minmax(180px, .75fr) minmax(260px, 1.25fr) auto; align-items: end; gap: 12px; }
.organization-filters { grid-template-columns: minmax(180px, 1fr) minmax(160px, .65fr) auto auto; }
.filter-grid { grid-template-columns: repeat(3, minmax(180px, 1fr)); }
.pool-create-actions { display: flex; align-items: end; gap: 9px; flex-wrap: wrap; margin: 18px 0; padding: 14px; border-radius: 12px; background: var(--wash); }
.pool-create-actions .inline-form { margin-top: 0; }
.order-choice { grid-template-columns: minmax(0, 1fr) minmax(125px, auto); padding: 14px; border: 1px solid transparent; border-radius: 12px; text-decoration: none; }
.order-choice.is-selected { border-color: #b7dacd; background: var(--green-soft); }
.order-choice .container-state { text-align: right; }
.detail-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin: 16px 0; }
.detail-grid > div { min-width: 0; padding: 13px; border-radius: 11px; background: var(--wash); }
.detail-grid span, .detail-grid small { display: block; color: var(--muted); font-size: 10px; }
.detail-grid strong { display: block; margin-top: 5px; font-size: 12px; overflow-wrap: anywhere; }
.integrity-card { display: grid; gap: 10px; margin: 18px 0; padding: 16px; border: 1px solid #d7ccef; border-radius: 12px; background: var(--document-soft); }
.integrity-card span { display: block; color: var(--muted); font-size: 10px; }
.integrity-card strong, .integrity-card code { display: block; margin-top: 4px; overflow-wrap: anywhere; }
.pool-picker { display: grid; gap: 7px; padding: 15px; border: 1px solid var(--line); border-radius: 12px; }
.pool-picker legend { padding: 0 7px; color: #33423c; font-size: 13px; font-weight: 700; }
.pool-option { padding: 7px 9px; border-radius: 9px; background: var(--wash); }
.pagination { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 18px; color: var(--muted); font-size: 11px; }
.side-stack { display: grid; gap: 0; }
.side-stack .card p { font-size: 13px; }
.xml-action-block { display: grid; gap: 12px; padding: 16px 0; border-top: 1px solid var(--line); }
.xml-action-block:first-of-type { border-top: 0; padding-top: 4px; }
.xml-action-block h3 { margin: 0; font-size: 14px; }
.xml-action-block form { display: grid; gap: 12px; }
.container-list { display: grid; }
.container-row { display: grid; grid-template-columns: 38px 1fr 85px 92px auto; align-items: center; gap: 12px; min-height: 70px; padding: 12px 0; border-top: 1px solid var(--line); }
.container-row.suz-session-row { grid-template-columns: minmax(220px, 1fr) auto auto; }
.container-row:first-child { border-top: 0; }
.row-card-link { color: inherit; text-decoration: none; border-radius: 10px; transition: background .15s ease, box-shadow .15s ease; }
.row-card-link:hover, .row-card-link:focus-visible { margin-inline: -10px; padding-inline: 10px; background: var(--wash); box-shadow: 0 0 0 1px var(--line); outline: 0; }
.is-muted { opacity: .64; }
.profile-badges { display: flex !important; flex-wrap: wrap; gap: 5px; margin-top: 6px; }
.profile-badges .env { display: inline-flex; margin-left: 0; padding: 3px 7px; font-size: 8px; }
.container-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; color: var(--green); background: var(--green-soft); font-weight: 900; font-size: 11px; }
.level-2 .container-icon { color: #285e8c; background: var(--blue-soft); }
.container-info strong, .container-info span, .container-count strong, .container-count span { display: block; }
.container-info span { margin-top: 4px; color: var(--muted); font-size: 10px; }
.container-count { text-align: right; }
.container-count strong { font-size: 16px; }
.container-count span { color: var(--muted); font-size: 9px; }
.container-state small { display: block; margin-top: 4px; color: var(--muted); font-size: 9px; }
.row-actions { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.row-actions form { display: inline-flex; }
.inline-form { display: flex; align-items: end; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.inline-form label { min-width: 130px; }
.inline-form input { min-height: 34px; }
.split-actions { display: flex; justify-content: space-between; align-items: end; gap: 16px; flex-wrap: wrap; margin: 18px 0; }
.secret-form { margin-top: 10px; }
.small-mono { display: block; font-size: 10px; word-break: break-all; }
.metric-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 16px 0; }
.metric-grid article { min-width: 0; padding: 14px; border-radius: 11px; background: var(--wash); }
.metric-grid span, .metric-grid small { display: block; color: var(--muted); font-size: 9px; }
.metric-grid strong { display: block; margin: 5px 0; font-size: 12px; }
.inline-action { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 20px; padding: 17px; border-radius: 12px; background: var(--wash); }
.inline-action p { margin: 4px 0 0; font-size: 11px; }
.export-mini-list { margin-top: 16px; border-top: 1px solid var(--line); }
.export-mini-list > a, .export-mini-list > div { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 11px 0; text-decoration: none; font-size: 12px; line-height: 1.45; border-bottom: 1px solid #edf1ef; }

.notice { border-radius: 12px; padding: 16px 18px; color: #40504a; font-size: 13px; line-height: 1.6; margin: 20px 0; }
.notice-info { background: var(--blue-soft); border: 1px solid #d4e3ee; }
.notice-success { color: var(--green-dark); background: var(--green-soft); border: 1px solid #cae8da; }
.notice-soft { background: var(--wash); margin: 0; }
.text-error { color: var(--red) !important; }
.flash-stack {
  position: fixed;
  right: max(24px, calc((100vw - 1280px) / 2));
  bottom: 24px;
  z-index: 100;
  display: grid;
  gap: 8px;
  width: min(440px, calc(100vw - 48px));
  pointer-events: none;
}
.flash { padding: 13px 16px; border-radius: 10px; font-size: 12px; font-weight: 650; border: 1px solid transparent; box-shadow: var(--shadow); pointer-events: auto; }
.flash-success { color: var(--green-dark); background: var(--green-soft); border-color: #cae8da; }
.flash-warning { color: var(--amber); background: var(--amber-soft); border-color: #f1ddb9; }
.flash-error { color: var(--red); background: var(--red-soft); border-color: #f1cacc; }
.empty { padding: 36px 20px; text-align: center; color: var(--muted); background: var(--wash); border-radius: 12px; }
.empty strong { color: var(--ink); }
.empty p { font-size: 12px; margin: 6px 0 0; }

.result-card { max-width: 780px; margin: 25px auto 20px; padding: 50px; border-radius: 22px; text-align: center; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow); }
.result-icon { display: grid; place-items: center; width: 62px; height: 62px; margin: 0 auto 20px; border-radius: 50%; font-size: 29px; font-weight: 800; }
.result-ok .result-icon { color: var(--green); background: var(--green-soft); }
.result-bad .result-icon { color: var(--red); background: var(--red-soft); }
.result-card h1 { font-size: 35px; }
.filename { word-break: break-all; font-size: 12px; }
.result-stats { display: grid; grid-template-columns: repeat(3, 1fr); margin: 25px 0; border: 1px solid var(--line); border-radius: 13px; overflow: hidden; }
.result-stats span { padding: 17px; color: var(--muted); font-size: 11px; border-left: 1px solid var(--line); }
.result-stats span:first-child { border-left: 0; }
.result-stats strong { display: block; color: var(--ink); font-size: 18px; }
.result-send-form { display: flex; justify-content: center; align-items: center; gap: 10px; max-width: 590px; margin: 20px auto 0; padding-top: 20px; border-top: 1px solid var(--line); }
.error-list { margin: 20px 0; padding: 13px; text-align: left; border-radius: 10px; background: var(--red-soft); }
.error-list p { color: var(--red); margin: 5px; font-size: 11px; }
.danger-zone { text-align: center; padding: 15px; }
.text-danger { border: 0; background: transparent; color: var(--red); font-size: 11px; text-decoration: underline; cursor: pointer; }

.pin-dialog { width: min(470px, calc(100vw - 32px)); max-width: none; padding: 0; border: 0; border-radius: 18px; color: var(--ink); background: #fff; box-shadow: 0 24px 80px rgba(13, 35, 28, .24); }
.pin-dialog::backdrop { background: rgba(12, 27, 22, .58); backdrop-filter: blur(3px); }
.pin-dialog-form { display: grid; gap: 19px; margin: 0; padding: 28px; }
.pin-dialog-head { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; align-items: center; }
.pin-dialog-icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; color: #fff; background: var(--api); font-size: 11px; font-weight: 850; letter-spacing: .04em; }
.pin-dialog-icon-warning { background: #9a6400; }
.pin-dialog-head .eyebrow { margin-bottom: 4px; color: var(--api); }
.pin-dialog-head h2 { margin: 0; font-size: 22px; }
.pin-dialog-description { margin: -4px 0 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.pin-dialog label { font-size: 12px; }
.pin-dialog input { font-family: "Cascadia Mono", Consolas, monospace; font-size: 18px; letter-spacing: .08em; }
.pin-dialog-note { display: block; margin-top: -10px; color: var(--muted); font-size: 10px; line-height: 1.5; }
.pin-dialog .form-actions { padding-top: 2px; }

code { padding: 1px 4px; border-radius: 4px; background: #edf2ef; color: #25463a; font-family: "Cascadia Mono", Consolas, monospace; font-size: .92em; }
.field-help { display: block; margin-top: 10px; color: var(--muted); font-size: 10px; line-height: 1.45; }
.form-grid > .field-help { margin-top: -9px; }
.sscc-mdlp-actions { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 10px; margin: 16px 0; }
.sscc-mdlp .button { max-width: 100%; min-width: 0; white-space: normal; text-align: center; }
.sscc-mdlp .form-actions > form { max-width: 100%; min-width: 0; }
.field-help-inline { display: flex; align-items: center; min-height: 22px; margin-top: -9px; }
.field-label { display: flex; align-items: center; gap: 7px; min-width: 0; }
.field-control { position: relative; min-width: 0; }
.field-control > label > .field-label { min-height: 20px; padding-right: 28px; }
.field-control > .field-help-button { position: absolute; top: 0; right: 0; z-index: 1; }
.inline-form .field-control { min-width: 130px; }
.inline-form .field-control label { min-width: 0; }
.field-help-button, .help-tip { display: inline-grid; place-items: center; flex: 0 0 auto; width: 20px; height: 20px; min-height: 20px; padding: 0; border: 1px solid #a8c4b9; border-radius: 50%; color: var(--green-dark); background: #fff; font-family: Georgia, serif; font-size: 12px; font-weight: 800; line-height: 1; cursor: pointer; }
.field-help-button:hover, .help-tip:hover { color: #fff; border-color: var(--green); background: var(--green); }
.field-help-button:focus-visible, .help-tip:focus-visible { outline: 0; box-shadow: 0 0 0 3px rgba(8,118,83,.16); }
.help-dialog { width: min(560px, calc(100vw - 32px)); max-width: none; padding: 0; border: 0; border-radius: 18px; color: var(--ink); background: #fff; box-shadow: 0 24px 80px rgba(13, 35, 28, .24); }
.help-dialog::backdrop { background: rgba(12, 27, 22, .5); backdrop-filter: blur(3px); }
.help-dialog-form { display: grid; gap: 20px; margin: 0; padding: 28px; }
.help-dialog-head { display: grid; grid-template-columns: 44px minmax(0, 1fr) 32px; gap: 14px; align-items: center; }
.help-dialog-icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; color: #fff; background: var(--green); font-family: Georgia, serif; font-size: 23px; font-weight: 800; }
.help-dialog-head .eyebrow { margin-bottom: 4px; }
.help-dialog-head h2 { margin: 0; font-size: 22px; }
.help-dialog-close { align-self: start; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 8px; color: var(--muted); background: var(--wash); font-size: 22px; line-height: 1; cursor: pointer; }
.help-dialog-close:hover { color: var(--ink); background: var(--green-soft); }
.help-dialog-close:focus-visible { outline: 0; box-shadow: 0 0 0 3px rgba(8,118,83,.16); }
.help-dialog-body { color: #33423c; font-size: 14px; line-height: 1.65; overflow-wrap: anywhere; }
.help-dialog-body p { margin: 0 0 13px; color: inherit; }
.help-dialog-body p:last-child { margin-bottom: 0; }
.help-dialog-body a { color: var(--green-dark); font-weight: 750; }
.help-dialog .form-actions { padding-top: 2px; }
.scanner-help { display: block; padding-top: 7px; color: #b7d8cc; font-size: 10px; line-height: 1.4; }

.help-hero { min-height: 235px; margin-bottom: 16px; padding: 38px 42px; border-radius: 22px; background: linear-gradient(120deg, #132721, #075840); color: #fff; display: grid; grid-template-columns: minmax(0, 1fr) 310px; align-items: center; gap: 45px; box-shadow: var(--shadow); }
.help-hero h1 { max-width: 820px; margin-bottom: 13px; font-size: clamp(30px, 3.7vw, 46px); }
.help-hero p { margin: 0; color: #c5d8d1; }
.help-hero-note { padding: 18px; border: 1px solid rgba(255,255,255,.16); border-radius: 13px; background: rgba(255,255,255,.08); }
.help-hero-note strong, .help-hero-note span { display: block; }
.help-hero-note strong { margin-bottom: 7px; color: #9fe3ca; font-size: 11px; text-transform: uppercase; letter-spacing: .07em; }
.help-hero-note span { color: #e4f0ec; font-size: 12px; line-height: 1.5; }
.help-toc { display: flex; gap: 7px; margin-bottom: 20px; padding: 10px; overflow-x: auto; background: #fff; border: 1px solid var(--line); border-radius: 13px; box-shadow: 0 4px 15px rgba(27,55,45,.03); }
.help-toc a { flex: 0 0 auto; padding: 8px 11px; border-radius: 8px; color: #41504a; text-decoration: none; font-size: 11px; font-weight: 700; }
.help-toc a:hover { color: var(--green-dark); background: var(--green-soft); }
.help-section { scroll-margin-top: 95px; }
.help-section > .section-head { margin-bottom: 26px; padding-bottom: 18px; border-bottom: 1px solid var(--line); align-items: center; }
.help-section > .section-head > div:has(> .step) { display: flex; align-items: center; gap: 12px; }
.help-section > .section-head > div:has(> .step) .step { flex: 0 0 auto; margin-right: 0; }
.help-section > .section-head > div:has(> .step) h2 { margin: 0; }
.help-section > .section-head .eyebrow { margin-bottom: 10px; }
.help-section > .section-head h2 { margin: 0; line-height: 1.25; }
.help-section > .section-head + p { margin-bottom: 24px; }
.help-section > p { max-width: 900px; font-size: 13px; line-height: 1.65; }
.help-section .notice strong { display: block; margin-bottom: 6px; }

.data-flow { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr auto 1fr; align-items: center; gap: 10px; margin: 22px 0; }
.data-flow article { min-height: 120px; padding: 17px; border: 1px solid var(--line); border-radius: 13px; background: var(--wash); }
.data-flow strong, .data-flow small { display: block; }
.data-flow strong { margin: 14px 0 7px; font-size: 13px; line-height: 1.35; }
.data-flow small { color: var(--muted); font-size: 10px; line-height: 1.4; }
.flow-number { display: grid; place-items: center; width: 25px; height: 25px; border-radius: 7px; background: var(--green); color: #fff; font-size: 10px; font-weight: 800; }
.flow-arrow { color: #91a69d; font-size: 20px; }
.output-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 11px; }
.output-grid article { display: flex; align-items: center; gap: 13px; padding: 15px; border-radius: 12px; background: var(--green-soft); }
.output-grid strong { display: block; font-size: 12px; }
.output-grid p { margin: 3px 0 0; font-size: 10px; }
.document-badge { display: inline-grid; place-items: center; min-width: 43px; height: 31px; padding: 0 8px; border-radius: 7px; background: var(--green); color: #fff; font-family: "Cascadia Mono", Consolas, monospace; font-size: 11px; font-weight: 800; }

.code-anatomy { display: flex; align-items: stretch; margin: 22px 0; overflow-x: auto; padding-bottom: 5px; }
.code-anatomy > span { flex: 0 0 auto; min-height: 66px; display: flex; flex-direction: column; justify-content: center; padding: 10px 13px; border: 1px solid #cddbd5; border-left: 0; font-family: "Cascadia Mono", Consolas, monospace; font-size: 15px; font-weight: 800; }
.code-anatomy > span:first-child { border-left: 1px solid #cddbd5; border-radius: 10px 0 0 10px; }
.code-anatomy > span:last-child { border-radius: 0 10px 10px 0; }
.code-anatomy small { display: block; margin-top: 7px; color: var(--muted); font-family: Inter, "Segoe UI", sans-serif; font-size: 8px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.code-ai { background: #e6f2fa; color: #285e8c; }
.code-gtin { background: #eff7f3; color: var(--green-dark); }
.code-serial { background: #fff8e9; color: #85531a; }
.code-gs { background: #f0edf7; color: #5b4981; }
.code-crypto { background: #f4f5f4; color: #56615d; }
.help-grid { display: grid; gap: 12px; }
.help-grid.two { grid-template-columns: repeat(2, 1fr); }
.help-grid.three { grid-template-columns: repeat(3, 1fr); }
.definition-card { padding: 19px; border: 1px solid var(--line); border-radius: 13px; background: #fff; }
.definition-card.emphasis { border-color: #bcdccc; background: var(--green-soft); }
.definition-card strong { display: block; margin: 11px 0 9px; font-size: 13px; line-height: 1.4; }
.definition-card p { margin: 0; font-size: 11px; line-height: 1.55; }
.definition-card > summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; cursor: pointer; list-style: none; }
.definition-card > summary::-webkit-details-marker { display: none; }
.definition-card > summary strong { margin: 0 0 4px; }
.definition-card > summary small { display: block; }
.nested-editor { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.nested-editor > summary { display: flex; align-items: center; gap: 8px; cursor: pointer; color: var(--green-dark); list-style: none; }
.nested-editor > summary::-webkit-details-marker { display: none; }
.nested-editor[open] > summary { margin-bottom: 14px; }
.nested-editor .form-grid { padding-top: 14px; }
.nested-editor .notice, .nested-editor .flash { margin: 12px 0; }
.profile-grid { grid-template-columns: 1fr; }
.sscc-preview { display: grid; gap: 13px; padding: 18px; border: 1px solid #cbded6; border-radius: 14px; background: linear-gradient(135deg, #f8fbfa, #eef7f3); }
.sscc-preview-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.sscc-preview-head h4 { margin: 0; font-size: 15px; line-height: 1.35; }
.sscc-preview-head > span { padding: 5px 8px; border-radius: 999px; color: var(--green-dark); background: var(--green-soft); font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; white-space: nowrap; }
.sscc-preview-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.sscc-preview-card { min-width: 0; padding: 14px; border: 1px solid var(--line); border-radius: 11px; background: #fff; }
.sscc-preview-card.is-invalid { border-color: #e9b8bb; background: #fffafa; }
.sscc-preview-card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.sscc-preview-card-head strong { margin: 0; font-size: 12px; }
.sscc-preview-card-head small { color: var(--muted); font-size: 9px; }
.sscc-preview-code { display: flex; align-items: center; gap: 5px; margin: 13px 0 9px; overflow-x: auto; white-space: nowrap; }
.sscc-preview-code code { display: flex; font-family: "Cascadia Mono", Consolas, monospace; font-size: clamp(14px, 1.45vw, 19px); font-weight: 800; letter-spacing: .02em; }
.sscc-ai { flex: 0 0 auto; color: var(--muted); font-family: "Cascadia Mono", Consolas, monospace; font-size: 11px; }
.sscc-segment { padding: 4px 1px; border-bottom: 3px solid transparent; }
.sscc-segment-extension { color: var(--amber); border-color: #d79a4b; }
.sscc-segment-issuer { color: var(--api-dark); border-color: #76a8ce; }
.sscc-segment-serial { color: var(--green-dark); border-color: #65b898; }
.sscc-segment-check { color: var(--document-dark); border-color: #9d88d0; }
.sscc-preview-legend { display: flex; flex-wrap: wrap; gap: 6px 10px; color: var(--muted); font-size: 8px; }
.sscc-preview-legend span { display: inline-flex; align-items: center; gap: 4px; }
.sscc-preview-legend i { width: 7px; height: 7px; border-radius: 2px; }
.sscc-key-extension { background: #d79a4b; }
.sscc-key-issuer { background: #76a8ce; }
.sscc-key-serial { background: #65b898; }
.sscc-key-check { background: #9d88d0; }
.sscc-preview-card > p { min-height: 17px; margin: 10px 0 0; color: var(--muted); font-family: "Cascadia Mono", Consolas, monospace; font-size: 10px; line-height: 1.55; overflow-wrap: anywhere; }
.sscc-preview-card > p.text-error { color: var(--red); font-family: inherit; }
.sscc-preview-note { margin: 0; padding-top: 2px; font-size: 10px; line-height: 1.6; }
.sscc-preview-note a { color: var(--green-dark); font-weight: 750; }
.sscc-range-overview { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; margin-top: 14px; }
.sscc-range-overview article { min-width: 0; padding: 13px; border-radius: 11px; background: var(--wash); }
.sscc-range-overview span, .sscc-range-overview small { display: block; color: var(--muted); font-size: 9px; line-height: 1.5; }
.sscc-range-overview strong { display: block; margin: 5px 0; font-size: 18px; }
.sscc-range-overview small .mono { color: var(--ink); overflow-wrap: anywhere; }
.sscc-history-entry .button { margin-top: 9px; }
.sscc-history-filters { grid-template-columns: minmax(180px, .8fr) minmax(180px, .8fr) minmax(260px, 1.4fr) auto; }
.sscc-history-table td:first-child { min-width: 205px; }
.sscc-history-table td:first-child strong { white-space: nowrap; }
.definition-label { color: var(--green); font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; }
.break-all { word-break: break-all; }
.compare-strip { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px; margin-top: 14px; padding: 18px; border-radius: 13px; background: var(--amber-soft); }
.compare-strip > span { color: var(--amber); font-size: 25px; font-weight: 800; }
.compare-strip article > strong, .compare-strip article > span { display: block; }
.compare-strip article > span { margin: 5px 0; color: #68481e; font-size: 12px; }
.compare-strip p { margin: 0; font-size: 10px; }

.help-table td { min-width: 145px; line-height: 1.45; vertical-align: top; }
.help-table td:first-child { min-width: 170px; }
.help-table th { white-space: nowrap; }
.instruction-card { position: relative; min-height: 150px; padding: 20px; border: 1px solid var(--line); border-radius: 13px; background: var(--wash); }
.instruction-card > span { display: grid; place-items: center; width: 27px; height: 27px; margin-bottom: 13px; border-radius: 8px; color: #fff; background: var(--green); font-size: 10px; font-weight: 800; }
.instruction-card strong { display: block; margin-bottom: 9px; font-size: 13px; line-height: 1.4; }
.instruction-card p { margin: 0; font-size: 11px; line-height: 1.55; }
.check-list { display: grid; gap: 9px; margin: 15px 0 20px; padding: 0; list-style: none; counter-reset: checks; }
.check-list li { position: relative; min-height: 76px; padding: 16px 18px 16px 56px; border: 1px solid var(--line); border-radius: 11px; color: var(--muted); font-size: 13px; line-height: 1.6; counter-increment: checks; }
.check-list li::before { content: counter(checks); position: absolute; left: 15px; top: 16px; display: grid; place-items: center; width: 25px; height: 25px; border-radius: 7px; background: var(--green-soft); color: var(--green); font-size: 9px; font-weight: 800; }
.check-list strong { display: block; margin-bottom: 8px; color: var(--ink); font-size: 13px; line-height: 1.35; }
.check-list li > span { display: block; }
.check-list.horizontal-flow { grid-template-columns: repeat(4, 1fr); }

.status-summary { display: grid; gap: 5px; margin: 16px 0; padding: 14px; border-radius: 11px; background: var(--wash); }
.status-summary span { color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .07em; }
.status-summary strong { font-size: 13px; line-height: 1.45; }

.post-close-hub { padding: 30px; }
.post-close-grid { display: grid; grid-template-columns: 1fr; gap: 18px; align-items: start; }
.workflow-step-card { min-width: 0; padding: 20px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.workflow-step-card > p { font-size: 13px; line-height: 1.65; }
.step-title { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 17px; padding-bottom: 15px; border-bottom: 1px solid var(--line); }
.step-title .step { flex: 0 0 auto; margin-right: 0; }
.step-title h3 { margin: 3px 0 0; font-size: 16px; }
.step-title .eyebrow { font-size: 9px; }
.action-form { display: grid; gap: 14px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); }
.action-form + .action-form { margin-top: 16px; }
.action-form h4 { margin: 0; font-size: 14px; line-height: 1.45; }
.compact-form { grid-template-columns: minmax(240px, 1fr) auto; align-items: end; }
.field-note { padding: 13px 14px; border-radius: 10px; background: var(--wash); font-size: 12px !important; }
.field-note strong { color: var(--ink); }

.session-subpanel { margin: 20px 0; border: 1px solid var(--line); border-radius: 13px; overflow: hidden; }
.session-subpanel > summary { display: flex; align-items: center; gap: 10px; padding: 17px 19px; cursor: pointer; list-style: none; background: var(--wash); }
.session-subpanel > summary::-webkit-details-marker { display: none; }
.session-subpanel[open] > summary { border-bottom: 1px solid var(--line); }
.session-subpanel > form { padding: 4px 20px 20px; }
.subpanel-body { padding: 4px 20px 20px; }
.copy-field-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 18px 0; }
.copy-field-list > div { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 7px; align-items: end; min-width: 0; padding: 13px; border: 1px solid var(--line); border-radius: 11px; background: var(--wash); }
.copy-field-list span { grid-column: 1 / -1; color: var(--muted); font-size: 10px; font-weight: 700; line-height: 1.45; text-transform: uppercase; letter-spacing: .04em; }
.copy-field-list input { min-width: 0; background: #fff; font-family: "Cascadia Mono", Consolas, monospace; font-size: 11px; }
.copy-field-list .button { white-space: nowrap; }
.manual-confirm-form, .reserve-313-form { padding: 18px; border: 1px solid var(--line); border-radius: 12px; background: var(--wash); }
.status-summary small { color: var(--muted); font-size: 11px; line-height: 1.55; }
.catalog-state-panel { display: grid; gap: 7px; padding: 14px; border: 1px solid var(--line); border-radius: 11px; background: var(--wash); }
.catalog-state-panel small { color: var(--muted); line-height: 1.5; }

.shipment-list, .document-action-list { display: grid; margin: 18px 0; border-top: 1px solid var(--line); }
.document-action-row { display: grid; grid-template-columns: minmax(240px, 1fr) auto minmax(250px, auto); align-items: center; gap: 18px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.document-action-row > div:first-child strong, .document-action-row > div:first-child span { display: block; }
.document-action-row > div:first-child span { margin-top: 5px; color: var(--muted); font-size: 11px; line-height: 1.45; word-break: break-word; }
.document-statuses { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.document-buttons { display: flex; align-items: end; justify-content: flex-end; gap: 8px; flex-wrap: wrap; }
.send-xml-form { display: flex; align-items: end; gap: 7px; }
.send-xml-form label { gap: 3px; color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .05em; }
.send-xml-form input { width: 105px; min-height: 32px; padding: 6px 8px; font-size: 11px; }
.xml-layout { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 15px 0 20px; }
.xml-layout article { min-width: 0; padding: 18px; border: 1px solid var(--line); border-radius: 13px; background: var(--wash); }
.xml-layout h3 { margin: 15px 0 12px; font-size: 14px; line-height: 1.35; }
.xml-layout pre { margin: 0; padding: 13px; overflow-x: auto; border-radius: 9px; background: #14221e; color: #d8e7e1; font-family: "Cascadia Mono", Consolas, monospace; font-size: 9px; line-height: 1.55; }
.yes-no { display: inline-flex; min-width: 38px; justify-content: center; padding: 4px 7px; border-radius: 99px; font-size: 9px; font-weight: 800; text-transform: uppercase; }
.yes-no.yes { color: var(--green-dark); background: var(--green-soft); }
.yes-no.no { color: var(--red); background: var(--red-soft); }

.working-profile { display: grid; grid-template-columns: minmax(0, 1fr) minmax(360px, auto); align-items: end; gap: 34px; border-color: #c9ddd4; background: linear-gradient(120deg, #fff, #f1f8f5); }
.working-profile h2 { margin-bottom: 7px; }
.working-profile p { max-width: 720px; margin-bottom: 0; font-size: 12px; }
.profile-switcher { display: grid; grid-template-columns: minmax(240px, 1fr) auto; align-items: end; gap: 9px; }
.connection-section { margin-top: 30px; }
.connection-list { display: grid; gap: 16px; }
.connection-card { margin: 0; scroll-margin-top: 94px; }
.connection-card.is-active { border-color: #8bc9b2; box-shadow: 0 9px 30px rgba(8,118,83,.09); }
.connection-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; }
.connection-head h2 { margin: 9px 0 5px; }
.connection-head p { margin: 0; font-size: 11px; }
.connection-title-line { display: flex; align-items: center; gap: 8px; }
.connection-title-line .env { padding: 5px 8px; font-size: 9px; }
.active-mark { padding: 4px 7px; border-radius: 999px; color: var(--green-dark); background: var(--green-soft); font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; }
.connection-statuses { display: flex; align-items: flex-start; gap: 8px; }
.connection-status { display: grid; justify-items: end; gap: 5px; }
.connection-status small { color: var(--muted); font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; }
.connection-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px; margin: 20px 0; }
.connection-summary article { min-width: 0; padding: 15px; border-radius: 12px; background: var(--wash); }
.connection-summary span, .connection-summary small { display: block; color: var(--muted); font-size: 9px; line-height: 1.45; }
.connection-summary strong { display: block; margin: 6px 0; font-size: 12px; line-height: 1.4; }
.connection-summary strong.mono { font-size: 11px; letter-spacing: -.02em; }
.connection-actions { display: flex; align-items: end; gap: 9px; flex-wrap: wrap; padding-top: 2px; }
.compact-api-form { margin-left: auto; }
.compact-api-form + .compact-api-form { margin-left: 0; }
.connection-details { margin-top: 19px; border-top: 1px solid var(--line); }
.connection-details > summary { padding: 17px 0 0; cursor: pointer; color: var(--green-dark); font-size: 11px; font-weight: 750; }
.connection-detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 17px; }
.connection-detail-grid > div { display: grid; gap: 5px; min-width: 0; padding: 15px; border-radius: 11px; background: var(--wash); }
.connection-detail-grid span { margin-top: 7px; color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .04em; }
.connection-detail-grid span:first-child { margin-top: 0; }
.connection-detail-grid strong { font-size: 11px; line-height: 1.45; }
.secret-update-form { display: grid; grid-template-columns: minmax(260px, 1fr) auto; align-items: end; gap: 10px; margin-top: 12px; padding: 15px; border: 1px solid var(--line); border-radius: 11px; }

.profile-editor { margin-top: 30px; scroll-margin-top: 92px; }
.integration-wizard { display: grid; gap: 0; }
.wizard-step { padding: 25px 0; border-bottom: 1px solid var(--line); }
.wizard-step:first-of-type { padding-top: 20px; }
.wizard-step-head { display: flex; align-items: flex-start; gap: 11px; margin-bottom: 18px; }
.wizard-step-head .step { flex: 0 0 auto; margin-right: 0; }
.wizard-step-head h3 { margin: 3px 0 4px; font-size: 17px; }
.wizard-step-head p { margin: 0; font-size: 11px; }
.wizard-step .form-grid { padding-top: 0; }
.read-only-field { display: grid; align-content: center; gap: 7px; min-height: 92px; padding: 14px 16px; border-radius: 11px; background: var(--wash); }
.read-only-field span { color: #33423c; font-size: 13px; font-weight: 700; }
.read-only-field strong { font-size: 14px; }
.read-only-field small { color: var(--muted); font-size: 11px; }
.signing-mode-picker { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 0 0 18px; padding: 0; border: 0; }
.signing-mode-picker legend { grid-column: 1 / -1; margin-bottom: 4px; color: var(--muted); font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.choice-card { display: flex; align-items: flex-start; gap: 11px; padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--wash); cursor: pointer; }
.choice-card:has(input:checked) { border-color: var(--api); background: var(--blue-soft); box-shadow: inset 0 0 0 1px var(--api); }
.choice-card input { flex: 0 0 auto; width: auto; margin-top: 3px; }
.choice-card span { display: grid; gap: 5px; }
.choice-card strong { font-size: 13px; }
.choice-card small { color: var(--muted); font-size: 10px; line-height: 1.5; }
.browser-certificate-tools { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1px dashed #aebfd3; border-radius: 11px; background: var(--blue-soft); }
.browser-certificate-tools span { color: var(--muted); font-size: 11px; line-height: 1.45; }
.certificate-preview { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px; padding: 13px; border: 1px solid #c8dfd5; border-radius: 12px; background: var(--green-soft); }
.certificate-preview > div { min-width: 0; padding: 8px; }
.certificate-preview span, .certificate-preview small { display: block; color: var(--green-dark); font-size: 9px; line-height: 1.45; }
.certificate-preview strong { display: block; margin-top: 5px; font-size: 11px; line-height: 1.45; }
.help-tip [role="tooltip"] { display: none; }
.external-help { margin: 14px 0 0; font-size: 11px; }
.external-help a { color: var(--green-dark); font-weight: 750; }
.wizard-actions { display: flex; justify-content: flex-end; gap: 9px; padding-top: 24px; }
.audit-panel { padding: 0; overflow: hidden; }
.audit-panel > summary { display: flex; align-items: center; justify-content: space-between; padding: 21px 25px; cursor: pointer; list-style: none; }
.audit-panel > summary::-webkit-details-marker { display: none; }
.audit-panel[open] > summary { border-bottom: 1px solid var(--line); }
.audit-body { padding: 18px 25px 25px; }

@media (max-width: 980px) {
  .topbar { flex-wrap: wrap; gap: 12px; }
  nav { order: 3; width: 100%; overflow-x: auto; }
  .env { margin-left: auto; }
  .settings-grid { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .workspace-grid, .split-layout, .print-workspace { grid-template-columns: 1fr; }
  .filter-bar, .filter-grid, .detail-grid, .organization-filters, .sscc-history-filters { grid-template-columns: 1fr 1fr; }
  .post-close-grid { grid-template-columns: 1fr; }
  .scanner-card { grid-template-columns: 1fr; }
  .scanner-aside { display: grid; grid-template-columns: repeat(2, 1fr); }
  .container-row { grid-template-columns: 38px 1fr 70px 90px; }
  .row-actions { grid-column: 2 / -1; }
  .help-hero { grid-template-columns: 1fr; gap: 22px; }
  .data-flow { grid-template-columns: 1fr; }
  .flow-arrow { transform: rotate(90deg); justify-self: center; }
  .xml-layout { grid-template-columns: 1fr; }
  .metric-grid, .check-list.horizontal-flow { grid-template-columns: repeat(2, 1fr); }
  .working-profile { grid-template-columns: 1fr; }
  .connection-summary, .certificate-preview { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.shared-control-card { border-color: #b7d8cf; }
.shared-control-grid { display: flex; align-items: end; justify-content: space-between; gap: 18px; margin-top: 18px; }
.shared-control-grid .compact-form { flex: 1; grid-template-columns: minmax(280px, 1fr) 140px auto; align-items: end; }
.shared-workstations { margin-top: 20px; }
.invite-layout { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 30px; align-items: center; margin: 24px 0; }
.invite-layout img { display: block; border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.invite-layout label { display: grid; gap: 7px; font-weight: 700; }
.invite-layout input { width: 100%; margin-bottom: 12px; }

@media (max-width: 640px) {
  .page, footer { width: min(100% - 24px, 1280px); }
  .page { padding-top: 24px; }
  .topbar { padding: 11px 12px; }
  .flash-stack { right: 12px; bottom: 12px; width: calc(100vw - 24px); }
  nav a { padding: 7px 9px; font-size: 12px; }
  .hero { padding: 30px 24px; display: block; }
  .hero .button { margin-top: 24px; }
  .stat-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .stat { padding: 15px; }
  .card { padding: 18px; }
  .form-grid, .field-pair, .filter-bar, .filter-grid, .detail-grid, .organization-filters, .sscc-history-filters, .signing-mode-picker { grid-template-columns: 1fr; }
  .browser-certificate-tools { align-items: stretch; flex-direction: column; }
  .sscc-preview-grid, .sscc-range-overview { grid-template-columns: 1fr; }
  .sscc-preview-head { display: grid; }
  .span-2 { grid-column: auto; }
  .session-head { display: block; }
  .session-head .status { margin-top: 14px; }
  .scanner-main { padding: 22px 18px; }
  .scanner-aside { padding: 20px 18px; grid-template-columns: 1fr; }
  .scan-input-row { grid-template-columns: 1fr; }
  .container-row { grid-template-columns: 34px 1fr auto; }
  .container-count { display: none; }
  .container-state { grid-column: 3; }
  .row-actions { grid-column: 2 / -1; }
  .result-card { padding: 30px 18px; }
  .result-stats { grid-template-columns: 1fr; }
  .result-stats span { border-left: 0; border-top: 1px solid var(--line); }
  .result-stats span:first-child { border-top: 0; }
  footer { display: grid; gap: 6px; }
  .page-head { display: block; }
  .page-head > .button { margin-top: 16px; }
  .help-hero { padding: 27px 21px; }
  .help-grid.two, .help-grid.three, .output-grid { grid-template-columns: 1fr; }
  .compare-strip { grid-template-columns: 1fr; }
  .compare-strip > span { transform: rotate(90deg); justify-self: center; }
  .metric-grid, .check-list.horizontal-flow { grid-template-columns: 1fr; }
  .copy-field-list, .compact-form { grid-template-columns: 1fr; }
  .copy-field-list > div { grid-template-columns: 1fr; }
  .copy-field-list span { grid-column: auto; }
  .inline-form { align-items: stretch; flex-direction: column; }
  .result-send-form { align-items: stretch; flex-direction: column; }
  .result-send-form .button { width: 100%; }
  .pin-dialog-form, .help-dialog-form { padding: 23px 20px 20px; }
  .document-action-row { grid-template-columns: 1fr; gap: 10px; }
  .document-buttons { justify-content: flex-start; }
  .send-xml-form { align-items: stretch; flex-direction: column; width: 100%; }
  .send-xml-form input { width: 100%; }
  .profile-context { max-width: 150px; }
  .profile-switcher, .secret-update-form { grid-template-columns: 1fr; }
  .connection-head { display: grid; }
  .connection-statuses { justify-content: start; }
  .connection-status { justify-items: start; }
  .connection-summary, .certificate-preview, .connection-detail-grid { grid-template-columns: 1fr; }
  .connection-actions { align-items: stretch; flex-direction: column; }
  .connection-actions > *, .connection-actions .button { width: 100%; }
  .compact-api-form { margin-left: 0; }
  .shared-control-grid { align-items: stretch; flex-direction: column; }
  .shared-control-grid .compact-form { grid-template-columns: 1fr; width: 100%; }
  .invite-layout { grid-template-columns: 1fr; }
  .invite-layout img { width: min(260px, 100%); height: auto; margin: auto; }
}
