/*------------------------------------*\
    CAMPER CONFIGURATOR

    Loaded only on the Camper Configurator page template. Uses the tokens from
    main.css — nothing here redefines a colour or a type size that already has
    a name.

    1.  Shell
    2.  Progress bar
    3.  Step body + actions
    4.  Step 1 — vehicles
    5.  Step 2 — wheelbases
    6.  Steps 3-6 — swatches
    7.  Steps 3-6 — layered preview
    8.  Step 7 — extras
    9.  Step 7 — running total
    10. Details panel
    11. Details panel — gallery
    12. Step 8 — the form
    13. Confirmation
    14. Responsive
    15. Get advice
\*------------------------------------*/


/*------------------------------------*\
    1. SHELL
\*------------------------------------*/

.configurator {
    background-color: var(--color-off-white);
}

/*
 * The steps are all in the page at once and hidden with the hidden attribute.
 * Grid and flex both beat it, so it is settled here once for everything inside.
 */

.configurator [hidden] {
    display: none !important;
}

/*
 * A rule can take any option off the list — a worktop that does not fit the
 * chosen van, an extra that is short wheelbase only. js/configurator.js marks
 * it .is-hidden and un-picks it, so this has to cover every step: without it
 * the option stays on screen, still looks pickable, and silently hands the
 * choice back to the first swatch the moment it is clicked.
 */

.configurator [data-option].is-hidden {
    display: none;
}

.configurator__noscript {
    padding: var(--space-lg) var(--gutter);
    background-color: var(--color-red);
    color: var(--color-white);
    text-align: center;
}

.configurator__noscript p {
    margin: 0;
}


/* Heading area — white, above the grey working area */

.configurator__header {
    padding: var(--section-y-sm) 0 var(--space-xl);
    background-color: var(--color-white);
    text-align: center;
}

.configurator__eyebrow {
    margin-bottom: var(--space-sm);
}

.configurator__title {
    margin: 0 auto;
    max-width: 20em;
    font-size: var(--fs-h1);
    font-weight: var(--fw-medium);
    line-height: var(--lh-heading);
    color: var(--color-heading);
}


/*------------------------------------*\
    2. PROGRESS BAR
\*------------------------------------*/

/*
 * Eight pips do not fit a phone, so the row scrolls sideways rather than
 * wrapping into a block that pushes the step itself off the screen. The nav
 * is the scroll port, so the list inside it may be wider than the screen.
 */

.configurator__progress {
    margin-top: var(--space-xl);
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
}

.configurator__progress::-webkit-scrollbar {
    display: none;
}

.configurator__progress-list {
    display: flex;
    align-items: center;
    gap: var(--space-xxs);
    width: max-content;
    margin: 0 auto;
    padding: 0;
    list-style: none;
}

.configurator__progress-item {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
    gap: var(--space-xxs);
}

/* The connector — drawn by the item, so the first one has none in front of it */

.configurator__progress-item + .configurator__progress-item::before {
    content: "";
    width: clamp(0.8rem, 1.2vw, 2rem);
    height: 1px;
    background-color: var(--color-grey-light);
}

.configurator__progress-item.is-done + .configurator__progress-item::before,
.configurator__progress-item.is-current::before {
    background-color: var(--color-charcoal);
}

.configurator__progress-link {
    /*
     * Positioned so the hidden labels below are contained by it. Left static,
     * their containing block is the page itself and their static positions —
     * out to the right, inside a row that scrolls sideways — stretch the
     * document's scroll width and give the whole page a horizontal drag.
     */
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    padding: 0;
    border: 0;
    background: none;
    font-family: inherit;
    font-size: var(--fs-xs);
    color: var(--color-text-muted);
    cursor: default;
}

.configurator__progress-link:not([disabled]) {
    cursor: pointer;
}

.configurator__progress-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.8rem;
    height: 2.8rem;
    border-radius: 50%;
    background-color: var(--color-grey-light);
    font-size: var(--fs-xs);
    font-weight: var(--fw-medium);
    color: var(--color-text-muted);
    transition: background-color var(--transition), color var(--transition);
}

.configurator__progress-item.is-done .configurator__progress-number,
.configurator__progress-item.is-current .configurator__progress-number {
    background-color: var(--color-red);
    color: var(--color-white);
}

/*
 * Eleven steps is a lot of label to fit, so the row is tuned for it rather
 * than left to overflow: the type drops a size, the words never wrap, and the
 * connectors give up most of their length. That lands the whole labelled row
 * inside the container from 1240px up. Narrower than that it goes compact —
 * see the breakpoints at the end of the file.
 */

.configurator__progress-label {
    white-space: nowrap;
    /*
     * A size down from the body's smallest, which is what buys the room for
     * eleven of them: the labelled row measures 1143px against the 1215px
     * container, leaving enough slack for a longer step name than any of the
     * ones set today.
     */
    font-size: 1.25rem;
}

.configurator__progress-item.is-current .configurator__progress-label {
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

.configurator__progress-item.is-done .configurator__progress-label {
    color: var(--color-charcoal);
}

.configurator__progress-link:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
    border-radius: var(--radius-sm);
}


/*------------------------------------*\
    3. STEP BODY + ACTIONS
\*------------------------------------*/

/* Continue is shut until the step's choice is made — see syncGates(). */

.configurator__next[disabled] {
    opacity: 0.45;
    cursor: not-allowed;
}

.configurator__body {
    padding-top: var(--section-y-sm);
    padding-bottom: var(--section-y-sm);
}

.configurator__intro {
    max-width: 46rem;
    margin: 0 0 var(--space-lg);
    color: var(--color-text);
}

.configurator__group-title {
    margin: 0 0 var(--space-md);
    font-size: var(--fs-h3);
    font-weight: var(--fw-regular);
    color: var(--color-heading);
}

.configurator__empty {
    padding: var(--space-lg);
    border: 1px dashed var(--color-border);
    border-radius: var(--radius-md);
    background-color: var(--color-white);
    color: var(--color-text-muted);
}

.configurator__actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-md);
    margin-top: var(--space-3xl);
}

.configurator__back {
    padding: 0;
    border: 0;
    background: none;
    font-family: inherit;
    font-size: var(--fs-sm);
    color: var(--color-text);
    cursor: pointer;
}

.configurator__back::before {
    content: "\f053";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 0.7em;
    margin-right: var(--space-xxs);
    transition: transform var(--transition);
    display: inline-block;
}

.configurator__back:hover {
    color: var(--color-red);
}

.configurator__back:hover::before {
    transform: translateX(-3px);
}

/* A step the visitor has not earned yet says so instead of failing silently */

.configurator__next[disabled] {
    opacity: 0.45;
    cursor: not-allowed;
}


/*------------------------------------*\
    4. STEP 1 — VEHICLES
\*------------------------------------*/

/*
 * Fixed 48rem tracks, left-aligned, rather than columns that share the row: one
 * vehicle should be a card, not a banner the width of the page, and adding a
 * second changes nothing about the size of the first.
 */

.configurator-vehicles {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(48rem, 100%), 59rem));
    justify-content: start;
    gap: var(--space-lg);
    margin: 0;
    padding: 0;
    list-style: none;
}

.configurator-vehicle {
    position: relative;
    display: grid;
    grid-template-columns: 18rem 1fr;
    height: 100%;
    border: 1px solid var(--color-line-beige);
    border-radius: var(--radius-md);
    background-color: var(--color-white);
    overflow: hidden;
    cursor: pointer;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.configurator-vehicle__input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.configurator-vehicle:hover {
    border-color: var(--color-grey);
}

/*
 * The selected state is a second border drawn inside, not a thicker one, so
 * choosing a card does not nudge the ones beside it.
 */

.configurator-vehicle:has(.configurator-vehicle__input:checked) {
    border-color: var(--color-red);
    box-shadow: inset 0 0 0 1px var(--color-red);
}

.configurator-vehicle:has(.configurator-vehicle__input:focus-visible) {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
}

.configurator-vehicle.is-unavailable {
    cursor: not-allowed;
    opacity: 0.55;
}

.configurator-vehicle__media {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-md);
    background-color: var(--color-sand);
}

.configurator-vehicle__media img {
    display: block;
    width: 100%;
    height: auto;
}

/* The logo standing in until a photograph of the van is uploaded. */

.configurator-vehicle__media.is-placeholder {
    aspect-ratio: 4 / 3;
    background-color: var(--color-off-white);
}

.configurator-vehicle__media.is-placeholder img {
    width: auto;
    max-width: 40%;
    max-height: 60%;
    opacity: 0.45;
}

.configurator-vehicle__body {
    display: flex;
    flex-direction: column;
    gap: var(--space-xxs);
    padding: var(--space-lg) var(--space-xl) var(--space-lg) var(--space-lg);
}

.configurator-vehicle__name {
    font-size: var(--fs-h4);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

.configurator-vehicle__price {
    font-size: var(--fs-sm);
    color: var(--color-text-muted);
}

.configurator-vehicle__text {
    margin-top: var(--space-xs);
    font-size: var(--fs-sm);
    line-height: var(--lh-body);
    color: var(--color-text);
    /* Long descriptions are trimmed rather than allowed to stretch the row. */
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.configurator-vehicle__note {
    align-self: flex-start;
    margin-top: var(--space-md);
    padding: 0.5rem 1.2rem;
    border-radius: var(--radius-sm);
    background-color: var(--color-off-white);
    font-size: var(--fs-xs);
    color: var(--color-charcoal);
}


/* The tick — shared shape with the wheelbase card */

.configurator-vehicle__check,
.configurator-wheelbase__check {
    position: absolute;
    top: var(--space-md);
    right: var(--space-md);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.8rem;
    height: 2.8rem;
    border: 1px solid var(--color-grey-light);
    border-radius: 50%;
    background-color: var(--color-white);
    transition: background-color var(--transition), border-color var(--transition);
}

.configurator-vehicle__check::before,
.configurator-wheelbase__check::before {
    content: "\f00c";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 1.2rem;
    color: var(--color-grey-light);
    transition: color var(--transition);
}

.configurator-vehicle:has(.configurator-vehicle__input:checked) .configurator-vehicle__check,
.configurator-wheelbase:has(.configurator-wheelbase__input:checked) .configurator-wheelbase__check {
    border-color: var(--color-red);
    background-color: var(--color-red);
}

.configurator-vehicle:has(.configurator-vehicle__input:checked) .configurator-vehicle__check::before,
.configurator-wheelbase:has(.configurator-wheelbase__input:checked) .configurator-wheelbase__check::before {
    color: var(--color-white);
}


/*------------------------------------*\
    5. STEP 2 — WHEELBASES
\*------------------------------------*/

.configurator-wheelbases {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(28rem, 1fr));
    gap: var(--space-lg);
    margin: 0;
    padding: 0;
    list-style: none;
}

.configurator-wheelbase {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: var(--space-lg);
    border: 1px solid var(--color-line-beige);
    border-radius: var(--radius-md);
    background-color: var(--color-white);
    cursor: pointer;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.configurator-wheelbase__input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.configurator-wheelbase:hover {
    border-color: var(--color-grey);
}

.configurator-wheelbase:has(.configurator-wheelbase__input:checked) {
    border-color: var(--color-red);
    box-shadow: inset 0 0 0 1px var(--color-red);
}

.configurator-wheelbase:has(.configurator-wheelbase__input:focus-visible) {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
}

/*
 * An unavailable wheelbase still prints — a visitor who cannot see the option
 * cannot ask us about it — but it is unmistakably out of reach.
 */

.configurator-wheelbase.is-unavailable {
    cursor: not-allowed;
    opacity: 0.5;
}

.configurator-wheelbase.is-unavailable .configurator-wheelbase__check {
    display: none;
}

.configurator-wheelbase__media {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 16rem;
    margin-bottom: var(--space-lg);
}

.configurator-wheelbase__media img {
    display: block;
    width: 100%;
    height: auto;
}

.configurator-wheelbase__body {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    gap: var(--space-sm);
}

.configurator-wheelbase__name {
    font-size: var(--fs-h4);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

/*
    The client's description, above the benefits. Spans rather than paragraphs
    because the whole card is a <label>, which may not contain block elements.
*/

.configurator-wheelbase__text {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
}

.configurator-wheelbase__paragraph {
    font-size: var(--fs-sm);
    line-height: 1.6;
    color: var(--color-text-soft);
}

.configurator-wheelbase__benefits {
    display: flex;
    flex-direction: column;
    gap: var(--space-xxs);
}

.configurator-wheelbase__benefit {
    position: relative;
    padding-left: var(--space-sm);
    font-size: var(--fs-sm);
    color: var(--color-text-soft);
}

.configurator-wheelbase__benefit::before {
    content: "\00B7";
    position: absolute;
    left: 0;
    color: var(--color-grey);
}

.configurator-wheelbase__price {
    margin-top: auto;
    padding-top: var(--space-md);
    font-size: var(--fs-sm);
    font-weight: var(--fw-medium);
    color: var(--color-accent);
}

.configurator-wheelbase__unavailable {
    margin: var(--space-xs) 0 0;
    font-size: var(--fs-xs);
    color: var(--color-text-muted);
    text-align: right;
}


/*------------------------------------*\
    6. STEPS 3-6 — SWATCHES
\*------------------------------------*/

/*
 * Both columns are left to stretch to the full row height rather than being
 * start-aligned: the preview inside the right one is sticky, and a sticky
 * element can only travel as far as its own container goes.
 */

.configurator-finish {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
    gap: clamp(2.4rem, 4vw, 6.4rem);
}

.configurator-swatches + .configurator-swatches,
.configurator-addon + .configurator-swatches {
    margin-top: var(--space-xl);
}

/*
 * An extra offered beneath a group's swatches — roof colour coding under the
 * pop top. The checkbox is the extras list's own, so it ticks the same way.
 */

.configurator-addon {
    max-width: 46rem;
    margin-top: var(--space-lg);
}

.configurator-addon + .configurator-addon {
    margin-top: var(--space-sm);
}

.configurator-addon__choose {
    display: flex;
    align-items: flex-start;
    gap: var(--space-md);
    padding: var(--space-md);
    border: 1px solid var(--color-line-beige);
    border-radius: var(--radius-sm);
    background-color: var(--color-white);
    cursor: pointer;
    transition: background-color var(--transition), border-color var(--transition);
}

.configurator-addon__choose .configurator-extra__box {
    flex: 0 0 auto;
    margin-top: 0.2rem;
}

.configurator-addon:has(.configurator-extra__input:checked) .configurator-addon__choose {
    border-color: var(--color-accent);
    background-color: rgba(167, 140, 72, 0.08);
}

.configurator-addon__body {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
    min-width: 0;
}

.configurator-addon__head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 0 var(--space-md);
}

.configurator-addon__name {
    font-size: var(--fs-sm);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

.configurator-addon__price {
    font-size: var(--fs-sm);
    font-weight: var(--fw-medium);
    white-space: nowrap;
    color: var(--color-heading);
}

.configurator-addon__text {
    font-size: var(--fs-xs);
    line-height: 1.6;
    color: var(--color-text-muted);
}

.configurator-swatches__title {
    margin: 0 0 var(--space-md);
    font-size: var(--fs-eyebrow);
    font-weight: var(--fw-semi);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--color-accent);
}

.configurator-swatches__list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(7.2rem, 1fr));
    gap: var(--space-md) var(--space-sm);
    margin: 0;
    padding: 0;
    list-style: none;
}

/*
    The chosen option's description, beneath the swatches — only the pop tops
    carry one for now. The script shows one at a time.
*/

.configurator-swatches__details {
    max-width: 46rem;
    margin-top: var(--space-lg);
}

.configurator-swatch-detail {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
    /* Text, not a card: the add-on cards beneath it are the things to tick. */
    padding-left: var(--space-md);
    border-left: 2px solid var(--color-accent);
}

.configurator-swatch-detail[hidden] {
    display: none;
}

.configurator-swatch-detail__name {
    margin: 0;
    font-size: var(--fs-sm);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

.configurator-swatch-detail__text {
    margin: 0;
    font-size: var(--fs-xs);
    line-height: 1.6;
    color: var(--color-text-muted);
}

.configurator-swatch {
    display: block;
    cursor: pointer;
    text-align: center;
}

.configurator-swatch__input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.configurator-swatch__media {
    display: block;
    aspect-ratio: 1;
    border: 1px solid var(--color-line-beige);
    border-radius: 4px;
    background-color: var(--color-grey-light);
    overflow: hidden;
    transition: box-shadow var(--transition), border-color var(--transition);
}

.configurator-swatch__media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.configurator-swatch:hover .configurator-swatch__media {
    border-color: var(--color-grey);
}

/*
    While the finish's overlay is downloading.

    The swatch itself is the thing that was clicked, so it is where the wait is
    reported — the preview is often further down the page on a narrow screen and
    a spinner there would go unseen. The tile dims and a ring turns over it.
*/

.configurator-swatches__item.is-loading .configurator-swatch__media {
    position: relative;
}

.configurator-swatches__item.is-loading .configurator-swatch__media img {
    opacity: 0.45;
    transition: opacity var(--transition);
}

/*
    A white disc under the ring. The swatches run from near-black to off-white,
    and a ring drawn straight onto the tile disappeared against the pale marbles
    and oaks — on its own disc it reads the same everywhere.
*/

.configurator-swatches__item.is-loading .configurator-swatch__media::before,
.configurator-swatches__item.is-loading .configurator-swatch__media::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    border-radius: 50%;
}

.configurator-swatches__item.is-loading .configurator-swatch__media::before {
    width: 3.2rem;
    height: 3.2rem;
    margin: -1.6rem 0 0 -1.6rem;
    background-color: var(--color-white);
    box-shadow: 0 1px 4px rgba(21, 24, 27, 0.2);
}

.configurator-swatches__item.is-loading .configurator-swatch__media::after {
    width: 1.8rem;
    height: 1.8rem;
    margin: -0.9rem 0 0 -0.9rem;
    border: 2px solid var(--color-line-beige);
    border-top-color: var(--color-red);
    animation: configurator-spin 0.7s linear infinite;
}

@keyframes configurator-spin {
    to {
        transform: rotate(360deg);
    }
}

/*
    Anyone who has asked for less movement gets the dimming but not the
    spinning — the tile still reads as busy without anything rotating.
*/

@media (prefers-reduced-motion: reduce) {
    .configurator-swatches__item.is-loading .configurator-swatch__media::after {
        animation: none;
    }
}

.configurator-swatch__input:checked + .configurator-swatch__media {
    border-color: var(--color-red);
    box-shadow: 0 0 0 2px var(--color-red);
}

.configurator-swatch__input:focus-visible + .configurator-swatch__media {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
}

.configurator-swatch__name {
    display: block;
    margin-top: var(--space-xs);
    font-size: 1.1rem;
    line-height: 1.3;
    color: var(--color-charcoal);
}

.configurator-swatch__price {
    display: block;
    font-size: 1.1rem;
    color: var(--color-accent);
}

/* A swatch with a colour but no photograph of its own. */
.configurator-swatch__colour {
    display: block;
    width: 100%;
    height: 100%;
}

/*
 * A group laid out as tabs — the two ranges of canvas colour — with the
 * chosen colour named beside the heading, since the chips are too small to
 * carry their own.
 */

.configurator-swatches[hidden] {
    display: none;
}

.configurator-swatches__head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--space-xs) var(--space-md);
    max-width: 46rem;
    margin-bottom: var(--space-md);
}

.configurator-swatches__head .configurator-swatches__title {
    margin-bottom: 0;
}

.configurator-swatches__chosen {
    font-size: var(--fs-xs);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

.configurator-tabs {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: var(--space-md);
    padding: 0.3rem;
    border-radius: var(--radius-pill);
    background-color: var(--color-grey-light);
}

.configurator-tabs__tab {
    padding: 0.6rem 1.4rem;
    border: 0;
    border-radius: var(--radius-pill);
    background: none;
    font: inherit;
    font-size: var(--fs-xs);
    font-weight: var(--fw-medium);
    color: var(--color-charcoal);
    cursor: pointer;
    transition: background-color var(--transition), box-shadow var(--transition);
}

.configurator-tabs__tab[aria-selected="true"] {
    background-color: var(--color-white);
    color: var(--color-heading);
    box-shadow: 0 1px 2px rgba(21, 24, 27, 0.12);
}

.configurator-tabs__tab:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

.configurator-tabs__count {
    margin-left: 0.3rem;
    font-weight: var(--fw-regular);
    color: var(--color-text-muted);
}

.configurator-swatches__list--chips {
    grid-template-columns: repeat(auto-fill, minmax(4rem, 1fr));
    gap: var(--space-xs);
    max-width: 46rem;
}

.configurator-swatches__list--chips[hidden] {
    display: none;
}

.configurator-swatches__list--chips .configurator-swatch__media {
    border-radius: 6px;
}

.configurator-swatches__list--chips .configurator-swatch__input:checked + .configurator-swatch__media {
    box-shadow: 0 0 0 2px var(--color-white), 0 0 0 4px var(--color-red);
}

/* Named by the heading and the hover title instead; still read out. */
.configurator-swatches__list--chips .configurator-swatch__name,
.configurator-swatches__list--chips .configurator-swatch__price {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
}


/*------------------------------------*\
    7. STEPS 3-6 — LAYERED PREVIEW
\*------------------------------------*/

.configurator-preview {
    position: sticky;
    top: calc(var(--header-height) + var(--space-md));
}

.configurator-preview__frame {
    position: relative;
    border-radius: var(--radius-md);
    background-color: var(--color-grey-light);
    overflow: hidden;
}

.configurator-preview__base {
    display: block;
    width: 100%;
    height: auto;
}

/*
 * Every layer is the same size as the photograph and painted over it in place.
 * Order is set in the markup — flooring first, trims last — so it cannot drift
 * from the order the steps are walked in.
 */

.configurator-preview__layer {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* A layer fading in reads as the material changing rather than a page flash */
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.configurator-preview__layer.is-visible {
    opacity: 1;
}

/*
 * The canvas colour: a fill cut to the pop top's canvas mask, then the mask
 * multiplied over it to put the folds and shadows back. The frame isolates
 * the blend so it only ever darkens what is inside the photograph.
 */

.configurator-preview__frame {
    isolation: isolate;
}

.configurator-preview__tint {
    display: block;
    -webkit-mask-size: 100% 100%;
    mask-size: 100% 100%;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
}

.configurator-preview__tint[hidden] {
    display: none;
}

.configurator-preview__tint-shade {
    mix-blend-mode: multiply;
}

.configurator-preview__placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: 3 / 2;
    padding: var(--space-lg);
    text-align: center;
    color: var(--color-text-muted);
}

.configurator-preview__placeholder p {
    max-width: 32rem;
    margin: 0;
    font-size: var(--fs-sm);
}

/* Small print under the preview photograph and the extras gallery. */

.configurator-disclaimer {
    margin: var(--space-xs) 0 0;
    font-size: 1.2rem;
    line-height: 1.4;
    color: var(--color-text-muted);
}

/*
 * The written list of choices is not decoration: it is the whole answer while
 * the layer artwork is still being prepared, and it stays useful afterwards for
 * anyone who cannot make out a finish from the photograph.
 */

.configurator-preview__choices {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr));
    gap: var(--space-xs) var(--space-md);
    margin: var(--space-md) 0 0;
    padding: 0;
    list-style: none;
}

.configurator-preview__choice {
    display: flex;
    flex-direction: column;
    padding-top: var(--space-xs);
    border-top: 1px solid var(--color-line-beige);
}

.configurator-preview__choice.is-active {
    border-top-color: var(--color-red);
}

.configurator-preview__choice-label {
    font-size: 1.1rem;
    font-weight: var(--fw-semi);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--color-text-muted);
}

.configurator-preview__choice.is-active .configurator-preview__choice-label {
    color: var(--color-red);
}

.configurator-preview__choice-value {
    font-size: var(--fs-sm);
    color: var(--color-heading);
}


/*------------------------------------*\
    8. STEP 7 — EXTRAS
\*------------------------------------*/

/* Stretched for the same reason as .configurator-finish — the total card sticks. */

.configurator-extras {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 32rem;
    gap: clamp(2.4rem, 3vw, 4rem);
}

.configurator-extras__group {
    margin-bottom: var(--space-lg);
    padding: var(--space-lg);
    border: 1px solid var(--color-line-beige);
    border-radius: var(--radius-md);
    background-color: var(--color-white);
}

.configurator-extras__group-title {
    margin: 0 0 var(--space-sm);
    font-size: var(--fs-eyebrow);
    font-weight: var(--fw-semi);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--color-accent);
}

.configurator-extras__list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.configurator-extra {
    display: grid;
    grid-template-columns: auto 5.6rem minmax(0, 1fr) auto auto;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-sm);
    border: 1px solid transparent;
    border-radius: var(--radius-sm);
    transition: background-color var(--transition), border-color var(--transition);
}

/* No price column while prices are switched off on the settings page. */
.configurator-extras--no-prices .configurator-extra {
    grid-template-columns: auto 5.6rem minmax(0, 1fr) auto;
}

.configurator-extra + .configurator-extra {
    margin-top: var(--space-xs);
}

.configurator-extra.is-selected {
    border-color: var(--color-accent);
    background-color: rgba(167, 140, 72, 0.08);
}

/* Rules can take an extra off the list entirely — hidden in section 1, with
   the swatches and the vehicle and wheelbase cards. */


/* Checkbox */

.configurator-extra__choose {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.configurator-extra__input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.configurator-extra__box {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border: 1px solid var(--color-grey);
    border-radius: 4px;
    background-color: var(--color-white);
    transition: background-color var(--transition), border-color var(--transition);
}

.configurator-extra__box::before {
    content: "\f00c";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 1rem;
    color: var(--color-white);
    opacity: 0;
    transition: opacity var(--transition);
}

.configurator-extra__input:checked + .configurator-extra__box {
    border-color: var(--color-accent);
    background-color: var(--color-accent);
}

.configurator-extra__input:checked + .configurator-extra__box::before {
    opacity: 1;
}

.configurator-extra__input:focus-visible + .configurator-extra__box {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
}


/* Row contents */

.configurator-extra__media {
    display: block;
    aspect-ratio: 1;
    border-radius: 4px;
    background-color: var(--color-grey-light);
    overflow: hidden;
}

.configurator-extra__media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/*
    The logo standing in for a missing photograph. Contained and inset rather
    than cropped — the badge is round, and cover would cut its lettering off —
    and paled back so a row without a picture does not shout louder than the
    rows that have one.
*/

.configurator-extra__media.is-placeholder {
    background-color: var(--color-off-white);
}

.configurator-extra__media.is-placeholder img {
    padding: 15%;
    object-fit: contain;
    opacity: 0.45;
}

/*
    The picture opens the detail panel too, so where there is one to open it is a
    button rather than a span. Stripped back to the box it replaces — a button
    brings its own border, padding and font — and given a pointer and a nudge on
    the photograph so it reads as something to press. The nudge is a transform
    rather than a fade, so it does not fight the paled-back placeholder above.
*/

.configurator-extra__media--button {
    width: 100%;
    padding: 0;
    border: 0;
    font: inherit;
    color: inherit;
    cursor: pointer;
}

.configurator-extra__media--button img {
    transition: transform var(--transition);
}

.configurator-extra__media--button:hover img,
.configurator-extra__media--button:focus-visible img {
    transform: scale(1.06);
}

.configurator-extra__media--button:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
}

.configurator-extra__body {
    display: flex;
    flex-direction: column;
}

.configurator-extra__name {
    font-size: var(--fs-sm);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

.configurator-extra__summary {
    font-size: var(--fs-xs);
    color: var(--color-text-muted);
}

.configurator-extra__price {
    font-size: var(--fs-sm);
    font-weight: var(--fw-medium);
    white-space: nowrap;
    color: var(--color-heading);
}

.configurator-extra__price-from {
    font-size: var(--fs-xs);
    font-weight: var(--fw-regular);
    color: var(--color-text-muted);
}

.configurator-extra__actions {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
}

.configurator-extra__add,
.configurator-extra__details {
    padding: 0.6rem 1.6rem;
    border: 1px solid var(--color-grey-light);
    border-radius: var(--radius-pill);
    background-color: var(--color-white);
    font-family: inherit;
    font-size: var(--fs-xs);
    white-space: nowrap;
    color: var(--color-charcoal);
    cursor: pointer;
    transition: background-color var(--transition), border-color var(--transition), color var(--transition);
}

.configurator-extra__add:hover,
.configurator-extra__details:hover {
    border-color: var(--color-charcoal);
}

/*
 * One button with both words in it, so the row does not change width when it is
 * pressed and the list stops jittering as things are added.
 */

.configurator-extra__add-done,
.configurator-extra__add[aria-pressed="true"] .configurator-extra__add-idle,
.configurator-panel__add[aria-pressed="true"] .configurator-extra__add-idle {
    display: none;
}

.configurator-extra__add[aria-pressed="true"] .configurator-extra__add-done,
.configurator-panel__add[aria-pressed="true"] .configurator-extra__add-done {
    display: inline;
}

.configurator-extra__add[aria-pressed="true"] {
    border-color: var(--color-accent);
    background-color: var(--color-accent);
    color: var(--color-white);
}


/*------------------------------------*\
    9. STEP 7 — RUNNING TOTAL
\*------------------------------------*/

.configurator-basket__inner {
    position: sticky;
    top: calc(var(--header-height) + var(--space-md));
    padding: var(--space-lg);
    border: 1px solid var(--color-line-beige);
    border-radius: var(--radius-md);
    background-color: var(--color-white);
}

.configurator-basket__title {
    margin: 0 0 var(--space-md);
    font-size: var(--fs-h4);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

.configurator-basket__lines {
    margin: 0;
    padding: 0;
    list-style: none;
    /* A long list scrolls inside the card rather than running past the fold */
    max-height: 34vh;
    overflow-y: auto;
}

.configurator-basket__line {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: baseline;
    gap: var(--space-xs);
    padding: var(--space-xs) 0;
    font-size: var(--fs-sm);
}

.configurator-basket__line-name {
    color: var(--color-text);
}

.configurator-basket__line-price {
    white-space: nowrap;
    color: var(--color-heading);
}

.configurator-basket__remove {
    width: 2rem;
    height: 2rem;
    padding: 0;
    border: 0;
    background: none;
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 1.2rem;
    line-height: 1;
    color: var(--color-grey);
    cursor: pointer;
    transition: color var(--transition);
}

.configurator-basket__remove::before {
    content: "\f00d";
}

.configurator-basket__remove:hover {
    color: var(--color-red);
}

.configurator-basket__empty {
    padding: var(--space-xs) 0;
    font-size: var(--fs-sm);
    color: var(--color-text-muted);
}

.configurator-basket__total {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--space-sm);
    margin: var(--space-md) 0 0;
    padding-top: var(--space-md);
    border-top: 1px solid var(--color-line-beige);
}

.configurator-basket__total-label {
    font-size: var(--fs-sm);
    color: var(--color-text);
}

.configurator-basket__total-value {
    font-size: var(--fs-h4);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

.configurator-basket__poa {
    margin: 0;
    font-size: var(--fs-xs);
    color: var(--color-text-muted);
}

.configurator-basket__next {
    width: 100%;
    margin-top: var(--space-md);
}

.configurator-basket__note {
    margin: var(--space-sm) 0 0;
    font-size: 1.1rem;
    line-height: 1.4;
    color: var(--color-text-muted);
}


/*------------------------------------*\
    10. DETAILS PANEL
\*------------------------------------*/

.configurator-panel {
    position: fixed;
    inset: 0;
    z-index: 1200;
}

.configurator-panel__backdrop {
    position: absolute;
    inset: 0;
    background-color: var(--color-overlay);
    opacity: 0;
    transition: opacity var(--transition);
}

.configurator-panel.is-open .configurator-panel__backdrop {
    opacity: 1;
}

.configurator-panel__sheet {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(52rem, 100%);
    padding: var(--space-lg);
    background-color: var(--color-white);
    overflow-y: auto;
    overscroll-behavior: contain;
    transform: translateX(100%);
    transition: transform var(--transition);
}

.configurator-panel.is-open .configurator-panel__sheet {
    transform: translateX(0);
}

@media (prefers-reduced-motion: reduce) {

    .configurator-panel__sheet,
    .configurator-panel__backdrop,
    .configurator-preview__layer {
        transition: none;
    }
}

.configurator-panel__close {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    margin-bottom: var(--space-md);
    padding: 0;
    border: 0;
    background: none;
    font-family: inherit;
    font-size: var(--fs-sm);
    color: var(--color-charcoal);
    cursor: pointer;
}

.configurator-panel__close::before {
    content: "\f053";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 0.75em;
}

.configurator-panel__close:hover {
    color: var(--color-red);
}

.configurator-panel__media {
    position: relative;
}

.configurator-panel__price {
    position: absolute;
    top: var(--space-sm);
    left: var(--space-sm);
    z-index: 2;
    margin: 0;
    padding: 0.4rem 1.4rem;
    border-radius: var(--radius-pill);
    background-color: var(--color-white);
    font-size: var(--fs-sm);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

.configurator-panel__title {
    margin: var(--space-lg) 0 var(--space-sm);
    font-size: var(--fs-h3);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

.configurator-panel__text {
    font-size: var(--fs-sm);
}

.configurator-panel__features {
    margin: var(--space-lg) 0;
    padding: 0;
    list-style: none;
}

.configurator-panel__feature {
    position: relative;
    padding-left: 3rem;
    margin-bottom: var(--space-xs);
    font-size: var(--fs-sm);
    color: var(--color-text);
}

.configurator-panel__feature::before {
    content: "\f00c";
    position: absolute;
    left: 0;
    top: 0.15em;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 1.8rem;
    height: 1.8rem;
    border-radius: 50%;
    background-color: var(--color-green);
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 0.9rem;
    color: var(--color-white);
}

.configurator-panel__add {
    padding: 1rem 2.4rem;
    border: 1px solid var(--color-accent);
    border-radius: var(--radius-pill);
    background-color: var(--color-accent);
    font-family: inherit;
    font-size: var(--fs-btn);
    color: var(--color-white);
    cursor: pointer;
    transition: background-color var(--transition), border-color var(--transition);
}

.configurator-panel__add:hover {
    background-color: var(--color-accent-hover);
    border-color: var(--color-accent-hover);
}


/*------------------------------------*\
    11. DETAILS PANEL — GALLERY
\*------------------------------------*/

.configurator-gallery {
    position: relative;
    border-radius: var(--radius-md);
    background-color: var(--color-grey-light);
    overflow: hidden;
}

/*
    Shown in the gallery's place when an extra has no photographs. It keeps the
    gallery's 4:3 box, which the price badge is positioned against — without it
    the media area had no height and the price printed across the title.
*/

.configurator-panel__placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: 4 / 3;
    border-radius: var(--radius-md);
    background-color: var(--color-off-white);
    overflow: hidden;
}

.configurator-panel__placeholder img {
    width: 40%;
    max-width: 16rem;
    height: auto;
    opacity: 0.45;
}

.configurator-gallery__track {
    position: relative;
    aspect-ratio: 4 / 3;
}

.configurator-gallery__slide {
    position: absolute;
    inset: 0;
    margin: 0;
    opacity: 0;
    transition: opacity var(--transition);
}

.configurator-gallery__slide.is-active {
    opacity: 1;
}

.configurator-gallery__slide img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.configurator-gallery__arrow {
    position: absolute;
    top: 50%;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3.2rem;
    height: 3.2rem;
    transform: translateY(-50%);
    border: 0;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.85);
    color: var(--color-charcoal);
    cursor: pointer;
    transition: background-color var(--transition);
}

.configurator-gallery__arrow:hover {
    background-color: var(--color-white);
}

.configurator-gallery__arrow::before {
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 1.3rem;
}

.configurator-gallery__arrow--prev {
    left: var(--space-xs);
}

.configurator-gallery__arrow--prev::before {
    content: "\f053";
}

.configurator-gallery__arrow--next {
    right: var(--space-xs);
}

.configurator-gallery__arrow--next::before {
    content: "\f054";
}

.configurator-gallery__dots {
    position: absolute;
    bottom: var(--space-sm);
    left: 0;
    right: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
}

.configurator-gallery__dot {
    width: 0.8rem;
    height: 0.8rem;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    transition: background-color var(--transition);
}

.configurator-gallery__dot.is-active {
    background-color: var(--color-white);
}


/*------------------------------------*\
    12. STEP 8 — THE FORM
\*------------------------------------*/

/*
 * The build on the left, the form on the right. The form column is the narrower
 * of the two: it is five short fields, where the review beside it is a list as
 * long as the build the visitor has just spent eleven steps making.
 */

.configurator-submit {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: clamp(2.4rem, 4vw, 6.4rem);
    align-items: start;
}

.configurator-submit__heading {
    margin: 0 0 var(--space-lg);
    font-size: var(--fs-h3);
}

/* Each list is its own card, so Extras reads as a section and not a footnote. */

.configurator-review {
    padding: var(--space-lg) var(--space-lg) var(--space-md);
    border: 1px solid var(--color-line-beige);
    border-radius: var(--radius-md);
    background-color: var(--color-white);
}

.configurator-review + .configurator-review {
    margin-top: var(--space-md);
}

.configurator-review__title {
    margin: 0 0 var(--space-sm);
    padding-bottom: var(--space-sm);
    border-bottom: 1px solid var(--color-line-beige);
    font-size: var(--fs-h4);
}

.configurator-review__list {
    margin: 0;
}

/*
 * Label and value on one line with the value against the right-hand edge, the
 * way a spec sheet reads. The label is allowed to shrink and the value is not:
 * "Vinyl - Rural Deckwood" is the answer, "Flooring" is only the question.
 */

.configurator-review__row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--space-md);
    padding: var(--space-sm) 0;
}

.configurator-review__row + .configurator-review__row {
    border-top: 1px solid var(--color-line-beige);
}

.configurator-review__label {
    flex: 0 1 auto;
    min-width: 0;
    font-size: var(--fs-sm);
    color: var(--color-text-muted);
}

.configurator-review__value {
    flex: 1 1 auto;
    margin: 0;
    font-size: var(--fs-sm);
    font-weight: var(--fw-semi);
    text-align: right;
}

/* A note is a sentence rather than a value, so it reads left to right. */

.configurator-review__list[data-review-list="notes"] .configurator-review__row {
    display: block;
}

.configurator-review__list[data-review-list="notes"] .configurator-review__value {
    margin-top: var(--space-xxs);
    font-weight: var(--fw-regular);
    text-align: left;
}

.configurator-submit__home {
    margin: var(--space-md) 0 0;
    font-size: var(--fs-sm);
    text-align: center;
}

.configurator-submit__card {
    padding: clamp(2rem, 3vw, 3.2rem);
    border: 1px solid var(--color-line-beige);
    border-radius: var(--radius-md);
    background-color: var(--color-white);
}

/*
 * Submit sits at the trailing edge, in line with the Continue button on every
 * step before it.
 *
 * The shared form styling gives the footer "grid-column: span 5", which is
 * right for the contact block — there the last row is a half-width field with
 * the button beside it. Here the last field is a full-width consent tick, so
 * the footer wraps onto a row of its own and those five columns strand the
 * button in the middle of the form. Spanning the full twelve puts it back on
 * the right-hand edge.
 *
 * Both classes are on the card so this can reach 0-5-0 and outrank the
 * .gf-styled .gform_wrapper.gravity-theme rule it is correcting.
 */

.configurator-submit__card.gf-styled .gform_wrapper.gravity-theme .gform_footer,
.configurator-submit__card.gf-styled .gform_wrapper .gform_footer,
.configurator-submit__card.gf-styled .gform_wrapper .gfield--type-submit {
    grid-column: 1 / -1;
    justify-self: stretch;
    justify-content: center;
}

/*
 * Every field runs the width of the card. The shared styling puts the short
 * ones side by side, which is right in a full-width contact block and wrong in
 * a column half that wide — a name and an email sharing 250px is worse than
 * either of them having all of it.
 */

.configurator-submit__card.gf-styled .gform_wrapper.gravity-theme .gfield,
.configurator-submit__card.gf-styled .gform_wrapper .gfield {
    grid-column: 1 / -1;
}

/* Filling the card, the way the button does on the confirmation screen. */

.configurator-submit__card.gf-styled .gform_wrapper .gform_footer input[type="submit"],
.configurator-submit__card.gf-styled .gform_wrapper .gform_footer button {
    width: 100%;
}


/*------------------------------------*\
    13. CONFIRMATION
\*------------------------------------*/

/*
 * Once the form has been replaced by the thank-you screen, the card around it
 * goes: the summary inside has its own, and a card within a card reads as two
 * separate messages.
 */

.configurator__step.is-confirmed .configurator-submit {
    display: block;
}

.configurator__step.is-confirmed .configurator-submit__card {
    max-width: none;
    padding: 0;
    border: 0;
    background-color: transparent;
}

.configurator-done {
    max-width: 93rem;
    margin: 0 auto;
    text-align: center;
}

/*
 * On its own page the card is the whole view rather than a screen replacing a
 * form, so it needs the padding the step around it used to give it.
 */

.configurator--build .configurator__body {
    padding-top: clamp(4rem, 7vw, 8rem);
    padding-bottom: clamp(4rem, 7vw, 8rem);
}

.configurator-done__saved {
    margin: var(--space-xs) 0 0;
    font-size: var(--fs-sm);
    color: var(--color-text-muted);
}

.configurator-done__tick {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 6.4rem;
    height: 6.4rem;
    margin-bottom: var(--space-lg);
    border-radius: 50%;
    background-color: var(--color-red);
}

.configurator-done__tick::before {
    content: "\f00c";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 2.4rem;
    color: var(--color-white);
}

.configurator-done__title {
    margin: 0 0 var(--space-md);
    font-size: var(--fs-h2);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

.configurator-done__text {
    margin: 0 auto var(--space-lg);
    max-width: 48rem;
    font-size: var(--fs-sm);
    color: var(--color-text);
}

.configurator-done__reference {
    display: inline-block;
    margin: 0 0 var(--space-lg);
    padding: 0.6rem 2rem;
    border: 1px solid var(--color-line-beige);
    border-radius: var(--radius-pill);
    background-color: var(--color-white);
    font-size: var(--fs-sm);
    color: var(--color-text-muted);
}

.configurator-done__reference strong {
    color: var(--color-red);
}

.configurator-done__summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(20rem, 1fr));
    gap: var(--space-lg);
    padding: var(--space-lg);
    border: 1px solid var(--color-line-beige);
    border-radius: var(--radius-md);
    background-color: var(--color-white);
    text-align: left;
}

.configurator-done__section-title {
    margin: 0 0 var(--space-xs);
    font-size: 1.1rem;
    font-weight: var(--fw-semi);
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--color-text-muted);
}

.configurator-done__section-list {
    margin: 0;
    padding: 0;
    list-style: none;
    font-size: var(--fs-sm);
    color: var(--color-heading);
}

.configurator-done__total {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--space-md);
    max-width: 100%;
    margin: var(--space-md) 0 var(--space-xl);
    padding: 0 var(--space-lg);
    text-align: left;
}

.configurator-done__poa {
    display: block;
    font-size: var(--fs-xs);
    font-weight: var(--fw-regular);
    color: var(--color-text-muted);
}

.configurator-done__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    margin: 0 0 var(--space-md);
}

.configurator-done__home {
    margin: 0;
    font-size: var(--fs-sm);
}


/*------------------------------------*\
    14. RESPONSIVE
\*------------------------------------*/

/*------------------------------------*\
    9. OWN VAN, NOTES AND THE ZOOM
\*------------------------------------*/

/*
 * The own-van card. No photograph — there is no van of ours to show — so it
 * reads as a written offer rather than a product, and sits on the off-white the
 * rest of the configurator's cards use.
 */

.configurator__group-title--own {
    margin-top: var(--space-2xl);
}

.configurator-vehicle--own {
    display: block;
    padding: var(--space-lg);
    background-color: var(--color-off-white);
}

.configurator-vehicle--own .configurator-vehicle__body {
    padding: 0;
}

.configurator-vehicle--own .configurator-vehicle__check {
    top: var(--space-md);
    right: var(--space-md);
}

/* The own-van step: a tick list of the workshop's services. */

.configurator-services {
    display: grid;
    gap: var(--space-sm);
    margin: 0;
    padding: 0;
    list-style: none;
}

.configurator-services__item {
    padding: var(--space-sm) var(--space-md);
    border: 1px solid var(--color-line-beige);
    border-radius: var(--radius-sm);
    background-color: var(--color-white);
    transition: border-color var(--transition);
}

.configurator-services__item:has(.configurator-service__input:checked) {
    border-color: var(--color-red);
    box-shadow: inset 0 0 0 1px var(--color-red);
}

.configurator-service {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 2.4rem;
    align-items: start;
    gap: var(--space-md);
    cursor: pointer;
}

.configurator-service__input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.configurator-service__body {
    display: flex;
    flex-direction: column;
    gap: var(--space-xxs);
}

.configurator-service__name {
    font-size: var(--fs-h5);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

.configurator-service__text {
    font-size: var(--fs-sm);
    line-height: var(--lh-body);
    color: var(--color-text-muted);
}

/* The tick: outlined until it is checked, then filled. */

.configurator-service__check {
    position: relative;
    width: 2.4rem;
    height: 2.4rem;
    border: 1px solid var(--color-grey-light);
    border-radius: var(--radius-sm);
    background-color: var(--color-white);
    transition: background-color var(--transition), border-color var(--transition);
}

.configurator-service__check::after {
    content: "";
    position: absolute;
    top: 0.4rem;
    left: 0.75rem;
    width: 0.6rem;
    height: 1.1rem;
    border-right: 2px solid var(--color-white);
    border-bottom: 2px solid var(--color-white);
    transform: rotate(40deg);
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.configurator-service:has(.configurator-service__input:checked) .configurator-service__check {
    border-color: var(--color-red);
    background-color: var(--color-red);
}

.configurator-service:has(.configurator-service__input:checked) .configurator-service__check::after {
    opacity: 1;
}

.configurator-service:has(.configurator-service__input:focus-visible) .configurator-service__check {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
}

.configurator-service__link {
    display: inline-block;
    margin-top: var(--space-xxs);
    font-size: var(--fs-xs);
    color: var(--color-text-muted);
}

.configurator-service__link:hover,
.configurator-service__link:focus-visible {
    color: var(--color-red);
}

/* A step's free-text box. */

.configurator-notes {
    margin-top: var(--space-xl);
    padding-top: var(--space-lg);
    border-top: 1px solid var(--color-line-beige);
}

.configurator-notes__label {
    display: block;
    margin-bottom: var(--space-xs);
    font-size: var(--fs-sm);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
}

.configurator-notes__input {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: var(--space-sm) var(--space-md);
    border: 1px solid var(--color-grey-light);
    border-radius: var(--radius-sm);
    background-color: var(--color-white);
    font-family: inherit;
    font-size: var(--fs-body);
    line-height: var(--lh-body);
    color: var(--color-text);
    resize: vertical;
}

.configurator-notes__input:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
    border-color: var(--color-grey);
}

.configurator-notes__hint {
    margin: var(--space-xxs) 0 0;
    font-size: var(--fs-xs);
    color: var(--color-text-muted);
}

/* A step with nothing for the interior photograph to show runs full width. */

.configurator-finish--wide {
    grid-template-columns: minmax(0, 1fr);
    max-width: 90rem;
}

/* The button that opens the enlarged preview. */

.configurator-preview__zoom {
    position: absolute;
    right: var(--space-sm);
    bottom: var(--space-sm);
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: var(--space-xxs);
    padding: 0.8rem 1.4rem;
    border: 0;
    border-radius: var(--radius-pill);
    background-color: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow-sm);
    font-family: inherit;
    font-size: var(--fs-xs);
    font-weight: var(--fw-medium);
    color: var(--color-heading);
    cursor: pointer;
    transition: background-color var(--transition), color var(--transition);
}

.configurator-preview__zoom:hover,
.configurator-preview__zoom:focus-visible {
    background-color: var(--color-white);
    color: var(--color-red);
}

.configurator-preview__zoom-icon {
    display: inline-flex;
}

/*
 * The enlarged preview: fixed over everything, the image fitted to the screen,
 * and one step in at twice that with the overflow dragged rather than scrolled
 * — a phone has no scrollbar to reach for.
 */

.configurator-zoom {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: flex;
    flex-direction: column;
    background-color: var(--color-overlay-strong);
}

.configurator-zoom__bar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: var(--space-sm);
    padding: var(--space-sm) var(--space-md);
}

.configurator-zoom__scale,
.configurator-zoom__close {
    border: 0;
    background: none;
    font-family: inherit;
    color: var(--color-white);
    cursor: pointer;
}

.configurator-zoom__scale {
    padding: 0.8rem 1.6rem;
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: var(--radius-pill);
    font-size: var(--fs-xs);
    font-weight: var(--fw-medium);
}

.configurator-zoom__scale:hover,
.configurator-zoom__scale:focus-visible {
    border-color: var(--color-white);
    background-color: rgba(255, 255, 255, 0.12);
}

.configurator-zoom__close {
    width: 4.4rem;
    height: 4.4rem;
    font-size: 3.2rem;
    line-height: 1;
}

.configurator-zoom__scroll {
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 var(--space-md) var(--space-xl);
    overflow: hidden;
}

.configurator-zoom__stage {
    position: relative;
    width: 100%;
    max-width: 130rem;
}

.configurator-zoom__stage .configurator-preview__frame {
    border-radius: var(--radius-md);
    overflow: hidden;
}

.configurator-zoom.is-zoomed .configurator-zoom__scroll {
    align-items: flex-start;
    justify-content: flex-start;
    overflow: auto;
    cursor: grab;
    touch-action: none;
}

.configurator-zoom.is-zoomed .configurator-zoom__scroll.is-dragging {
    cursor: grabbing;
}

.configurator-zoom.is-zoomed .configurator-zoom__stage {
    width: 200%;
    max-width: none;
}


/*------------------------------------*\
    10. THE PROGRESS ROW, NARROWER
\*------------------------------------*/

/*
 * Under 1240px eleven labels stop fitting, so only the step being looked at
 * says its name and the rest stand as numbers. The others keep their names for
 * a screen reader rather than losing them: "step 7 of 11" on its own is not
 * much of an answer to where you are.
 */

@media only screen and (max-width: 1240px) {

    .configurator__progress-label {
        position: absolute;
        width: 1px;
        height: 1px;
        margin: -1px;
        padding: 0;
        overflow: hidden;
        clip-path: inset(50%);
    }

    .configurator__progress-item.is-current .configurator__progress-label {
        position: static;
        width: auto;
        height: auto;
        margin: 0;
        overflow: visible;
        clip-path: none;
        font-size: var(--fs-xs);
    }

    .configurator__progress-item + .configurator__progress-item::before {
        width: clamp(1.2rem, 2.5vw, 4rem);
    }
}

/* Narrower again and even that one label has to go. */

@media only screen and (max-width: 680px) {

    .configurator__progress-item.is-current .configurator__progress-label {
        position: absolute;
        width: 1px;
        height: 1px;
        margin: -1px;
        overflow: hidden;
        clip-path: inset(50%);
    }
}

@media only screen and (max-width: 1140px) {

    .configurator-extras {
        grid-template-columns: minmax(0, 1fr);
    }

    /*
     * With the card no longer beside the list it becomes a bar pinned to the
     * bottom of the window, so the total stays in sight while the visitor works
     * down a long list of extras.
     */

    .configurator-basket__inner {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        top: auto;
        z-index: 900;
        border-radius: 0;
        border-width: 1px 0 0;
        box-shadow: var(--shadow-md);
    }

    .configurator-basket__title,
    .configurator-basket__note {
        display: none;
    }

    .configurator-basket__lines {
        max-height: 18vh;
    }

    .configurator__step[data-step="extras"] .configurator__actions {
        margin-bottom: 16rem;
    }
}

@media only screen and (max-width: 900px) {

    .configurator-finish,
    .configurator-submit {
        grid-template-columns: minmax(0, 1fr);
    }

    /* Preview first: the room is the point, the swatches only serve it. */

    .configurator-finish__preview {
        order: -1;
    }

    .configurator-preview {
        position: static;
    }

    /*
     * Eleven pips outgrow the container long before a phone: the row is made to
     * fit rather than scroll, because a row you have to drag sideways hides the
     * steps you have not reached — which is the half of the bar that says how
     * far there is left to go. The pips keep their size and the connectors give
     * up the slack.
     */

    .configurator__progress-list {
        width: 100%;
        gap: 0;
        margin-left: 0;
        margin-right: 0;
    }

    .configurator__progress-item {
        gap: 0;
    }

    .configurator__progress-item + .configurator__progress-item {
        flex: 1 1 auto;
        min-width: 0;
    }

    .configurator__progress-item + .configurator__progress-item::before {
        flex: 1 1 auto;
        width: auto;
        min-width: 0.4rem;
    }

    /*
     * A 28px circle is under the size of a fingertip, so the button carries
     * padding above and below it — the hit area grows, the pip looks unchanged.
     * Vertical only: eleven pips have no width to give away sideways.
     */

    .configurator__progress-link {
        flex: 0 0 auto;
        padding: 0.8rem 0;
    }
}

@media only screen and (max-width: 680px) {

    .configurator-vehicle {
        grid-template-columns: minmax(0, 1fr);
    }

    .configurator-extra,
    .configurator-extras--no-prices .configurator-extra {
        grid-template-columns: auto 4.8rem minmax(0, 1fr);
        row-gap: var(--space-xs);
    }

    .configurator-extra__price {
        grid-column: 2 / -1;
    }

    .configurator-extra__actions {
        grid-column: 2 / -1;
    }

    /*
     * Tighter again on a phone, where eleven pips and ten connectors are a
     * squeeze even with the connectors collapsed. Below about 340px the row
     * gives up and scrolls, which the scroll port above still allows.
     */

    .configurator__progress {
        margin-top: var(--space-lg);
    }

    .configurator__progress-number {
        width: 2.4rem;
        height: 2.4rem;
    }

    .configurator__progress-item + .configurator__progress-item::before {
        min-width: 0.3rem;
    }

    .configurator__actions {
        margin-top: var(--space-xl);
    }
}


/*------------------------------------*\
    15. GET ADVICE
\*------------------------------------*/

/*
 * The prompt sits beside the Continue button rather than opposite Back: it is
 * the other thing that can be done with this screen, not the way back off it.
 */

.configurator__actions-end {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

/*
 * The whole pill is the button. The red words read as the target, but a visitor
 * aiming at the sentence should not have to aim again — and the photograph is
 * the part that says a person is on the other end of it.
 */

.configurator-advice {
    display: inline-flex;
    align-items: center;
    gap: var(--space-md);
    max-width: 100%;
    padding: 0.3rem var(--space-lg) ;
    border: 1.5px solid var(--color-line-beige);
    border-radius: var(--radius-pill);
    background-color: var(--color-white);
    font-family: inherit;
    font-size: var(--fs-sm);
    line-height: var(--lh-tight);
    text-align: left;
    cursor: pointer;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.configurator-advice:hover {
    border-color: var(--color-red);
    box-shadow: var(--shadow-sm);
}

/* The photograph sits against the edge, so the pill gives up its padding for it. */

.configurator-advice--photo {
    padding-left: 0.8rem;
}

.configurator-advice__photo {
    flex: 0 0 auto;
    width: 4rem;
    height: 4rem;
    border-radius: 50%;
    object-fit: cover;
}

.configurator-advice__text {
    font-weight: var(--fw-semi);
    color: var(--color-black);
}

.configurator-advice__cta {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xxs);
    margin-left: auto;
    font-weight: var(--fw-semi);
    color: var(--color-red);
    white-space: nowrap;
}

.configurator-advice__cta::after {
    content: "\f054";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 0.7em;
    line-height: 1;
    transition: transform var(--transition);
}

.configurator-advice:hover .configurator-advice__cta::after {
    transform: translateX(3px);
}


/* The dialogue ------------------------------------------------------------ */

/*
 * Above the details panel, because it can be opened from a step that has one
 * open behind it.
 */

.configurator-advice-modal {
    position: fixed;
    inset: 0;
    z-index: 1300;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-lg);
}

.configurator-advice-modal__backdrop {
    position: absolute;
    inset: 0;
    background-color: var(--color-overlay);
    opacity: 0;
    transition: opacity var(--transition);
}

.configurator-advice-modal.is-open .configurator-advice-modal__backdrop {
    opacity: 1;
}

.configurator-advice-modal__sheet {
    position: relative;
    width: min(58rem, 100%);
    max-height: calc(100vh - var(--space-2xl));
    padding: clamp(2.4rem, 4vw, 4rem);
    border-radius: var(--radius-lg);
    background-color: var(--color-white);
    overflow-y: auto;
    overscroll-behavior: contain;
    opacity: 0;
    transform: translateY(1.2rem);
    transition: opacity var(--transition), transform var(--transition);
}

/*
 * Focus is moved here when the dialogue opens, so that screen readers announce
 * it — but it is a box rather than a control, and a ring drawn round the whole
 * sheet reads as an error state.
 */

.configurator-advice-modal__sheet:focus {
    outline: none;
}

.configurator-advice-modal.is-open .configurator-advice-modal__sheet {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {

    .configurator-advice-modal__sheet,
    .configurator-advice-modal__backdrop {
        transition: none;
    }
}

.configurator-advice-modal__close {
    position: absolute;
    top: var(--space-md);
    right: var(--space-md);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3.2rem;
    height: 3.2rem;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: none;
    font-size: 2.4rem;
    line-height: 1;
    color: var(--color-charcoal);
    cursor: pointer;
    transition: color var(--transition);
}

.configurator-advice-modal__close:hover {
    color: var(--color-red);
}

.configurator-advice-modal__title {
    margin: 0 0 var(--space-sm);
    padding-right: var(--space-xl);
    font-size: var(--fs-h3);
    text-align: center;
    font-weight: var(--fw-medium);
}

.configurator-advice-modal__intro {
    margin: 0;
    font-size: var(--fs-sm);
    color: var(--color-text-muted);
    text-align: center;
}

/* The gap above the fields belongs to the form, so it is the same with an
   introduction above it or without one. */

.configurator-advice-modal__body .gform_wrapper {
    margin-top: var(--space-lg);
}

/*
 * Three short fields in a 480px sheet. The shared form styling puts the short
 * ones side by side, which is right in a full-width contact block and wrong
 * here for the same reason it is wrong in the step 11 card.
 */

.configurator-advice-modal__body.gf-styled .gform_wrapper.gravity-theme .gfield,
.configurator-advice-modal__body.gf-styled .gform_wrapper .gfield {
    grid-column: 1 / -1;
}

.configurator-advice-modal__body.gf-styled .gform_wrapper.gravity-theme .gform_footer,
.configurator-advice-modal__body.gf-styled .gform_wrapper .gform_footer,
.configurator-advice-modal__body.gf-styled .gform_wrapper .gfield--type-submit {
    grid-column: 1 / -1;
    justify-self: stretch;
    justify-content: center;
}


/* The thank-you ----------------------------------------------------------- */

.configurator-advice-done {
    text-align: center;
}

.configurator-advice-done__title {
    margin: 0 0 var(--space-sm);
    font-size: var(--fs-h3);
}

.configurator-advice-done__text {
    margin: 0 0 var(--space-lg);
    font-size: var(--fs-sm);
    line-height: var(--lh-loose);
    color: var(--color-text-muted);
}

.configurator-advice-done__actions {
    margin: 0;
}


/* Narrower ---------------------------------------------------------------- */

@media only screen and (max-width: 700px) {

    /*
     * The sentence is too long to share a line with a button on a phone, so the
     * trailing group takes a row of its own and the pill takes all of it. Back
     * keeps the row above, where it has always been.
     */

    .configurator__actions {
        flex-wrap: wrap;
        row-gap: var(--space-md);
    }

    .configurator__actions-end {
        flex: 1 1 100%;
        flex-wrap: wrap;
        justify-content: flex-end;
    }

    .configurator-advice {
        flex: 1 1 100%;
    }
}
