.contact-section {
    position: relative;
    overflow: hidden;

    padding: 90px 0;

    color: #ffffff;
    background:
        radial-gradient(circle at 8% 10%, rgba(118, 81, 230, 0.24), transparent 34%),
        radial-gradient(circle at 92% 90%, rgba(242, 109, 196, 0.13), transparent 32%), #17151d;
}

.contact-section::before {
    content: "";

    position: absolute;
    inset: 0;

    opacity: 0.3;
    pointer-events: none;

    background-image:
        linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);

    background-size: 44px 44px;
}

.contact-section .container {
    position: relative;
    z-index: 1;
}

.contact-section__header {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    height: min-content;
    margin-bottom: 42px;
    gap: 20px;
}

.contact-section__eyebrow,
.representatives__eyebrow {
    display: inline-flex;

    margin-bottom: 12px;

    color: #bba9ff;

    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.contact-section__title {
    margin: 0 0 16px;

    color: #ffffff;

    font-size: clamp(34px, 5vw, 54px);
    font-weight: 800;
    line-height: 1.08;
    letter-spacing: -0.035em;
}

.contact-section__description {
    max-width: 650px;
    margin: 0;

    color: rgba(255, 255, 255, 0.66);

    font-size: 17px;
    line-height: 1.7;
}

.contact-grid {
    gap: 24px;
    align-items: flex-start;
    margin-bottom: 80px;
}

.contact-card {
    position: relative;

    min-width: 0;
    padding: 34px;

    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 26px;

    background: rgba(255, 255, 255, 0.055);
    box-shadow: 0 24px 65px rgba(0, 0, 0, 0.18);
    backdrop-filter: blur(14px);
}

.contact-card.contact-card--information {
    border: none;
    background: none;
    box-shadow: none;
    backdrop-filter: none;
    position: relative;
    top: 35px;
    padding: 0;
}

.contact-card.contact-card--information .contact-card__title {
    text-align: left;
}

.contact-card.contact-card--information .contact-socials {
    margin-top: 10px;
}

.contact-card.contact-card--information .contact-details__item {
    border-bottom: none;
}

.contact-card__header {
    position: relative;
    z-index: 1;

    margin-bottom: 30px;
}

.contact-card__label {
    display: inline-flex;

    margin-bottom: 11px;
    padding: 6px 10px;

    border: 1px solid rgba(187, 169, 255, 0.22);
    border-radius: 8px;

    color: #c8baff;
    background: rgba(118, 81, 230, 0.12);

    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.contact-card__title {
    margin: 0;

    color: #ffffff;

    font-size: 25px;
    font-weight: 750;
    line-height: 1.25;
}

.contact-card__text {
    margin: 12px 0 0;

    color: rgba(255, 255, 255, 0.6);

    font-size: 14px;
    line-height: 1.65;
}

.contact-details {
    position: relative;
    z-index: 1;

    display: grid;
    gap: 5px;

    margin: 0;
    padding: 0;

    font-style: normal;
}

.contact-details__item {
    display: grid;
    gap: 6px;

    padding-bottom: 12px;

    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.contact-details__caption,
.partner-contact__label {
    color: rgba(255, 255, 255, 0.42);

    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.contact-details__value {
    min-width: 400px;
    margin: 0;

    color: rgba(255, 255, 255, 0.78);

    font-size: 15px;
    line-height: 1.65;
}

.contact-details__link {
    width: fit-content;

    color: #ffffff;

    font-size: 17px;
    font-weight: 700;
    text-decoration: none;

    transition:
        color 0.2s ease,
        transform 0.2s ease;
}

.contact-details__link:hover {
    color: #c7b8ff;
    transform: translateX(3px);
}

.contact-socials {
    position: relative;
    z-index: 1;

    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;

    margin-top: 28px;
}

.contact-socials__link {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 48px;
    height: 48px;

    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;

    color: #ffffff;
    background: rgba(255, 255, 255, 0.07);

    transition:
        transform 0.2s ease,
        background-color 0.2s ease,
        border-color 0.2s ease;
}

.contact-socials__link:hover {
    border-color: #7651e6;
    background: #7651e6;
    transform: translateY(-3px);
}

.contact-socials__link svg {
    max-width: 27px;
    max-height: 27px;
}

.contact-socials__youtube {
    display: flex;
    align-items: center;

    min-height: 48px;
    padding: 10px 14px;

    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;

    background: rgba(255, 255, 255, 0.07);

    transition:
        transform 0.2s ease,
        border-color 0.2s ease;
}

.contact-socials__youtube:hover {
    border-color: rgba(242, 109, 196, 0.65);
    transform: translateY(-3px);
}

.contact-socials__youtube img {
    display: block;
    width: auto;
    max-width: 110px;
    height: 24px;
    object-fit: contain;
}

.tm-contactform {
    position: relative;

    padding: 34px;

    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 26px;

    background:
        radial-gradient(circle at 100% 0, rgba(118, 81, 230, 0.18), transparent 42%), rgba(255, 255, 255, 0.055);

    box-shadow:
        0 24px 65px rgba(0, 0, 0, 0.18),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);

    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.tm-contactform::before {
    content: "";

    position: absolute;
    top: 0;
    left: 34px;

    width: 75px;
    height: 3px;

    border-radius: 0 0 8px 8px;

    background: linear-gradient(90deg, #7651e6, #f26dc4);
}

#tm-contactform {
    display: flex;
    height: 100%;
    flex-direction: column;
    gap: 18px;
}

#tm-contactform .form-group {
    margin: 0;
}

#tm-contactform label {
    display: block;

    margin: 0 0 8px;

    color: rgba(255, 255, 255, 0.68);

    font-size: 13px;
    font-weight: 650;
    line-height: 1.4;
}

#tm-contactform .form-control {
    display: block;

    width: 100%;
    min-height: 54px;
    padding: 14px 16px;

    border: 1px solid rgba(255, 255, 255, 0.11);
    border-radius: 13px;

    color: #ffffff;
    background: rgba(255, 255, 255, 0.055);

    font-family: inherit;
    font-size: 15px;
    line-height: 1.5;

    outline: none;
    box-shadow: none;

    transition:
        border-color 0.2s ease,
        background-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

#tm-contactform .form-control:hover {
    border-color: rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.07);
}

#tm-contactform .form-control:focus {
    border-color: #8d6cf0;

    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);

    box-shadow:
        0 0 0 4px rgba(118, 81, 230, 0.14),
        0 12px 28px rgba(0, 0, 0, 0.09);
}

#tm-contactform .form-control::placeholder {
    color: rgba(255, 255, 255, 0.3);
    opacity: 1;
}

#tm-contactform .form-control:-webkit-autofill,
#tm-contactform .form-control:-webkit-autofill:hover,
#tm-contactform .form-control:-webkit-autofill:focus {
    -webkit-text-fill-color: #ffffff;

    box-shadow:
        0 0 0 1000px #27232e inset,
        0 0 0 4px rgba(118, 81, 230, 0.14);

    transition: background-color 9999s ease-in-out 0s;
}

#tm-contactform textarea.form-control {
    min-height: 130px;

    line-height: 1.65;
    resize: vertical;
}

#tm-contactform .form-control:required:valid:not(:placeholder-shown) {
    border-color: rgba(87, 197, 133, 0.45);
}

#tm-contactform .form-control:required:invalid:not(:placeholder-shown) {
    border-color: rgba(240, 97, 115, 0.45);
}

#tm-contactform .form-control:required:valid:not(:placeholder-shown) {
    border-color: rgba(87, 197, 133, 0.45);
}

#tm-contactform .form-control:required:invalid:not(:placeholder-shown) {
    border-color: rgba(240, 97, 115, 0.5);
}

#tm-contactform .form-control:required:invalid:not(:placeholder-shown):focus {
    box-shadow:
        0 0 0 4px rgba(240, 97, 115, 0.12),
        0 12px 28px rgba(0, 0, 0, 0.09);
}

#tm-contactform .form-btn-group {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding-top: 6px;
}

#tm-contactform .btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 180px;
    min-height: 54px;
    padding: 14px 26px;

    border: 0;
    border-radius: 13px;

    color: #ffffff;
    background: linear-gradient(135deg, #7651e6, #9875ff);

    box-shadow:
        0 12px 30px rgba(118, 81, 230, 0.28),
        inset 0 1px 0 rgba(255, 255, 255, 0.18);

    font-family: inherit;
    font-size: 15px;
    font-weight: 750;
    line-height: 1;

    cursor: pointer;

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        filter 0.2s ease;
}

#tm-contactform .btn-primary:hover {
    color: #ffffff;

    filter: brightness(1.08);

    box-shadow:
        0 17px 38px rgba(118, 81, 230, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);

    transform: translateY(-2px);
}

#tm-contactform .btn-primary:active {
    transform: translateY(0) scale(0.98);
}

#tm-contactform .btn-primary:focus-visible {
    outline: 3px solid rgba(242, 109, 196, 0.45);
    outline-offset: 4px;
}

#tm-contactform .connect {
    color: rgba(255, 255, 255, 0.42);
    width: 300px;
    margin-top: 15px;
    text-align: right;
    font-size: 11px;
    font-weight: 400;
    line-height: 1.55;
    text-decoration: none;

    transition: color 0.2s ease;
}

#tm-contactform .connect:hover {
    color: rgba(255, 255, 255, 0.72);
    text-decoration: underline;
}

#tm-contactform .btn-primary:disabled {
    cursor: not-allowed;
    opacity: 0.65;
    transform: none;
    filter: grayscale(0.2);
}

#tm-contactform.is-loading .btn-primary {
    position: relative;

    color: transparent;
    pointer-events: none;
}

#tm-contactform.is-loading .btn-primary::after {
    content: "";

    position: absolute;

    width: 20px;
    height: 20px;

    border: 2px solid rgba(255, 255, 255, 0.35);
    border-top-color: #ffffff;
    border-radius: 50%;

    animation: contact-form-loading 0.7s linear infinite;
}

.form-btn-group .connect {
    position: relative;
    inset: 0;
}

@keyframes contact-form-loading {
    to {
        transform: rotate(360deg);
    }
}

.contact-form-message {
    padding: 13px 15px;

    border-radius: 11px;

    font-size: 13px;
    line-height: 1.5;
}

.contact-form-message--success {
    border: 1px solid rgba(87, 197, 133, 0.35);

    color: #b9f3cf;
    background: rgba(87, 197, 133, 0.1);
}

.contact-form-message--error {
    border: 1px solid rgba(240, 97, 115, 0.35);

    color: #ffc0c9;
    background: rgba(240, 97, 115, 0.1);
}

/* =========================================
   АДАПТИВ
   ========================================= */

@media (max-width: 991px) {
    .tm-contactform {
        margin-top: 24px;
    }

    .contact-section__header {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 767px) {
    .tm-contactform {
        padding: 25px 20px;

        border-radius: 20px;
    }

    .tm-contactform::before {
        left: 20px;
    }

    #tm-contactform {
        gap: 16px;
    }

    #tm-contactform .form-control {
        min-height: 52px;
        padding: 13px 14px;

        border-radius: 12px;
    }

    #tm-contactform textarea.form-control {
        min-height: 120px;
    }

    #tm-contactform .form-btn-group {
        align-items: stretch;
        flex-direction: column;
        gap: 12px;
    }

    #tm-contactform .btn-primary {
        width: 100%;
        min-width: 0;
    }

    #tm-contactform .connect {
        width: 100%;
        display: block;
        text-align: center;
    }
}

@media (max-width: 420px) {
    .tm-contactform {
        padding: 22px 16px;
    }

    #tm-contactform label {
        font-size: 12px;
    }

    #tm-contactform .form-control {
        font-size: 14px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .tm-contactform *,
    .tm-contactform *::before,
    .tm-contactform *::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}

.representatives {
    padding-top: 60px;

    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.representatives__header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;

    margin-bottom: 30px;
}

.representatives__title {
    margin: 0;

    color: #ffffff;

    font-size: clamp(28px, 4vw, 40px);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.025em;
}

.representatives__description {
    max-width: 440px;
    margin: 0;

    color: rgba(255, 255, 255, 0.54);

    font-size: 14px;
    line-height: 1.65;
}

.partners {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;

    margin: 0;
    padding: 0;

    list-style: none;
}

.partner-card {
    position: relative;
    overflow: hidden;

    display: flex;
    min-width: 0;
    min-height: 350px;
    flex-direction: column;

    padding: 28px;

    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 22px;

    background:
        radial-gradient(circle at 100% 0, rgba(118, 81, 230, 0.18), transparent 42%), rgba(255, 255, 255, 0.045);

    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.14);

    transition:
        transform 0.25s ease,
        border-color 0.25s ease,
        box-shadow 0.25s ease;
}

.partner-card::before {
    content: "";

    position: absolute;
    top: 0;
    left: 28px;

    width: 72px;
    height: 3px;

    border-radius: 0 0 10px 10px;

    background: linear-gradient(90deg, #7651e6, #f26dc4);
}

.partner-card:hover {
    border-color: rgba(118, 81, 230, 0.5);

    box-shadow:
        0 26px 60px rgba(0, 0, 0, 0.2),
        0 0 32px rgba(118, 81, 230, 0.07);

    transform: translateY(-4px);
}

.partner-card__top {
    margin-bottom: 26px;
}

.partner-card__country {
    display: inline-flex;

    margin-bottom: 13px;
    padding: 6px 10px;

    border-radius: 8px;

    color: #c5b6ff;
    background: rgba(118, 81, 230, 0.13);

    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.partner-card__title {
    margin: 0;

    color: #ffffff;

    font-size: 22px;
    font-weight: 750;
    line-height: 1.3;
}

.partner-card__contacts {
    display: grid;
    gap: 18px;

    margin: 0;
    padding: 0 0 25px;

    font-style: normal;
}

.partner-contact {
    display: grid;
    gap: 5px;
}

.partner-contact__value {
    margin: 0;

    color: rgba(255, 255, 255, 0.66);

    font-size: 14px;
    line-height: 1.6;
}

.partner-contact__link {
    width: fit-content;

    color: #ffffff;

    font-size: 15px;
    font-weight: 650;
    text-decoration: none;

    transition:
        color 0.2s ease,
        transform 0.2s ease;
}

.partner-contact__link:hover {
    color: #c5b6ff;
    transform: translateX(3px);
}

.partner-card__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;

    margin-top: auto;
    padding-top: 20px;

    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.partner-card__messenger-label {
    color: rgba(255, 255, 255, 0.46);

    font-size: 12px;
    line-height: 1.4;
}

.messengers {
    display: flex;
    align-items: center;
    gap: 9px;
}

.messengers__link {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 44px;
    height: 44px;

    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;

    color: #ffffff;
    background: rgba(255, 255, 255, 0.065);

    transition:
        border-color 0.2s ease,
        background-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.messengers__link:hover {
    border-color: #7651e6;
    background: #7651e6;
    box-shadow: 0 9px 24px rgba(118, 81, 230, 0.28);
    transform: translateY(-3px);
}

.messengers__link svg {
    display: block;

    max-width: 27px;
    max-height: 27px;
}

@media (max-width: 991px) {
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .contact-card.contact-card--information {
        top: 0;
        padding: 0;
    }

    .partners {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 767px) {
    .contact-section {
        padding: 64px 0;
    }

    .contact-section__header {
        margin-bottom: 28px;
    }

    .contact-card {
        padding: 24px 20px;
        border-radius: 20px;
    }

    .contact-form {
        grid-template-columns: 1fr;
    }

    .contact-form .form-group,
    .contact-form .form-group:has(textarea) {
        grid-column: auto;
    }

    .form-btn-group {
        grid-column: auto;

        flex-direction: column;
        align-items: stretch;
    }

    .contact-form__submit {
        width: 100%;
    }

    .contact-form__agreement {
        max-width: none;
        text-align: center;
    }

    .representatives {
        padding-top: 44px;
    }

    .representatives__header {
        align-items: flex-start;
        flex-direction: column;
        gap: 14px;
    }

    .partner-card {
        min-height: 0;
        padding: 24px 20px;
        border-radius: 18px;
    }

    .partner-card::before {
        left: 20px;
    }

    .partner-card__footer {
        align-items: flex-start;
        flex-direction: column;
    }
}
