/* Shared Bootstrap component corrections for GLIS public and portal pages. */
[hidden] { display: none !important; }
/* Standalone loading indicators take space only while their request runs. */
div.htmx-indicator:not(.htmx-request):not(.htmx-request *) { display: none; }
.card, .card-body, .glis-shell-content, main, .glis-field { min-width: 0; }
.card-body { overflow-wrap: anywhere; }
.glis-field { display: flex; flex-direction: column; gap: .3rem; margin: 0; padding: .15rem 0; border: 0; }
legend.form-label { float: none; width: auto; padding: 0; margin: 0; }
.form-label { white-space: normal; }
.choice-options { display: grid; gap: .5rem; min-width: 0; }
.choice-options label { display: flex; align-items: flex-start; gap: .6rem; min-width: 0; min-height: 1.5rem; color: var(--bs-body-color); font-size: .8125rem; line-height: 1.5; overflow-wrap: anywhere; cursor: pointer; }
.choice-options .form-check-input { flex-shrink: 0; margin: .2rem 0 0; }
.choice-options label:has(input:disabled) { cursor: not-allowed; }
.form-control, .form-select { max-width: 100%; }
.errorlist { margin-block: .35rem; padding: 0; list-style: none; color: var(--bs-danger); font-size: .8rem; }
.glis-input-shell { display: flex; align-items: center; gap: .5rem; }
.glis-input-shell > input { width: 100%; min-width: 0; border: 0; outline: 0; padding: 0; color: inherit; font: inherit; background: transparent; }
.glis-switch { width: 2em; border-radius: 2em !important; background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%239ca3af'/%3e%3c/svg%3e"); background-position: left center; transition: background-position .15s; }
.form-check-input.glis-switch:checked { background-position: right center; background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23fff'/%3e%3c/svg%3e"); }
html[dir="rtl"] .glis-switch { background-position: right center; }
html[dir="rtl"] .glis-switch:checked { background-position: left center; }
.portal-dashboard { grid-template-columns: minmax(0,1fr); min-width: 0; }
.portal-dashboard > *, .portal-dashboard-section, .portal-chart-grid, .portal-lower-grid, .portal-side-stack { min-width: 0; }
.portal-table-wrap { position: relative; max-width: 100%; }
.modal-dialog { width: auto; max-height: calc(100dvh - 2rem); }
.modal-body { overscroll-behavior: contain; }
.modal-footer { flex-wrap: wrap; gap: .5rem; margin: 1rem -1rem -1rem; }
.dropdown-menu { max-width: calc(100vw - 1.5rem); }
.glis-divided > * + * { border-top: 1px solid var(--bs-border-color); }
.glis-aura { position: relative; isolation: isolate; }
.glis-aura::before { content: ""; position: absolute; z-index: -1; inset: 0; border-radius: inherit; pointer-events: none; background: radial-gradient(ellipse at var(--aura-x,75%) var(--aura-y,15%), color-mix(in srgb,var(--bs-primary) 14%,transparent),transparent 70%); }
.glis-tilt { transform: perspective(1000px) rotateX(var(--rx,0deg)) rotateY(var(--ry,0deg)); transition: transform .2s ease, box-shadow .2s ease; }
.glis-glass { background: color-mix(in srgb,var(--bs-body-bg) 90%,transparent); backdrop-filter: blur(16px); }
.glis-portal-app :focus-visible, .public-shell :focus-visible { outline: 2px solid var(--bs-primary); outline-offset: 2px; }
.glis-skip-link { position: fixed; inset-block-start: .75rem; inset-inline-start: .75rem; z-index: 2000; padding: .5rem 1rem; border-radius: .5rem; background: var(--bs-primary); color: #fff; }
@media (prefers-reduced-motion: reduce) {
 .glis-tilt { transform: none !important; }
 *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
/* Editors keep their contents when enlarged and can also be resized by dragging. */
.richtext-editor .richtext-canvas { min-height: var(--glis-editor-height, 9rem) !important; height: var(--glis-editor-height, 9rem); resize: vertical; overflow: auto; }
.richtext-editor.is-expanded .richtext-canvas { height: min(65vh, 42rem); }
.richtext-editor .richtext-canvas:focus { outline: 2px solid var(--bs-primary); outline-offset: -2px; }
.ticket-activity pre { max-height: 20rem; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; }
.otp-digit { width: 0; min-width: 0; flex: 1 1 0; padding-inline: .25rem; font-size: 1.4rem; font-weight: 600; }
