#assembly-wizard {
    --ca-green: #2f641f;
    --ca-dark: #102414;
    --ca-soft: #f4f7ef;
    --ca-line: #d9e3d4;
    --ca-gold: #d6a93a;
    --ca-orange: #df6b1f;
    color: var(--ca-dark);
    font-family: Arial, sans-serif;
}

#assembly-wizard * {
    box-sizing: border-box;
}

.wizard-hero {
    background: linear-gradient(135deg, #132716 0%, #2f641f 65%, #547f2a 100%);
    border-radius: 28px;
    color: #fff;
    margin: 24px auto 30px;
    max-width: 1240px;
    overflow: hidden;
    padding: clamp(34px, 6vw, 78px);
    position: relative;
}

.wizard-hero::after {
    border: 1px solid rgba(255,255,255,.18);
    border-radius: 50%;
    content: "";
    height: 260px;
    position: absolute;
    right: -70px;
    top: -90px;
    width: 260px;
}

.wizard-eyebrow {
    color: #d9b84e;
    display: inline-block;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .14em;
    margin-bottom: 12px;
    text-transform: uppercase;
}

.wizard-hero h1 {
    color: #fff;
    font-size: clamp(42px, 7vw, 86px);
    line-height: .95;
    margin: 0 0 22px;
    max-width: 840px;
}

.wizard-hero p {
    color: rgba(255,255,255,.9);
    font-size: clamp(18px, 2vw, 24px);
    line-height: 1.45;
    margin: 0;
    max-width: 760px;
}

.wizard-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 28px;
}

.wizard-badges span,
.wizard-metrics__head span {
    background: rgba(255,255,255,.12);
    border: 1px solid rgba(255,255,255,.24);
    border-radius: 999px;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .04em;
    padding: 9px 13px;
    text-transform: uppercase;
}

.wizard-layout {
    align-items: flex-start;
    display: grid;
    gap: 28px;
    grid-template-columns: minmax(0, 1fr) 360px;
    margin: 0 auto;
    max-width: 1240px;
}

.wizard-main {
    min-width: 0;
}

.wizard-sidebar {
    position: sticky;
    top: 92px;
    z-index: 2;
}

.wizard-sidebar__inner {
    display: grid;
    gap: 14px;
}

.wizard-summary-toggle {
    background: #fff;
    border: 1px solid var(--ca-line);
    border-radius: 16px;
    color: var(--ca-green);
    display: none;
    font-weight: 800;
    padding: 14px 16px;
    width: 100%;
}

.wizard-progress {
    background: #fff;
    border: 1px solid var(--ca-line);
    border-radius: 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    list-style: none;
    margin: 0 0 18px;
    padding: 12px;
}

.wizard-progress__item {
    align-items: center;
    border-radius: 999px;
    color: #6a7665;
    cursor: default;
    display: flex;
    font-size: 13px;
    font-weight: 800;
    gap: 8px;
    padding: 8px 12px;
}

.wizard-progress__item--reachable {
    cursor: pointer;
}

.wizard-progress__number {
    align-items: center;
    background: #e7eee2;
    border-radius: 50%;
    color: var(--ca-green);
    display: inline-flex;
    height: 24px;
    justify-content: center;
    width: 24px;
}

.wizard-progress__item--active {
    background: var(--ca-green);
    color: #fff;
}

.wizard-progress__item--active .wizard-progress__number {
    background: #fff;
    color: var(--ca-green);
}

.wizard-progress__item--done:not(.wizard-progress__item--active) {
    background: #eef6e9;
    color: var(--ca-green);
}

.wizard-panel,
.wizard-architecture {
    background: #fff;
    border: 1px solid var(--ca-line);
    border-radius: 26px;
    box-shadow: 0 18px 48px rgba(21, 45, 18, .08);
    display: none;
    margin-bottom: 22px;
    padding: clamp(22px, 4vw, 38px);
}

.wizard-panel--active,
.wizard-architecture {
    display: block;
}

.wizard-panel__header {
    margin-bottom: 22px;
}

.wizard-panel__title,
.wizard-architecture h2 {
    color: var(--ca-dark);
    font-size: clamp(28px, 4vw, 46px);
    line-height: 1.04;
    margin: 0 0 12px;
}

.wizard-panel__header p,
.wizard-architecture p,
.wizard-contact-panel p {
    color: #5f6f5b;
    font-size: 16px;
    line-height: 1.55;
    margin: 0;
}

.product-options {
    display: grid;
    gap: 18px;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}

.product-option {
    background: #fbfcf8;
    border: 2px solid #e0ead9;
    border-radius: 22px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    min-height: 100%;
    padding: 18px;
    transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.product-option:hover {
    border-color: #8cad6f;
    box-shadow: 0 16px 36px rgba(35, 68, 28, .14);
    transform: translateY(-2px);
}

.product-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.product-option:has(input[type="radio"]:checked) {
    background: #f0f7ea;
    border-color: var(--ca-green);
    box-shadow: 0 18px 42px rgba(47, 100, 31, .18);
}

.product-option__media {
    align-items: center;
    background: #eef4e9;
    border-radius: 18px;
    display: flex;
    height: 180px;
    justify-content: center;
    margin-bottom: 16px;
}

.product-option img {
    height: 150px;
    max-width: 100%;
    object-fit: contain;
    width: 150px;
}

.product-option__name {
    color: var(--ca-dark);
    font-size: 18px;
    font-weight: 800;
    line-height: 1.25;
}

.product-option__features {
    color: #667461;
    list-style: none;
    margin: 12px 0 0;
    padding: 0;
}

.product-option__features li {
    font-size: 13px;
    line-height: 1.45;
    padding: 4px 0 4px 18px;
    position: relative;
}

.product-option__features li::before {
    color: var(--ca-green);
    content: "✓";
    font-weight: 800;
    left: 0;
    position: absolute;
}

.wizard-form-grid {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.wizard-form-grid label,
.wizard-consent {
    color: var(--ca-dark);
    display: flex;
    flex-direction: column;
    font-size: 14px;
    font-weight: 800;
    gap: 8px;
}

.wizard-form-grid input,
.wizard-form-grid select {
    background: #fbfcf8;
    border: 1px solid #cbd8c5;
    border-radius: 14px;
    color: var(--ca-dark);
    font-size: 16px;
    min-height: 48px;
    padding: 12px 14px;
    width: 100%;
}

.wizard-field--readonly {
    background: #eef2ea;
    color: #667461;
    cursor: not-allowed;
}

.wizard-contact-panel {
    background: var(--ca-soft);
    border: 1px solid var(--ca-line);
    border-radius: 22px;
    margin-top: 24px;
    padding: 22px;
}

.wizard-contact-panel h3 {
    color: var(--ca-dark);
    font-size: 24px;
    margin: 0 0 8px;
}

.wizard-contact-panel .wizard-form-grid {
    margin-top: 18px;
}

.wizard-consent {
    align-items: flex-start;
    flex-direction: row;
    font-weight: 600;
    line-height: 1.45;
    margin-top: 16px;
}

.wizard-consent input {
    margin-top: 3px;
}

.wizard-architecture {
    display: block;
}

.wizard-energy-flow {
    background: #f5f6f3;
    border-radius: 22px;
    color: var(--ca-dark);
    display: grid;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    gap: 8px;
    justify-items: center;
    margin-top: 22px;
    padding: 24px;
    text-align: center;
}

.wizard-energy-flow span,
.wizard-energy-split b {
    background: #fff;
    border: 1px solid #dce5d6;
    border-radius: 14px;
    padding: 10px 14px;
}

.wizard-energy-flow i {
    color: var(--ca-green);
    font-style: normal;
    font-weight: 900;
}

.wizard-energy-split {
    display: grid;
    gap: 14px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 8px;
    width: min(520px, 100%);
}

.wizard-energy-split small {
    color: #687663;
    font-family: Arial, sans-serif;
    font-weight: 600;
}

.wizard-summary,
.wizard-metrics,
.wizard-nav {
    background: #fff;
    border: 1px solid var(--ca-line);
    border-radius: 22px;
    box-shadow: 0 16px 44px rgba(21, 45, 18, .08);
    padding: 18px;
}

.wizard-summary h3 {
    color: var(--ca-dark);
    font-size: 20px;
    margin: 0 0 12px;
}

#assembly-summary {
    list-style: none;
    margin: 0;
    padding: 0;
}

#assembly-summary li {
    border-top: 1px solid #eef2ea;
    display: grid;
    gap: 4px;
    padding: 10px 0;
}

#assembly-summary li:first-child {
    border-top: 0;
}

#assembly-summary strong {
    color: #60715c;
    font-size: 12px;
    text-transform: uppercase;
}

#assembly-summary span {
    color: var(--ca-dark);
    font-weight: 800;
}

.wizard-summary__empty {
    color: #788373;
}

.wizard-metrics {
    background: linear-gradient(180deg, #153019 0%, #2f641f 100%);
    color: #fff;
}

.wizard-metrics__head {
    display: grid;
    gap: 8px;
    margin-bottom: 14px;
}

.wizard-metrics__head small {
    color: rgba(255,255,255,.76);
    line-height: 1.4;
}

.wizard-metric {
    align-items: center;
    border-top: 1px solid rgba(255,255,255,.14);
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
}

.wizard-metric span {
    color: rgba(255,255,255,.82);
    font-size: 13px;
}

.wizard-metric strong {
    color: #fff;
    font-size: 21px;
}

.wizard-nav {
    display: grid;
    gap: 10px;
}

.wizard-nav button {
    border: 0;
    border-radius: 14px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 900;
    min-height: 48px;
    padding: 12px 14px;
    transition: opacity .18s ease, transform .18s ease;
    width: 100%;
}

.wizard-nav button:hover:not(:disabled) {
    transform: translateY(-1px);
}

.wizard-nav button:disabled {
    cursor: not-allowed;
    opacity: .45;
}

.wizard-nav__back {
    background: #eef2ea;
    color: var(--ca-dark);
}

.wizard-nav__next {
    background: var(--ca-green);
    color: #fff;
}

.wizard-nav__login {
    background: #fff6df;
    color: #81550d;
}

.wizard-nav__submit {
    background: var(--ca-orange);
    color: #fff;
    display: none;
}

@media (max-width: 980px) {
    .wizard-layout {
        grid-template-columns: 1fr;
    }

    .wizard-sidebar {
        bottom: 0;
        position: sticky;
        top: auto;
    }

    .wizard-summary-toggle {
        display: block;
    }

    .wizard-sidebar__inner {
        background: rgba(244,247,239,.94);
        border: 1px solid var(--ca-line);
        border-radius: 22px 22px 0 0;
        max-height: 70vh;
        overflow: auto;
        padding: 10px;
    }

    .wizard-form-grid,
    .wizard-energy-split {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 620px) {
    .wizard-hero {
        border-radius: 0 0 24px 24px;
        margin-left: -15px;
        margin-right: -15px;
    }

    .wizard-progress {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 14px;
    }

    .wizard-progress__item {
        flex: 0 0 auto;
    }

    .product-options {
        grid-template-columns: 1fr;
    }

    .wizard-panel,
    .wizard-architecture {
        border-radius: 20px;
        padding: 20px;
    }
}

/* Focused configurator flow: one full-width stage + persistent action dock */
body.assemblywizard-index-index .page-main,
body.assemblywizard-index-index .columns,
body.assemblywizard-index-index .column.main {
    max-width: none;
    padding-left: 0;
    padding-right: 0;
    width: 100%;
}

body.assemblywizard-index-index .page-title-wrapper {
    display: none;
}

#assembly-wizard {
    padding: 0 clamp(16px, 3vw, 56px) 245px;
    width: 100%;
}

.wizard-layout {
    display: block;
    margin: 0;
    max-width: none;
    width: 100%;
}

.wizard-main {
    margin: 0 auto;
    max-width: 1560px;
    width: 100%;
}

.wizard-progress {
    border-radius: 0 0 22px 22px;
    box-shadow: 0 14px 34px rgba(16, 36, 20, .08);
    margin: 0 0 22px;
    position: sticky;
    top: 76px;
    z-index: 15;
}

.wizard-panel {
    min-height: min(760px, calc(100vh - 260px));
}

.wizard-panel--intro {
    background: transparent;
    border: 0;
    box-shadow: none;
    padding: 0;
}

.wizard-hero {
    margin: 0 0 22px;
    max-width: none;
    min-height: clamp(420px, 58vh, 680px);
    padding: clamp(36px, 7vw, 96px);
}

.wizard-hero__cta {
    background: #fff;
    border: 0;
    border-radius: 16px;
    color: var(--ca-green);
    cursor: pointer;
    font-size: 17px;
    font-weight: 900;
    margin-top: 30px;
    min-height: 54px;
    padding: 15px 22px;
    position: relative;
    z-index: 1;
}

.wizard-preflight {
    display: grid;
    gap: 18px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin: 0 0 22px;
}

.wizard-preflight article {
    background: #fff;
    border: 1px solid var(--ca-line);
    border-radius: 22px;
    box-shadow: 0 14px 34px rgba(21, 45, 18, .06);
    padding: 22px;
}

.wizard-preflight strong {
    align-items: center;
    background: #eef6e9;
    border-radius: 50%;
    color: var(--ca-green);
    display: inline-flex;
    height: 34px;
    justify-content: center;
    margin-bottom: 12px;
    width: 34px;
}

.wizard-preflight h2 {
    color: var(--ca-dark);
    font-size: 20px;
    margin: 0 0 8px;
}

.wizard-preflight p {
    color: #61705d;
    line-height: 1.5;
    margin: 0;
}

.wizard-architecture--intro {
    margin-bottom: 0;
}

.product-options {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.product-option__media {
    height: clamp(180px, 22vw, 260px);
}

.product-option img {
    height: min(210px, 80%);
    width: min(210px, 80%);
}

.wizard-sidebar {
    background: rgba(244, 247, 239, .97);
    border-top: 1px solid var(--ca-line);
    bottom: 0;
    box-shadow: 0 -18px 44px rgba(16, 36, 20, .14);
    left: 0;
    padding: 10px clamp(12px, 2.5vw, 34px) 12px;
    position: fixed;
    right: 0;
    top: auto;
    z-index: 60;
}

.wizard-summary-toggle {
    background: transparent;
    border: 0;
    border-radius: 0;
    color: var(--ca-green);
    display: block;
    font-size: 13px;
    margin: 0 auto 8px;
    max-width: 1560px;
    min-height: 26px;
    padding: 0;
    text-align: left;
}

.wizard-summary-toggle::after {
    content: "⌃";
    float: right;
}

.wizard-summary-toggle[aria-expanded="false"]::after {
    content: "⌄";
}

.wizard-sidebar__inner {
    align-items: stretch;
    display: grid;
    gap: 12px;
    grid-template-columns: minmax(0, 1fr) minmax(360px, 430px);
    margin: 0 auto;
    max-width: 1560px;
    max-height: none;
    overflow: visible;
    padding: 0;
}

.wizard-dock__details {
    display: grid;
    gap: 12px;
    grid-template-columns: minmax(240px, .8fr) minmax(420px, 1.2fr);
}

.wizard-summary,
.wizard-metrics,
.wizard-nav {
    border-radius: 18px;
    box-shadow: none;
    padding: 14px;
}

.wizard-summary h3 {
    font-size: 16px;
    margin-bottom: 6px;
}

#assembly-summary {
    max-height: 96px;
    overflow: auto;
}

#assembly-summary li {
    padding: 6px 0;
}

.wizard-metrics {
    align-items: center;
    display: grid;
    gap: 10px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.wizard-metrics__head {
    grid-column: 1 / -1;
    margin-bottom: 0;
}

.wizard-metrics__head small {
    font-size: 12px;
}

.wizard-metric {
    border-top: 1px solid rgba(255,255,255,.13);
    display: grid;
    gap: 4px;
    padding: 8px 0 0;
}

.wizard-metric strong {
    font-size: clamp(17px, 1.4vw, 22px);
}

.wizard-nav {
    align-content: center;
    display: grid;
    gap: 10px;
    grid-template-columns: 1fr 1.35fr;
}

.wizard-nav__login,
.wizard-nav__submit {
    grid-column: 1 / -1;
}

.wizard-nav button {
    min-height: 46px;
}

@media (max-width: 1180px) {
    #assembly-wizard {
        padding-bottom: 300px;
    }

    .wizard-sidebar__inner,
    .wizard-dock__details {
        grid-template-columns: 1fr;
    }

    .wizard-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .wizard-summary {
        display: none;
    }
}

@media (max-width: 760px) {
    #assembly-wizard {
        padding: 0 12px 320px;
    }

    .wizard-progress {
        top: 68px;
    }

    .wizard-hero {
        border-radius: 22px;
        margin-left: 0;
        margin-right: 0;
        min-height: auto;
        padding: 32px 24px;
    }

    .wizard-preflight {
        grid-template-columns: 1fr;
    }

    .wizard-panel {
        min-height: auto;
    }

    .wizard-metrics {
        grid-template-columns: 1fr 1fr;
    }

    .wizard-metrics__head {
        display: none;
    }
}

@media (max-width: 520px) {
    #assembly-wizard {
        padding-bottom: 345px;
    }

    .wizard-sidebar {
        padding-left: 8px;
        padding-right: 8px;
    }

    .wizard-sidebar__inner {
        gap: 8px;
    }

    .wizard-nav {
        grid-template-columns: 1fr 1fr;
    }

    .wizard-nav button {
        font-size: 14px;
        min-height: 44px;
        padding: 10px;
    }
}

/*
 * Desktop split view: progress + step content on the right, project
 * summary on the left, sized to fit one screen. Scoped to large viewports
 * only (min-width: 1281px, just above the existing 1180px breakpoint used
 * by the bottom-dock layout) so phones/tablets keep the sticky-top +
 * bottom-dock behavior above untouched.
 *
 * "Fits without scrolling" applies to the shell itself: #assembly-wizard
 * is sized to the space below the site header (measured in JS into
 * --site-header-h, see wizard.phtml) and never forces overflow:hidden, so
 * if one step's own content is unusually tall it scrolls locally inside
 * that step instead of breaking the page.
 */
@media (min-width: 1281px) {
    #assembly-wizard {
        min-height: calc(100dvh - var(--site-header-h, 132px));
        padding-bottom: 24px;
        padding-top: 20px;
    }

    .wizard-layout {
        display: grid;
        gap: 26px;
        grid-template-areas: "sidebar main";
        grid-template-columns: minmax(320px, 400px) minmax(0, 1fr);
        max-width: 1720px;
    }

    .wizard-main {
        display: flex;
        flex-direction: column;
        grid-area: main;
        height: 100%;
        max-width: none;
        min-height: 0;
    }

    .wizard-progress {
        flex-shrink: 0;
        position: static;
    }

    #assembly-form {
        display: flex;
        flex: 1;
        flex-direction: column;
        min-height: 0;
    }

    .wizard-panel {
        min-height: 0;
        overflow-y: auto;
    }

    .wizard-panel--active {
        flex: 1;
    }

    .wizard-sidebar {
        background: transparent;
        border: 0;
        box-shadow: none;
        display: flex;
        flex-direction: column;
        grid-area: sidebar;
        height: 100%;
        left: auto;
        padding: 0;
        position: static;
        right: auto;
    }

    .wizard-summary-toggle {
        display: none;
    }

    .wizard-sidebar__inner {
        display: flex;
        flex-direction: column;
        height: 100%;
        max-width: none;
        overflow-y: auto;
    }

    .wizard-dock__details {
        display: flex;
        flex-direction: column;
        grid-template-columns: none;
    }

    .wizard-summary {
        display: block;
    }

    #assembly-summary {
        max-height: none;
    }

    .wizard-metrics {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .wizard-nav {
        flex-shrink: 0;
        grid-template-columns: 1fr;
        margin-top: 12px;
    }

    .wizard-nav__login,
    .wizard-nav__submit {
        grid-column: auto;
    }
}
