/* ==================================================
   FDPL — ARCHIVES & SEARCH PREMIUM GRID
   Clean • Stable • Scalable • Editorial
================================================== */


/* ==================================================
   GLOBAL STRUCTURE
================================================== */

.archive .site-main,
.search-results .site-main {
  display: block;
}
/* =========================================
   FIX STRUCTURE HEADER SEARCH / ARCHIVE
========================================= */

.archive .generate-columns-container,
.search .generate-columns-container {
    display: block !important;
}


/* ==================================================
   HERO SECTION
================================================== */

.archive-seo-intro {
  padding-top: 80px;
}
generate-columns-container {
	.flex-direction:column;
}

/* ==================================================
   HERO H1 — VERSION ÉDITORIALE PREMIUM
================================================== */

.archive-seo-intro .page-title {
  max-width: 820px;
  
  font-size: clamp(2.1rem, 3.5vw, 2.6rem);
  line-height: 1.18;
  font-weight: 800;
  letter-spacing: -0.02em;

  color: #0f172a;

  margin-bottom: 32px;
}


/* ==================================================
   HERO INTRO CARD (si présente)
================================================== */

.archive-intro {
  max-width: 760px;
  margin-top: 16px;
  margin-bottom: 40px; /* 🔥 vraie séparation avant la grille */
}


/* ==================================================
   HERO LINKS
================================================== */

.archive-seo-intro a {
  position: relative;
  color: #2563eb;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.2s ease;
}

.archive-seo-intro a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -3px;
  width: 100%;
  height: 2px;
  background: rgba(37, 99, 235, 0.3);
  transition: background 0.25s ease;
}

.archive-seo-intro a:hover {
  color: #1d4ed8;
}

.archive-seo-intro a:hover::after {
  background: #1d4ed8;
}


/* ==================================================
   ARTICLES GRID WRAPPER
================================================== */

.archive-articles-grid {
  display: grid;
  gap: 36px; /* 🔥 un peu plus premium que 32px */
  margin-top: 24px; /* 🔥 espace entre hero et articles */
}


/* Desktop */
@media (min-width: 1200px) {
  .archive-articles-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Tablet */
@media (min-width: 768px) and (max-width: 1199px) {
  .archive-articles-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Mobile */
@media (max-width: 767px) {
  .archive-articles-grid {
    grid-template-columns: 1fr;
    gap: 24px;
	margin: 0 10px;
  }
  .archive-seo-intro {
    padding: 5px 0 0 5px !important;
  }
  .archive-intro {
	margin: 0 10px;
  }
  .astuceArchives{
    margin: 3rem 0 !important;
    padding: 1.75rem 2rem !important;
    border-radius: 0; 
  }
  .paging-navigation{
	padding-top:10px;
  }
  .paging-navigation{
	padding-top:20px !important;
  }
}


/* Header & SEO bottom full width inside grid */
.archive-seo-intro,
.archive-seo-bottom {
  grid-column: 1 / -1;
}


/* ==================================================
   RESET GENERATEPRESS GRID BEHAVIOR
================================================== */

.archive .generate-columns,
.search-results .generate-columns {
  width: 100% !important;
  max-width: 100% !important;
  flex: none !important;
}

.archive-articles-grid article {
  width: 100%;
  margin: 0;
}


/* ==================================================
   ARTICLE CARD DESIGN
================================================== */

.archive .inside-article,
.search-results .inside-article {
  position: relative;
  display: flex;
  flex-direction: column;

  height: 420px;
  padding: 24px;

  background: #ffffff;
  border: 1px solid #e6e8ee;
  border-radius: 18px;

  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease,
    border-color 0.25s ease;
}


/* ==================================================
   ARTICLE IMAGE
================================================== */

.archive .post-image {
  margin-bottom: 16px;
}

.archive .post-image img {
  width: 100%;
  height: 190px;
  object-fit: cover;
  border-radius: 14px;
  transition: transform 0.35s ease;
}

.archive article:hover .post-image img {
  transform: scale(1.04);
}


/* ==================================================
   ARTICLE TITLE
================================================== */

.archive .entry-title {
  margin: 0 0 12px;
  font-size: 1.08rem;
  line-height: 1.35;
  font-weight: 700;
}

.archive .entry-title a {
  color: #0f172a;
  text-decoration: none;
  transition: color 0.2s ease;
}

.archive .entry-title a:hover {
  color: #1d4ed8;
}


/* ==================================================
   META
================================================== */

.archive .entry-meta {
  font-size: 0.85rem;
  color: #64748b;
  margin-bottom: 12px;
}


/* ==================================================
   EXCERPT
================================================== */

.archive .entry-summary {
  font-size: 0.95rem;
  line-height: 1.6;
  color: #475569;
}


/* ==================================================
   CTA ALIGNMENT
================================================== */

.archive .read-more-container {
  margin-top: auto;
  padding-top: 20px;
}


/* ==================================================
   CARD HOVER EFFECT
================================================== */

.archive article:hover .inside-article {
  transform: translateY(-6px);
  border-color: #c7d2fe;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}


/* ==================================================
   FDPL VISUAL SIGNATURE
================================================== */

.archive .inside-article::before {
  content: "";
  position: absolute;
  top: 24px;
  left: 0;

  width: 4px;
  height: 42px;

  border-radius: 4px;
  background: linear-gradient(180deg, #2563eb, #38bdf8);

  opacity: 0;
  transition: opacity 0.25s ease;
}

.archive article:hover .inside-article::before {
  opacity: 1;
}


/* ==================================================
   PAGINATION — PREMIUM
================================================== */

.paging-navigation {
  display: flex;
  justify-content: center;
  align-items: center;

  margin: 72px auto 48px;
  padding-top: 36px;

  border-top: 1px solid #e6e8ee;
}

.paging-navigation .nav-links {
  display: flex;
  align-items: center;
  gap: 10px;
}

.paging-navigation .page-numbers {
  min-width: 42px;
  height: 42px;
  padding: 0 14px;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  font-size: 0.9rem;
  font-weight: 600;

  color: #2563eb;
  background: #ffffff;

  border: 1px solid #dbeafe;
  border-radius: 12px;

  transition:
    background-color 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.15s ease;
}

.paging-navigation .page-numbers:hover {
  background: #eff6ff;
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(37, 99, 235, 0.15);
}

.paging-navigation .page-numbers.current {
  background: linear-gradient(180deg, #2563eb, #1d4ed8);
  color: #ffffff;
  border-color: transparent;
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.35);
}


/* ==================================================
   SEO BOTTOM SECTION
================================================== */

.archive-seo-bottom {
  max-width: 760px;
  margin: 80px auto 0;
  padding-inline: 32px;
}


/* ==================================================
   MOBILE ADAPTATION
================================================== */

@media (max-width: 767px) {

  .archive .inside-article {
    height: auto;
    padding: 18px;
  }

  .archive .inside-article::before {
    display: none;
  }

  .paging-navigation .dots {
    display: none;
  }

}
