/* По умолчанию показываем десктопный текст, скрываем мобильный */
.benefit-text.mobile-text {
    display: none;
}

.benefit-text.desktop-text {
    display: block;
}

/* На мобильных - наоборот */
@media (max-width: 768px) {
    .benefit-text.mobile-text {
        display: block;
    }

    .benefit-text.desktop-text {
        display: none;
    }
}

/* Основные стили секции */
.benefits-section {
    background-color: #131316;
    color: var(--color-primary);
    padding: 80px 0;
    position: relative;
}

.benefits-header {
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
}

.benefits-badge {
    color: var(--color-accent);
    font-size: 16px;
    font-family: 'Geologica', sans-serif;
    font-weight: 500;
    text-transform: uppercase;
    line-height: 16px;
    letter-spacing: 0.48px;
}

.benefits-title {
    color: var(--color-primary);
    font-size: 32px;
    font-family: 'Dela Gothic One', cursive;
    font-weight: 400;
    line-height: 38.4px;
    letter-spacing: 0.96px;
    margin: 0;
    text-align: center;
}

/* Скрываем мобильный заголовок на десктопе */
.mobile-header {
    display: none;
}

/* Десктопный заголовок по центру */
.desktop-header {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    pointer-events: none;
}

/* Сетка преимуществ */
.benefits-grid {
    position: relative;
    max-width: 1273px;
    height: 762px;
    margin: 0 auto;
}

.benefits-row {
    position: absolute;
    display: flex;
    gap: 18px;
}

/* Позиционирование строк */
.benefits-row-1 {
    top: 0;
    left: 0;
    right: 0;
}

.benefits-row-2 {
    top: 226px;
    left: 0;
    right: 0;
}

.benefits-row-3 {
    bottom: 0;
    left: 0;
    right: 0;
}

/* Базовые стили карточек преимуществ */
.benefit-item {
    background: rgba(250, 250, 250, 0.02);
    border-radius: 16px;
    border: 2px solid rgba(250, 250, 250, 0.06);
    overflow: hidden;
    position: relative;
    transition: all 0.3s ease;
}

.benefit-item:hover {
    border-color: rgba(250, 250, 250, 0.12);
    background: rgba(250, 250, 250, 0.04);
}

.benefit-content {
    position: relative;
    width: 100%;
    height: 100%;
    padding: 32px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.benefit-text {
    color: #E4E4E7;
    font-size: 16px;
    font-family: 'Dela Gothic One', cursive;
    font-weight: 400;
    line-height: 22.4px;
    margin: 0;
    word-wrap: break-word;
    position: relative;
    z-index: 2;
}

.benefit-icon {
    position: absolute;
    z-index: 1;
}

/* Специфичные размеры для каждой карточки */
.benefit-1 {
    width: 685px;
    height: 208px;
}

.benefit-1 .benefit-icon {
    right: 32px;
    top: 17px;
    width: 169px;
}

.benefit-1 .benefit-text {
    max-width: 299px;
}

.benefit-2 {
    width: 575px;
    height: 208px;
}

.benefit-2 .benefit-icon {
    right: 32px;
    top: 0;
    width: 208px;
}

.benefit-2 .benefit-text {
    max-width: 299px;
}

.benefit-3 {
    width: 392px;
    height: 284px;
}

.benefit-3 .benefit-content {
    justify-content: flex-end;
}

.benefit-3 .benefit-icon {
    left: 30px;
    top: 40px;
    width: 280px;
}

.benefit-3 .benefit-text {
    max-width: 255px;
}

.benefit-4 {
    width: 392px;
    height: 284px;
    margin-left: auto;
}

.benefit-4 .benefit-content {
    justify-content: flex-end;
}

.benefit-4 .benefit-icon {
    right: 5px;
    top: 0;
    width: 225px;
}

.benefit-4 .benefit-text {
    max-width: 309px;
}

.benefit-5 {
    width: 432px;
    height: 234px;
}

.benefit-5 .benefit-icon {
    right: 0px;
    top: -8px;
    width: 216px;
}

.benefit-5 .benefit-text {
    max-width: 218px;
}

.benefit-6 {
    width: 451px;
    height: 234px;
}

.benefit-6 .benefit-content {
    justify-content: flex-start;
}

.benefit-6 .benefit-icon {
    right: 0px;
    bottom: 10px;
    width: 188px;
}

.benefit-6 .benefit-text {
    max-width: 255px;
}

.benefit-7 {
    width: 352px;
    height: 234px;
    margin-left: auto;
}

.benefit-7 .benefit-icon {
    right: 33px;
    top: 27px;
    width: 112px;
}

.benefit-7 .benefit-text {
    max-width: 277px;
}

/* Планшетная версия */
@media (max-width: 1280px) {
    .benefits-grid {
        max-width: 100%;
        height: auto;
        display: grid;
        grid-template-columns: 1fr 1fr;
        grid-gap: 20px;
        padding: 0 20px;
    }

    .benefits-row {
        position: relative;
        display: contents;
    }

    .desktop-header {
        position: relative;
        top: auto;
        left: auto;
        transform: none;
        margin-bottom: 40px;
    }

    .benefit-item {
        width: 100% !important;
        height: 250px !important;
        margin: 0 !important;
    }

    .benefit-content {
        justify-content: center !important;
        align-items: center;
        text-align: center;
        gap: 20px;
    }

    .benefit-icon {
        position: relative !important;
        top: auto !important;
        left: auto !important;
        right: auto !important;
        bottom: auto !important;
        max-width: 120px;
        height: auto;
    }

    .benefit-text {
        max-width: none !important;
        text-align: center;
        font-size: 14px;
        line-height: 19.6px;
    }
}

/* Мобильная версия */
@media (max-width: 768px) {
    .benefits-section {
        padding: 60px 0;
    }

    .desktop-header {
        display: none;
    }

    .mobile-header {
        display: flex;
        margin-bottom: 32px;
    }

    .benefits-badge {
        font-size: 14px;
        line-height: 14px;
        letter-spacing: 0.42px;
    }

    .benefits-title {
        font-size: 24px;
        line-height: 28.8px;
        letter-spacing: 0.72px;
    }

    .benefits-grid {
        display: flex;
        flex-direction: column;
        gap: 16px;
        padding: 0;
    }

    .benefits-row {
        position: relative;
        display: contents;
    }

    .benefit-item {
        width: 100% !important;
        height: 206px !important;
        margin: 0 !important;
    }

    .benefit-content {
        padding: 20px;
        justify-content: flex-end !important;
        align-items: flex-start;
        text-align: center;
        gap: 0;
    }

    .benefit-icon {
        position: absolute !important;
        top: 8px !important;
        left: 50% !important;
        right: auto !important;
        bottom: auto !important;
        transform: translateX(-50%);
        width: 107px !important;
        height: 107px !important;
        object-fit: contain;
    }

    .benefit-text {
        max-width: none !important;
        text-align: center;
        font-size: 14px;
        line-height: 19.6px;
        margin-top: auto;
        padding-top: 120px;
    }
}

/* Очень маленькие экраны */
@media (max-width: 576px) {
    .benefits-section {
        padding: 40px 0;
    }

    .benefits-title {
        font-size: 20px;
        line-height: 24px;
    }

    .benefit-item {
        height: 180px !important;
    }

    .benefit-content {
        padding: 16px;
    }

    .benefit-icon {
        width: 90px !important;
        height: 90px !important;
    }

    .benefit-text {
        font-size: 13px;
        line-height: 18.2px;
        padding-top: 100px;
    }
}