html {
    scroll-behavior: smooth;
  }
/* Стили для галереи */
.mediaGalleryContainer {
    display: flex;
    flex-direction: column;
    margin-top: 5rem;
    margin-bottom: 5rem;
}
.galleryContainer {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
}
.gallery {
    display: flex;
    align-items: center; /* Центрируем миниатюры относительно основного изображения */
    margin-right: 1rem;
}
.thumbnails-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-height: 462px; /* Ограничиваем высоту контейнера миниатюр */
    overflow: hidden;
}
.thumbnails {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-right: 1rem;
    overflow-y: auto;
    max-height: 100%;
    scrollbar-width: none; /* Firefox */
}

.thumbnails img {
    width: 120px;
    height: 120px;
    padding: .5rem;
    border: 1px solid #dbdbdb;
    cursor: pointer;
    box-sizing: border-box; /* Чтобы бордер был снаружи */
}
/* Стиль для кнопок прокрутки */
.scroll-button {
    background-color: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    width: 40px;
    height: 40px;
}

.scroll-button-icon {
    fill: rgb(229 229 229);
    width: 24px;
    height: 24px;
}

/* Шеврон вверх */
.scroll-button-up .scroll-button-icon {
    transform: rotate(-90deg);
}

/* Шеврон вниз */
.scroll-button-down .scroll-button-icon {
    transform: rotate(90deg);
}


.main-photo {
    width: 462px; /* Устанавливаем ширину контейнера */
    height: 462px; /* Устанавливаем высоту контейнера */
    border: 1px solid #dbdbdb;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box; /* Чтобы бордер был снаружи */
    padding: .5rem;
}
.main-photo img {
    display: block;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain; /* Вписываем изображение в контейнер без искажений */
    transition: transform 0.3s ease;
    margin: .5rem;
}
.main-photo img:hover {
    transform: scale(1.1);
}
.product-data {
    flex: 1;
}
.product-data h3 {
    margin: 0;
    margin-bottom: .5rem;
}
.product-data p {
    margin: 0;
    max-width: 40rem;
    font-family: 'Rotis Sans Serif Pro Cyr', sans-serif;
}
.product-data ul {
    margin: 0;
    max-width: 40rem;
    font-size: 1rem;
    font-family: 'Rotis Sans Serif Pro Cyr', sans-serif;
    line-height: 1.375rem;
}
.product-data-p {
    margin: 0;
    max-width: 40rem;
    font-weight: 700;
    font-family: 'Rotis Sans Serif Pro Cyr', sans-serif;
    font-size: 1.375rem;
    line-height: 1.875rem;
}
.product-data li {
    margin-bottom: .5rem;
}
.product-data-read {
    cursor: pointer;
    font-weight: 700;
    font-family: arial;
    font-size: 1rem;
}
/* Планшеты */
@media (max-width: 768px) {
    .galleryContainer {
        flex-direction: column;
        align-items: center;
    }
    .gallery {
        margin-right: 0;
        margin-bottom: 1rem;
    }
    .main-photo {
        width: 100%;
        height: auto;
    }
    .main-photo img {
        width: 100%;
        height: auto;
        margin: 0;
    }
}

/* Мобильные устройства */
@media (max-width: 480px) {
    .mediaGalleryContainer {
        align-items: center;
    }
    .galleryContainer {
        flex-direction: column;
        align-items: center;
    }
    .thumbnails {
        display: none; /* Скрываем миниатюры на мобильных устройствах */
    }
    .thumbnails-container {
        display: none; /* Скрываем миниатюры на мобильных устройствах */
    }
    .main-photo {
        width: 100%;
        height: auto;
        margin-bottom: 1rem;
    }
    .main-photo img {
        width: 100%;
        height: auto;
        margin: 0;
    }
    .product-data {
        width: 100%;
    }
    .product-data p {
        max-width: 100%;
    }

    .mobile-navigation button {
        background-color: rgb(0 169 122);
        border: none;
        color: white;
        padding: 0.5rem;
        margin: 0 0.5rem;
        cursor: pointer;
        border-radius: 50%;
    }
    .image-indicators {
        display: flex;
        justify-content: center;
        margin-top: 1rem;
    }
    .image-indicator {
        width: 10px;
        height: 10px;
        background-color: lightgray;
        border-radius: 50%;
        margin: 0 5px;
        transition: background-color 0.3s;
    }
    .image-indicator.active {
        background-color: rgb(0 169 122);
    }
}

.accordion__header {
    background-color: #eee;
    color: #444;
    cursor: pointer;
    padding: 1rem;
    border: none;
    text-align: left;
    outline: none;
    font-size: 15px;
    transition: 0.4s;
    margin-bottom: .25rem;
}

.accordion__header h4 {
    font-weight: 700;
    margin: 0;
    font-size: 1.25rem;
    font-family: 'Arial';
}

.accordion__header::after {
    flex-shrink: 0;
    width: 1.25rem;
    height: 1.25rem;
    margin-left: auto;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23ffffff'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-size: 1.25rem;
    content: "";
}

.accordion__item_show .accordion__header::after {
    transform: rotate(-180deg);
}

.accordion__body {
    padding: 0 18px;
    background-color: white;
    display: none;
    overflow: hidden;
}

.accordion__item_show .accordion__body {
    display: block;
}


/* Стили для контейнера табов */
.container-tab {
    margin-top: 7rem;
}

/* Стили для списка табов */
.tab__list {
    display: flex;
    align-items: center;
    margin: 0;
    padding: 0;
    list-style-type: none;
    border-bottom: 1px solid;
    border-bottom-color: rgb(219, 219, 219);
}

/* Дополнительные стили для элементов списка табов */
.tab__list ul {
    padding-top: 1rem;
}

/* Стили для каждого элемента списка табов */
.tab__list-item {
    min-width: 150px;
    text-align: center;
    cursor: pointer;
    padding-left: 1rem;
    padding-right: 1rem;
    font-family: 'Rotis Sans Serif Pro Cyr', sans-serif;
    font-weight: bold;
    font-size: 24px;
    color: rgb(110, 110, 110);
    border-bottom: 2px solid transparent; /* Убираем нижнее подчеркивание у неактивных табов */
}

/* Стили для элемента списка табов при наведении */
.tab__list-item:hover {
    background-color: #e5f4ff;
}

/* Стили для активного элемента списка табов */
.tab__list-item_selected {
    background: #fff;
    border-bottom: 2px solid rgb(0, 169, 122);
    color: rgb(0, 169, 122);
}

/* Стили для контейнера контента табов */
.tab__content {
    margin-top: 2.5rem;
}

/* Скрываем контент элементов по умолчанию */
.tab__content-item {
    display: none;
}

/* Отображаем контент активного элемента */
.tab__content-item_selected {
    display: block;
}

/* Стили для документов */
.product-documents {
    margin-top: 2rem;
}

.document-list-view__info {
    display: flex;
    justify-content: space-between;
    padding-top: 1rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid;
    border-bottom-color: rgb(219, 219, 219);
}

.document-list-view__text {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.document-list-view__text p {
    margin: 0;
}

.document-title {
    font-weight: 700;
}

.document-description {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 1rem;
}

.document-meta {
    color: #6b7280;
    font-size: .875rem;
    line-height: 1.25rem;
}

.document-meta p {
    margin-right: 0.5rem;
}

.document-list-view__widgets {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.download-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 3.25rem;
    height: 3.25rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
}

.download-button:hover {
    border-color: #9e2ab5;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1);
    color: #9e2ab5;
}

.download-button svg {
    width: 1.5rem;
    height: 1.5rem;
    fill: rgb(110, 110, 110); /* Начальный цвет svg */
    transition: fill 0.2s ease-in-out;
}

.download-button:hover svg {
    fill: #9e2ab5; /* Цвет svg при наведении */
}

.download-button:focus,
.download-button:active {
    border-color: rgb(110, 110, 110);
    background-color: #e5f4ff;
    color: rgb(110, 110, 110);
}

.related-products {
    margin-top: 4rem;
}

.related-products-container {
    display: flex;
    flex-wrap: wrap; /* Добавлено для правильного расположения карточек */
    justify-content: space-between; /* Равномерное распределение карточек */
}

.related-product-link {
    text-decoration: none; /* Убирает подчеркивание у ссылок */
    color: inherit; /* Сохраняет цвет текста */
    width: calc(25% - 1rem); /* Четыре карточки в ряд с учетом отступов */
    margin-bottom: 1rem; /* Отступ между рядами карточек */
}

.related-product-item {
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    padding: .5rem;
    height: auto;
    display: flex;
    flex-direction: column;
    overflow: hidden; /* Добавлено для корректного отображения содержимого */
}

.related-product-img {
    flex-shrink: 0; /* Запрещает уменьшение изображения */
}

.related-product-img img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
}

.related-product-item-text {
    border-top: 1px solid rgb(229 229 229);
    padding-top: .5rem;
}

.related-product-item h4 {
    font-size: 1rem !important; 
    margin: 0 !important;
    font-family: Arial !important;
}

.related-product-item p {
    font-size: 14px;
    color: rgb(51 51 51);
    margin: .5rem 0 0 0; /* Отступы вокруг текста */
}

/* Стили для планшетов (768px - 1024px) */
@media (max-width: 1024px) {
    .related-product-link {
        flex: 1 1 calc(33.33% - 1rem); /* Три карточки в ряд с учетом отступов */
        max-width: calc(33.33% - 1rem);
    }
}

/* Стили для мобильных устройств (меньше 768px) */
@media (max-width: 768px) {
    .related-product-link {
        flex: 1 1 100%; /* Одна карточка в ряд */
        max-width: 100%;
    }
}
