/* ================= COOKIE CONSENT ================= */

.cookie-consent {
    position: fixed;
    left: 24px;
    right: 24px;
    bottom: 24px;
    z-index: 9999;
    display: flex;
    justify-content: center;
    pointer-events: none;
}

.cookie-consent-card {
    width: 100%;
    max-width: 1180px;
    padding: 26px;
    border-radius: 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;

    background:
        linear-gradient(135deg, rgba(255,255,255,0.92), rgba(245,248,255,0.86)),
        radial-gradient(circle at 10% 20%, rgba(120,160,255,0.22), transparent 35%);

    border: 1px solid rgba(255,255,255,0.85);
    box-shadow: 0 24px 70px rgba(18, 38, 82, 0.18);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);

    pointer-events: auto;
}

.cookie-eyebrow {
    display: inline-block;
    margin-bottom: 8px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #3267d6;
}

.cookie-consent-content h3 {
    margin: 0 0 8px 0;
    font-size: 1.35rem;
    font-weight: 800;
    color: #101828;
}

.cookie-consent-content p {
    max-width: 720px;
    margin: 0;
    color: #667085;
    line-height: 1.6;
    font-size: 0.98rem;
}

.cookie-consent-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.cookie-btn {
    border: none;
    border-radius: 999px;
    padding: 12px 18px;
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.25s ease;
    white-space: nowrap;
}

.cookie-btn-primary {
    color: #ffffff;
    background: linear-gradient(135deg, #2f6df6, #174ea6);
    box-shadow: 0 12px 28px rgba(47, 109, 246, 0.28);
}

.cookie-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 34px rgba(47, 109, 246, 0.36);
}

.cookie-btn-secondary {
    color: #174ea6;
    background: rgba(47, 109, 246, 0.10);
}

.cookie-btn-secondary:hover {
    background: rgba(47, 109, 246, 0.16);
}

.cookie-btn-ghost {
    color: #475467;
    background: rgba(255,255,255,0.65);
    border: 1px solid rgba(210, 220, 235, 0.9);
}

.cookie-btn-ghost:hover {
    color: #101828;
    background: #ffffff;
}

/* Animation */
.cookie-consent.is-visible .cookie-consent-card {
    animation: cookieSlideUp 0.45s ease forwards;
}

@keyframes cookieSlideUp {
    from {
        opacity: 0;
        transform: translateY(26px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Mobile */
@media (max-width: 768px) {
    .cookie-consent {
        left: 14px;
        right: 14px;
        bottom: 14px;
    }

    .cookie-consent-card {
        padding: 22px;
        border-radius: 24px;
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .cookie-consent-actions {
        width: 100%;
        flex-direction: column;
        align-items: stretch;
    }

    .cookie-btn {
        width: 100%;
        text-align: center;
    }
}

/* ================= COOKIE MODAL ================= */

.cookie-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
}

.cookie-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(10, 18, 35, 0.45);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.cookie-modal-card {
    position: relative;
    width: calc(100% - 40px);
    max-width: 760px;
    margin: 60px auto;
    padding: 34px;
    border-radius: 32px;

    background:
        linear-gradient(135deg, rgba(255,255,255,0.96), rgba(245,248,255,0.92)),
        radial-gradient(circle at top left, rgba(120,160,255,0.18), transparent 35%);

    border: 1px solid rgba(255,255,255,0.8);

    box-shadow:
        0 30px 80px rgba(15, 23, 42, 0.18);

    animation: cookieModalIn 0.35s ease;
}

@keyframes cookieModalIn {
    from {
        opacity: 0;
        transform: translateY(24px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.cookie-modal-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 18px;
}

.cookie-modal-head h3 {
    margin: 6px 0 0 0;
    font-size: 1.9rem;
    font-weight: 800;
    color: #101828;
}

.cookie-modal-x {
    width: 42px;
    height: 42px;
    border: none;
    border-radius: 50%;
    background: rgba(20, 40, 90, 0.06);
    font-size: 1.6rem;
    cursor: pointer;
    transition: all 0.25s ease;
}

.cookie-modal-x:hover {
    background: rgba(20, 40, 90, 0.12);
    transform: rotate(90deg);
}

.cookie-modal-intro {
    color: #667085;
    line-height: 1.7;
    margin-bottom: 28px;
}

.cookie-category {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;

    padding: 22px;
    margin-bottom: 18px;

    border-radius: 24px;

    background: rgba(255,255,255,0.65);

    border: 1px solid rgba(220,228,242,0.8);
}

.cookie-category h4 {
    margin: 0 0 8px 0;
    font-size: 1.08rem;
    font-weight: 700;
    color: #101828;
}

.cookie-category p {
    margin: 0;
    color: #667085;
    line-height: 1.6;
    font-size: 0.95rem;
}

.cookie-required {
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(47,109,246,0.12);
    color: #174ea6;
    font-weight: 700;
    font-size: 0.82rem;
    white-space: nowrap;
}

/* ================= SWITCH ================= */

.cookie-switch {
    position: relative;
    width: 58px;
    height: 32px;
    flex-shrink: 0;
}

.cookie-switch input {
    display: none;
}

.cookie-switch span {
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: #d0d5dd;
    cursor: pointer;
    transition: all 0.25s ease;
}

.cookie-switch span::before {
    content: "";
    position: absolute;
    width: 24px;
    height: 24px;
    left: 4px;
    top: 4px;
    border-radius: 50%;
    background: white;
    transition: all 0.25s ease;
    box-shadow: 0 3px 10px rgba(0,0,0,0.15);
}

.cookie-switch input:checked + span {
    background: linear-gradient(135deg, #2f6df6, #174ea6);
}

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

.cookie-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 14px;
    margin-top: 32px;
}

/* Mobile */

@media (max-width: 768px) {

    .cookie-modal-card {
        width: calc(100% - 24px);
        margin: 18px auto;
        padding: 24px;
        border-radius: 26px;
    }

    .cookie-modal-head h3 {
        font-size: 1.5rem;
    }

    .cookie-category {
        flex-direction: column;
        align-items: flex-start;
    }

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

    .cookie-modal-actions .cookie-btn {
        width: 100%;
    }
}