.fabric-drawer__topbar,
.fabric-drawer__scroll {
    display: contents;
}

.fabric-drawer__section-title[hidden] {
    display: none !important;
}

.fabric-filter-button__icon--active,
.fabric-filter-button.is-active .fabric-filter-button__icon--inactive {
    display: none;
}

.fabric-filter-button.is-active .fabric-filter-button__icon--active {
    display: block;
}

.fabric-drawer__video-slot:empty {
    display: none;
}

.fabric-drawer__video-slot[hidden] {
    display: none !important;
}

.fabric-drawer__video-slot {
    margin: 0px 32px 14px;
}

.fabric-video-preview--drawer {
}

.fabric-video-preview--drawer .fabric-video-preview__button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 38px;
    padding: 0 12px;
    border-color: #dbd1c4;
    border-radius: 10px;
    background: #fff;
    color: #5a3121;
    text-align: center;
}

.fabric-video-preview--drawer .fabric-video-preview__thumbnail img,
.fabric-video-preview--drawer .fabric-video-preview__content > span,
.fabric-video-preview--drawer .fabric-video-preview__arrow {
    display: none;
}

.fabric-video-preview--drawer .fabric-video-preview__thumbnail {
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    overflow: visible;
    border-radius: 0;
}

.fabric-video-preview--drawer .fabric-video-preview__content,
.fabric-video-preview--drawer .fabric-video-preview__content strong {
    display: block;
    margin: 0;
    color: inherit;
    font-size: 14px;
    font-weight: 600;
}

.fabric-video-preview--drawer .fabric-video-preview__play {
    position: static;
    display: grid;
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    transform: none;
    color: #5a3121;
    background: transparent;
    border: 0;
    font-size: 8px;
}

.fabric-video-preview__play svg {
    display: block;
    width: 100%;
    height: 100%;
}

#product .details-block.fabric-panel-open .fabric-drawer__video-slot {
    margin-right: 0;
    margin-left: 0;
}

@media (max-width: 767px) {
    .fabric-drawer__video-slot {
        margin-right: 16px;
        margin-left: 16px;
    }
}

.fabric-drawer__sample {
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    min-height: 50px;
    margin-top: 14px;
    padding: 10px 16px;
    border: 1px solid #ddd7cf;
    border-radius: 12px;
    background: #fff;
    color: #000;
    font: 600 14px/1.4 Poppins, sans-serif;
    cursor: pointer;
}

.fabric-drawer__sample-icon {
    display: block;
    flex: 0 0 16px;
    width: 16px;
    height: 16px;
    object-fit: contain;
}

.fabric-selector {
    width: 100%;
}

.fabric-selector__trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    min-height: 52px;
    padding: 12px 16px;
    border: 1px solid var(--cornero-border-light);
    border-radius: 8px;
    background: #fff;
    color: var(--cornero-black);
    text-align: left;
    cursor: pointer;
}

.fabric-selector__change {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.fabric-selector__change svg {
    display: block;
    flex: 0 0 11px;
    /* width: 10px; */
    /* height: 14px; */
}

.fabric-drawer {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: block;
    visibility: hidden;
    pointer-events: none;
}

.fabric-drawer__backdrop {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    background: rgba(0, 0, 0, 0.42);
    opacity: 0;
    cursor: pointer;
    transition: opacity 200ms ease;
}

.fabric-drawer.is-open {
    visibility: visible;
    pointer-events: auto;
}

.fabric-drawer.is-open .fabric-drawer__backdrop {
    opacity: 1;
}

.fabric-drawer__header {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 24px 32px 16px;
}

.fabric-drawer__header h2 {
    grid-column: 1 / -1;
    grid-row: 2;
    margin: 0;
    font-size: 24px;
    font-weight: 600;
}

.fabric-drawer__back {
    grid-column: 1;
    grid-row: 1;
    width: fit-content;
    padding: 0;
    border: 0;
    background: transparent;
    color: #543529;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}

.fabric-drawer__selected {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 18px 32px;
    padding: 14px 16px;
    border: 1px solid var(--cornero-border-light);
    border-radius: 8px;
    background: #fff;
}

.fabric-drawer__selected-preview {
    display: none;
}

.fabric-selector > .fabric-selector__trigger .fabric-selector__preview {
    display: none;
}

.fabric-selector__availability {
    display: none;
}

.fabric-drawer__selected small,
.fabric-drawer__selected strong {
    display: block;
}

.fabric-drawer__selected small {
    color: var(--gray);
    font-size: 14px;
}

.fabric-drawer__selected strong {
    font-size: 15px;
    font-weight: 600;
}

.fabric-drawer__filters {
    display: flex;
    gap: 8px;
    margin: 0 32px 14px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--cornero-border-light);
}

.fabric-drawer__section-title {
    /* margin: 0 32px 10px; */
    color: var(--cornero-black);
    font-size: 16px;
    font-weight: 600;
}

.fabric-filter-button {
    display: inline-flex;
    flex: 1 1 0;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 14px;
    border: 1px solid var(--cornero-border-light);
    border-radius: 10px;
    background: #fff;
    color: var(--cornero-black);
    font: inherit;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
}

.fabric-filter-button:disabled {
    border-color: #ded8d4;
    background: #f1f1f1;
    color: #999;
    cursor: not-allowed;
}

.fabric-filter-button:disabled .fabric-filter-button__icon {
    filter: grayscale(1);
    opacity: 0.45;
}

.fabric-filter-button.is-active[data-fabric-filter="fast"] {
    border: 1.5px solid #16834b;
    background: #eaf5ef;
    color: #16834b;
    font-weight: 600;
}

.fabric-filter-button.is-active[data-fabric-filter="all"] {
    border: 1.5px solid #5a3121;
    background: #f6f0eb;
    color: #5a3121;
    font-weight: 600;
}

.fabric-filter-button__icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
}

.fabric-drawer__families {
    display: flex;
    gap: 8px;
    margin: 0 32px 16px;
    overflow-x: auto;
}

.fabric-drawer__families[hidden] {
    display: none;
}

.fabric-family-button {
    flex: 0 0 auto;
    min-width: 110px;
    min-height: 48px;
    padding: 10px 16px;
    border: 1px solid var(--cornero-border-light);
    border-radius: 10px;
    background: #fff;
    color: var(--cornero-black);
    cursor: pointer;
}

.fabric-family-button.is-active {
    border-color: #5a3121;
    background: #f4ece7;
    color: #292421;
}

/* Fabric family tiles share the swatch image used by the color choices. */
.fabric-drawer__families {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(110px, 100%), 1fr));
    gap: 8px;
    overflow: visible;
}
.fabric-family-button {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    min-height: 62px;
    padding: 8px;
    border: 1px solid #ded8d4;
    border-radius: 12px;
    background: #fff;
    text-align: left;
}
.fabric-family-button.is-active {
    border-color: #5a3121;
    box-shadow: inset 0 0 0 0.5px #5a3121;
    background: #f4ece7;
}
.fabric-family-button__texture {
    display: block;
    flex: 0 0 34px;
    width: 34px;
    height: 44px;
    border-radius: 7px;
    background-color: #eeeae6;
    background-position: center;
    background-size: var(--fabric-family-crop-size, 120px) auto;
    background-repeat: no-repeat;
}
.fabric-family-button__text { display: flex; min-width: 0; flex-direction: column; gap: 3px; }
.fabric-family-button__text strong { font-weight: 600; overflow-wrap: anywhere; }
.fabric-family-button__description { color: #766f69; font-size: .85em; line-height: 1.3; overflow-wrap: anywhere; }
.fabric-family-button:focus-visible { outline: 2px solid #5a3121; outline-offset: 2px; }

@media (min-width: 768px) {
    .fabric-drawer__families {
        grid-template-columns: repeat(auto-fit, minmax(max(110px, calc((100% - 16px) / 3)), 1fr));
    }
    .fabric-family-button {gap: 12px;min-height: 74px;padding: 9px;}
    .fabric-family-button__texture { flex-basis: 44px; width: 44px; height: 54px; }
}

.fabric-drawer__body {
    min-height: 0;
    padding: 0 32px 24px;
    overflow: auto;
}

.fabric-drawer__panel {
    position: absolute;
    top: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    width: min(720px, 58vw);
    height: 100%;
    overflow: hidden;
    background: #fff;
    box-shadow: -8px 0 30px rgba(0, 0, 0, 0.14);
    transform: translateX(100%);
    transition: transform 260ms ease;
}

.fabric-drawer.is-open .fabric-drawer__panel {
    transform: translateX(0);
}

.fabric-drawer__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    width: 100%;
    margin: 0;
    padding: 0;
    list-style: none;
}

.fabric-option label {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 48px;
    margin: 0;
    padding: 10px 12px;
    border: 1px solid var(--cornero-border-light);
    border-radius: 8px;
    background: #fff;
    color: var(--cornero-black);
    cursor: pointer;
}

.fabric-option__texture {
    display: block;
    width: 100%;
    height: 112px;
    border-radius: 6px 6px 0 0;
    background-color: #eee;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

.fabric-option__name {
    display: flex;
    align-items: center;
    min-height: 38px;
    width: 100%;
    padding: 8px 6px;
    overflow: hidden;
    font-size: 13px;
    text-align: center;
    justify-content: center;
    text-overflow: ellipsis;
    white-space: normal;
}

.fabric-option label {
    flex-direction: column;
    padding: 3px;
}

.fabric-option .input-color:checked + label {
    border-color: var(--blue-accent);
    box-shadow: 0 0 0 1px var(--blue-accent);
}

.fabric-drawer__footer {
    display: none;
}

.fabric-option {
    position: relative;
    min-width: 0;
    margin: 0 !important;
    padding: 0;
}

.fabric-option .input-color {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: 0;
    opacity: 0;
    pointer-events: none;
}

.fabric-option__texture {
    display: block;
    width: 100%;
    height: 72px;
    border-radius: 6px;
    background-color: #eee;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

.fabric-option .input-color:focus-visible + label {
    outline: 2px solid #4b3027;
    outline-offset: 3px;
}

/* Filtrowanie przez JS */
.fabric-option[hidden] {
    display: none !important;
}

@media (max-width: 767px) {
    .fabric-selector > .control-label {
        display: block;
        margin-bottom: 10px;
        font-size: 16px;
        font-weight: 600;
    }

    .fabric-selector__trigger {
        position: relative;
        display: flex;
        align-items: center;
        gap: 9px;
        width: 100%;
        height: 74px;
        min-height: 74px;
        padding: 10px;
        border: 1px solid #ded8d4;
        border-radius: 12px;
        background: #fff;
        color: #292421;
        text-align: left;
        cursor: pointer;
    }

    .fabric-selector > .fabric-selector__trigger .fabric-selector__preview {
        display: block;
        width: 48px;
        height: 48px;
        flex: 0 0 48px;
        border-radius: 8px;
        background-color: #eee;
        background-position: center;
        background-repeat: no-repeat;
        background-size: cover;
    }

    .fabric-selector__content {
        position: relative;
        display: flex;
        flex: 1;
        flex-direction: column;
        gap: 2px;
        min-width: 0;
        padding: 0 88px 0 0;
    }

    .fabric-selector__content strong {
        overflow: hidden;
        font-size: 14px;
        font-weight: 600;
        line-height: 1.45;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .fabric-selector__availability {
        display: flex;
        align-items: center;
        gap: 4px;
        color: #766f69;
        font-size: 12px;
        line-height: 1.45;
        white-space: nowrap;
    }

    .fabric-selector__availability[data-delivery-speed="fast"] {
        color: #008c4f;
    }

    .fabric-selector__availability-dot {
        width: 6px;
        height: 6px;
        flex: 0 0 6px;
        border-radius: 50%;
        background: currentColor;
    }

    .fabric-selector__content > span:not(.fabric-selector__availability) {
        position: absolute;
        top: 50%;
        right: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 98px;
        height: 38px;
        border-radius: 19px;
        background: #faf7f4;
        color: #5a3121;
        font-size: 12px;
        font-weight: 600;
        white-space: nowrap;
        transform: translateY(-50%);
    }

    .fabric-selector__arrow {
        display: none;
    }

    .fabric-drawer {
        position: fixed;
        top:39px;
        left:0;
        right:0;
        bottom:60px;
        z-index: 999999;
        display: block;
        visibility: hidden;
        pointer-events: none;
    }

    .fabric-drawer.is-open {
        visibility: visible;
        pointer-events: auto;
    }

    .fabric-drawer__backdrop {
        position: absolute;
        inset: 0;
        display: block;
        width: 100%;
        height: 100%;
        padding: 0;
        border: 0;
        background: rgba(0, 0, 0, 0.58);
        opacity: 0;
        cursor: pointer;
        transition: opacity 250ms ease;
    }

    .fabric-drawer.is-open .fabric-drawer__backdrop {
        opacity: 1;
    }

    .fabric-drawer {
        position: fixed;
        inset: 0;
        height: 100dvh;
        z-index: 999999;
    }
    .fabric-drawer__panel {
        height: 100dvh;
        position: absolute;
        top: 0;
        right: 0;
        display: flex;
        flex-direction: column;
        width: 100%;
        overflow: hidden;
        background: #fff;
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.15);
        transform: translateX(100%);
        transition: transform 300ms ease;
    }

    .fabric-drawer.is-open .fabric-drawer__panel {
        transform: translateX(0);
    }

    .fabric-drawer.is-closing .fabric-drawer__panel {
        transform: translateX(100%);
        transition: transform 220ms ease-in;
    }

    .fabric-drawer.is-closing .fabric-drawer__backdrop {
        opacity: 0;
        transition: opacity 180ms ease-in;
    }

    .fabric-drawer__topbar {
        display: flex;
        flex: 0 0 auto;
        align-items: center;
        min-height: 44px;
        padding: 0px 16px 0;
    }

    .fabric-drawer__scroll {
        display: block;
        flex: 1 1 auto;
        min-height: 0;
        overflow-x: hidden;
        overflow-y: auto;
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
    }

    .fabric-drawer__header {
        display: flex;
        align-items: flex-start;
        flex-direction: column;
        justify-content: flex-start;
        gap: 10px;
        flex: 0 0 auto;
        padding: 0 16px;
    }

    .fabric-drawer__selected {
        display: none;
    }

    .fabric-drawer__selection-summary {
        flex: 0 0 auto;
    }

    .fabric-drawer__back {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        min-height: 14px;
        padding: 0;
        border: 0;
        background: transparent;
        color: #613829;
        font-size: 12px;
        font-weight: 500;
    }

    .fabric-drawer__back-icon {
        display: block;
        width: 15px;
        height: 15px;
        flex: 0 0 15px;
    }

    .fabric-drawer__header h2 {
        margin: 0;
        font-size: 22px;
        line-height: 1.2;
        font-weight: 600;
    }

    .fabric-drawer__hint {
        display: none;
        font-size: 9px;
        line-height: 1.35;
    }

    .fabric-drawer__search {
        display: none;
    }

    .fabric-drawer__section-title {
        display: block;
        margin: 14px 16px 14px;
        font-size: 16px;
    }

    .fabric-drawer__selected {
        display: none;
        align-items: center;
        gap: 12px;
        flex: 0 0 auto;
        margin: 0 18px 14px;
        padding: 10px;
        border: 1px solid #ded8d4;
        border-radius: 10px;
        background: #fff;
    }

    .fabric-drawer__selected-preview {
        display: block;
        width: 68px;
        height: 68px;
        flex: 0 0 68px;
        border-radius: 7px;
        background-color: #eee;
        background-position: center;
        background-repeat: no-repeat;
        background-size: cover;
    }

    .fabric-drawer__selected strong {
        overflow: hidden;
        font-size: 16px;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .fabric-drawer__search {
        display: none;
    }

    .fabric-drawer__search input {
        width: 100%;
        height: 48px;
        padding: 0 14px;
        border: 1px solid #ded8d4;
        border-radius: 9px;
        background: #fff;
        color: #292421;
        font-size: 15px;
        outline: none;
    }

    .fabric-drawer__search input:focus {
        border-color: #4b3027;
        box-shadow: 0 0 0 1px #4b3027;
    }

    .fabric-drawer__families {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(min(120px, 100%), 1fr));
        flex: 0 0 auto;
        gap: 8px;
        margin: 0 16px 14px;
        overflow: visible;
        scrollbar-width: none;
    }

    .fabric-drawer__families::-webkit-scrollbar {
        display: none;
    }

    .fabric-family-button {
        min-width: 0;
        height: auto;
        min-height: 62px;
        padding: 8px;
        border: 1px solid #ded8d4;
        border-radius: 12px;
        background: #fff;
        color: #292421;
        font-size: 14px;
        cursor: pointer;
    }

    .fabric-family-button.is-active {
        border-color: #5a3121;
        background: #f4ece7;
        color: #292421;
    }

    .fabric-drawer__body {
        flex: 0 0 auto;
        min-height: auto;
        padding: 0 16px 18px;
        overflow-x: hidden;
        overflow-y: visible;
    }

    .fabric-drawer__grid {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 10px;
        margin: 0;
    }

    .fabric-option label {
        padding: 3px;
        border-color: #ded8d4;
        border-radius: 9px;
    }

    .fabric-option__texture {
        height: 112px;
        border-radius: 6px 6px 0 0;
    }

    .fabric-option__name {
        display: flex;
        flex-direction: column;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .fabric-option .attribute-price-impact {
        margin: 3px 0 0;
        font-size: 14px;
    }

    .fabric-option .input-color:checked + label {
        position: relative;
    }

    .fabric-option .input-color:checked + label::after {
        content: "Ã¢Å“â€œ";
        position: absolute;
        top: 9px;
        right: 9px;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 26px;
        height: 26px;
        border-radius: 50%;
        background: #4b3027;
        color: #fff;
        font-size: 15px;
    }

    .fabric-drawer__footer {
        display: block;
        flex: 0 0 auto;
        padding: 12px 18px;
        padding-bottom: max(12px, env(safe-area-inset-bottom));
        border-top: 1px solid #ded8d4;
        background: #fbfaf9;
    }

    .fabric-drawer__confirm {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 5px;
        width: 100%;
        min-height: 52px;
        padding: 10px 16px;
        border: 0;
        border-radius: 8px;
        background: #4b3027;
        color: #fff;
        font-size: 15px;
        font-weight: 600;
        cursor: pointer;
    }

    .fabric-drawer__confirm-icon {
        display: block;
        flex: 0 0 20px;
        width: 20px;
        height: 20px;
    }

    body.fabric-drawer-open {
        overflow: hidden;
        touch-action: none;
    }
}

.fabric-drawer__mode-block {
    margin: 0px 32px 14px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--cornero-border-light);
}

.fabric-drawer__mode-block .fabric-drawer__filters {
    padding: 0;
    border: 0;
}

.fabric-drawer__mode-notice,
.fabric-drawer__selection-summary {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    margin: 0;
    padding: 10px 12px;
    border-radius: 12px;
}

.fabric-drawer__mode-notice[hidden],
.fabric-drawer__selection-summary[hidden] {
    display: none !important;
}

.fabric-drawer__mode-notice--fast {
    background: #f0f8f3;
    color: #188653;
}

.fabric-drawer__mode-notice--all {
    background: #f7f4ef;
    color: #5a3121;
}

.fabric-drawer__mode-icon,
.fabric-drawer__selection-icon {
    display: block;
    flex: 0 0 24px;
    width: 24px;
    height: 24px;
}

.fabric-drawer__mode-copy,
.fabric-drawer__selection-copy {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.fabric-drawer__mode-copy strong,
.fabric-drawer__selection-copy strong {
    color: currentColor;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.35;
}

.fabric-drawer__mode-copy > span,
.fabric-drawer__selection-copy > span {
    color: #766f69;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.4;
}

.fabric-drawer__selection-summary {
    margin-top: 0;
    margin-bottom: 14px;
    padding: 12px;
    background: #ebfaf2;
    color: #188653;
}

.fabric-drawer__selection-copy strong {
    color: #292421;
}

.fabric-drawer__selection-summary .fabric-drawer__selection-copy > span {
    color: #188653;
}

#product .details-block.fabric-panel-open .fabric-drawer__mode-notice,
#product .details-block.fabric-panel-open .fabric-drawer__selection-summary {
    margin-right: 0;
    margin-left: 0;
}

#product .details-block.fabric-panel-open .fabric-drawer__mode-block {
    margin-right: 0;
    margin-left: 0;
}

@media (max-width: 767px) {
    .fabric-drawer__mode-block {
        /* margin-right: 16px; */
        /* margin-left: 16px; */
        margin: 14px 16px 14px 16px;
    }

    .fabric-drawer__mode-block .fabric-drawer__filters {
        display: flex !important;
        gap: 8px;
        margin: 0 0 12px;
        padding: 0;
        border: 0;
    }

    .fabric-drawer__mode-block .fabric-filter-button {
        min-width: 0;
        min-height: 44px;
        padding: 0 8px;
        border-radius: 10px;
        font-size: 14px;
        white-space: nowrap;
    }

    .fabric-drawer__mode-block .fabric-filter-button__icon {
        width: 16px;
        height: 16px;
        flex-basis: 16px;
    }

    .fabric-drawer__mode-notice,
    .fabric-drawer__selection-summary {
        margin-right: 16px;
        margin-left: 16px;
        margin-top: 12px;
    }

    .fabric-drawer__mode-notice {
        margin-right: 0;
        margin-left: 0;
    }
}

@media (min-width: 768px) {
    #product .fabric-selector__arrow {
        display: none;
    }

    #product .fabric-selector__trigger {
        min-height: 68px;
        gap: 12px;
        padding: 10px 12px;
        border-radius: 10px;
    }

    #product .fabric-selector > .fabric-selector__trigger .fabric-selector__preview {
        display: block;
        width: 44px;
        height: 44px;
        flex: 0 0 44px;
        border: 1px solid var(--cornero-border-light);
        border-radius: 8px;
        background-position: center;
        background-repeat: no-repeat;
        background-size: cover;
    }

    #product .fabric-selector__content {
        display: flex;
        flex: 1;
        flex-direction: column;
        justify-content: center;
        align-items: flex-start;
        position: relative;
        min-width: 0;
        gap: 4px;
        padding: 0 94px 0 0;
        text-align: left;
    }

    #product .fabric-selector {
        padding-top: 0;
    }

    #product .product-variants-item.fabric-selector > .fabric-selector__title {
        display: block;
        margin: 0 0 8px;
        color: var(--cornero-black);
        font-size: 16px;
        font-weight: 600;
        line-height: 1.3;
    }

    #product .fabric-selector__content strong {
        font-size: 16px;
        line-height: 1.35;
        font-weight: 600;
    }

    #product .fabric-selector__availability {
        display: flex;
        align-items: center;
        gap: 5px;
        color: #625a56;
        font-size: 13px;
        font-weight: 500;
        line-height: 1.35;
    }

    #product .fabric-selector__availability[data-delivery-speed="fast"] {
        color: #17834a;
    }

    #product .fabric-selector__availability-dot {
        width: 6px;
        height: 6px;
        flex: 0 0 6px;
        border-radius: 50%;
        background: currentColor;
    }

    #product .fabric-selector__content > span:not(.fabric-selector__availability) {
        position: absolute;
        top: 50%;
        right: 0;
        transform: translateY(-50%);
        padding: 7px 16px;
        border-radius: 18px;
        background: var(--ivory);
        color: var(--blue-accent);
        font-size: 12px;
        font-weight: 600;
        white-space: nowrap;
    }

    #product .details-block.fabric-panel-open .product-details-block > :not(.product-information),
    #product .details-block.fabric-panel-open .product-information > :not(.product-actions),
    #product .details-block.fabric-panel-open .product-actions > :not(#add-to-cart-or-refresh),
    #product .details-block.fabric-panel-open #add-to-cart-or-refresh > :not(.js-product-variants):not([type="hidden"]),
    #product .details-block.fabric-panel-open #add-to-cart-or-refresh > .js-product-variants > :not(.fabric-drawer) {
        display: none !important;
    }

    #product .details-block.fabric-panel-open .product-information,
    #product .details-block.fabric-panel-open .product-actions,
    #product .details-block.fabric-panel-open #add-to-cart-or-refresh {
        margin: 0 !important;
        padding: 0 !important;
        border: 0 !important;
    }

    #product .details-block.fabric-panel-open .fabric-drawer {
        position: static;
        inset: auto;
        z-index: auto;
        display: block;
        width: 100%;
        height: auto;
        visibility: visible;
        pointer-events: auto;
        background: #fff;
    }

    #product .details-block.fabric-panel-open .fabric-drawer__backdrop {
        display: none;
    }

    #product .details-block.fabric-panel-open .fabric-drawer__panel,
    #product .details-block.fabric-panel-open .fabric-drawer.is-open .fabric-drawer__panel {
        position: static;
        inset: auto;
        display: flex;
        width: 100%;
        height: auto;
        min-height: 0;
        max-height: none;
        overflow: visible;
        background: #fff;
        box-shadow: none;
        transform: none;
        transition: none;
        visibility: visible;
    }

    #product .details-block.fabric-panel-open .fabric-drawer__body {
        flex: 0 0 auto;
        overflow: visible;
    }

    /* Match the product details content box: no extra drawer inset or top offset. */
    #product .details-block.fabric-panel-open .fabric-drawer__header {
        padding: 0 0 14px;
    }

    #product .details-block.fabric-panel-open .fabric-drawer__selected {
        margin: 18px 0;
    }

    #product .details-block.fabric-panel-open .fabric-drawer__filters {
        margin: 0 0 14px;
    }

    #product .details-block.fabric-panel-open .fabric-drawer__section-title {
        margin: 14px 0 14px;
    }

    #product .details-block.fabric-panel-open .fabric-drawer__families {
        margin: 0 0 16px;
    }

    #product .details-block.fabric-panel-open .fabric-drawer__body {
        padding: 0px 0 14px;
    }

    #product .details-block.fabric-panel-open .fabric-drawer__footer {
        display: block;
        flex: 0 0 auto;
        padding: 0 0 16px;
        border: 0;
        background: transparent;
    }

    #product .details-block.fabric-panel-open .fabric-drawer__confirm {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 12px;
        width: 100%;
        min-height: 58px;
        padding: 12px 20px;
        border: 0;
        border-radius: 10px;
        background: #543529;
        color: #fff;
        font-size: 15px;
        font-weight: 600;
        cursor: pointer;
    }

    #product .details-block.fabric-panel-open .fabric-drawer__confirm-icon {
        display: block;
        flex: 0 0 20px;
        width: 20px;
        height: 20px;
    }

    #product .fabric-drawer__back {
        display: inline-flex;
        align-items: center;
        gap: 8px;
    }

    #product .fabric-drawer__back-icon {
        display: block;
        width: 18px;
        height: 18px;
        flex: 0 0 18px;
        stroke-width: 2.2;
    }
}

.fabric-drawer__header {
    grid-template-columns: 1fr;
    gap: 8px;
}

.fabric-drawer__hint {
    grid-column: 1;
    margin: 0;
    color: #766f69;
    font-size: 14px;
    line-height: 1.4;
}

.fabric-drawer__colors-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 0 32px 14px;
}

.fabric-drawer__colors-header h3 {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    color: #292421;
    font-size: 16px;
    font-weight: 600;
}

.fabric-drawer__colors-fast-icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    object-fit: contain;
}

.fabric-drawer__colors-fast-icon[hidden],
.fabric-drawer__legend[hidden] {
    display: none !important;
}

.fabric-drawer__colors-header.is-fast-delivery [data-fabric-colors-count] {
    background: #e8f5ee;
    color: #188653;
}

.fabric-video-preview--drawer .fabric-video-preview__play .fabric-video-preview__play-icon {
    display: block;
    width: 20px;
    height: 20px;
    object-fit: contain;
}

.fabric-drawer__colors-header [data-fabric-colors-count] {
    min-width: 82px;
    padding: 7px 14px;
    border-radius: 14px;
    background: #f6f3ee;
    color: #543529;
    font-size: 12px;
    font-weight: 600;
    text-align: center;
}

.fabric-drawer__legend {
    display: flex;
    align-items: center;
    gap: 18px;
    min-height: 13px;
    margin: 0 32px 14px;
    color: #7a736b;
    font-size: 14px;
    font-weight: 400;
    line-height: 13px;
}

.fabric-drawer__legend-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.fabric-drawer__legend-dot {
    display: block;
    flex: 0 0 9px;
    width: 9px;
    height: 9px;
}

.fabric-drawer__grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.fabric-option label {
    position: relative;
    display: flex;
    align-items: stretch;
    flex-direction: column;
    gap: 6px;
    min-height: 0;
    padding: 0;
    border: 1px solid transparent;
    border-radius: 10px;
    background: transparent;
}

.fabric-option__texture {
    height: auto;
    aspect-ratio: 1.5 / 1;
    border: 1px solid #ddd7cf;
    border-radius: 10px;
}

.fabric-option__name {
    min-height: 14px;
    padding: 0;
    justify-content: flex-start;
    color: #7a736b;
    font-size: 12px;
    font-weight: 400;
    line-height: 14px;
    text-align: left;
}

.fabric-option .input-color:checked + label {
    border-color: transparent;
    box-shadow: none;
}

.fabric-option .input-color:checked + label .fabric-option__texture {
    border: 2px solid #5a3121;
}

.fabric-option.is-fast-delivery .fabric-option__name {
    color: #188653;
    font-weight: 600;
}

@media (max-width: 767px) {
    .fabric-drawer__selected small {
        font-size: 12px;
    }

    .fabric-drawer__back,
    .fabric-drawer__mode-copy strong,
    .fabric-drawer__selection-copy strong,
    .fabric-drawer__mode-block .fabric-filter-button,
    .fabric-drawer__hint {
        font-size: 13px;
    }

    .fabric-drawer__mode-copy > span,
    .fabric-drawer__selection-copy > span,
    .fabric-drawer__colors-header [data-fabric-colors-count],
    .fabric-drawer__legend {
        /* font-size: 10px; */
    }


    .fabric-drawer__colors-header {
        display: flex;
        margin: 0 16px 10px;
    }

    .fabric-drawer__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 10px;
    }

    .fabric-option__texture {
        height: auto;
        aspect-ratio: 1.5 / 1;
    }

    .fabric-drawer__legend {
        margin-left: 18px;
        margin-right: 18px;
        gap: 12px;
        font-size: 12px;
    }
}

#product .details-block.fabric-panel-open .fabric-drawer__colors-header {
}

#product .details-block.fabric-panel-open .fabric-drawer__legend {
    margin-left: 0;
    margin-right: 0;
}

#product .details-block.fabric-panel-open .fabric-drawer__body {
    padding-left: 0;
    padding-right: 0;
}

#product .details-block.fabric-panel-open > :not(.fabric-drawer),
#product .details-block.fabric-panel-open #add-to-cart-or-refresh > .js-product-variants {
    display: none !important;
}

.fabric-option__texture {
    position: relative;
}

.fabric-option .input-color:checked + label::after {
    content: none;
}

.fabric-option__selected-icon {
    position: absolute;
    top: 4px;
    right: 4px;
    display: none;
    width: 26px;
    height: 26px;
}

.fabric-option .input-color:checked + label .fabric-option__selected-icon {
    display: block;
}

@media (max-width: 767px) {
    #product .fabric-selector > .fabric-selector__trigger .fabric-selector__preview {
        display: block !important;
        width: 48px !important;
        height: 48px !important;
        min-width: 48px;
        flex: 0 0 48px;
        overflow: hidden;
        border-radius: 7px;
        background-color: #eee;
        background-position: center;
        background-repeat: no-repeat;
        background-size: cover;
    }
}
@media (max-width: 767px) {
    #product .fabric-drawer .fabric-drawer__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}
