.options-gallery {
    padding-block: 40px;
}

.options-gallery__container {
    width: min(100% - 32px, 1455px);
    margin-inline: auto;
}

.options-gallery__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 20px;
}

.options-gallery__title {
    margin: 0;
    font-size: clamp(24px, 3vw, 36px);
    line-height: 1.2;
}

.options-gallery__controls {
    display: none;
    gap: 8px;
    margin-inline-start: auto;
    flex-shrink: 0;
}

.options-gallery.is-initialized .options-gallery__controls {
    display: flex;
}

.options-gallery__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 1px solid #d6d6d6;
    border-radius: 50%;
    background: #fff;
    color: #222;
    font: inherit;
    font-size: 24px;
    cursor: pointer;
}

.options-gallery__button:disabled {
    opacity: 0.35;
    cursor: default;
}

.options-gallery__slider {
    overflow: hidden;
}

/* Readable horizontal gallery if Swiper is unavailable or JavaScript is disabled. */
.options-gallery:not(.is-initialized) .swiper-wrapper {
    display: flex;
    gap: 16px;
    overflow-x: auto;
}

.options-gallery:not(.is-initialized) .swiper-slide {
    width: 85%;
    flex: 0 0 85%;
}

.options-gallery__link {
    display: block;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-radius: 12px;
    background: #f4f4f4;
}

.options-gallery__link .options-gallery__image {
    display: block;
    width: 100%;
    height: 100%;
    max-width: 100%;
    margin: 0;
    object-fit: cover;
}

.options-gallery__button:focus-visible,
.options-gallery__link:focus-visible {
    outline: 3px solid #2364d2;
    outline-offset: -3px;
}

@media (min-width: 768px) {
    .options-gallery:not(.is-initialized) .swiper-slide {
        width: calc((100% - 16px) / 2);
        flex-basis: calc((100% - 16px) / 2);
    }
}

@media (min-width: 1024px) {
    .options-gallery:not(.is-initialized) .swiper-wrapper {
        gap: 24px;
    }

    .options-gallery:not(.is-initialized) .swiper-slide {
        width: calc((100% - 72px) / 4);
        flex-basis: calc((100% - 72px) / 4);
    }
}


/* SEO +++++ */

.seo-text__inner {
    display: flow-root;
}

/* Обмеження застосовується після запуску JS. */
.section-content.is-toggle-ready .seo-text__viewport {
    position: relative;
    overflow: hidden;
    max-height: var(--seo-collapsed-height);
    transition: max-height 0.35s ease;
}

.section-content.is-expanded .seo-text__viewport {
    max-height: var(--seo-full-height);
}

/* Колір градієнта має відповідати фону секції. */
.section-content.is-toggle-ready:not(.is-expanded)
.seo-text__viewport::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 48px;
    background: linear-gradient(
        to bottom,
        transparent,
        var(--seo-background, #fff)
    );
    pointer-events: none;
}

.seo-text__toggle:not([hidden]) {
    display: inline-flex;
    margin-top: 16px;
    padding: 10px 20px;
    border: 1px solid currentColor;
    border-radius: 6px;
    background: transparent;
    color: inherit;
    font: inherit;
    cursor: pointer;
}

.seo-text__toggle:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
    .section-content.is-toggle-ready .seo-text__viewport {
        transition: none;
    }
}

/* Кнопка розгортання SEO-тексту */
.section-content[data-seo-toggle] .seo-text__toggle:not([hidden]) {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;

    width: fit-content;
    max-width: 100%;
    min-height: 48px;
    box-sizing: border-box;
    margin: 24px auto 0;
    padding: 13px 24px;

    border: 2px solid #ff0b0b;
    border-radius: 100px;
    background: #fff;
    color: #ff0b0b;

    font: inherit;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
    text-align: center;
    cursor: pointer;

    transition: background-color .2s ease, color .2s ease;
}

/* Стрілка вниз */
.section-content[data-seo-toggle] .seo-text__toggle::after {
    content: "";
    display: block;
    flex-shrink: 0;
    width: 8px;
    height: 8px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: translateY(-2px) rotate(45deg);
    transition: transform .2s ease;
}

/* Стрілка вгору після відкриття */
.section-content[data-seo-toggle]
.seo-text__toggle[aria-expanded="true"]::after {
    transform: translateY(2px) rotate(225deg);
}

@media (hover: hover) {
    .section-content[data-seo-toggle] .seo-text__toggle:hover {
        background: #ff0b0b;
        color: #fff;
    }
}

.section-content[data-seo-toggle] .seo-text__toggle:focus-visible {
    outline: 2px solid #334250;
    outline-offset: 4px;
}

@media (max-width: 575px) {
    .section-content[data-seo-toggle] .seo-text__toggle:not([hidden]) {
        margin-top: 20px;
        padding: 12px 20px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .section-content[data-seo-toggle] .seo-text__toggle,
    .section-content[data-seo-toggle] .seo-text__toggle::after {
        transition: none;
    }
}