/* v10 frontend realism + wheel scroll stability */
#asg-configuratore-wrapper .asg-viewer-col {
    isolation: isolate;
}
#asg-configuratore-wrapper .asg-viewer-controls {
    left: 50%;
    transform: translateX(0);
    justify-content: center;
    margin-inline: auto;
}
#asg-configuratore-wrapper .asg-viewer-controls .btn,
#asg-configuratore-wrapper .asg-viewer-controls .btn-sm {
    min-width: 122px;
    justify-content: center;
}


/* ==========================================================================
   ASG V11 FRONTEND RECOVERY
   Focus: crisp external XYZ gizmo, centered toolbar, no viewer wheel hijack.
   ========================================================================== */
#asg-configuratore-wrapper .asg-gizmo-overlay {
    position: absolute;
    left: 18px;
    bottom: 18px;
    z-index: 18;
    pointer-events: none;
    user-select: none;
    filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.28));
}

#asg-configuratore-wrapper .asg-gizmo-overlay canvas {
    display: block;
    width: 100%;
    height: 100%;
    background: transparent;
}

#asg-configuratore-wrapper .asg-viewer-controls {
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    margin: 0;
    justify-content: center;
}

#asg-configuratore-wrapper .asg-viewer-controls .btn,
#asg-configuratore-wrapper .asg-viewer-controls .btn-sm {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 126px;
    text-align: center;
}

@media (max-width: 767px) {
    #asg-configuratore-wrapper .asg-gizmo-overlay {
        top: 16px;
        right: 16px;
        left: auto;
        bottom: auto;
    }

    #asg-configuratore-wrapper .asg-viewer-top-info {
        max-width: calc(100% - 132px);
    }

    #asg-configuratore-wrapper .asg-viewer-controls {
        width: min(328px, calc(100% - 24px));
        max-width: calc(100% - 24px);
        left: 50%;
        transform: translateX(-50%);
        justify-items: center;
        align-items: center;
    }

    #asg-configuratore-wrapper .asg-viewer-controls .btn,
    #asg-configuratore-wrapper .asg-viewer-controls .btn-sm {
        width: 100%;
        min-width: 0;
    }
}


/* ========================================================================== 
   ASG V12 FRONTEND FIX
   Focus: empty viewer before model selection, true external XYZ, centered toolbar.
   ========================================================================== */
#asg-configuratore-wrapper .asg-state-models .asg-gizmo-overlay {
    opacity: 0;
    visibility: hidden;
}

#asg-configuratore-wrapper .asg-state-models #asg-3d-canvas {
    background: radial-gradient(circle at 50% 42%, rgba(17,32,54,0.42), rgba(4,9,18,0.94) 62%, rgba(2,5,10,1) 100%);
}

#asg-configuratore-wrapper .asg-viewer-controls {
    width: fit-content;
    max-width: calc(100% - 32px);
    gap: 12px;
}

#asg-configuratore-wrapper .asg-viewer-controls .btn,
#asg-configuratore-wrapper .asg-viewer-controls .btn-sm {
    min-width: 128px;
}

#asg-configuratore-wrapper .asg-gizmo-overlay {
    width: 148px;
    height: 148px;
}

@media (max-width: 767px) {
    #asg-configuratore-wrapper .asg-gizmo-overlay {
        width: 92px;
        height: 92px;
        top: 14px;
        right: 14px;
        left: auto;
        bottom: auto;
    }

    #asg-configuratore-wrapper .asg-viewer-controls {
        width: min(330px, calc(100% - 24px));
        max-width: calc(100% - 24px);
        margin-inline: auto;
    }
}

/* ========================================================================== 
   ASG V13 FRONTEND HOTFIX
   Focus: viewer zoom preserved, configurator panel wheel scroll, visible furniture,
   stable axis gizmo colors, centered viewer actions.
   ========================================================================== */
#asg-configuratore-wrapper .asg-viewer-controls {
    position: absolute;
    left: 50%;
    right: auto;
    bottom: 18px;
    transform: translateX(-50%);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: max-content;
    max-width: calc(100% - 28px);
    margin: 0;
    padding: 10px;
}

#asg-configuratore-wrapper .asg-viewer-controls .btn,
#asg-configuratore-wrapper .asg-viewer-controls .btn-sm {
    min-width: 132px;
    justify-content: center;
    text-align: center;
}

#asg-configuratore-wrapper .asg-gizmo-overlay {
    width: 168px;
    height: 168px;
    left: 16px;
    bottom: 16px;
    top: auto;
    right: auto;
}

#asg-configuratore-wrapper .asg-gizmo-overlay canvas {
    image-rendering: auto;
}

#asg-configuratore-wrapper #step-2-view {
    overflow: hidden;
}

#asg-configuratore-wrapper #step-2-view .asg-controls-body {
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
}

@media (max-width: 767px) {
    #asg-configuratore-wrapper .asg-viewer-controls {
        width: min(340px, calc(100% - 24px));
        max-width: calc(100% - 24px);
        bottom: 12px;
    }

    #asg-configuratore-wrapper .asg-viewer-controls .btn,
    #asg-configuratore-wrapper .asg-viewer-controls .btn-sm {
        min-width: 0;
        flex: 1 1 0;
    }

    #asg-configuratore-wrapper .asg-gizmo-overlay {
        width: 96px;
        height: 96px;
        top: 14px;
        right: 14px;
        left: auto;
        bottom: auto;
    }
}

/* ========================================================================== 
   ASG V16 FRONTEND UX POLISH
   Focus: smart furniture spacing, true wheel scroll in configurator panel,
   sticky live controls + live price that release at section end.
   ========================================================================== */
@media (min-width: 1181px) {
    #asg-configuratore-wrapper .asg-grid,
    #asg-configuratore-wrapper .asg-viewer-col,
    #asg-configuratore-wrapper .asg-controls-col,
    #asg-configuratore-wrapper #step-2-view {
        contain: none;
    }

    #asg-configuratore-wrapper.asg-state-configurator .asg-grid,
    #asg-configuratore-wrapper .asg-state-configurator .asg-grid,
    #asg-configuratore-wrapper.asg-state-configurator .asg-grid {
        align-items: start;
    }

    #asg-configuratore-wrapper .asg-state-configurator .asg-viewer-col,
    #asg-configuratore-wrapper .asg-state-configurator .asg-controls-col,
    #asg-configuratore-wrapper.asg-state-configurator .asg-viewer-col,
    #asg-configuratore-wrapper.asg-state-configurator .asg-controls-col {
        position: sticky;
        top: 86px;
        align-self: start;
        height: calc(100vh - 104px);
        max-height: calc(100vh - 104px);
    }

    #asg-configuratore-wrapper .asg-state-configurator .asg-viewer-col,
    #asg-configuratore-wrapper.asg-state-configurator .asg-viewer-col {
        min-height: calc(100vh - 104px);
    }

    #asg-configuratore-wrapper .asg-state-configurator .asg-controls-col,
    #asg-configuratore-wrapper.asg-state-configurator .asg-controls-col {
        overflow: hidden;
    }

    #asg-configuratore-wrapper .asg-state-configurator #step-2-view,
    #asg-configuratore-wrapper.asg-state-configurator #step-2-view {
        display: grid;
        grid-template-rows: auto minmax(0, 1fr) auto;
        min-height: 100%;
        height: 100%;
        overflow: hidden;
    }

    #asg-configuratore-wrapper .asg-state-configurator #step-2-view .asg-controls-body,
    #asg-configuratore-wrapper.asg-state-configurator #step-2-view .asg-controls-body {
        min-height: 0;
        height: 100%;
        overflow-y: auto;
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 156px;
        scrollbar-width: thin;
    }

    #asg-configuratore-wrapper .asg-state-configurator #step-2-view .asg-controls-footer,
    #asg-configuratore-wrapper.asg-state-configurator #step-2-view .asg-controls-footer {
        position: sticky;
        bottom: 0;
        z-index: 6;
        margin-top: 0;
        background: linear-gradient(180deg, rgba(6,11,20,0.78) 0%, rgba(8,13,23,0.96) 18%, rgba(8,13,23,0.99) 100%);
        backdrop-filter: blur(18px);
        -webkit-backdrop-filter: blur(18px);
        box-shadow: 0 -12px 30px rgba(0,0,0,0.28);
    }
}

#asg-configuratore-wrapper .asg-viewer-controls {
    z-index: 20;
}

#asg-configuratore-wrapper .asg-controls-footer .price-box {
    transition: transform .24s ease, box-shadow .24s ease;
}

#asg-configuratore-wrapper .asg-state-configurator .asg-controls-footer .price-box,
#asg-configuratore-wrapper.asg-state-configurator .asg-controls-footer .price-box {
    box-shadow: 0 16px 34px rgba(0,0,0,0.22);
}

@media (max-width: 1180px) {
    #asg-configuratore-wrapper .asg-controls-col,
    #asg-configuratore-wrapper .asg-viewer-col,
    #asg-configuratore-wrapper #step-2-view,
    #asg-configuratore-wrapper #step-2-view .asg-controls-body,
    #asg-configuratore-wrapper #step-2-view .asg-controls-footer {
        position: relative;
        top: auto;
        height: auto;
        max-height: none;
    }

    #asg-configuratore-wrapper #step-2-view .asg-controls-body {
        overflow: visible;
        padding-bottom: 24px;
    }
}

/* ========================================================================== 
   ASG V17 FRONTEND STABILITY ROLLBACK
   Focus: remove overlapping sticky panel, restore page scroll on desktop,
   keep viewer toolbar centered and let the page handle wheel scrolling.
   ========================================================================== */
@media (min-width: 1181px) {
    #asg-configuratore-wrapper.asg-state-configurator .asg-grid,
    #asg-configuratore-wrapper .asg-state-configurator .asg-grid {
        align-items: stretch;
    }

    #asg-configuratore-wrapper.asg-state-configurator .asg-viewer-col,
    #asg-configuratore-wrapper.asg-state-configurator .asg-controls-col,
    #asg-configuratore-wrapper .asg-state-configurator .asg-viewer-col,
    #asg-configuratore-wrapper .asg-state-configurator .asg-controls-col,
    #asg-configuratore-wrapper.asg-state-configurator #step-2-view,
    #asg-configuratore-wrapper .asg-state-configurator #step-2-view,
    #asg-configuratore-wrapper.asg-state-configurator #step-2-view .asg-controls-body,
    #asg-configuratore-wrapper .asg-state-configurator #step-2-view .asg-controls-body,
    #asg-configuratore-wrapper.asg-state-configurator #step-2-view .asg-controls-footer,
    #asg-configuratore-wrapper .asg-state-configurator #step-2-view .asg-controls-footer {
        position: relative;
        top: auto;
        bottom: auto;
        height: auto;
        max-height: none;
        overflow: visible;
    }

    #asg-configuratore-wrapper.asg-state-configurator .asg-controls-col,
    #asg-configuratore-wrapper .asg-state-configurator .asg-controls-col {
        align-self: stretch;
    }

    #asg-configuratore-wrapper.asg-state-configurator #step-2-view,
    #asg-configuratore-wrapper .asg-state-configurator #step-2-view {
        display: flex;
        min-height: 100%;
    }

    #asg-configuratore-wrapper.asg-state-configurator #step-2-view .asg-controls-body,
    #asg-configuratore-wrapper .asg-state-configurator #step-2-view .asg-controls-body {
        padding-bottom: 28px;
    }

    #asg-configuratore-wrapper.asg-state-configurator #step-2-view .asg-controls-footer,
    #asg-configuratore-wrapper .asg-state-configurator #step-2-view .asg-controls-footer {
        margin-top: 0;
        box-shadow: 0 -10px 24px rgba(0,0,0,0.18);
        background: rgba(0,0,0,0.3);
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }
}

#asg-configuratore-wrapper .asg-viewer-controls {
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    min-width: max-content;
}


/* ==========================================================================
   ASG V19 FRONTEND FINISH
   Focus: full-page model selection, image-ready cards, smart sticky docks,
   page scroll behavior restored, tighter mobile popup.
   ========================================================================== */
#asg-configuratore-wrapper.asg-state-models .asg-grid,
#asg-configuratore-wrapper .asg-state-models .asg-grid {
    grid-template-columns: 1fr;
    gap: 0;
}

#asg-configuratore-wrapper.asg-state-models .asg-viewer-col,
#asg-configuratore-wrapper .asg-state-models .asg-viewer-col {
    display: none;
}

#asg-configuratore-wrapper.asg-state-models .asg-controls-col,
#asg-configuratore-wrapper .asg-state-models .asg-controls-col {
    width: 100%;
    max-width: 1320px;
    margin: 0 auto;
    border-left: 0;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.05), 0 28px 60px rgba(0,0,0,0.28);
}

#asg-configuratore-wrapper.asg-state-models .asg-controls-header-models,
#asg-configuratore-wrapper .asg-state-models .asg-controls-header-models {
    padding: 34px 34px 22px;
    background:
        radial-gradient(circle at top right, rgba(0,212,170,0.12), transparent 28%),
        radial-gradient(circle at top left, rgba(91,154,255,0.10), transparent 26%),
        linear-gradient(180deg, rgba(11,18,31,0.98) 0%, rgba(8,14,24,0.94) 100%);
}

#asg-configuratore-wrapper.asg-state-models .asg-controls-header-models .asg-controls-heading h2,
#asg-configuratore-wrapper .asg-state-models .asg-controls-header-models .asg-controls-heading h2 {
    font-size: clamp(34px, 4vw, 58px);
    line-height: 0.94;
}

#asg-configuratore-wrapper.asg-state-models .asg-controls-header-models .asg-controls-heading p,
#asg-configuratore-wrapper .asg-state-models .asg-controls-header-models .asg-controls-heading p {
    max-width: 62ch;
    color: #9eb2cb;
    font-size: 15px;
}

#asg-configuratore-wrapper.asg-state-models .asg-controls-body,
#asg-configuratore-wrapper .asg-state-models .asg-controls-body {
    padding: 10px 34px 34px;
}

#asg-configuratore-wrapper.asg-state-models .asg-models-grid,
#asg-configuratore-wrapper .asg-state-models .asg-models-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

#asg-configuratore-wrapper .asg-model-card {
    overflow: hidden;
}

#asg-configuratore-wrapper .asg-model-card .mc-visual {
    position: relative;
    min-height: 220px;
    border-radius: 22px;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    padding: 18px;
    background:
        radial-gradient(circle at top right, rgba(0,212,170,0.12), transparent 28%),
        linear-gradient(180deg, rgba(16,24,40,0.18) 0%, rgba(7,10,18,0.92) 100%);
    border: 1px solid rgba(255,255,255,0.05);
}

#asg-configuratore-wrapper .asg-model-card .mc-visual.has-image {
    background-size: cover;
    background-position: center center;
}

#asg-configuratore-wrapper .asg-model-card .mc-visual-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(4,8,14,0.08) 0%, rgba(4,8,14,0.24) 40%, rgba(4,8,14,0.82) 100%),
        radial-gradient(circle at top right, rgba(0,212,170,0.22), transparent 34%);
}

#asg-configuratore-wrapper .asg-model-card .mc-visual .mc-icon,
#asg-configuratore-wrapper .asg-model-card .mc-visual .mc-visual-copy {
    position: relative;
    z-index: 1;
}

#asg-configuratore-wrapper .asg-model-card .mc-visual .mc-icon {
    width: 62px;
    height: 62px;
    border-radius: 20px;
    background: rgba(7,13,22,0.55);
    backdrop-filter: blur(10px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.22);
}

#asg-configuratore-wrapper .asg-model-card .mc-visual-copy {
    display: grid;
    gap: 8px;
    justify-items: end;
}

#asg-configuratore-wrapper .asg-model-card .mc-visual-copy span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(7,13,22,0.52);
    border: 1px solid rgba(255,255,255,0.08);
    color: #eef5ff;
    font-size: 12px;
    font-weight: 700;
}

#asg-configuratore-wrapper .asg-model-card .mc-main {
    grid-template-columns: minmax(0, 1fr);
}

@media (min-width: 1181px) {
    #asg-configuratore-wrapper.asg-state-configurator .asg-viewer-col,
    #asg-configuratore-wrapper .asg-state-configurator .asg-viewer-col {
        position: sticky;
        top: 104px;
        align-self: start;
    }

    #asg-configuratore-wrapper.asg-state-configurator #asg-3d-canvas,
    #asg-configuratore-wrapper .asg-state-configurator #asg-3d-canvas {
        min-height: calc(100vh - 152px);
    }

    #asg-configuratore-wrapper.asg-state-configurator .asg-viewer-overlay,
    #asg-configuratore-wrapper .asg-state-configurator .asg-viewer-overlay {
        display: flex;
        flex-direction: column;
    }

    #asg-configuratore-wrapper .asg-viewer-controls {
        margin-top: auto;
    }

    #asg-configuratore-wrapper.asg-state-configurator #step-2-view,
    #asg-configuratore-wrapper .asg-state-configurator #step-2-view {
        display: flex;
        flex-direction: column;
        min-height: 100%;
    }

    #asg-configuratore-wrapper.asg-state-configurator #step-2-view .asg-controls-body,
    #asg-configuratore-wrapper .asg-state-configurator #step-2-view .asg-controls-body {
        padding-bottom: 260px;
    }

    #asg-configuratore-wrapper.asg-state-configurator #step-2-view .asg-controls-footer,
    #asg-configuratore-wrapper .asg-state-configurator #step-2-view .asg-controls-footer {
        position: sticky;
        bottom: 16px;
        z-index: 18;
        margin-top: auto;
        padding: 18px;
        border-radius: 26px;
        border: 1px solid rgba(255,255,255,0.08);
        background: linear-gradient(180deg, rgba(8,13,23,0.86) 0%, rgba(5,9,17,0.96) 100%);
        backdrop-filter: blur(16px);
        box-shadow: 0 18px 40px rgba(0,0,0,0.28);
    }
}

@media (max-width: 767px) {
    #asg-configuratore-wrapper.asg-state-models .asg-controls-header-models,
    #asg-configuratore-wrapper .asg-state-models .asg-controls-header-models,
    #asg-configuratore-wrapper.asg-state-models .asg-controls-body,
    #asg-configuratore-wrapper .asg-state-models .asg-controls-body {
        padding-left: 16px;
        padding-right: 16px;
    }

    #asg-configuratore-wrapper .asg-model-card .mc-visual {
        min-height: 180px;
        padding: 14px;
    }

    #asg-configuratore-wrapper .asg-model-card .mc-visual .mc-icon {
        width: 52px;
        height: 52px;
        border-radius: 16px;
    }

    #asg-configuratore-wrapper .asg-model-card .mc-visual-copy {
        justify-items: start;
    }

    #asg-configuratore-wrapper .asg-model-card .mc-visual-copy span:last-child {
        display: none;
    }

    #asg-configuratore-wrapper .asg-modal-content.asg-modal-wide {
        max-height: min(92dvh, 700px);
        overflow: hidden;
    }

    #asg-configuratore-wrapper .asg-modal-left {
        gap: 10px;
        padding: 14px 16px 8px;
    }

    #asg-configuratore-wrapper .asg-modal-copy h3 {
        font-size: 24px;
        line-height: 0.98;
        margin-bottom: 0;
    }

    #asg-configuratore-wrapper .asg-modal-copy p,
    #asg-configuratore-wrapper .asg-modal-stats,
    #asg-configuratore-wrapper .asg-modal-left-footer {
        display: none;
    }

    #asg-configuratore-wrapper .asg-modal-icon {
        width: 46px;
        height: 46px;
        border-radius: 14px;
    }

    #asg-configuratore-wrapper .asg-modal-right {
        padding: 12px 16px 16px;
        overflow: hidden;
    }

    #asg-configuratore-wrapper .asg-modal-card-grid {
        gap: 10px;
        margin-bottom: 10px;
    }

    #asg-configuratore-wrapper .asg-modal-card {
        padding: 12px;
        border-radius: 18px;
    }

    #asg-configuratore-wrapper .asg-modal-section-title {
        margin-bottom: 10px;
        font-size: 12px;
    }

    #asg-configuratore-wrapper .asg-modal-card .asg-field-group + .asg-field-group {
        margin-top: 10px;
    }

    #asg-configuratore-wrapper .asg-modal-card label {
        font-size: 10px;
        margin-bottom: 4px;
    }

    #asg-configuratore-wrapper .asg-modal-input {
        min-height: 44px;
        font-size: 14px;
    }

    #asg-configuratore-wrapper .asg-toggle-option {
        min-height: 50px;
        padding: 12px 14px;
    }

    #asg-configuratore-wrapper .asg-modal-submit-btn {
        min-height: 52px;
        border-radius: 16px;
    }
}

/* ===== V20 Frontend Finish Overrides ===== */
#asg-configuratore-wrapper .btn,
#asg-configuratore-wrapper .btn-stepper,
#asg-configuratore-wrapper .asg-swatch,
#asg-configuratore-wrapper .asg-modal-submit-btn,
#asg-configuratore-wrapper .asg-modal-close-btn,
#asg-configuratore-wrapper input,
#asg-configuratore-wrapper textarea,
#asg-configuratore-wrapper select {
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

#asg-configuratore-wrapper .asg-viewer-controls {
    left: 50%;
    transform: translateX(-50%);
    bottom: 20px;
    z-index: 12;
}

#asg-configuratore-wrapper .asg-viewer-controls .btn {
    min-width: 132px;
    justify-content: center;
}

#asg-configuratore-wrapper .asg-controls-footer {
    background: linear-gradient(180deg, rgba(4,9,18,0.1) 0%, rgba(4,9,18,0.92) 16%, rgba(4,9,18,0.97) 100%);
    backdrop-filter: blur(12px);
    border-top: 1px solid rgba(96, 143, 255, 0.16);
}

#asg-configuratore-wrapper.asg-state-configurator .asg-viewer-col {
    position: sticky;
    top: 96px;
    align-self: start;
}

#asg-configuratore-wrapper.asg-state-configurator #step-2-view .asg-controls-body {
    padding-bottom: 248px;
}

#asg-configuratore-wrapper.asg-state-configurator .asg-controls-footer {
    position: sticky;
    bottom: 14px;
    z-index: 6;
    border-radius: 24px;
    padding: 18px;
    margin-top: 16px;
    box-shadow: 0 18px 40px rgba(0,0,0,0.34);
}

#asg-configuratore-wrapper.asg-state-models .asg-viewer-col {
    background: radial-gradient(circle at 20% 20%, rgba(22,46,86,0.18), rgba(4,9,18,0.02) 42%), linear-gradient(180deg, rgba(4,9,18,0.74), rgba(4,9,18,0.92));
}

#asg-configuratore-wrapper.asg-state-models #asg-3d-canvas,
#asg-configuratore-wrapper.asg-state-models .asg-viewer-top-info,
#asg-configuratore-wrapper.asg-state-models .asg-viewer-controls,
#asg-configuratore-wrapper.asg-state-models .asg-watermark,
#asg-configuratore-wrapper.asg-state-models .asg-gizmo-overlay {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

#asg-configuratore-wrapper.asg-state-models .asg-viewer-teaser {
    inset: 0;
    opacity: 1;
    visibility: visible;
}

#asg-configuratore-wrapper #btn-request-quote {
    background: rgba(255,255,255,0.03);
}

#asg-configuratore-wrapper #asg-contact-message-card {
    display: none;
}

#asg-configuratore-wrapper .asg-modal-overlay.is-contact-mode #asg-contact-message-card {
    display: block;
}

#asg-configuratore-wrapper .asg-modal-overlay.is-contact-mode #asg-pdf-options-card,
#asg-configuratore-wrapper .asg-modal-overlay.is-contact-mode #asg-modal-stats {
    display: none;
}

#asg-configuratore-wrapper .asg-modal-textarea {
    min-height: 92px;
    resize: vertical;
    padding-top: 16px;
}

@media (max-width: 1100px) {
    #asg-configuratore-wrapper.asg-state-configurator .asg-viewer-col {
        position: relative;
        top: auto;
    }

    #asg-configuratore-wrapper.asg-state-configurator #step-2-view .asg-controls-body {
        padding-bottom: 32px;
    }

    #asg-configuratore-wrapper.asg-state-configurator .asg-controls-footer {
        position: relative;
        bottom: auto;
        border-radius: 20px;
        padding: 16px;
        margin-top: 14px;
    }
}

@media (max-width: 768px) {
    #asg-configuratore-wrapper .asg-viewer-controls {
        bottom: 14px;
        width: calc(100% - 24px);
        max-width: 360px;
        padding: 8px;
        gap: 8px;
    }

    #asg-configuratore-wrapper .asg-viewer-controls .btn {
        min-width: 0;
        flex: 1 1 0;
    }

    #asg-configuratore-wrapper .asg-modal-overlay {
        padding: 10px;
        align-items: center;
    }

    #asg-configuratore-wrapper .asg-modal-content.asg-modal-wide {
        width: min(100%, 430px);
        max-height: 92dvh;
        min-height: 0;
        grid-template-columns: 1fr;
        overflow: hidden;
        border-radius: 24px;
    }

    #asg-configuratore-wrapper .asg-modal-left {
        padding: 16px 16px 8px;
        border-right: none;
        border-bottom: 1px solid rgba(255,255,255,0.06);
    }

    #asg-configuratore-wrapper .asg-modal-copy h3 {
        font-size: 2.15rem;
        line-height: 0.95;
        margin-bottom: 8px;
    }

    #asg-configuratore-wrapper .asg-modal-copy p,
    #asg-configuratore-wrapper .asg-modal-stats,
    #asg-configuratore-wrapper .asg-modal-left-footer {
        display: none;
    }

    #asg-configuratore-wrapper .asg-modal-icon {
        width: 72px;
        height: 72px;
        margin-bottom: 10px;
    }

    #asg-configuratore-wrapper .asg-modal-right {
        padding: 12px 14px 14px;
        overflow: auto;
        -webkit-overflow-scrolling: touch;
    }

    #asg-configuratore-wrapper .asg-modal-card-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    #asg-configuratore-wrapper .asg-modal-card {
        padding: 12px;
        border-radius: 18px;
    }

    #asg-configuratore-wrapper .asg-modal-card .asg-field-group + .asg-field-group {
        margin-top: 8px;
    }

    #asg-configuratore-wrapper .asg-modal-input {
        min-height: 44px;
        padding: 12px 14px;
        font-size: 16px;
    }

    #asg-configuratore-wrapper .asg-modal-textarea {
        min-height: 72px;
    }

    #asg-configuratore-wrapper #asg-location-card .asg-field-group:last-child {
        display: none;
    }

    #asg-configuratore-wrapper .asg-modal-submit-btn {
        margin-top: 10px;
        min-height: 50px;
        border-radius: 16px;
        font-size: 15px;
        padding: 0 16px;
    }
}

/* === V21 stability + contact UX overrides === */
#asg-configuratore-wrapper {
    touch-action: manipulation;
}

#asg-configuratore-wrapper .asg-choice-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 10px;
}

#asg-configuratore-wrapper .asg-choice-pill {
    position: relative;
    display: block;
}

#asg-configuratore-wrapper .asg-choice-pill input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

#asg-configuratore-wrapper .asg-choice-pill span {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 12px 14px;
    border-radius: 16px;
    border: 1px solid rgba(255,255,255,0.08);
    background: rgba(8,16,30,0.88);
    color: #c6d3e4;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.25;
    text-align: center;
    transition: all .2s ease;
}

#asg-configuratore-wrapper .asg-choice-pill input:checked + span {
    border-color: rgba(0,212,170,0.42);
    background: linear-gradient(135deg, rgba(0,212,170,0.18), rgba(37,99,235,0.16));
    color: #fff;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.24), inset 0 0 0 1px rgba(255,255,255,0.03);
}

#asg-configuratore-wrapper .asg-upload-box {
    display: block;
    border: 1px dashed rgba(255,255,255,0.14);
    border-radius: 18px;
    background: rgba(8,16,30,0.88);
    padding: 14px 16px;
    cursor: pointer;
}

#asg-configuratore-wrapper .asg-modal-file {
    display: none;
}

#asg-configuratore-wrapper .asg-upload-copy {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #dbe8f6;
}

#asg-configuratore-wrapper .asg-upload-copy i {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(0,212,170,0.22), rgba(37,99,235,0.2));
    color: #36f3d7;
}

#asg-configuratore-wrapper .asg-upload-copy strong {
    display: block;
    color: #fff;
    font-size: 14px;
    line-height: 1.15;
}

#asg-configuratore-wrapper .asg-upload-copy small {
    display: block;
    color: #7f93ac;
    margin-top: 3px;
    line-height: 1.35;
}

#asg-configuratore-wrapper .asg-photo-preview {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

#asg-configuratore-wrapper .asg-photo-chip {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 8px 11px;
    border-radius: 999px;
    background: rgba(255,255,255,0.06);
    color: #dce8f7;
    font-size: 11px;
    line-height: 1.2;
}

#asg-configuratore-wrapper .asg-photo-chip small {
    color: #8ea2bb;
}

@media (min-width: 1101px) {
    #asg-configuratore-wrapper .asg-grid {
        align-items: start;
    }

    #asg-configuratore-wrapper .asg-viewer-col {
        position: sticky;
        top: 112px;
        z-index: 2;
    }

    #asg-configuratore-wrapper .asg-viewer-controls {
        position: absolute;
        left: 50%;
        bottom: 24px;
        transform: translateX(-50%);
        z-index: 5;
    }

    #asg-configuratore-wrapper .asg-controls-col {
        position: relative;
    }

    #asg-configuratore-wrapper.asg-state-configurator #step-2-view .asg-controls-footer {
        position: sticky;
        bottom: 12px;
        z-index: 6;
        margin-top: 18px;
        border-top: 1px solid rgba(255,255,255,0.06);
        background: linear-gradient(180deg, rgba(5,12,25,0.86) 0%, rgba(5,12,25,0.98) 24%, rgba(5,12,25,1) 100%);
        backdrop-filter: blur(16px);
        box-shadow: 0 -18px 40px rgba(2,6,18,0.3);
    }
}

@media (max-width: 768px) {
    #asg-configuratore-wrapper .asg-modal-overlay {
        padding: 10px;
        align-items: flex-start;
    }

    #asg-configuratore-wrapper .asg-modal-content.asg-modal-wide {
        width: 100%;
        max-height: calc(100dvh - 20px);
        overflow: auto;
        border-radius: 26px;
        margin: 0;
    }

    #asg-configuratore-wrapper .asg-modal-left {
        padding: 22px 22px 12px;
    }

    #asg-configuratore-wrapper .asg-modal-right {
        padding: 14px 18px 18px;
    }

    #asg-configuratore-wrapper .asg-modal-card {
        padding: 16px;
        border-radius: 18px;
    }

    #asg-configuratore-wrapper .asg-choice-grid {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    #asg-configuratore-wrapper .asg-choice-pill span {
        min-height: 44px;
        padding: 10px;
        font-size: 11px;
    }

    #asg-configuratore-wrapper .asg-upload-copy strong {
        font-size: 13px;
    }

    #asg-configuratore-wrapper .asg-upload-copy small {
        font-size: 11px;
    }

    #asg-configuratore-wrapper .asg-modal-right .asg-field-group {
        margin-bottom: 14px;
    }

    #asg-configuratore-wrapper .asg-modal-submit-btn {
        position: sticky;
        bottom: 0;
        z-index: 4;
        margin-top: 12px;
        min-height: 56px;
    }

    #asg-configuratore-wrapper .asg-controls-footer,
    #asg-configuratore-wrapper.asg-state-configurator .asg-controls-footer,
    #asg-configuratore-wrapper .asg-viewer-col {
        position: static;
        top: auto;
        bottom: auto;
    }
}



/* v5 final gizmo placement */
@media (min-width: 1181px) {
  #asg-configuratore-wrapper .asg-gizmo-overlay {
    width: 108px;
    height: 108px;
    left: 22px;
    bottom: 84px;
    top: auto;
    right: auto;
  }
}
@media (max-width: 1180px) {
  #asg-configuratore-wrapper .asg-gizmo-overlay {
    width: 84px;
    height: 84px;
    left: 18px;
    bottom: 74px;
    top: auto;
    right: auto;
  }
}


/* v6 gizmo placement cleanup */
@media (min-width: 1181px) {
  #asg-configuratore-wrapper .asg-gizmo-overlay {
    top: 18px;
    right: 18px;
    left: auto;
    bottom: auto;
    width: 84px;
    height: 84px;
  }

  #asg-configuratore-wrapper .asg-gizmo-overlay canvas {
    width: 84px;
    height: 84px;
  }
}
