*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    background: #f4f6fa;
    color: #1f2933;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 15px;
    line-height: 1.5;
    min-height: 100vh;
}

a {
    color: #2456a6;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.adm-auth {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: linear-gradient(180deg, #0f1f3a 0%, #1c2f54 100%);
}

.adm-auth__card {
    width: 100%;
    max-width: 26rem;
    background: #ffffff;
    border-radius: 10px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    /* Center every element of the auth card — brand, title, labels, the
       submit button and the hints. The submit button is an inline-flex box,
       so text-align centers it too. Typed input text keeps its own (left)
       alignment, which form controls do not inherit. */
    text-align: center;
}

.adm-auth__logo {
    display: block;
    height: 56px;
    width: auto;
    margin: 0 auto 1.25rem;
}

.adm-auth__brand {
    font-size: 0.85rem;
    color: #52606d;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin: 0 0 0.25rem;
    font-weight: 600;
}

.adm-auth__title {
    font-size: 1.5rem;
    margin: 0 0 1.25rem;
    color: #0f1f3a;
}

.adm-auth label {
    display: block;
    margin: 1rem 0 0.25rem;
    font-weight: 600;
    color: #1f2933;
}

.adm-auth input[type="email"],
.adm-auth input[type="text"],
.adm-auth input[type="password"] {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 1px solid #cbd2d9;
    border-radius: 6px;
    font-size: 1rem;
    box-sizing: border-box;
}

.adm-auth__hint {
    color: #7b8794;
    font-size: 0.8rem;
    margin: 1.5rem 0 0;
}

.adm-shell {
    display: grid;
    grid-template-columns: 240px 1fr;
    min-height: 100vh;
}

.adm-sidebar {
    background: #0f1f3a;
    color: #d7dee8;
    display: flex;
    flex-direction: column;
    /* Pin the main menu to the viewport so it runs along while the content
       scrolls. height (not min-height) + align-self:start stop the grid cell
       from stretching to the full content height, which would defeat sticky. */
    height: 100vh;
    align-self: start;
    position: sticky;
    top: 0;
}

.adm-sidebar__brand {
    padding: 1.25rem 1.25rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.adm-sidebar__brand-name {
    font-size: 0.95rem;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.25;
}

.adm-sidebar__brand-sub {
    font-size: 0.7rem;
    color: #8aa0c0;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-top: 0.25rem;
}

.adm-nav {
    flex: 1;
    padding: 0.75rem 0;
    overflow-y: auto;
}

.adm-nav__group-label {
    color: #6b7e9c;
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 0.75rem 1.25rem 0.4rem;
    font-weight: 700;
}

.adm-nav__link {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.6rem 1.25rem;
    color: #c9d3e1;
    font-size: 0.95rem;
    border-left: 3px solid transparent;
}

.adm-nav__link:hover {
    background: rgba(255, 255, 255, 0.04);
    color: #ffffff;
    text-decoration: none;
}

.adm-nav__link--active {
    background: rgba(255, 255, 255, 0.07);
    color: #ffffff;
    border-left-color: #4f8ef7;
}

.adm-nav__icon {
    width: 1rem;
    text-align: center;
    color: #8aa0c0;
    flex-shrink: 0;
}

.adm-nav__link--active .adm-nav__icon {
    color: #ffffff;
}

.adm-sidebar__footer {
    padding: 0.75rem 1.25rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.75rem;
    color: #8aa0c0;
}

.adm-workspace {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background: #f4f6fa;
}

.adm-topbar {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1.5rem;
    background: #ffffff;
    border-bottom: 1px solid #e4e7eb;
}

.adm-topbar__search {
    flex: 1;
    max-width: 28rem;
}

.adm-topbar__search input {
    width: 100%;
    padding: 0.5rem 0.75rem;
    background: #f4f6fa;
    border: 1px solid #e4e7eb;
    border-radius: 6px;
    font-size: 0.85rem;
    color: #1f2933;
}

.adm-topbar__search input:focus {
    outline: 2px solid #4f8ef7;
    outline-offset: -1px;
    background: #ffffff;
}

.adm-topbar__spacer {
    flex: 1;
}

.adm-topbar__item {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: #52606d;
    font-size: 0.8rem;
    padding: 0.35rem 0.6rem;
    border-radius: 6px;
}

.adm-topbar__item--muted {
    color: #9aa5b1;
}

.adm-topbar__user {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding-left: 0.75rem;
    margin-left: 0.25rem;
    border-left: 1px solid #e4e7eb;
}

.adm-topbar__logout {
    background: none;
    border: 0;
    color: #52606d;
    font-size: 0.8rem;
    cursor: pointer;
    padding: 0.35rem 0.6rem;
    border-radius: 6px;
}

.adm-topbar__logout:hover {
    background: #f4f6fa;
    color: #1f2933;
}

/* In-console language switcher (one short link per supported locale). */
.adm-topbar__langs {
    display: inline-flex;
    align-items: center;
    gap: 0.15rem;
    margin-right: 0.25rem;
}
.adm-topbar__lang {
    display: inline-block;
    padding: 0.2rem 0.4rem;
    border-radius: 5px;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    color: #7b8794;
    text-decoration: none;
}
.adm-topbar__lang:hover {
    background: #f0f4f8;
    color: #102a43;
    text-decoration: none;
}
.adm-topbar__lang--active {
    background: #eaf2ff;
    color: #1c3d80;
    cursor: default;
}

.adm-page {
    padding: 1.5rem;
    max-width: 1400px;
    width: 100%;
}

.adm-page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.adm-page-header__title {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 0;
    color: #0f1f3a;
}

.adm-page-header__subtitle {
    color: #7b8794;
    font-size: 0.85rem;
    margin: 0.25rem 0 0;
}

.adm-page-header__actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.adm-alert {
    padding: 0.75rem 1rem;
    border-radius: 6px;
    margin-bottom: 1rem;
    font-size: 0.875rem;
    border: 1px solid transparent;
}

.adm-alert--info {
    background: #eaf2ff;
    border-color: #cfddf7;
    color: #1c3d80;
}

.adm-alert--success {
    background: #e6f4ea;
    border-color: #c1e4cb;
    color: #1e6431;
}

.adm-alert--warning {
    background: #fff5e0;
    border-color: #f3dca1;
    color: #7a5300;
}

.adm-alert--danger {
    background: #fdecea;
    border-color: #f3c6c1;
    color: #a8261d;
}

.adm-card-grid {
    display: grid;
    /* Four KPI cards per row on a normal desktop (8 cards => a clean 4 + 4). */
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 1fr; /* every KPI card in a row shares the same height */
    gap: 1rem;
    margin-bottom: 1.5rem;
}

/* Fewer columns as the viewport narrows so cards never get too cramped. */
@media (max-width: 1200px) {
    .adm-card-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 680px) {
    .adm-card-grid {
        grid-template-columns: 1fr;
    }
}

.adm-card {
    background: #ffffff;
    border: 1px solid #e4e7eb;
    border-radius: 8px;
    padding: 1rem 1.1rem;
    box-shadow: 0 1px 2px rgba(15, 31, 58, 0.04);
    /* Fill the equal-height grid track so all cards line up regardless of how
       much hint text each one carries. */
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* A KPI card that links to its screen: whole card is clickable. */
.adm-card--link {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
    transition: box-shadow 0.12s ease, border-color 0.12s ease, transform 0.12s ease;
}

.adm-card--link:hover,
.adm-card--link:focus-visible {
    border-color: #c3cad4;
    box-shadow: 0 4px 10px rgba(15, 31, 58, 0.10);
    transform: translateY(-1px);
    outline: none;
    /* Never underline the card text on hover (overrides the global a:hover). */
    text-decoration: none;
}

.adm-card__label {
    font-size: 0.72rem;
    color: #7b8794;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 600;
    margin: 0;
}

.adm-card__value {
    font-size: 1.75rem;
    font-weight: 700;
    color: #0f1f3a;
    margin: 0.4rem 0 0.1rem;
    line-height: 1.1;
}

.adm-card__hint {
    font-size: 0.8rem;
    color: #7b8794;
    margin: 0;
}

.adm-card--panel {
    padding: 1.25rem 1.5rem;
}

.adm-card__title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.75rem;
    color: #1f2933;
}

.adm-table-wrap {
    background: #ffffff;
    border: 1px solid #e4e7eb;
    border-radius: 8px;
    box-shadow: 0 1px 2px rgba(15, 31, 58, 0.04);
    overflow: hidden;
}

.adm-table-toolbar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e4e7eb;
    background: #fafbfc;
}

/* Bottom toolbar: mirrors the top toolbar but closes the card from below
   (top border instead of bottom) and carries no title. */
.adm-table-toolbar--footer {
    border-bottom: none;
    border-top: 1px solid #e4e7eb;
}

.adm-table-toolbar__title {
    font-weight: 600;
    color: #1f2933;
    margin: 0;
    font-size: 0.9rem;
}

.adm-table-toolbar__spacer {
    flex: 1;
}

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

.adm-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.92rem;
}

.adm-table th,
.adm-table td {
    text-align: left;
    padding: 0.7rem 1rem;
    border-bottom: 1px solid #eef0f3;
    white-space: nowrap;
    vertical-align: middle;
}

.adm-table thead th {
    background: #fafbfc;
    color: #52606d;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 700;
    border-bottom: 1px solid #e4e7eb;
}

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

.adm-table tbody tr:hover {
    background: #f9fafc;
}

.adm-table__col-actions,
.adm-table th.adm-table__col-actions,
.adm-table td.adm-table__col-actions {
    text-align: right;
}

/* Pure-number columns (counts, ids, years, quantities) are centre-aligned. */
.adm-table th.adm-table__num,
.adm-table td.adm-table__num {
    text-align: center;
}

.adm-table__empty {
    padding: 2.5rem 1rem;
    text-align: center;
    color: #7b8794;
    font-size: 0.9rem;
}

/* Equal-width, fixed layout: every column gets the same share of the width so
   two stacked tables with the same column count line up column-for-column.
   Long, unbreakable values (e.g. an installation id) wrap instead of forcing a
   column wider than its neighbours. */
.adm-table--fixed {
    table-layout: fixed;
}

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

/* Air between two tables stacked directly on top of each other (e.g. the
   Installations screen's mirrored-installations and snapshot-syncs cards). */
.adm-table-wrap + .adm-table-wrap {
    margin-top: 1.5rem;
}

.adm-empty {
    background: #ffffff;
    border: 1px dashed #cbd2d9;
    border-radius: 8px;
    padding: 2.5rem 1.5rem;
    text-align: center;
    color: #52606d;
}

.adm-empty__title {
    font-size: 1rem;
    font-weight: 600;
    color: #1f2933;
    margin: 0 0 0.4rem;
}

.adm-empty__body {
    margin: 0;
    color: #7b8794;
    font-size: 0.875rem;
}

.adm-empty__tag {
    display: inline-block;
    margin-top: 0.75rem;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #52606d;
    background: #f1f3f5;
    border-radius: 6px;
    padding: 0.2rem 0.6rem;
    font-weight: 500;
}

.adm-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    border: 1px solid transparent;
    border-radius: 6px;
    padding: 0.45rem 0.85rem;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    line-height: 1.1;
    background: #ffffff;
    color: #1f2933;
    text-decoration: none;
}

.adm-btn:hover {
    text-decoration: none;
}

.adm-btn--primary {
    background: #1f3a5f;
    border-color: #1f3a5f;
    color: #ffffff;
}

.adm-btn--primary:hover {
    background: #172a45;
    border-color: #172a45;
}

.adm-btn--secondary {
    background: #ffffff;
    border-color: #cbd2d9;
    color: #1f2933;
}

.adm-btn--secondary:hover {
    background: #f4f6fa;
}

.adm-btn--danger {
    background: #c0392b;
    border-color: #c0392b;
    color: #ffffff;
}

.adm-btn--danger:hover {
    background: #962d22;
    border-color: #962d22;
}

.adm-btn--ghost {
    background: transparent;
    border-color: transparent;
    color: #2456a6;
}

.adm-btn--ghost:hover {
    background: #eef3fb;
}

.adm-btn[disabled],
.adm-btn--disabled {
    background: #f1f3f5;
    border-color: #e4e7eb;
    color: #9aa5b1;
    cursor: not-allowed;
    pointer-events: none;
}

.adm-btn--sm {
    padding: 0.3rem 0.6rem;
    font-size: 0.75rem;
}

.adm-control-sm {
    height: 32px;
    box-sizing: border-box;
    border-radius: 6px;
    line-height: 1.1;
    vertical-align: middle;
}

button.adm-control-sm,
a.adm-control-sm {
    display: inline-flex;
    align-items: center;
    padding: 0 0.8rem;
    font-size: 0.8rem;
}

select.adm-control-sm {
    width: auto;
    min-width: 4.25rem;
    padding: 0 1.7rem 0 0.6rem;
    font-size: 0.82rem;
}

.adm-table-toolbar__actions {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.adm-table-toolbar__actions .adm-inline-form {
    display: inline-flex;
    align-items: center;
}

.adm-badge {
    display: inline-block;
    padding: 0.18rem 0.55rem;
    font-size: 0.7rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-radius: 6px;
    background: #eef0f3;
    color: #52606d;
    border: 1px solid currentColor;
    line-height: 1.4;
}

.adm-badge--active,
.adm-badge--allowed,
.adm-badge--verified {
    background: #e6f4ea;
    color: #1e6431;
}

.adm-badge--inactive {
    background: #eef0f3;
    color: #52606d;
}

.adm-badge--pending,
.adm-badge--info {
    background: #eaf2ff;
    color: #1c3d80;
}

.adm-badge--suspended,
.adm-badge--warning,
.adm-badge--mismatch {
    background: #fff5e0;
    color: #7a5300;
}

.adm-badge--expired,
.adm-badge--denied,
.adm-badge--critical {
    background: #fdecea;
    color: #a8261d;
}

.adm-badge--blocked {
    background: #f3e1f6;
    color: #6b1f7a;
}

.adm-field {
    display: block;
    margin-bottom: 0.85rem;
}

.adm-field__label {
    display: block;
    font-weight: 600;
    font-size: 0.78rem;
    color: #52606d;
    margin-bottom: 0.25rem;
}

.adm-field__input,
.adm-field__select {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid #cbd2d9;
    border-radius: 6px;
    background: #ffffff;
    color: #1f2933;
    font-size: 0.92rem;
    font-family: inherit;
}

.adm-field__input:focus,
.adm-field__select:focus {
    outline: 2px solid #4f8ef7;
    outline-offset: -1px;
}

.adm-field__hint {
    margin: 0.25rem 0 0;
    color: #9aa5b1;
    font-size: 0.75rem;
}

.adm-filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-bottom: 1rem;
}

.adm-filter-row .adm-field {
    margin: 0;
    min-width: 12rem;
}

.adm-drawer {
    position: fixed;
    inset: 0;
    background: rgba(15, 31, 58, 0.45);
    display: none;
    z-index: 50;
}

.adm-drawer[hidden] {
    display: none !important;
}

.adm-drawer--open {
    display: block;
}

.adm-drawer__panel {
    position: absolute;
    top: 0;
    right: 0;
    width: min(420px, 100%);
    height: 100%;
    background: #ffffff;
    box-shadow: -8px 0 24px rgba(15, 31, 58, 0.2);
    display: flex;
    flex-direction: column;
}

.adm-drawer__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #e4e7eb;
}

.adm-drawer__title {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    color: #0f1f3a;
}

.adm-drawer__close {
    background: none;
    border: 0;
    font-size: 1.25rem;
    line-height: 1;
    color: #52606d;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

.adm-drawer__close:hover {
    background: #f4f6fa;
    color: #1f2933;
}

.adm-drawer__body {
    padding: 1.25rem;
    overflow-y: auto;
    flex: 1;
}

.adm-dl {
    display: grid;
    grid-template-columns: 200px minmax(0, 1fr);
    gap: 0.65rem 1.25rem;
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.5;
}

.adm-dl dt {
    color: #7b8794;
    font-weight: 500;
}

.adm-dl dd {
    margin: 0;
    color: #1f2933;
    word-break: break-word;
    min-width: 0;
}

@media (max-width: 640px) {
    .adm-dl {
        grid-template-columns: minmax(0, 1fr);
        gap: 0.15rem 0;
    }
}

.adm-section {
    background: #ffffff;
    border: 1px solid #e4e7eb;
    border-radius: 8px;
    padding: 1.5rem 1.75rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 2px rgba(15, 31, 58, 0.04);
}

.adm-section__title {
    margin: 0 0 0.6rem;
    font-size: 1.05rem;
    font-weight: 600;
    color: #0f1f3a;
}

.adm-section__subtitle {
    margin: 0 0 0.75rem;
    color: #52606d;
    font-size: 0.9rem;
    line-height: 1.5;
}

.adm-section > .adm-dl,
.adm-section > .adm-table-wrap,
.adm-section > .adm-bullets,
.adm-section > .adm-form,
.adm-section > .adm-card__hint,
.adm-section > .adm-alert,
.adm-section > .adm-card-grid {
    margin-top: 0.85rem;
}

.adm-section__actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: 1.1rem;
}

.adm-inline-form {
    display: inline;
    margin: 0;
    padding: 0;
}

.adm-visually-hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.adm-action-group {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    flex-wrap: nowrap;
}

.adm-action-group .adm-inline-form {
    display: inline-flex;
    margin: 0;
}

.adm-icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 1px solid currentColor;
    border-radius: 6px;
    background: #fff;
    color: #1f2933;
    cursor: pointer;
    line-height: 1;
    text-decoration: none;
}

.adm-icon-btn:hover {
    background: rgba(31, 41, 51, 0.06);
    color: inherit;
    text-decoration: none;
}

.adm-icon-btn:focus-visible {
    outline: 2px solid #2456a6;
    outline-offset: 1px;
}

.adm-icon-btn--secondary {
    border-color: #cbd2d9;
    color: #1f2933;
}

.adm-icon-btn--secondary:hover {
    background: #f4f6fa;
}

.adm-icon-btn--neutral,
.adm-icon-btn--neutral:link,
.adm-icon-btn--neutral:visited {
    color: #1f2933;
}

.adm-icon-btn--neutral:hover {
    background: rgba(31, 41, 51, 0.08);
    color: #1f2933;
}

.adm-icon-btn--danger,
.adm-icon-btn--danger:link,
.adm-icon-btn--danger:visited {
    color: #c0392b;
}

.adm-icon-btn--danger:hover {
    background: rgba(192, 57, 43, 0.10);
    color: #962d22;
}

.adm-icon-btn--success,
.adm-icon-btn--success:link,
.adm-icon-btn--success:visited {
    color: #1d8348;
}

.adm-icon-btn--success:hover {
    background: rgba(29, 131, 72, 0.10);
    color: #166637;
}

.adm-icon-btn--warning,
.adm-icon-btn--warning:link,
.adm-icon-btn--warning:visited {
    color: #b7791f;
}

.adm-icon-btn--warning:hover {
    background: rgba(183, 121, 31, 0.12);
    color: #8a5a17;
}

.adm-icon-btn[disabled],
.adm-icon-btn--disabled {
    color: #9aa5b1;
    cursor: not-allowed;
    pointer-events: none;
}

.adm-icon {
    display: block;
    width: 16px;
    height: 16px;
}

@media (max-width: 800px) {
    .adm-shell {
        grid-template-columns: 1fr;
    }
    .adm-sidebar {
        position: static;
        min-height: 0;
    }
    .adm-nav {
        display: none;
        padding-bottom: 0.75rem;
    }
    .adm-shell[data-nav="open"] .adm-nav {
        display: block;
    }
    .adm-sidebar__footer {
        display: none;
    }
    .adm-sidebar__brand {
        display: flex;
        align-items: center;
        justify-content: space-between;
    }
    .adm-sidebar__toggle {
        background: none;
        border: 1px solid rgba(255, 255, 255, 0.15);
        color: #d7dee8;
        border-radius: 6px;
        padding: 0.3rem 0.55rem;
        font-size: 0.8rem;
        cursor: pointer;
    }
}

@media (min-width: 801px) {
    .adm-sidebar__toggle {
        display: none;
    }
}

.adm-form {
    max-width: 720px;
}

.adm-form--two-col {
    max-width: none;
}

.adm-form-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0 1.5rem;
}

.adm-form-grid--two {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.adm-form-column {
    min-width: 0;
}

@media (max-width: 900px) {
    .adm-form-grid--two {
        grid-template-columns: minmax(0, 1fr);
    }
}

.adm-form__actions {
    display: flex;
    gap: 0.6rem;
    margin-top: 1rem;
    flex-wrap: wrap;
}

.adm-fieldset {
    border: 1px solid #e4e7eb;
    border-radius: 6px;
    padding: 0.75rem 1rem 0.25rem;
    margin: 0.5rem 0 1rem;
}

.adm-fieldset legend {
    padding: 0 0.4rem;
    font-weight: 600;
    color: #52606d;
    font-size: 0.85rem;
}

.adm-field--check .adm-field__check {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.92rem;
    color: #1f2933;
    cursor: pointer;
}

.adm-field--check input[type="checkbox"] {
    width: 1rem;
    height: 1rem;
    accent-color: #2456a6;
}

.adm-muted {
    color: #9aa5b1;
}

.adm-bullets {
    margin: 0.25rem 0 0;
    padding-left: 1.25rem;
    color: #2d3748;
    font-size: 0.92rem;
    line-height: 1.55;
}

.adm-bullets li {
    margin: 0.15rem 0;
}

.adm-chip {
    display: inline-block;
    background: #eef2f6;
    color: #1f2933;
    border: 1px solid #dde3ea;
    border-radius: 6px;
    padding: 0.05rem 0.55rem;
    font-size: 0.75rem;
    line-height: 1.4;
    margin: 0.05rem 0.1rem 0.05rem 0;
    white-space: nowrap;
}

.adm-license-key code {
    display: inline-block;
    font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, "Liberation Mono", monospace;
    font-size: 1rem;
    background: #1f2933;
    color: #f4f6fa;
    padding: 0.4rem 0.6rem;
    border-radius: 6px;
    word-break: break-all;
}

.adm-alert__list {
    margin: 0;
    padding-left: 1.2rem;
}

.adm-alert__list li {
    margin: 0.1rem 0;
}

textarea.adm-field__input {
    resize: vertical;
    min-height: 6em;
}

.adm-page--wide {
    max-width: none;
}

.adm-search {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex-wrap: wrap;
    margin: 0 0 1rem;
}

.adm-search__field {
    display: flex;
    align-items: stretch;
    flex: 1 1 18rem;
    min-width: 12rem;
    max-width: 28rem;
}

.adm-search__input {
    flex: 1 1 auto;
    border: 1px solid #cdd2d9;
    border-right: 0;
    border-radius: 6px 0 0 6px;
    padding: 0.45rem 0.7rem;
    font-size: 0.9rem;
    color: #1f2933;
    background: #fff;
}

.adm-search__input:focus {
    outline: 2px solid #2456a6;
    outline-offset: -1px;
}

.adm-search__submit {
    border: 1px solid #2456a6;
    background: #2456a6;
    color: #fff;
    padding: 0 1rem;
    border-radius: 0 6px 6px 0;
    cursor: pointer;
    font-size: 0.85rem;
}

.adm-search__submit:hover {
    background: #1c4385;
}

.adm-search__clear {
    color: #52606d;
    font-size: 0.85rem;
    text-decoration: underline;
}

.adm-search__status {
    color: #52606d;
    font-size: 0.85rem;
}

.adm-two-col {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
    gap: 1.25rem;
    align-items: start;
}

.adm-two-col > .adm-two-col__left,
.adm-two-col > .adm-two-col__right {
    min-width: 0;
}

.adm-two-col .adm-form {
    max-width: none;
}

@media (max-width: 1000px) {
    .adm-two-col {
        grid-template-columns: minmax(0, 1fr);
    }
}

.adm-ops-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 1.25rem;
    align-items: stretch;
}

.adm-ops-grid > .adm-subcard {
    margin-bottom: 0;
    display: flex;
    flex-direction: column;
}

.adm-ops-grid > .adm-subcard > .adm-subcard__foot,
.adm-ops-grid > .adm-subcard > .adm-muted:last-child {
    margin-top: auto;
}

@media (max-width: 1000px) {
    .adm-ops-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

.adm-history-full {
    margin-top: 1.5rem;
}

.adm-ai-group {
    margin-top: 0.85rem;
    padding-top: 0.85rem;
    border-top: 1px solid #e4e7eb;
}

.adm-form--inline-hidden {
    display: none;
}

.adm-ai-group__title {
    margin: 0 0 0.5rem;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #52606d;
}

.adm-modal {
    position: fixed;
    inset: 0;
    background: rgba(15, 31, 58, 0.55);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    /* Generous, responsive side padding so a clickable backdrop margin always
       exists around the dialog — clicking it (or pressing Esc) closes the
       modal, even on narrower screens where the dialog would otherwise fill
       the full width. */
    padding: 3rem clamp(1rem, 5vw, 4rem);
    z-index: 50;
    overflow-y: auto;
    cursor: pointer;
}

.adm-modal__dialog {
    cursor: default;
}

.adm-modal__dialog {
    background: #fff;
    border-radius: 10px;
    width: 100%;
    max-width: 1100px;
    box-shadow: 0 16px 40px rgba(15, 31, 58, 0.25);
    border: 1px solid #e4e7eb;
    display: flex;
    flex-direction: column;
}

.adm-modal__header {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #e4e7eb;
}

.adm-modal__title {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 700;
    color: #0f1f3a;
    flex: 1 1 auto;
}

.adm-modal__close {
    color: #52606d;
    font-size: 0.85rem;
    text-decoration: none;
    padding: 0.3rem 0.6rem;
    border-radius: 6px;
    border: 1px solid #cdd2d9;
    background: #fff;
}

.adm-modal__close:hover {
    background: #f4f6fa;
    color: #1f2933;
}

.adm-modal__body {
    padding: 1.25rem;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
    gap: 1.25rem;
}

.adm-modal__body > * {
    min-width: 0;
}

@media (max-width: 900px) {
    .adm-modal__body {
        grid-template-columns: minmax(0, 1fr);
    }
}

.adm-modal__footer {
    padding: 0.9rem 1.25rem;
    border-top: 1px solid #e4e7eb;
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.adm-subcard {
    border: 1px solid #e4e7eb;
    border-radius: 8px;
    padding: 0.9rem 1rem;
    background: #fff;
    margin: 0 0 0.85rem;
}

.adm-subcard:last-child {
    margin-bottom: 0;
}

.adm-subcard__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
    min-height: 1.9rem;
}

.adm-subcard__header .adm-subcard__title {
    margin: 0;
}

.adm-subcard__head-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 0 0 auto;
}

.adm-subcard__actions {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.adm-subcard__title {
    margin: 0 0 0.5rem;
    font-size: 0.95rem;
    font-weight: 700;
    color: #0f1f3a;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.adm-ops-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    height: 30px;
    min-width: 96px;
    padding: 0 0.6rem;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-radius: 6px;
    border: 1px solid currentColor;
    line-height: 1;
    white-space: nowrap;
}

.adm-ops-pill--ok {
    background: #e6f4ea;
    color: #1e6431;
}

.adm-ops-pill--warn {
    background: #fff5e0;
    color: #7a5300;
}

.adm-ops-pill--danger {
    background: #fdecea;
    color: #a8261d;
}

.adm-ops-pill--muted {
    background: #eef0f3;
    color: #52606d;
}

.adm-ops-meta {
    margin-top: 1.25rem;
}

.adm-meta-strip {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.5rem 2rem;
    padding: 0.7rem 1rem;
    background: #f7f9fb;
    border: 1px solid #e4e7eb;
    border-radius: 8px;
}

.adm-meta-strip__title {
    margin: 0;
    font-size: 0.75rem;
    font-weight: 700;
    color: #52606d;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.adm-meta-strip__item {
    font-size: 0.82rem;
    color: #1f2933;
    white-space: nowrap;
}

.adm-meta-strip__item .adm-meta-strip__label {
    color: #7b8794;
    font-weight: 600;
    margin-right: 0.35rem;
}

.adm-form__actions--bottom {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid #e4e7eb;
}

.adm-subcard__count {
    background: #eef2f6;
    color: #52606d;
    border-radius: 6px;
    padding: 0.05rem 0.55rem;
    font-size: 0.72rem;
    font-weight: 500;
}

.adm-subcard__note {
    color: #7b8794;
    font-size: 0.8rem;
    margin: 0.5rem 0 0;
}

.adm-detail-list {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    margin: 0;
    font-size: 0.85rem;
}

.adm-detail-row {
    display: grid;
    grid-template-columns: 160px 1fr;
    gap: 1.25rem;
    align-items: baseline;
}

.adm-detail-label {
    color: #7b8794;
    font-weight: 600;
    margin: 0;
}

.adm-detail-value {
    color: #1f2933;
    margin: 0;
    word-break: break-word;
    min-width: 0;
}

.adm-detail-value a {
    word-break: break-all;
}

@media (max-width: 640px) {
    .adm-detail-row {
        grid-template-columns: 1fr;
        gap: 0.15rem;
    }
}

.adm-license-row {
    border-top: 1px solid #eef2f6;
    padding: 0.6rem 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
}

.adm-license-row:first-of-type {
    border-top: 0;
}

.adm-license-row__main {
    flex: 1 1 16rem;
    min-width: 0;
}

.adm-license-row__meta {
    color: #52606d;
    font-size: 0.8rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin: 0.2rem 0 0;
}

.adm-license-row__actions {
    display: flex;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.adm-license-row__actions .adm-inline-form {
    margin: 0;
}

.adm-reissue-warn {
    color: #7b8794;
    font-size: 0.75rem;
    margin: 0.3rem 0 0;
    flex-basis: 100%;
}

.adm-filter-strip {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0 0 0.5rem;
    flex-wrap: wrap;
}

.adm-filter-strip__label {
    font-size: 0.8125rem;
    color: #4a5568;
    font-weight: 600;
}

.adm-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.18rem 0.6rem;
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1.4;
    border-radius: 6px;
    border: 1px solid currentColor;
    background: #fff;
    color: #52606d;
    text-decoration: none;
    white-space: nowrap;
}

.adm-pill:hover {
    text-decoration: none;
}

.adm-pill--active {
    color: #1e6431;
    background: #f1f9f3;
}

.adm-pill--archived,
.adm-pill--warning {
    color: #7a5300;
    background: #fff8e6;
}

.adm-pill--danger {
    color: #a8261d;
    background: #fdecea;
}

.adm-pill--neutral {
    color: #52606d;
    background: #f5f7fa;
}

.adm-pill--selected {
    box-shadow: inset 0 0 0 1px currentColor;
}

/* Deferred / planned area: a notice banner plus a greyed-out, inert config block. */
.adm-deferred-banner {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin: 0.25rem 0 1rem;
    padding: 0.7rem 0.9rem;
    font-size: 0.85rem;
    line-height: 1.5;
    color: #52606d;
    background: #f5f7fa;
    border: 1px solid #e3e8ef;
    border-radius: 8px;
}

.adm-deferred {
    /* Native <fieldset disabled> makes the controls inert; this dims the whole
       block so it reads clearly as "planned, not active". */
    border: 0;
    margin: 0;
    padding: 0;
    min-width: 0;
    opacity: 0.55;
}

/* Analytics: simple horizontal bar list (label | track | value). */
.adm-bars {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.adm-bars__row {
    display: grid;
    grid-template-columns: minmax(8rem, 18rem) 1fr 3rem;
    align-items: center;
    gap: 0.75rem;
}

.adm-bars__label {
    font-size: 0.85rem;
    color: #1f2933;
    overflow-wrap: anywhere;
}

.adm-bars__track {
    position: relative;
    height: 0.7rem;
    background: #eef1f5;
    border-radius: 999px;
    overflow: hidden;
}

.adm-bars__fill {
    height: 100%;
    background: #2f5d8a;
    border-radius: 999px;
    min-width: 2px;
}

.adm-bars__value {
    text-align: right;
    font-variant-numeric: tabular-nums;
    font-weight: 600;
    color: #1f2933;
}

.adm-num {
    font-variant-numeric: tabular-nums;
}

/* Analytics: grouped vertical-column chart (customers / licenses / installations). */
.adm-chart {
    margin-bottom: 1.25rem;
}

.adm-chart__legend {
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem;
    margin-bottom: 0.9rem;
    font-size: 0.8rem;
    color: #52606d;
}

.adm-chart__key {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.adm-chart__key::before {
    content: "";
    width: 0.7rem;
    height: 0.7rem;
    border-radius: 2px;
    background: #9aa5b1;
}

.adm-chart__key--cust::before { background: #2f5d8a; }
.adm-chart__key--lic::before  { background: #3f8f6b; }
.adm-chart__key--inst::before { background: #b9842f; }

.adm-chart__plot {
    display: flex;
    align-items: flex-end;
    gap: 0.5rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid #e3e8ef;
}

.adm-chart__col {
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
}

.adm-chart__bars {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 2px;
    width: 100%;
    height: 170px;
}

.adm-chart__bar {
    width: 32%;
    max-width: 14px;
    min-height: 0;
    border-radius: 3px 3px 0 0;
    background: #9aa5b1;
}

.adm-chart__bar--cust { background: #2f5d8a; }
.adm-chart__bar--lic  { background: #3f8f6b; }
.adm-chart__bar--inst { background: #b9842f; }

.adm-chart__xlabel {
    font-size: 0.7rem;
    color: #7a8794;
    white-space: nowrap;
}

.adm-filter-strip__link {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.18rem 0.6rem;
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1.4;
    border-radius: 6px;
    border: 1px solid currentColor;
    background: #fff;
    color: #52606d;
    text-decoration: none;
    white-space: nowrap;
}

.adm-filter-strip__link:hover {
    text-decoration: none;
    filter: brightness(0.98);
}

.adm-filter-strip__link--active {
    box-shadow: inset 0 0 0 1px currentColor;
    filter: brightness(0.97);
}

.adm-filter-strip__link--active:hover {
    filter: brightness(0.94);
}

.adm-json-block {
    background: #f7f9fb;
    border: 1px solid #dde3ea;
    border-radius: 6px;
    padding: 0.6rem 0.75rem;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 0.75rem;
    line-height: 1.45;
    color: #1f2933;
    white-space: pre-wrap;
    word-break: break-word;
    margin: 0;
    overflow-x: auto;
    max-height: 28rem;
}

.adm-count-badge {
    display: inline-block;
    min-width: 1.1rem;
    padding: 0 0.35rem;
    margin-left: 0.4rem;
    font-size: 0.68rem;
    font-weight: 600;
    line-height: 1.5;
    text-align: center;
    color: #ffffff;
    background: #c8281d;
    border-radius: 999px;
    vertical-align: middle;
}

.adm-count-badge--topbar {
    margin-left: 0.35rem;
}

.adm-row--unread {
    background: #fff8ec;
    box-shadow: inset 3px 0 0 0 #e0a106;
}

.adm-row--unread td {
    font-weight: 500;
}

.adm-row--resolved {
    background: #f6f7f9;
    color: #8794a1;
}

.adm-badge--unread {
    background: #fdecea;
    color: #a8261d;
}

.adm-source__domain {
    color: #1f2933;
}

.adm-source__ip {
    display: inline-block;
    margin-top: 0.1rem;
    font-size: 0.86em;
    color: #3e4c59;
    font-weight: 500;
}

.adm-source__ip-value {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
    color: #1f2933;
}

.adm-event-label {
    cursor: help;
}

.adm-tech-code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
    font-size: 0.85em;
    color: #52606d;
}

.adm-wrap {
    display: inline-block;
    max-width: 32rem;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.adm-cell-sub {
    display: block;
    margin-top: 0.2rem;
    font-size: 0.82em;
    color: #6b7785;
    font-weight: 400;
    line-height: 1.35;
}

.adm-usage {
    display: inline-flex;
    flex-direction: column;
    gap: 0.1rem;
    font-size: 0.85em;
    line-height: 1.3;
    white-space: nowrap;
}

.adm-usage__num {
    display: inline-block;
    min-width: 1.4em;
    font-weight: 600;
    color: #1f2933;
}

/* ----------------------------------------------------------------------
   In-app documentation rendering (Help → Documentation library).
   Markdown is converted to this safe subset by App\Services\MarkdownRenderer.
---------------------------------------------------------------------- */
.adm-doc {
    font-size: 0.92rem;
    line-height: 1.6;
    color: #1f2933;
    max-width: none;
}
.adm-doc__nav { margin: 0 0 1rem; }
.adm-doc__h {
    margin: 1.4rem 0 0.6rem;
    line-height: 1.3;
    color: #102a43;
}
.adm-doc h2.adm-doc__h { font-size: 1.25rem; }
.adm-doc h3.adm-doc__h { font-size: 1.1rem; }
.adm-doc h4.adm-doc__h { font-size: 1rem; }
.adm-doc h5.adm-doc__h,
.adm-doc h6.adm-doc__h { font-size: 0.95rem; }
.adm-doc p { margin: 0.6rem 0; }
.adm-doc__list { margin: 0.5rem 0 0.5rem 1.4rem; }
.adm-doc__list li { margin: 0.25rem 0; }
.adm-doc code {
    background: #f0f4f8;
    border: 1px solid #e1e8ef;
    border-radius: 4px;
    padding: 0.05rem 0.3rem;
    font-size: 0.85em;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.adm-doc__pre {
    background: #0f2231;
    color: #e6edf3;
    border-radius: 8px;
    padding: 0.85rem 1rem;
    overflow-x: auto;
    margin: 0.8rem 0;
}
.adm-doc__pre code {
    background: transparent;
    border: 0;
    padding: 0;
    color: inherit;
    font-size: 0.82rem;
}
.adm-doc__quote {
    margin: 0.8rem 0;
    padding: 0.5rem 0.9rem;
    border-left: 3px solid #9fb3c8;
    background: #f5f7fa;
    color: #3e4c59;
}
.adm-doc__table { margin: 0.4rem 0; }
.adm-doc__hr {
    border: 0;
    border-top: 1px solid #e1e8ef;
    margin: 1.2rem 0;
}
.adm-doc__link { color: #2563eb; }
.adm-doc__link:hover { text-decoration: underline; }

/* ----------------------------------------------------------------------
   Help / documentation page layout (read-only, all roles).
   Scoped to .adm-help — does not affect the shared .adm-dl elsewhere.
---------------------------------------------------------------------- */
.adm-help { width: 100%; }

/* "On this page" quick navigation */
.adm-help__toc {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    background: #ffffff;
    border: 1px solid #e4e7eb;
    border-radius: 8px;
    padding: 0.7rem 1rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 2px rgba(15, 31, 58, 0.04);
}
.adm-help__toc-label {
    color: #7b8794;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-right: 0.35rem;
}
.adm-help__toc a {
    display: inline-block;
    padding: 0.28rem 0.7rem;
    border: 1px solid #d9e2ec;
    border-radius: 999px;
    font-size: 0.82rem;
    color: #334e68;
    text-decoration: none;
    background: #f7f9fc;
    transition: background .12s ease, border-color .12s ease, color .12s ease;
}
.adm-help__toc a:hover {
    background: #eef2f7;
    border-color: #bcccdc;
    color: #1f2933;
}
.adm-help__sec { scroll-margin-top: 1rem; }

/* Two-/three-column card grid for glossary, FAQ and roles.
   A real CSS grid (not multicol), so the two columns share aligned rows and the
   block always ends on a clean bottom edge — no masonry. align-items: stretch
   (grid default) keeps both cells in a row the same height. */
.adm-help-grid {
    display: grid;
    gap: 0 2.5rem;
}
.adm-help-grid--two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.adm-help-grid--three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.adm-help-grid__item {
    padding: 0.8rem 0;
    border-top: 1px solid #eef2f7;
}
.adm-help-grid__term {
    font-weight: 600;
    color: #102a43;
    line-height: 1.45;
    margin-bottom: 0.2rem;
}
.adm-help-grid__def {
    color: #3e4c59;
    line-height: 1.55;
    word-break: break-word;
}
@media (max-width: 980px) {
    .adm-help-grid--three { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 680px) {
    .adm-help-grid--two,
    .adm-help-grid--three { grid-template-columns: minmax(0, 1fr); }
}

/* ----------------------------------------------------------------------
   Customer "Portal access" subcard (operator manages per-portal accounts).
---------------------------------------------------------------------- */
.adm-portal-block {
    border-top: 1px solid #eef2f7;
    padding: 0.85rem 0;
}
.adm-portal-block:first-of-type { border-top: 0; }
.adm-portal-block__title {
    font-weight: 600;
    color: #102a43;
    margin-bottom: 0.35rem;
}
.adm-portal-block__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 0.55rem;
}
.adm-form--inline { display: inline-block; margin: 0; }
.adm-portal-reveal {
    margin-top: 0.5rem;
    font-size: 0.85rem;
    line-height: 1.7;
}
.adm-portal-reveal code {
    background: #fff;
    border: 1px solid #f3dca1;
    border-radius: 4px;
    padding: 0.05rem 0.35rem;
}

/* ----------------------------------------------------------------------
   In-page left sub-navigation (e.g. Settings): a sticky section menu that
   stays visible while the content column scrolls. Reusable on other long
   screens. The anchored sections use .adm-help__sec for scroll-margin.
---------------------------------------------------------------------- */
.adm-subnav-layout {
    display: grid;
    grid-template-columns: 210px minmax(0, 1fr);
    gap: 1.5rem;
    align-items: start;
}
.adm-subnav {
    position: sticky;
    top: 1rem;
    align-self: start;
    background: #ffffff;
    border: 1px solid #e4e7eb;
    border-radius: 8px;
    padding: 0.5rem;
    box-shadow: 0 1px 2px rgba(15, 31, 58, 0.04);
}
.adm-subnav__label {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #7b8794;
    padding: 0.4rem 0.65rem 0.55rem;
}
.adm-subnav nav {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}
.adm-subnav a {
    display: block;
    padding: 0.45rem 0.65rem;
    border-radius: 6px;
    font-size: 0.875rem;
    color: #334e68;
    text-decoration: none;
    border-left: 3px solid transparent;
}
.adm-subnav a:hover {
    background: #f0f4f8;
    color: #102a43;
    border-left-color: #4f8ef7;
}
.adm-subnav-content { min-width: 0; }

@media (max-width: 900px) {
    .adm-subnav-layout { grid-template-columns: minmax(0, 1fr); }
    .adm-subnav {
        position: static;
        display: flex;
        flex-wrap: wrap;
        gap: 0.3rem;
        align-items: center;
    }
    .adm-subnav nav { flex-direction: row; flex-wrap: wrap; gap: 0.3rem; }
    .adm-subnav a { border-left: 0; }
}

/* ----------------------------------------------------------------------
   List pagination bar (Page 1, 2, 3 …). Each link loads only its page.
---------------------------------------------------------------------- */
.adm-pagination {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.3rem;
    margin-top: 0.9rem;
    font-size: 0.85rem;
}
.adm-page-link {
    display: inline-block;
    min-width: 2rem;
    text-align: center;
    padding: 0.35rem 0.6rem;
    border: 1px solid #d9e2ec;
    border-radius: 6px;
    color: #334e68;
    background: #ffffff;
    text-decoration: none;
}
.adm-page-link:hover {
    background: #eef2f7;
    border-color: #bcccdc;
    color: #102a43;
    text-decoration: none;
}
.adm-page-link--active {
    background: #2456a6;
    border-color: #2456a6;
    color: #ffffff;
    font-weight: 600;
}
.adm-page-link--disabled {
    color: #9aa5b1;
    border-color: #e4e7eb;
    background: #f7f9fc;
    cursor: default;
}
.adm-page-ellipsis { color: #9aa5b1; padding: 0 0.15rem; }
.adm-page-summary { color: #7b8794; margin-left: auto; }

/* Combined list controls (pagination + rows), right-aligned, shown both above
   and below a table so you never need to scroll to change page. */
.adm-page-summary { margin-left: 0; }
.adm-listbar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 1rem;
    flex-wrap: wrap;
}
.adm-listbar .adm-pagination { margin-top: 0; }
.adm-table-footer { margin-top: 0.9rem; }

/* ---- Login: centered card + display-only language selector ------------- */
.adm-auth__card { text-align: center; }
.adm-auth__card label { text-align: center; }
.adm-auth__card input[type="email"],
.adm-auth__card input[type="text"],
.adm-auth__card input[type="password"] { text-align: left; }
.adm-auth__card .adm-btn { display: inline-block; }

.adm-langform {
    margin-top: 1.5rem;
    padding-top: 1.1rem;
    border-top: 1px solid #e2e8f0;
    text-align: center;
}
.adm-langform__label {
    display: block;
    font-size: 0.8rem;
    color: #7b8794;
    margin-bottom: 0.4rem;
}
.adm-langform__row {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
}
.adm-langform__select {
    flex: 1;
    max-width: 16rem;
    padding: 0.55rem 0.65rem;
    border: 1px solid #cbd2d9;
    border-radius: 6px;
    font-size: 0.95rem;
    background: #ffffff;
    color: #1f2933;
}
