/* ============================================================
   lc_news — front
   ============================================================ */

.lc-news-list-section,
.lc-news-article {
    padding: 30px 0 60px 0;
}

/* ---------- LISTE ---------- */

.lc-news-list-header {
    margin-bottom: 30px;
    text-align: center;
}

.lc-news-list-title {
    font-size: 2.2rem;
    margin: 0 0 8px 0;
    font-weight: 700;
}

.lc-news-list-count {
    color: #888;
    margin: 0;
    font-size: 0.95rem;
}

.lc-news-list-layout {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 30px;
}

/* Sans sidebar : une seule colonne pleine largeur */
.lc-news-list-layout--no-sidebar {
    grid-template-columns: 1fr;
}

/* Sidebar */
.lc-news-sidebar-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 14px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid #e5e5e5;
}

/* Sous-titre dans la sidebar (ex : "Magasins" en plus de "Categories") :
   marge superieure pour separer les sections. */
.lc-news-sidebar-title--sub {
    margin-top: 28px;
}

.lc-news-cat-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.lc-news-cat-list li {
    margin-bottom: 6px;
}

.lc-news-cat-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    border-radius: 6px;
    color: #444;
    text-decoration: none;
    font-size: 0.95rem;
    transition: background 0.15s;
}

.lc-news-cat-list a:hover {
    background: #f5f5f5;
    color: #000;
}

.lc-news-cat-list li.active a {
    background: #333;
    color: #fff;
    font-weight: 600;
}

.lc-news-cat-list li.active a:hover {
    background: #222;
    color: #fff;
}

.lc-news-cat-count {
    font-size: 0.85em;
    opacity: 0.7;
}

/* Filtre mobile (liste deroulante) : masque sur desktop, affiche < 900px.
   Voir la media query plus bas pour l'affichage. */
.lc-news-mobile-filter {
    display: none;
    margin-bottom: 22px;
}

.lc-news-mobile-filter-label {
    display: block;
    font-size: 1rem;
    font-weight: 700;
    color: #a7bc44;
    margin: 0 0 8px;
}

.lc-news-mobile-filter .lc-news-filter-select + .lc-news-mobile-filter-label {
    margin-top: 16px;
}

.lc-news-filter-select {
    display: block;
    width: 100%;
    padding: 13px 44px 13px 15px;
    font-size: 1rem;
    line-height: 1.3;
    color: #414142;
    background-color: #fff;
    border: 1px solid #d8d8d8;
    border-radius: 6px;
    cursor: pointer;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    /* chevron gris #414142 */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23414142' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
}

.lc-news-filter-select:focus {
    outline: none;
    border-color: #a7bc44;
    box-shadow: 0 0 0 2px rgba(167, 188, 68, 0.25);
}

/* Grille articles : 1 colonne (1 article par ligne, layout horizontal interne) */
.lc-news-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.lc-news-empty {
    text-align: center;
    color: #888;
    padding: 40px 20px;
    font-style: italic;
}

/* Card article (utilisee en page liste ET dans "a lire aussi") */
.lc-news-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
    transition: transform 0.15s, box-shadow 0.15s;
}

.lc-news-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}

.lc-news-card-link {
    color: inherit;
    text-decoration: none;
}

.lc-news-card-link:hover,
.lc-news-card-link:focus {
    color: inherit;
    text-decoration: none;
}

/* ---------- Layout VERTICAL (utilise dans "a lire aussi") ---------- */
.lc-news-also-grid .lc-news-card-link {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.lc-news-also-grid .lc-news-card-image {
    position: relative;
    aspect-ratio: 1 / 1;
    background: #f0f0f0;
    overflow: hidden;
}

/* ---------- Layout HORIZONTAL (utilise en page liste) ---------- */
.lc-news-grid .lc-news-card-link {
    display: grid;
    grid-template-columns: 180px minmax(0, 1fr);
    gap: 0;
    align-items: stretch;
}

.lc-news-grid .lc-news-card-image {
    position: relative;
    background: #fff;
    overflow: hidden;
    aspect-ratio: 1 / 1;
    width: 180px;
    /* Padding pour eloigner l'image des coins arrondis de la card.
       Evite que le contenu de l'image (cadre, bordure, etc.) soit
       rogne par le border-radius:10px de la card parente. */
    padding: 10px;
    box-sizing: border-box;
}

/* L'image elle-meme dans le layout horizontal : coins droits */
.lc-news-grid .lc-news-card-image img {
    border-radius: 0;
}

/* ---------- Communs aux deux layouts ---------- */
.lc-news-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.lc-news-card-placeholder {
    width: 100%;
    height: 100%;
    min-height: 110px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #bbb;
    font-size: 0.85rem;
    background: linear-gradient(135deg, #f0f0f0, #e0e0e0);
    border-radius: 4px;
}

/* Pastille de date (uniquement dans "a lire aussi" car list utilise date textuelle) */
.lc-news-also-grid .lc-news-card-date {
    position: absolute;
    top: 12px;
    left: 12px;
    background: #fff;
    color: #222;
    border-radius: 8px;
    padding: 6px 10px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1;
    min-width: 44px;
}

.lc-news-card-day {
    font-size: 1.2rem;
    font-weight: 700;
}

.lc-news-card-month {
    font-size: 0.7rem;
    text-transform: uppercase;
    color: #888;
    margin-top: 2px;
    letter-spacing: 0.02em;
}

.lc-news-card-content {
    padding: 16px 18px 20px 18px;
    display: flex;
    flex-direction: column;
    flex: 1;
    position: relative;
}

/* Date textuelle en haut a droite (uniquement en page liste) */
.lc-news-grid .lc-news-card-date-text {
    position: absolute;
    top: 12px;
    right: 16px;
    font-size: 0.78rem;
    color: #999;
    font-weight: 500;
}

.lc-news-card-cats {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

/* En page liste : reserver de la place pour la date a droite */
.lc-news-grid .lc-news-card-cats {
    padding-right: 90px;
}

.lc-news-card-cat {
    display: inline-block;
    background: #f0f0f0;
    color: #555;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

/* Variante OVERLAY : badge categorie pose en bas de la photo, centre,
   largeur ajustee au texte. Fond sombre semi-transparent pour bon contraste
   sur n'importe quelle photo. */
.lc-news-card-cat--overlay {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(65, 65, 66, 0.92);
    color: #fff;
    padding: 4px 12px;
    border-radius: 14px;
    font-size: 0.7rem;
    white-space: nowrap;
    z-index: 2;
    /* Subtile bordure blanche pour detacher du visuel */
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.15);
}

.lc-news-card-title {
    /* Forcer la police PARAGRAPHE du theme (eviter d'heriter de la police
       heading que le theme applique sur les <h3>). On essaie d'abord les
       variables CSS courantes des themes PrestaShop modernes, fallback sur
       une stack systeme sans-serif. !important pour battre le selecteur du
       theme qui cible h3. */
    font-family: var(--ps_font-family-base, var(--font-family-base, var(--bs-body-font-family, -apple-system))), BlinkMacSystemFont, "Open Sans", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
    font-size: 0.95rem;
    font-weight: 400;
    margin: 0 0 8px 0;
    line-height: 1.4;
    color: #414142;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

/* En page liste : reserve place pour la date a droite */
.lc-news-grid .lc-news-card-title {
    padding-right: 90px;
}

.lc-news-card-summary {
    margin: 0;
    font-size: 0.85rem;
    color: #666;
    line-height: 1.5;
    /* Meme stack que les titres pour la coherence (police paragraphe du theme) */
    font-family: var(--ps_font-family-base, var(--font-family-base, var(--bs-body-font-family, -apple-system))), BlinkMacSystemFont, "Open Sans", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
    font-weight: 400;
    font-style: normal;
    flex: 1;
}

/* Bouton "Voir plus d'articles" (chargement AJAX) */
.lc-news-loadmore-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    margin-top: 30px;
    padding: 20px 0;
}

.lc-news-loadmore-btn {
    padding: 12px 28px;
    background: #a7bc44;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 0.95rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    cursor: pointer;
    transition: background 0.15s, transform 0.1s;
}

.lc-news-loadmore-btn:hover {
    background: #8fa336;
}

.lc-news-loadmore-btn:active {
    transform: translateY(1px);
}

.lc-news-loadmore-btn:disabled {
    background: #c5c5c5;
    cursor: wait;
}

.lc-news-loadmore-status {
    color: #888;
    font-size: 0.85rem;
}

/* ---------- ARTICLE SEUL ---------- */

.lc-news-article-hero {
    width: 100%;
    max-height: 480px;
    overflow: hidden;
    background: #f0f0f0;
}

.lc-news-article-hero img {
    width: 100%;
    height: auto;
    max-height: 480px;
    object-fit: cover;
    display: block;
}

.lc-news-article-header {
    text-align: center;
    margin: 40px 0 30px 0;
    padding: 0 15px;
}

.lc-news-article-cats {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.lc-news-article-cat {
    background: #333;
    color: #fff;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    text-decoration: none;
    letter-spacing: 0.03em;
}

.lc-news-article-cat:hover {
    background: #000;
    color: #fff;
    text-decoration: none;
}

.lc-news-article-title {
    font-size: 2.4rem;
    font-weight: 700;
    margin: 0 0 14px 0;
    line-height: 1.2;
    color: #1a1a1a;
}

.lc-news-article-meta {
    color: #888;
    font-size: 0.95rem;
}

.lc-news-article-summary {
    max-width: 750px;
    margin: 0 auto 30px auto;
    font-size: 1.15rem;
    color: #444;
    line-height: 1.6;
    font-style: italic;
    padding: 0 15px;
}

.lc-news-article-content {
    max-width: 750px;
    margin: 0 auto;
    font-size: 1.05rem;
    line-height: 1.7;
    color: #333;
    padding: 0 15px;
}

.lc-news-article-content h2,
.lc-news-article-content h3 {
    margin-top: 1.8em;
    margin-bottom: 0.6em;
    font-weight: 700;
}

.lc-news-article-content h2 { font-size: 1.6rem; }
.lc-news-article-content h3 { font-size: 1.3rem; }

.lc-news-article-content p { margin: 0 0 1em 0; }

.lc-news-article-content img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    margin: 1em 0;
}

.lc-news-article-content ul,
.lc-news-article-content ol {
    margin: 0 0 1em 0;
    padding-left: 1.4em;
}

.lc-news-article-content li { margin-bottom: 0.4em; }

.lc-news-article-content blockquote {
    border-left: 4px solid #333;
    background: #f8f8f8;
    margin: 1.5em 0;
    padding: 1em 1.4em;
    font-style: italic;
    color: #555;
}

/* ---------- Blocs du page builder ---------- */
.lc-news-block-heading {
    margin-top: 1.8em;
    margin-bottom: 0.6em;
    font-size: 1.6rem;
    font-weight: 700;
    color: #a7bc44;
    line-height: 1.3;
}

.lc-news-block-text {
    margin: 0 0 1.2em 0;
}

.lc-news-block-image {
    margin: 1.8em 0;
}

/* Image bornee a la largeur du texte (le conteneur fait deja max-width:750px) */
.lc-news-block-image img {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    margin: 0 auto;
}

.lc-news-block-caption {
    margin-top: 8px;
    font-size: 0.88rem;
    color: #888;
    font-style: italic;
    text-align: center;
}

/* Bloc bouton (lien cliquable mis en valeur)
   Style inspire du bouton "Nos magasins" de la home block : uppercase +
   letter-spacing + padding genereux. Couleurs adaptees pour bon contraste
   sur fond blanc de l'article. */
.lc-news-block-button-wrap {
    text-align: center;
    margin: 1.8em 0;
}

.lc-news-block-button {
    display: inline-block;
    padding: 11px 28px;
    background: #a7bc44;
    color: #fff;
    border-radius: 3px;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: background 0.15s, transform 0.15s;
}

.lc-news-block-button:hover {
    background: #8fa336;
    color: #fff;
    text-decoration: none;
    transform: translateY(-1px);
}

.lc-news-article-back {
    max-width: 750px;
    margin: 50px auto 0 auto;
    padding: 0 15px;
}

.lc-news-back-link {
    color: #666;
    text-decoration: none;
    font-weight: 600;
}

.lc-news-back-link:hover {
    color: #000;
    text-decoration: underline;
}

/* ---------- LAYOUT ARTICLE + SIDEBAR MAGASIN ---------- */
.lc-news-article-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
}

/* Quand l'article a une sidebar magasin, grille 2 colonnes */
.lc-news-article--with-sidebar .lc-news-article-layout {
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 40px;
    align-items: start;
}

.lc-news-article-main {
    min-width: 0;
}

/* Sidebar fiche magasin */
.lc-news-store-sidebar {
    background: #f8f8f8;
    border-radius: 10px;
    padding: 22px 24px;
    position: sticky;
    /* Decaler de la hauteur du menu sticky du theme (sinon la sidebar
       glisse derriere le menu au scroll). Valeur safe pour un header
       PrestaShop avec menu fixe. */
    top: 120px;
    font-size: 0.9rem;
}

/* Bloc EVENEMENT en haut de la sidebar magasin (si l'article a une date d'evenement) */
.lc-news-event-block {
    background: #a7bc44;
    color: #fff;
    padding: 14px 16px;
    border-radius: 6px;
    margin-bottom: 18px;
}

.lc-news-event-label {
    display: block;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    opacity: 0.9;
    margin-bottom: 4px;
}

.lc-news-event-date {
    margin: 0;
    font-weight: 700;
    font-size: 1rem;
    line-height: 1.3;
}

.lc-news-event-date-end {
    margin: 2px 0 0 0;
    font-size: 0.85rem;
    opacity: 0.95;
}

.lc-news-event-time {
    margin: 4px 0 0 0;
    font-size: 0.9rem;
    opacity: 0.95;
}

.lc-news-store-name {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 18px 0;
    color: #a7bc44;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.lc-news-store-block {
    margin-bottom: 16px;
}

.lc-news-store-block:last-child {
    margin-bottom: 0;
}

.lc-news-store-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #414142;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}

/* Titre "Fermetures exceptionnelles" en rouge */
.lc-news-store-label--alert {
    color: #c0392b;
}

.lc-news-store-value {
    margin: 0;
    color: #333;
    line-height: 1.5;
}

.lc-news-store-value a {
    color: #a7bc44;
    text-decoration: none;
}

.lc-news-store-value a:hover {
    text-decoration: underline;
}

.lc-news-store-hours {
    list-style: none;
    padding: 0;
    margin: 0;
}

.lc-news-store-day {
    display: flex;
    justify-content: space-between;
    padding: 3px 0;
    font-size: 0.85rem;
    color: #333;
}

.lc-news-store-day-label {
    font-weight: 500;
}

.lc-news-store-day-slots {
    text-align: right;
    color: #555;
}

.lc-news-store-day--closed .lc-news-store-day-slots {
    color: #b0b0b0;
    font-style: italic;
}

/* Lien "Voir tous nos magasins" en bas de la sidebar magasin */
.lc-news-store-locator-link {
    display: block;
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid #e5e5e5;
    text-align: center;
    color: #a7bc44;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    transition: color 0.15s;
}
.lc-news-store-locator-link:hover {
    color: #8fa336;
    text-decoration: underline;
}

/* SIDEBAR ALTERNATIVE "Trouver un magasin"
   (s'affiche quand l'article n'a PAS de magasin lie)
   Style aligne sur .lc-news-store-sidebar pour la coherence. */
.lc-news-locator-sidebar {
    background: #f8f8f8;
    border-radius: 10px;
    padding: 22px 24px;
    position: sticky;
    top: 120px;
    font-size: 0.9rem;
    text-align: center;
}

.lc-news-locator-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 8px 0;
    color: #a7bc44;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    text-align: center;
}

.lc-news-locator-subtitle {
    font-size: 0.85rem;
    color: #666;
    margin: 0 0 18px 0;
    line-height: 1.4;
}

.lc-news-locator-img-link {
    display: block;
    margin: 0 auto 16px auto;
    max-width: 200px;
    transition: transform 0.2s;
}
.lc-news-locator-img-link:hover {
    transform: scale(1.03);
}

.lc-news-locator-img {
    width: 100%;
    height: auto;
    display: block;
    background: transparent;
}

.lc-news-locator-btn {
    display: inline-block;
    background: #a7bc44;
    color: #fff;
    padding: 10px 20px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: background 0.15s;
}
.lc-news-locator-btn:hover {
    background: #8fa336;
    color: #fff;
    text-decoration: none;
}

/* Responsive : sur tablette/mobile, sidebar passe sous l'article */
@media (max-width: 900px) {
    .lc-news-article--with-sidebar .lc-news-article-layout {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    .lc-news-store-sidebar,
    .lc-news-locator-sidebar {
        position: static;
    }
}

/* "A lire aussi" — injectee dans le page-footer du theme (block page_footer),
   donc dans le flux naturel : pas besoin de hack pour la "coller" au footer.
   Fond pleine largeur ecran (full-bleed) : le bloc deborde de son conteneur
   limite, tout en gardant le .container interne centre. */
.lc-news-also-section {
    margin-top: 0;
    margin-bottom: 0;
    padding: 40px 0;
    background: #f8f8f8;
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
}

/* Le <section id="main"> du theme contient page-content ET page-footer, et a
   un padding-bottom (souvent 60px) qui cree un espace blanc apres "a lire aussi"
   avant le footer du site. On l'annule UNIQUEMENT sur les pages du module
   (via les classes body lc-news-view / lc-news-list garanties par le filet
   de securite des controleurs). */
body.lc-news-view #main,
body.lc-news-list #main {
    padding-bottom: 0 !important;
    margin-bottom: 0 !important;
}

.lc-news-also-title {
    text-align: center;
    font-size: 1.6rem;
    font-weight: 700;
    margin: 0 0 30px 0;
    color: #a7bc44;
}

.lc-news-also-grid {
    display: grid;
    /* 4 colonnes en desktop, 2 en tablette, 1 en mobile (gere plus bas) */
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
}

/* ---------- RESPONSIVE ---------- */

@media (max-width: 900px) {
    .lc-news-list-layout {
        grid-template-columns: 1fr;
    }

    /* Sur mobile, le filtre est rendu par la liste deroulante en haut de page :
       on masque la sidebar (categories/magasins en bas). */
    .lc-news-sidebar {
        display: none;
    }

    .lc-news-mobile-filter {
        display: block;
    }

    /* A lire aussi : 2 colonnes en tablette */
    .lc-news-also-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    /* A lire aussi : 1 colonne en mobile + images carrees */
    .lc-news-also-grid {
        grid-template-columns: 1fr;
    }
    .lc-news-also-grid .lc-news-card-image {
        aspect-ratio: 1 / 1;
    }

    /* Page liste : repasser la card en vertical sur mobile (image en haut)
       + images carrees */
    .lc-news-grid .lc-news-card-link {
        grid-template-columns: 1fr;
    }
    .lc-news-grid .lc-news-card-image {
        aspect-ratio: 1 / 1;
        min-height: 0;
    }
    .lc-news-grid .lc-news-card-title,
    .lc-news-grid .lc-news-card-cats {
        padding-right: 0;
    }
    .lc-news-grid .lc-news-card-date-text {
        position: static;
        margin-bottom: 6px;
        display: block;
    }
}

@media (max-width: 600px) {
    .lc-news-article-title {
        font-size: 1.7rem;
    }

    .lc-news-list-title {
        font-size: 1.6rem;
    }

    .lc-news-article-hero {
        max-height: 250px;
    }

    .lc-news-article-hero img {
        max-height: 250px;
    }

    .lc-news-list-section,
    .lc-news-article {
        padding: 20px 0 40px 0;
    }
}
