/* ==========================================================================
   1. PALETTE DE COULEURS & VARIABLES
========================================================================== */
:root {
    --la-orange: #FAA940;
    --la-orange-d: #f89310;
    --la-rose: #FF006B;
    --la-rose-d: #dc0b63;
    --la-rouge: #da0a0e;
    --la-rouge-d: #971012;
    --la-mauve: #d00bf4;
    --la-mauve-d: #9f07bb;
    --la-jaune: #fef00e;
    --la-jaune-d: #d6cc25;

    /* Dégradés d'ambiance */
    --grad-rose-orange: linear-gradient(135deg, var(--la-rose), var(--la-orange-d));
    --grad-mauve-rose: linear-gradient(135deg, var(--la-mauve), var(--la-rose-d));
    --grad-rouge-orange: linear-gradient(135deg, var(--la-rouge), var(--la-orange));
    --grad-jaune-orange: linear-gradient(135deg, var(--la-jaune), var(--la-orange-d));
}

/* ==========================================================================
   2. DESIGN GLOBAL : STRUCTURATION
========================================================================== */
.la-global-grid {
    max-width: 1650px;
    margin: 0 auto;
    padding: 20px;
    display: grid;
    /* La colonne des articles prend plus de place, la sidebar des tags est plus fine */
    grid-template-columns: 1fr minmax(250px, 300px); 
    gap: 40px;
    align-items: start;
}

.la-container { max-width: 100%; padding: 0; }
.la-img-cover { width: 100%; height: 100%; object-fit: cover; object-position: center; }

.la-section-title {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 25px;
    color: #fff;
}

/* ==========================================================================
   3. HERO GRID (Carrousel horizontal en haut + Article à la une en bas)
========================================================================== */
.la-hero-section { padding-bottom: 30px; }

.la-grid-top {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* --- CAROUSEL (Derniers articles - Maintenant Horizontal) --- */
.la-latest-carousel {
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 15px;
    scrollbar-width: thin;
    scrollbar-color: var(--la-orange) rgba(255, 255, 255, 0.05);
}

.la-latest-carousel::-webkit-scrollbar { height: 6px; }
.la-latest-carousel::-webkit-scrollbar-thumb { background-color: var(--la-orange); border-radius: 10px; }
.la-latest-carousel::-webkit-scrollbar-track { background: rgba(255, 255, 255, 0.05); border-radius: 10px; }

.la-latest-list {
    display: flex;
    flex-direction: row;
    gap: 20px;
}

.la-latest-item {
    flex: 0 0 280px; /* Largeur fixe pour faire un effet carrousel */
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 12px;
    border-radius: 14px;
    background: rgba(20, 20, 24, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: transform 0.3s ease;
}

.la-latest-item:hover { transform: translateY(-5px); border-color: rgba(255, 255, 255, 0.15); }

.la-latest-img {
    width: 100%;
    height: 140px;
    border-radius: 8px;
    overflow: hidden;
}

.la-latest-content h4 { font-size: 1rem; font-weight: 700; color: #fff; line-height: 1.3; margin-top: 5px; }

/* --- ARTICLE À LA UNE (En dessous) --- */
.la-featured {
    display: flex;
    flex-direction: column;
    padding: 20px;
    gap: 20px;
    border-radius: 20px;
    overflow: hidden;
    background: rgba(20, 20, 24, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.la-featured-img-wrap { width: 100%; height: 350px; border-radius: 12px; overflow: hidden; }
.la-featured-img-wrap .la-img-cover { object-position: top center; }

.la-featured-content { display: flex; flex-direction: column; text-align: left; }
.la-featured-title { font-size: 2rem; font-weight: 800; color: #fff; margin: 10px 0 0 0; line-height: 1.3; }
.la-featured-desc { font-size: 1.05rem; color: rgba(255, 255, 255, 0.7); line-height: 1.6; margin: 10px 0 0 0; }

.la-featured-btn-full {
    display: inline-block;
    width: auto;
    align-self: flex-start;
    text-align: center;
    margin-top: 20px;
    padding: 14px 40px;
    border-radius: 8px;
    background: var(--grad-rose-orange);
    color: #fff;
    font-size: 1rem;
    font-weight: 800;
    text-transform: uppercase;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
}
.la-featured-btn-full:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(255, 0, 107, 0.3); color: #fff; }

/* --- BADGES --- */
.la-badges-wrapper { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.la-badge { padding: 4px 12px; border-radius: 20px; font-size: 0.75rem; font-weight: 900; }
.bg-rose { background: #FF006B; color:#fff;}
.la-meta-badge {
    background: rgba(255, 255, 255, 0.15); color: #e2e2e2; padding: 4px 10px; border-radius: 20px;
    font-size: 0.7rem; font-weight: 700; backdrop-filter: blur(5px); border: 1px solid rgba(255, 255, 255, 0.1);
}

/* ==========================================================================
   4. NOUVELLE BARRE DE FILTRES EN HAUT (List Section)
========================================================================== */
.la-list-section { padding: 20px 0 50px 0; }

.la-top-filters-wrapper {
    background: rgba(20, 20, 24, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 25px;
    margin-bottom: 40px;
}

.la-top-search { margin-bottom: 25px; }

.la-sidebar-search-pill {
    display: flex; align-items: center; background: rgba(10, 10, 14, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.15); border-radius: 50px; padding: 8px 8px 8px 25px;
    transition: all 0.3s ease;
}
.la-sidebar-search-pill:focus-within { border-color: var(--la-orange); box-shadow: 0 0 20px rgba(250, 169, 64, 0.2); }
.la-sidebar-input-pill { flex: 1; background: transparent; border: none; color: #fff; font-family: inherit; font-size: 1rem; outline: none; }
.la-sidebar-btn-circle {
    background: var(--grad-rose-orange); border: none; width: 48px; height: 48px; border-radius: 50%;
    display: flex; justify-content: center; align-items: center; cursor: pointer; color: #000; transition: all 0.3s ease;
}
.la-sidebar-btn-circle:hover { transform: scale(1.05); }

/* Grille des filtres horizontale */
.la-top-filters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    align-items: end;
}

.la-filter-field { display: flex; flex-direction: column; gap: 8px; }
.la-filter-field label {
    font-size: 0.85rem; font-weight: 900; text-transform: uppercase; letter-spacing: 1px;
    background: linear-gradient(135deg, var(--la-orange), var(--la-orange-d));
    -webkit-background-clip: text; -webkit-text-fill-color: transparent; display: inline-block;
}

.la-sidebar-select {
    background: rgba(0,0,0,0.4); border: 1px solid rgba(255,255,255,0.1); border-radius: 8px;
    padding: 12px; color: #fff; outline: none; font-family: inherit; font-size: 0.9rem; cursor: pointer;
}
.la-sidebar-select:focus { border-color: var(--la-orange); }
.la-sidebar-select option { background: #0f1117; color: #fff; }

.la-engagement-toggles { display: flex; flex-wrap: wrap; gap: 10px; }
.la-sort-btn {
    flex: 1; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff; padding: 12px 15px; border-radius: 8px; cursor: pointer; font-size: 0.75rem; font-weight: 700;
    display: flex; align-items: center; justify-content: center; gap: 6px; transition: all 0.3s ease; text-transform: uppercase; white-space: nowrap;
}
.la-sort-btn:hover { background: rgba(255, 255, 255, 0.1); transform: translateY(-2px); }
.la-sort-btn[data-active="true"] { background: var(--grad-mauve-rose); border-color: transparent; box-shadow: 0 8px 20px rgba(208, 11, 244, 0.3); }

/* ==========================================================================
   5. FLUX DES ARTICLES (Header, Liste, Grille)
========================================================================== */
.la-list-header {
    display: flex; justify-content: space-between; align-items: center;
    border-bottom: 1px solid rgba(255,255,255,0.08); padding-bottom: 15px; margin-bottom: 30px;
}
.la-view-toggles { display: flex; gap: 10px; }
.la-toggle { background: transparent; border: none; color: rgba(255,255,255,0.4); font-weight: 800; font-size: 0.8rem; display: flex; align-items: center; gap: 6px; cursor: pointer; }
.la-toggle.active, .la-toggle:hover { color: #FF006B; }

.la-articles-feed { display: flex; flex-direction: column; gap: 20px; }
.la-article-row {
    display: grid; grid-template-columns: 80px 240px 1fr; gap: 30px; align-items: center;
    padding-bottom: 25px; border-bottom: 1px solid rgba(255,255,255,0.05);
}
.la-row-date { display: flex; flex-direction: column; align-items: center; border-top: 2px solid rgba(255,255,255,0.1); padding-top: 10px; }
.la-month { font-size: 0.75rem; font-weight: 800; opacity: 0.6; text-transform: uppercase; }
.la-day { font-size: 2.2rem; font-weight: 900; color: #fff; line-height: 1; margin: 2px 0; }
.la-year { font-size: 0.8rem; font-weight: 700; color: rgba(255,255,255,0.4); }

.la-row-img-wrap { height: 160px; border-radius: 10px; overflow: hidden; }
.la-row-content h3 { font-size: 1.4rem; font-weight: 800; color: #fff; margin-bottom: 8px; }
.la-row-meta { font-size: 0.85rem; opacity: 0.5; margin-bottom: 10px; }
.la-row-excerpt { font-size: 0.95rem; opacity: 0.7; line-height: 1.5; margin-bottom: 15px; }
.la-row-link { font-size: 0.8rem; font-weight: 800; text-transform: uppercase; color: #FF006B; text-decoration: none; }

/* MODE GRILLE */
.la-articles-feed.grid-mode { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.la-articles-feed.grid-mode .la-article-row { display: flex; flex-direction: column; align-items: stretch; padding: 15px; background: rgba(20, 20, 24, 0.4); border: 1px solid rgba(255,255,255,0.06); border-radius: 16px; height: 100%; }
.la-articles-feed.grid-mode .la-row-date { flex-direction: row; gap: 6px; border: none; padding: 0; margin-bottom: 10px; align-items: baseline; }
.la-articles-feed.grid-mode .la-day { font-size: 1.4rem; }
.la-articles-feed.grid-mode .la-month, .la-articles-feed.grid-mode .la-year { font-size: 0.75rem; }
.la-articles-feed.grid-mode .la-row-img-wrap { width: 100%; height: 180px; margin-bottom: 12px; }
.la-articles-feed.grid-mode .la-row-content h3 { font-size: 1.1rem; line-height: 1.3; }
.la-articles-feed.grid-mode .la-row-excerpt { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* ==========================================================================
   6. SIDEBAR (Uniquement Mots-clés)
========================================================================== */
.la-sidebar-global {
    display: flex; flex-direction: column; gap: 25px; position: sticky; top: 90px;
    max-height: calc(100vh - 100px); overflow-y: auto; scrollbar-width: none;
}

.la-widget { padding: 25px; border-radius: 20px; background: rgba(20, 20, 24, 0.6); border: 1px solid rgba(255, 255, 255, 0.08); }
.la-widget-title { font-size: 1.1rem; font-weight: 800; color: #fff; border-bottom: 1px solid rgba(255,255,255,0.1); padding-bottom: 8px; margin-bottom: 18px; }

.la-tag-list { display: flex; flex-wrap: wrap; padding: 5px 0; }
.la-keyword-btn {
    background: transparent; color: rgba(255, 255, 255, 0.8); padding: 8px 15px; border-radius: 8px;
    font-size: 0.8rem; font-weight: 600; cursor: pointer; transition: all 0.3s ease; margin-right: 8px; margin-bottom: 10px;
}
.la-keyword-btn:nth-child(odd) { background: rgba(255, 0, 107, 0.1); border: 1px solid rgba(255, 0, 107, 0.4); }
.la-keyword-btn:nth-child(even) { background: rgba(250, 169, 64, 0.1); border: 1px solid rgba(250, 169, 64, 0.4); }
.la-keyword-btn:hover, .la-keyword-btn.active { transform: translateY(-3px); color: #fff; border-color: transparent; }
.la-keyword-btn:nth-child(odd):hover, .la-keyword-btn:nth-child(odd).active { background: var(--grad-mauve-rose); box-shadow: 0 5px 15px rgba(208, 11, 244, 0.3); }
.la-keyword-btn:nth-child(even):hover, .la-keyword-btn:nth-child(even).active { background: var(--grad-jaune-orange); box-shadow: 0 5px 15px rgba(250, 169, 64, 0.3); }

/* ==========================================================================
   7. PAGINATION & AUTRES SECTIONS
========================================================================== */
.la-pagination-modern { display: flex; justify-content: center; align-items: center; gap: 8px; margin-top: 40px; }
.la-page-btn { width: 42px; height: 42px; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 10px; color: #fff; font-size: 1rem; font-weight: 800; cursor: pointer; display: flex; justify-content: center; align-items: center; transition: all 0.3s ease; }
.la-page-btn:hover:not(.active) { background: rgba(255, 255, 255, 0.15); transform: translateY(-2px); }
.la-page-btn.active { background: var(--grad-rose-orange); color: #000; border: none; box-shadow: 0 8px 25px rgba(255, 0, 107, 0.4); transform: scale(1.1); }
.la-page-dots { color: rgba(255, 255, 255, 0.5); font-weight: 800; padding: 0 5px; letter-spacing: 2px; }

/* ==========================================================================
   8. RESPONSIVE DESIGN
========================================================================== */
@media (max-width: 1024px) {
    .la-global-grid { grid-template-columns: 1fr; }
    .la-sidebar-global { position: static; display: block; }
}

@media (max-width: 768px) {
    .la-article-row { grid-template-columns: 1fr; gap: 15px; }
    .la-row-date { flex-direction: row; gap: 10px; border: none; padding: 0; align-self: flex-start; }
    .la-row-img-wrap { height: 200px; width: 100%; }
    .la-featured-img-wrap { height: 250px; }
    .la-featured-title { font-size: 1.5rem; }
    .la-top-filters-grid { grid-template-columns: 1fr; }
}