/* Accessibility controls are outside the page layout, so they never resize content. */
#cetam-a11y-panel {
    position: fixed;
    z-index: 1035;
    inset-inline-start: max(.65rem, env(safe-area-inset-left));
    bottom: max(.65rem, env(safe-area-inset-bottom));
    color: #183457;
}
#cetam-a11y-panel summary {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    border: 1px solid #c7d9ef;
    border-radius: 50%;
    background: #fff;
    color: #214d85;
    box-shadow: 0 4px 14px #102b5640;
    cursor: pointer;
    list-style: none;
}
#cetam-a11y-panel summary::-webkit-details-marker { display: none; }
#cetam-a11y-panel summary:hover { background: #edf5ff; }
#cetam-a11y-panel .cetam-a11y-controls {
    position: absolute;
    inset-inline-start: 0;
    bottom: 54px;
    width: min(21rem, calc(100vw - 1.3rem));
    max-height: calc(100dvh - 80px);
    overflow: auto;
    padding: 1rem;
    border: 1px solid #c7d9ef;
    border-radius: .85rem;
    background: #fff;
    box-shadow: 0 8px 30px #102b5640;
}
.cetam-a11y-controls h2 { font-size: 1.1rem; margin-bottom: .8rem; }
.cetam-a11y-controls > label:not(.cetam-a11y-toggle) { display: block; margin: .65rem 0 .25rem; font-weight: 650; }
.cetam-a11y-controls .form-select { min-height: 44px; }
.cetam-a11y-toggle { display: flex; align-items: center; gap: .55rem; min-height: 44px; margin: 0; }
.cetam-a11y-controls .cetam-a11y-actions { display: flex; flex-wrap: wrap; gap: .45rem; margin-top: .6rem; }
.cetam-a11y-controls .btn { min-height: 44px; white-space: normal; }
.cetam-a11y-controls [role="status"]:empty { display: none; }
.cetam-a11y-controls [role="status"] { margin: .65rem 0 0; font-size: .86rem; }

html[data-cetam-text="large"] { font-size: 112.5%; }
html[data-cetam-text="largest"] { font-size: 125%; }
:where(a, button, input, textarea, select, summary, [tabindex]):focus-visible {
    outline: 3px solid #326eb7 !important;
    outline-offset: 3px;
}
@media (prefers-reduced-motion: no-preference) {
    .btn, .form-control, .form-select, .cetam-dashboard-card, .cetam-service-card, .course-card {
        transition: background-color .16s ease, border-color .16s ease, box-shadow .16s ease, color .16s ease;
    }
    .form-control:focus, .form-select:focus { box-shadow: 0 0 0 .19rem #3979cb30; }
    #cetam-a11y-panel[open] .cetam-a11y-controls { animation: cetam-a11y-enter .16s ease-out both; }
}
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
    .btn:is(.btn-primary, .btn-outline-primary):not(:disabled):hover { box-shadow: 0 .25rem .65rem #16396628; }
    .cetam-service-card:hover, .course-card:hover { border-color: #90b1d9; box-shadow: 0 .35rem .9rem #16396615; }
}
@keyframes cetam-a11y-enter {
    from { opacity: 0; transform: translateY(.3rem); }
    to { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
html[data-cetam-motion] *, html[data-cetam-motion] *::before, html[data-cetam-motion] *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
}

[data-cetam-contrast] body :is(.btn, .form-control, .form-select, .card, .table-responsive, .cetam-service-section) { border-color: currentColor !important; }
[data-cetam-contrast] a:not(.btn) { text-decoration: underline !important; text-underline-offset: .18em; }
[data-cetam-contrast] :where(a, button, input, textarea, select, summary, [tabindex]):focus-visible { outline-width: 4px !important; }
@media (forced-colors: active) {
    #cetam-a11y-panel :is(summary, .cetam-a11y-controls) { border: 1px solid ButtonText; }
    :where(a, button, input, textarea, select, summary, [tabindex]):focus-visible { outline-color: Highlight !important; }
}

@media print { #cetam-a11y-panel { display: none !important; } }

html:not([data-cetam-libras]) #vlibras-access-wrapper { display: none !important; }

[data-cetam-spacing] #region-main :is(p, li, dt, dd, blockquote) {
    line-height: 1.7 !important;
    letter-spacing: .045em;
    word-spacing: .1em;
}
[data-cetam-links] #page a[href]:not(.btn) {
    text-decoration: underline !important;
    text-decoration-thickness: .12em !important;
    text-underline-offset: .2em;
}
[data-cetam-focus] :is(a, button, input, textarea, select, summary, [tabindex]):focus-visible {
    outline: 4px solid #11478a !important;
    outline-offset: 4px;
    box-shadow: 0 0 0 4px #fff !important;
}
