/* =========================================================
   STANKI-M — PROMOTIONS
   Единая таблица стилей карточек акций
========================================================= */

/* Общая страница */

.stm-promotions {
    width: 100%;
    margin: 0 auto;
}

.stm-promotions__heading {
    display: none !important;
}

.stm-promotions__intro {
    margin: 0 0 30px;
    color: #333;
    font-size: 17px;
    line-height: 1.6;
}

.stm-promotions__list {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* =========================================================
   ВНЕШНЯЯ КАРТОЧКА
========================================================= */

.stm-promotion-card {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: flex-start;

    box-sizing: border-box;
    width: 100%;
    min-height: 520px;

    padding: 45px;

    overflow: hidden;
    isolation: isolate;

    border-radius: 0;
    background-color: #e9eef8;
    background-position: center right;
    background-repeat: no-repeat;
    background-size: cover;

    box-shadow: 0 14px 38px rgba(0, 20, 75, .13);
}

/* Декоративная световая линия */

.stm-promotion-card::after {
    content: "";
    position: absolute;
    z-index: 0;
    top: -100%;
    left: -35%;

    width: 24%;
    height: 300%;

    pointer-events: none;
    transform: rotate(28deg);

    background: linear-gradient(
        90deg,
        transparent,
        rgba(49, 92, 255, .13),
        rgba(255, 255, 255, .42),
        transparent
    );

    animation: stmPromotionLight 8s ease-in-out infinite;
}

@keyframes stmPromotionLight {
    0%, 55% {
        left: -35%;
        opacity: 0;
    }

    65% {
        opacity: 1;
    }

    100% {
        left: 120%;
        opacity: 0;
    }
}

/* =========================================================
   ДИАГОНАЛЬНАЯ АКЦИОННАЯ ЛЕНТА
========================================================= */

.stm-promotion-card__ribbon {
    position: absolute;
    z-index: 3;

    top: 38px;
    right: -80px;
    bottom: auto;
    left: auto;

    display: flex;
    align-items: center;
    justify-content: center;

    box-sizing: border-box;
    width: 290px;
    height: 68px;
    min-height: 0;

    padding: 7px 80px;

    overflow: visible;

    color: #fff;
    text-align: center;
    text-transform: uppercase;

    font-size: 10px;
    line-height: 1.2;
    font-weight: 900;
    letter-spacing: .5px;

    white-space: normal;
    overflow-wrap: normal;
    word-break: normal;

    writing-mode: horizontal-tb;
    text-orientation: mixed;

    transform: rotate(45deg);
    transform-origin: center center;

    border: 1px solid #ffd34d;
    border-radius: 2px;

    background: linear-gradient(
        90deg,
        #850000,
        #d00000,
        #ff3030,
        #d00000,
        #850000
    );

    box-shadow: 0 4px 13px rgba(80, 0, 0, .3);
    text-shadow: 0 1px 2px rgba(0, 0, 0, .4);
}

.stm-promotion-card__ribbon::after {
    display: none !important;
}

/* =========================================================
   ТЕКСТОВАЯ ПАНЕЛЬ
========================================================= */

.stm-promotion-card__content {
    position: relative;
    z-index: 1;

    box-sizing: border-box;
    width: 100%;
    max-width: 740px;

    padding: 28px 32px 30px;

    color: #000;

    background: rgba(255, 255, 255, .78);
    border: 1px solid rgba(0, 27, 114, .8);
    border-radius: 13px;

    box-shadow: 0 12px 35px rgba(0, 18, 70, .13);

    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);

    margin-top: 0;
    margin-bottom: 0;
    align-self: center;
}

/* Заголовок */

.stm-promotion-card__title {
    position: relative;

    margin: 0 0 17px;
    padding-bottom: 15px;

    color: #000 !important;

    font-size: 36px;
    line-height: 1.13;
    font-weight: 900;
    letter-spacing: -.7px;
}

.stm-promotion-card__title::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;

    width: 105px;
    height: 4px;

    border-radius: 5px;
    background: linear-gradient(90deg, #001b72, #315cff);
}

/* Описание */

.stm-promotion-card__description {
    margin: 0 0 20px;

    color: #000 !important;

    font-size: 17px;
    line-height: 1.6;
    font-weight: 500;
}

/* =========================================================
   ТРИ ЦЕНОВЫХ БЛОКА
========================================================= */

.stm-promotion-card__prices {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: stretch;

    gap: 10px;
    width: 100%;
    margin: 0 0 23px;
}

.stm-promotion-card__price-old,
.stm-promotion-card__price-new,
.stm-promotion-card__saving {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    box-sizing: border-box;
    min-width: 0;
    min-height: 82px;

    margin: 0;
    padding: 10px 8px;

    text-align: center;
}

/* Цена по прайсу */

.stm-promotion-card__price-old {
    gap: 3px;

    border: 1px solid rgba(0, 27, 114, .14);
    border-radius: 8px;

    background: rgba(255, 255, 255, .65);
}

.stm-promotion-card__price-old .stm-promotion-card__price-label {
    color: #333 !important;

    font-size: 10px;
    line-height: 1.3;
    font-weight: 700;
    text-align: center;
    text-transform: uppercase;
}

.stm-promotion-card__price-old strong {
    color: #000 !important;

    font-size: 20px;
    line-height: 1.2;
    font-weight: 800;

    text-decoration: line-through;
    text-decoration-color: #c90000;
    text-decoration-thickness: 2px;

    white-space: nowrap;
}

/* Цена по акции */

.stm-promotion-card__price-new {
    gap: 3px;

    color: #fff;

    border: 1px solid rgba(0, 27, 114, .2);
    border-radius: 8px;

    background: linear-gradient(115deg, #001b72, #315cff);
    box-shadow: 0 6px 16px rgba(0, 27, 114, .2);
}

.stm-promotion-card__price-new .stm-promotion-card__price-label {
    color: rgba(255, 255, 255, .85);

    font-size: 10px;
    line-height: 1.3;
    font-weight: 700;
    text-align: center;
    text-transform: uppercase;
}

.stm-promotion-card__price-new strong {
    color: #fff;

    font-size: 23px;
    line-height: 1.15;
    font-weight: 900;

    white-space: nowrap;
}

/* Экономия */

.stm-promotion-card__saving {
    gap: 5px;

    width: auto;
    max-width: none;

    color: #fff;

    border: 1px solid rgba(255, 211, 77, .35);
    border-radius: 8px;

    background: linear-gradient(115deg, #970000, #e00000, #ff3434);
    box-shadow: 0 5px 14px rgba(180, 0, 0, .2);
}

.stm-promotion-card__saving span {
    color: rgba(255, 255, 255, .92);

    font-size: 10px;
    line-height: 1.3;
    font-weight: 800;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.stm-promotion-card__saving strong {
    color: #fff;

    font-size: 23px;
    line-height: 1.15;
    font-weight: 900;

    white-space: nowrap;
}

/* =========================================================
   КНОПКА
========================================================= */

.stm-promotion-card__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 18px;

    min-height: 52px;
    box-sizing: border-box;

    padding: 13px 24px;

    color: #fff !important;

    font-size: 15px;
    line-height: 1.2;
    font-weight: 800;

    text-decoration: none !important;

    border: 1px solid #001b72;
    border-radius: 7px;

    background: linear-gradient(110deg, #001b72, #1239bd);
    box-shadow: 0 7px 18px rgba(0, 27, 114, .2);

    transition:
        transform .25s ease,
        box-shadow .25s ease,
        background .25s ease;
}

.stm-promotion-card__button::after {
    content: "→";

    font-size: 22px;
    line-height: 1;

    transition: transform .25s ease;
}

.stm-promotion-card__button:hover {
    color: #fff !important;

    transform: translateY(-3px);

    background: linear-gradient(110deg, #1239bd, #315cff);
    box-shadow: 0 11px 24px rgba(0, 27, 114, .3);
}

.stm-promotion-card__button:hover::after {
    transform: translateX(5px);
}

/* =========================================================
   ПЛАНШЕТЫ
========================================================= */

@media (max-width: 768px) {

    .stm-promotions__heading {
        font-size: 29px;
    }

    .stm-promotion-card {
        min-height: 480px;
        padding: 45px 22px;

        background-position: center;
    }

    .stm-promotion-card__ribbon {
        top: 29px;
        right: -77px;

        width: 260px;
        height: 60px;

        padding: 6px 72px;
        font-size: 9px;
    }

    .stm-promotion-card__content {
        max-width: 100%;
        padding: 24px 22px;
    }

    .stm-promotion-card__title {
        font-size: 30px;
    }

    .stm-promotion-card__prices {
        gap: 7px;
    }

    .stm-promotion-card__price-old,
    .stm-promotion-card__price-new,
    .stm-promotion-card__saving {
        min-height: 76px;
        padding: 8px 5px;
    }

    .stm-promotion-card__price-old strong {
        font-size: 17px;
    }

    .stm-promotion-card__price-new strong,
    .stm-promotion-card__saving strong {
        font-size: 19px;
    }
}

/* =========================================================
   ТЕЛЕФОНЫ
========================================================= */

@media (max-width: 480px) {

    .stm-promotions__heading {
        font-size: 25px;
    }

    .stm-promotions__intro {
        font-size: 15px;
    }

    .stm-promotions__list {
        gap: 20px;
    }

    .stm-promotion-card {
        min-height: 0;
        padding: 35px 12px;

        background-position: center;
    }

    .stm-promotion-card__ribbon {
        top: 24px;
        right: -78px;

        width: 245px;
        height: 56px;

        padding: 5px 68px;

        font-size: 8px;
        letter-spacing: .3px;
    }

    .stm-promotion-card__content {
        max-width: 100%;
        padding: 20px 16px;

        border-radius: 9px;
        background: rgba(255, 255, 255, .88);
    }

    .stm-promotion-card__title {
        margin-bottom: 13px;
        padding-bottom: 12px;
        font-size: 25px;
    }

    .stm-promotion-card__description {
        font-size: 14px;
        line-height: 1.5;
    }

    .stm-promotion-card__prices {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 5px;
        margin-bottom: 18px;
    }

    .stm-promotion-card__price-old,
    .stm-promotion-card__price-new,
    .stm-promotion-card__saving {
        min-height: 70px;
        padding: 7px 3px;
    }

    .stm-promotion-card__price-old .stm-promotion-card__price-label,
    .stm-promotion-card__price-new .stm-promotion-card__price-label,
    .stm-promotion-card__saving span {
        font-size: 8px;
    }

    .stm-promotion-card__price-old strong {
        font-size: 13px;
    }

    .stm-promotion-card__price-new strong,
    .stm-promotion-card__saving strong {
        font-size: 14px;
    }

    .stm-promotion-card__button {
        width: 100%;
        min-height: 48px;
        padding: 11px 16px;
        font-size: 14px;
    }
}

/* =========================================================
   УМЕНЬШЕНИЕ АНИМАЦИИ
========================================================= */

@media (prefers-reduced-motion: reduce) {

    .stm-promotion-card::after,
    .stm-promotion-card__ribbon::after {
        animation: none !important;
    }

    .stm-promotion-card__button,
    .stm-promotion-card__button::after {
        transition: none !important;
    }
}

/* =========================================
   STANKI-M — ОТСТУПЫ СТРАНИЦЫ АКЦИЙ
========================================= */

/* Расстояние между карточками акций */
.stm-promotions__list {
    gap: 18px !important;
}

/* Небольшой отступ сверху у основного заголовка */
.stm-promotions__heading {
    margin-top: 20px !important;
}


/* STANKI-M — ИСПРАВЛЕНИЕ ОТСТУПОВ АКЦИЙ */

.stm-promotions .stm-promotions__list {
    display: flex !important;
    flex-direction: column !important;
    gap: 18px !important;
}

.stm-promotions .stm-promotions__heading {
    display: block !important;
    margin: 20px 0 20px !important;
}

.stm-promotions .stm-promotions__title {
    margin-top: 0 !important;
}


/* STANKI-M — ФИНАЛЬНЫЕ ОТСТУПЫ СТРАНИЦЫ АКЦИЙ */

.stm-promotions__list {
    gap: 18px !important;
}

body:has(.stm-promotions) h1 {
    margin-top: 20px !important;
}


/* STANKI-M: опускаем заголовок страницы акций */

/* STANKI-M — финальная настройка заголовка акций */
.stm-promotions .stm-promotions__heading { display: none !important; }

/* Заголовок акций — как на странице блога */
article#post-8276 > .entry-content > p:first-child { display: none !important; }
.stm-promotions .stm-promotions__heading { display: none !important; }

/* STANKI-M — положение H1 страницы акций */
article#post-8276 > h1 { margin-top: 30px !important; }

article#post-8276 > h1 { margin-top: 45px !important; }

/* Небольшой отступ между карточками акций */
.stm-promotions .stm-promotions__list { gap: 12px !important; row-gap: 12px !important; }

.stm-promotions .stm-promotions__list { gap: 22px !important; row-gap: 22px !important; }

.stm-promotions .stm-promotions__list { gap: 40px !important; row-gap: 40px !important; }

.stm-promotions .stm-promotions__list { gap: 50px !important; row-gap: 50px !important; }
