.tac-cookie-banner,
.tac-cookie-banner * {
    box-sizing: border-box;
}

.tac-cookie-banner {
    position: fixed;
    z-index: 999999;
    color: var(--tac-text);
    font-family: inherit;
    line-height: 1.5;
}

.tac-cookie-banner[hidden] {
    display: none !important;
}

.tac-position-bottom {
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    background: var(--tac-bg);
    border-top: 1px solid var(--tac-border);
    box-shadow: 0 -12px 35px rgba(0, 0, 0, .08);
}

.tac-position-bottom-left,
.tac-position-bottom-right {
    bottom: 24px;
    width: min(460px, calc(100% - 32px));
    background: var(--tac-bg);
    border: 1px solid var(--tac-border);
    border-radius: 16px;
    box-shadow: 0 14px 40px rgba(0, 0, 0, .12);
}

.tac-position-bottom-left {
    left: 24px;
}

.tac-position-bottom-right {
    right: 24px;
}

.tac-cookie-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    width: min(1200px, calc(100% - 40px));
    margin: 0 auto;
    padding: 18px 0;
}

.tac-position-bottom-left .tac-cookie-inner,
.tac-position-bottom-right .tac-cookie-inner {
    display: block;
    width: 100%;
    padding: 22px;
}

.tac-cookie-content {
    min-width: 0;
}

.tac-cookie-title {
    display: block;
    margin: 0 0 4px;
    font-size: 16px;
    line-height: 1.3;
}

.tac-cookie-message {
    margin: 0;
    font-size: 14px;
    opacity: .82;
}

.tac-cookie-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex: 0 0 auto;
    gap: 10px;
}

.tac-position-bottom-left .tac-cookie-actions,
.tac-position-bottom-right .tac-cookie-actions {
    justify-content: flex-start;
    flex-wrap: wrap;
    margin-top: 18px;
}

.tac-cookie-btn,
.tac-cookie-policy {
    appearance: none;
    -webkit-appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 10px 16px;
    border-radius: 8px;
    font: inherit;
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    text-decoration: none;
    transition: opacity .2s ease, transform .2s ease, background-color .2s ease;
}

.tac-cookie-btn:hover,
.tac-cookie-policy:hover {
    opacity: .88;
}

.tac-cookie-btn:focus-visible,
.tac-cookie-policy:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 3px;
}

.tac-cookie-accept {
    color: var(--tac-btn-text);
    background: var(--tac-btn);
    border: 1px solid var(--tac-btn);
}

.tac-cookie-reject {
    color: var(--tac-text);
    background: transparent;
    border: 1px solid var(--tac-border);
}

.tac-cookie-policy {
    color: var(--tac-text);
    min-height: auto;
    padding-inline: 4px;
    text-decoration: underline;
    text-underline-offset: 3px;
}

@media (max-width: 767px) {
    .tac-position-bottom-left,
    .tac-position-bottom-right {
        left: 12px;
        right: 12px;
        bottom: 12px;
        width: auto;
    }

    .tac-cookie-inner {
        display: block;
        width: 100%;
        padding: 18px;
    }

    .tac-position-bottom {
        border-radius: 16px 16px 0 0;
    }

    .tac-cookie-title {
        font-size: 15px;
    }

    .tac-cookie-message {
        font-size: 13px;
    }

    .tac-cookie-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        margin-top: 16px;
    }

    .tac-cookie-policy {
        grid-column: 1 / -1;
        justify-content: flex-start;
        padding-left: 0;
        margin-bottom: 2px;
    }

    .tac-cookie-btn {
        width: 100%;
        min-width: 0;
    }
}

@media (max-width: 420px) {
    .tac-cookie-actions {
        grid-template-columns: 1fr;
    }

    .tac-cookie-policy {
        grid-column: auto;
    }
}
