.analytics-consent[hidden] {
    display: none;
}

.analytics-consent {
    position: fixed;
    z-index: 10020;
    right: 0.85rem;
    bottom: 0.85rem;
    left: 0.85rem;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    width: min(820px, calc(100% - 1.7rem));
    margin: 0 auto;
    padding: 0.8rem 0.9rem 0.8rem 1rem;
    color: #fff;
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 0.9rem;
    box-shadow: var(--shadow-sm);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
}

.analytics-consent-copy {
    min-width: 0;
}

.analytics-consent h2 {
    margin: 0 0 0.18rem;
    color: #fff;
    font-size: 1rem;
    line-height: 1.25;
    text-shadow: 0 1px 3px rgba(0, 20, 44, 0.5);
}

.analytics-consent p {
    margin: 0;
    color: rgba(244, 247, 250, 0.84);
    font-size: 0.8rem;
    line-height: 1.38;
}

.analytics-consent a,
.analytics-settings-link {
    color: rgba(225, 239, 255, 0.9);
    text-decoration: underline;
    text-underline-offset: 0.2em;
}

.analytics-consent-actions {
    display: flex;
    flex: 0 0 auto;
    gap: 0.5rem;
}

.analytics-consent-actions button {
    min-height: 2.3rem;
    padding: 0.48rem 0.78rem;
    border: 1px solid transparent;
    border-radius: 0.6rem;
    font: inherit;
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    cursor: pointer;
    transition: background-color 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.analytics-consent-accept {
    color: #fff;
    background: #0d6efd;
    border-color: rgba(170, 213, 255, 0.45) !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22);
}

.analytics-consent-decline {
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.055);
    border-color: rgba(255, 255, 255, 0.2) !important;
}

.analytics-consent-accept:hover {
    background: #0a58ca;
}

.analytics-consent-decline:hover {
    background: rgba(255, 255, 255, 0.11);
    border-color: rgba(255, 255, 255, 0.34) !important;
}

.analytics-consent-actions button:active {
    transform: translateY(1px);
}

.analytics-consent-actions button:focus-visible,
.analytics-settings-link:focus-visible {
    outline: 3px solid rgba(148, 207, 255, 0.92);
    outline-offset: 2px;
}

.analytics-settings-link {
    padding: 0;
    background: none;
    border: 0;
    font: inherit;
    cursor: pointer;
}

@media (max-width: 736px) {
    .analytics-consent {
        align-items: stretch;
        flex-direction: column;
        gap: 0.7rem;
        padding: 0.85rem;
    }

    .analytics-consent-actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    .analytics-consent-actions button {
        width: 100%;
    }
}

@media (prefers-reduced-transparency: reduce) {
    .analytics-consent {
        background: #1f1f1f;
        -webkit-backdrop-filter: none;
        backdrop-filter: none;
    }
}
