/* Modern Cookie Banner Styles */

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: white;
    color: #334155;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    max-width: 420px;
    border: 1px solid #e2e8f0;
    transform: translateX(450px);
    transition: all 0.3s ease;
    opacity: 0;
}

.cookie-banner.show {
    transform: translateX(0);
    opacity: 1;
}

.cookie-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.cookie-text h4 {
    margin: 0 0 0.5rem 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: #1e293b;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cookie-text p {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.5;
    color: #64748b;
}

.cookie-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.cookie-btn {
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    text-align: center;
}

.cookie-btn.primary {
    background: linear-gradient(135deg, #f78e43 0%, #ff9666 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(247, 142, 67, 0.3);
}

.cookie-btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(247, 142, 67, 0.4);
}

.cookie-btn.secondary {
    background: #f1f5f9;
    color: #475569;
    border: 1px solid #cbd5e1;
}

.cookie-btn.secondary:hover {
    background: #e2e8f0;
    transform: translateY(-1px);
}

.cookie-btn.link {
    background: transparent;
    color: #f78e43;
    text-decoration: underline;
    font-weight: 500;
}

.cookie-btn.link:hover {
    color: #5a67d8;
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1001;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.show {
    opacity: 1;
}

.modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.modal-content {
    background: white;
    border-radius: 15px;
    padding: 0;
    max-width: 500px;
    max-height: 80vh;
    overflow: hidden;
    position: relative;
    z-index: 1;
    transform: scale(0.9);
    transition: transform 0.3s ease;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.2);
}

.modal.show .modal-content {
    transform: scale(1);
}

.modal-header {
    padding: 1.5rem;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    font-size: 1.3rem;
    font-weight: 600;
    color: #1e293b;
}

.modal-close {
    background: #f1f5f9;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    color: #64748b;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: #e2e8f0;
    color: #334155;
}

.modal-body {
    padding: 1.5rem;
    max-height: 60vh;
    overflow-y: auto;
}

.modal-footer {
    padding: 1.5rem;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: flex-end;
}

/* Cookie Category Styles */
.cookie-category {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 1rem 0;
    border-bottom: 1px solid #f1f5f9;
}

.cookie-category:last-child {
    border-bottom: none;
}

.cookie-category div {
    flex: 1;
    margin-right: 1rem;
}

.cookie-category h4 {
    margin: 0 0 0.5rem 0;
    font-size: 1rem;
    font-weight: 600;
    color: #334155;
}

.cookie-category p {
    margin: 0;
    font-size: 0.9rem;
    color: #64748b;
    line-height: 1.4;
}

/* Toggle Switch */
.switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 24px;
    flex-shrink: 0;
}

.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: 0.3s;
    border-radius: 24px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

input:checked + .slider {
    background: linear-gradient(135deg, #f78e43 0%, #ff9666 100%);
}

input:focus + .slider {
    box-shadow: 0 0 0 3px rgba(247, 142, 67, 0.2);
}

input:checked + .slider:before {
    transform: translateX(24px);
}

input:disabled + .slider {
    background-color: #94a3b8;
    cursor: not-allowed;
}

input:disabled + .slider:before {
    background-color: #f1f5f9;
}

/* Responsive Design */
@media (max-width: 768px) {
    .cookie-banner {
        bottom: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
        transform: translateY(400px);
    }
    
    .cookie-banner.show {
        transform: translateY(0);
    }
    
    .modal-content {
        margin: 1rem;
        max-width: none;
    }
    
    .cookie-buttons {
        flex-direction: column;
    }
    
    .cookie-category {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .cookie-category div {
        margin-right: 0;
    }
}

@media (max-width: 480px) {
    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 1rem;
    }
    
    .cookie-banner {
        padding: 1rem;
    }
}

/* Animation classes */
@keyframes slideInRight {
    from {
        transform: translateX(450px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(450px);
        opacity: 0;
    }
}

.cookie-banner.slide-in {
    animation: slideInRight 0.3s ease forwards;
}

.cookie-banner.slide-out {
    animation: slideOutRight 0.3s ease forwards;
}
