/* Variables CSS pour la couleur personnalisée */
:root {
    --primary-color: #DC3545;
    --primary-hover: #bb2d3b;
}

/* Couleurs personnalisées pour Bootstrap */
.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
}

/* Cookie Banner Styles */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    border-top: 1px solid #e9ecef;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 9999;
}

.cookie-banner.show {
    transform: translateY(0);
}

.cookie-title {
    font-weight: 700;
    color: #212529;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.cookie-subtitle {
    color: #6c757d;
    font-size: 0.95rem;
    line-height: 1.4;
}

/* Settings Modal Styles */
.modal-content {
    border: none;
    border-radius: 1rem;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
}

.modal-header {
    border-bottom: 1px solid #dee2e6;
    padding: 1.5rem;
}

.modal-title {
    font-weight: 700;
    font-size: 1.5rem;
    color: #212529;
}

.modal-subtitle {
    color: #6c757d;
    font-size: 0.95rem;
    margin-bottom: 0;
    margin-top: 0.5rem;
}

/* Purpose Categories */
.purpose-category {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 0.75rem;
    margin-bottom: 1rem;
}

.purpose-title {
    font-weight: 600;
    color: #212529;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.1rem;
}

.purpose-description {
    color: #6c757d;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 0.5rem;
}

.purpose-details {
    font-size: 0.8rem;
    color: #6c757d;
    background: white;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    margin-top: 0.5rem;
    line-height: 1.4;
}

/* Custom Toggle Switch avec couleur rouge */
.form-switch .form-check-input {
    width: 3.25rem;
    height: 1.75rem;
    background-color: #dee2e6;
    border: none;
    border-radius: 1rem;
    background-image: none;
}

.form-switch .form-check-input:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    background-image: none;
}

.form-switch .form-check-input:focus {
    box-shadow: 0 0 0 0.25rem rgba(220, 53, 69, 0.25);
}

.form-switch .form-check-input:disabled {
    background-color: #6c757d;
    opacity: 0.65;
}

.form-switch .form-check-input::before {
    content: '';
    position: absolute;
    top: calc(50% + 2px);
    left: 0.125rem;
    transform: translateY(-50%);
    width: 1.375rem;
    height: 1.375rem;
    background: white;
    border-radius: 50%;
    transition: transform 0.2s ease-in-out;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.form-switch .form-check-input:checked::before {
    transform: translateY(-50%) translateX(1.5rem);
}

/* Footer info styling */
.footer-info {
    font-size: 0.8rem;
    color: #6c757d;
    display: flex;
    align-items: center;
}

/* Responsive pour mobile */
@media (max-width: 767.98px) {
    .cookie-banner .row {
        flex-direction: column;
        text-align: center;
    }
    
    .cookie-banner .btn {
        margin: 0.25rem 0;
        width: 100%;
    }
    
    .cookie-banner .d-md-flex {
        display: block !important;
    }
    
    .modal-dialog {
        margin: 1rem;
    }
    
    .modal-header,
    .modal-body,
    .modal-footer {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    .modal-footer {
        flex-direction: column;
        gap: 1rem;
    }
    
    .modal-footer > div {
        width: 100%;
        text-align: center;
    }
    
    .cookie-title {
        font-size: 1rem;
    }
    
    .cookie-subtitle {
        font-size: 0.9rem;
    }
}

/* Animation d'entrée du bandeau */
.cookie-banner {
    animation-duration: 0.3s;
    animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.cookie-banner.show {
    animation-name: slideUp;
}

@keyframes slideUp {
    from {
        transform: translateY(100%);
    }
    to {
        transform: translateY(0);
    }
}

/* Style pour le backdrop du modal */
.modal-backdrop {
    background-color: rgba(0, 0, 0, 0.6);
}

/* Amélioration des boutons du bandeau */
.cookie-banner .btn {
    font-weight: 500;
    transition: all 0.2s ease;
}

.cookie-banner .btn:hover {
    transform: translateY(-1px);
}

.cookie-banner .btn-link:hover {
    transform: none;
    text-decoration: underline;
}