/* ============================================
   SignaHub Advanced Cookie Consent Styles
   RGPD Compliant Design
   ============================================ */

/* Bannière initiale */
#cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #1a2b3c 0%, #2c3e50 100%);
    color: white;
    padding: 20px;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.2);
    z-index: 10000;
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from {
        transform: translateY(100%);
    }

    to {
        transform: translateY(0);
    }
}

.cookie-banner-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.cookie-banner-text {
    flex: 1;
    margin: 0;
    font-size: 0.95em;
    line-height: 1.5;
}

.cookie-banner-buttons {
    display: flex;
    gap: 12px;
    flex-shrink: 0;
}

/* Boutons cookies */
.cookie-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 0.95em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.cookie-btn-primary {
    background: #00d4aa;
    color: white;
}

.cookie-btn-primary:hover {
    background: #00b894;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 212, 170, 0.3);
}

.cookie-btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.cookie-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
}

.cookie-btn-confirm {
    background: #006233;
    color: white;
}

.cookie-btn-confirm:hover {
    background: #004d28;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 98, 51, 0.3);
}

/* Overlay panneau */
#cookie-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
    animation: fadeIn 0.3s ease-out;
    padding: 20px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Panneau détaillé */
.cookie-panel {
    background: white;
    border-radius: 16px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 40px;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.cookie-panel-title {
    color: #1a2b3c;
    font-size: 1.8em;
    margin: 0 0 16px 0;
    padding-right: 40px;
}

.cookie-panel-intro {
    color: #666;
    line-height: 1.6;
    margin: 0 0 20px 0;
    font-size: 0.95em;
}

.cookie-privacy-link {
    color: #00d4aa;
    text-decoration: none;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 30px;
}

.cookie-privacy-link:hover {
    text-decoration: underline;
}

/* Catégories */
.cookie-categories {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 30px;
}

.cookie-category {
    border: 1px solid #e0e6ed;
    border-radius: 12px;
    padding: 20px;
    background: #f8f9fa;
    transition: all 0.3s ease;
}

.cookie-category:hover {
    border-color: #00d4aa;
    background: white;
    box-shadow: 0 4px 12px rgba(0, 212, 170, 0.1);
}

.cookie-category-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.cookie-category-label {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    user-select: none;
}

.cookie-category-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.cookie-category-label input[type="checkbox"]:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

.cookie-category-name {
    font-weight: 600;
    color: #1a2b3c;
    font-size: 1.1em;
}

.cookie-required {
    font-weight: 400;
    color: #999;
    font-size: 0.85em;
    margin-left: 8px;
}

.cookie-category-desc {
    color: #666;
    font-size: 0.9em;
    line-height: 1.5;
    margin: 0;
    padding-left: 32px;
}

/* Boutons panneau */
.cookie-panel-buttons {
    display: flex;
    gap: 12px;
    margin-top: 30px;
    justify-content: flex-end;
}

/* Bouton fermeture */
.cookie-panel-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: none;
    font-size: 2em;
    color: #999;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.cookie-panel-close:hover {
    background: #f0f0f0;
    color: #333;
}

/* ============================================
   Responsive Design
   ============================================ */

@media (max-width: 768px) {
    .cookie-banner-content {
        flex-direction: column;
        text-align: center;
    }

    .cookie-banner-buttons {
        width: 100%;
        flex-direction: column;
    }

    .cookie-btn {
        width: 100%;
    }

    .cookie-panel {
        padding: 24px;
        margin: 10px;
        max-height: 85vh;
    }

    .cookie-panel-title {
        font-size: 1.4em;
    }

    .cookie-panel-buttons {
        flex-direction: column;
    }

    .cookie-panel-buttons .cookie-btn {
        width: 100%;
    }

    .cookie-category-desc {
        padding-left: 0;
        margin-top: 8px;
    }
}

/* Scrollbar personnalisée pour le panneau */
.cookie-panel::-webkit-scrollbar {
    width: 8px;
}

.cookie-panel::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.cookie-panel::-webkit-scrollbar-thumb {
    background: #00d4aa;
    border-radius: 10px;
}

.cookie-panel::-webkit-scrollbar-thumb:hover {
    background: #00b894;
}