/* --- СТИЛІ ДЛЯ ТЕКСТУ ПІД СЕРТИФІКАТАМИ (Відредаговано під дизайн сайту) --- */

.certificates-text {
    width: 100%;
    text-align: left !important;
    margin-top: 25px;
}

/* Використовуємо системний шрифт сайту (без засічок) */
.certificates-text p,
.certificates-text ul,
.certificates-text li {
    font-family: sans-serif !important;
    /* ТАКИЙ ЖЕ, ЯК У BODY */
    color: #222222;
    /* Такий же колір, як у тексту вище (.section-one__content p) */
    font-size: 18px;
    /* Розмір як у основного тексту */
    line-height: 25.2px;
    /* Інтервал як у основного тексту */
}

.cert-text-main {
    margin-bottom: 20px;

    text-align: center !important;
}

.cert-list {
    list-style-type: none;
    padding: 0;
    margin: 0;
    text-align: left !important;
}

.cert-list li {
    margin-bottom: 15px;
}

.cert-list li strong {
    font-weight: 700;
    /* Робимо жирним */
    color: #000000;
}

/* --- АДАПТИВНІСТЬ ДЛЯ ТЕЛЕФОНІВ --- */
@media (max-width: 992px) {

    /* На телефонах робимо шрифт трохи меншим, як у всьому іншому тексті */
    .certificates-text p,
    .certificates-text ul,
    .certificates-text li {
        font-size: 16px;
        line-height: 22px;
    }
}










/* --- СТИЛІ ДЛЯ СЕРТИФІКАТІВ, ТЕКСТУ ТА ЗБІЛЬШЕННЯ --- */

/* Загальний контейнер для сертифікатів і тексту під ними */
.certificates-section {
    display: flex;
    flex-direction: column;
    /* Змушує елементи йти чітко зверху вниз (сертифікати, потім текст) */
    align-items: center;
    /* Центруємо все по горизонталі */
    margin: 40px auto 0 auto;
    /* Відступ зверху від основного тексту про Марка */
    width: 100%;
    max-width: 900px;
    /* Обмежуємо максимальну ширину для краси на великих екранах */
    padding: 0 15px;
    box-sizing: border-box;
}

/* Контейнер ТІЛЬКИ для 3-х картинок */
/* Контейнер ТІЛЬКИ для 3-х картинок */
.certificates-row {
    display: flex;
    justify-content: center;
    align-items: stretch;
    /* Важливо: дозволяє елементам розтягуватись по висоті, якщо потрібно */
    gap: 20px;
    /* Трохи зменшив відстань між картинками на десктопі */
    width: 100%;
    margin-bottom: 25px;
}

/* Маленькі картинки сертифікатів */
/* Маленькі картинки сертифікатів */
/* Маленькі картинки сертифікатів */
.cert-thumb {
    flex: 1;
    width: 0;
    height: auto;
    max-width: 250px;
    border-radius: 4px;
    cursor: pointer;

    /* СМАРАГДОВА ПІДСВІТКА (в стані спокою) */
    /* Використовуємо ваш колір rgba(0, 92, 83) з прозорістю 40% */
    box-shadow: 0 6px 20px rgba(0, 92, 83, 0.6);

    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: block;
    background-color: transparent;
    -webkit-tap-highlight-color: transparent;
    /* Прибирає синій квадрат на телефоні */

}

/* Ефект при наведенні мишки (або тапі) */
.cert-thumb:hover {
    transform: translateY(-8px);

    /* БІЛЬШ НАСИЧЕНА СМАРАГДОВА ПІДСВІТКА (при наведенні) */
    /* Тінь стає більшою і менш прозорою (70%) */
    box-shadow: 0 10px 25px rgba(0, 92, 83, 0.7);
}

/* СТИЛІ ДЛЯ ТЕКСТУ ПІД СЕРТИФІКАТАМИ */
.certificates-text {
    width: 100%;
    text-align: center;
    /* Текст по центру */
}

.certificates-text p {
    font-size: 16px;
    line-height: 1.6;
    color: #4a4a4a;
    /* Темно-сірий колір, не такий різкий як чорний */
    margin: 0;
    /* Якщо у вас на сайті є фірмовий шрифт, він застосується автоматично */
}

/* --- МОДАЛЬНЕ ВІКНО (БЕЗ ЗМІН) --- */
.cert-modal {
    display: none;
    position: fixed;
    z-index: 100000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

.cert-modal-content {
    max-width: 90%;
    max-height: 90vh;
    border-radius: 10px;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
    animation: certZoomIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    object-fit: contain;
}

.cert-close {
    position: absolute;
    top: 20px;
    right: 40px;
    color: #ffffff;
    font-size: 50px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease, transform 0.3s ease;
    line-height: 1;
    z-index: 100001;
}

.cert-close:hover {
    color: #25D366;
    transform: scale(1.1);
}

@keyframes certZoomIn {
    from {
        transform: scale(0.8);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* --- АДАПТИВНІСТЬ ДЛЯ ТЕЛЕФОНІВ ТА ПЛАНШЕТІВ --- */
@media (max-width: 768px) {
    .certificates-section {
        margin-top: 30px;
        /* Трохи менший відступ зверху на мобільних */
    }

    .certificates-row {
        gap: 15px;
        /* Менша відстань між картинками */
        margin-bottom: 20px;
        /* Менший відступ до тексту */
    }

    .cert-thumb {
        width: 31%;
        /* Картинки трохи ширші, щоб заповнити екран */
        border-radius: 5px;
    }

    .certificates-text p {
        font-size: 14px;
        /* Трохи менший шрифт на телефонах для кращої читабельності */
    }

    .cert-close {
        top: 15px;
        right: 25px;
        font-size: 45px;
    }
}

























/* === ПОЧАТОК БЛОКУ ДЛЯ ЗАМІНИ === */

#spin-wheel-btn {
    /* Базові стилі */
    background-color: #25D366;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 15px 30px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: background-color 0.3s, transform 0.2s;

    /* Властивості для оптимізації рендерингу */
    will-change: transform, box-shadow;
    transform-origin: center center;
    backface-visibility: hidden;
    /* Допомагає згладити 3D-трансформації */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;

    /* Запускаємо обидві анімації */
    animation:
        smooth-pulse 2s infinite,
        pulse-glow 2s infinite;
}

/* Клас для зупинки анімації */
#spin-wheel-btn.clicked {
    animation: none;
    background-color: #ccc;
    cursor: not-allowed;
    transform: scale(1) translateZ(0);
    /* Скидаємо трансформацію */
}

/*
 * ВИПРАВЛЕННЯ №2: Додаємо translateZ(0) до стану наведення,
 * щоб уникнути стрибка при наведенні курсора.
 */
#spin-wheel-btn:hover:not(.clicked) {
    background-color: #128C7E;
    transform: scale(1.05) translateZ(0);
}

/*
 * ОСНОВНЕ ВИПРАВЛЕННЯ: Анімація пульсації з 3D-прискоренням
 * Додавання `translateZ(0)` змушує браузер передати анімацію
 * на GPU. Це стабілізує рендеринг і повністю прибирає
 * тремтіння тексту.
 */
@keyframes smooth-pulse {
    0% {
        transform: scale(1) translateZ(0);
    }

    50% {
        transform: scale(1.05) translateZ(0);
    }

    100% {
        transform: scale(1) translateZ(0);
    }
}

/* Анімація світіння (без змін) */
@keyframes pulse-glow {
    0% {
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2), 0 0 0 0 rgba(37, 211, 102, 0.7);
    }

    70% {
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2), 0 0 20px 20px rgba(37, 211, 102, 0);
    }

    100% {
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2), 0 0 0 0 rgba(37, 211, 102, 0);
    }
}


.fortune-prompt {
    position: fixed;
    bottom: 20px;
    left: 50%;
    width: 300px;
    z-index: 10001;
    font-family: 'Montserrat', sans-serif;

    /* Початковий стан: приховано */
    opacity: 0;
    transform: translate(-50%, 150px);
    pointer-events: none;

    /* Плавний перехід для появи/зникнення */
    transition: transform 0.5s ease-in-out, opacity 0.5s ease-in-out;
}

/* Клас .show робить контейнер видимим */
.fortune-prompt.show {
    opacity: 1;
    transform: translate(-50%, 0);
    pointer-events: auto;
}

/* Внутрішній контейнер: відповідає за фон, відступи та ПУЛЬСАЦІЮ */
.fortune-prompt__content {
    background-color: #ffffff;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
    padding: 20px;
    text-align: center;

    /* Властивості для згладжування тексту */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;

    /*
   * ВИПРАВЛЕННЯ:
   * 1. `will-change` "підказує" браузеру, що властивість `transform` буде
   *    змінюватися. Це дозволяє браузеру заздалегідь оптимізувати
   *    анімацію, що робить її значно плавнішою.
   * 2. `transform-origin` гарантує, що масштабування відбувається
   *    точно від центру елемента.
   */
    will-change: transform;
    transform-origin: center center;
}

/* Запускаємо анімацію ТІЛЬКИ коли вікно видиме */
.fortune-prompt.show .fortune-prompt__content {
    animation:
        smooth-pulse-prompt 2s infinite,
        pulse-glow 2s infinite;
}

/* Анімація пульсації (масштабування) */
@keyframes smooth-pulse-prompt {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }

    100% {
        transform: scale(1);
    }
}

/*
 * Припустимо, у вас є така анімація світіння.
 * Якщо її немає, можете видалити `pulse-glow` з властивості `animation`.
 */
@keyframes pulse-glow {
    0% {
        box-shadow:
            0 4px 15px rgba(0, 0, 0, 0.1),
            0 0 20px 0px rgba(37, 211, 102, 0.3);
    }

    50% {
        /*
     * Збільшуємо розмиття (30px) та поширення (8px)
     * зеленої тіні, щоб вона стала більшою та яскравішою.
     */
        box-shadow:
            0 6px 20px rgba(0, 0, 0, 0.15),
            /* Трохи збільшуємо і темну тінь */
            0 0 30px 8px rgba(37, 211, 102, 0.5);
        /* ОСНОВНА ЗМІНА ТУТ */
    }

    100% {
        box-shadow:
            0 4px 15px rgba(0, 0, 0, 0.1),
            0 0 20px 0px rgba(37, 211, 102, 0.3);
    }
}


.fortune-prompt p {
    margin: 0 0 15px 0;
    font-size: 16px;
    line-height: 1.4;
    color: #333;
    /*
   * ДОДАТКОВА ОПТИМІЗАЦІЯ:
   * Ми можемо також "підказати" браузеру, що і сам текст
   * буде трансформуватися. Це може покращити його рендеринг
   * під час анімації батьківського елемента.
   */
    will-change: transform;
}

.fortune-prompt button {
    background-color: #25D366;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 12px 25px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s;
    /* ДОДАТКОВА ОПТИМІЗАЦІЯ для кнопки */
    will-change: transform;
}

.fortune-prompt button:hover {
    background-color: #128C7E;
    transform: scale(1.05);
}

/* 2. Загальні стилі для модальних вікон */
.wheel-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    justify-content: center;
    align-items: center;
    z-index: 10002;
    font-family: 'Montserrat', sans-serif;
}

.wheel-modal-content {
    background: white;
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    max-width: 90%;
    width: 400px;
    animation: modal-appear 0.3s ease-out;
}

@keyframes modal-appear {
    from {
        opacity: 0;
        transform: scale(0.8);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.wheel-modal h2 {
    font-size: 28px;
    margin-bottom: 25px;
    color: #128C7E;
}

.wheel-modal button {
    margin-top: 25px;
    background-color: #25D366;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 15px 30px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
}

.wheel-modal button:hover {
    background-color: #128C7E;
    transform: scale(1.05);
}

.wheel-modal button:disabled {
    background-color: #ccc;
    cursor: not-allowed;
    transform: scale(1);
}

/* 3. Стилі для колеса фортуни */
.wheel-container {
    position: relative;
    width: 300px;
    height: 300px;
    margin: 0 auto;
}

.wheel-pointer {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 20px solid transparent;
    border-right: 20px solid transparent;
    border-top: 30px solid #d9534f;
    z-index: 2;
    transition: transform 0.3s ease;
}

.wheel-container:hover .wheel-pointer {
    transform: translateX(-50%) scale(1.1);
}

/* ЗМІНА №1: Нові кольори для секторів */
/* === НОВІ СТИЛІ ДЛЯ КОЛЕСА (з новими кольорами) === */
.wheel {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 8px solid #333;
    overflow: hidden;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
    /* Нові кольори для нового порядку призів */
    background: conic-gradient(#fffbe6 0deg 45deg,
            /* 50€ */
            #ffee99 45deg 90deg,
            /* 200€ (найяскравіший) */
            #f8f8f8 90deg 135deg,
            /* Без бонуса (сірий) */
            #fffbe6 135deg 180deg,
            /* 50€ */
            #fff5cc 180deg 225deg,
            /* 100€ */
            #f8f8f8 225deg 270deg,
            /* Без бонуса (сірий) */
            #fffbe6 270deg 315deg,
            /* 50€ */
            #fff5cc 315deg 360deg
            /* 100€ */
        );
    transition: transform 5s cubic-bezier(0.25, 0.1, 0.25, 1);
}

/* === КІНЕЦЬ === */

.wheel-sector-text {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* === НОВІ, ВИПРАВЛЕНІ СТИЛІ ДЛЯ ТЕКСТУ === */
.wheel-sector-text span {
    display: block;
    position: absolute;
    top: 25px;
    /* Трохи підняли для кращого центрування */
    left: 50%;
    transform: translateX(-50%);
    font-weight: 700;
    font-size: 19px;
    /* Трохи зменшили для гарантії */
    color: #333;
    line-height: 1.1;
    /* Зменшили відстань між рядками */
    text-align: center;
    /* Центруємо текст */
}

/* === КІНЕЦЬ === */
/* Розташування контейнерів з текстом по колу */
.wheel-sector-text:nth-child(1) {
    transform: rotate(22.5deg);
}

.wheel-sector-text:nth-child(2) {
    transform: rotate(67.5deg);
}

.wheel-sector-text:nth-child(3) {
    transform: rotate(112.5deg);
}

.wheel-sector-text:nth-child(4) {
    transform: rotate(157.5deg);
}

.wheel-sector-text:nth-child(5) {
    transform: rotate(202.5deg);
}

.wheel-sector-text:nth-child(6) {
    transform: rotate(247.5deg);
}

.wheel-sector-text:nth-child(7) {
    transform: rotate(292.5deg);
}

.wheel-sector-text:nth-child(8) {
    transform: rotate(337.5deg);
}

/* 4. Стилі для вікна виграшу */
.bonus-won-content p {
    font-size: 18px;
    margin: 15px 0;
}

.bonus-amount {
    font-size: 60px;
    font-weight: 700;
    color: #25D366;
    margin: 10px 0 20px;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1);
    }
}

















/* --- УНІВЕРСАЛЬНИЙ CSS ДЛЯ СТАНДАРТНОЇ АНІМАЦІЇ --- */
.header-main,
.section-three,
.footer {
    position: relative;
    overflow: hidden;
}

.header-main .container,
.section-three .container,
.footer .container {
    position: relative;
    z-index: 1;
}

.whatsapp-animation-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.whatsapp-logo {
    position: absolute;
    width: 50px;
    height: 50px;
    background-image: url('../images/WhatsApp.svg');
    background-size: contain;
    background-repeat: no-repeat;
    opacity: 0.15;
    transition-property: transform, opacity;
    transition-timing-function: linear;
    will-change: transform;
}

/* --- ІЗОЛЬОВАНІ СТИЛІ ТІЛЬКИ ДЛЯ КАЛЬКУЛЯТОРА --- */
section.calculator {
    position: relative !important;
    overflow: hidden !important;
}

section.calculator .container {
    position: relative !important;
    z-index: 1 !important;
}

.calculator-animation-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.calculator-logo {
    position: absolute !important;
    width: 50px !important;
    height: 50px !important;
    background-image: url('../images/WhatsApp.svg') !important;
    background-size: contain !important;
    background-repeat: no-repeat !important;
    opacity: 0.15 !important;
    transition-property: transform, opacity !important;
    transition-timing-function: linear !important;
    will-change: transform;
}
















.section-wrapper {
    display: flex;
    justify-content: center;
    padding: 20px 0;
}

.main-container {
    width: 100%;
    max-width: 900px;
    height: 65vh;
    max-height: 550px;
    display: flex;
    flex-direction: column;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    background-color: #f0f2f5;
}

.main-body {
    flex-grow: 1;
    background-color: #f0f2f5;
    padding: 10px;
    overflow: auto;
    overflow-x: auto;
}

/* --- СТИЛІ ДЛЯ ПОСТІЙНО ВИДИМОГО СКРОЛБАРУ --- */

.main-body::-webkit-scrollbar {
    width: 12px;
    height: 12px;
}

/* Доріжка (трек) - ЗАВЖДИ ВИДИМА */
.main-body::-webkit-scrollbar-track {
    background: #d8e8d8;
    /* Більш помітний, але все ще світлий зелений */
    border-radius: 6px;
    box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.1);
    /* Легка внутрішня тінь */
}

/* Повзунок (з'являється при скролі) */
.main-body::-webkit-scrollbar-thumb {
    background-color: #4CAF50;
    border-radius: 6px;
    border: 2px solid #d8e8d8;
    /* Рамка кольору доріжки */
}

.main-body::-webkit-scrollbar-thumb:hover {
    background-color: #45a049;
}

/* Стилізація для Firefox */
.main-body {
    scrollbar-width: auto;
    scrollbar-color: #4CAF50 #d8e8d8;
    /* Колір повзунка і колір доріжки */
}

/* --- СТИЛІ ДЛЯ ТАБЛИЦІ --- */
.table__table {
    width: 100%;
    border-collapse: collapse;
    background-color: #fff;
    min-width: 800px;
}

.table__table th,
.table__table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #e9edef;
    vertical-align: middle;
}

.table__table th {
    background-color: #f8f9fa;
    font-weight: 600;
    color: #54656f;
}

.table__table tbody tr:hover {
    background-color: #f5f5f5;
}

.status-profit {
    color: #008000;
    font-weight: bold;
}

.direction-long {
    color: #008000;
    font-weight: bold;
}

.direction-short {
    color: #D32F2F;
    font-weight: bold;
}

.table__body-row td:nth-child(3) {
    text-align: right;
}

.profit-bubble {
    position: relative;
    display: inline-block;
    padding: 8px 14px;
    background-color: #dcf8c6;
    border-radius: 10px;
    color: #303030;
    font-weight: 500;
    margin-right: 15px;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.08);
}

.profit-bubble::after {
    content: '';
    position: absolute;
    top: 50%;
    right: -8px;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    border-left: 8px solid #dcf8c6;
}

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








/* 
      -- Змінні CSS для легкого керування дизайном --
      Ви можете змінювати ці значення, щоб налаштувати вигляд.
    */
:root {
    --bg-whatsapp-dark: #075E54;
    /* Основний темно-зелений фон */
    --accent-whatsapp-green: #25D366;
    /* Яскраво-зелений для акцентів */
    --text-color-primary: #FFFFFF;
    /* Основний колір тексту */
    --text-color-secondary: rgba(255, 255, 255, 0.85);
    /* Другорядний колір тексту */

    --card-border-radius: 12px;
    /* Радіус заокруглення карток */
    --card-padding: 25px;
    /* Внутрішні відступи карток */
    --container-gap: 20px;
    /* Відстань між картками */

    --card-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    /* Тінь карток */
    --card-shadow-hover: 0 8px 16px rgba(0, 0, 0, 0.3);
    /* Тінь при наведенні */
}

.stats-container {
    display: flex;
    flex-direction: column;
    /* -- Mobile First: спочатку все в один стовпець -- */
    gap: var(--container-gap);
    width: 100%;
    max-width: 1100px;
    /* Трохи збільшимо максимальну ширину для десктопів */
    padding: 0 15px;
    /* Додамо невеликі відступи з боків на мобільних */
    box-sizing: border-box;


    margin: 0 auto;
}

.stat-card {
    background-color: var(--bg-whatsapp-dark);
    color: var(--text-color-primary);
    border-radius: var(--card-border-radius);
    padding: var(--card-padding);
    text-align: center;
    box-shadow: var(--card-shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.stat-number {
    font-weight: bold;
    color: var(--accent-whatsapp-green);
    margin-bottom: 10px;
    line-height: 1.2;
    /* -- Плавний шрифт: мін. 36px, макс. 48px, ідеально 5vw -- */
    font-size: clamp(2.25rem, 5vw, 3rem);
    /* 1rem = 16px */
}

.stat-description {
    color: var(--text-color-secondary);
    /* -- Плавний шрифт: мін. 14px, макс. 16px, ідеально 2vw -- */
    font-size: clamp(0.875rem, 2vw, 1rem);
}

/* -- Адаптивність для планшетів (і великих телефонів) -- */
/* Коли екран ширший за 576px, ставимо картки по дві в ряд */
@media (min-width: 576px) {
    .stats-container {
        flex-direction: row;
        /* Повертаємо вигляд рядка */
        flex-wrap: wrap;
        /* Дозволяємо перенесення */
        justify-content: center;
    }

    .stat-card {
        /* Кожна картка займає майже половину ширини (з урахуванням відступу) */
        flex-basis: calc(50% - (var(--container-gap) / 2));
        flex-grow: 1;
    }
}

/* -- Адаптивність для десктопів -- */
/* Коли екран ширший за 992px, ставимо всі чотири картки в один ряд */
@media (min-width: 992px) {
    .stat-card {
        /* Кожна картка займає приблизно чверть ширини */
        flex-basis: calc(25% - (var(--container-gap) * 3 / 4));
    }
}

/* -- Ефект наведення тільки для пристроїв з мишкою -- */
/* Це запобігає "залипанню" ефекту на телефонах і планшетах */
@media (hover: hover) and (pointer: fine) {
    .stat-card:hover {
        transform: translateY(-5px);
        box-shadow: var(--card-shadow-hover);
    }
}



/* Стиль для корректного ввода */
.valid {
    background: #00ef0098 !important;
    color: var(--valid-input-color) !important;
}

/* Стиль для некорректного ввода */
.invalid {
    background: #ef000099 !important;
    color: var(--valid-input-color) !important;
}

.input__wrapper {
    background: #fff;
}

/* Чтобы кнопка-крестик была в правом верхнем углу */
.modal-lead__content {
    position: relative;
    /* Относительное позиционирование обёртки */
}

.close-modal-btn {
    position: absolute;
    top: 20px;
    /* Отступ от верхнего края */
    right: 20px;
    /* Отступ от правого края */
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    color: #333;
    /* Цвет иконки (через fill="currentColor") */
    transition: color 0.2s ease;
}

.close-modal-btn:hover {
    color: #000;
    /* При наведении иконка станет чуть темнее */

}




#loadingOverlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.loader-bg {
    position: absolute;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    /* напівпрозорий чорний */
    backdrop-filter: blur(4px);
    /* ефект блюру */
}

.loader-gif {
    position: relative;
    width: 100px;
    height: auto;
    z-index: 1;
}


/* Контейнер */
#wa-comments-wrapper {
    background-color: #fff;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    max-width: 800px;
    margin: 40px auto;
    padding: 20px;
    border-radius: 8px;
}

#wa-comments-wrapper h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
    color: #1c1e21;
    text-align: center;
}

/* Форма вводу (головна) */
.wa-input-row {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    align-items: flex-start;
}

.wa-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.wa-input-container {
    flex-grow: 1;
    position: relative;
}

.wa-input-field {
    width: 100%;
    background: #f0f2f5;
    border: 1px solid transparent;
    border-radius: 20px;
    padding: 10px 15px;
    font-size: 15px;
    color: #050505;
    outline: none;
    transition: 0.2s;
    box-sizing: border-box;
}

.wa-input-field:focus {
    background: #fff;
    border-color: #25D366;
}

.wa-send-btn {
    background: #25D366;
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 20px;
    font-weight: 600;
    cursor: pointer;
    font-size: 14px;
    margin-top: 5px;
    transition: background 0.2s;
}

.wa-send-btn:hover {
    background: #1ebc57;
}

/* Список коментарів */
#wa-comments-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.wa-comment-item {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    align-items: flex-start;
}

/* Клас для відступу відповіді */
.wa-reply {
    margin-left: 50px;
    position: relative;
}

/* Лінія з'єднання (опціонально, як у Facebook) */
.wa-reply::before {
    content: '';
    position: absolute;
    left: -25px;
    top: -10px;
    width: 20px;
    height: 40px;
    border-bottom: 2px solid #e5e5e5;
    border-left: 2px solid #e5e5e5;
    border-bottom-left-radius: 10px;
}

.wa-comment-content {
    max-width: calc(100% - 50px);
    width: 100%;
}

.wa-bubble {
    background-color: #f0f2f5;
    padding: 10px 15px;
    border-radius: 18px;
    display: inline-block;
    position: relative;
}

.wa-author {
    display: block;
    font-weight: 700;
    color: #050505;
    font-size: 13px;
    margin-bottom: 2px;
    text-decoration: none;
    cursor: pointer;
}

.wa-text {
    color: #050505;
    font-size: 15px;
    line-height: 1.4;
    word-wrap: break-word;
}

/* Дії (лайк, відповідь) */
.wa-actions {
    display: flex;
    gap: 15px;
    margin-top: 3px;
    margin-left: 12px;
    font-size: 12px;
    color: #65676b;
    align-items: center;
}

.wa-action-link {
    font-weight: 700;
    cursor: pointer;
    color: #65676b;
}

.wa-action-link:hover {
    text-decoration: underline;
}

/* Лічильник лайків */
.wa-likes-count-wrapper {
    display: flex;
    align-items: center;
    gap: 4px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    padding: 2px 5px;
    border-radius: 10px;
    position: absolute;
    bottom: -5px;
    right: -10px;
    z-index: 2;
}

.wa-like-icon {
    width: 16px;
    height: 16px;
}

.wa-likes-num {
    font-size: 11px;
    color: #65676b;
}

/* ФОРМА ВІДПОВІДІ (динамічна) */
.wa-reply-input-box {
    margin-top: 10px;
    display: flex;
    gap: 10px;
    align-items: center;
    animation: fadeIn 0.3s ease;
}

.wa-reply-input-box input {
    flex-grow: 1;
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 15px;
    padding: 5px 10px;
    font-size: 13px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Адаптив */
@media (max-width: 600px) {
    .wa-reply {
        margin-left: 20px;
    }

    .wa-reply::before {
        display: none;
    }
}





/* Контейнер */
#wa-comments-wrapper {
    background-color: #fff;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    max-width: 800px;
    margin: 40px auto;
    padding: 20px;
    border-radius: 8px;
}

#wa-comments-wrapper h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
    color: #1c1e21;
    text-align: center;
}

/* Форма вводу */
.wa-input-row {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    align-items: flex-start;
}

.wa-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.wa-input-container {
    flex-grow: 1;
    position: relative;
}

.wa-input-field {
    width: 100%;
    background: #f0f2f5;
    border: 1px solid transparent;
    border-radius: 20px;
    padding: 10px 15px;
    font-size: 15px;
    color: #050505;
    outline: none;
    transition: 0.2s;
    box-sizing: border-box;
}

.wa-input-field:focus {
    background: #fff;
    border-color: #25D366;
}

.wa-send-btn {
    background: #25D366;
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 20px;
    font-weight: 600;
    cursor: pointer;
    font-size: 14px;
    margin-top: 5px;
    transition: background 0.2s;
}

.wa-send-btn:hover {
    background: #1ebc57;
}

/* Список коментарів */
#wa-comments-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.wa-comment-item {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    align-items: flex-start;
}

/* Стилі для фотографій у коментарях */
.wa-attached-img {
    display: block;
    max-width: 100%;
    width: 250px;
    /* Оптимальна ширина для скріншота */
    height: auto;
    border-radius: 12px;
    margin-top: 8px;
    cursor: pointer;
    border: 1px solid #ddd;
}

/* Відповіді */
.wa-reply {
    margin-left: 50px;
    position: relative;
}

.wa-reply::before {
    content: '';
    position: absolute;
    left: -25px;
    top: -10px;
    width: 20px;
    height: 40px;
    border-bottom: 2px solid #e5e5e5;
    border-left: 2px solid #e5e5e5;
    border-bottom-left-radius: 10px;
}

.wa-comment-content {
    max-width: calc(100% - 50px);
    width: 100%;
}

.wa-bubble {
    background-color: #f0f2f5;
    padding: 10px 15px;
    border-radius: 18px;
    display: inline-block;
    position: relative;
    min-width: 120px;
}

.wa-author {
    display: block;
    font-weight: 700;
    color: #050505;
    font-size: 13px;
    margin-bottom: 2px;
    text-decoration: none;
    cursor: pointer;
}

.wa-text {
    color: #050505;
    font-size: 15px;
    line-height: 1.4;
    word-wrap: break-word;
    display: block;
}

.wa-actions {
    display: flex;
    gap: 15px;
    margin-top: 3px;
    margin-left: 12px;
    font-size: 12px;
    color: #65676b;
    align-items: center;
}

.wa-action-link {
    font-weight: 700;
    cursor: pointer;
    color: #65676b;
}

.wa-action-link:hover {
    text-decoration: underline;
}

/* Лайки */
.wa-likes-count-wrapper {
    display: flex;
    align-items: center;
    gap: 4px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    padding: 2px 5px;
    border-radius: 10px;
    position: absolute;
    bottom: -8px;
    right: -5px;
    z-index: 2;
}

.wa-like-icon {
    width: 16px;
    height: 16px;
}

.wa-likes-num {
    font-size: 11px;
    color: #65676b;
}

/* Форма відповіді */
.wa-reply-input-box {
    margin-top: 10px;
    display: flex;
    gap: 10px;
    align-items: center;
    animation: fadeIn 0.3s ease;
}

.wa-reply-input-box input {
    flex-grow: 1;
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 15px;
    padding: 5px 10px;
    font-size: 13px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 600px) {
    .wa-reply {
        margin-left: 20px;
    }

    .wa-reply::before {
        display: none;
    }

    .wa-attached-img {
        width: 100%;
    }
}