/* ========================================
   ATHÉNA LUXE - GESTION DES COOKIES RGPD
   Version: 1.4.5
   Date: 30 Novembre 2024
   ======================================== */

/* === VARIABLES === */
:root {
    --cookie-primary: #c9a961;
    --cookie-dark: #2c2c2c;
    --cookie-light: #ffffff;
    --cookie-overlay: rgba(0, 0, 0, 0.7);
    --cookie-border: rgba(201, 169, 97, 0.3);
    --cookie-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

/* === BANNIÈRE COOKIES (POPUP PRINCIPAL) === */
#cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, var(--cookie-dark) 0%, #1a1a1a 100%);
    color: var(--cookie-light);
    padding: 30px 20px;
    box-shadow: var(--cookie-shadow);
    z-index: 999999;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-top: 3px solid var(--cookie-primary);
}

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

.cookie-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    flex-wrap: wrap;
}

.cookie-content {
    flex: 1;
    min-width: 300px;
}

.cookie-content h3 {
    font-family: 'Playfair Display', serif;
    font-size: 24px;
    color: var(--cookie-primary);
    margin: 0 0 10px 0;
    font-weight: 600;
}

.cookie-content p {
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    line-height: 1.6;
    margin: 0 0 15px 0;
    color: #e0e0e0;
}

.cookie-content a {
    color: var(--cookie-primary);
    text-decoration: underline;
    transition: color 0.3s ease;
}

.cookie-content a:hover {
    color: #d4b76a;
}

.cookie-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.cookie-btn {
    padding: 12px 25px;
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    font-weight: 600;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cookie-btn-accept {
    background: var(--cookie-primary);
    color: var(--cookie-dark);
}

.cookie-btn-accept:hover {
    background: #d4b76a;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(201, 169, 97, 0.4);
}

.cookie-btn-refuse {
    background: transparent;
    color: var(--cookie-light);
    border: 2px solid #666;
}

.cookie-btn-refuse:hover {
    background: #333;
    border-color: #888;
}

.cookie-btn-customize {
    background: transparent;
    color: var(--cookie-primary);
    border: 2px solid var(--cookie-primary);
}

.cookie-btn-customize:hover {
    background: var(--cookie-primary);
    color: var(--cookie-dark);
}

/* === ICON COOKIES === */
.cookie-icon {
    font-size: 40px;
    margin-right: 20px;
    display: none;
}

/* === MODAL PERSONNALISATION === */
#cookie-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--cookie-overlay);
    z-index: 1000000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

#cookie-modal.show {
    display: flex;
    opacity: 1;
}

.cookie-modal-content {
    background: var(--cookie-light);
    border-radius: 10px;
    max-width: 700px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.cookie-modal-header {
    background: linear-gradient(135deg, var(--cookie-dark) 0%, #1a1a1a 100%);
    color: var(--cookie-light);
    padding: 25px 30px;
    border-bottom: 3px solid var(--cookie-primary);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cookie-modal-header h2 {
    font-family: 'Playfair Display', serif;
    font-size: 26px;
    color: var(--cookie-primary);
    margin: 0;
}

.cookie-modal-close {
    background: transparent;
    border: none;
    color: var(--cookie-light);
    font-size: 30px;
    cursor: pointer;
    transition: transform 0.3s ease, color 0.3s ease;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cookie-modal-close:hover {
    color: var(--cookie-primary);
    transform: rotate(90deg);
}

.cookie-modal-body {
    padding: 30px;
    color: var(--cookie-dark);
}

.cookie-category {
    margin-bottom: 25px;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 8px;
    border-left: 4px solid var(--cookie-primary);
}

.cookie-category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.cookie-category h3 {
    font-family: 'Playfair Display', serif;
    font-size: 18px;
    color: var(--cookie-dark);
    margin: 0;
}

.cookie-category p {
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    line-height: 1.6;
    color: #555;
    margin: 10px 0 0 0;
}

/* === TOGGLE SWITCH === */
.cookie-toggle {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 30px;
}

.cookie-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.cookie-toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.4s;
    border-radius: 30px;
}

.cookie-toggle-slider:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: 0.4s;
    border-radius: 50%;
}

.cookie-toggle input:checked + .cookie-toggle-slider {
    background-color: var(--cookie-primary);
}

.cookie-toggle input:checked + .cookie-toggle-slider:before {
    transform: translateX(30px);
}

.cookie-toggle input:disabled + .cookie-toggle-slider {
    background-color: #999;
    cursor: not-allowed;
}

.cookie-toggle-label {
    margin-left: 10px;
    font-size: 12px;
    color: #999;
    font-style: italic;
}

/* === BOUTONS MODAL === */
.cookie-modal-footer {
    padding: 20px 30px;
    background: #f5f5f5;
    border-top: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    gap: 15px;
    flex-wrap: wrap;
}

/* === BADGE "COOKIES" (ICÔNE FLOTTANTE) === */
#cookie-settings-btn {
    position: fixed;
    bottom: 20px;
    left: 20px;
    background: var(--cookie-primary);
    color: var(--cookie-dark);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    z-index: 999998;
    opacity: 0;
    visibility: hidden;
}

#cookie-settings-btn.show {
    opacity: 1;
    visibility: visible;
}

#cookie-settings-btn:hover {
    background: #d4b76a;
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(201, 169, 97, 0.5);
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
    #cookie-banner {
        padding: 20px 15px;
    }

    .cookie-container {
        flex-direction: column;
        gap: 20px;
    }

    .cookie-content h3 {
        font-size: 20px;
    }

    .cookie-content p {
        font-size: 13px;
    }

    .cookie-buttons {
        width: 100%;
        flex-direction: column;
    }

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

    .cookie-modal-content {
        margin: 10px;
    }

    .cookie-modal-header {
        padding: 20px;
    }

    .cookie-modal-header h2 {
        font-size: 22px;
    }

    .cookie-modal-body {
        padding: 20px;
    }

    .cookie-category {
        padding: 15px;
    }

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

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

    #cookie-settings-btn {
        bottom: 15px;
        left: 15px;
        width: 45px;
        height: 45px;
        font-size: 20px;
    }
}

@media (max-width: 480px) {
    .cookie-content h3 {
        font-size: 18px;
    }

    .cookie-content p {
        font-size: 12px;
    }

    .cookie-btn {
        padding: 10px 20px;
        font-size: 13px;
    }
}

/* === ANIMATIONS === */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

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

/* === PRINT (MASQUER SUR IMPRESSION) === */
@media print {
    #cookie-banner,
    #cookie-modal,
    #cookie-settings-btn {
        display: none !important;
    }
}
