/* Modern Cookie Consent - Toast Style */
:root {
    --cookie-bg: rgba(255, 255, 255, 0.95);
    --cookie-text: #334155;
    --cookie-border: rgba(255, 255, 255, 0.5);
    --cookie-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.15);
    --cookie-primary: #2563EB;
    --cookie-primary-hover: #1d4ed8;
}

.cookie-banner-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: calc(100% - 48px);
    max-width: 400px;
    background: var(--cookie-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--cookie-border);
    border-radius: 16px;
    padding: 20px;
    box-shadow: var(--cookie-shadow);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 16px;
    animation: cookieSlideUp 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    font-family: 'Montserrat', sans-serif;
}

@keyframes cookieSlideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.cookie-content {
    display: flex;
    gap: 12px;
}

.cookie-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.cookie-text h5 {
    margin: 0 0 4px 0;
    font-size: 1rem;
    font-weight: 700;
    color: #0F172A;
}

.cookie-text p {
    margin: 0;
    font-size: 0.85rem;
    line-height: 1.5;
    color: var(--cookie-text);
}

.cookie-privacy-link {
    color: var(--cookie-primary);
    text-decoration: underline;
    font-weight: 600;
    transition: color 0.2s;
}

.cookie-privacy-link:hover {
    color: var(--cookie-primary-hover);
}

.cookie-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.btn-cookie {
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-config {
    grid-column: 1 / -1;
    background: transparent;
    color: #64748B;
    text-decoration: underline;
    padding: 4px;
    margin-bottom: 4px;
    font-size: 0.75rem;
}

.btn-reject {
    background: #F1F5F9;
    color: #475569;
    border: 1px solid #E2E8F0;
}

.btn-reject:hover {
    background: #E2E8F0;
    color: #1E293B;
}

.btn-accept {
    background: var(--cookie-primary);
    color: white;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}

.btn-accept:hover {
    background: var(--cookie-primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.3);
}

/* Mobile Optimization */
@media (max-width: 480px) {
    .cookie-banner-container {
        bottom: 16px;
        right: 16px;
        left: 16px;
        width: auto;
        max-width: none;
        padding: 16px;
    }

    .cookie-actions {
        grid-template-columns: 1fr;
    }

    .btn-config {
        order: 3;
        margin-top: 8px;
    }

    .btn-accept {
        order: 1;
    }

    .btn-reject {
        order: 2;
    }
}

/* Modal Styles for Configuration */
.cookie-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.cookie-modal {
    background: white;
    width: 100%;
    max-width: 500px;
    border-radius: 16px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    overflow: hidden;
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from {
        transform: scale(0.95);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid #E2E8F0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    font-size: 1.25rem;
    color: #0F172A;
}

.btn-close-modal {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #64748B;
}

.modal-body {
    padding: 24px;
}

.preference-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #F1F5F9;
}

.preference-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.pref-info h4 {
    margin: 0 0 4px 0;
    font-size: 1rem;
    color: #1E293B;
}

.pref-info p {
    margin: 0;
    font-size: 0.85rem;
    color: #64748B;
}

/* Switch Toggle */
.switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #CBD5E1;
    transition: .4s;
    border-radius: 24px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked+.slider {
    background-color: var(--cookie-primary);
}

input:checked+.slider:before {
    transform: translateX(20px);
}

input:disabled+.slider {
    opacity: 0.5;
    cursor: not-allowed;
}

.modal-footer {
    padding: 16px 24px;
    background: #F8FAFC;
    border-top: 1px solid #E2E8F0;
    display: flex;
    justify-content: flex-end;
}

.btn-save {
    background: #0F172A;
    color: white;
    padding: 10px 24px;
    border-radius: 8px;
    border: none;
    font-weight: 600;
    cursor: pointer;
}