/**
 * Archives 8 Derniers Mois - Styles
 * Version: 1.0.0
 */

/* ============================================
   STYLE PAR DÉFAUT
   ============================================ */

.custom-archives {
    background: #2a2a2a;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 20px;
}

.custom-archives-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.custom-archives-wrapper .archive-button {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    background: white;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #1a1a1a;
    text-decoration: none;
    text-transform: uppercase;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    cursor: pointer;
}

.custom-archives-wrapper .archive-button:hover {
    background: #FF0000;
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(255, 0, 0, 0.35);
}

/* Bouton du mois actuel */
.custom-archives-wrapper .archive-button.current {
    background: #FF0000;
    color: white;
    box-shadow: 0 4px 12px rgba(255, 0, 0, 0.3);
}

/* Compteur de posts */
.custom-archives-wrapper .archive-button .count {
    font-size: 11px;
    opacity: 0.8;
    font-weight: 500;
}

/* ============================================
   STYLE OUTLINED
   ============================================ */

.custom-archives.style-outlined {
    background: transparent;
    padding: 0;
}

.custom-archives.style-outlined .archive-button {
    background: transparent;
    color: #1a1a1a;
    border: 2px solid #E0E0E0;
}

.custom-archives.style-outlined .archive-button:hover {
    background: #1a1a1a;
    color: white;
    border-color: #1a1a1a;
}

.custom-archives.style-outlined .archive-button.current {
    background: #FF0000;
    color: white;
    border-color: #FF0000;
}

/* ============================================
   STYLE GRADIENT
   ============================================ */

.custom-archives.style-gradient {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.custom-archives.style-gradient .archive-button {
    background: linear-gradient(135deg, #ffffff 0%, #f5f5f5 100%);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.custom-archives.style-gradient .archive-button:hover {
    background: linear-gradient(135deg, #FF0000 0%, #CC0000 100%);
    color: white;
    box-shadow: 0 6px 20px rgba(255, 0, 0, 0.4);
}

.custom-archives.style-gradient .archive-button.current {
    background: linear-gradient(135deg, #FF0000 0%, #CC0000 100%);
    color: white;
}

/* ============================================
   STYLE PILLS (Arrondi)
   ============================================ */

.custom-archives.style-pills .archive-button {
    border-radius: 50px;
    padding: 10px 24px;
}

/* ============================================
   RESPONSIVE
   ============================================ */

/* Tablet */
@media (max-width: 1024px) {
    .custom-archives {
        padding: 20px;
    }
    
    .custom-archives-wrapper {
        gap: 8px;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .custom-archives {
        padding: 15px;
    }
    
    .custom-archives-wrapper {
        gap: 8px;
    }
    
    .custom-archives-wrapper .archive-button {
        font-size: 12px;
        padding: 8px 16px;
    }
    
    .custom-archives-wrapper .archive-button .count {
        font-size: 10px;
    }
}

/* Très petit mobile */
@media (max-width: 480px) {
    .custom-archives {
        padding: 12px;
    }
    
    .custom-archives-wrapper {
        gap: 6px;
    }
    
    .custom-archives-wrapper .archive-button {
        font-size: 11px;
        padding: 7px 14px;
    }
}

/* ============================================
   ANIMATIONS
   ============================================ */

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.custom-archives-wrapper .archive-button {
    animation: fadeInUp 0.4s ease-out backwards;
}

.custom-archives-wrapper .archive-button:nth-child(1) { animation-delay: 0.05s; }
.custom-archives-wrapper .archive-button:nth-child(2) { animation-delay: 0.1s; }
.custom-archives-wrapper .archive-button:nth-child(3) { animation-delay: 0.15s; }
.custom-archives-wrapper .archive-button:nth-child(4) { animation-delay: 0.2s; }
.custom-archives-wrapper .archive-button:nth-child(5) { animation-delay: 0.25s; }
.custom-archives-wrapper .archive-button:nth-child(6) { animation-delay: 0.3s; }
.custom-archives-wrapper .archive-button:nth-child(7) { animation-delay: 0.35s; }
.custom-archives-wrapper .archive-button:nth-child(8) { animation-delay: 0.4s; }

/* ============================================
   ACCESSIBILITÉ
   ============================================ */

.custom-archives-wrapper .archive-button:focus {
    outline: 3px solid rgba(255, 0, 0, 0.5);
    outline-offset: 2px;
}

.custom-archives-wrapper .archive-button:focus:not(:focus-visible) {
    outline: none;
}

/* Pour les utilisateurs préférant réduire les animations */
@media (prefers-reduced-motion: reduce) {
    .custom-archives-wrapper .archive-button {
        animation: none;
        transition: none;
    }
    
    .custom-archives-wrapper .archive-button:hover {
        transform: none;
    }
}

/* ============================================
   DARK MODE (si le thème le supporte)
   ============================================ */

@media (prefers-color-scheme: dark) {
    .custom-archives.style-outlined .archive-button {
        color: #ffffff;
        border-color: rgba(255, 255, 255, 0.3);
    }
    
    .custom-archives.style-outlined .archive-button:hover {
        background: white;
        color: #1a1a1a;
        border-color: white;
    }
}