/* uproot color scheme */
:root {
    --bs-uproot: #4e1388;
    --bs-uproot-rgb: 68, 17, 119;
    --bs-uproot-rgb: 78, 19, 136;
    --bs-uproot-bg-light: #f0e5fb;  /* rgb(240, 229, 251) */
    --bs-uproot-bg-subtle: #faf6fe;  /* rgb(250, 246, 254) */
    --bs-uproot-border-light: #9241e4;
    --bs-uproot-border-light-rgb: 146, 65, 228;
    --bs-uproot-border-subtle: #ba86ee;
    --bs-uproot-border-subtle-rgb: 186, 134, 238;
    --bs-uproot-border-subtle-light: #dcbef4;
    --bs-uproot-border-subtle-light-rgb: 220, 190, 244;
    --bs-uproot-dark: #300c55;
    --bs-uproot-dark-rgb: 48, 12, 85;
}

/* Make body text black in light theme (instead of Bootstrap’s default #212529) */
:root,
[data-bs-theme=light] {
    --bs-body-color: var(--bs-black, #000);
    --bs-body-color-rgb: var(--bs-black-rgb, 0, 0, 0);
}

.bg-uproot {
    background-color: var(--bs-uproot) !important;
}
.bg-uproot-light {
    background-color: var(--bs-uproot-bg-light) !important;
}
.bg-uproot-subtle {
    background-color: var(--bs-uproot-bg-subtle) !important;
}

.border-opacity-0 {
    --bs-border-opacity: 0;
}

.border-uproot {
    --bs-border-opacity: 1;
    border-color: rgba(var(--bs-uproot-rgb), var(--bs-border-opacity)) !important;
}
.border-uproot-light {
    --bs-border-opacity: 1;
    border-color: rgba(var(--bs-uproot-border-light-rgb), var(--bs-border-opacity)) !important;
}
.border-uproot-subtle {
    --bs-border-opacity: 1;
    border-color: rgba(var(--bs-uproot-border-subtle-rgb), var(--bs-border-opacity)) !important;
}
.border-uproot-subtle-light {
    --bs-border-opacity: 1;
    border-color: rgba(var(--bs-uproot-border-subtle-light-rgb), var(--bs-border-opacity)) !important;
}

.btn-uproot {
    --bs-btn-color: #fff;
    --bs-btn-bg: var(--bs-uproot);
    --bs-btn-border-color: var(--bs-uproot);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--bs-uproot-dark);
    --bs-btn-hover-border-color: var(--bs-uproot-dark);
    --bs-btn-focus-shadow-rgb: 49, 132, 253;
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--bs-uproot-dark);
    --bs-btn-active-border-color: var(--bs-uproot-dark);
    --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
    --bs-btn-disabled-color: #fff;
    --bs-btn-disabled-bg: var(--bs-uproot);
    --bs-btn-disabled-border-color: var(--bs-uproot);
}
.btn-outline-uproot {
    --bs-btn-color: var(--bs-uproot);
    --bs-btn-border-color: var(--bs-uproot);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--bs-uproot);
    --bs-btn-hover-border-color: var(--bs-uproot);
    --bs-btn-focus-shadow-rgb: 13, 110, 253;
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--bs-uproot);
    --bs-btn-active-border-color: var(--bs-uproot);
    --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
    --bs-btn-disabled-color: var(--bs-uproot);
    --bs-btn-disabled-bg: transparent;
    --bs-btn-disabled-border-color: var(--bs-uproot);
    --bs-gradient: none;
}
.btn-xs {
    --bs-btn-font-size: .75rem;
    --bs-btn-padding-x: .5rem;
    --bs-btn-padding-y: .25rem;
    --bs-btn-border-radius: var(--bs-border-radius-sm);
}

/* Dedicated classes for switching to sans-serif and serif font */
/* Adapted from https://tailwindcss.com/docs/font-family, extending Bootstrap’s default fonts  */
:root {
    --bs-font-math: "STIX Two Math", "Latin Modern Math", "Cambria Math", "XITS Math", "DejaVu Math TeX Gyre", "Asana Math", "Noto Sans Math", "Symbola", math, serif;
    --bs-font-monospace: "Cascadia Mono", "Cascadia Code", ui-monospace, SFMono-Regular, Menlo, Monaco, "Segoe UI Mono", "Roboto Mono", "Oxygen Mono", "Ubuntu Mono", "Source Code Pro", "Fira Mono", "Droid Sans Mono", Consolas, "Courier New", monospace;
    --bs-font-serif: ui-serif, "New York", "Noto Serif", "Liberation Serif", "Times New Roman", Times, Cambria, Georgia, serif;
}
/* Class for formulas in math font */
.font-math {
    font-family: var(--bs-font-math);
}
.font-sans-serif {
    font-family: var(--bs-font-sans-serif);
}
.font-serif {
    font-family: var(--bs-font-serif);
}

/* Follow a suggestion by https://www.joshwcomeau.com/css/custom-css-reset/#the-css-reset-1 */
button, input, select, textarea {
    font-family: inherit;
}

* {
    /* Enable selected features defined in inter.css to improve disambiguation of glyphs */
    font-variant-alternates:
    character-variant(lc-l-with-tail, alt-double-s)
    styleset(open-digits);
    /* Disable contextual alternates, since they may produce unwanted results with Inter (e.g., in “Step 1: ‘Go’” */
    font-feature-settings: "calt" 0;
    /* Settings related to number formatting */
    font-variant-numeric:
    var(--fvn-figure-style,)
    var(--fvn-spacing, proportional-nums)
    var(--fvn-fractions,)
    var(--fvn-zero,)
    var(--fvn-alt,);
    /* Follow a suggestion by https://www.joshwcomeau.com/css/custom-css-reset/#the-css-reset-1 */
    text-wrap: pretty;
}

/* Enable full disambiguation of glyphs for input fields (since every character may matter) */
input[type=email], input[type=file], input[type=text], input[type=url], textarea {
    font-variant-numeric: slashed-zero;
    font-variant-alternates: styleset(disambiguation, open-digits);
}

/* Inter and various other fonts have proportional figures enabled by default */
/* We enable tabular figures in tables and particular input fields */
input[type=date],
input[type=number],
span[id^="popover-content-"],
td, th, *[style*="table-cell"], .d-table-cell {
    --fvn-spacing: tabular-nums;
    font-variant-alternates:
    character-variant(lc-l-with-tail, alt-double-s)
    styleset(open-digits);
}
ol li::marker {
    --fvn-spacing: tabular-nums;  /* Probably unnecessary, most browsers’ default behavior */
}
.ffs-calt, .ffs-calt-on {
    font-feature-settings: "calt" 1 !important;  /* Enable contextual alternates */
}
.ffs-calt-off {
    font-feature-settings: "calt" 0 !important;  /* Disable contextual alternates */
}
.ffs-lnum, .fvn-lining-nums {
    --fvn-figure-style: lining-nums !important;
    /* Equivalent to font-feature-settings: "lnum" !important; */
}
.ffs-onum, .fvn-oldstyle-nums {
    --fvn-figure-style: oldstyle-nums !important;
    /* Equivalent to font-feature-settings: "onum" !important; */
}
.ffs-pnum, .fvn-proportional-nums {
    --fvn-spacing: proportional-nums !important;
    /* Equivalent to font-feature-settings: "pnum" !important; */
}
.ffs-tnum, .fvn-tabular-nums {
    --fvn-spacing: tabular-nums !important;
    /* Equivalent to font-feature-settings: "tnum" !important; */
}
.ffs-zero, .fvn-slashed-zero {
    --fvn-zero: slashed-zero !important;
    /* Equivalent to font-feature-settings: "zero" !important; */
}
.ffa-disambiguation {
    --fvn-zero: slashed-zero !important;
    font-variant-alternates: styleset(disambiguation) !important;
}
.ffa-disambiguation-except-zero {
    font-variant-alternates: styleset(disambiguation-except-zero) !important;
}

/* Adding classes for highlighting, inspired by https://getbootstrap.com/docs/5.3/docsref/#callouts */
/* Use in conjunction with utilities like .alert, .bg-*, .border-*, card, etc. */
.callout {
    border-bottom-width: 0px;
    border-left-width: 5px !important;
    border-right-width: 0px;
    border-top-width: 0px;
    border-radius: 0px;
    margin-left: 1px;
}

/* Override bootstrap.css to make font size of <code> elements match the surrounding text */
code {
    font-size: unset;
}
code, .font-monospace {
    font-size-adjust: ex-height 0.54;  /* Match Cascadia Mono to Inter */
}

/* Extension of the Bootstrap .fs-* classes */
.fs-sm {
    font-size: small;
}
.fs-xs {
    font-size: x-small;
}
.fs-xxs {
    font-size: xx-small;
}

/* Extension of the Bootstrap .fw- classes */
.fw-100 {
    font-weight: 100 !important;  /* Thin (Hairline) */
}
.fw-200 {
    font-weight: 200 !important;  /* ExtraLight/UltraLight */
}
.fw-300 {
    font-weight: 300 !important;  /* Light */
}
.fw-350 {
    font-weight: 350 !important;  /* SemiLight/Book (for some fonts, Book is lighter than Normal) */
}
.fw-400 {
    font-weight: 400 !important;  /* Normal/Regular */
}
.fw-450 {
    font-weight: 450 !important;  /* Book/Text (for some fonts, Book is heavier than Normal) */
}
.fw-500 {
    font-weight: 500 !important;  /* Medium */
}
.fw-600 {
    font-weight: 600 !important;  /* SemiBold/DemiBold */
}
.fw-700 {
    font-weight: 700 !important;  /* Bold */
}
.fw-800 {
    font-weight: 800 !important;  /* ExtraBold/UltraBold */
}
.fw-900 {
    font-weight: 900 !important;  /* Black/Heavy */
}
.fw-950 {
    font-weight: 950 !important;  /* ExtraBlack/UltraBlack */
}
/* Mapping to common OpenType weight names according to https://developer.mozilla.org/en-US/docs/Web/CSS/font-weight */

/* Extension of the Bootstrap .g* and .m* classes */
/* 4.5 spacing value: 2.25rem */

/* 4.5 spacing value: 2.25rem */

/* Base gutter utilities */
.g-4-5,
.gx-4-5 {
    --bs-gutter-x: 2.25rem;
}
.g-4-5,
.gy-4-5 {
    --bs-gutter-y: 2.25rem;
}

/* Base margin utilities */
.m-4-5 {
    margin: 2.25rem !important;
}
.mb-4-5 {
    margin-bottom: 2.25rem !important;
}
.me-4-5 {
    margin-right: 2.25rem !important;
}
.ms-4-5 {
    margin-left: 2.25rem !important;
}
.mt-4-5 {
    margin-top: 2.25rem !important;
}
.mx-4-5 {
    margin-right: 2.25rem !important;
    margin-left: 2.25rem !important;
}
.my-4-5 {
    margin-top: 2.25rem !important;
    margin-bottom: 2.25rem !important;
}

/* sm */
@media (min-width: 576px) {
    .g-sm-4-5,
    .gx-sm-4-5 {
        --bs-gutter-x: 2.25rem;
    }
    .g-sm-4-5,
    .gy-sm-4-5 {
        --bs-gutter-y: 2.25rem;
    }
    .m-sm-4-5 {
        margin: 2.25rem !important;
    }
    .mb-sm-4-5 {
        margin-bottom: 2.25rem !important;
    }
    .me-sm-4-5 {
        margin-right: 2.25rem !important;
    }
    .ms-sm-4-5 {
        margin-left: 2.25rem !important;
    }
    .mt-sm-4-5 {
        margin-top: 2.25rem !important;
    }
    .mx-sm-4-5 {
        margin-right: 2.25rem !important;
        margin-left: 2.25rem !important;
    }
    .my-sm-4-5 {
        margin-top: 2.25rem !important;
        margin-bottom: 2.25rem !important;
    }
}

/* md */
@media (min-width: 768px) {
    .g-md-4-5,
    .gx-md-4-5 {
        --bs-gutter-x: 2.25rem;
    }
    .g-md-4-5,
    .gy-md-4-5 {
        --bs-gutter-y: 2.25rem;
    }
    .m-md-4-5 {
        margin: 2.25rem !important;
    }
    .mb-md-4-5 {
        margin-bottom: 2.25rem !important;
    }
    .me-md-4-5 {
        margin-right: 2.25rem !important;
    }
    .ms-md-4-5 {
        margin-left: 2.25rem !important;
    }
    .mt-md-4-5 {
        margin-top: 2.25rem !important;
    }
    .mx-md-4-5 {
        margin-right: 2.25rem !important;
        margin-left: 2.25rem !important;
    }
    .my-md-4-5 {
        margin-top: 2.25rem !important;
        margin-bottom: 2.25rem !important;
    }
}

/* lg */
@media (min-width: 992px) {
    .g-lg-4-5,
    .gx-lg-4-5 {
        --bs-gutter-x: 2.25rem;
    }
    .g-lg-4-5,
    .gy-lg-4-5 {
        --bs-gutter-y: 2.25rem;
    }
    .m-lg-4-5 {
        margin: 2.25rem !important;
    }
    .mb-lg-4-5 {
        margin-bottom: 2.25rem !important;
    }
    .me-lg-4-5 {
        margin-right: 2.25rem !important;
    }
    .ms-lg-4-5 {
        margin-left: 2.25rem !important;
    }
    .mt-lg-4-5 {
        margin-top: 2.25rem !important;
    }
    .mx-lg-4-5 {
        margin-right: 2.25rem !important;
        margin-left: 2.25rem !important;
    }
    .my-lg-4-5 {
        margin-top: 2.25rem !important;
        margin-bottom: 2.25rem !important;
    }
}

/* xl */
@media (min-width: 1200px) {
    .g-xl-4-5,
    .gx-xl-4-5 {
        --bs-gutter-x: 2.25rem;
    }
    .g-xl-4-5,
    .gy-xl-4-5 {
        --bs-gutter-y: 2.25rem;
    }
    .m-xl-4-5 {
        margin: 2.25rem !important;
    }
    .mb-xl-4-5 {
        margin-bottom: 2.25rem !important;
    }
    .me-xl-4-5 {
        margin-right: 2.25rem !important;
    }
    .ms-xl-4-5 {
        margin-left: 2.25rem !important;
    }
    .mt-xl-4-5 {
        margin-top: 2.25rem !important;
    }
    .mx-xl-4-5 {
        margin-right: 2.25rem !important;
        margin-left: 2.25rem !important;
    }
    .my-xl-4-5 {
        margin-top: 2.25rem !important;
        margin-bottom: 2.25rem !important;
    }
}

/* xxl */
@media (min-width: 1400px) {
    .g-xxl-4-5,
    .gx-xxl-4-5 {
        --bs-gutter-x: 2.25rem;
    }
    .g-xxl-4-5,
    .gy-xxl-4-5 {
        --bs-gutter-y: 2.25rem;
    }
    .m-xxl-4-5 {
        margin: 2.25rem !important;
    }
    .mb-xxl-4-5 {
        margin-bottom: 2.25rem !important;
    }
    .me-xxl-4-5 {
        margin-right: 2.25rem !important;
    }
    .ms-xxl-4-5 {
        margin-left: 2.25rem !important;
    }
    .mt-xxl-4-5 {
        margin-top: 2.25rem !important;
    }
    .mx-xxl-4-5 {
        margin-right: 2.25rem !important;
        margin-left: 2.25rem !important;
    }
    .my-xxl-4-5 {
        margin-top: 2.25rem !important;
        margin-bottom: 2.25rem !important;
    }
}

/* Extension of the Bootstrap .w-* classes */
.w-fit-content {
    width: fit-content !important;
}

/* Styling of Likert scales */
.likert-cell {
    min-width: 4ch;
}
.likert-item {
    --fvn-spacing: proportional-nums;
}
.uproot-likert caption {
    color: var(--bs-body-color);
}
.uproot-likert-responsive {
    display: block;
    border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-border-radius-lg);
    padding: 0.75rem 1rem;
}
.uproot-likert-responsive-caption {
    color: var(--bs-body-color);
    grid-column: 1 / -1;
}
.uproot-likert-responsive-caption .form-label {
    margin-bottom: 0.5rem;  /* Like .mb-2 */
}
.uproot-likert-responsive-corner,
.uproot-likert-responsive-choice-label,
.uproot-likert-responsive-scale-min,
.uproot-likert-responsive-scale-max {
    display: none;
}
.uproot-likert-responsive-choice-label {
    font-weight: 600;
}
.uproot-likert-responsive-option {
    align-items: center;
    column-gap: 0.5rem;
    display: grid;
    grid-template-columns: 50% auto 33%;
}
.uproot-likert-responsive-mobile-scale-label {
    white-space: nowrap;
}
.uproot-likert-responsive-mobile-label {
    color: var(--bs-tertiary-color);
    font-weight: 600;
    padding-right: 50%;
    text-align: right;
}
.uproot-likert-responsive-mobile-label .form-check-label {
    font-variant-numeric: tabular-nums !important;
}
.uproot-likert-responsive-choice-label,
.uproot-likert-responsive-option {
    border-bottom: 1px solid var(--bs-border-color);
    padding: 0.33rem;
    padding-left: 0;  /* flush with horizontal rules */
}
.uproot-likert-responsive-option-last {
    border-bottom: 0;
    padding-bottom: 0;
}
.uproot-likert-responsive-scale-min,
.uproot-likert-responsive-scale-max {
    border-bottom: 1px solid var(--bs-border-color);
    font-weight: normal;
    padding: 0.5rem 0;
}
.uproot-likert-responsive-scale-min {
    padding-right: 1rem;
    text-align: right;
}
.uproot-likert-responsive-scale-max {
    padding-left: 1rem;
    text-align: left;
}
.uproot-likert-matrix .likert-corner {
    width: 60%;
}
.uproot-likert-matrix .likert-scale-max {
    width: 45%;  /* Leave space between Likert matrix max/min labels */
    text-align: right;
}
.uproot-likert-matrix .likert-scale-min {
    width: 45%;  /* Leave space between Likert matrix max/min labels */
}
.uproot-likert-matrix .likert-item .form-text,
.likert-scale-max, .likert-scale-min {
    font-weight: normal;
}
.uproot-likert-matrix .form-label {
    margin-bottom: 0;
}

/* Likert grid: Responsive Likert matrix */
.uproot-likert-grid {
    display: grid;
    grid-template-columns:
        55%
        repeat(var(--likert-columns), minmax(0, 1fr));
    gap: 0;
    width: 100%;
}
.uproot-likert-grid-scale {
    display: none;
}
.uproot-likert-grid-header,
.uproot-likert-grid-item-label,
.uproot-likert-grid-cell {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--bs-border-color);
}
.uproot-likert-grid-item-label .form-label {
    margin-bottom: 0;
}
.uproot-likert-grid-choice-label,
.uproot-likert-grid-cell {
    text-align: center;
}
.uproot-likert-grid-choice-label {
    font-weight: 600;
}
.uproot-likert-grid-mobile-label,
.uproot-likert-grid-mobile-scale-label {
    display: none;
}
.uproot-likert-grid-radio {
    display: inline-flex;
    justify-content: center;
}
@media (min-width: 992px) {  /* Equals Bootstrap’s -lg- breakpoint */
    .uproot-likert-grid-scale {
        display: flex;
        justify-content: space-between;
        gap: 0.25rem;
        padding: 0.25rem;
    }
    .uproot-likert-grid-item-label {
        padding-left: 0;  /* flush with horizontal rules */
        padding-right: 1rem;  /* like .pe-3 */
    }
}
@media (max-width: 991px) {  /* 1px less than Bootstrap’s -lg- breakpoint, since Bootstrap uses min-width */
    .uproot-likert-grid {
        display: block;
    }
    .uproot-likert-grid-scale,
    .uproot-likert-grid-scale-corner,
    .uproot-likert-grid-header {
        display: none;
    }
    .uproot-likert-grid-item-label {
        border: 1px solid var(--bs-border-color);
        border-bottom: 0;
        border-radius: 0.5rem 0.5rem 0 0;
        margin-top: 1rem;
        font-weight: 600;
        text-align: left;
    }
    .uproot-likert-grid-cell {
        border-left: 1px solid var(--bs-border-color);
        border-right: 1px solid var(--bs-border-color);
        border-bottom: 0;
        display: grid;
        grid-template-columns: 33% 33% auto;
        align-items: center;
        column-gap: 0;
        padding-bottom: 0;
        padding-top: 0.33rem;
        text-align: left;
    }
    .uproot-likert-grid-cell-last {
        border-radius: 0 0 0.5rem 0.5rem;
        border-bottom: 1px solid var(--bs-border-color);
        padding-bottom: 0.25rem;
    }
    .uproot-likert-grid-mobile-scale-label {
        border-bottom: 1px solid var(--bs-border-color);
        display: block;
        grid-column: 1;
        height: 2em;
        padding-top: 0.1em;
        white-space: nowrap;
    }
    .uproot-likert-grid-radio {
        border-bottom: 1px solid var(--bs-border-color);
        grid-column: 2;
        height: 2em;
        justify-self: center;
        padding-bottom: 0.33rem;
        width: 100%;
    }
    .uproot-likert-grid-mobile-label {
        border-bottom: 1px solid var(--bs-border-color);
        color: var(--bs-tertiary-color);
        display: inline;
        font-weight: 600;
        grid-column: 3;
        height: 2em;
        padding-bottom: 0.33rem;
        padding-right: 75%;
        text-align: right;
    }
    .uproot-likert-grid-cell-last .uproot-likert-grid-mobile-scale-label,
    .uproot-likert-grid-cell-last .uproot-likert-grid-radio,
    .uproot-likert-grid-cell-last .uproot-likert-grid-mobile-label {
        border-bottom: 0;
    }
    .uproot-likert-grid-mobile-label .form-check-label {
        font-variant-numeric: tabular-nums;
    }
}

/* In-text hyperlink with gray underline that turns black on hover */
/* See https://cdn.jsdelivr.net/npm/bootstrap@5.3.8/dist/css/bootstrap.min.css */
.link-subtle {
    color: var(--bs-dark) !important;  /* link-dark */
    text-decoration-line: underline;
    text-underline-offset: .25em !important;  /* link-offset-2 */
    --bs-link-underline-opacity: .25;  /* .link-underline-opacity-25 */
    text-decoration-color: rgba(var(--bs-dark-rgb), var(--bs-link-underline-opacity)); /* .link-underline-dark */
}
.link-subtle:hover, .link-subtle:focus {
    color: var(--bs-dark) !important;
    --bs-link-underline-opacity: 1;  /* link-underline-opacity-100-hover */
    text-decoration-color: rgba(var(--bs-dark-rgb), var(--bs-link-underline-opacity)) !important;
}

.link-underline-uproot {
    -webkit-text-decoration-color: rgba(var(--bs-uproot-rgb), var(--bs-link-underline-opacity)) !important;
    text-decoration-color: rgba(var(--bs-uproot-rgb), var(--bs-link-underline-opacity)) !important;
}
.link-underline-uproot:hover, .link-underline-uproot:focus {
    color: var(--bs-uproot-dark) !important;
    -webkit-text-decoration-color: rgba(var(--bs-uproot-rgb-dark), var(--bs-link-underline-opacity)) !important;
    text-decoration-color: rgba(var(--bs-uproot-rgb-dark), var(--bs-link-underline-opacity)) !important;
}

.link-uproot {
    color: rgba(var(--bs-uproot-rgb), var(--bs-link-opacity, 1)) !important;
    -webkit-text-decoration-color: rgba(var(--bs-uproot-rgb), var(--bs-link-underline-opacity, 1)) !important;
    text-decoration-color: rgba(var(--bs-uproot-rgb), var(--bs-link-underline-opacity, 1)) !important;
}
.link-uproot:hover, .link-uproot:focus {
    color: rgba(var(--bs-uproot-dark-rgb), var(--bs-link-opacity, 1)) !important;
    -webkit-text-decoration-color: rgba(var(--bs-uproot-dark-rgb), var(--bs-link-underline-opacity, 1)) !important;
    text-decoration-color: rgba(var(--bs-uproot-dark-rgb), var(--bs-link-underline-opacity, 1)) !important;
}

.text-ls-uppercase {
    letter-spacing: 0.05em;
}

.text-uproot {
    --bs-text-opacity: 1;
    color: rgba(var(--bs-uproot-rgb), var(--bs-text-opacity)) !important;
}

.text-uproot-dark {
    --bs-text-opacity: 1;
    color: rgba(var(--bs-uproot-dark-rgb), var(--bs-text-opacity)) !important;
}

/* Main style */
body {
    overflow-y: scroll;
    /* Harmonize font smoothing across platforms */
    font-smooth: always;  /* https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Properties/font-smooth */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;

}
header {
    margin-bottom: 1em;
}
main {
    margin-top: 1em;
    margin-bottom: 3em;
}
.hidden {
    display: none;
}
.visually-hidden,
.visually-hidden-focusable:not(:focus):not(:focus-within) {
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}
.visually-hidden:not(caption),
.visually-hidden-focusable:not(:focus):not(:focus-within):not(caption) {
    position: absolute !important;
}
.uproot-form-label {
    font-weight: bold;
    display: block;
}
.uproot-form-description {
    display: block;
}

.uproot-form-group {
    margin-bottom: 1.5rem;
    margin-top: 1.5rem;
}  /* Corresponds to mb-4 mt-4 */
.uproot-form-group ul {
    list-style-type: none;
    list-style-position: inside;
    margin: 0;
    padding: 0;
}

input[type="radio"].form-check-input {
    border-color: var(--bs-gray-500);
}

#error-modal {
    z-index: 9999;
}

#uproot-buddy {
    position: fixed;
    left: 2em;
    bottom: 2em;
    opacity: 0.9;
}
#uproot-buddy button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

#uproot-button-wrapper {
    display: flex;
    justify-content: space-between;
    margin-top: 1.5rem;  /* like .mt-4 */
}

[x-cloak] {
    display: none !important;
}

/* Ensure space between bottom and window border so that buttons can be pressed also on mobile devices */
#uproot-spacer {
    height: 4rem;  /* Do not make too large, so that single-hand use of smartphones is not impacted */
}

#uproot-timeout {
    backdrop-filter: blur(0.1rem);
    -webkit-backdrop-filter: blur(1px);
    background-color: rgba(from var(--bs-alert-bg) r g b / 0.85);
    width: fit-content;
}
#uproot-timeout #uproot-time-remaining {
    font-weight: bold;
    font-variant-numeric: tabular-nums;
}
.uproot-timeout-light {
    --bs-alert-bg: var(--bs-light);
    --bs-alert-border-color: var(--bs-tertiary-color);
    --bs-alert-color: var(--bs-secondary-color);
}
.uproot-timeout-warning {
    --bs-alert-bg: var(--bs-warning-bg-subtle);
    --bs-alert-border-color: var(--bs-warning);
    --bs-alert-color: var(--bs-black);
}
.uproot-timeout-danger {
    --bs-alert-bg: var(--bs-danger-bg-subtle);
    --bs-alert-border-color: var(--bs-danger);
    --bs-alert-color: var(--bs-black);
}

#uproot-title {
    font-weight: 600;
}

div.without-anchoring-overlay {
    background: var(--bs-primary);
    border-radius: var(--bs-border-radius-pill);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
    z-index: 10;
}

.uproot-testing-only {
    display: none;
    font-size: smaller;
}

#uproot-testing-button-wrapper {
    position: absolute;
    top: 1em;
    right: 1em;
    z-index: 1000;
}
#uproot-testing-button-wrapper button {
    max-width: 96px;
}

#uproot-testing-button-wrapper .bg-hover-uproot:hover {
    background-color: var(--bs-uproot) !important;
}
#uproot-testing-button-wrapper .text-hover-white:hover {
    color: white !important;
}

.message-hover:hover {
    background-color: rgba(13, 110, 253, 0.05) !important;
}
.messages-container {
    height: 280px;
    overflow-y: scroll;
    resize: vertical;
}
.messages-container .sender {
    font-family: monospace;
}

.uproot-chat textarea {
    resize: vertical;
}

.uproot-form-group.short-field div.input-group {
    max-width: 340px;
}

/* Slider popover styles (requires JS initialization via slidersWithPopovers) */
.uproot-slider-popover-wrapper {
    flex-grow: 1;
}
.uproot-slider-label {
    padding-bottom: 0.45em;
}
.uproot-slider-popover-container {
    height: 3.25rem;
    width: 0;
}
.uproot-slider-popover-spacer {
    height: 3.25rem;
}
.popover-body {
    padding: 0.5rem 0.75rem;
}

/* Radio toggle-clear styles (requires JS initialization via nonRequiredRadios) */
.radio-toggle-enabled .form-check.radio-toggle-clear-hover > .form-check-label {
    color: var(--bs-dark-bg-subtle);
    text-decoration: line-through;
    text-decoration-color: var(--bs-dark-bg-subtle);
    text-decoration-thickness: from-font;
    cursor: pointer;
}

/* RTL support for Bootstrap form-check (radio buttons, checkboxes) */
[dir="rtl"] .form-check {
    padding-left: 0;
    padding-right: 1.5em;
}
[dir="rtl"] .form-check .form-check-input {
    float: right;
    margin-left: 0;
    margin-right: -1.5em;
}
[dir="rtl"] .form-check-inline {
    margin-right: 0;
    margin-left: 1rem;
}
[dir="rtl"] .form-switch {
    padding-left: 0;
    padding-right: 2.5em;
}
[dir="rtl"] .form-switch .form-check-input {
    float: right;
    margin-left: 0;
    margin-right: -2.5em;
    background-position: right center;
}
[dir="rtl"] .form-switch .form-check-input:checked {
    background-position: left center;
}

/* Print styles */
@media print {
    /* Hide testing elements */
    #uproot-testing-button-wrapper,
    .uproot-testing-only {
        display: none !important;
    }

    /* Hide interactive/non-printable elements */
    #uproot-buddy,
    #uproot-timeout,
    .modal {
        display: none !important;
    }

    /* Reset bottom spacer for print layout */
    #uproot-spacer {
        height: 0;
    }

    /* Preserve background colors and images */
    * {
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    /* Avoid awkward page breaks */
    .uproot-form-group,
    .card,
    .alert,
    table,
    figure,
    img {
        break-inside: avoid;
    }

    /* Ensure links are visible */
    a[href]:not(.btn)::after {
        content: " (" attr(href) ")";
        font-size: smaller;
        opacity: 0.7;
    }
    a[href^="#"]::after,
    a[href^="javascript:"]::after {
        content: none;
    }

    /* Clean up body for print */
    body {
        overflow: visible;
    }
}
