/* ==============================
   Cookie Consent Banner Styles
   Matches TypingSpeedTest.co design
   ============================== */

.cookie-consent-overlay {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 99999;
    pointer-events: none;
    display: flex;
    justify-content: center;
    padding: 1rem;
    animation: cookieSlideUp 0.5s ease-out;
}

.cookie-consent-banner {
    pointer-events: all;
    max-width: 720px;
    width: 100%;
    background: var(--surface, #1a1a1a);
    border: 1px solid var(--border, rgba(255, 255, 255, 0.1));
    border-radius: 16px;
    padding: 1.5rem 2rem;
    box-shadow: 0 -4px 30px rgba(0, 0, 0, 0.3), 0 0 60px rgba(100, 108, 255, 0.08);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.cookie-consent-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.cookie-consent-header {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.cookie-consent-icon {
    font-size: 1.5rem;
    line-height: 1;
}

.cookie-consent-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text, #e8e8e8);
    margin: 0;
}

.cookie-consent-text {
    font-size: 0.88rem;
    line-height: 1.6;
    color: var(--text-dim, #999);
    margin: 0;
}

.cookie-consent-text a {
    color: var(--accent, #646cff);
    text-decoration: none;
    font-weight: 500;
    transition: opacity 0.2s;
}

.cookie-consent-text a:hover {
    opacity: 0.8;
    text-decoration: underline;
}

.cookie-consent-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.cookie-btn {
    padding: 0.6rem 1.5rem;
    border-radius: 8px;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    font-family: inherit;
    white-space: nowrap;
}

.cookie-btn-accept {
    background: linear-gradient(135deg, #646cff, #535bf2);
    color: #fff;
    box-shadow: 0 2px 12px rgba(100, 108, 255, 0.3);
}

.cookie-btn-accept:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(100, 108, 255, 0.4);
}

.cookie-btn-decline {
    background: var(--surface-hover, #252525);
    color: var(--text-dim, #999);
    border: 1px solid var(--border, rgba(255, 255, 255, 0.1));
}

.cookie-btn-decline:hover {
    color: var(--text, #e8e8e8);
    border-color: var(--text-dim, #666);
}

.cookie-consent-banner.cookie-hidden {
    display: none;
}

@keyframes cookieSlideUp {
    from {
        opacity: 0;
        transform: translateY(100%);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Light mode overrides */
:root:not(.dark) .cookie-consent-banner,
body:not(.dark) .cookie-consent-banner {
    background: #ffffff;
    border-color: rgba(0, 0, 0, 0.1);
    box-shadow: 0 -4px 30px rgba(0, 0, 0, 0.1), 0 0 60px rgba(100, 108, 255, 0.05);
}

:root:not(.dark) .cookie-consent-title,
body:not(.dark) .cookie-consent-title {
    color: #1a1a1a;
}

:root:not(.dark) .cookie-consent-text,
body:not(.dark) .cookie-consent-text {
    color: #666;
}

:root:not(.dark) .cookie-btn-decline,
body:not(.dark) .cookie-btn-decline {
    background: #f0f0f0;
    color: #666;
    border-color: rgba(0, 0, 0, 0.1);
}

:root:not(.dark) .cookie-btn-decline:hover,
body:not(.dark) .cookie-btn-decline:hover {
    color: #1a1a1a;
}

/* Responsive */
@media (max-width: 600px) {
    .cookie-consent-overlay {
        padding: 0.75rem;
    }

    .cookie-consent-banner {
        padding: 1.25rem 1.25rem;
        border-radius: 12px;
    }

    .cookie-consent-actions {
        flex-direction: column;
    }

    .cookie-btn {
        width: 100%;
        text-align: center;
        padding: 0.7rem 1rem;
    }
}
