/* ==========================================================================
   Components
   ========================================================================== */

/* ---------- Buttons ---------- */
.btn {
  --bg: var(--c-surface); --fg: var(--c-primary); --bd: var(--c-border-strong);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px;
  border-radius: 9px; border: 1px solid var(--bd); background: var(--bg); color: var(--fg); font-weight: 600; font-size: .94rem;
  text-decoration: none; line-height: 1.2; transition: background var(--t), border-color var(--t), color var(--t), box-shadow var(--t); white-space: nowrap;
}
.btn:hover { border-color: var(--c-secondary); color: var(--c-secondary); }
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn-primary { --bg: var(--c-brand); --fg: #fff; --bd: var(--c-brand); }
.btn-primary:hover { background: #0A469A; border-color: #0A469A; color: #fff; }
.btn-teal { --bg: var(--c-teal-600); --fg: #fff; --bd: var(--c-teal-600); }
.btn-teal:hover { background: #086E6D; border-color: #086E6D; color: #fff; }
.btn-dark { --bg: var(--c-primary); --fg: #fff; --bd: var(--c-primary); }
.btn-dark:hover { background: var(--c-primary-700); color: #fff; }
.btn-ghost { --bg: transparent; --bd: transparent; --fg: var(--c-secondary); padding-inline: 10px; }
.btn-ghost:hover { background: var(--c-bg-2); }
.btn-on-dark { --bg: transparent; --fg: #fff; --bd: rgba(255,255,255,.45); }
.btn-on-dark:hover { background: rgba(255,255,255,.1); border-color: #fff; color: #fff; }
.btn-sm { min-height: 36px; padding: 6px 12px; font-size: .86rem; }
.btn-lg { min-height: 52px; padding: 14px 24px; font-size: 1rem; }
.btn-block { width: 100%; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .55; pointer-events: none; }
.btn.is-loading { position: relative; color: transparent !important; pointer-events: none; }
.btn.is-loading::after { content: ""; position: absolute; width: 18px; height: 18px; border: 2px solid currentColor; border-color: #fff #fff transparent transparent; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Badges & chips ---------- */
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: var(--r-pill); font-size: .74rem; font-weight: 600; line-height: 1.4; border: 1px solid transparent; white-space: nowrap; }
.badge svg { width: 13px; height: 13px; }
.badge--brand { background: #E3EEFB; color: #0A469A; }
.badge--teal { background: #DDF4F3; color: #0A6F6E; }
.badge--amber { background: var(--c-warning-fill); color: #8A4B06; }
.badge--green { background: var(--c-success-fill); color: #146C43; }
.badge--red { background: var(--c-error-fill); color: #A11D2C; }
.badge--grey { background: #EDF2F5; color: #4A6372; }
.badge--outline { border-color: var(--c-border-strong); color: var(--c-ink-2); background: transparent; }
.badge--demo { background: #FFF4E0; color: #8A4B06; border: 1px dashed #E0A64B; }
[data-theme="dark"] .badge--grey { background: #1C3A4F; color: #C3D5E0; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.chip { display: inline-flex; align-items: center; padding: 4px 10px; border-radius: 6px; background: var(--c-bg-2); color: var(--c-ink-2); font-size: .8rem; border: 1px solid var(--c-border); text-decoration: none; }
a.chip:hover { border-color: var(--c-secondary); color: var(--c-secondary); }

/* ---------- Cards ---------- */
.card { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--r-lg); padding: 24px; box-shadow: var(--sh-1); display: flex; flex-direction: column; gap: 10px; position: relative; }
.card h3 { font-size: 1.12rem; margin: 0; }
.card p { margin: 0; color: var(--c-ink-2); font-size: .94rem; }
.card-foot { margin-top: auto; padding-top: 8px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.card--link { transition: border-color var(--t), box-shadow var(--t), transform var(--t); }
.card--link:hover { border-color: var(--c-secondary); box-shadow: var(--sh-2); }
.card--link .stretched::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.card-icon { width: 44px; height: 44px; border-radius: 10px; display: grid; place-items: center; background: #E4F0F7; color: var(--c-secondary); }
[data-theme="dark"] .card-icon { background: #173A52; }
.card-icon svg { width: 22px; height: 22px; }
.card-meta { display: flex; flex-wrap: wrap; gap: 12px; font-size: .8rem; color: var(--c-muted); }
.card-meta span { display: inline-flex; align-items: center; gap: 4px; }
.card-meta svg { width: 14px; height: 14px; }
.card--flat { box-shadow: none; }
.card--media { padding: 0; overflow: hidden; }
.card--media .card-body { padding: 20px 22px 22px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.card--media img { aspect-ratio: 16/9; object-fit: cover; width: 100%; }
.card-kicker { font-size: .78rem; color: var(--c-muted); font-weight: 500; }

/* Definition list used in detail views */
.dl { display: grid; grid-template-columns: minmax(120px, 34%) 1fr; gap: 8px 16px; margin: 0; font-size: .93rem; }
.dl dt { color: var(--c-muted); }
.dl dd { margin: 0; color: var(--c-ink); }
@media (max-width: 520px) { .dl { grid-template-columns: 1fr; gap: 2px; } .dl dd { margin-bottom: 8px; } }

/* ---------- Forms ---------- */
.form-grid { display: grid; gap: 18px 20px; grid-template-columns: 1fr; }
@media (min-width: 768px) { .form-grid { grid-template-columns: 1fr 1fr; } .form-grid .span-2 { grid-column: 1 / -1; } }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > label, .field > .label, fieldset > legend { font-weight: 600; font-size: .9rem; color: var(--c-ink); }
.req { color: var(--c-error); margin-left: 2px; }
.opt { color: var(--c-muted); font-weight: 400; font-size: .8rem; margin-left: 4px; }
.hint { font-size: .8rem; color: var(--c-muted); }
.input, .select, .textarea {
  width: 100%; min-height: 46px; padding: 10px 12px; border: 1px solid var(--c-border-strong); border-radius: 9px; background: var(--c-surface);
  transition: border-color var(--t), box-shadow var(--t); font-size: 1rem;
}
.textarea { min-height: 120px; resize: vertical; line-height: 1.5; }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%23607D8B' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 36px; }
.input:hover, .select:hover, .textarea:hover { border-color: var(--c-secondary); }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--c-secondary); box-shadow: 0 0 0 3px rgba(20,121,168,.22); }
.field.has-error .input, .field.has-error .select, .field.has-error .textarea, .field.has-error .combo-input { border-color: var(--c-error); }
.field-error { display: none; color: var(--c-error); font-size: .82rem; font-weight: 500; }
.field.has-error .field-error { display: flex; gap: 4px; align-items: center; }
.char-count { font-size: .76rem; color: var(--c-muted); text-align: right; }
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
fieldset > legend { margin-bottom: 10px; padding: 0; }
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Checkbox / radio cards */
.check-grid { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 210px), 1fr)); }
.check-card { position: relative; display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--c-border-strong); border-radius: 10px; background: var(--c-surface); cursor: pointer; transition: border-color var(--t), background var(--t); font-size: .92rem; line-height: 1.35; }
.check-card:hover { border-color: var(--c-secondary); }
.check-card input { position: absolute; opacity: 0; pointer-events: none; }
.check-card .box { flex-shrink: 0; width: 20px; height: 20px; border: 2px solid var(--c-border-strong); border-radius: 5px; display: grid; place-items: center; transition: background var(--t), border-color var(--t); margin-top: 1px; background: var(--c-surface); }
.check-card input[type="radio"] + .box { border-radius: 50%; }
.check-card .box svg { width: 14px; height: 14px; color: #fff; opacity: 0; transform: scale(.6); transition: opacity var(--t), transform var(--t); }
.check-card input:checked + .box { background: var(--c-brand); border-color: var(--c-brand); }
.check-card input:checked + .box svg { opacity: 1; transform: none; }
.check-card:has(input:checked) { border-color: var(--c-brand); background: #F1F6FD; }
[data-theme="dark"] .check-card:has(input:checked) { background: #13324A; }
.check-card input:focus-visible + .box { outline: 3px solid var(--c-focus); outline-offset: 2px; }
.check-card small { display: block; color: var(--c-muted); font-size: .78rem; margin-top: 2px; }
.check-card--rich { flex-direction: column; gap: 6px; }
.check-card--rich .check-head { display: flex; gap: 10px; align-items: center; font-weight: 600; }
.inline-checks { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.inline-check { display: inline-flex; align-items: center; gap: 8px; font-size: .94rem; cursor: pointer; }
.inline-check input { width: 18px; height: 18px; accent-color: var(--c-brand); }

/* Country combobox */
.combo { position: relative; }
.combo-input { padding-right: 36px; }
.combo-list { position: absolute; z-index: 50; left: 0; right: 0; top: calc(100% + 4px); max-height: 260px; overflow-y: auto; background: var(--c-surface); border: 1px solid var(--c-border-strong); border-radius: 10px; box-shadow: var(--sh-3); margin: 0; padding: 6px; list-style: none; }
.combo-list li { padding: 9px 10px; border-radius: 6px; cursor: pointer; font-size: .94rem; }
.combo-list li[aria-selected="true"], .combo-list li:hover { background: var(--c-bg-2); }
.combo-list li.empty { color: var(--c-muted); cursor: default; }
.combo-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.combo-tag { display: inline-flex; align-items: center; gap: 4px; padding: 3px 4px 3px 10px; border-radius: 6px; background: #E3EEFB; color: #0A469A; font-size: .82rem; font-weight: 500; }
.combo-tag button { border: 0; background: none; color: inherit; width: 22px; height: 22px; display: grid; place-items: center; border-radius: 4px; }
.combo-tag button:hover { background: rgba(10,70,154,.12); }
.combo-tag svg { width: 14px; height: 14px; }

/* Upload */
.dropzone { border: 2px dashed var(--c-border-strong); border-radius: var(--r-lg); padding: 28px 20px; text-align: center; background: var(--c-surface); transition: border-color var(--t), background var(--t); }
.dropzone.is-over { border-color: var(--c-brand); background: #F1F6FD; }
.dropzone svg { width: 34px; height: 34px; margin: 0 auto 8px; color: var(--c-secondary); }
.dropzone p { margin: 4px 0; }
.file-list { list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 8px; }
.file-item { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border: 1px solid var(--c-border); border-radius: 10px; background: var(--c-surface); }
.file-item svg { width: 22px; height: 22px; color: var(--c-secondary); flex-shrink: 0; }
.file-item .fname { font-weight: 500; word-break: break-all; }
.file-item .fmeta { font-size: .78rem; color: var(--c-muted); }
.file-item .grow { flex: 1; min-width: 0; }

/* ---------- Alerts / notices ---------- */
.alert { display: flex; gap: 12px; padding: 14px 16px; border-radius: var(--r-md); border: 1px solid; font-size: .92rem; line-height: 1.5; }
.alert svg { width: 20px; height: 20px; flex-shrink: 0; margin-top: 1px; }
.alert p { margin: 0; }
.alert--info { background: #EEF6FB; border-color: #BFDCEC; color: #134F6E; }
.alert--warn { background: var(--c-warning-fill); border-color: #F3D48A; color: #7A4306; }
.alert--error { background: var(--c-error-fill); border-color: #F2B8BF; color: #8D1A27; }
.alert--success { background: var(--c-success-fill); border-color: #A9D8BD; color: #0F5A37; }
[data-theme="dark"] .alert--info { background: #11324A; color: #CFE6F4; border-color: #25506E; }

/* ---------- Toasts ---------- */
.toast-region { position: fixed; z-index: 400; bottom: 20px; right: 20px; left: 20px; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; pointer-events: none; }
.toast { pointer-events: auto; max-width: 420px; background: var(--c-ink); color: #fff; padding: 12px 16px; border-radius: 10px; box-shadow: var(--sh-3); display: flex; gap: 10px; align-items: flex-start; font-size: .92rem; animation: toastIn 220ms var(--ease); }
[data-theme="dark"] .toast { background: #E6F0F6; color: #0A1B28; }
.toast svg { width: 20px; height: 20px; flex-shrink: 0; }
.toast--success svg { color: #6FD39A; } .toast--error svg { color: #FF8C98; }
@keyframes toastIn { from { transform: translateY(8px); opacity: 0; } to { transform: none; opacity: 1; } }

/* ---------- Modal ---------- */
.modal { position: fixed; inset: 0; z-index: 300; display: grid; place-items: center; padding: 16px; }
.modal[hidden] { display: none; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(8,28,44,.55); animation: fade var(--t) var(--ease); }
.modal-dialog { position: relative; background: var(--c-surface); border-radius: var(--r-xl); width: min(760px, 100%); max-height: calc(100vh - 32px); display: flex; flex-direction: column; box-shadow: var(--sh-3); animation: modalIn 220ms var(--ease); }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 22px 24px 12px; border-bottom: 1px solid var(--c-border); }
.modal-head h2 { font-size: 1.35rem; margin: 0; }
.modal-body { padding: 20px 24px; overflow-y: auto; }
.modal-foot { padding: 14px 24px 20px; border-top: 1px solid var(--c-border); display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; }
@keyframes modalIn { from { transform: translateY(10px) scale(.99); opacity: 0; } to { transform: none; opacity: 1; } }

/* ---------- Tabs ---------- */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--c-border); overflow-x: auto; scrollbar-width: thin; margin-bottom: var(--s5); }
.tab { border: 0; background: none; padding: 12px 14px; font-weight: 600; font-size: .92rem; color: var(--c-muted); border-bottom: 2px solid transparent; white-space: nowrap; }
.tab[aria-selected="true"] { color: var(--c-brand); border-bottom-color: var(--c-brand); }
.tab:hover { color: var(--c-ink); }
.tab .count { font-weight: 500; color: var(--c-muted); margin-left: 4px; font-size: .8rem; }

/* ---------- Accordion ---------- */
.accordion { border: 1px solid var(--c-border); border-radius: var(--r-md); background: var(--c-surface); overflow: hidden; }
.accordion details + details { border-top: 1px solid var(--c-border); }
.accordion summary { list-style: none; cursor: pointer; padding: 16px 18px; font-weight: 600; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary svg { width: 18px; height: 18px; transition: transform var(--t); flex-shrink: 0; color: var(--c-muted); }
.accordion details[open] summary svg { transform: rotate(180deg); }
.accordion .acc-body { padding: 0 18px 18px; color: var(--c-ink-2); }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--c-border); border-radius: var(--r-md); background: var(--c-surface); }
.table { font-size: .9rem; }
.table th, .table td { padding: 11px 14px; text-align: left; border-bottom: 1px solid var(--c-border); vertical-align: top; }
.table th { background: var(--c-bg); font-weight: 600; color: var(--c-ink-2); white-space: nowrap; font-size: .82rem; }
.table tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: #FAFCFE; }
[data-theme="dark"] .table tbody tr:hover { background: #12304A; }

/* ---------- Empty / loading / error states ---------- */
.empty-state { text-align: center; padding: 48px 20px; border: 1px dashed var(--c-border-strong); border-radius: var(--r-lg); background: var(--c-surface); }
.empty-state svg { width: 40px; height: 40px; margin: 0 auto 12px; color: var(--c-muted); }
.empty-state h3 { font-size: 1.15rem; margin-bottom: 6px; }
.empty-state p { color: var(--c-muted); margin-bottom: 16px; }
.skeleton { background: linear-gradient(90deg, var(--c-bg-2) 0%, #F7FAFC 50%, var(--c-bg-2) 100%); background-size: 200% 100%; animation: shimmer 1.2s linear infinite; border-radius: 8px; }
.skeleton-card { height: 180px; border-radius: var(--r-lg); }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ---------- Stepper ---------- */
.stepper { list-style: none; margin: 0 0 var(--s6); padding: 0; display: flex; gap: 0; overflow-x: auto; scrollbar-width: none; }
.stepper::-webkit-scrollbar { display: none; }
.stepper li { flex: 1 0 auto; min-width: 92px; position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; font-size: .78rem; color: var(--c-muted); font-weight: 500; padding: 0 4px; }
.stepper li::before { content: ""; position: absolute; top: 17px; left: calc(-50% + 20px); right: calc(50% + 20px); height: 2px; background: var(--c-border-strong); }
.stepper li:first-child::before { display: none; }
.stepper .dot { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--c-surface); border: 2px solid var(--c-border-strong); font-weight: 700; color: var(--c-muted); position: relative; z-index: 1; transition: all var(--t); font-size: .9rem; }
.stepper .dot svg { width: 18px; height: 18px; }
.stepper li.done .dot { background: var(--c-green); border-color: var(--c-green); color: #fff; }
.stepper li.done::before, .stepper li.current::before { background: var(--c-green); }
.stepper li.current .dot { border-color: var(--c-brand); color: var(--c-brand); box-shadow: 0 0 0 4px rgba(1,82,179,.14); }
.stepper li.current { color: var(--c-ink); }
.stepper button { all: unset; cursor: pointer; display: contents; }
.stepper button:focus-visible .dot { outline: 3px solid var(--c-focus); outline-offset: 2px; }

/* ---------- Timeline (lifecycle progress) ---------- */
.progress-line { display: flex; gap: 0; overflow-x: auto; padding-bottom: 6px; }
.progress-line .pl-step { flex: 1 0 96px; text-align: center; font-size: .74rem; color: var(--c-muted); position: relative; padding-top: 22px; }
.progress-line .pl-step::before { content: ""; position: absolute; top: 7px; left: 0; right: 0; height: 2px; background: var(--c-border-strong); }
.progress-line .pl-step::after { content: ""; position: absolute; top: 2px; left: calc(50% - 6px); width: 12px; height: 12px; border-radius: 50%; background: var(--c-surface); border: 2px solid var(--c-border-strong); }
.progress-line .completed::before, .progress-line .completed::after { background: var(--c-green); border-color: var(--c-green); }
.progress-line .current { color: var(--c-ink); font-weight: 600; }
.progress-line .current::after { background: var(--c-brand); border-color: var(--c-brand); box-shadow: 0 0 0 4px rgba(1,82,179,.16); }
.progress-line .na { opacity: .45; }

/* ---------- Filter panel ---------- */
.filter-layout { display: grid; gap: var(--s5); }
@media (min-width: 992px) { .filter-layout { grid-template-columns: 270px 1fr; align-items: start; } }
.filter-panel { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--r-lg); padding: 18px; position: sticky; top: calc(var(--header-h) + 16px); }
.filter-panel h2 { font-size: 1rem; margin-bottom: 12px; display: flex; justify-content: space-between; align-items: center; }
.filter-group { border-top: 1px solid var(--c-border); padding-top: 12px; margin-top: 12px; }
.filter-group > summary { font-weight: 600; font-size: .88rem; cursor: pointer; list-style: none; display: flex; justify-content: space-between; }
.filter-group > summary::-webkit-details-marker { display: none; }
.filter-group .opts { display: grid; gap: 6px; margin-top: 10px; max-height: 240px; overflow-y: auto; }
.filter-group label { display: flex; gap: 8px; align-items: center; font-size: .87rem; cursor: pointer; }
.filter-group input { accent-color: var(--c-brand); width: 16px; height: 16px; }
.filter-toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; margin-bottom: var(--s4); }
.filter-open-btn { display: none; }
@media (max-width: 991px) {
  .filter-panel { position: fixed; inset: 0 0 0 auto; width: min(92vw, 360px); z-index: 250; border-radius: 0; overflow-y: auto; transform: translateX(100%); transition: transform 240ms var(--ease); top: 0; }
  .filter-panel.open { transform: none; box-shadow: var(--sh-3); }
  .filter-open-btn { display: inline-flex; }
  .filter-scrim { position: fixed; inset: 0; background: rgba(8,28,44,.45); z-index: 240; }
}
.search-box { position: relative; flex: 1; min-width: 220px; }
.search-box svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--c-muted); pointer-events: none; }
.search-box .input { padding-left: 40px; }
.result-count { font-size: .88rem; color: var(--c-muted); }

/* ---------- Search overlay ---------- */
.search-overlay { position: fixed; inset: 0; z-index: 350; display: none; }
.search-overlay.open { display: block; }
.search-overlay .modal-backdrop { position: absolute; inset: 0; }
.search-panel { position: relative; margin: 8vh auto 0; width: min(760px, calc(100% - 24px)); background: var(--c-surface); border-radius: var(--r-xl); box-shadow: var(--sh-3); overflow: hidden; animation: modalIn 200ms var(--ease); }
.search-panel .search-box { padding: 14px; border-bottom: 1px solid var(--c-border); }
.search-panel .search-box svg { left: 28px; }
.search-panel .input { border: 0; box-shadow: none !important; font-size: 1.1rem; }
.search-results { max-height: 60vh; overflow-y: auto; padding: 8px 12px 16px; }
.sr-group h3 { font-size: .78rem; color: var(--c-muted); margin: 14px 6px 6px; font-weight: 600; }
.sr-item { display: flex; gap: 12px; align-items: flex-start; padding: 10px; border-radius: 10px; text-decoration: none; color: var(--c-ink); }
.sr-item:hover, .sr-item.active { background: var(--c-bg-2); }
.sr-item svg { width: 20px; height: 20px; color: var(--c-secondary); flex-shrink: 0; margin-top: 2px; }
.sr-item strong { display: block; font-weight: 600; }
.sr-item span { font-size: .82rem; color: var(--c-muted); }
.sr-item mark { background: #FFF1B8; color: inherit; border-radius: 2px; }
.search-hints { padding: 16px; display: flex; flex-wrap: wrap; gap: 6px; }

/* ---------- Tooltip ---------- */
.tip { border-bottom: 1px dotted var(--c-muted); cursor: help; position: relative; }
.tip:hover::after, .tip:focus::after { content: attr(data-tip); position: absolute; left: 50%; bottom: calc(100% + 8px); transform: translateX(-50%); width: max-content; max-width: 260px; background: var(--c-ink); color: #fff; font-size: .78rem; font-weight: 400; line-height: 1.4; padding: 8px 10px; border-radius: 8px; z-index: 60; box-shadow: var(--sh-2); }

/* ---------- Route (service availability) marker ---------- */
.route { display: inline-flex; align-items: center; gap: 6px; font-size: .78rem; font-weight: 600; }
.route::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.route--direct { color: var(--c-brand); }
.route--partner { color: var(--c-teal-600); }
.route--assessment { color: var(--c-warning); }

/* ---------- Flow (arrow sequence) ---------- */
.flow { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; counter-reset: flow; }
.flow li { display: inline-flex; align-items: center; gap: 8px; font-size: .88rem; font-weight: 500; }
.flow li span { padding: 7px 12px; border-radius: 8px; background: var(--c-surface); border: 1px solid var(--c-border); }
.flow li:not(:last-child)::after { content: ""; width: 16px; height: 2px; background: var(--c-border-strong); }
.flow--vertical { flex-direction: column; align-items: stretch; }
.flow--vertical li { flex-direction: column; align-items: stretch; }
.flow--vertical li:not(:last-child)::after { width: 2px; height: 14px; margin-left: 20px; }

/* Static-rendered icons (build.py) and icons inside headings */
svg.ic { width: 1.15em; height: 1.15em; flex-shrink: 0; vertical-align: -0.18em; }
.btn svg.ic { width: 18px; height: 18px; }
.sub-block h3 svg, .wizard-step h3 svg { width: 20px; height: 20px; vertical-align: -4px; color: var(--c-secondary); margin-right: 4px; }
.card-icon svg.ic { width: 24px; height: 24px; }
.alert svg.ic { width: 20px; height: 20px; }
.sub-block h3 { display: flex; align-items: center; gap: 6px; }
.filter-group > summary svg { width: 16px; height: 16px; color: var(--c-muted); transition: transform var(--t); }
.filter-group[open] > summary svg { transform: rotate(180deg); }
.table-wrap { position: relative; }
@media (max-width: 520px) { .btn { white-space: normal; text-align: center; } .btn-lg { padding-inline: 18px; } }
.form-grid { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 768px) { .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.select, .input, .textarea { max-width: 100%; min-width: 0; }
.alert p, .hint, .field-error span { overflow-wrap: anywhere; min-width: 0; }
