/* css/services-section.css — стили блока услуг */

/* =====================================================
   СЕКЦИЯ
===================================================== */
.services-section {
    padding: 100px 0;
    background: white;
}

.services-section__header {
    text-align: center;
    margin: 0 auto 60px;
    max-width: 800px;
}

.services-section__title {
    font-size: 2.8rem;
    font-weight: 800;
    margin-bottom: 20px;
    color: #333;
    font-family: var(--font-heading);
}

.services-section__subtitle {
    font-size: 1.2rem;
    color: #666;
    line-height: 1.6;
}

.services-section__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 20px;
}

.services-section__footer {
    text-align: center;
}


/* =====================================================
   КАРТОЧКА УСЛУГ
===================================================== */
.service-preview {
    position: relative;
    padding: 20px;
    min-height: 300px;
    border-radius: 15px;
    background: #f8f9fa;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    text-align: center;

    display: flex;
    flex-direction: column;
    justify-content: space-between;

    transition: all 0.3s ease;
    overflow: hidden;
}

/* Наведение */
.service-preview:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
    border-color: #4CAF50;
}

.service-preview:hover .service-preview__overlay {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.9) 100%);
}

/* =====================================================
   ОВЕРЛЕЙ ФОНА
===================================================== */
.service-preview__overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg,
            rgba(0, 0, 0, 0.7) 0%,
            rgba(0, 0, 0, 0.4) 100%);
    z-index: 1;
}

.service-preview>*:not(.service-preview__overlay):not(.service-preview__badge) {
    position: relative;
    z-index: 2;
    color: #fff;
}


/* =====================================================
   ЭЛЕМЕНТЫ КАРТОЧКИ
===================================================== */

/* Иконка */
.service-preview__icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 25px;
    background: white;
    border-radius: 50%;

    display: flex;
    align-items: center;
    justify-content: center;

    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.service-preview__icon img {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

/* Заголовок */
.service-preview__title {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 15px;
    font-family: var(--font-heading);
}

.service-preview__title a {
    color: #fff;
    text-decoration: none;
}

.service-preview__title a:hover {
    color: #7747D4;
}

/* Текст */
.service-preview__excerpt {
    color: #666;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 20px;
}

.service-preview__price {
    font-size: 1rem;
    font-weight: 400;
    margin-bottom: 25px;
}

.service-preview__actions {
    margin-top: auto;
}


/* =====================================================
   МОДИФИКАТОРЫ
===================================================== */
.service-preview--popular {
    border: 2px solid #7747D4;
    background-color: white;
    box-shadow: 0 10px 30px rgba(76, 175, 80, 0.1);
}

/* Бейдж */
.service-preview__badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #7747D4;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    z-index: 3;
    width: fit-content;
}


/* =====================================================
   АДАПТИВНОСТЬ
===================================================== */
@media (max-width: 1024px) {
    .services-section__grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 25px;
    }
}

@media (max-width: 768px) {
    .services-section {
        padding: 60px 0;
    }

    .services-section__title {
        font-size: 2.2rem;
    }

    .services-section__grid {
        grid-template-columns: 1fr;
    }

    .service-preview {
        padding: 30px 25px;
    }
}

@media (max-width: 480px) {
    .services-section__title {
        font-size: 1.8rem;
    }

    .service-preview {
        padding: 25px 20px;
    }
}