/* ===== БЛОК ПРОЕКТЫ - КОМПАКТНАЯ ВЕРСИЯ ===== */

/* Расстояние между проектами */
.project-item {
    margin-bottom: 5rem !important; /* 80px - увеличенное расстояние между проектами */
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.project-item.fade-in-section {
    opacity: 1;
    transform: translateY(0);
}

/* Убираем стандартные отступы Bootstrap между колонками */
.project-item .row {
    --bs-gutter-y: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 40px;
    margin-left: 0;
    margin-right: 0;
}

/* Ширина колонок */
.project-item .col-12 {
    flex: 0 0 auto;
}

@media (min-width: 992px) {
    .project-item .col-lg-6 {
        width: 45%;
        max-width: 500px;
    }
}

/* Мобильная версия: отступ между слайдером и текстом */
@media (max-width: 992px) {
    .project-item .row {
        flex-direction: column;
        gap: 1.5rem; /* 24px - небольшой отступ внутри проекта */
    }
    
    .project-item .col-lg-6 {
        width: 100%;
        max-width: 550px;
    }
}

/* Слайдер */
.project-swiper {
    position: relative;
    width: 100%;
    overflow: hidden;
}

/* Контейнер слайдов - отступ для радиуса */
.swiper-wrapper {
    padding: 0;
}

/* Индивидуальный радиус для каждого фото */
.slide-image {
    border-radius: 20px;
    overflow: hidden;
    margin-right: 10px;
    height: 100%;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Обертка для изображения */
.slide-image a {
    display: block;
    height: 100%;
    border-radius: 20px;
    overflow: hidden;
}

.project-swiper-img {
    height: 240px;
    width: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
    display: block;
}

.swiper-slide:hover .project-swiper-img {
    transform: scale(1.02);
}

/* Всегда 2 фото на любом разрешении */
.project-swiper .swiper-slide {
    width: 50% !important;
}

.swiper-slide {
    height: auto !important;
}

/* Кнопки навигации Swiper */
.project-swiper .swiper-button-prev,
.project-swiper .swiper-button-next {
    width: 32px;
    height: 32px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    transition: all 0.3s ease;
    margin-top: -16px;
}

.project-swiper .swiper-button-prev {
    left: 5px;
}

.project-swiper .swiper-button-next {
    right: 5px;
}

.project-swiper .swiper-button-prev:hover,
.project-swiper .swiper-button-next:hover {
    background: #ff0000;
}

.project-swiper .swiper-button-prev:after,
.project-swiper .swiper-button-next:after {
    font-size: 14px;
    color: white;
    font-weight: bold;
}

/* Пагинация (точки) */
.project-swiper .swiper-pagination {
    position: relative;
    bottom: auto;
    margin-top: 25px;
    display: flex;
    justify-content: center;
    gap: 10px;
}

.project-swiper .swiper-pagination-bullet {
    width: 8px;
    height: 8px;
    background: #ccc;
    opacity: 1;
    border-radius: 50%;
    margin: 0 !important;
    transition: all 0.2s ease;
}

.project-swiper .swiper-pagination-bullet-active {
    background: #ff0000;
    width: 10px;
    height: 10px;
}

/* Описание проекта */
.project-item h3 {
    font-size: 1.2rem !important;
    margin-bottom: 12px;
    font-weight: 600;
}

.project-item ul {
    margin-bottom: 20px;
    padding-left: 0;
}

.project-item ul li {
    font-size: 0.85rem;
    margin-bottom: 6px;
    color: #555;
}

/* Кнопка */
.project-item .btn {
    padding: 8px 24px;
    font-size: 0.85rem;
    border-radius: 30px;
    width: auto;
    min-width: 160px;
    display: inline-block;
    text-align: center;
}

@media (min-width: 992px) {
    .project-item .btn {
        width: auto !important;
    }
}

/* Отступ для описания */
.project-item .ps-lg-4 {
    padding-left: 0 !important;
}

/* Видео-иконка */
.video-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.7);
    border-radius: 50%;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    pointer-events: none;
}

.video-play-icon svg {
    fill: white;
    width: 22px;
    height: 22px;
}

.swiper-slide:hover .video-play-icon {
    background: #ff0000;
    transform: translate(-50%, -50%) scale(1.1);
}

/* ===== АДАПТИВ ===== */

/* Планшеты */
@media (max-width: 992px) {
    .project-swiper-img {
        height: 280px;
    }
    
    .project-item h3 {
        text-align: center;
        font-size: 1.3rem !important;
    }
    
    .project-item ul {
        text-align: center;
    }
    
    .project-item ul li {
        display: inline-block;
        margin: 0 10px 8px;
    }
    
    .project-item .btn {
        display: block;
        margin: 0 auto;
    }
}

/* Планшеты вертикально */
@media (max-width: 768px) {
    .project-item {
        margin-bottom: 5rem !important;
    }
    
    .project-item h3 {
        font-size: 1.2rem !important;
    }
    
    .project-swiper-img {
        height: 250px;
    }
    
    .swiper-button-prev,
    .swiper-button-next {
        display: flex !important;
    }
}

/* Мобильные телефоны */
@media (max-width: 576px) {
    .project-item {
        margin-bottom: 5rem !important;
    }
    
    .project-item h3 {
        font-size: 1.1rem !important;
    }
    
    .project-swiper-img {
        height: 200px;
    }
    
    .video-play-icon {
        width: 40px;
        height: 40px;
    }
    
    .video-play-icon svg {
        width: 20px;
        height: 20px;
    }
    
    .project-item ul li {
        font-size: 0.8rem;
        display: list-item;
        text-align: left;
    }
    
    .project-item .btn {
        width: 100%;
        font-size: 0.85rem;
    }
    
    .swiper-button-prev,
    .swiper-button-next {
        width: 28px;
        height: 28px;
    }
    
    .swiper-button-prev:after,
    .swiper-button-next:after {
        font-size: 12px;
    }
    
    .project-swiper .swiper-pagination {
        margin-top: 20px;
        gap: 8px;
    }
}

/* Маленькие телефоны */
@media (max-width: 480px) {
    .project-swiper-img {
        height: 180px;
    }
    
    .swiper-wrapper {
        padding: 12px 0;
    }
}