:root {
    --main-red-color: #e3050f;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.banner {
    position: relative;
}

.banner__background-image {
    display: block;
    width: 100%;
    height: calc(100vh - 60px) !important;
    object-fit: cover;
    object-position: center;
}

.banner__shadow {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 2;

    background: linear-gradient(to right, rgba(0,0,0,.7) 60%, rgba(0,0,0,0));
}

.banner__content {
    position: absolute;
    top: 0;
    bottom: 100px;
    left: 0;
    right: 50%;
    z-index: 3;

    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 12px;

    padding: 40px;
}

.banner__content > * {
    margin: 0;
}

.banner__features {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 100px;
    z-index: 3;

    display: flex;
    align-items: center;
    gap: 20px;

    padding: 0 40px;
}

.banner__title {
    font-size: 60px;
    color: white;
    line-height: 70px;

    display: flex;
    flex-direction: column;
    gap: 20px;
}

.banner__title > span {
    display: block;
}

.banner__title--red-part {
    color: var(--main-red-color);
    font-size: 120px;
}

.banner__description {
    display: block;
    color: white;
    font-size: 22px;
    line-height: 25px;
    max-width: 600px;
    text-wrap: wrap;
}

.banner__buttons {
    display: flex;
    gap: 20px;
}

.banner__button,
.banner__button:visited {
    max-width: 300px;
}

.banner__button:hover{

}

.banner__button--red {

}

.banner__feature {
    display: flex;
    gap: 10px;
    align-items: center;
    max-width: 300px;
}

.banner__feature-img {
    display: block;
    width: 80px;
    height: 80px;
    color: var(--main-red-color);
}

.banner__feature-desc {
    color: white;
    font-size: 16px;
    line-height: 18px;
    text-wrap: balance;
}

.advantages,
.steps {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    padding: 40px;
}

.advantage {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
}

.advantage__img {
    display: block;
    width: 80px;
    height: 80px;
    color: var(--main-red-color);
}

.advantage__title {
    display: block;
    height: 40px;
    font-size: 18px;
    line-height: 20px;
    font-weight: bold;
    text-align: center;
    display: flex;
    align-items: center;
}

.advantage__desc {
    display: block;
    font-size: 16px;
    line-height: 18px;
    font-weight: normal;
    text-align: center;
}

.clients {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 10px;
    padding: 40px;
}


.products {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px 20px;

    padding: 40px;
}

.product {
    display: grid;
    grid-template-columns: 4fr 6fr;
    grid-template-rows: auto minmax(200px, 1fr) auto;
    gap: 20px;
    align-items: center;
}

.product__image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;

    grid-column: 1;
    grid-row-start: 1;
    grid-row-end: 4;
}

.product__header {
    display: flex;
    flex-direction: column;
    gap: 5px;

    grid-column: 2;
    grid-row: 1;
}

.product__title {
    font-size: 24px;
    line-height: 26px;
    font-weight: bold;
    display: block;
}

.product__power {
    font-size: 24px;
    line-height: 26px;
    font-weight: bold;
    color: var(--main-red-color);
}

.product__content {
    grid-column: 2;
    grid-row: 2;
}

.product__buttons {
    grid-column: 2;
    grid-row: 3;
}


.rounded-block {
    border-radius: 10px;
    border: 1px solid #ccc;
    box-shadow: 0 0 15px rgba(0,0,0,.1);
    padding: 40px;
}

.for-parthners {
    position: relative;

    display: block;
    background: url('/assets/gov-support/img/parthners.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;

    color: white;

    height: max-content;
    padding: 0;
}

.for-parthners__content {
    padding: 40px;
    background: linear-gradient(to right, rgba(0,0,0,.7) 60%, rgba(0,0,0,0));

    display: flex;
    flex-direction: column;

    gap: 10px;
    height: 100%;
}

.for-parthners::before {
    content: '';
}

.for-parthners__title {
    color: var(--main-red-color);
    font-size: 24px;
    line-height: 26px;
    font-weight: bold;
}

.for-parthners__p {
    color: white;
}

.for-parthners__sub-title {
    color: white;
    font-weight: bold;
}

/* ===== THANKS POPUP ===== */

.popup-thanks {
    display: none; /* JS перемикає на flex */
    position: fixed;
    inset: 0;
    z-index: 1000;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    overflow: auto;
}

.popup-thanks__wrap {
    position: relative;
    background: #fff;
    border-radius: 10px;
    padding: 50px 60px;
    max-width: 560px;
    width: 90%;
    margin: auto;
    text-align: center;
}

.popup-thanks__title {
    font-size: 28px;
    font-weight: bold;
    color: var(--main-red-color);
    line-height: 1.3;
    margin-bottom: 16px;
}

.popup-thanks__subtitle {
    font-size: 16px;
    color: #444;
    line-height: 1.6;
}

.p-close {
    display: block;
    width: 36px;
    height: 36px;
    position: absolute;
    right: -48px;
    top: 0;
    cursor: pointer;

    background: transparent;
    border: none;
    outline: none;
}

.p-close::before,
.p-close::after {
    content: '';
    display: block;
    width: 100%;
    height: 2px;
    background: #fff;
    position: absolute;
    top: 50%;
    left: 0;
    border-radius: 2px;
}

.p-close::before { transform: rotate(45deg); }
.p-close::after  { transform: rotate(-45deg); }

/* ===== FAQ ===== */

.faq {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.faq__list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
}

.faq__item:not(:last-child) {
    border-bottom: 1px solid #e0e0e0;
}

.faq__details {
    width: 100%;
}

.faq__question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;

    padding: 8px 0;

    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
    line-height: 1.4;

    cursor: pointer;
    list-style: none;
    user-select: none;
}

/* прибираємо дефолтний трикутник у всіх браузерах */
.faq__question::-webkit-details-marker { display: none; }
.faq__question::marker { display: none; }

/* іконка "+" справа */
.faq__question::after {
    content: '+';
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 28px;
    height: 28px;

    font-size: 22px;
    font-weight: 300;
    line-height: 1;
    color: #888;

    transition: transform 0.25s ease, color 0.2s ease;
}

/* коли відкрито — міняємо "+" на "−" через rotate */
.faq__details[open] > .faq__question::after {
    content: '−';
    color: var(--main-red-color);
}

.faq__details[open] > .faq__question {
    color: var(--main-red-color);
}

.faq__answer {
    padding: 0 0 18px 0;
    overflow: hidden;
}

.faq__answer p {
    font-size: 15px;
    line-height: 1.6;
    color: #555;
}

/* плавне відкриття через анімацію */
@keyframes faq-open {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: translateY(0); }
}

.faq__details[open] .faq__answer {
    animation: faq-open 0.2s ease forwards;
}

@media (max-width: 1200px) {
    .banner__content {
        right: 0;
    }

    .banner__title {
        font-size: 40px;
        line-height: 42px;
    }

    .banner__title--red-part {
        font-size: 80px;
    }

    .banner__buttons {
        margin-top: 20px;
        flex-direction: column;
    }

    .banner__features {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        height: 200px;
        bottom: 10px;
    }

    .banner__feature-desc {
        word-break: break-word;
        word-wrap: balance;
    }

    .advantages,
    .steps,
    .clients {
        grid-template-columns: repeat(2, 1fr);
        padding: 10px;
    }

    .advantage__title {
        height: 60px;
    }

    .products {
        padding: 10px;
        grid-template-columns: 1fr;
        margin-top: 20px;
    }

    .steps {
        margin: 20px 0;
    }
}

@media (max-width: 768px) {
    .banner__content {
        padding: 20px;
    }

    .banner__title--red-part {
        font-size: 60px;
    }

    .banner__title {
        font-size: 25px;
        line-height: 28px;;
    }

    .banner__description {
        font-size: 16px;
        line-height: 18px;
    }

    .banner__buttons {
        gap: 10px;
    }

    .banner__features {
        padding: 0 10px;
    }

    .banner__feature-desc {
        font-size: 12px;
        line-height: 14px;
    }

    .advantages {
        margin-top: 20px;
        gap: 10px;
    }

    .advantage__title {
        font-size: 16px;
        line-height: 18px;
        word-break: break-word;
    }

    .advantage__desc {
        font-size: 14px;
        line-height: 16px;
    }

    .product {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
    }

    .product__image {
        grid-column: unset;
        grid-row-start: unset;
        grid-row-end: unset;
    }

    .product__header {
        grid-column: unset;
        grid-row: unset;
    }

    .product__content {
        grid-column: unset;
        grid-row: unset;
    }

    .product__buttons {
        grid-column: unset;
        grid-row: unset;
    }

    .steps {
        padding: 0;

    }

    .steps > .advantage__title {
        height: auto;
    }
}