/* ABIS shared form vocabulary. af-* is assigned only to legacy view elements. */
:root {
    --af-ink: #243750;
    --af-muted: #5b7895;
    --af-line: #d6e2ee;
    --af-soft: #edf3f8;
    --af-accent: #2866a6;
    --af-radius: 9px;
}
.abis-standalone { margin: 0; padding: 20px; background: #f1f5f9 !important; color: var(--af-ink) !important; font: 14px/1.5 'DM Sans','Segoe UI',Arial,sans-serif !important; }
.af-form { min-width: 0; color: var(--af-ink); }
.af-heading { color: var(--af-ink) !important; font-family: 'DM Sans','Segoe UI',Arial,sans-serif; font-weight: 650; letter-spacing: -.025em; line-height: 1.3; margin-bottom: 14px; }
h1.af-heading { font-size: 27px; } h2.af-heading { font-size: 24px; }
h3.af-heading { font-size: 21px; } h4.af-heading { font-size: 19px; }
h5.af-heading,h6.af-heading { font-size: 15px; }
.af-label { color: var(--af-ink); font-family: inherit !important; font-size: 13px !important; }
.af-control.af-control {
    box-sizing: border-box; max-width: 100%; min-height: 32px;
    padding: 5px 9px; border: 1px solid var(--af-line) !important;
    border-radius: 6px; background-color: #fff; color: var(--af-ink);
    font: 13px/1.45 'DM Sans','Segoe UI',Arial,sans-serif !important;
    box-shadow: none; vertical-align: middle;
}
textarea.af-control { min-height: 78px; resize: vertical; }
select.af-control { padding-right: 25px; }
select[multiple].af-control { min-height: 96px; }
.af-control:focus { border-color: var(--af-accent) !important; outline: 2px solid #a9cdef; outline-offset: 1px; }
.af-control:disabled,.af-control[readonly] { background-color: #edf2f7; color: #5c6f83; }
.af-control.input-validation-error,.af-control.is-invalid { border-color: #b34343 !important; }
.af-check { accent-color: var(--af-accent); vertical-align: middle; }
.af-button.af-button {
    border-radius: 7px; min-height: 32px; padding: 5px 11px;
    border: 1px solid var(--af-line); background: #f7faff; color: #36516b;
    font: 500 13px/1.4 'DM Sans','Segoe UI',Arial,sans-serif;
    text-decoration: none; box-shadow: none; vertical-align: middle;
}
.af-button:hover { background: #e7f0fa; border-color: #abc5df; color: #244b72; }
.af-button:is(.btn-primary,.btn-info,.btn-success),input[type="submit"].af-button,button[type="submit"].af-button { background: var(--af-accent) !important; border-color: var(--af-accent); color: #fff !important; }
.af-button:is(.btn-primary,.btn-info,.btn-success):hover,input[type="submit"].af-button:hover { background: #1e548b !important; border-color: #1e548b; }
.af-button.af-button:is(.btn-danger,.btn-outline-danger) { background: #fff2f1 !important; border-color: #e6bcbc; color: #a43737 !important; }
.af-button.af-button.btn-warning { background: #fff5df !important; border-color: #e5c98b; color: #805d16 !important; }
.af-button.btn-link { background: transparent; border-color: transparent; color: var(--af-accent); }
.af-button:disabled,.af-button.disabled { opacity: .55; cursor: default; }
.af-button:focus-visible,.af-check:focus-visible { outline: 3px solid #a9cdef; outline-offset: 2px; }
.af-toolbar { gap: 8px; row-gap: 8px; flex-wrap: wrap; padding: 4px 0 10px; }
.af-toolbar > .af-heading { margin: 0 10px 0 0; }
/* Match single-line fields, attached captions and actions in legacy search bars. */
.input-group:has(> .af-control, > .af-label, > .af-button) > :is(
    .input-group-text,
    input.af-control:not([type="file"]),
    select:not([multiple]):not([size]),
    select[size="1"]:not([multiple]),
    .af-button
) {
    box-sizing: border-box;
    height: 32px !important;
    min-height: 32px !important;
    padding-top: 5px !important;
    padding-bottom: 5px !important;
    font-size: 13px !important;
    line-height: 20px !important;
    margin-top: 0;
    margin-bottom: 0;
}
.input-group:has(> .af-control, > .af-label, > .af-button) > .input-group-text {
    display: inline-flex;
    align-items: center;
}
.af-table.af-table { width: 100%; max-width: 100%; margin-bottom: 14px; border-collapse: separate; border-spacing: 0; border: 1px solid var(--af-line); border-radius: var(--af-radius); background: #fff; color: var(--af-ink); font-size: 13px; }
.af-table > :is(thead,tbody,tfoot) > tr > :is(th,td),.af-table > tr > :is(th,td) { padding: 7px 10px !important; border: 0; border-bottom: 1px solid #e4ebf3; vertical-align: middle; font-size: 13px; }
.af-table > thead > tr > th { background: var(--af-soft); color: #49647f; font-weight: 600; font-size: 12px; box-shadow: none; }
.af-table > :is(tbody,tfoot):last-child > tr:last-child > :is(td,th) { border-bottom: 0; }
.af-table > thead:first-child > tr:first-child > :first-child { border-top-left-radius: var(--af-radius); }
.af-table > thead:first-child > tr:first-child > :last-child { border-top-right-radius: var(--af-radius); }
.af-table.table-hover > tbody > tr:hover > * { --bs-table-accent-bg: #f3f8fd; }
.af-field-table > :is(tbody,thead) > tr > td:has(> label):not(:has(input,select,textarea)),.af-field-table > tr > td:has(> label):not(:has(input,select,textarea)) { background: #edf3f8 !important; color: #49647f; }
.af-field-table label { margin: 0; font-size: 12px !important; }
.af-card { border: 1px solid var(--af-line); border-radius: 12px; background: #fff; box-shadow: 0 3px 12px #193e6310; }
.af-card > .card-header { background: var(--af-soft); border-bottom: 1px solid var(--af-line); color: var(--af-ink); }
.af-dialog.af-dialog { border: 1px solid var(--af-line); border-radius: 12px; background: #fff; color: var(--af-ink); box-shadow: 0 18px 55px #17345130; font-family: 'DM Sans','Segoe UI',Arial,sans-serif; }
.af-dialog > :is(.ui-dialog-titlebar,.modal-header,.jconfirm-title-c) { border: 0; border-bottom: 1px solid var(--af-line); border-radius: 11px 11px 0 0; background: #edf4fc; color: #233f59; padding: 12px 16px; }
.af-dialog > :is(.ui-dialog-buttonpane,.modal-footer) { border-top: 1px solid var(--af-line); padding: 10px 14px; background: #f9fbfd; }
.af-dialog .ui-dialog-buttonset { display: flex; gap: 8px; flex-wrap: wrap; }
.af-tabs { gap: 5px; border-color: var(--af-line); }
.af-tabs .nav-link { color: #526f8b; border-radius: 8px 8px 0 0; padding: 8px 13px; font-size: 13px; }
.af-tabs .nav-link.active { color: #244e78; background: #e8f1fa; border-color: var(--af-line); font-weight: 600; }
.af-pagination .page-link { border-color: var(--af-line); color: #365d86; font-size: 13px; }
.af-pagination .active .page-link { background: var(--af-accent); border-color: var(--af-accent); color: #fff; }
.af-alert { border-radius: 8px; font-size: 13px; }
.af-editor-column { width: 100%; flex: 0 1 720px; max-width: 100%; }
@media (max-width: 760px) {
    .abis-standalone { padding: 12px; }
    .af-table { display: block; overflow-x: auto; overscroll-behavior-x: contain; }
    .af-field-table { display: table; }
    .af-field-table > tbody > tr { display: flex; flex-wrap: wrap; }
    .af-field-table > tbody > tr > td { flex: 1 1 180px; min-width: 0; }
    .af-field-table .af-control { width: 100% !important; }
    .af-dialog.ui-dialog { max-width: calc(100vw - 16px) !important; }
    .af-toolbar { align-items: center; }
}
@media (prefers-reduced-motion: reduce) { .af-button,.af-control { transition: none; } }
@media print {
    .abis-standalone { background: #fff; padding: 0; }
    .af-table { display: table; overflow: visible; border-collapse: collapse; }
    .af-field-table > tbody > tr { display: table-row; }
    .af-field-table > tbody > tr > td { display: table-cell; }
    .af-card,.af-dialog { box-shadow: none; }
}
