/* Colours come from the site's Elementor kit, with its current values as fallbacks. */
.qst-mmc {
    --qst-mmc-primary: var(--e-global-color-primary, #5377A4);
    --qst-mmc-dark: var(--e-global-color-secondary, #3F3F3F);
    --qst-mmc-accent: var(--e-global-color-accent, #FBBB1F);
    --qst-mmc-border: #EBEBF0;
    width: 100%;
    color: var(--qst-mmc-dark);
    text-align: left;
}

.qst-mmc-anchor {
    display: block;
    scroll-margin-top: 120px;
}

.qst-mmc-course {
    margin: 16px 0 24px;
}

.qst-mmc-table {
    width: 100%;
    margin: 0 0 16px;
    border-collapse: collapse;
    background: #fff;
    font-size: 15px;
}

.qst-mmc-table th,
.qst-mmc-table td {
    padding: 12px 14px;
    border: 0;
    border-bottom: 1px solid var(--qst-mmc-border);
    background: #fff;
    vertical-align: middle;
    text-align: left;
}

.qst-mmc-table th {
    background: var(--qst-mmc-primary);
    color: #fff;
    font-weight: 600;
}

.qst-mmc-table small {
    display: block;
    margin-top: 2px;
    color: #6b6b6b;
    font-size: 13px;
}

.qst-mmc-table s,
.qst-mmc-price s {
    color: #6b6b6b;
    font-size: 0.9em;
}

.qst-mmc-price-cell {
    white-space: nowrap;
}

.qst-mmc-action {
    text-align: right;
    white-space: nowrap;
}

.qst-mmc-button,
.qst-mmc a.qst-mmc-button,
.qst-mmc button.qst-mmc-button {
    display: inline-block;
    padding: 10px 18px;
    border: 2px solid var(--qst-mmc-primary);
    border-radius: 4px;
    background: var(--qst-mmc-primary);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
}

.qst-mmc a.qst-mmc-button:hover,
.qst-mmc a.qst-mmc-button:focus,
.qst-mmc button.qst-mmc-button:hover,
.qst-mmc button.qst-mmc-button:focus {
    border-color: var(--qst-mmc-dark);
    background: var(--qst-mmc-dark);
    color: #fff;
}

.qst-mmc a.qst-mmc-button-alt {
    background: #fff;
    color: var(--qst-mmc-primary);
}

.qst-mmc-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 13px;
    font-weight: 600;
}

.qst-mmc-badge-urgent {
    background: var(--qst-mmc-accent);
    color: #000;
}

.qst-mmc-badge-full {
    background: var(--qst-mmc-border);
    color: var(--qst-mmc-dark);
}

.qst-mmc-card,
.qst-mmc-empty {
    margin: 0 0 16px;
    padding: 18px;
    border: 1px solid var(--qst-mmc-border);
    background: #fff;
}

.qst-mmc-card-title {
    margin: 0 0 8px;
}

.qst-mmc-price {
    margin: 0 0 8px;
    font-size: 18px;
}

.qst-mmc-units {
    margin: 0 0 14px;
}

.qst-mmc-units summary {
    cursor: pointer;
    font-weight: 600;
}

.qst-mmc-filters {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 12px;
    margin: 0 0 16px;
}

.qst-mmc-filters label {
    display: flex;
    flex: 1 1 180px;
    flex-direction: column;
    gap: 4px;
    font-weight: 600;
}

.qst-mmc-filters select {
    width: 100%;
    min-height: 42px;
    padding: 8px;
    border: 1px solid #c9c9d2;
    background: #fff;
}

.qst-mmc-pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.qst-mmc-pagination a {
    padding: 6px 12px;
    border: 1px solid var(--qst-mmc-border);
    text-decoration: none;
}

.qst-mmc-pagination a[aria-current="page"] {
    background: var(--qst-mmc-primary);
    color: #fff;
}

.qst-mmc-course-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.qst-mmc-course-list li {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--qst-mmc-border);
}

@media (max-width: 700px) {
    .qst-mmc-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
    }

    .qst-mmc-table,
    .qst-mmc-table tbody,
    .qst-mmc-table tr,
    .qst-mmc-table td {
        display: block;
        width: 100%;
    }

    .qst-mmc-table tr {
        margin: 0 0 14px;
        border: 1px solid var(--qst-mmc-border);
    }

    .qst-mmc-table td {
        display: flex;
        justify-content: space-between;
        gap: 14px;
        padding: 10px 12px;
        text-align: right;
    }

    .qst-mmc-table .qst-mmc-cell {
        min-width: 0;
    }

    .qst-mmc-table td[data-label]::before {
        flex: 0 0 auto;
        content: attr(data-label);
        font-weight: 600;
        text-align: left;
    }

    .qst-mmc-table td.qst-mmc-action {
        display: block;
        border-bottom: 0;
    }

    .qst-mmc-action .qst-mmc-button {
        display: block;
        text-align: center;
    }
}


/* Mega menu */
.qst-mega {
    --qst-mega-dark: #1f3450;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 24px;
    box-sizing: border-box;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    color: #3f3f3f;
    text-align: left;
}

.qst-mega ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.qst-mega-cats {
    position: relative;
    min-height: 340px;
}

.qst-mega-cats > li {
    width: 250px;
}

/* The dividing line between sections and what's in them. */
.qst-mega-cats::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 250px;
    width: 1px;
    background: #dfe3ea;
}

.qst-mega a.qst-mega-cat {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 10px 12px;
    border-radius: 4px;
    color: #3f3f3f;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.3;
    text-decoration: none;
}

.qst-mega .qst-mega-item.is-open > a.qst-mega-cat,
.qst-mega a.qst-mega-cat:hover,
.qst-mega a.qst-mega-cat:focus {
    background: #eef1f6;
    color: #33557f;
}

.qst-mega-panel {
    position: absolute;
    top: 0;
    right: 0;
    left: 250px;
    display: none;
    padding: 0 0 0 24px;
}

.qst-mega-item.is-open > .qst-mega-panel {
    display: block;
}

.qst-mega a.qst-mega-all {
    display: block;
    margin: 10px 0 8px;
    color: #33557f;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
}

.qst-mega-panel ul {
    columns: 2;
    column-gap: 20px;
}

.qst-mega-panel li {
    break-inside: avoid;
}

.qst-mega-panel li a {
    display: block;
    padding: 6px 0;
    color: #3f3f3f;
    font-size: 14px;
    font-weight: 400;
    line-height: 1.35;
    text-decoration: none;
}

.qst-mega-panel li a:hover,
.qst-mega-panel li a:focus {
    color: #33557f;
    text-decoration: underline;
}

.qst-mega-help {
    padding: 20px;
    border-radius: 8px;
    background: var(--qst-mega-dark);
    color: #fff;
}

.qst-mega .qst-mega-help-title {
    margin: 0 0 6px;
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.25;
}

.qst-mega a.qst-mega-phone {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 12px;
    color: var(--e-global-color-accent, #FBBB1F);
    font-size: 20px;
    font-weight: 700;
    text-decoration: none;
}

.qst-mega-help-rows li + li {
    border-top: 1px solid rgba(255, 255, 255, .14);
}

.qst-mega-help-rows a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    color: #fff;
    font-size: 13.5px;
    font-weight: 500;
    line-height: 1.3;
    text-decoration: none;
}

.qst-mega-help-rows a:hover,
.qst-mega-help-rows a:focus {
    color: var(--e-global-color-accent, #FBBB1F);
}

.qst-mega-help-rows svg {
    flex: 0 0 18px;
    color: var(--e-global-color-accent, #FBBB1F);
}

/* Without a pointer: sections open in place, one under another. */
@media (max-width: 1024px) {
    .qst-mega {
        grid-template-columns: minmax(0, 1fr);
        padding: 12px;
    }

    .qst-mega-cats {
        min-height: 0;
    }

    .qst-mega-cats > li {
        width: auto;
    }

    .qst-mega-cats::before {
        display: none;
    }

    .qst-mega-panel {
        position: static;
        padding: 0 12px 8px;
    }

    .qst-mega-panel ul {
        columns: 1;
    }
}

/* Site link colours mustn't reach the dark box. */
.qst-mega .qst-mega-help a.qst-mega-phone,
.qst-mega .qst-mega-help a.qst-mega-phone:visited {
    color: var(--e-global-color-accent, #FBBB1F) !important;
}

.qst-mega .qst-mega-help-rows a,
.qst-mega .qst-mega-help-rows a:visited,
.qst-mega .qst-mega-help-rows a span {
    color: #fff !important;
}

.qst-mega .qst-mega-help-rows a:hover span,
.qst-mega .qst-mega-help-rows a:focus span {
    color: var(--e-global-color-accent, #FBBB1F) !important;
}
