/* 3wCookies.css - Module de consentement Loi 25 par TonCodeur / 3w Labz */
/* Thème Signature ChocoFun : Chocolat Profond, Or & Baie Gourmande */

:root {
    --3w-cookies-bg: rgba(25, 14, 10, 0.95);
    --3w-cookies-glass-bg: rgba(45, 25, 18, 0.75);
    --3w-cookies-border: rgba(212, 163, 89, 0.28);
    --3w-cookies-text: #FDFBF7;
    --3w-cookies-text-muted: #D1C2BA;
    --3w-cookies-primary: #C43D57;
    --3w-cookies-primary-hover: #A82E44;
    --3w-cookies-gold: #D4A359;
    --3w-cookies-radius: 20px;
    --3w-cookies-shadow: 0 25px 60px -12px rgba(0, 0, 0, 0.7);
    --3w-cookies-font: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

#three-w-cookies-banner {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(40px);
    width: calc(100% - 40px);
    max-width: 650px;
    background: var(--3w-cookies-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--3w-cookies-border);
    border-radius: var(--3w-cookies-radius);
    padding: 28px;
    z-index: 99998;
    box-shadow: var(--3w-cookies-shadow);
    display: flex;
    flex-direction: column;
    gap: 24px;
    font-family: var(--3w-cookies-font);
    color: var(--3w-cookies-text);
    transition: transform 0.5s cubic-bezier(0.19, 1, 0.22, 1), opacity 0.4s ease;
    opacity: 0;
    pointer-events: none;
}

#three-w-cookies-banner.active {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
    pointer-events: auto;
}

.three-w-cookies-header {
    display: flex;
    align-items: center;
    gap: 14px;
}

.three-w-cookies-icon {
    font-size: 28px;
    filter: drop-shadow(0 0 10px rgba(196, 61, 87, 0.4));
}

.three-w-cookies-title {
    font-size: 1.25rem;
    font-weight: 800;
    margin: 0;
    letter-spacing: -0.02em;
    color: var(--3w-cookies-text);
}

.three-w-cookies-content {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--3w-cookies-text-muted);
}

.three-w-cookies-content p {
    margin: 0;
}

.three-w-cookies-content a {
    color: var(--3w-cookies-gold);
    text-decoration: none;
    font-weight: 600;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s;
}

.three-w-cookies-content a:hover {
    border-color: var(--3w-cookies-gold);
    color: #FFFFFF;
}

.three-w-cookies-actions {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.three-w-cookies-btn {
    padding: 13px 24px;
    border-radius: 12px;
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    flex: 1;
    outline: none;
    text-align: center;
}

.three-w-cookies-btn-primary {
    background: var(--3w-cookies-primary);
    color: white;
    box-shadow: 0 4px 15px rgba(196, 61, 87, 0.3);
}

.three-w-cookies-btn-primary:hover {
    background: var(--3w-cookies-primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(196, 61, 87, 0.5);
}

.three-w-cookies-btn-primary:active {
    transform: translateY(0);
}

.three-w-cookies-btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--3w-cookies-text);
    border: 1px solid var(--3w-cookies-border);
}

.three-w-cookies-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(212, 163, 89, 0.5);
}

/* Modal Styling */
#three-w-cookies-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(18, 10, 7, 0.88);
    backdrop-filter: blur(10px);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

#three-w-cookies-modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

#three-w-cookies-modal {
    width: calc(100% - 40px);
    max-width: 550px;
    max-height: 90vh;
    overflow-y: auto;
    background: var(--3w-cookies-bg);
    border: 1px solid var(--3w-cookies-border);
    border-radius: 24px;
    padding: 32px;
    box-shadow: var(--3w-cookies-shadow);
    font-family: var(--3w-cookies-font);
    color: var(--3w-cookies-text);
    transform: scale(0.9) translateY(20px);
    transition: transform 0.5s cubic-bezier(0.19, 1, 0.22, 1);
}

#three-w-cookies-modal-overlay.active #three-w-cookies-modal {
    transform: scale(1) translateY(0);
}

.three-w-cookies-modal-header {
    margin-bottom: 32px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.three-w-cookies-modal-title {
    font-size: 1.45rem;
    font-weight: 800;
    margin: 0 0 8px 0;
    letter-spacing: -0.03em;
    color: var(--3w-cookies-text);
}

.three-w-cookies-modal-desc {
    color: var(--3w-cookies-text-muted);
    font-size: 0.9rem;
    line-height: 1.5;
}

.three-w-cookies-category-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 32px;
}

.three-w-cookies-category {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 16px;
    border: 1px solid var(--3w-cookies-border);
    transition: background 0.2s;
}

.three-w-cookies-category:hover {
    background: rgba(255, 255, 255, 0.07);
}

.three-w-cookies-cat-info {
    flex: 1;
    padding-right: 20px;
}

.three-w-cookies-cat-name {
    font-weight: 700;
    font-size: 1rem;
    display: block;
    margin-bottom: 4px;
    color: var(--3w-cookies-text);
}

.three-w-cookies-cat-desc {
    font-size: 0.85rem;
    color: var(--3w-cookies-text-muted);
    line-height: 1.4;
}

/* Toggle Switch Premium */
.three-w-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 28px;
    flex-shrink: 0;
}

.three-w-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.three-w-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.12);
    transition: .3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 28px;
}

.three-w-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

input:checked + .three-w-slider {
    background-color: var(--3w-cookies-primary);
}

input:checked + .three-w-slider:before {
    transform: translateX(22px);
}

input:disabled + .three-w-slider {
    opacity: 0.35;
    cursor: not-allowed;
}

.three-w-cookies-modal-footer {
    display: flex;
    justify-content: flex-end;
}

.three-w-cookies-btn-save {
    width: auto;
    padding-left: 36px;
    padding-right: 36px;
}

/* Floating Settings Button */
#three-w-cookies-settings-trigger {
    position: fixed;
    bottom: 24px;
    left: 24px;
    width: 44px;
    height: 44px;
    background: var(--3w-cookies-bg);
    backdrop-filter: blur(12px);
    border: 1px solid var(--3w-cookies-border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 9998;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
    transition: all 0.3s ease;
}

#three-w-cookies-settings-trigger:hover {
    transform: scale(1.1) rotate(15deg);
    border-color: var(--3w-cookies-gold);
    box-shadow: 0 8px 24px rgba(212, 163, 89, 0.3);
}

#three-w-cookies-settings-trigger svg {
    width: 22px;
    height: 22px;
    fill: var(--3w-cookies-gold);
}

/* Toast */
#three-w-cookies-toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(30px);
    background: var(--3w-cookies-bg);
    border: 1px solid var(--3w-cookies-border);
    color: var(--3w-cookies-text);
    padding: 12px 24px;
    border-radius: 9999px;
    font-size: 0.9rem;
    font-weight: 600;
    font-family: var(--3w-cookies-font);
    box-shadow: var(--3w-cookies-shadow);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    z-index: 9999999;
}

#three-w-cookies-toast.active {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

@media (max-width: 600px) {
    #three-w-cookies-banner {
        bottom: 16px;
        padding: 20px;
        width: calc(100% - 24px);
    }
    
    .three-w-cookies-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .three-w-cookies-btn {
        width: 100%;
    }
}
