.cards-text-icon-block {
    /* margin: 100px 0; */
    /* padding: 0; */
}

.cards-text-icon-block.has-background {
    margin-left: calc(585px - 50vw);
    margin-right: calc(585px - 50vw);
    max-width: 100vw;
    overflow: hidden;
    padding: 100px calc(50vw - 585px);
    background: #E8E6D4;
}
.cards-text-icon-block.has-background .cards-text-icon-block__title {
    color: #18383C;
}

.cards-text-icon-block.has-background+.cards-text-icon-block.has-background {
    margin-top: -200px;
}

.cards-text-icon-block__header {
    text-align: center;
}

.cards-text-icon-block__title {
    color: #E8E6D4;
}

.cards-text-icon-block__cards {
    display: grid;
    gap: 10px;
    margin-bottom: 30px;
}

.cards-text-icon-block__card.content-text {
    display: flex;
    padding: 40px 20px;
    flex-direction: column;
    align-items: flex-start;
    gap: 30px;
    flex: 1 0 0;
    border-radius: 8px;
    border: 1px solid rgba(132, 168, 172, 0.60);
    background: rgba(132, 168, 172, 0.20);
}

.orientation-horizontal .cards-text-icon-block__card-icon-img {
    width: 30px;
    height: 30px;
}

/* Количество карточек в ряд */
.cards-text-icon-block.cards-per-row-1 .cards-text-icon-block__cards {
    grid-template-columns: 1fr;
}

.cards-text-icon-block.cards-per-row-2 .cards-text-icon-block__cards {
    grid-template-columns: repeat(2, 1fr);
}

.cards-text-icon-block.cards-per-row-3 .cards-text-icon-block__cards {
    grid-template-columns: repeat(3, 1fr);
}

.cards-text-icon-block.cards-per-row-4 .cards-text-icon-block__cards {
    grid-template-columns: repeat(4, 1fr);
}

.cards-text-icon-block.cards-per-row-5 .cards-text-icon-block__cards {
    grid-template-columns: repeat(5, 1fr);
}

.cards-text-icon-block.cards-per-row-6 .cards-text-icon-block__cards {
    grid-template-columns: repeat(6, 1fr);
}

/* Горизонтальная ориентация */
.cards-text-icon-block.orientation-horizontal .cards-text-icon-block__card {
    display: flex;
    align-items: center;
    gap: 15px;
    text-align: left;
    flex-direction: row;
    padding: 20px;
}

.cards-text-icon-block.orientation-horizontal .cards-text-icon-block__card-icon {
    flex-shrink: 0;
    width: 30px;
    height: 30px;
}

/* Вертикальная ориентация */
.cards-text-icon-block.orientation-vertical .cards-text-icon-block__card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    gap: 30px;
}

/* Контент только картинка для отдельных карточек */
.cards-text-icon-block__card.content-image {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.cards-text-icon-block__card {
    padding: 40px 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-radius: 6px;
    border: 1px solid rgba(232, 230, 212, 0.20);
    background: rgba(118, 130, 74, 0.10);
}

.cards-text-icon-block__card-icon {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    margin-bottom: 0;
}

.cards-text-icon-block.orientation-vertical .cards-text-icon-block__card-icon {
    margin-bottom: 0;
}

.cards-text-icon-block__card-icon-img {
    width: 50px;
    height: 50px;
    object-fit: contain;
}

.cards-text-icon-block .cards-text-icon-block__card.content-image {
    background: transparent;
    padding: 0;
    position: relative;
}

.cards-text-icon-block .cards-text-icon-block__card.content-image .cards-text-icon-block__card-icon {
    position: absolute;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
}

.cards-text-icon-block .cards-text-icon-block__card.content-image .cards-text-icon-block__card-icon img {
    position: absolute;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.cards-text-icon-block__card-content {
    flex: 1;
}

.cards-text-icon-block__card-title {
    color: #E8E6D4;
    font-size: 20px;
    font-style: italic;
    font-weight: 600;
    margin: 0 0 10px 0;
}

.cards-text-icon-block__card-text {
    color: #E8E6D4;
    font-size: 16px;
    font-weight: 500;
}

.has-background.cards-text-icon-block .cards-text-icon-block__card {
    border-radius: 8px;
    border: 1px solid rgba(118, 130, 74, 0.60);
    background: rgba(118, 130, 74, 0.05);
}

.has-background .cards-text-icon-block__card-title,
.has-background .cards-text-icon-block__card-text {
    color: #18383C;
}

.has-background .cards-text-icon-block__card.highlighted {background: var(--color-text-green);}

.has-background .cards-text-icon-block__card.highlighted .cards-text-icon-block__card-title,
.has-background .cards-text-icon-block__card.highlighted .cards-text-icon-block__card-text {
    color: var(--color-text-green);
}

.has-background .cards-text-icon-block__card.highlighted .cards-text-icon-block__card-title,
.has-background .cards-text-icon-block__card.highlighted .cards-text-icon-block__card-text {
    color: #fff;
}

.cards-text-icon-block__button-container {
    display: flex;
    justify-content: center;
}

.cards-text-icon-block__footnote {
    border-radius: 8px;
    background: var(--color-text-green);
    color: #E8E6D4;
    text-align: center;
    font-size: 16px;
    line-height: normal;
    padding: 10px 20px;
    display: block;
    margin: auto;
    width: max-content;
    margin-top: 30px;
}

.cards-text-icon-block.layout-center-image .cards-text-icon-block__layout {
    display: flex;
    gap: 10px;
}

.cards-text-icon-block.layout-center-image .cards-text-icon-block__column {
    display: flex;
    gap: 10px;
    flex-direction: column;
}

.cards-text-icon-block.layout-center-image .cards-text-icon-block__column {
    flex: 1;
}

/* Стили для разного количества карточек во втором ряду */
.cards-text-icon-block.second-row-2 .cards-text-icon-block__column:last-child {
    /* 2 карточки во втором ряду - стандартное поведение */
}

.cards-text-icon-block.second-row-3 .cards-text-icon-block__column:last-child {
    /* 3 карточки во втором ряду - карточки располагаются в 2 ряда */
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.cards-text-icon-block.second-row-3 .cards-text-icon-block__column:last-child .cards-text-icon-block__card:nth-child(3) {
    /* Третья карточка занимает всю ширину */
    grid-column: 1 / -1;
}

.cards-text-icon-block.layout-center-image .cards-text-icon-block__card.content-image {
    height: 100%;
}

/* Адаптивность */
@media (max-width: 1220px) {

    .text-image-block.has-background,
    .cards-text-icon-block.has-background {
        margin-left: -20px;
        margin-right: -20px;
        padding: 80px 20px;
    }
}

@media (max-width: 1024px) {}

@media (max-width: 768px) {

    .cards-text-icon-block.layout-center-image .cards-text-icon-block__layout,
    .cards-text-icon-block__cards {
        display: flex;
        margin-bottom: 10px;
        gap: 10px;
        flex-direction: column;
    }

    .cards-text-icon-block .cards-text-icon-block__card.content-image .cards-text-icon-block__card-icon img,
    .cards-text-icon-block .cards-text-icon-block__card.content-image .cards-text-icon-block__card-icon {
        position: relative;
    }

    /* На мобильных устройствах все карточки в одну колонку */
    .cards-text-icon-block.second-row-3 .cards-text-icon-block__column:last-child {
        display: flex;
        flex-direction: column;
    }

    .cards-text-icon-block.second-row-3 .cards-text-icon-block__column:last-child .cards-text-icon-block__card:nth-child(3) {
        grid-column: unset;
    }
    .cards-text-icon-block__footnote{
        width: 100%;
    }
}

@media (max-width: 488px) {}