:root {
    /* --- Brand Overrides (Defaults) --- */
    --brand-font: "Proxima Nova", "Helvetica", "Arial", sans-serif;
    --brand-font-size: 16px;
    --brand-font-color: var(--mantis-blueberry-jam);
    --brand-bg: #ffffff ;
    --brand-primary: var(--mantis-violet-plum);
    --brand-primary-hover: var(--mantis-blueberry-pie);
    --brand-primary-active: var(--mantis-aubergine);
    --brand-button-text: var(--mantis-white);
    --brand-link-color: var(--mantis-violet-plum);
    --brand-icon-color: var(--mantis-blueberry-jam);
    --brand-nav-bg: #ffffff;
    --brand-nav-link-color: #000;
    --brand-nav-icon-color: #000;
    --brand-radius: 44px;
    --brand-card-bg: #f3f4f6;
    --brand-bc-bg: transparent;
    --brand-bc-padding: 0;
    --brand-bc-color: var(--mantis-blueberry-jam-80);

    /* --- Mantis Standard Palette (Fallbacks) --- */
    --mantis-aubergine: #421c92;
    --mantis-blueberry-pie: #4a2dc0;
    --mantis-violet-plum: #5d40d2;
    --mantis-violet-plum-50: #5d40d280;
    --mantis-wisteria: #9f6aff;
    --mantis-lavender-macaron: #ddcefe;
    --mantis-lavender-macaron-30: #ddcefe4c;
    --mantis-coconut-milk: #f2f4f6;
    --mantis-blueberry-jam: #1a2b4aff;
    --mantis-blueberry-jam-07: #1a2b4a12;
    --mantis-blueberry-jam-09: #1a2b4a17;
    --mantis-blueberry-jam-12: #1a2b4a1e;
    --mantis-blueberry-jam-30: #1a2b4a4c;
    --mantis-blueberry-jam-60: #1a2b4a99;
    --mantis-blueberry-jam-80: #1a2b4acc;
    --mantis-blueberry-jam-90: #1a2b4ae6;
    --mantis-white: #ffffff;
    --mantis-raspberry-coulis: #e95087;
    --mantis-blue-strawberry: #0ba4e6;
    --mantis-blue-mojito-80: #15c9c9;
    --mantis-seasalt-ice-cream: #10e2bf;

    /* --- Brand-to-Mantis Logic Mapping --- */
    --mantis-brand-primary: var(--brand-primary);
    --mantis-brand-primary-hover: var(--brand-primary-hover);
    --mantis-brand-primary-active: var(--brand-primary-active);
    --mantis-brand-menu-border-color: var(--brand-primary);
    --mantis-brand-secondary: var(--mantis-seasalt-ice-cream);
    
    /* Bootstrap Mapping */
    --bs-body-font-family: var(--brand-font);
    --bs-font-sans-serif: var(--brand-font);
    --bs-body-color: var(--brand-font-color);
    --bs-body-bg: var(--brand-bg);
    --bs-list-group-bg: var(--brand-card-bg);
    --bs-list-group-border-color: var(--mantis-blueberry-jam-12);
    
    --writing-toolbar-height: 56px;
    --dice-header-height: 60px;
    --dice-footer-height: 60px;
}

/* Elements */

html {
    min-height: 100%;
    height: 100%;
    background-color: var(--brand-bg);
    font-size: var(--brand-font-size);
}

body {
    min-height: 100%;
    background-color: var(--brand-bg) !important;
    font-family: var(--brand-font);
    color: var(--brand-font-color);
    line-height: 1.5;
    letter-spacing: 0.5px;
    font-weight: 400;
    font-style: normal;
}



body:has(#spreadsheet-page) {
    overflow-y: hidden;
}

.container, .wrapper {
    background-color: var(--brand-bg);
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--brand-font);
    color: var(--brand-font-color);
}

h1 {
    font-weight: 600;
    font-size: 2.25rem;
    line-height: 1.3;
}

h2 {
    font-weight: 600;
    font-size: 1.875rem;
    line-height: 1.3;
}

h3 {
    font-weight: 600;
    font-size: 1.5rem;
    line-height: 1.3;
}

h4 {
    font-weight: 700;
    font-size: 1.25rem;
    line-height: 1.3;
}

h5 {
    font-weight: 600;
    font-size: 1.25rem;
    line-height: 1.3;
}

/* HEADING MARGINS */
/* possible TODO setting heading margins to 0 in favour of authored css for each usage */
h1 {
    margin-bottom: 2.5rem;
}
h2 {
    margin-bottom: 2.25rem;
}
h3 {
    margin-bottom: 2rem;
}
h4 {
    margin-bottom: 1.75rem;
}
h5 {
    margin-bottom: 1.5rem;
}
/* fyi bootstrap's default heading margins are `margin-top: 0` and `margin-bottom: 0.5rem` */
/* px values compared to old */
/* h1 40px, old was 40px */
/* h2 36px, old was 40px */
/* h3 32px, old was 18px */
/* h4 28px, old was 30px */
/* h5 24px, old was 28px */

/* Enabling this causes 4:3 aspect videos to be stretched when in fullscreen
video {
    object-fit: fill;
}
*/

img.disabled {
    opacity: 0.7;
    filter: grayscale(1);
}

figure {
    max-width: fit-content;
    text-align: center;
    margin: 0.5em auto;
}

figure img {
    max-width: 100%;
}

figcaption {
    text-align: center;
}

blockquote {
    background-color: var(--mantis-blueberry-jam-12);
    padding: 0.5em;
}

main {
    flex-grow: 1;
}

strong {
    font-weight: 700;
}

hr {
    background-color: var(--mantis-blueberry-jam-12);
    opacity: 1;
}

.text-spreadsheet {
    color: var(--mantis-blue-strawberry);
}

.text-writing {
    color: var(--mantis-seasalt-ice-cream);
}

/*
Don't use text-bg as that has default contrast, so do this manually 
*/
.bg-primary,
.bg-danger,
.bg-dark {
    color: white;
}
.bg-danger:hover {
    color: white;
}
/* Bootstrap doesn't allow this, probably for good reason */
.bg-secondary {
    --bs-bg-opacity: 0.07;
}

/* Utilities */
.font-weight-600 {
    font-weight: 600;
}

.mx--3 {
    margin-left: -24px;
    margin-right: -24px;
}

.centrist-dad {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Font size */
.text-xsmall {
    font-size: 0.875rem !important;
}

.text-small {
    font-size: 1rem !important;
}

.text-large {
    font-size: 1.5rem;
}

.text-xlarge {
    font-size: 1.875rem;
}

/* Online...  Assume offline */
.myc-online {
    display: none;
}

.myc-offline {
    display: inherit;
}

/* Icons */
.mn-xlarge, .mn-large, .mn-medium, .bi {
    color: var(--brand-icon-color, inherit);
}

.mn-xlarge {
    font-size: 1.6rem;
}

.mn-large {
    font-size: 1.2rem;
}

.mn-medium {
    font-size: 1.1rem;
}

/* Accessibility */
.font-open-dyslexic,
.font-open-dyslexic h1,
.font-open-dyslexic h2 {
    font-family: "Open Dyslexic", "Proxima Nova", "Helvetica", "Arial", sans-serif;
    letter-spacing: 0px;
    line-height: 1.4;
    --bs-font-sans-serif: "Open Dyslexic", "Proxima Nova", "Helvetica", "Arial", sans-serif;
}
.font-open-dyslexic .popover-tour {
    --bs-font-sans-serif: "Open Dyslexic", "Proxima Nova", "Helvetica", "Arial", sans-serif;
}
#overlay-example:not(.font-open-dyslexic) {
    font-family: "Proxima Nova", "Helvetica", "Arial", sans-serif;
}

.overlay-region {
    border-top: 2px solid var(--mantis-blueberry-jam-12);
    margin-left: -30px;
    margin-right: -30px;
    padding: 20px 15px;
}

/* Sorry cricket... */
#overlay-example-container {
    margin: 1rem -1rem -1rem -1rem;
    padding: 1rem 30px;
    position: relative;
}

#overlay-example-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
    opacity: 0.5;
}

/* Cards */
.card {
    --bs-card-spacer-y: 20px;
    --bs-card-spacer-x: 24px;
    --bs-card-title-spacer-y: 24px;
    --bs-card-title-color: var(--mantis-blueberry-jam);
    --bs-card-subtitle-color: var(--mantis-blueberry-jam);
    --bs-card-border-width: 0;
    --bs-card-border-color: transparent;
    --bs-card-border-radius: 6px;
    --bs-card-box-shadow: none;
    --bs-card-inner-border-radius: 6px;
    --bs-card-cap-padding-y: 20px;
    --bs-card-cap-padding-x: 24px;
    --bs-card-cap-bg: transparent;
    --bs-card-cap-color: var(--mantis-blueberry-jam-60);
    --bs-heading-color: var(--mantis-blueberry-jam);
    --bs-card-color: var(--mantis-blueberry-jam-60);
    --bs-card-bg: white;
    --bs-card-img-overlay-padding: 24px;
    --bs-card-group-margin: 24px;
}

.card-dark {
    --bs-card-title-color: white;
    --bs-heading-color: white;
    --bs-card-color: white;
    --bs-card-bg: var(--mantis-blueberry-jam);
    --bs-card-cap-color: var(--mantis-white);
}

.card-footer {
    padding-top: 0;
}

.home-card {
    --bs-card-color: var(--mantis-blueberry-jam);
    height: 100%;
}

.home-card .category-img {
    height: 40px;
    margin: 1rem 1rem 0 0;
    align-self: flex-end;
}

.home-card .card-body {
    padding-top: 0;
    padding-bottom: 0;
}

.home-card .card-footer {
    font-size: 1.5rem;
}

.card-title-truncated {
    display: -webkit-box;
    line-clamp: 2;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    margin: 0;
}

/* Ensure the image doesn't hit the very top of the card */
.card-img-container {
    padding: 12px 12px 0 12px;
    background-color: transparent;
}

/* Round the image corners to match the card and add a tiny border */
.card-img-top {
    border-radius: 6px !important;
    border: 1px solid rgba(0,0,0,0.05);
}

/* This creates a clean "shelf" for the image to sit on */
.card-body {
    border-top: 1px solid rgba(0,0,0,0.08);
    margin-top: 8px;
    padding: 15px !important;
}

/* Reversable cards.  Currently fixed height is required for the absolute positioning. */
.card-reversable {
    position: relative;
}
.card-reversable .card {
    height: 340px;
}
.card-reversable .card-text {
    overflow: hidden;
}

.card-reversable .card-front,
.card-reversable .card-reverse {
    top: 0;
    left: 0;
    opacity: 0;
    background-color: var(--mantis-blueberry-jam) !important;
    color: #ffffff !important;
    text-decoration: none !important;
    transition: 0.3s;
}

.card-reverse h1, 
.card-reverse h2, 
.card-reverse h3, 
.card-reverse h4, 
.card-reverse h5, 
.card-reverse p, 
.card-reverse span, 
.card-reverse a,
.card-reverse .card-body {
    color: #ffffff !important;
    text-decoration: none !important;
}

.card-reversable .card-front,
.card-reversable .card-reverse:hover,
.card-reversable a.card-reverse:focus-visible {
    opacity: 1;
}

.card-reverse .card-body {
    max-height: 300px;
    overflow-y: auto;
    scrollbar-color: white transparent;
}

.card-reverse {
    position: absolute;
}

.card-reverse .card-footer {
    display: flex;
    justify-content: end;
}

/* absolutely position badge within reversable cards */
.card-reversable .badge-status-container {
    position: absolute;
    top: 12px;
    right: 12px;

    font-size: 1rem;
}

/* Layout */
.body-utils {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    padding-bottom: var(--dice-footer-height);
}

.content-bg {
    background-color: white;
}

.full-height {
    min-height: 100vh;
}

.hero-title {
    letter-spacing: -0.25px;
    font-weight: 600;
    margin-bottom: 24px;
}

.hero-container {
    box-shadow: inset 0 20px 20px -20px rgba(0, 0, 0, 0.1);
    background: white;
}

.bottom-container {
    background-color: white;
    height: 157px;
}

.video-content {
    text-align: right;
}

.tour-banner {
    background-color: var(--mantis-violet-plum);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    gap: 1.25rem;
}

/* Box Containers */

.description-box {
    color: var(--mantis-blueberry-jam);
    background: white;
    padding: 20px 15px;
    height: 130px;
    border-bottom-left-radius: 4px;
    border-bottom-right-radius: 4px;
}

.content-body {
    margin-top: 36px;
}

.book-image {
    box-shadow: 0 0 16px 0 rgba(0, 0, 0, 0.04);
    margin-bottom: 16px;
}

.book-image:hover {
    box-shadow: 0 0 21px 0 rgb(0, 0, 0, 0.12);
}

.course-img {
    border-top-left-radius: 4px;
    border-top-right-radius: 4px;
    width: 100%;
}

.hero-img {
    width: 100%;
    max-width: 680px;
    margin-bottom: 40px;
}

.back-link {
    /* Actaully 24, but 10 is consumed by the button */
    margin-left: 14px;
}

.forward-link {
    /* Actaully 30, but 20 is consumed by the buttons */
    margin-left: 10px;
}

.header-buttons {
    display: flex;
    justify-content: end;
    align-items: center;
    padding-right: 14px;
    gap: 20px;
}

.coracle-logo {
    height: 24px;
}

.vertical-line {
    border-left: 2px solid var(--mantis-blueberry-jam-12);
}

/* Breadcrumb */
#breadcrumb-nav-full {
    overflow-x: hidden;
}
.breadcrumb {
    background-color: var(--brand-bc-bg);
    --bs-breadcrumb-item-padding-x: 8px;
    --bs-breadcrumb-font-size: 1rem;
}

.breadcrumb-item, .breadcrumb-item a {
    color: var(--brand-bc-color) !important;
}

.breadcrumb-item:hover,
.breadcrumb-item:focus-visible,
.breadcrumb-item:active {
    color: var(--mantis-blueberry-jam-60);
}

.breadcrumb-item + .breadcrumb-item::before {
    font-family: "mantis-icons", sans-serif;
    color: var(--brande-bc-color);
    content: "\e910";

    transform: scale(0.8);
}

.breadcrumb-item.active {
    font-weight: 600;
    color: var(--mantis-blueberry-jam);
    font-size: 1rem;
}
.dropdown-menu[aria-labelledby="navDropdown"] li {
    border: none;
    margin-bottom: 0.5rem;
}
#mantis-breadcrumb-full {
    display: none;
}

/* Links */
a {
    color: var(--brand-link-color);
    text-decoration: underline;
    text-underline-offset: 2px;
    font-weight: 600;
}

a:hover {
    color: var(--brand-primary-hover);
    text-decoration: none;
}

a:active {
    color: var(--mantis-aubergine);
    text-decoration: underline;
}

a:focus-visible {
    outline: none;
    color: var(--mantis-blueberry-jam);
    text-decoration: none;
}

a:disabled,
a.disabled {
    color: var(--mantis-blueberry-jam-60);
    text-decoration: none;
}

/* Dark */

.bg-brand-primary a,
.bg-blueberry-jam a,
a.dark {
    color: var(--mantis-wisteria);
}

.bg-brand-primary a:hover,
.bg-blueberry-jam a:hover,
a.dark:hover {
    color: var(--mantis-wisteria);
}

.bg-brand-primary a:active,
.bg-blueberry-jam a:active,
a.dark:active {
    color: white;
}

.bg-brand-primary a:focus-visible,
.bg-blueberry-jam a:focus-visible,
a.dark:focus-visible {
    color: white;
    text-decoration: none;
}

.bg-brand-primary a:disabled,
.bg-brand-primary a.disabled,
.bg-blueberry-jam a:disabled,
.bg-blueberry-jam a.disabled,
a.dark:disabled,
a.dark.disabled {
    color: var(--mantis-white-60);
    text-decoration: none;
}

/* Provider */
.bg-brand-primary {
    background-color: var(--mantis-brand-primary);
}

.provider a,
a.provider {
    color: var(--mantis-blueberry-jam);
}

.provider a:hover,
a.provider:hover {
    color: var(--mantis-blueberry-jam);
}

.provider a:focus-visible,
a.provider:focus-visible {
    color: var(--mantis-blueberry-jam);
}

.provider a:disabled,
a.provider:disabled {
    color: var(--mantis-blueberry-jam-60);
}

/* Menu items and other non-inline links */

.indifferent-link-container a,
.list-group-item a,
.list-group-item .btn-link,
.link-indifferent {
    text-decoration: none;
    outline: 2px solid transparent;
    outline-offset: 4px;
    border-radius: 4px;
}

.indifferent-link-container a:hover,
.link-indifferent:hover {
    color: inherit;
    text-decoration: underline;
}

.indifferent-link-container a:active,
.link-indifferent:active {
    text-decoration: underline;
}

.indifferent-link-container a:focus-visible,
.link-indifferent:focus-visible {
    text-decoration: none;
    color: var(--mantis-violet-plum);
    outline: 2px solid transparent;
}

.indifferent-link-container a:disabled,
.indifferent-link-container a.disabled,
.link-indifferent:disabled,
.link-indifferent.disabled {
    text-decoration: none;
    color: var(--mantis-blueberry-jam-60) !important;
}

/* Links as parents */
unstyled-link-container a,
.link-unstyled {
    color: inherit;
    font-weight: inherit;
    text-decoration: none;
}

.link-unstyled:hover {
    color: inherit;
    box-shadow: 0 0 21px 0 var(--mantis-blueberry-jam-30);
}

.link-unstyled:active {
    box-shadow: 0 0 21px 0 var(--mantis-blueberry-jam-60);
    text-decoration: none;
}

.link-unstyled:focus-visible {
    box-shadow: 0 0 21px 0 var(--mantis-violet-plum-50);
}

/* Buttons */

/* The divider for prev / next buttons */

.divider {
    border-left: 1px solid var(--mantis-blueberry-jam-12);
    margin-left: 7px;
    padding-left: 7px;
}

.btn {
    --bs-btn-focus-box-shadow: none;
    --bs-btn-border-width: 2px;
    --bs-btn-disabled-opacity: 1;
    --bs-btn-font-weight: 600;

    /* button groups use this figure for a negative margin, causing an overlap that we don't want */
    --bs-border-width: 0;

    /* For <a>s */
    text-decoration: none;
}

/* .btn-like isn't bootstrap... */
.btn,
.btn-like {
    /* border-radius is arbitrarily large */
    border-radius: var(--brand-radius);
    padding: 8px 16px 8px 16px;

    font-size: 1rem;
    letter-spacing: 0.5px;
    text-decoration: none;
    white-space: nowrap;

    display: inline-flex;
    justify-content: center;
    align-items: center;
}

/* Match the size of any remaining bootstrap icons to mantis ones */
.btn .bi {
    font-size: 1.25rem;
}

.btn-small {
    padding: 4px 16px;
}

.btn-big {
    padding: 11px 24px;

    font-size: 1.125rem;
    font-weight: 600;
}

.btn-toolbar .btn {
    margin-top: 2px;
}

.btn:active {
    text-decoration: none;
}

.btn:focus-visible {
    color: var(--bs-btn-focus-color);
    box-shadow: 0 0 0 3px var(--bs-btn-focus-shadow-rgb);
    border-color: var(--bs-btn-focus-border-color);
    background-color: var(--bs-btn-focus-bg);
}

.btn-check:checked + .btn:focus-visible,
.btn.active:focus-visible,
.btn.show:focus-visible,
.btn:first-child:active:focus-visible,
:not(.btn-check) + .btn:active:focus-visible {
    background-color: var(--bs-btn-active-bg);
    box-shadow: 0 0 0 3px var(--bs-btn-focus-shadow-rgb);
}

.btn-primary {
    --bs-btn-color: var(--brand-button-text);
    --bs-btn-bg: var(--brand-primary) !important;
    --bs-btn-border-color: var(--brand-primary);

    --bs-btn-hover-color: var(--brand-button-text);
    --bs-btn-hover-bg: var(--brand-primary-hover);
    --bs-btn-hover-border-color: var(--brand-primary-hover);

    --bs-btn-active-color: white;
    --bs-btn-active-bg: var(--brand-primary-active);
    --bs-btn-active-border-color: transparent;
    --bs-btn-active-shadow-rgb: none;

    --bs-btn-focus-color: #fff;
    --bs-btn-focus-bg: var(--mantis-violet-plum);
    --bs-btn-focus-border-color: white;
    --bs-btn-focus-shadow-rgb: var(--mantis-violet-plum);

    --bs-btn-disabled-color: var(--mantis-blueberry-jam-80);
    --bs-btn-disabled-bg: var(--mantis-blueberry-jam-12);
    --bs-btn-disabled-border-color: transparent;
}

/* Ensure icons inside primary buttons match the button text color */
.btn-primary .bi, 
.btn-primary .mn, 
.btn-primary i,
.btn-brand-primary .bi,
.btn-brand-primary .mn,
.btn-brand-primary i {
    color: var(--brand-button-text, #ffffff) !important;
}

.bg-brand-primary .btn-primary,
.bg-blueberry-jam .btn-primary,
.btn-primary-dark {
    --bs-btn-disabled-color: var(--mantis-white-80);
    --bs-btn-disabled-bg: transparent;
    --bs-btn-disabled-border-color: var(--mantis-white-30);
}

.btn-brand-primary {
    --bs-btn-color: var(--brand-button-text);
    --bs-btn-bg: var(--brand-primary);
    --bs-btn-hover-bg: var(--brand-primary-hover);

    --bs-btn-hover-color: white;
    --bs-btn-hover-bg: var(--mantis-brand-primary-hover);
    --bs-btn-hover-border-color: transparent;

    --bs-btn-active-color: white;
    --bs-btn-active-bg: var(--mantis-brand-primary-active);
    --bs-btn-active-border-color: transparent;
    --bs-btn-active-shadow-rgb: none;

    --bs-btn-focus-color: #fff;
    --bs-btn-focus-bg: var(--mantis-brand-primary);
    --bs-btn-focus-border-color: white;
    --bs-btn-focus-shadow-rgb: var(--mantis-brand-primary);

    --bs-btn-disabled-color: var(--mantis-blueberry-jam-80);
    --bs-btn-disabled-bg: var(--mantis-blueberry-jam-12);
    --bs-btn-disabled-border-color: transparent;
}

.btn-secondary {
    --bs-btn-color: var(--mantis-blueberry-jam);
    --bs-btn-bg: var(--mantis-blueberry-jam-07);
    --bs-btn-border-color: transparent;

    --bs-btn-hover-color: var(--mantis-blueberry-jam);
    --bs-btn-hover-bg: var(--mantis-blueberry-jam-09);
    --bs-btn-hover-border-color: transparent;

    --bs-btn-active-color: var(--mantis-blueberry-jam);
    --bs-btn-active-bg: var(--mantis-blueberry-jam-12);
    --bs-btn-active-border-color: transparent;
    --bs-btn-active-shadow-rgb: none;

    --bs-btn-focus-color: var(--mantis-violet-plum);
    --bs-btn-focus-bg: var(--mantis-coconut-milk);
    --bs-btn-focus-border-color: var(--mantis-coconut-milk);
    --bs-btn-focus-shadow-rgb: var(--mantis-violet-plum);

    --bs-btn-disabled-color: var(--mantis-blueberry-jam-60);
    --bs-btn-disabled-bg: transparent;
    --bs-btn-disabled-border-color: var(--mantis-blueberry-jam-12);

    --bs-btn-font-weight: 400;
}

.btn-brand-secondary {
    --bs-btn-color: var(--mantis-blueberry-jam);
    --bs-btn-bg: var(--mantis-brand-secondary);
    --bs-btn-border-color: transparent;

    --bs-btn-hover-color: var(--mantis-blueberry-jam);
    --bs-btn-hover-bg: var(--mantis-brand-secondary-hover);
    --bs-btn-hover-border-color: transparent;

    --bs-btn-active-color: var(--mantis-blueberry-jam);
    --bs-btn-active-bg: var(--mantis-brand-secondary-active);
    --bs-btn-active-border-color: transparent;
    --bs-btn-active-shadow-rgb: none;

    --bs-btn-focus-color: var(--mantis-blueberry-jam);
    --bs-btn-focus-bg: var(--mantis-brand-secondary-active);
    --bs-btn-focus-border-color: var(--mantis-coconut-milk);
    --bs-btn-focus-shadow-rgb: var(--mantis-brand-secondary-active);

    --bs-btn-disabled-color: var(--mantis-blueberry-jam-60);
    --bs-btn-disabled-bg: transparent;
    --bs-btn-disabled-border-color: var(--mantis-brand-secondary-active);

    --bs-btn-font-weight: 400;
}

.btn-tertiary {
    --bs-btn-color: var(--mantis-white);
    --bs-btn-bg: var(--mantis-blue-mojito-80);
    --bs-btn-border-color: transparent;

    --bs-btn-hover-color: var(--mantis-white);
    --bs-btn-hover-bg: var(--mantis-blue-mojito);
    --bs-btn-hover-border-color: transparent;

    --bs-btn-active-color: var(--mantis-white);
    --bs-btn-active-bg: var(--mantis-blue-damson);
    --bs-btn-active-border-color: transparent;
    --bs-btn-active-shadow-rgb: none;

    --bs-btn-focus-color: var(--mantis-white);
    --bs-btn-focus-bg: var(--mantis-blue-damson);
    --bs-btn-focus-border-color: var(--mantis-coconut-milk);
    --bs-btn-focus-shadow-rgb: var(--mantis-blue-strawberry);

    --bs-btn-disabled-color: var(--mantis-blueberry-jam-60);
    --bs-btn-disabled-bg: transparent;
    --bs-btn-disabled-border-color: var(--mantis-blueberry-jam-12);

    --bs-btn-font-weight: 400;
}

.bg-brand-primary .btn-secondary,
.bg-blueberry-jam .btn-secondary,
.btn-secondary-dark {
    --bs-btn-color: white;
    --bs-btn-bg: var(--mantis-white-30);
    --bs-btn-border-color: transparent;

    --bs-btn-hover-color: white;
    --bs-btn-hover-bg: var(--mantis-white-20);
    --bs-btn-hover-border-color: transparent;

    --bs-btn-active-color: white;
    --bs-btn-active-bg: var(--mantis-white-10);
    --bs-btn-active-border-color: transparent;
    --bs-btn-active-shadow-rgb: none;

    --bs-btn-focus-color: white;
    --bs-btn-focus-bg: var(--mantis-white-30);
    --bs-btn-focus-border-color: white;
    --bs-btn-focus-shadow-rgb: transparent;

    --bs-btn-disabled-color: var(--mantis-white-30);
    --bs-btn-disabled-bg: transparent;
    --bs-btn-disabled-border-color: var(--mantis-white-20);

    --bs-btn-font-weight: 400;
}

/* The previous and next buttons */
.btn-navigation {
    line-height: 1.2;
    padding: 4px 10px;
    font-weight: 600;
    border-radius: 6px;
}

/* Variation on btn-secondary, togglable */
.btn-checkbox {
    --bs-btn-bg: var(--mantis-blueberry-jam-07);
    --bs-btn-border-color: transparent;

    --bs-btn-hover-bg: var(--mantis-blueberry-jam-12);
    --bs-btn-hover-border-color: transparent;

    --bs-btn-active-border-color: transparent;
    --bs-btn-active-shadow-rgb: none;

    --bs-btn-focus-bg: var(--mantis-coconut-milk);
    --bs-btn-focus-shadow-rgb: var(--mantis-white-00);

    --bs-btn-disabled-color: var(--mantis-blueberry-jam-60);
    --bs-btn-disabled-bg: var(--mantis-blueberry-jam-07);
    --bs-btn-disabled-border-color: var(--mantis-blueberry-jam-60);

    --bs-btn-font-weight: 400;
}

.btn-checkbox.checked {
    --bs-btn-color: white;
    --bs-btn-bg: var(--mantis-blueberry-jam);
    --bs-btn-border-color: var(--mantis-blueberry-jam);

    --bs-btn-hover-color: white;
    --bs-btn-hover-bg: var(--mantis-blueberry-jam-80);
    --bs-btn-hover-border-color: var(--mantis-white-00);

    --bs-btn-active-color: white;
    --bs-btn-active-bg: var(--mantis-blueberry-jam-30);
    --bs-btn-active-border-color: var(--mantis-white-00);
    --bs-btn-active-shadow-rgb: none;

    --bs-btn-focus-color: white;
    --bs-btn-focus-bg: var(--mantis-blueberry-jam);
    --bs-btn-focus-border-color: var(--mantis-blueberry-jam-30);
    --bs-btn-focus-shadow-rgb: var(--mantis-blueberry-jam-30);

    --bs-btn-disabled-color: white;
    --bs-btn-disabled-bg: var(--mantis-blueberry-jam-30);
    --bs-btn-disabled-border-color: var(--mantis-white-00);

    --bs-btn-font-weight: 400;
}

.btn-checkbox-main {
    --bs-btn-color: var(--mantis-blueberry-jam);

    --bs-btn-hover-color: var(--mantis-blueberry-jam);

    --bs-btn-active-color: white;
    --bs-btn-active-bg: var(--mantis-blueberry-jam);

    --bs-btn-focus-color: var(--mantis-blueberry-jam);
    --bs-btn-focus-border-color: var(--mantis-blueberry-jam);
}

.btn-checkbox-main.checked {
    --bs-btn-color: white;
    --bs-btn-bg: var(--mantis-blueberry-jam);
    --bs-btn-border-color: var(--mantis-blueberry-jam);

    --bs-btn-hover-color: white;
    --bs-btn-hover-bg: var(--mantis-blueberry-jam-80);
    --bs-btn-hover-border-color: var(--mantis-white-00);

    --bs-btn-active-color: white;
    --bs-btn-active-bg: var(--mantis-blueberry-jam-30);
    --bs-btn-active-border-color: var(--mantis-white-00);

    --bs-btn-focus-color: white;
    --bs-btn-focus-bg: var(--mantis-blueberry-jam);
}

.btn-checkbox-alternative {
    --bs-btn-color: var(--mantis-blueberry-jam);

    --bs-btn-hover-color: var(--mantis-blueberry-jam);

    --bs-btn-active-color: var(--mantis-blueberry-jam);
    --bs-btn-active-bg: var(--mantis-brand-secondary-active);

    --bs-btn-focus-color: var(--mantis-blueberry-jam);
    --bs-btn-focus-border-color: var(--mantis-brand-secondary-active);
}

.btn-checkbox-alternative.checked {
    --bs-btn-color: var(--mantis-blueberry-jam);
    --bs-btn-bg: var(--mantis-brand-secondary);
    --bs-btn-border-color: var(--mantis-brand-secondary);

    --bs-btn-hover-color: var(--mantis-blueberry-jam);
    --bs-btn-hover-bg: var(--mantis-brand-secondary-hover);
    --bs-btn-hover-border-color: var(--mantis-brand-secondary-hover);

    --bs-btn-active-color: var(--mantis-blueberry-jam);
    --bs-btn-active-bg: var(--mantis-brand-secondary-active);
    --bs-btn-active-border-color: var(--mantis-brand-secondary-active);

    --bs-btn-focus-color: var(--mantis-blueberry-jam);
    --bs-btn-focus-bg: var(--mantis-brand-secondary-hover);
    --bs-btn-focus-border-color: transparent;
    --bs-btn-focus-shadow-rgb: var(--mantis-brand-secondary-active);
}

.btn-light {
    --bs-btn-color: var(--mantis-blueberry-jam);
    --bs-btn-bg: white;
    --bs-btn-border-color: var(--mantis-coconut-milk);

    --bs-btn-hover-color: var(--mantis-blueberry-jam);
    --bs-btn-hover-bg: var(--mantis-blueberry-jam-12);
    --bs-btn-hover-border-color: var(--mantis-coconut-milk);

    --bs-btn-active-color: white;
    --bs-btn-active-bg: var(--mantis-brand-primary);
    --bs-btn-active-border-color: var(--mantis-coconut-milk);
    --bs-btn-active-shadow-rgb: transparent;

    --bs-btn-focus-color: var(--mantis-blueberry-jam);
    --bs-btn-focus-bg: var(--mantis-blueberry-jam-12);
    --bs-btn-focus-border-color: var(--mantis-brand-primary);

    --bs-btn-disabled-color: var(--mantis-blueberry-jam-80);
    --bs-btn-disabled-bg: white;
    --bs-btn-disabled-border-color: var(--mantis-blueberry-jam-30);

    --bs-btn-font-weight: 400;
}

.btn-dark {
    --bs-btn-color: var(--mantis-coconut-milk);
    --bs-btn-bg: transparent;
    --bs-btn-border-color: var(--mantis-coconut-milk);

    --bs-btn-hover-bg: var(--mantis-white-20);
    --bs-btn-hover-border-color: var(--mantis-coconut-milk);

    --bs-btn-active-bg: var(--mantis-wisteria);
    --bs-btn-active-border-color: var(--mantis-coconut-milk);

    --bs-btn-focus-color: #fff;
    --bs-btn-focus-bg: transparent;
    --bs-btn-focus-border-color: white;
    --bs-btn-focus-shadow-rgb: var(--mantis-coconut-milk);

    --bs-btn-disabled-color: var(--mantis-white-60);
    --bs-btn-disabled-bg: transparent;
    --bs-btn-disabled-border-color: var(--mantis-white-20);

    font-weight: 600;
}

/* Border sits 'inside' the button */
.btn-tool {
    --bs-btn-hover-border-color: transparent;
    --bs-btn-active-border-color: transparent;
    --bs-btn-disabled-border-color: transparent;
    --bs-btn-focus-shadow-rgb: transparent;
    border: 2px solid transparent;
    border-radius: 0;
    padding: 14px;
    min-width: 1.375rem;

    font-size: 1.5rem;
    line-height: 1;
}

/* There are two types of link, Mantis links and provider links */
/* There's a whole bunch of esoteric versions of these too */

.btn-link {
    font-size: 1rem;
    text-decoration: none;
    --bs-btn-color: var(--brand-link-color);
    --bs-btn-bg: transparent;
    --bs-btn-border-color: transparent;

    --bs-btn-hover-color: var(--mantis-violet-plum);
    --bs-btn-hover-bg: transparent;
    --bs-btn-hover-border-color: transparent;

    --bs-btn-active-color: var(--mantis-aubergine);
    --bs-btn-active-bg: transparent;
    --bs-btn-active-border-color: transparent;
    --bs-btn-active-shadow-rgb: transparent;

    --bs-btn-focus-color: var(--mantis-blueberry-jam);
    --bs-btn-focus-bg: transparent;
    --bs-btn-focus-border-color: transparent;

    --bs-btn-disabled-color: var(--mantis-blueberry-jam-60);
    --bs-btn-disabled-bg: transparent;
    --bs-btn-disabled-border-color: transparent;

    --bs-btn-font-weight: 600;
}

.btn-link:hover,
.btn-link:focus-visible {
    text-decoration: none;
}

.btn-link:hover:active,
.btn-link:hover.active {
    text-decoration: underline;
}

.bg-brand-primary .btn-link,
.bg-blueberry-jam .btn-link,
.btn-link-dark {
    --bs-btn-color: var(--mantis-wisteria);

    --bs-btn-hover-color: var(--mantis-wisteria);

    --bs-btn-active-color: white;

    --bs-btn-focus-color: white;

    --bs-btn-disabled-color: var(--mantis-white-60);
}

.btn-link:hover,
.btn-link:focus-visible {
    text-decoration: none;
}

.btn-squarish {
    border-radius: 6px;
}

.btn-icon-square {
    border-radius: 6px;
    padding: 8px;
    min-width: 1.375rem; /* There's some rounding errors calculating the width */

    font-size: 1.5rem;
    line-height: 1;
}

.btn-icon-square-discrete {
    border-radius: 6px;
    padding: 3px;

    font-size: 0.875rem;
    line-height: 1;
    min-width: 24px;

    --bs-btn-bg: transparent;
    --bs-btn-border-color: transparent;

    --bs-btn-hover-color: var(--mantis-blueberry-jam-60);
    --bs-btn-hover-bg: transparent;

    --bs-btn-active-bg: transparent;
    --bs-btn-active-border-color: var(--mantis-blueberry-jam);

    --bs-btn-focus-color: var(--mantis-blueberry-jam-30);
    --bs-btn-focus-border-color: white;
    --bs-btn-focus-bg: transparent;

    --bs-btn-disabled-color: var(--mantis-blueberry-jam-30);
    --bs-btn-disabled-bg: transparent;
    --bs-btn-disabled-border-color: transparent;
}

.bg-brand-primary .btn-icon-square-discrete,
.bg-blueberry-jam .btn-icon-square-discrete,
.btn-icon-square-discrete-dark {
    border-radius: 6px;
    padding: 3px;

    font-size: 0.875rem;
    line-height: 1;
    min-width: 24px;

    --bs-btn-color: white;
    --bs-btn-bg: transparent;
    --bs-btn-border-color: transparent;

    --bs-btn-hover-color: var(--mantis-white-60);
    --bs-btn-hover-bg: transparent;

    --bs-btn-active-color: var(--mantis-white-30);
    --bs-btn-active-bg: transparent;
    --bs-btn-active-border-color: var(--mantis-blueberry-jam);

    --bs-btn-focus-color: white;
    --bs-btn-focus-border-color: white;
    --bs-btn-focus-bg: transparent;

    --bs-btn-disabled-color: var(--mantis-white-30);
    --bs-btn-disabled-bg: transparent;
    --bs-btn-disabled-border-color: var(--mantis-blueberry-jam);
}

.btn-icon-square-discrete:focus-visible {
    box-shadow: none;
}

.btn-icon-round {
    padding: 8px;

    font-size: 1.5rem;
    line-height: 1;

    min-width: 44px; /* There's some rounding errors calculating the width */

    --bs-btn-bg: transparent;
    --bs-btn-border-color: transparent;
    --bs-btn-disabled-border-color: transparent;
}

.btn-green {
    --bs-btn-color: var(--mantis-blueberry-jam);
    --bs-btn-bg: var(--mantis-cucumber-melon);
    --bs-btn-border-color: transparent;

    --bs-btn-hover-color: var(--mantis-blueberry-jam);
    --bs-btn-hover-bg: var(--mantis-cucumber);
    --bs-btn-hover-border-color: transparent;

    --bs-btn-active-color: var(--mantis-blueberry-jam);
    --bs-btn-active-bg: var(--mantis-kiwi);
    --bs-btn-active-border-color: transparent;
    --bs-btn-active-shadow-rgb: none;

    --bs-btn-focus-color: var(--mantis-blueberry-jam);
    --bs-btn-focus-bg: var(--mantis-cucumber);
    --bs-btn-focus-border-color: var(--mantis-coconut-milk);
    --bs-btn-focus-shadow-rgb: var(--mantis-kiwi);

    --bs-btn-disabled-color: var(--mantis-blueberry-jam-60);
    --bs-btn-disabled-bg: transparent;
    --bs-btn-disabled-border-color: var(--mantis-blueberry-jam-12);

    --bs-btn-font-weight: 400;
}

.btn-install-selected-collection {
    border-top-left-radius: 6px !important;
    border-bottom-left-radius: 6px !important;
}
/* Forms */

.mantis-form fieldset {
    border: none;
    margin-bottom: 30px;
}

.mantis-form legend {
    font-size: 1.875rem;
    line-height: 1.3;

    font-weight: 600;
}

.text-area-container {
    display: block;
    position: relative;
    width: 300px;
}

.form-label {
    margin-bottom: 6px;
    font-weight: 700;
}

.form-control {
    border: none;
    background-color: var(--mantis-coconut-milk);
    border-radius: 6px;
    margin-bottom: 14px;
}

.form-control:focus,
.form-control:active {
    background-color: var(--mantis-coconut-milk);
    border-color: var(--mantis-blueberry-jam-80);
    box-shadow: 0 0 0 0.2rem var(--mantis-blueberry-jam-80) 40;
}

.bg-mantis-coconut-milk .form-control {
    background-color: white;
}

.bg-mantis-coconut-milk .form-control:focus {
    background-color: white;
}

.form-check-input:focus {
    box-shadow: 0 0 0 0.1rem var(--mantis-coconut-milk);
}

.form-control-grey {
    background-color: white;
}

.form-control-grey:focus,
.form-control-grey:active {
    background-color: white;
}

.input-group-text {
    border: none;
    padding: 0 20px;
    margin-bottom: 14px;
}

textarea,
textarea.paddack {
    width: 100%;
    height: 7rem;
    margin: 0 0 1rem 0;
    resize: none;
}

.input-like {
    border-radius: 6px;
    background-color: var(--mantis-blueberry-jam-12);
    color: var(--mantis-blueberry-jam);
    border: none;
    padding: 8px 14px;
    min-height: 50px;
}

input[type="range"] {
    accent-color: var(--mantis-violet-plum);
}

input[type="radio"] {
    position: relative;
    top: 2px;
    box-sizing: border-box;
    width: 16px;
    height: 16px;
    margin: 0;
    margin-top: 3px;
    padding: 0;
    border: none;
    background-image: radial-gradient(
        circle,
        var(--mantis-blueberry-jam-12) 0%,
        var(--mantis-blueberry-jam-12) 100%
    );
    border-radius: 50%;
    appearance: none;
    background-color: var(--mantis-blueberry-jam-12);
    outline: none;
}

tr + .cq-single-answer-grey {
    background: white;
}

.cq-single-answer-grey input[type="radio"] {
    background-image: radial-gradient(circle, white 0%, white 100%);
    background-color: white;
}

input[type="radio"]:not(:disabled):checked {
    border: 3px solid var(--mantis-blueberry-jam-12);
    background-clip: content-box;
    background-image: radial-gradient(
        circle,
        var(--mantis-brand-primary-radio-active) 0%,
        var(--mantis-brand-primary-radio-active) 100%
    );
}

input[type="radio"]:disabled {
    background-color: var(--mantis-blueberry-jam-80);
}

input[type="radio"]:disabled:checked {
    background-image: radial-gradient(
        circle,
        var(--mantis-blueberry-jam-07) 0%,
        var(--mantis-blueberry-jam-60) 50%,
        transparent 50%,
        transparent 100%
    );
}

input[type="radio"]:not(:disabled):focus {
    box-shadow: none;
}

input[type="radio"]:not(:disabled):hover {
    outline: 1px solid var(--mantis-blueberry-jam-09);
}

input[type="radio"]:focus-visible {
    background-color: var(--mantis-blueberry-jam-07);
    outline: 1px solid black;
}

/* Checkbox arena */

/* Backwards compat: */

/* INLINE CHECKBOXES */

.checkbox-arena-standard {
    width: 90%;
    margin: 1rem auto;
    background-color: #f8f8f8;
}

.checkbox-arena-standard input {
    margin-right: 30px;
}

.checkbox-inline {
    padding: 20px;
}
.checkbox-inline:hover {
    background-color: #b6d8fe;
}

.checkbox-inline input {
    margin: 0px 10px 4px 0;
    display: inline;
    vertical-align: middle;
}

.button-select-mantis {
    margin-top: 16px;
    margin-bottom: 30px;
}

.button-select-mantis button {
    margin-bottom: 10px;
}

.button-select-mantis input[type="radio"],
.button-select-mantis input[type="checkbox"] {
    display: none;
}

/* Inline radio buttons */
.inline-radio-arena {
    margin-bottom: 20px;
}

.inline-radio-arena input {
    margin: 4px 0 8px 0;
}

/* Date fields */
.mantis-date-container {
    display: flex;
    justify-content: space-between;
}

.mantis-date-field-container .date-format {
    padding: 0 76px 0 10px;
    color: var(--mantis-blueberry-jam-80);
}

/* Tempus dominus */
.tempus-dominus-widget .calendar-header {
    margin-top: 10px;
}

/* Checkbox arena:  Hide checkboxes and radio buttons */

.mantis-divider {
    margin-top: 40px;
    padding-top: 40px;
    border-top: 1px solid var(--mantis-blueberry-jam-12);
}

.checkbox-arena-mantis-default input {
    display: none;
}

/* Slider toggle:
https://bootsnipp.com/snippets/GaxR2
 */
/* The switch - the box around the slider */
.mantis-switch {
    position: relative;
    display: block;
    width: 56px;
    height: 28px;
    float: right;
}

/* Hide default HTML checkbox */
.mantis-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

/* The slider */
.mantis-switch .slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--mantis-blueberry-jam-12);
    -webkit-transition: 0.4s;
    transition: 0.4s;
}

.mantis-switch .slider:before {
    position: absolute;
    content: "";
    height: 24px;
    width: 24px;
    left: 3px;
    bottom: 2px;
    background-color: white;
    -webkit-transition: 0.4s;
    transition: 0.4s;
}

.mantis-switch input:checked + .slider {
    background-color: var(--mantis-brand-primary);
}

.mantis-switch input.primary:checked + .slider {
    background-color: var(--mantis-brand-primary);
}

.mantis-switch input.success:checked + .slider {
    background-color: #8bc34a;
}

.mantis-switch input.info:checked + .slider {
    background-color: #3de0f5;
}

.mantis-switch input.warning:checked + .slider {
    background-color: #ffc107;
}

.smantis-witch input.danger:checked + .slider {
    background-color: #f44336;
}

.mantis-switch input:focus + .slider {
    box-shadow: 0 0 1px var(--mantis-blueberry-jam);
}

.mantis-switch input:checked + .slider:before {
    --webkit-transform: translateX(26px);
    --ms-transform: translateX(26px);
    transform: translateX(26px);
}

/* Rounded sliders */
.mantis-switch .slider.round {
    border-radius: 34px;
}

.mantis-switch .slider.round:before {
    border-radius: 50%;
}

/* Popover */

.popover-tour {
    --bs-popover-font-size: 1rem;
    --bs-font-sans-serif: "Proxima Nova", "Helvetica", "Arial", sans-serif;
    --bs-popover-header-bg: var(--mantis-blueberry-jam);
    --bs-popover-bg: var(--mantis-blueberry-jam);
    --bs-popover-body-color: var(--mantis-white);
    --bs-popover-header-padding-x: 12px;
    --bs-popover-header-padding-y: 12px;
    --bs-popover-body-padding-x: 18px;
    --bs-popover-body-padding-y: 18px;
    --bs-popover-max-width: 301px;

    border-radius: 6px;
    min-width: 301px;
    font-weight: 600;
}

.popover-tour-index {
    color: var(--mantis-lavender-macaron);
    padding-bottom: 4px;
    font-weight: 400;
}

.popover-navigation {
    padding: 6px 2px;
    gap: 2px;
    display: flex;
    justify-content: space-evenly;
}

.popover-navigation .btn {
    padding-left: 42px;
    padding-right: 42px;
    font-weight: 600;
    line-height: 1.2;
}

/* Tour Modal */
.tour-modal {
    z-index: 1111;
    text-align: center;
}

.tour-modal .modal-dialog {
    --bs-modal-border-width: 0;
    --bs-modal-width: 415px;
}

.tour-modal .modal-content {
    height: 193px;
    width: 415px;
    border-radius: 6px;
}

.tour-modal .modal-header {
    padding: 30px 16px 30px 24px;
    height: 75px;
    border-bottom: none;
}

.tour-modal .modal-title {
    top: 50%;
    width: 100%;
}

.tour-modal .modal-body {
    padding: 0;
    max-height: 50px;
}

.tour-modal > div {
    height: 13px;
    line-height: 1;
}

.tour-modal .modal-navigation {
    height: 44px;
}

.tour-modal .modal-footer {
    border-top: none;
    justify-content: center;
    padding: 0 24px 0 24px;
    --bs-modal-footer-gap: 0;
}

/* Filter lists */

.btn-filter-dropdown {
    border: 6px solid var(--mantis-coconut-milk);
    border-radius: 6px;
    width: 100%;
    color: var(--mantis-blueberry-jam);
    padding: 4px 8px;
    background-color: var(--mantis-coconut-milk);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Dropdowns */

.dropdown-menu {
    --bs-dropdown-bg: var(--mantis-white);
    --bs-dropdown-font-size: 1rem;
    --bs-dropdown-min-width: 305px;
    --bs-dropdown-divider-bg: var(--bs-mantis-blueberry-jam-12);
    --bs-dropdown-link-hover-color: var(--mantis-blueberry-jam);
    --bs-dropdown-link-hover-bg: var(--mantis-blueberry-jam-09);
    --bs-dropdown-link-active-color: var(--mantis-blueberry-jam);
    --bs-dropdown-link-active-bg: var(--mantis-blueberry-jam-09);
    --bs-dropdown-link-disabled-colour: var(--mantis-blueberry-jam-30);
    margin: 2px 0 0 0;
    border-width: 0;

    line-height: 1; /* These can appear in parents with interesting line heights */
}

/* Dropdowns dark */

.dropdown-menu-dark {
    --bs-dropdown-bg: var(--mantis-blueberry-jam);
    --bs-dropdown-divider-bg: var(--bs-mantis-white-10);
    --bs-dropdown-link-hover-color: var(--mantis-wisteria);
    --bs-dropdown-link-active-color: var(--mantis-white);
    --bs-dropdown-link-active-bg: var(--mantis-blueberry-jam-12);
    --bs-dropdown-link-disabled-colour: var(--mantis-white-60);
}

.dropdown-menu-dark:focus-visible {
    color: var(--mantis-white-80);
}

.dropdown-menu-small {
    --bs-dropdown-min-width: auto;
}

.dropdown-menu h5 {
    font-weight: bold;
    padding: 12px 24px;
    margin: 0;
}

.dropdown li {
    border-bottom: 1px solid var(--mantis-blueberry-jam-12);
}

.dropdown-item {
    padding: 10px 18px 10px 18px;
    line-height: 1;
    border-width: 0;
    display: flex;
    align-items: center;
}

.dropdown-menu li:last-child {
    border-bottom-left-radius: 6px;
    border-bottom-right-radius: 6px;
}

.dropdown-item:focus-visible {
    color: var(--mantis-brand-primary);
}

.screen-darken {
    content: "";
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background-color: rgba(0, 0, 0, 0.35);
    pointer-events: none;
    z-index: 4;
    opacity: 1;
    visibility: visible;
    position: fixed;
}

.drop-icon {
    font-size: 1.25rem;
    padding-right: 18px;
}
.dropdown-menu:has(> .search-container) {
    min-width: 640px;
    box-shadow: 0 0 16px 0 rgba(0, 0, 0, 0.24);
}

.search-container {
    padding: 8px 16px;
    font-size: 1.25rem;
}
.search-container i {
    color: var(--mantis-blueberry-jam-30);
}
.search-container .btn-icon-square-discrete {
    background-color: var(--mantis-blueberry-jam-12);
    border-radius: 70px;
    letter-spacing: 0px;
    padding: 5px 0px;
}
.search-container .btn-icon-square-discrete i {
    color: var(--mantis-blueberry-jam);
    font-size: 0.625rem;
}
.search-bar {
    border: none;
    width: 90%;
}
.search-bar:focus {
    border: none;
    outline: none;
}
.search-bar-item {
    font-weight: 400;
    display: flex;
    align-items: center;
}
.search-bar-item i {
    color: var(--mantis-blueberry-jam-30);
}
.search-bar-item.active span {
    text-decoration: underline;
}

.search-bar-item.active i {
    text-decoration: none;
}
#search-results-link {
    text-decoration: none;
    color: var(--mantis-violet-plum);
}
#search-results-link.active {
    text-decoration: underline;
}
#suggestions {
    list-style: none;
    padding: 0;
    max-height: 300px;
    overflow-y: auto;
    border-top: 1px solid #ccc;
    font-size: 1.25rem;
    background-color: #fff;
}
#suggestions li {
    padding: 12px;
    cursor: pointer;
}
/* https://developer.mozilla.org/en-US/docs/Web/CSS/-webkit-line-clamp */
#suggestions li span {
    display: -webkit-box;
    line-clamp: 1;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

#suggestions a:not(.disabled) {
    text-decoration: none;
    color: var(--mantis-blueberry-jam);
}
#suggestions a.disabled {
    cursor: default;
}

#suggestions a:not(.disabled):hover li span {
    text-decoration: underline;
}

/* Catalogue */
.catalogue-sidemenu-item:hover {
    cursor: pointer;
}

.catalogue-sidebar h2 {
    padding: 30px 0 0 0;
}

.catalogue-sidebar h5 {
    margin: 16px 30px 16px 30px;
}

.catalogueWarningContainer {
    padding: 0 25px;
    max-width: 724px;
}

.catalogueWarningContainer > p:first-of-type {
    font-weight: 700;
}

.catalogue-sidebar .offcanvas {
    --bs-offcanvas-border-width: 0;
    --bs-offcanvas-zindex: 2;
    --bs-offcanvas-color: var(--mantis-blueberry-jam);
    --bs-offcanvas-bg: white;

    position: absolute;
    top: 68px;
    bottom: 60px;
    width: 22.7%;
}

.catalogue-offcanvas-back {
    margin: 40px 24px 18px 19px;
}

.catalogue-body {
    width: 100%;
    min-height: 100vh;
}
.catalogue-body:has(> .aim-awards) {
    min-height: auto;
}

.availability-toggle-container a {
    color: var(--mantis-blueberry-jam-60);
    font-weight: 600;
    text-decoration: none;
}

.availability-toggle-container a.active {
    color: var(--mantis-blueberry-jam);
    font-weight: 600;
    text-decoration: underline;
}

/* Standard content layout */

.ext-logo-img {
    height: 50px;
}

.left-container {
    margin-top: 60px;
    padding-right: 40px;
}

.right-container {
    margin-top: 30px;
}

.nav-icon-list {
    font-size: 1.875rem;
}

.home-link {
    font-size: 1rem;
    font-weight: 600;
}

.home-img {
    height: 24px;
}

/* The little chevron that moved */

.movable-icon:hover i {
    transform: translate(10px, 0);
}

.movable-icon i {
    transition: transform 0.2s ease-out;
    display: inline-block;
}

/* avoid-the-to-top-button */
.mantis-content {
    padding-bottom: 100px;
}

/* Mantis content implies that text will be used here */
.mantis-content h3 {
    margin-top: 1rem;
}

.mantis-content ul,
.mantis-content .list-group {
    margin-bottom: 1rem;
}

/* footer */

.footer {
    background-color: var(--mantis-blueberry-jam);
    color: white;
    font-size: 1rem;
    position: fixed;
    height: var(--dice-footer-height);
    width: 100%;
    bottom: 0;
    z-index: 10;
}

.status-bar {
    padding: 10px 0;
}

.battery-indicator {
    padding-top: 3px;
    font-size: 1.875rem;
}

/* !important is needed to override the 'd-flex' class that still exists on older cached modules */
:is(.battery, .clock, .current-date) {
    display: none !important;
}
body[data-diceenvtype="in-cell"] :is(.battery, .clock, .current-date) {
    display: flex !important;
}

/* Tool tip - modelled from btn-navigation */
.mantis-tooltip {
    --bs-tooltip-max-width: 400px;
    --bs-tooltip-font-size: 1rem;
    --bs-tooltip-padding-x: 10px;
    --bs-tooltip-padding-y: 4px;
    --bs-tooltip-border-radius: 6px;
    --bs-tooltip-bg: var(--mantis-blueberry-jam);
    --bs-tooltip-color: white;
    min-width: auto;
    width: auto;
    line-height: 1.2;
    font-weight: 600;
}

.mantis-tooltip .tooltip-inner {
    background-color: var(--mantis-blueberry-jam);
    color: white;
    border-color: var(--mantis-blueberry-jam-80);
}

.mantis-tooltip .tooltip-arrow {
    background-color: var(--mantis-wisteria);
    color: var(--mantis-white);
    display: none;
}

/* Task bar */

.task-bar {
    color: white;
    border-color: var(--mantis-blueberry-jam-80);
    height: var(--dice-footer-height);
    padding: 0 0 0 30px;
}

.task-bar .btn-group {
    margin: 8px 0;
}

.task-bar .btn-group .btn {
    text-align: left;
}

.task-bar-tab-label {
    display: inline-block;
    width: 150px;
}

.task-bar .btn-tools-container {
    border-left: 1px solid var(--mantis-white-60);
}

.task-bar .btn-tools-container .btn-icon-square {
    border: 0;
    border-radius: 0;
    padding: 18px 24px;
}

.task-bar .mn-paper-x-earmark-rounded {
    color: var(--mantis-seasalt-ice-cream);
}

.task-bar .mn-pencil {
    color: var(--mantis-blue-strawberry);
}

/* Coracle Quiz */
.coracle-quiz-table table {
    background: inherit;
}

.coracle-quiz-table table td,
.coracle-quiz-table table th {
    border: 0;
}

.coracle-quiz-table table .cq-selected {
    background-color: var(--mantis-blueberry-jam-07);
}

/*Status bar*/
.status-bar {
    height: var(--dice-footer-height);
    padding: 12px 0;
}

.status-bar-container {
    padding-right: 20px;
}

.status-bar-sync-icon {
    font-size: 1.5rem;
}

/* Media pages */
iframe#pdf-frame {
    border: 2px solid var(--mantis-blueberry-jam-12);
}

.iframe-fix {
    min-height: 100%;
}

.mantis-prev-next {
    display: flex;
    justify-content: flex-end;
    color: var(--mantis-blueberry-jam);
}

/* Make sure the pdf takes the whole height by applying this to all parents */
.vertical-stretch {
    display: flex;
    flex-direction: column;
}

#previous-button a::before {
    content: attr(data-description);
    display: inline;
    top: 40px;
    left: 0;
}

#next-button a::before {
    content: attr(data-description);
    left: 90px;
    top: 40px;
}

/* notes */
.btn-sort {
    font-size: 1.875rem;
    min-width: 65px;
}

.paddack-panel {
    position: relative;
    padding-left: 16px !important;
}

.notes-paddack-container {
    height: 100%;
    border-radius: 0;
    padding: 10px;
    border: 2px solid var(--mantis-blueberry-jam-12);
    box-shadow: 0 0 16px 0 rgba(0, 0, 0, 0.04);
}

.notes-paddack:focus-visible {
    outline: none;
    border-color: var(--mantis-wisteria);
}

textarea.notes-paddack {
    height: calc(100% - 60px);
    width: 100%;
    border: none;
    padding: 0 6px;
    margin: 30px 0;
}

.notes-paddack::placeholder {
    color: var(--mantis-blueberry-jam-80);
}

.notes-paddack-container:has(.notes-paddack:focus-visible) {
    border-color: var(--mantis-wisteria);
}

#notes-close {
    position: absolute;
    top: 12px;
    right: 10px;
}

#notes-clear {
    position: absolute;
    bottom: 12px;
    right: 10px;
    border: none;
    background: white;
    font-size: 1.25rem;
}

/* Side menu */
.dont-overlap-the-side-menu {
    margin-right: 30px;
    height: 100%;
    position: relative;
}

.media-side-menu {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    right: 0;
    border-radius: 6px 0 0 6px;
    display: flex;
    flex-direction: column;
}
.media-side-menu .btn {
    border-radius: 0;
}

.media-side-menu .rounded-top-left {
    border-top-left-radius: 6px;
}

.media-side-menu .rounded-bottom-left {
    border-bottom-left-radius: 6px;
}

.side-menu-extra {
    transform: translateY(120%);
}

/* List of links with an icon left */
.file-list-item {
    display: flex;
    text-decoration: none;
    list-style: none;
    border-top: 2px solid var(--mantis-blueberry-jam-12);
    padding: 15px 0;
    margin: 0;
}

.file-list-item:last-child {
    border-bottom: 2px solid var(--mantis-blueberry-jam-12);
}

/* Inline list of buttons */

.button-list-group {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 40px;
}

.button-list-group .btn {
    font-weight: 400;
}

.list-container {
    margin: 30px 0;
}

.title-link-container {
    flex-grow: 1;
}

.title-link-container a {
    font-weight: 600;
}

.title-link-container a, 
.list-elem-title, 
.file-list-item a {
    color: var(--brand-primary) !important;
    font-family: var(--brand-font);
    text-decoration: none;
}

.title-link-container a:hover {
    color: var(--brand-primary-hover) !important;
    text-decoration: underline;
}

.file-list-item, 
.list-group-item,
.description-box p {
    color: var(--brand-font-color, var(--mantis-blueberry-jam)) !important;
    font-family: var(--brand-font);
}

/* 3. Fix the "Indifferent" links (links that shouldn't look like standard blue links) */
.indifferent-link-container a, 
.link-indifferent {
    color: var(--brand-primary) !important;
}

/* 4. Fix the horizontal dividers if they look too dark/light */
.file-list-item {
    border-top: 2px solid var(--mantis-blueberry-jam-12);
}

.level-container {
    width: 200px;
    text-align: right;
}

.level-list {
    margin-left: 40px;
    text-align: right;
}

.list-body {
    padding: 40px 60px 40px 60px;
    background-color: var(--mantis-coconut-milk);
    box-shadow: inset 0 20px 20px -20px rgba(0, 0, 0, 0.1);
    min-height: 100vh;
}

.list-elem-title {
    line-height: 1.5;
}

.list-elem-title:active {
    text-decoration: underline;
}

.list-date {
    font-size: 1rem;
    line-height: 1.4;
    font-weight: 600;
}

.filter-body {
    background: white;
    color: var(--mantis-blueberry-jam);
    box-shadow: inset 0 20px 20px -20px rgba(0, 0, 0, 0.1);

    font-size: 1.125rem;
}

.filter-body h2 {
    margin: 0 30px 30px 30px;
}

.filter-body-dark {
    color: white;
    background: var(--mantis-blueberry-jam);
}

.level-body {
    padding: 30px 30px 0 30px;
}

.main-logo-container {
    padding: 30px;
}

.main-logo-container img {
    max-width: 100%;
}

.main-page-title {
    margin-top: 24px;
    margin-left: 30px;
    margin-bottom: 0;
}

.level-body {
    padding: 30px 30px 0 30px;
}

.main-logo-container {
    padding: 30px;
}

.main-page-title {
    margin-top: 24px;
    margin-left: 30px;
    margin-bottom: 0;
}

.list-group {
    --bs-list-group-color: var(--mantis-blueberry-jam);
    --bs-list-group-bg: transparent;
    --bs-list-group-border-color: var(--mantis-blueberry-jam-12);
    --bs-list-group-border-width: 2px;
    --bs-list-group-border-radius: 0;
    --bs-list-group-item-padding-x: 30px;
    --bs-list-group-item-padding-y: 10px;
    --bs-list-group-hover-color: var(--mantis-blueberry-jam);
    --bs-list-group-hover-bg: transparent;
    --bs-list-group-active-color: var(--mantis-blueberry-jam);
    --bs-list-group-active-bg: transparent;
    --bs-list-group-active-border-color: var(--mantis-blueberry-jam-12);
    --bs-list-group-disabled-color: var(--mantis-blueberry-jam-60);
    --bs-list-group-disabled-bg: transparent;

    --bs-list-group-action-color: var(--mantis-blueberry-jam);
    --bs-list-group-action-hover-color: var(--mantis-blueberry-jam);
    --bs-list-group-action-hover-bg: transparent;
    --bs-list-group-action-active-border-color: transparent;
    --bs-list-group-action-active-color: var(--mantis-blueberry-jam);
    --bs-list-group-action-active-bg: var(--mantis-blueberry-jam-12);
}

.list-group-item {
    border-left: 0;
    border-right: 0;
}

.list-group-item-action {
    font-weight: 400;
    border-radius: 0;
    text-decoration: none;
}

.list-group-item-action:focus-visible {
    color: var(--mantis-violet-plum);
}

/* Borders are double-stacked here, causing transparency darkening, which we need to remove */
.list-group-item.active:not(:first-child) {
    border-top-color: transparent;
}

.active-left-border:hover,
.active-left-border:not(:disabled):not(.disabled):active,
.active-left-border.active {
    text-decoration: none;
    box-shadow: 8px 0 0 var(--mantis-brand-menu-border-color) inset;
}

.active-left-border:hover i,
.active-left-border:not(:disabled):not(.disabled):focus-visible i,
.active-left-border:not(:disabled):not(.disabled):active i {
    color: var(--mantis-brand-menu-border-color);
}

.list-group-dark {
    --bs-list-group-color: white;
    --bs-list-group-border-color: var(--mantis-white-10);
    --bs-list-group-hover-color: white;
    --bs-list-group-active-color: white;
    --bs-list-group-disabled-color: var(--mantis-white-60);

    --bs-list-group-action-color: white;
    --bs-list-group-action-hover-color: white;
    --bs-list-group-action-active-color: white;
    --bs-list-group-action-active-bg: var(--mantis-white-10);
}
.list-group-dark .list-group-item.active {
    --bs-list-group-active-border-color: var(--mantis-white-10);
}

.list-group-dark .list-group-item-action:focus-visible {
    color: white;
}

/* My account */

.my-account-content .module-image,
.my-certificates .module-image {
    width: 100px;
    border-radius: 6px;
}

.my-account-content .module-holder,
.my-certificates .module-holder {
    border-bottom: solid 2px var(--mantis-blueberry-jam-12);
    width: 100%;
    padding: 18px 0;
}

.my-account-content .recently-viewed-title {
    color: var(--mantis-blueberry-jam);
}

.my-account-content #recent-modules .module-provider {
    color: var(--mantis-blueberry-jam-60);
}

/* My Certificates */
#modal-edit-name-on-certificate {
    margin: auto;
    max-width: 550px;
}
#modal-edit-name-on-certificate :is(.modal-header, .modal-footer) {
    border: none;
}
#name-on-certificate-static {
    max-width: 500px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

/* My Account Right Side Bar */
.right-side-bar-container {
    min-width: min-content;
    max-width: 400px;
}
.right-side-bar {
    background-color: white;
    border-radius: 6px;
    padding: 24px;
}

.right-side-bar .active-left-border {
    padding: 8px 0;
    font-weight: 600;
}
/* smaller chevron icon */
.right-side-bar a i {
    font-size: 12px;
}

.level-body {
    padding: 30px 30px 0 30px;
}

.main-logo-container {
    padding: 30px;
}

.main-page-title {
    margin-top: 24px;
    margin-left: 30px;
    margin-bottom: 0;
}

.media-nav {
    margin-bottom: 14px;
}

/* Windows */
.winbox {
    container-type: inline-size;
}

.wb-body {
    overflow-x: hidden;
    overflow-y: hidden;
}
.wb-body:has(> .document-editor-container) {
    background: var(--ck-color-base-foreground);
}
.wb-body .document-editor {
    border: none;
}

.wb-body .document-editor__editable-container {
    max-height: unset;
    overscroll-behavior: contain;
}
.wb-body .document-editor-container {
    height: 100%;
}
.wb-body :is(.document-editor, #spreadsheet-modal) {
    height: calc(100% - var(--writing-toolbar-height));
}
.wb-body .jexcel_container {
    height: 100%;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.wb-control * {
    vertical-align: middle;
}
.wb-close {
    background-image: none;
}

/* Modal page */

.modal-header {
    padding-top: 0.75rem;
    display: flex;
    justify-content: space-between;
}

.modal-header .btn-link {
    padding: 0;
    font-size: 1.25rem;
}

.modal-content {
    border-radius: 6px;
}

.modal-footer {
    justify-content: space-between;
}

.modal-header .close-btn {
    padding: calc(var(--bs-modal-header-padding-y) * 0.5)
        calc(var(--bs-modal-header-padding-x) * 0.5);
    margin: calc(-0.5 * var(--bs-modal-header-padding-y))
        calc(-0.5 * var(--bs-modal-header-padding-x)) calc(-0.5 * var(--bs-modal-header-padding-y))
        auto;
}

/* Modal specifics */

#closeSessionWarningModal .modal-dialog,
#feedbackModal .modal-dialog {
    width: 549px;
    max-width: 549px;
}

.feedback-modal .feedback-header,
.warning-modal .modal-header {
    height: 5%;

    padding-top: 30px;
    border: none;
}

.feedback-modal {
    margin: auto;
    width: 550px;
    height: 550px;
}

.warning-modal {
    margin: auto;
    width: 550px;
    height: 316px;
}

.feedback-modal .feedback-body {
    width: auto;
    height: 90%;

    padding-top: 15px;
}

.warning-modal .modal-body {
    width: auto;
    height: auto;

    padding: 0;
}

.feedback-modal .feedback-top {
    height: 20%;
}

.feedback-modal .feedback-stars-container {
    width: 63%;
    margin: auto;
    padding-left: 10px;
}

.feedback-modal .feedback-stars {
    width: 100%;
    margin-right: 27px;
}

.jq-star-svg {
    overflow: visible;
}

.feedback-modal #feedback-star-text {
    font-weight: 500;
    font-size: 2.25rem;
    width: 20%;

    color: var(--mantis-blueberry-jam-12);
}

.feedback-modal .feedback-helper {
    height: 10%;

    padding: 12px 30px 12px 30px;
    gap: 10px;
}

.feedback-modal .feedback-helper p {
    text-align: center;
    color: var(--mantis-blueberry-jam-60);

    font-size: 1rem;
}

.feedback-modal .feedback-title,
.warning-modal .modal-title {
    color: #000000;
    font-size: 1.5rem;
    font-weight: 600;
}

.feedback-modal .feedback-review-title {
    height: 52px;
    padding: 12px 30px;

    gap: 10px;
}

.feedback-modal .feedback-review-title h6 {
    color: black;
    font-size: 1.5rem;
    font-weight: 600;
}

.feedback-modal .feedback-review-title {
    height: 10%;
    padding: 12px 30px;

    gap: 10px;
}

.feedback-modal .feedback-review-title h6 {
    color: black;

    font-weight: 700;
    font-size: 1.25rem;
}

.feedback-modal .feedback-textarea-container {
    height: 35%;
    width: 100%;

    padding: 0 30px;
    gap: 10px;
}

.warning-modal .close-session-warning {
    height: 65%;
    padding: 12px 18px 16px 18px;
}

.warning-modal .close-session-warning div {
    border: 3px solid var(--mantis-raspberry-coulis);
    border-radius: 6px;
    padding: 24px;

    width: auto;
}

.warning-modal .modal-warning {
    color: var(--mantis-raspberry-coulis);

    width: 93%;
    font-weight: 600;
    font-size: 1.25rem;

    gap: 18px;
}

.warning-modal .close-session-warning .mn-exclamation-mark-in-circle {
    width: 24px;
    height: 24px;

    font-size: 1.25rem;
    line-height: 1.5;
    text-align: center;
    color: var(--mantis-raspberry-coulis);
}

.feedback-modal .feedback-textarea-container #review-input {
    height: 100%;
    width: 100%;

    padding: 16px 10px 8px 14px;
    border: none;
    background-color: var(--mantis-blueberry-jam-07);
    resize: none;
    border-radius: 6px;

    outline: none;
}

.feedback-modal .feedback-textarea-container #review-input.invalid {
    border: 3px solid var(--mantis-raspberry-coulis);
}

.feedback-modal .feedback-word-count-container {
    height: 8%;

    padding: 8px 30px;
    gap: 10px;
}

.feedback-modal .feedback-word-count-container #feedback-word-count {
    font-weight: 600;
    font-size: 1.25rem;

    text-align: center;
}

.feedback-modal .feedback-word-count-container #feedback-word-count.invalid {
    color: var(--mantis-raspberry-coulis);
}

.feedback-modal .feedback-footer {
    width: 100%;
    height: 18%;

    padding: 0 30px 30px 30px;
    border: none;
}

.warning-modal .modal-footer {
    width: 100%;
    height: 35%;

    padding: 0 18px 24px 18px;
    border: none;
}

.feedback-modal .feedback-footer .feedback-submit.disabled {
    background-color: var(--mantis-blueberry-jam-12);
    color: var(--mantis-blueberry-jam-60);
    border: none;

    opacity: 1;
}

.modal-footer {
    justify-content: space-between;
}

/* Personal base styling */

.document-editor {
    max-height: none;
}

.document-editor-container {
    width: inherit;
}

.document-editor__editable-container {
    max-height: 71vh;
}

.wb-header {
    background-color: var(--mantis-violet-plum);
}

.ck-powered-by-balloon {
    display: none !important;
}

.writing-bg {
    background-color: var(--ck-editor-white);
}

.writing-toolbar {
    border-top: 1px solid white;
    background-color: var(--mantis-violet-plum);
    color: white;
    min-height: var(--writing-toolbar-height);
}

.writing-toolbar > .col {
    min-width: 0;
}

.writing-toolbar > div:last-child {
    border: none;
}

.writing-toolbar > div {
    border-right: 1px solid white;
}

.char-count-section {
    align-items: center;
}

.jexcel_container {
    width: 100%;
    height: calc(
        100vh -
        var(--writing-toolbar-height) -
        var(--dice-header-height) -
        var(--dice-footer-height)
    );

    overflow: scroll;
}

.prev-item-icon {
    font-size: 0.875rem;
    padding-right: 6px;
}

.next-item-icon {
    font-size: 0.875rem;
    padding-left: 6px;
}
/* Carousels */
.mantis-carousel-icon {
    font-size: 3.75rem;
    color: var(--mantis-blueberry-jam);
}

/* Modals */
.modal {
    --bs-modal-header-padding-x: 6px;
    --bs-modal-header-padding-y: 6px;
}

/* mdlg modals - for the keyboard shortcuts */

.modal-mdlg {
    --bs-modal-width: 650px;
}

/*Extra large modals */
.modal-xl {
    --bs-modal-width: 98%;
    height: 90%;

    margin-top: 1%;
}

.modal-xl .modal-content {
    height: 100%;
    overflow: hidden;
}

.modal-xl .document-editor {
    overflow-y: scroll;
}

/* Edit title Modal */
.editTitleModal {
    margin: auto;
    max-width: 549px;
}

.editTitleModal .modal-header {
    border: none;
}
.editTitleModal .modal-footer {
    border: none;
}
.editTitleModal .modal-footer #btn-edit-title-ok {
    min-width: 100px;
}

.editTitleModal .mn-x {
    font-size: 0.875rem;
}

.note-modal-stats {
    padding: 6px 24px 6px 65px;

    background-color: var(--mantis-coconut-milk);
    border-color: var(--mantis-blueberry-jam-07);

    color: var(--mantis-blueberry-jam-80);
    font-size: 1rem;
}

#editTitleModal .new-title-length {
    font-size: 1rem;
}

/*Writing & Spreadsheet Modal */

.words-left-container,
.char-count-container {
    padding-right: 1rem;
}

#spreadsheetModal .modal-body {
    overflow-y: hidden;
}

.offcanvas-value {
    font-weight: 400;
}
.offcanvas-subtitle {
    font-weight: 600;
    border-bottom: 2px solid var(--mantis-blueberry-jam-07);
    padding-bottom: 12px;
    margin-bottom: 12px;
}

.offcanvas-list {
    list-style: none;
}

.offcanvas.offcanvas-top {
    height: fit-content;
}
.offcanvas-image {
    position: absolute;
    max-width: 24px;
    left: -2.25vw;
    top: 1vh;
}

.offcanvas-bulb {
    left: -1.5vw;
    top: -1vh;
}

/* Centered content containers */
.centered-modal-container {
    max-width: 600px;
    width: 90%;
    background: white;
    border-radius: 16px;
    padding: 48px 32px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    text-align: center;
}

@media (width <= 768px) {
    .centered-modal-container {
        padding: 32px 24px;
        width: 95%;
    }
}

@media (width <= 480px) {
    .centered-modal-container {
        padding: 24px 16px;
    }
}

/* up button */
#toTop {
    text-decoration: none;
    display: none;
    position: fixed;
    bottom: 75px;
    right: 44px;
    z-index: 99;
    border: none;
    background-color: var(--mantis-blueberry-jam-90);
    color: white;
    border-radius: 100px;
    padding: 12px 19px;
    cursor: pointer;
}

/* Badges */
.badge {
    --bs-badge-color: var(--mantis-blueberry-jam);
    --bs-badge-padding-x: 16px;
    --bs-badge-padding-y: 5px;
    --bs-badge-font-weight: normal;
    --bs-badge-font-size: 1rem;
    line-height: 1.25;
    font-weight: inherit;
}

.box-header {
    min-height: 75px;
}

/* Reviewer Page */

.requires-admin {
    opacity: 0;
    transition: 2s opacity;
}
.reviewer-page-container {
    background-color: var(--mantis-blueberry-jam-09);
    border-radius: 16px;
    margin: 16px auto;

    padding: 4px 16px;
    word-wrap: break-word;
}

#id_no-statements-to-review {
    padding: 24px;
    background-color: var(--mantis-blueberry-jam-09);
    border-radius: 16px;
}

.review-page-title {
    margin-top: 1.2em;
    font-weight: normal;
    font-size: 1.6em;
}

/* SPELLCHECK */

.ck-content s {
    border-bottom: 1px solid red;
    background-color: unset;
    text-decoration: none;
}

.ck-content s:hover {
    background-color: lightcoral;
}

.spellcheck-list-item:hover {
    cursor: pointer;
}

#mantis-header {
    min-height: var(
        --dice-header-height
    ); /* min-height to guarantee desired height when other page items flex-grow */
    /* Fixed height is required for the transition to work. */
    height: var(--dice-header-height);
    transition: height 0.5s;
    background-color: white;
}

.mantis-headers-shadow {
    /* 
    Sigh.
    I don't want the header to create a new stacking context. 
    It becomes very difficult to control how the dropdowns there will interplay
    with stacked things in the body.

    So we apply the header's shadow as an inset to the main container.
    Elements which colour this (such as filter-body) will need to re-apply this.
    */
    box-shadow: inset 0 20px 20px -20px rgba(0, 0, 0, 0.1);
}

/* Developer mode overrides */
body.developer-mode #mantis-header {
    border-top: 5px solid var(--mantis-raspberry-coulis);
}
body.developer-mode .footer {
    border-bottom: 5px solid var(--mantis-raspberry-coulis);
}

@container (max-width: 700px) {
    .char-count-section {
        flex-direction: column;
        align-items: start;
        justify-content: center;
    }

    .char-count-section .word-count-div {
        padding-top: 5px;
    }

    .words-left-container,
    .char-count-container {
        line-height: 1.2;
    }
}

/* Bootstrap lg breakpoint */
@media (min-width: 992px) {
    .mantis-content .inset-image {
        float: right;
        margin-left: 18px;
        margin-bottom: 18px;
        max-width: 400px;
    }
}

/* Responsive */
@media (min-width: 1366px) {
    .container {
        --bs-gutter-x: 60px;
        max-width: 1366px;
    }

    .filter-body {
        width: 22.7%;
    }

    .filter-body-dark {
        width: 22.7%;
    }

    .list-body {
        width: 77.3%;
    }
}

@media (min-width: 1650px) {
    .card-reversable .card {
        height: auto;
    }
}

.progress-bar {
    --bs-progress-bar-bg: var(--mantis-blue-mojito);
    --bs-progress-bar-transition: width 0.3s;
}

/* Enlarge all default audio controls and text */
audio {
    width: 800px;
}
audio::-webkit-media-controls-play-button,
audio::-webkit-media-controls-mute-button {
    transform: scale(1.5);
}
audio::-webkit-media-controls-current-time-display,
audio::-webkit-media-controls-time-remaining-display {
    font-size: 24px;
}

.form-control, 
.input-like,
textarea {
    background-color: var(--mantis-white) !important;
    border: 1px solid var(--mantis-blueberry-jam-12) !important;
    padding: 10px 14px;
}

/* Adjust the specific "Choose File" button to look like a button */
input[type="file"]::file-selector-button {
    background-color: var(--mantis-white);
    border: 1px solid var(--mantis-blueberry-jam-12);
    border-radius: 4px;
    padding: 4px 12px;
    margin-right: 10px;
    cursor: pointer;
}