/* Gratienne — the configurator: one studio below the home page's film and on its own page, from the names to the
   payment. Fieldsets under display-face legends, hairline fields, the step line 01–05 and the bill. Nothing here is washed in
   gold: a press answers with a hairline drawn under its words and ink deepening, slowly, and gold stays a line. */
.home-configurator {
    background: var(--ground);
}

/* Far less air above „Zaczyna się od Ciebie” than a block's — under the film,
   and less still on its own page, where the site's header stands above. Stronger than .block, whatever the order of the
   stylesheets. */
.home-configurator.block {
    padding-top: clamp(3rem, 6vw, 5rem);
    /* And less under it, before the page's close, never a vast gap round the farewell. */
    padding-bottom: clamp(2rem, 4vw, 3.5rem);
}

.home-configurator.block.home-configurator--page {
    padding-top: var(--page-top);
}

    .home-configurator .home-configurator__heading .display {
        margin-top: 0;
    }

.home-configurator__heading {
    max-width: 40rem;
    margin-bottom: clamp(3rem, 6vw, 6rem);
}

.home-configurator__heading .display {
    margin: 1.5rem 0;
}

.home-configurator__heading .text {
    max-width: 27rem;
}

.home-configurator__heading .home-configurator__notice {
    max-width: 32rem;
    margin-top: 1.5rem;
}

/* Two columns: the steps on the left, the book's cover on the right (.home-configurator__aside). The cover is part of
   the form — its style's radios are what the order posts, and a keyboard reaches them after step 02's counts, before
   the way on —, so the form spans both columns on the workspace's own (sub)grid: the step line and every part of the
   form in the first column, the cover in the second, beside all of them. */
.home-configurator__workspace {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
    align-items: start;
    column-gap: clamp(3rem, 7vw, 8rem);
    min-width: 0;
    scroll-margin-top: 1rem;
}

    .home-configurator__workspace > * {
        grid-column: 1;
        min-width: 0;
    }

    .home-configurator__workspace > .home-configurator__form {
        grid-column: 1 / -1;
        display: grid;
        grid-template-columns: subgrid;
        /* The step, the refusal and the way on stand on rows of their own height; the last row takes what the cover
           beside them is taller by, so the way on never drops under a gap. */
        grid-template-rows: auto auto auto 1fr;
        align-items: start;
    }

    .home-configurator__form > * {
        grid-column: 1;
        min-width: 0;
    }

.home-configurator__steps {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 3rem;
    border-bottom: 1px solid var(--rule);
}

.home-configurator__steps button {
    position: relative;
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    min-height: 3.25rem;
    padding: 0.75rem 0;
    border: 0;
    background: transparent;
    font-family: var(--sans);
    font-weight: var(--sans-weight);
    font-size: var(--caps-size);
    letter-spacing: 0.08em;
    cursor: pointer;
}

/* Upright, as every word of the house but the pair's ampersand and a signature. */
.home-configurator__step-number {
    font-family: var(--serif);
    font-size: var(--type-small);
    letter-spacing: 0;
}

.home-configurator__step-name {
    transition: opacity 0.35s var(--slow);
}

/* A step shown by its number alone is still a thumb's width to press: the target reaches past the two figures without
   moving them (::after is the step's underline). */
.home-configurator__steps button::before {
    content: '';
    position: absolute;
    inset: 0 -0.85rem;
}

.home-configurator__steps button::after {
    content: '';
    position: absolute;
    inset: auto 0 -1px;
    height: 1px;
    background: var(--ink);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.35s var(--slow);
}

.home-configurator__steps button[aria-current="step"]::after {
    transform: scaleX(1);
}

.home-configurator__steps button:disabled {
    color: var(--ink-soft);
    cursor: default;
}

.home-configurator__step {
    padding: 0;
    margin: 0;
    min-width: 0;
    border: 0;
}

/* A step is as tall as its fields: the error and the way on stand right under them, never a vast empty band above
   them. A press scrolls the new step to its top anyway. */
.home-configurator__step {
    min-height: 0;
}

.home-configurator__step legend {
    width: 100%;
    margin-bottom: 1.25rem;
    padding: 0;
    font-family: var(--display);
    font-size: var(--type-subtitle);
    line-height: 1.12;
    letter-spacing: var(--display-tracking);
    text-wrap: balance;
}

    /* The step's heading takes the focus when the step opens (configurator.js, for a reader who hears the page): never
       the browser's black box round it — a keyboard's arrival is shown in the house's gold. */
    .home-configurator__step legend:focus {
        outline: none;
    }

    .home-configurator__step legend:focus-visible {
        outline: 1px solid var(--gold);
        outline-offset: 0.4rem;
    }

    /* A step's heading is one quiet line in the display face, never a roman line with an italic one under it: the copy
       keeps its two parts, set here upright and run on. */
    .home-configurator__step legend em {
        font-style: normal;
    }

        /* The hidden break leaves no space behind, so the second part brings its own. */
        .home-configurator__step legend br + em::before {
            content: ' ';
        }

    .home-configurator__step legend br {
        display: none;
    }

.home-configurator__hint {
    max-width: 28rem;
    /* More air under each step's line before its fields. */
    margin-bottom: 3rem;
    font-size: var(--type-lede);
    line-height: 1.5;
}

.home-configurator__names {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    gap: 1rem;
    align-items: end;
}

.home-configurator__amp {
    align-self: center;
    margin-top: 1rem;
    font-family: var(--display);
    font-size: var(--type-heading);
    font-style: italic;
    /* The pair's ampersand is the house's gold, as everywhere the two names stand. */
    color: var(--gold);
}

.home-configurator__field {
    margin-bottom: 1.5rem;
    min-width: 0;
}

.home-configurator__field label,
.home-configurator__quantity > label {
    display: block;
    margin-bottom: var(--label-gap);
    font-family: var(--sans);
    font-weight: var(--sans-weight);
    font-size: var(--caps-size);
    letter-spacing: 0.05em;
}

.home-configurator__field label span {
    margin-left: 0.5rem;
    color: var(--ink-soft);
}

/* A hairline under each field; focus draws an ink line over it from the left. */
.home-configurator__field input,
.home-configurator__field select {
    display: block;
    width: 100%;
    min-width: 0;
    min-height: 2.75rem;
    padding: var(--field-air) 0 0.5rem;
    border: 0;
    border-bottom: 1px solid var(--rule);
    border-radius: 0;
    background: linear-gradient(var(--ink), var(--ink)) no-repeat left bottom / 0 1px;
    font-family: var(--serif);
    font-size: var(--type-heading);
    /* The display face's own line is tall: a tight one keeps the writing under its label, not low in the field. */
    line-height: 1.1;
    color: var(--ink);
    color-scheme: light;
    outline: none;
    transition: background-size 0.5s var(--slow);
}

.home-configurator__field input:focus-visible,
.home-configurator__field select:focus-visible {
    background-size: 100% 1px;
}

/* The choice of a country is the house's own (site.css, .choice — ui.js lays it over the select); here only the
   plain select without the script keeps the same quiet chevron. */
.home-configurator__field select {
    padding-right: 1.75rem;
    appearance: none;
    -webkit-appearance: none;
    background:
        linear-gradient(45deg, transparent 50%, var(--ink) 50%) no-repeat calc(100% - 0.7rem) 55% / 0.35rem 0.35rem,
        linear-gradient(-45deg, transparent 50%, var(--ink) 50%) no-repeat calc(100% - 0.35rem) 55% / 0.35rem 0.35rem,
        linear-gradient(var(--ink), var(--ink)) no-repeat left bottom / 0 1px;
    cursor: pointer;
}

.home-configurator__field select:focus-visible {
    background-size: 0.35rem 0.35rem, 0.35rem 0.35rem, 100% 1px;
}

/* The house's choice over the select (site.css, .choice) keeps this field's line and draws its chevron. */
.home-configurator__field .choice > input.choice__input {
    padding-right: 1.75rem;
    background: var(--choice-chevron), linear-gradient(var(--ink), var(--ink)) no-repeat left bottom / 0 1px;
    cursor: text;
}

    .home-configurator__field .choice > input.choice__input:focus-visible {
        background-size: 0.75rem 0.45rem, 100% 1px;
    }

.home-configurator__row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 0 2rem;
}

/* The payer's address after the delivery's country and whatever its customs say. */
.home-configurator__field--email {
    margin-top: 2rem;
}

/* „Które imię jest Twoje?” under the address: the two names as the house's rounds, its legend the group's question. */
.home-configurator__payer {
    margin: 2rem 0 0;
}

    .home-configurator__payer .home-configurator__checks {
        margin-top: 0;
    }

/* The day under the names, with the air of a new line of the letter between them. */
.home-configurator__quiet + .home-configurator__row {
    margin-top: 2rem;
}

.home-configurator__note {
    margin-top: 0.6rem;
    font-size: var(--type-small);
    line-height: 1.45;
    color: var(--ink-soft);
}

/* A notice is set apart by a gold hairline alone, never a tinted ground. */
.home-configurator__notice {
    padding: 0.4rem 0 0.4rem 1.1rem;
    border-left: 1px solid var(--gold);
    font-size: var(--type-body);
    line-height: 1.5;
}

.home-configurator__notice:empty {
    display: none;
}

/* The code is typed large and spaced, a size of its own outside the reading scale. */
.home-configurator__field--code input {
    max-width: 16rem;
    font-family: var(--display);
    font-size: 2.2rem;
    letter-spacing: 0.3em;
}

.home-configurator__field input::placeholder {
    color: var(--ink-soft);
    opacity: 1;
}

.home-configurator__field input:focus,
.home-configurator__field select:focus {
    border-bottom-color: var(--ink);
}

.home-configurator [aria-invalid="true"],
.home-configurator__field [aria-invalid="true"]:focus {
    border-bottom: 2px solid var(--error);
    background-color: rgba(5, 5, 5, 0.025);
}

.home-configurator__quiet {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    min-height: 2.75rem;
    padding: 0.5rem 0;
    border: 0;
    background: transparent;
    font-family: var(--sans);
    font-weight: var(--sans-weight);
    font-size: var(--caps-size);
    letter-spacing: 0.04em;
    background: linear-gradient(currentColor, currentColor) 0 calc(100% - 0.55rem) / 0 1px no-repeat;
    color: var(--ink-soft);
    cursor: pointer;
    transition: color 0.4s var(--slow), background-size 0.6s var(--slow);
}

/* A quiet press: its words deepen to ink while a hairline is drawn under them from the left. */
.home-configurator__quiet:is(:hover, :focus-visible):not(:disabled, [aria-disabled="true"]) {
    color: var(--ink);
    background-size: 100% 1px;
}

.home-configurator__quiet[aria-disabled="true"] {
    color: var(--ink-soft);
    cursor: default;
}

.home-configurator__aside {
    margin-top: 2rem;
    color: var(--ink-soft);
    font-size: var(--type-body);
    line-height: 1.5;
}

.home-configurator__quantity {
    margin: 1.5rem 0;
}

/* The count's „− 20 +” is the house's stepper (ui.js, site.css's .stepper), the card page's party the same. */

/* A form's price beside its count: one band — its price and how many it prices — for the envelope and, one flat step
   since 2026-11-19, for the case. A list with brackets would lay one band per bracket, a hairline track filling in gold
   under each (none is drawn while the case has one price). The band the last invitation stands in is set in ink, a
   band with none stays quiet. */
.home-configurator__ladder {
    margin: 0 0 2.25rem;
}

.home-configurator__ladder-label {
    margin-bottom: 0.9rem;
    font-family: var(--sans);
    font-weight: var(--sans-weight);
    font-size: var(--caps-size);
    letter-spacing: var(--caps-tracking);
    text-transform: uppercase;
    color: var(--ink-soft);
}

.home-configurator__bands {
    display: grid;
    grid-auto-columns: minmax(0, 1fr);
    grid-auto-flow: column;
    gap: 0.35rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.home-configurator__band {
    display: grid;
    gap: 0.55rem;
    min-width: 0;
    --fill: 0;
}

.home-configurator__band-price {
    font-family: var(--display);
    font-size: var(--type-heading);
    line-height: 1.2;
    font-variant-numeric: lining-nums tabular-nums;
    color: var(--ink-soft);
    white-space: nowrap;
    transition: color 0.35s var(--slow);
}

.home-configurator__band-track {
    position: relative;
    display: block;
    height: 3px;
    background: linear-gradient(var(--rule), var(--rule)) 0 50% / 100% 1px no-repeat;
}

.home-configurator__band-fill {
    position: absolute;
    inset: 0;
    background: var(--gold);
    transform: scaleX(var(--fill));
    transform-origin: left;
    transition: transform 0.5s var(--slow);
}

.home-configurator__band-count {
    font-family: var(--sans);
    font-weight: var(--sans-weight);
    font-size: var(--caps-size-small);
    letter-spacing: var(--caps-tracking);
    text-transform: uppercase;
    font-variant-numeric: tabular-nums;
    color: var(--ink-soft);
    overflow-wrap: break-word;
}

.home-configurator__band.is-current .home-configurator__band-price,
.home-configurator__band.is-current .home-configurator__band-count {
    color: var(--ink);
}

.home-configurator__band.is-ahead .home-configurator__band-price {
    color: rgba(5, 5, 5, 0.4);
}

/* The count and its ladder side by side: the stepper on the left, the brackets on the right as a
   short list — each its price and, beside it, how many of the couple's invitations it prices, its hairline filling under them
   — both labels on one line. */
.home-configurator__count-row {
    display: grid;
    grid-template-columns: minmax(0, 18rem) minmax(0, 1fr);
    gap: 1.5rem 2.5rem;
    align-items: start;
    margin: 1.5rem 0 2.25rem;
}

    .home-configurator__count-row .home-configurator__quantity,
    .home-configurator__count-row .home-configurator__ladder {
        margin: 0;
    }

    .home-configurator__count-row .home-configurator__ladder-label {
        margin-bottom: var(--label-gap);
        font-size: var(--caps-size);
        letter-spacing: 0.05em;
        text-transform: none;
        color: var(--ink);
    }

    .home-configurator__count-row .home-configurator__bands {
        grid-auto-flow: row;
        gap: 0.6rem;
    }

    .home-configurator__count-row .home-configurator__band {
        grid-template-columns: auto minmax(0, 1fr);
        align-items: baseline;
        gap: 0.2rem 0.9rem;
    }

        .home-configurator__count-row .home-configurator__band-price {
            font-size: var(--type-lede);
        }

        .home-configurator__count-row .home-configurator__band-track {
            grid-column: 1 / -1;
            grid-row: 2;
        }

/* Side by side only where the form's own column holds both (the stepper's 18rem, the gap and a ladder of words): it is
   the column, not the screen, that decides — a tablet's studio of two columns would leave the ladder a sliver, its
   words one letter per line. */
.home-configurator__step {
    container-type: inline-size;
}

    /* The container makes the step a layer of its own, which the refusal and the way on after it were drawn over, so
       an open month's or hour's sheet showed the button through it. While a sheet is open the step stands above them. */
    .home-configurator__step:has(.calendar:not([hidden])) {
        position: relative;
        z-index: 1;
    }

@container (max-width: 34rem) {
    .home-configurator__count-row {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* A group of choices — the book's cover style, whose name is theirs — under its legend in small spaced capitals. */
.home-configurator__choices {
    min-width: 0;
    margin: 0 0 1rem;
    padding: 0;
    border: 0;
}

.home-configurator__choices legend {
    display: block;
    margin-bottom: 0.9rem;
    padding: 0;
    font-family: var(--sans);
    font-weight: var(--sans-weight);
    font-size: var(--caps-size);
    letter-spacing: 0.05em;
}

/* The printed book's cover beside the steps, large and flat: the press's drawing of the chosen style for the couple
   (configurator.js's paintCover) — no model of the book (the owner's decision of 2026-11-25). Beside every step it
   stands quietly under its label, with its name and sentence; while step 02 is open (.is-choosing) the hint, the arrows
   and the row of every style's picture join it, and the style is chosen here. Held in view while the steps scroll. The
   cover is as large as the column allows while the label, the hint, the cover and its words still fit one screen under
   the header; the row of pictures may wait under them, the arrows beside the words choosing as well. Everything in it
   keeps the cover's width. Kept to the whole choice on one screen, a laptop's cover stood some 270 pixels across and
   its words could not be read (the tester's report of 2026-11-26, „napisy są kompletnie niewyraźne”). */
.home-configurator__aside {
    grid-column: 2;
    grid-row: 1 / span 4;
    position: sticky;
    top: calc(var(--header) + 1.5rem);
    --cover-size: min(100%, max(20rem, calc(100svh - var(--header) - 17rem)));
}

    .home-configurator__workspace > .home-configurator__form > .home-configurator__aside {
        grid-column: 2;
    }

.home-configurator__cover {
    margin: 0;
}

    .home-configurator__cover > * {
        width: var(--cover-size);
        max-width: 100%;
    }

.home-configurator__styles-hint {
    display: none;
    margin: -0.4rem 0 1.4rem;
}

/* The cover as the press prints it: its cut edge in --card-edge and the light --shadow-object, square as the book. */
.home-configurator__cover-card {
    display: block;
    aspect-ratio: 1;
    border: 1px solid rgba(5, 5, 5, 0.06);
    background: #F5F5F5;
    box-shadow: 2px 3px 0 var(--card-edge), var(--shadow-object);
}

    .home-configurator__cover-card > img {
        display: block;
        width: 100%;
        height: 100%;
    }

/* A style turned: the cover leaving lies over the one coming in, both held inside the card's own edge
   (configurator.js's layCover). */
.home-configurator__cover-card {
    position: relative;
    overflow: hidden;
}

    .home-configurator__cover-card > .home-configurator__cover-ghost {
        position: absolute;
        inset: 0;
        pointer-events: none;
    }

/* The chosen style's name and sentence under the cover, the arrows to the previous and the next style beside them. */
.home-configurator__chosen {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1.5rem;
    margin-top: 1.6rem;
}

.home-configurator__chosen-words {
    display: grid;
    gap: 0.35rem;
    margin: 0;
    min-width: 0;
}

.home-configurator__chosen-name {
    font-family: var(--display);
    font-weight: var(--weight-display);
    font-size: var(--type-lede);
    line-height: 1.2;
    color: var(--ink);
}

/* The chosen style's sentence. */
.home-configurator__style-chosen {
    display: block;
    font-family: var(--serif);
    font-size: var(--type-small);
    line-height: 1.5;
    color: var(--ink-soft);
}

/* The previous and the next style: two hairline squares with an arrow, the house's hairline deepening to ink under the
   pointer and a keyboard's arrival in gold. */
.home-configurator__turn {
    display: none;
    flex: none;
    gap: 0.5rem;
}

.home-configurator__turn-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    padding: 0;
    border: 1px solid var(--rule);
    background: transparent;
    color: var(--ink);
    font-family: var(--sans);
    font-weight: var(--sans-weight);
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
    transition: border-color 0.35s var(--slow);
}

    .home-configurator__turn-button:hover {
        border-color: var(--ink);
    }

    .home-configurator__turn-button:focus-visible {
        border-color: var(--ink);
        outline: 1px solid var(--gold);
        outline-offset: 0.25rem;
    }

/* Every style's picture as a small square in one row that scrolls sideways (configurator.js brings the chosen one to
   its middle): each the press's drawing of the cover for the demonstration couple. The chosen one stands on a gold
   hairline; the others wait a little paler. The radio is out of sight but takes the keyboard, its arrows walking the
   row; the whole picture answers the pointer. The row's padding keeps the keyboard's outline inside it, and its ends
   fade, so a picture cut by the edge reads as more of the row rather than as a fault. */
.home-configurator__styles {
    position: relative;
    display: none;
    grid-auto-flow: column;
    grid-auto-columns: 5.25rem;
    gap: 0.75rem;
    margin: 1.4rem -0.45rem 0;
    padding: 0.45rem 0.45rem 0.9rem;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x proximity;
    scrollbar-width: thin;
    mask-image: linear-gradient(to right, transparent, #000 1.5rem, #000 calc(100% - 1.5rem), transparent);
}

    .home-configurator__cover > .home-configurator__styles {
        width: calc(var(--cover-size) + 0.9rem);
        max-width: calc(100% + 0.9rem);
    }

.home-configurator__aside.is-choosing .home-configurator__styles-hint {
    display: block;
}

.home-configurator__aside.is-choosing .home-configurator__turn {
    display: flex;
}

.home-configurator__aside.is-choosing .home-configurator__styles {
    display: grid;
}

.home-configurator__style {
    position: relative;
    display: block;
    scroll-snap-align: center;
    cursor: pointer;
}

    .home-configurator__style input {
        position: absolute;
        opacity: 0;
        pointer-events: none;
    }

/* Every cover whole on its own white, as the press prints it: never faded to tell the chosen one apart — at 0.72 the
   page showed through the cover's paper (the owner's report of 2026-11-25, „przenika przez nią kolor tła”); the chosen
   one is told by its gold hairline and its shadow. */
.home-configurator__thumb {
    display: block;
    aspect-ratio: 1;
    background: #F5F5F5;
    box-shadow: 0 0 0 1px var(--rule);
    transition: box-shadow 0.4s var(--slow), transform 0.4s var(--slow);
}

    .home-configurator__thumb > img {
        display: block;
        width: 100%;
        height: 100%;
    }

.home-configurator__style:hover .home-configurator__thumb {
    transform: translateY(-2px);
}

.home-configurator__style:has(input:checked) .home-configurator__thumb {
    box-shadow: 0 0 0 1px var(--gold), var(--shadow-object);
}

.home-configurator__style:has(input:focus-visible) .home-configurator__thumb {
    outline: 1px solid var(--ink);
    outline-offset: 0.3rem;
}

/* The parts of the whole: what happens after the payment, and what the couple declares before it. */
.home-configurator__part {
    margin-top: 2.5rem;
    padding-top: 2rem;
    border-top: 1px solid var(--rule);
}

.home-configurator__part--first {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}

.home-configurator__subhead {
    margin-bottom: 1rem;
    font-family: var(--display);
    font-size: var(--type-heading);
    line-height: 1.2;
    letter-spacing: var(--display-tracking);
}

.home-configurator__text {
    max-width: 34rem;
    margin-bottom: 0.9rem;
    font-size: var(--type-body);
    line-height: 1.55;
}

.home-configurator__part .home-configurator__notice {
    margin-bottom: 1.5rem;
}

/* The declarations: a hairline square that fills with ink, each one a declaration of its own. */
.home-configurator__checks {
    display: grid;
    gap: 1.1rem;
    margin-top: 1.75rem;
}

    /* The shipping time and the safety notice under the declarations. */
    .home-configurator__checks + .home-configurator__fine {
        margin-top: 1.75rem;
    }

.home-configurator__check {
    display: grid;
    grid-template-columns: 1.15rem minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
    font-size: var(--type-body);
    line-height: 1.5;
    cursor: pointer;
}

/* The box itself is the house's one (site.css, „Boxes and rounds”): a fine ink square with a gold tick. */
.home-configurator__check input {
    margin: 0.2rem 0 0;
}

.home-configurator__stripe {
    margin-top: 1.5rem;
    min-height: 3rem;
}

/* What is still missing is said right under the step's last field (a field's own margin and the message's would add
   up to a gap far too large). */
.home-configurator__error {
    min-height: 1.5em;
    margin-top: 0.6rem;
}

    /* Silent, it keeps no room: an empty band between two hairlines reads as a field missing. It stays in the page for
       role="alert" to speak into. */
    .home-configurator__error:empty {
        min-height: 0;
        margin-top: 0;
    }

.home-configurator__step > .home-configurator__field:last-child,
.home-configurator__step > .home-configurator__row:last-child .home-configurator__field {
    margin-bottom: 0;
}

.home-configurator__navigation {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem 2rem;
    margin-top: 1.25rem;
    padding-top: 1.75rem;
    border-top: 1px solid var(--rule);
}

/* The way on stands at the right whether or not a way back stands beside it. */
.home-configurator__navigation > .home-configurator__primary {
    margin-left: auto;
}

/* The step's way on, in the house's hand: a hairline frame around light, spaced Montserrat capitals and an arrow drawn
   as a gold line — never a filled slab, and never a tinted wash. On the pointer's arrival a hairline is drawn under the
   words from the left, slowly, and the arrow leans the way it points. */
.home-configurator__primary {
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.75rem;
    min-height: 3.4rem;
    padding: 0.9rem 1.6rem 0.9rem 1.9rem;
    border: 1px solid var(--ink);
    border-radius: 0;
    background: transparent;
    color: var(--ink);
    font-family: var(--sans);
    font-weight: var(--sans-weight);
    font-size: var(--caps-size);
    letter-spacing: var(--caps-tracking);
    text-transform: uppercase;
    line-height: 1.4;
    cursor: pointer;
    transition: color 0.3s var(--slow), border-color 0.3s var(--slow);
}

/* The words' own hairline, in the words' colour: ink on the light buttons, the paper's white on the filled one. */
.home-configurator__primary > span:first-child {
    padding-bottom: 0.2em;
    background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
    transition: background-size 0.7s var(--slow);
}

/* A button waiting for the server is aria-disabled, not disabled, so it keeps the keyboard's focus; it looks the same. */
.home-configurator__primary:is(:hover, :focus-visible):not(:disabled, [aria-disabled="true"]) > span:first-child {
    background-size: 100% 1px;
}

/* The arrow: a thin gold line with its head, never a glyph that thickens in capitals. */
.home-configurator__primary > [aria-hidden="true"] {
    position: relative;
    display: inline-block;
    width: 1.9rem;
    height: 0.6rem;
    color: transparent;
    font-size: 0;
    transition: transform 0.45s var(--slow);
}

    .home-configurator__primary > [aria-hidden="true"]::before {
        content: '';
        position: absolute;
        inset: 50% 0 auto 0;
        height: 1px;
        background: var(--gold);
    }

    .home-configurator__primary > [aria-hidden="true"]::after {
        content: '';
        position: absolute;
        right: 0;
        top: 50%;
        width: 0.45rem;
        height: 0.45rem;
        border: solid var(--gold);
        border-width: 1px 1px 0 0;
        transform: translateY(-50%) rotate(45deg);
        transform-origin: center;
    }

.home-configurator__primary:is(:hover, :focus-visible):not(:disabled, [aria-disabled="true"]) > [aria-hidden="true"] {
    transform: translateX(0.3rem);
}

.home-configurator__primary:focus-visible {
    outline: 1px solid var(--gold);
    outline-offset: 3px;
}

.home-configurator__primary:active:not(:disabled, [aria-disabled="true"]) {
    transform: scale(0.985);
}

.home-configurator__primary:is(:disabled, [aria-disabled="true"]) {
    border-color: var(--rule);
    color: var(--ink-soft);
    cursor: not-allowed;
}

/* The press that concludes the contract carries the weight of ink: the one filled button of the studio. It stays ink
   under the pointer, answering as the others do, with the hairline under its words. */
.home-configurator__primary--final {
    background: var(--ink);
    color: var(--ground);
}

/* The way back: a quiet line of the same capitals, its arrow leaning back, underlined only while pointed at. */
.home-configurator__back {
    display: inline-flex;
    align-items: center;
    gap: 0.9rem;
    min-height: 2.75rem;
    padding: 0.5rem 0;
    border: 0;
    background: linear-gradient(currentColor, currentColor) 0 calc(100% - 0.55rem) / 0 1px no-repeat;
    color: var(--ink-soft);
    font-family: var(--sans);
    font-weight: var(--sans-weight);
    font-size: var(--caps-size);
    letter-spacing: var(--caps-tracking);
    text-transform: uppercase;
    cursor: pointer;
    transition: color 0.3s var(--slow), background-size 0.5s var(--slow);
}

    .home-configurator__back > [aria-hidden="true"] {
        display: inline-block;
        color: var(--gold);
        font-size: var(--type-small);
        letter-spacing: 0;
        transition: transform 0.45s var(--slow);
    }

.home-configurator__back:is(:hover, :focus-visible) {
    color: var(--ink);
    background-size: 100% 1px;
}

    .home-configurator__back:is(:hover, :focus-visible) > [aria-hidden="true"] {
        transform: translateX(-0.3rem);
    }

/* While the server answers, a gold hairline runs along the button's foot instead of a spinner. */
.home-configurator__primary[aria-busy="true"],
.home-configurator__quiet[aria-busy="true"] {
    position: relative;
    overflow: hidden;
    cursor: progress;
}

.home-configurator__primary[aria-busy="true"]::after,
.home-configurator__quiet[aria-busy="true"]::after {
    content: '';
    position: absolute;
    inset: auto 0 0;
    height: 1px;
    background: var(--gold);
    transform-origin: left;
    animation: studio-busy 1.2s var(--slow) infinite;
}

@keyframes studio-busy {
    from {
        transform: scaleX(0);
    }
    60% {
        transform: scaleX(1);
        opacity: 1;
    }
    to {
        transform: scaleX(1);
        opacity: 0;
    }
}

.home-configurator__bill {
    margin: 1.8rem 0;
    font-size: var(--type-lede);
}

.home-configurator__bill > div {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: baseline;
    gap: 1rem;
    padding: 0.75rem 0;
}

/* An amount is one word: never „6” over „270 zł” (the tester's report of 2026-10-28, taken as a class); the label
   beside it wraps instead. */
.home-configurator__bill dd {
    text-align: right;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.home-configurator__bill .home-configurator__bill-total {
    margin-top: 1rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--rule);
}


.home-configurator__bill-total dd {
    font-family: var(--display);
    font-size: var(--type-subtitle);
    line-height: 1.2;
}

.home-configurator__fine {
    font-size: var(--type-small);
    line-height: 1.5;
    color: var(--ink-soft);
}

/* „Zachowaj wycenę” under the studio: one quiet line until it is opened, so it never stands against the way on. */
.home-configurator__keep {
    margin-top: 1.75rem;
}

    .home-configurator__keep > summary {
        width: fit-content;
        padding: 0.6rem 0;
        font-family: var(--sans);
        font-weight: var(--sans-weight);
        font-size: var(--caps-size);
        letter-spacing: 0.04em;
        color: var(--ink-soft);
        cursor: pointer;
    }

    .home-configurator__keep form {
        display: grid;
        gap: 1.25rem;
        padding-top: 0.75rem;
    }

        .home-configurator__keep form > * {
            margin: 0;
        }

    .home-configurator__keep .home-configurator__quiet {
        justify-self: start;
    }

@media (max-width: 1099px) {
    .home-configurator__workspace {
        column-gap: 2.5rem;
    }

    .home-configurator__steps button {
        gap: 0.3rem;
    }

    .home-configurator__names {
        gap: 0.6rem;
    }
}

/* One column up to a tablet held upright: two columns there would leave the form narrower than a phone's and the cover
   small beside it. The cover then stands under step 02's counts alone, where its style is chosen, and the other steps
   go without it — a cover between every step's words and its way on would only push the way on down. */
@media (max-width: 1023px) {
    .home-configurator__workspace {
        grid-template-columns: minmax(0, 1fr);
        max-width: var(--measure);
        width: 100%;
    }

        .home-configurator__workspace > .home-configurator__form {
            grid-template-rows: none;
        }

        .home-configurator__workspace > .home-configurator__form > .home-configurator__aside {
            display: none;
            grid-column: 1;
            grid-row: auto;
            position: static;
            margin: 2.75rem 0 1rem;
            --cover-size: min(100%, 26rem);
        }

        .home-configurator__workspace > .home-configurator__form > .home-configurator__aside.is-choosing {
            display: block;
        }

    .home-configurator__heading {
        margin-bottom: 2.5rem;
    }

    .home-configurator__steps {
        margin-bottom: 2rem;
    }

    .home-configurator__step {
        min-height: 0;
    }
}

/* Five steps where the studio's column cannot hold five names in a line: the numbers stay, and only the current step
   keeps its name. */
@media (max-width: 1399px) {
    .home-configurator__steps button:not([aria-current="step"]) .home-configurator__step-name {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip-path: inset(50%);
        white-space: nowrap;
        opacity: 0;
    }
}

@media (max-width: 599px) {
    /* One field under another, each label with its own air above it — the step's last row keeps no margin of its own. */
    .home-configurator__row {
        grid-template-columns: minmax(0, 1fr);
        row-gap: 1.5rem;
    }

    /* A phone's way on: the button across the column first, „Wstecz” quiet under it — side by side they would break into two
       rows of their own. */
    .home-configurator__navigation > .home-configurator__primary {
        flex: 1 1 100%;
        order: 1;
        margin-left: 0;
    }

    .home-configurator__navigation > .home-configurator__back {
        order: 2;
    }

    .home-configurator__primary--final {
        padding-inline: 1rem;
        letter-spacing: 0.12em;
    }
}

@media (max-width: 399px) {
    .home-configurator__steps {
        gap: 0.5rem;
    }

    .home-configurator__steps button {
        letter-spacing: 0;
    }

    .home-configurator__primary {
        padding: 0.9rem 1rem;
        gap: 0.75rem;
        letter-spacing: 0.12em;
    }

    .home-configurator__band-price {
        font-size: var(--type-lede);
    }
}

@media (prefers-reduced-motion: reduce) {
    .home-configurator__steps button::after,
    .home-configurator__primary > [aria-hidden="true"],
    .home-configurator__primary,
    .home-configurator__primary > span:first-child,
    .home-configurator__quiet,
    .home-configurator__back,
    .home-configurator__back > [aria-hidden="true"],
    .home-configurator__band-fill,
    .home-configurator__band-price,
    .home-configurator__field input,
    .home-configurator__field select,
    .home-configurator__thumb,
    .home-configurator__turn-button {
        transition: none;
    }

    .home-configurator__primary[aria-busy="true"]::after,
    .home-configurator__quiet[aria-busy="true"]::after {
        animation: none;
    }
}

@media (forced-colors: active) {
    /* The chosen style's picture keeps a frame forced colours can show: its gold hairline is a shadow, which they drop. */
    .home-configurator__style:has(input:checked) .home-configurator__thumb {
        outline: 2px solid Highlight;
        outline-offset: 2px;
    }

    /* The drawn arrow and the ladder's fill are lines of colour, which forced colours would erase. */
    .home-configurator__primary > [aria-hidden="true"]::before,
    .home-configurator__band-fill {
        forced-color-adjust: none;
        background: ButtonText;
    }

    .home-configurator__primary > [aria-hidden="true"]::after {
        border-color: ButtonText;
    }
}
