:root {
    --tg-theme-primary: #1ED760;
    --tg-theme-primary-hover: #19c251;
    --tg-common-white: #ffffff;
    --tg-common-black: #161439;
    --tg-grey-1: #5f6168;
    --tg-grey-5: #f5f5f5;
    --tg-grey-7: #eafcf0;
    --tg-border-soft: #e6e6e6;
    --tg-shadow-soft: 0 20px 60px rgba(22, 20, 57, 0.18);
    --tg-shadow-soft-2: 0 10px 30px rgba(22, 20, 57, 0.12);
}

#cookie-consent-root {
    font-family: inherit;
}

.tg-cookie-consent-title {
    margin: 0 0 6px;
    color: var(--tg-common-black);
    font-size: 18px;
    line-height: 1.2;
    font-weight: 700;
    font-family: var(--tg-ff-chillax);
}

.tg-cookie-consent-text {
    margin: 0;
    color: var(--tg-grey-1);
    font-size: 13px;
    line-height: 1.55;
    max-width: 720px;
}

.tg-cookie-consent-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 16px;
    z-index: 9997;
    padding: 0 15px;
    display: none;
}

.tg-cookie-consent-banner.is-visible {
    display: block;
}

.tg-cookie-consent-banner__inner {
    max-width: 980px;
    margin: 0 auto;
    padding: 16px 20px;
    border-radius: 20px;
    box-shadow: 0 12px 30px rgba(22, 20, 57, 0.12);
    background: rgba(255,255,255,0.97);
    backdrop-filter: blur(8px);
    display: flex;
    gap: 16px;
    align-items: center;
    justify-content: space-between;
}

.tg-cookie-consent-banner__content {
    flex: 1 1 auto;
    min-width: 0;
    max-width: 720px;
}

.tg-cookie-consent-banner__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
    flex: 0 0 auto;
}

.tg-cookie-consent-banner .tg-btn,
.tg-cookie-consent-modal .tg-btn {
       border: 0;
    cursor: pointer;
    transition: .25s ease;
    min-height: 42px;
    border-radius: 12px;
    padding: 0 18px;
    font-size: 13px;
    font-weight: 600;
}

.tg-cookie-consent-banner .tg-btn.tg-btn-switch-animation,
.tg-cookie-consent-modal .tg-btn.tg-btn-switch-animation {
    background: var(--tg-theme-primary);
    color: #fff;
    box-shadow: 0 10px 22px rgba(30,215,96,0.18);
}

.tg-cookie-consent-banner .tg-btn.tg-btn-switch-animation:hover,
.tg-cookie-consent-modal .tg-btn.tg-btn-switch-animation:hover {
    background: var(--tg-theme-primary-hover);
    color: #fff;
}

.tg-cookie-consent-banner .tg-btn.tg-btn-gray,
.tg-cookie-consent-modal .tg-btn.tg-btn-gray {
    background: #eff7f2;
    color: #4f5b71;
}

.tg-cookie-consent-banner .tg-btn.tg-btn-gray:hover,
.tg-cookie-consent-modal .tg-btn.tg-btn-gray:hover {
    background: #e8f1eb;
    color: #31405b;
}

.tg-cookie-consent-banner .tg-btn.tg-btn-transparent,
.tg-cookie-consent-modal .tg-btn.tg-btn-transparent {
    background: transparent;
    color: #6a758d;
    border: 1px solid #dde4ea;
}

.tg-cookie-consent-banner .tg-btn.tg-btn-transparent:hover,
.tg-cookie-consent-modal .tg-btn.tg-btn-transparent:hover {
    background: #f7f9fb;
    color: #31405b;
}

.tg-cookie-consent-banner__actions .tg-btn:not(.tg-btn-switch-animation) {
    font-weight: 600;
}

.tg-cookie-consent-overlay {
    position: fixed;
    inset: 0;
    background: rgba(14, 14, 24, 0.52);
    z-index: 9998;
    display: none;
}

.tg-cookie-consent-overlay.is-visible {
    display: block;
}

.tg-cookie-consent-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
    padding: 24px 15px;
    overflow-y: auto;
}

.tg-cookie-consent-modal.is-visible {
    display: block;
}

.tg-cookie-consent-modal__dialog {
    min-height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tg-cookie-consent-modal__panel {
    width: 100%;
    max-width: 720px;
    padding: 28px;
    border-radius: 24px;
    box-shadow: var(--tg-shadow-soft);
    background: #fff;
}

.tg-cookie-consent-modal__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 20px;
}

.tg-cookie-consent-close {
    border: none;
    background: #f2f2f2;
    color: var(--tg-common-black);
    width: 40px;
    height: 40px;
    min-width: 40px;
    border-radius: 50%;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
}

.tg-cookie-consent-modal__body {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.tg-cookie-preference-card {
    border: 1px solid var(--tg-border-soft);
    border-radius: 18px;
    background: #fafafa;
    padding: 18px 20px;
}

.tg-cookie-preference-card.is-required {
    background: #f4fdf7;
}

.tg-cookie-preference-card__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.tg-cookie-preference-card h4 {
    margin: 0 0 6px;
    color: var(--tg-common-black);
    font-size: 17px;
    font-weight: 600;
}

.tg-cookie-preference-card p {
    margin: 0;
    color: var(--tg-grey-1);
    font-size: 14px;
    line-height: 1.65;
}

.tg-cookie-consent-modal__footer {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    flex-wrap: wrap;
    margin-top: 24px;
}

.tg-cookie-switch {
    position: relative;
    display: inline-flex;
    align-items: center;
    width: 58px;
    height: 32px;
    min-width: 58px;
}

.tg-cookie-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.tg-cookie-switch__slider {
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: #d8d8e2;
    transition: .25s ease;
    cursor: pointer;
}

.tg-cookie-switch__slider:before {
    content: "";
    position: absolute;
    width: 24px;
    height: 24px;
    left: 4px;
    top: 4px;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .15);
    transition: .25s ease;
}

.tg-cookie-switch input:checked + .tg-cookie-switch__slider {
    background: var(--tg-theme-primary);
}

.tg-cookie-switch input:checked + .tg-cookie-switch__slider:before {
    transform: translateX(26px);
}

.tg-cookie-switch__slider.is-locked {
    background: #bfeecf;
    cursor: not-allowed;
}

body.tg-cookie-consent-modal-open {
    overflow: hidden;
}

@media (max-width: 991px) {
    .tg-cookie-consent-banner {
        bottom: 12px;
        padding: 0 12px;
    }

    .tg-cookie-consent-banner__inner {
        padding: 18px 18px 16px;
        border-radius: 22px;
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
    }

    .tg-cookie-consent-banner__content {
        max-width: none;
    }

    .tg-cookie-consent-banner__actions {
        width: 100%;
        justify-content: flex-start;
    }

    .tg-cookie-consent-modal__panel {
        padding: 24px 18px;
        border-radius: 20px;
    }

    .tg-cookie-preference-card__top {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 575px) {
    .tg-cookie-consent-banner {
        bottom: 8px;
        padding: 0 8px;
    }

    .tg-cookie-consent-banner__inner {
        padding: 14px;
        border-radius: 18px;
        gap: 10px;
    }

    .tg-cookie-consent-title {
        font-size: 16px;
    }

    .tg-cookie-consent-text {
        font-size: 12px;
        line-height: 1.5;
    }

    .tg-cookie-consent-banner__actions,
    .tg-cookie-consent-modal__footer {
        flex-direction: column;
        width: 100%;
    }

    .tg-cookie-consent-banner__actions .tg-btn,
    .tg-cookie-consent-modal__footer .tg-btn {
        width: 100%;
        min-height: 40px;
    }
}
