/* ===== CD54 BILLARD - PAGE D'ACCUEIL ===== */
/* Version: 1.1.24 */

/* ============================================================
   0. RESET ESPACEMENT HOMEPAGE
   ============================================================ */

/* Empêcher le débordement horizontal sur mobile */
body.home {
  overflow-x: hidden !important;
}

body.home .site-content,
body.home #content.site-content,
body.home .ast-separate-container .site-content > .ast-container,
body.home .ast-separate-container article,
body.home .ast-separate-container .ast-article-single {
  padding-top: 0 !important;
  margin-top: 0 !important;
}

/* ============================================================
   1. HERO - Bandeau principal avec événement phare
   ============================================================ */

.cd54-hero,
.wp-block-cover.cd54-hero {
  position: relative;
  margin-top: -30px !important;
  min-height: 500px !important;
  padding: 0 !important;
  overflow: hidden !important;
  width: 100vw !important;
  max-width: 100vw !important;
  margin-left: calc(-50vw + 50%) !important;
  margin-right: calc(-50vw + 50%) !important;
  border-radius: 0 !important; /* Pas de coins arrondis sur le hero */
}

/* Image de fond optimisée */
.cd54-hero .wp-block-cover__image-background,
.cd54-hero img.wp-block-cover__image-background {
  object-fit: cover !important;
  object-position: center 80% !important;
  width: 100% !important;
  height: 120% !important;
  min-height: 120% !important;
  transform: translateY(-15%) !important;
}

/* Overlay gradient pour lisibilité - renforcé pour accessibilité WCAG */
.cd54-hero::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.4) 0%,
    rgba(0, 0, 0, 0.2) 50%,
    rgba(0, 0, 0, 0.6) 100%
  );
  pointer-events: none;
  z-index: 1;
}

/* Container interne du hero */
.cd54-hero .wp-block-cover__inner-container {
  width: 100% !important;
  max-width: 1200px !important;
  margin: 0 auto !important;
  padding: 60px 24px !important;
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 400px;
}

/* Contenu Hero */
.cd54-hero-content {
  background: rgba(255, 255, 255, 0.95) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border-radius: 16px !important;
  padding: 32px 40px !important;
  max-width: 600px !important;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15) !important;
}

.cd54-hero-content .cd54-hero-tag {
  display: inline-block;
  background: var(--cd54-primary, #DD183B) !important;
  color: #fff !important;
  padding: 6px 16px !important;
  border-radius: 20px !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: 1px !important;
  margin-bottom: 12px !important;
}

.cd54-hero-content h2,
.cd54-hero-content .wp-block-heading {
  font-size: 2rem !important;
  font-weight: 800 !important;
  color: var(--cd54-text-dark) !important;
  margin: 0 0 8px 0 !important;
  line-height: 1.2 !important;
}

.cd54-hero-content .cd54-hero-meta {
  font-size: 16px !important;
  color: #6B7280 !important;
  margin-bottom: 20px !important;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.cd54-hero-content .cd54-hero-meta span {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Boutons CTA Hero */
.cd54-hero-buttons {
  display: flex !important;
  gap: 12px !important;
  flex-wrap: wrap !important;
}

.cd54-hero-buttons .wp-block-button__link {
  padding: 14px 28px !important;
  font-size: 15px !important;
  font-weight: 600 !important;
  border-radius: 8px !important;
  transition: all 0.3s ease !important;
}

.cd54-hero-buttons .wp-block-button.is-style-fill .wp-block-button__link {
  background: var(--cd54-primary, #DD183B) !important;
  color: #fff !important;
}

.cd54-hero-buttons .wp-block-button.is-style-fill .wp-block-button__link:hover {
  background: var(--cd54-primary-dark, #CC1939) !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 4px 12px rgba(221, 24, 59, 0.3) !important;
}

.cd54-hero-buttons .wp-block-button.is-style-outline .wp-block-button__link {
  background: transparent !important;
  color: var(--cd54-text-dark) !important;
  border: 2px solid var(--cd54-text-dark) !important;
}

.cd54-hero-buttons .wp-block-button.is-style-outline .wp-block-button__link:hover {
  background: var(--cd54-text-dark) !important;
  color: #fff !important;
}

/* ============================================================
   2. SECTION "À VENIR CETTE SEMAINE" - 3 cartes événements
   ============================================================ */

.cd54-events-section {
  padding: 64px 24px !important;
  max-width: 1200px !important;
  margin: 0 auto !important;
}

.cd54-events-section > h2,
.cd54-events-section > .wp-block-heading {
  text-align: center !important;
  margin-bottom: 40px !important;
  font-size: 2rem !important;
  font-weight: 700 !important;
}

.cd54-events-grid {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important;
  gap: 24px !important;
}

/* Carte événement */
.cd54-event-card {
  background: #fff !important;
  border-radius: 16px !important;
  overflow: hidden !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
  transition: all 0.3s ease !important;
  display: flex !important;
  flex-direction: column !important;
}

.cd54-event-card:hover {
  transform: translateY(-6px) !important;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12) !important;
}

/* Date en badge */
.cd54-event-card .cd54-event-date {
  background: var(--cd54-primary, #DD183B) !important;
  color: #fff !important;
  padding: 12px 16px !important;
  text-align: center !important;
  min-height: auto !important;
  max-height: 100px !important;
}

.cd54-event-card .cd54-event-date .day {
  display: block !important;
  font-size: 2rem !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  margin: 0 0 4px 0 !important;
}

.cd54-event-card .cd54-event-date .month {
  display: block !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  letter-spacing: 1px !important;
  margin: 0 !important;
}




/* Reset margins on paragraphs inside event date */
.cd54-event-date p {
  margin: 0 !important;
  padding: 0 !important;
}
.cd54-event-date p.day {
  margin-bottom: 4px !important;
}

/* Override Gutenberg min-height on event date blocks */
.wp-block-group.cd54-event-date,
.cd54-event-card .wp-block-group.cd54-event-date {
  min-height: auto !important;
  padding-top: 14px !important;
  padding-bottom: 14px !important;
}

/* Contenu carte événement */
.cd54-event-card .cd54-event-content {
  padding: 20px !important;
  flex: 1 !important;
  display: flex !important;
  flex-direction: column !important;
}

.cd54-event-card .cd54-event-discipline {
  display: inline-flex !important;
  align-items: center !important;
  background: #f3f4f6 !important;
  color: #374151 !important;
  padding: 8px 16px !important;
  min-height: 44px !important;
  border-radius: 12px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  margin-bottom: 12px !important;
  width: fit-content !important;
  box-sizing: border-box !important;
}

.cd54-event-card h3,
.cd54-event-card .wp-block-heading {
  font-size: 1.1rem !important;
  font-weight: 700 !important;
  margin: 0 0 12px 0 !important;
  color: var(--cd54-text-dark) !important;
}

.cd54-event-card .cd54-event-location {
  font-size: 14px !important;
  color: #6B7280 !important;
  display: flex !important;
  align-items: center !important;
  gap: 6px !important;
  margin-top: auto !important;
}

/* SPÉCIFIQUE: Emojis/icônes dans les cartes événements - taille 1em */
.cd54-event-card .cd54-event-location img,
.cd54-event-card .cd54-event-location svg,
.cd54-event-card .cd54-event-content img:not(.wp-block-post-featured-image img),
.cd54-event-card .cd54-event-discipline img,
.cd54-event-card .cd54-event-discipline svg {
  width: 1em !important;
  height: 1em !important;
  max-width: 1em !important;
  max-height: 1em !important;
  min-width: 1em !important;
  min-height: 1em !important;
  display: inline !important;
  vertical-align: -0.1em !important;
}

/* Bouton "Voir tout le calendrier" - fond rouge, texte blanc */
.cd54-events-section .wp-block-button.is-style-outline .wp-block-button__link,
.cd54-events-section .wp-block-button .wp-block-button__link {
  background: var(--cd54-primary, #DD183B) !important;
  color: #fff !important;
  border: none !important;
  border-radius: 8px !important;
  padding: 14px 32px !important;
  font-weight: 600 !important;
  transition: all 0.3s ease !important;
}

.cd54-events-section .wp-block-button.is-style-outline .wp-block-button__link:hover,
.cd54-events-section .wp-block-button .wp-block-button__link:hover {
  background: #b81432 !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 4px 12px rgba(221, 24, 59, 0.3) !important;
}

/* ============================================================
   3. SECTION "DERNIÈRES ACTUALITÉS"
   ============================================================ */

.cd54-news-section {
  padding: 64px 24px !important;
  max-width: 1200px !important;
  margin: 0 auto !important;
}

.cd54-news-section > h2,
.cd54-news-section > .wp-block-heading {
  text-align: center !important;
  margin-bottom: 40px !important;
}

.cd54-news-grid {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important;
  gap: 32px !important;
}

/* Carte article */
.cd54-news-card {
  background: #fff !important;
  border-radius: 16px !important;
  overflow: hidden !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
  transition: all 0.3s ease !important;
}

.cd54-news-card:hover {
  transform: translateY(-6px) !important;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12) !important;
}

.cd54-news-card .wp-block-post-featured-image {
  aspect-ratio: 16/9 !important;
  overflow: hidden !important;
  margin: 0 !important;
}

.cd54-news-card .wp-block-post-featured-image img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  transition: transform 0.3s ease !important;
}

.cd54-news-card:hover .wp-block-post-featured-image img {
  transform: scale(1.05) !important;
}

.cd54-news-card .cd54-news-content {
  padding: 24px !important;
}

.cd54-news-card .wp-block-post-date {
  font-size: 13px !important;
  color: #6B7280 !important;
  margin-bottom: 8px !important;
}

.cd54-news-card .wp-block-post-title {
  font-size: 1.1rem !important;
  font-weight: 700 !important;
  margin: 0 !important;
  line-height: 1.4 !important;
}

.cd54-news-card .wp-block-post-title a {
  color: var(--cd54-text-dark) !important;
  text-decoration: none !important;
}

.cd54-news-card .wp-block-post-title a:hover {
  color: var(--cd54-primary, #DD183B) !important;
}

/* ============================================================
   4. SECTION "RÉSULTATS RÉCENTS" - Tableau compact
   ============================================================ */

.cd54-results-section {
  padding: 64px 24px !important;
  max-width: 1200px !important;
  margin: 0 auto !important;
}

.cd54-results-section > h2,
.cd54-results-section > .wp-block-heading {
  text-align: center !important;
  margin-bottom: 40px !important;
}

.cd54-results-table {
  background: #fff !important;
  border-radius: 16px !important;
  overflow: hidden !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
}

.cd54-results-table table {
  width: 100% !important;
  border-collapse: collapse !important;
}

.cd54-results-table thead {
  background: #f9fafb !important;
}

.cd54-results-table th {
  padding: 16px 20px !important;
  text-align: left !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.5px !important;
  color: #6B7280 !important;
  border-bottom: 2px solid #e5e7eb !important;
}

.cd54-results-table td {
  padding: 16px 20px !important;
  font-size: 15px !important;
  color: var(--cd54-text-dark) !important;
  border-bottom: 1px solid #f3f4f6 !important;
}

.cd54-results-table tr:last-child td {
  border-bottom: none !important;
}

.cd54-results-table tr:hover {
  background: #f9fafb !important;
}

/* Badges discipline */
.cd54-results-table .cd54-discipline-badge {
  display: inline-block !important;
  padding: 4px 12px !important;
  border-radius: 12px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
}

.cd54-discipline-badge.libre { background: #dbeafe !important; color: #1d4ed8 !important; }
.cd54-discipline-badge.bandes { background: #fef3c7 !important; color: #b45309 !important; }
.cd54-discipline-badge.cadre { background: #d1fae5 !important; color: #047857 !important; }
.cd54-discipline-badge.blackball { background: var(--cd54-text-dark) !important; color: #fff !important; }

/* Podium */
.cd54-results-table .cd54-podium {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
}

.cd54-results-table .cd54-medal {
  width: 24px !important;
  height: 24px !important;
  border-radius: 50% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 12px !important;
  font-weight: 700 !important;
}

.cd54-medal.gold { background: #fbbf24 !important; color: #78350f !important; }
.cd54-medal.silver { background: #d1d5db !important; color: #374151 !important; }
.cd54-medal.bronze { background: #f59e0b !important; color: #78350f !important; }

/* Lien voir détail */
.cd54-results-table .cd54-results-link {
  color: var(--cd54-primary, #DD183B) !important;
  font-weight: 600 !important;
  text-decoration: none !important;
}

.cd54-results-table .cd54-results-link:hover {
  text-decoration: underline !important;
}

/* Bouton voir tous */
.cd54-results-section .cd54-view-all {
  text-align: center !important;
  margin-top: 32px !important;
}

/* ============================================================
   5. SECTION "SE FORMER" - 2 cartes
   ============================================================ */

.cd54-training-section {
  padding: 64px 24px !important;
  max-width: 1200px !important;
  margin: 0 auto !important;
}

.cd54-training-section > h2,
.cd54-training-section > .wp-block-heading {
  text-align: center !important;
  margin-bottom: 40px !important;
}

.cd54-training-grid {
  display: grid !important;
  grid-template-columns: repeat(2, 1fr) !important;
  gap: 32px !important;
}

/* Carte formation */
.cd54-training-card {
  background: #fff !important;
  border-radius: 16px !important;
  overflow: hidden !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
  transition: all 0.3s ease !important;
  display: flex !important;
  flex-direction: column !important;
}

.cd54-training-card:hover {
  transform: translateY(-6px) !important;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12) !important;
}

.cd54-training-card .cd54-training-image {
  aspect-ratio: 16/10 !important;
  overflow: hidden !important;
  background: #f5f5f5 !important;
}

.cd54-training-card .cd54-training-image img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  transition: transform 0.3s ease !important;
}

.cd54-training-card:hover .cd54-training-image img {
  transform: scale(1.05) !important;
}

.cd54-training-card .cd54-training-content {
  padding: 32px !important;
  flex: 1 !important;
  display: flex !important;
  flex-direction: column !important;
}

.cd54-training-card h3,
.cd54-training-card .wp-block-heading {
  font-size: 1.5rem !important;
  font-weight: 700 !important;
  margin: 0 0 12px 0 !important;
  color: var(--cd54-text-dark) !important;
}

.cd54-training-card p {
  font-size: 15px !important;
  color: #6B7280 !important;
  line-height: 1.6 !important;
  margin: 0 0 24px 0 !important;
  flex: 1 !important;
}

.cd54-training-card .wp-block-button__link {
  background: var(--cd54-primary, #DD183B) !important;
  color: #fff !important;
  padding: 12px 24px !important;
  border-radius: 8px !important;
  font-weight: 600 !important;
  text-align: center !important;
  transition: all 0.3s ease !important;
  width: 100% !important;
}

.cd54-training-card .wp-block-button__link:hover {
  background: var(--cd54-primary-dark, #CC1939) !important;
}

/* ============================================================
   6. SECTION "NOS CLUBS" - Aperçu carte
   ============================================================ */

.cd54-clubs-section {
  padding: 64px 24px !important;
  max-width: 1200px !important;
  margin: 0 auto !important;
  position: relative !important;
  background: transparent !important;
}

/* Supprimer tout overlay sur la section clubs */
.cd54-clubs-section::before,
.cd54-clubs-section::after {
  display: none !important;
  content: none !important;
}

.cd54-clubs-section > h2,
.cd54-clubs-section > .wp-block-heading {
  text-align: center !important;
  margin-bottom: 40px !important;
}

.cd54-clubs-preview {
  display: grid !important;
  grid-template-columns: 1fr 1fr !important;
  gap: 32px !important;
  align-items: stretch !important;
}

/* Forcer les colonnes à la même hauteur */
.cd54-clubs-preview.wp-block-columns {
  display: grid !important;
  grid-template-columns: 1fr 1fr !important;
}

.cd54-clubs-preview > .wp-block-column {
  height: 100% !important;
  min-height: 320px !important;
}

/* Carte interactive Leaflet */
.cd54-clubs-map {
  background: #fff !important;
  border-radius: 16px !important;
  overflow: hidden !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
  min-height: 420px !important;
  height: 100% !important;
  position: relative !important;
  display: flex !important;
  flex-direction: column !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* Supprimer tout voile/overlay sur la carte et ses parents */
/* IMPORTANT: Ne pas masquer les pseudo-éléments Leaflet (tooltips, popups) */
.cd54-clubs-map::before,
.cd54-clubs-map::after,
.cd54-clubs-section::before,
.cd54-clubs-section::after,
.cd54-clubs-preview::before,
.cd54-clubs-preview::after {
  display: none !important;
  content: none !important;
  background: none !important;
}

/* Masquer uniquement les pseudo-éléments du shortcode wrapper, pas les éléments Leaflet */
.cd54-clubs-map > .wp-block-shortcode::before,
.cd54-clubs-map > .wp-block-shortcode::after {
  display: none !important;
}

/* Forcer l'affichage du bloc shortcode */
.cd54-clubs-map > .wp-block-shortcode,
.cd54-clubs-map .wp-block-shortcode {
  display: block !important;
  width: 100% !important;
  flex: 1 !important;
  min-height: 420px !important;
  padding: 0 !important;
  margin: 0 !important;
  background: transparent !important;
}

/* Forcer l'affichage de la carte Leaflet - remplir toute la colonne */
.cd54-clubs-map .leaflet-container {
  width: 100% !important;
  height: 100% !important;
  min-height: 420px !important;
  border-radius: 16px !important;
  z-index: 1 !important;
  display: block !important;
  background: #f5f5f5 !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* Conteneur carte - garder les marqueurs à l'intérieur */
.cd54-clubs-map {
  overflow: hidden !important;
  position: relative !important;
}

/* Style du contrôle de zoom Leaflet - supprimer le cadre */
.cd54-clubs-map .leaflet-control-zoom {
  border: none !important;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15) !important;
  border-radius: 8px !important;
  overflow: hidden !important;
}

.cd54-clubs-map .leaflet-control-zoom a {
  background: #fff !important;
  color: #333 !important;
  border: none !important;
  width: 32px !important;
  height: 32px !important;
  line-height: 32px !important;
  font-size: 18px !important;
}

.cd54-clubs-map .leaflet-control-zoom a:hover {
  background: #f5f5f5 !important;
}

.cd54-clubs-map .leaflet-control-zoom-in {
  border-bottom: 1px solid #eee !important;
  border-radius: 8px 8px 0 0 !important;
}

.cd54-clubs-map .leaflet-control-zoom-out {
  border-radius: 0 0 8px 8px !important;
}

/* Masquer l'attribution Leaflet */
.cd54-clubs-map .leaflet-control-attribution {
  display: none !important;
}

/* Supprimer tout cadre/bordure/scrollbar sur la carte */
.cd54-clubs-map,
.cd54-clubs-map .wp-block-shortcode {
  border: none !important;
  outline: none !important;
}

/* S'assurer que les popups et tooltips Leaflet sont visibles */
.cd54-clubs-map .leaflet-popup,
.cd54-clubs-map .leaflet-tooltip,
.cd54-clubs-map .leaflet-popup-pane,
.cd54-clubs-map .leaflet-tooltip-pane {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  z-index: 1000 !important;
}

.cd54-clubs-map .leaflet-popup-content-wrapper {
  background: #fff !important;
  border-radius: 8px !important;
  box-shadow: 0 3px 14px rgba(0,0,0,0.2) !important;
  padding: 0 !important;
}

.cd54-clubs-map .leaflet-popup-content {
  margin: 12px 16px !important;
  font-family: Arial, sans-serif !important;
  font-size: 14px !important;
  line-height: 1.5 !important;
}

.cd54-clubs-map .leaflet-popup-content strong {
  color: var(--cd54-text-dark) !important;
  font-weight: 700 !important;
}

.cd54-clubs-map .leaflet-popup-content a {
  color: var(--cd54-primary, #DD183B) !important;
  text-decoration: none !important;
}

.cd54-clubs-map .leaflet-popup-tip {
  background: #fff !important;
}

.cd54-clubs-map .leaflet-popup-close-button {
  color: #999 !important;
  top: 4px !important;
  right: 4px !important;
  width: 20px !important;
  height: 20px !important;
  font-size: 18px !important;
  line-height: 18px !important;
  padding: 0 !important;
  text-align: center !important;
}

.cd54-clubs-map .leaflet-popup-close-button:hover {
  color: #333 !important;
}

/* Tooltip au survol des markers */
.cd54-clubs-map .leaflet-tooltip {
  background: var(--cd54-text-dark) !important;
  color: #fff !important;
  border: none !important;
  border-radius: 4px !important;
  padding: 6px 10px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  white-space: nowrap !important;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2) !important;
}

.cd54-clubs-map .leaflet-tooltip::before {
  border-top-color: var(--cd54-text-dark) !important;
}

/* Masquer le pane des ombres Leaflet (cause du voile) */
.cd54-clubs-map .leaflet-shadow-pane {
  display: none !important;
}

/* Supprimer tout fond/gradient sur le container de contrôles */
.cd54-clubs-map .leaflet-control-container {
  background: none !important;
}

/* Supprimer les ombres des marqueurs */
.cd54-clubs-map .leaflet-marker-shadow {
  display: none !important;
}

/* Supprimer tout overlay/gradient sur les tuiles - RESTAURÉ du backup v1.0.120 */
.cd54-clubs-map .leaflet-tile-pane,
.cd54-clubs-map .leaflet-overlay-pane {
  filter: none !important;
  opacity: 1 !important;
}

/* S'assurer que le pane de la carte est opaque */
.cd54-clubs-map .leaflet-map-pane {
  background: transparent !important;
}

/* Fix pour le wrapper Leaflet Map plugin */
.cd54-clubs-map .leaflet-map-shortcode {
  width: 100% !important;
  height: 100% !important;
  min-height: 420px !important;
}

/* S'assurer que les markers sont cliquables */
.cd54-clubs-map .leaflet-marker-pane,
.cd54-clubs-map .leaflet-marker-icon {
  pointer-events: auto !important;
  cursor: pointer !important;
}

/* Préserver les icônes Leaflet */
.cd54-clubs-map .leaflet-marker-icon {
  width: 25px !important;
  height: 41px !important;
}

/* Supprimer tout overlay/gradient sur les tuiles */
.cd54-clubs-map .leaflet-tile-pane,
.cd54-clubs-map .leaflet-overlay-pane {
  filter: none !important;
  opacity: 1 !important;
}

/* S'assurer que le pane de la carte est opaque */
.cd54-clubs-map .leaflet-map-pane {
  background: transparent !important;
}

/* Fond beige pour masquer les gaps entre tuiles */
.cd54-clubs-map .leaflet-tile-pane,
.cd54-clubs-map .leaflet-layer,
.cd54-clubs-map .leaflet-tile-container {
  background-color: #f2efe9 !important;
}

.cd54-clubs-map .leaflet-tile {
  filter: none !important;
  opacity: 1 !important;
}

.cd54-clubs-map iframe {
  width: 100% !important;
  height: 100% !important;
}

/* Liste clubs aperçu */
.cd54-clubs-list {
  background: #fff !important;
  border-radius: 16px !important;
  padding: 16px 20px !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
  height: 100% !important;
  min-height: 320px !important;
  display: flex !important;
  flex-direction: column !important;
}

.cd54-clubs-list h3 {
  font-size: 1rem !important;
  font-weight: 700 !important;
  margin: 0 0 12px 0 !important;
  color: var(--cd54-text-dark) !important;
  flex-shrink: 0 !important;
}

/* Conteneur scrollable pour les clubs */
.cd54-clubs-list-items {
  flex: 1 !important;
  overflow-y: auto !important;
  margin-bottom: 12px !important;
}

.cd54-club-item {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  padding: 4px 0 !important;
  border-bottom: 1px solid #f3f4f6 !important;
  transition: all 0.2s ease !important;
  text-decoration: none !important;
}

.cd54-club-item:last-child {
  border-bottom: none !important;
}

.cd54-club-item:hover {
  background: #f9fafb !important;
  margin: 0 -8px !important;
  padding: 6px 8px 6px 12px !important;
  border-radius: 6px !important;
}

/* Icône point/marqueur (fallback sans logo) */
.cd54-club-item .cd54-club-icon {
  width: 8px !important;
  height: 8px !important;
  min-width: 8px !important;
  background: var(--cd54-primary, #DD183B) !important;
  border-radius: 50% !important;
  display: block !important;
  font-size: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* Cacher le contenu emoji */
.cd54-club-item .cd54-club-icon::before,
.cd54-club-item .cd54-club-icon::after {
  display: none !important;
}

/* Logo club miniature */
.cd54-club-item .cd54-club-logo,
.cd54-club-item figure.cd54-club-logo {
  width: 24px !important;
  height: 24px !important;
  min-width: 24px !important;
  max-width: 24px !important;
  border-radius: 4px !important;
  background: transparent !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  flex-shrink: 0 !important;
}

.cd54-club-item .cd54-club-logo img {
  width: 24px !important;
  height: 24px !important;
  max-width: 24px !important;
  object-fit: contain !important;
  border-radius: 4px !important;
  display: block !important;
}

.cd54-club-item .cd54-club-info {
  flex: 1 !important;
  min-width: 0 !important;
}

/* Reset complet pour éviter les conflits avec les polices d'icônes */
/* IMPORTANT: Exclure TOUTES les polices d'icônes connues */
.cd54-club-item .cd54-club-info,
.cd54-club-item .cd54-club-info h4,
.cd54-club-item .cd54-club-info h4 a,
.cd54-club-item .cd54-club-info .wp-block-heading,
.cd54-club-item .cd54-club-info .wp-block-heading a,
.cd54-club-item .cd54-club-info *,
.cd54-club-item .cd54-club-info *::before,
.cd54-club-item .cd54-club-info *::after {
  font-family: Arial, Helvetica, sans-serif !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  font-style: normal !important;
  font-variant: normal !important;
  font-feature-settings: normal !important;
  -webkit-font-smoothing: antialiased !important;
  -moz-osx-font-smoothing: grayscale !important;
  margin: 0 !important;
  color: var(--cd54-text-dark) !important;
  text-decoration: none !important;
  line-height: 1.3 !important;
  letter-spacing: normal !important;
  text-transform: none !important;
  /* Désactiver les icônes */
  -webkit-font-feature-settings: "liga" 0, "clig" 0 !important;
  font-feature-settings: "liga" 0, "clig" 0 !important;
  text-rendering: optimizeLegibility !important;
}

/* Forcer overflow visible pour voir le texte complet */
/* IMPORTANT: padding-left pour masquer l'icône parasite ::before */
.cd54-club-item .cd54-club-info h4,
.cd54-club-item .cd54-club-info h4 a {
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  padding-left: 5px !important;
}

.cd54-club-item:hover .cd54-club-info h4,
.cd54-club-item:hover .cd54-club-info h4 a {
  color: var(--cd54-primary, #DD183B) !important;
}

.cd54-club-item .cd54-club-info p,
.cd54-club-item .cd54-club-info span {
  font-family: Arial, Helvetica, sans-serif !important;
  font-size: 11px !important;
  color: #6B7280 !important;
  margin: 0 !important;
  line-height: 1.2 !important;
  padding-left: 5px !important;
}

.cd54-clubs-list .cd54-view-all-clubs {
  display: block !important;
  text-align: center !important;
  margin-top: auto !important;
  padding: 5px 20px !important;
  background: transparent !important;
  color: var(--cd54-primary, #DD183B) !important;
  border: 2px solid var(--cd54-primary, #DD183B) !important;
  border-radius: 8px !important;
  font-weight: 600 !important;
  font-size: 14px !important;
  text-decoration: none !important;
  transition: all 0.3s ease !important;
  flex-shrink: 0 !important;
}

.cd54-clubs-list .cd54-view-all-clubs:hover {
  background: var(--cd54-primary, #DD183B) !important;
  color: #fff !important;
}

.cd54-clubs-list .cd54-view-all-clubs a {
  color: inherit !important;
  text-decoration: none !important;
}

/* Desktop : hauteur 780px pour section clubs */
@media (min-width: 993px) {
  .cd54-clubs-preview,
  .cd54-clubs-preview.wp-block-columns {
    height: 780px !important;
    min-height: 780px !important;
  }

  .cd54-clubs-preview > .wp-block-column {
    height: 780px !important;
    min-height: 780px !important;
  }

  .cd54-clubs-map,
  .cd54-clubs-map .leaflet-container,
  .cd54-clubs-map .wp-block-shortcode,
  .cd54-clubs-map .leaflet-map-shortcode {
    height: 780px !important;
    min-height: 780px !important;
  }

  .cd54-clubs-list {
    height: 780px !important;
    min-height: 780px !important;
  }

  /* Titre liste clubs - 1.5rem */
  .cd54-clubs-list h3 {
    font-size: 1.5rem !important;
    margin: 0 !important;
  }

  /* Noms des clubs - 1rem (16px, adaptatif) */
  body.home .cd54-club-item .cd54-club-info h4,
  body.home .cd54-club-item .cd54-club-info h4 a,
  body.home .cd54-club-item .cd54-club-info *,
  body.home .cd54-clubs-list .cd54-club-item .cd54-club-info h4 {
    font-size: 1rem !important;
  }
}

/* ============================================================
   7. TITRES DE SECTIONS AVEC DÉCORATION
   ============================================================ */

.cd54-section-title {
  position: relative !important;
  display: inline-block !important;
}

/* Centrer le titre dans la colonne des articles (75%) */
.cd54-sidebar + .wp-block-column .cd54-section-title,
.cd54-sidebar ~ .wp-block-column .cd54-section-title,
.wp-block-columns .wp-block-column:not(.cd54-sidebar) .cd54-section-title,
h3.cd54-section-title.has-text-align-center {
  display: block !important;
  width: 100% !important;
  text-align: center !important;
  margin-left: auto !important;
  margin-right: auto !important;
}

.cd54-section-title::after {
  content: '' !important;
  position: absolute !important;
  bottom: -8px !important;
  left: 50% !important;
  transform: translateX(-50%) !important;
  width: 60px !important;
  height: 4px !important;
  background: var(--cd54-primary, #DD183B) !important;
  border-radius: 2px !important;
}

/* ============================================================
   8. MENU VERTICAL GAUCHE (existant)
   ============================================================ */

/* --- Logo à cheval sur le hero --- */
body.home .ast-primary-header-bar .site-branding {
  position: relative;
  z-index: 100;
  margin-bottom: -180px;
}

body.home header .custom-logo-link img,
body.home .site-header .custom-logo-link img {
  max-width: 200px !important;
  width: 200px !important;
  height: 200px !important;
  max-height: 200px !important;
  position: absolute !important;
  top: -180px !important;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.2));
  transition: all 0.3s ease !important;
}

body.home .ast-primary-header-bar {
  display: contents;
}

/* Menu vertical */
.cd54-sidebar {
  display: flex;
  align-items: center;
}

.cd54-nav-vertical {
  padding-top: 0;
  width: 100%;
}

.cd54-nav-item {
  position: relative;
  padding: 16px 0;
  border-bottom: 2px solid #2563eb !important;
  margin: 0 !important;
}

.cd54-nav-item:first-child {
  border-top: 2px solid #2563eb !important;
}

.cd54-nav-item a {
  position: relative;
  color: var(--cd54-text-dark) !important;
  text-decoration: none !important;
  font-weight: 700;
  font-size: 15px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
  padding-left: 0;
  display: inline-block;
}

/* Animation billes de billard */
.cd54-nav-item a::before {
  content: '';
  position: absolute;
  left: -30px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  border-radius: 50%;
  opacity: 0;
  transition: all 0.3s ease;
}

.cd54-nav-item:nth-child(1) a::before { background: #e53935; }
.cd54-nav-item:nth-child(2) a::before { background: #ffffff; box-shadow: 0 0 3px #333; }
.cd54-nav-item:nth-child(3) a::before { background: #fdd835; }
.cd54-nav-item:nth-child(4) a::before { background: #e53935; }
.cd54-nav-item:nth-child(5) a::before { background: #ffffff; box-shadow: 0 0 3px #333; }
.cd54-nav-item:nth-child(6) a::before { background: #fdd835; }
.cd54-nav-item:nth-child(7) a::before { background: #e53935; }

.cd54-nav-item:hover a {
  padding-left: 30px;
  color: #2563eb !important;
}

.cd54-nav-item:hover a::before {
  left: 0;
  opacity: 1;
}

/* ============================================================
   9. CARTES D'ARTICLES (existant amélioré)
   ============================================================ */

.cd54-articles-grid .wp-block-post-template {
  gap: 32px !important;
}

.cd54-card {
  background: #fff !important;
  border-radius: 16px !important;
  overflow: hidden !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
  transition: all 0.3s ease !important;
}

.cd54-card:hover {
  transform: translateY(-6px) !important;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12) !important;
}

.cd54-card .wp-block-post-featured-image {
  margin: 0 !important;
  overflow: hidden;
}

.cd54-card .wp-block-post-featured-image img,
.wp-block-post .wp-block-post-featured-image img,
.wp-block-post-template .wp-block-post-featured-image img {
  transition: transform 0.3s ease;
  width: 100% !important;
  height: auto !important;
  max-height: 200px !important;
  aspect-ratio: 16/9 !important;
  object-fit: cover !important;
}

.cd54-card:hover .wp-block-post-featured-image img {
  transform: scale(1.05);
}

.cd54-card .wp-block-post-title {
  padding: 20px 20px 0 20px !important;
}

.cd54-card .wp-block-post-title a {
  color: var(--cd54-text-dark);
  text-decoration: none;
  font-size: 16px !important;
  font-weight: 700 !important;
}

.cd54-card .wp-block-post-title a:hover {
  color: var(--cd54-primary, #DD183B);
}

/* SPÉCIFIQUE: Emojis/icônes dans les cartes articles (PAS l'image à la une) */
.cd54-card .wp-block-post-title img,
.cd54-card .wp-block-post-title svg,
.cd54-card .wp-block-post-excerpt img,
.cd54-card .wp-block-post-excerpt svg,
.cd54-card .wp-block-post-date img,
.cd54-card .wp-block-post-date svg,
.wp-block-post .wp-block-post-title img,
.wp-block-post .wp-block-post-title svg,
.wp-block-post .wp-block-post-excerpt img,
.wp-block-post .wp-block-post-excerpt svg {
  width: 1em !important;
  height: 1em !important;
  max-width: 1em !important;
  max-height: 1em !important;
  min-width: 1em !important;
  min-height: 1em !important;
  display: inline !important;
  vertical-align: -0.1em !important;
}

.cd54-card .wp-block-post-date {
  padding: 8px 20px 20px 20px !important;
  color: #6B7280 !important;
  font-size: 13px !important;
}

/* ============================================================
   10. RESPONSIVE - OPTIMISÉ MOBILE FIRST
   ============================================================ */

/* --- TABLETTES (max 992px) --- */
@media (max-width: 992px) {
  /* Grilles en colonnes réduites */
  .cd54-events-grid {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }

  .cd54-news-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 20px !important;
  }

  .cd54-training-grid {
    grid-template-columns: 1fr !important;
    gap: 20px !important;
  }

  /* Section clubs en colonne */
  .cd54-clubs-preview,
  .cd54-clubs-preview.wp-block-columns {
    grid-template-columns: 1fr !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 24px !important;
  }

  .cd54-clubs-preview > .wp-block-column {
    min-height: auto !important;
    height: auto !important;
  }

  .cd54-clubs-map {
    min-height: 45vh !important;
    height: 45vh !important;
  }

  .cd54-clubs-map .leaflet-container,
  .cd54-clubs-map .wp-block-shortcode {
    min-height: 45vh !important;
    height: 45vh !important;
  }

  /* Forcer les popups Leaflet à hauteur auto (ne pas hériter des 300px) */
  .cd54-clubs-map .leaflet-popup,
  .cd54-clubs-map .leaflet-popup-content-wrapper,
  .cd54-clubs-map .leaflet-popup-content {
    min-height: auto !important;
    height: auto !important;
  }

  .cd54-clubs-list {
    min-height: auto !important;
    height: auto !important;
  }

  .cd54-clubs-list-items {
    max-height: 350px !important;
  }

  /* Titres de sections */
  .cd54-events-section > h2,
  .cd54-news-section > h2,
  .cd54-training-section > h2,
  .cd54-clubs-section > h2,
  .cd54-section-title {
    font-size: 1.6rem !important;
    margin-bottom: 28px !important;
  }
}

/* --- SMARTPHONES (max 782px) --- */
@media (max-width: 782px) {

  /* === HEADER MOBILE - STRUCTURE FLEX === */
  .site-header,
  .ast-primary-header,
  #masthead {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 9999 !important;
    background: #fff !important;
    height: 60px !important;
    min-height: 60px !important;
    max-height: 60px !important;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08) !important;
    overflow: visible !important; /* Permet au logo de déborder */
  }

  /* Conteneur principal du header - FLEX */
  .ast-primary-header-bar,
  .ast-builder-grid-row {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
    height: 60px !important;
    padding: 0 16px !important;
  }

  /* Forcer la structure flex gauche/droite */
  .site-header-primary-section-left {
    flex: 0 0 auto !important;
    order: 1 !important;
  }

  .site-header-primary-section-right {
    flex: 0 0 auto !important;
    order: 2 !important;
    margin-left: auto !important;
  }

  /* === LOGO MOBILE - À CHEVAL SUR LE HERO === */
  .site-branding,
  .ast-site-identity {
    position: relative !important;
    z-index: 10000 !important;
    overflow: visible !important;
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
  }

  /* === TITRE HEADER - DESIGN ÉLÉGANT AVEC DÉCO === */

  /* Bloc titre avec décoration raffinée */
  .site-branding::after,
  .ast-site-identity::after {
    content: '« Le billard en Meurthe‑et‑Moselle »' !important;
    font-family: 'Outfit', Arial, sans-serif !important;
    white-space: nowrap !important;
    text-align: center !important;
    opacity: 0 !important;
    visibility: hidden !important;
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
    transform: translateX(-10px) !important;
    margin-left: 10px !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    font-style: italic !important;
    color: #374151 !important;
    letter-spacing: 0.5px !important;
    /* Relief élégant - effet gravure */
    text-shadow:
      0 1px 0 rgba(255, 255, 255, 1),
      0 -1px 0 rgba(0, 0, 0, 0.05) !important;
    background: transparent !important;
    padding: 4px 0 !important;
    /* Bordure décorative dessous */
    border-bottom: 1px solid transparent !important;
    background-image: linear-gradient(90deg, transparent, #DD183B 20%, #DD183B 80%, transparent) !important;
    background-size: 100% 1px !important;
    background-repeat: no-repeat !important;
    background-position: bottom !important;
  }

  /* Animation au scroll */
  body.scrolled .site-branding::after,
  body.scrolled .ast-site-identity::after {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateX(0) !important;
  }

  .custom-logo-link {
    display: block !important;
    overflow: visible !important;
  }

  /* Logo qui déborde du header vers le bas - SIMPLE sans double cercle */
  .custom-logo-link img,
  header .custom-logo-link img,
  .site-header .custom-logo-link img,
  body.home .custom-logo-link img,
  body.home .site-header .custom-logo-link img,
  body.home header .custom-logo-link img,
  body.home.scrolled .custom-logo-link img,
  body.home.scrolled .site-header .custom-logo-link img,
  body.home.scrolled header .custom-logo-link img {
    width: 80px !important;
    height: 80px !important;
    max-width: 80px !important;
    max-height: 80px !important;
    position: relative !important;
    top: 10px !important;
    display: block !important;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.15)) !important;
    border-radius: 0 !important; /* Pas de cercle - le logo a déjà sa forme */
    background: transparent !important;
    border: none !important;
  }

  /* === MENU BURGER - POSITIONNÉ À DROITE === */
  .ast-mobile-menu-buttons {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    position: absolute !important;
    right: 16px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
  }

  .ast-button-wrap {
    display: flex !important;
  }

  /* Bouton burger - design épuré et sobre */
  .ast-mobile-menu-trigger-minimal,
  .menu-toggle {
    background: #f8f9fa !important; /* Gris très clair */
    border: 1px solid #e5e7eb !important;
    border-radius: 8px !important;
    width: 44px !important;
    height: 44px !important;
    min-width: 44px !important;
    min-height: 44px !important;
    padding: 0 !important;
    position: relative !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08) !important;
  }

  /* Masquer le SVG d'Astra */
  .ast-mobile-menu-trigger-minimal svg,
  .ast-mobile-menu-trigger-minimal .ast-mobile-svg,
  .menu-toggle svg {
    display: none !important;
  }

  /* 3 barres du burger en CSS - couleur gris foncé */
  .ast-mobile-menu-trigger-minimal::before,
  .ast-mobile-menu-trigger-minimal::after,
  .menu-toggle::before,
  .menu-toggle::after {
    content: '' !important;
    position: absolute !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    width: 18px !important;
    height: 2px !important;
    background: #374151 !important; /* Gris foncé */
    border-radius: 1px !important;
  }

  .ast-mobile-menu-trigger-minimal::before,
  .menu-toggle::before {
    top: 14px !important;
    box-shadow: 0 7px 0 #374151 !important; /* Barre du milieu */
  }

  .ast-mobile-menu-trigger-minimal::after,
  .menu-toggle::after {
    bottom: 14px !important;
  }

  /* === MENU MOBILE - DÉCALÉ SOUS LE HEADER === */
  .ast-mobile-popup-drawer,
  .ast-mobile-popup-content,
  .ast-mobile-header-content,
  .ast-mobile-popup-inner,
  #ast-mobile-popup,
  .main-header-menu,
  .ast-mobile-menu-wrap,
  .ast-hfb-header .main-header-menu {
    top: 60px !important; /* Commence après le header */
    padding-top: 10px !important;
  }

  /* Menu déroulant pleine largeur */
  .ast-mobile-popup-drawer.active,
  .ast-mobile-header-content.active {
    position: fixed !important;
    top: 60px !important;
    left: 0 !important;
    right: 0 !important;
    max-height: calc(100vh - 60px) !important;
    overflow-y: auto !important;
    z-index: 9998 !important;
    background: #fff !important;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1) !important;
  }

  /* Éléments du menu - padding suffisant */
  .ast-mobile-popup-drawer .menu-item,
  .ast-mobile-header-content .menu-item,
  .main-header-menu .menu-item {
    padding: 12px 20px !important;
    border-bottom: 1px solid #f0f0f0 !important;
  }

  .ast-mobile-popup-drawer .menu-item a,
  .ast-mobile-header-content .menu-item a,
  .main-header-menu .menu-item a {
    font-size: 16px !important;
    color: var(--cd54-text-dark) !important;
  }

  /* Espace pour le header fixe */
  body,
  body.home {
    padding-top: 60px !important;
  }

  /* Reset des comportements desktop pour le logo */
  body.home .ast-primary-header-bar .site-branding {
    margin-bottom: 0 !important;
    position: relative !important;
  }

  /* === SIDEBAR MOBILE - MASQUÉE (contenu dans le menu burger) === */
  .cd54-sidebar {
    display: none !important;
  }

  /* Colonne principale pleine largeur */
  .cd54-sidebar + .wp-block-column,
  .cd54-sidebar ~ .wp-block-column {
    flex-basis: 100% !important;
    max-width: 100% !important;
  }

  /* Colonnes en colonne sur mobile */
  .wp-block-columns {
    flex-direction: column !important;
  }

  /* === HERO MOBILE - COMPACT ET SANS COINS ARRONDIS === */
  .cd54-hero,
  .wp-block-cover.cd54-hero {
    min-height: 220px !important;
    max-height: 280px !important;
    margin-top: 0 !important;
    border-radius: 0 !important;
    overflow: hidden !important;
  }

  .cd54-hero .wp-block-cover__inner-container {
    padding: 16px !important;
    min-height: 200px !important;
  }

  .cd54-hero-content {
    padding: 14px !important;
    max-width: 100% !important;
    margin: 0 !important;
    border-radius: 10px !important;
  }

  .cd54-hero-content .cd54-hero-tag {
    font-size: 9px !important;
    padding: 4px 10px !important;
    margin-bottom: 6px !important;
  }

  .cd54-hero-content h2,
  .cd54-hero-content .wp-block-heading {
    font-size: 1.1rem !important;
    margin-bottom: 4px !important;
    line-height: 1.2 !important;
  }

  .cd54-hero-content .cd54-hero-meta {
    font-size: 11px !important;
    margin-bottom: 10px !important;
    gap: 4px !important;
  }

  .cd54-hero-buttons {
    flex-direction: column !important;
    gap: 6px !important;
  }

  .cd54-hero-buttons .wp-block-button__link {
    width: 100% !important;
    text-align: center !important;
    padding: 10px 14px !important;
    font-size: 13px !important;
    min-height: 40px !important;
  }

  /* === SECTIONS MOBILE === */
  .cd54-events-section,
  .cd54-news-section,
  .cd54-results-section,
  .cd54-training-section,
  .cd54-clubs-section {
    padding: 32px 16px !important;
  }

  /* Titres de sections */
  .cd54-events-section > h2,
  .cd54-news-section > h2,
  .cd54-training-section > h2,
  .cd54-clubs-section > h2,
  .cd54-section-title {
    font-size: 1.4rem !important;
    margin-bottom: 24px !important;
  }

  /* === CARTES ÉVÉNEMENTS MOBILE === */
  .cd54-events-grid {
    gap: 12px !important;
  }

  .cd54-event-card {
    display: flex !important;
    flex-direction: row !important;
    border-radius: 12px !important;
    overflow: hidden !important;
  }

  .cd54-event-card .cd54-event-date {
    min-width: 70px !important;
    max-width: 70px !important;
    padding: 12px 8px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    border-radius: 0 !important;
    margin: 0 !important;
  }

  .cd54-event-card .cd54-event-date .day {
    font-size: 1.8rem !important;
    line-height: 1 !important;
  }

  .cd54-event-card .cd54-event-date .month {
    font-size: 11px !important;
    margin-top: 2px !important;
  }

  .cd54-event-card .cd54-event-content {
    padding: 12px 14px !important;
    flex: 1 !important;
  }

  .cd54-event-card .cd54-event-discipline {
    font-size: 10px !important;
    padding: 3px 8px !important;
    margin-bottom: 6px !important;
  }

  .cd54-event-card h3,
  .cd54-event-card .wp-block-heading {
    font-size: 0.95rem !important;
    margin-bottom: 6px !important;
    line-height: 1.3 !important;
  }

  .cd54-event-card .cd54-event-location {
    font-size: 12px !important;
  }

  /* Bouton calendrier mobile */
  .cd54-events-section .wp-block-button {
    margin-top: 20px !important;
  }

  .cd54-events-section .wp-block-button .wp-block-button__link {
    width: 100% !important;
    padding: 12px 20px !important;
    font-size: 14px !important;
    min-height: 44px !important;
  }

  /* === GRILLE NEWS MOBILE === */
  .cd54-news-grid {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }

  .cd54-news-card .cd54-news-content {
    padding: 16px !important;
  }

  .cd54-news-card .wp-block-post-title {
    font-size: 1rem !important;
  }

  /* === CARTES FORMATION MOBILE === */
  .cd54-training-grid {
    gap: 16px !important;
  }

  .cd54-training-card {
    border-radius: 12px !important;
  }

  .cd54-training-card .cd54-training-image {
    aspect-ratio: 16/9 !important;
    max-height: 180px !important;
  }

  .cd54-training-card .cd54-training-content {
    padding: 20px !important;
  }

  .cd54-training-card h3,
  .cd54-training-card .wp-block-heading {
    font-size: 1.2rem !important;
    margin-bottom: 8px !important;
  }

  .cd54-training-card p {
    font-size: 14px !important;
    margin-bottom: 16px !important;
    line-height: 1.5 !important;
  }

  .cd54-training-card .wp-block-button__link {
    padding: 12px 20px !important;
    font-size: 14px !important;
    min-height: 44px !important;
  }

  /* === SECTION CLUBS MOBILE === */
  .cd54-clubs-map {
    min-height: 40vh !important;
    height: 40vh !important;
    border-radius: 12px !important;
  }

  .cd54-clubs-map .leaflet-container,
  .cd54-clubs-map .wp-block-shortcode {
    min-height: 40vh !important;
    height: 40vh !important;
    border-radius: 12px !important;
  }

  .cd54-clubs-list {
    padding: 14px 16px !important;
    border-radius: 12px !important;
  }

  .cd54-clubs-list h3 {
    font-size: 0.9rem !important;
    margin-bottom: 10px !important;
  }

  .cd54-clubs-list-items {
    max-height: 280px !important;
  }

  .cd54-club-item {
    padding: 8px 0 !important;
    min-height: 44px !important; /* Touch target */
  }

  .cd54-club-item .cd54-club-logo,
  .cd54-club-item figure.cd54-club-logo {
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
    max-width: 28px !important;
  }

  .cd54-club-item .cd54-club-logo img {
    width: 28px !important;
    height: 28px !important;
    max-width: 28px !important;
  }

  .cd54-clubs-list .cd54-view-all-clubs {
    padding: 12px 16px !important;
    font-size: 13px !important;
    min-height: 44px !important;
  }

  /* === POPUPS LEAFLET MOBILE - Plus compactes (hauteur réduite) === */
  .cd54-clubs-map .leaflet-popup {
    margin-bottom: 10px !important;
  }

  .cd54-clubs-map .leaflet-popup-content-wrapper {
    border-radius: 6px !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12) !important;
    padding: 8px 10px !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
  }

  .cd54-clubs-map .leaflet-popup-content {
    margin: 0 !important;
    padding: 0 !important;
    font-size: 12px !important;
    line-height: 1.3 !important;
    min-width: 100px !important;
    max-width: 150px !important;
    width: auto !important;
    height: auto !important;
    min-height: 0 !important;
  }

  .cd54-clubs-map .leaflet-popup-content strong {
    font-size: 11px !important;
    display: block !important;
    margin-bottom: 2px !important;
    line-height: 1.1 !important;
  }

  .cd54-clubs-map .leaflet-popup-content br {
    display: none !important;
  }

  .cd54-clubs-map .leaflet-popup-content a {
    font-size: 10px !important;
    display: inline-block !important;
    margin-top: 2px !important;
  }

  .cd54-clubs-map .leaflet-popup-close-button {
    top: 0 !important;
    right: 0 !important;
    width: 14px !important;
    height: 14px !important;
    font-size: 12px !important;
    line-height: 12px !important;
    padding: 0 !important;
  }

  .cd54-clubs-map .leaflet-popup-tip {
    width: 10px !important;
    height: 10px !important;
  }

  /* === TABLEAU RÉSULTATS MOBILE === */
  .cd54-results-table {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    border-radius: 12px !important;
  }

  .cd54-results-table table {
    min-width: 500px !important;
  }

  .cd54-results-table th,
  .cd54-results-table td {
    padding: 12px 14px !important;
    font-size: 13px !important;
  }

  /* === CARTES ARTICLES (Query Loop) - COMPACTES === */
  .cd54-card,
  .wp-block-post {
    border-radius: 12px !important;
    overflow: hidden !important;
  }

  /* Images des articles plus petites */
  .cd54-card .wp-block-post-featured-image,
  .wp-block-post .wp-block-post-featured-image {
    aspect-ratio: 16/10 !important;
    max-height: 140px !important;
    overflow: hidden !important;
  }

  .cd54-card .wp-block-post-featured-image img,
  .wp-block-post .wp-block-post-featured-image img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    max-height: 140px !important;
  }

  .cd54-card .wp-block-post-title,
  .wp-block-post .wp-block-post-title {
    padding: 12px 14px 0 14px !important;
  }

  .cd54-card .wp-block-post-title a,
  .wp-block-post .wp-block-post-title a {
    font-size: 14px !important;
    line-height: 1.3 !important;
  }

  .cd54-card .wp-block-post-date,
  .wp-block-post .wp-block-post-date {
    padding: 6px 14px 12px 14px !important;
    font-size: 11px !important;
  }

  /* Grille articles - 2 colonnes sur mobile */
  .cd54-articles-grid .wp-block-post-template,
  .wp-block-query .wp-block-post-template {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px !important;
  }

  /* === DÉSACTIVER TOUS LES EFFETS HOVER SUR TACTILE === */
  .cd54-event-card:hover,
  .cd54-news-card:hover,
  .cd54-training-card:hover,
  .cd54-card:hover,
  .wp-block-post:hover,
  .cd54-club-item:hover,
  .wp-block-button__link:hover,
  .ast-mobile-menu-trigger-minimal:hover,
  .menu-toggle:hover,
  a:hover {
    transform: none !important;
    box-shadow: inherit !important;
  }

  /* Pas de changement de couleur au hover sur tactile */
  .cd54-club-item:hover .cd54-club-info h4,
  .cd54-club-item:hover .cd54-club-info h4 a {
    color: inherit !important;
  }
}

/* --- PETITS SMARTPHONES (max 480px) --- */
@media (max-width: 480px) {
  /* Hero encore plus compact */
  .cd54-hero {
    min-height: 280px !important;
  }

  .cd54-hero .wp-block-cover__inner-container {
    padding: 20px 12px !important;
    min-height: 240px !important;
  }

  .cd54-hero-content {
    padding: 16px !important;
  }

  .cd54-hero-content h2,
  .cd54-hero-content .wp-block-heading {
    font-size: 1.2rem !important;
  }

  .cd54-hero-content .cd54-hero-meta {
    font-size: 12px !important;
    flex-direction: column !important;
    gap: 4px !important;
  }

  /* Logo plus petit sur petits écrans - toujours à cheval */
  .custom-logo-link img,
  header .custom-logo-link img,
  body.home header .custom-logo-link img,
  body.home .site-header .custom-logo-link img {
    width: 70px !important;
    height: 70px !important;
    max-width: 70px !important;
    max-height: 70px !important;
    top: 8px !important;
    border-radius: 0 !important;
    background: transparent !important;
    border: none !important;
  }

  /* Sections plus compactes */
  .cd54-events-section,
  .cd54-news-section,
  .cd54-results-section,
  .cd54-training-section,
  .cd54-clubs-section {
    padding: 24px 12px !important;
  }

  /* Titres plus petits */
  .cd54-events-section > h2,
  .cd54-news-section > h2,
  .cd54-training-section > h2,
  .cd54-clubs-section > h2,
  .cd54-section-title {
    font-size: 1.25rem !important;
    margin-bottom: 20px !important;
  }

  /* Cartes événements très compactes */
  .cd54-event-card .cd54-event-date {
    min-width: 60px !important;
    max-width: 60px !important;
    padding: 10px 6px !important;
    border-radius: 0 !important;
  }

  .cd54-event-card .cd54-event-date .day {
    font-size: 1.5rem !important;
  }

  .cd54-event-card .cd54-event-date .month {
    font-size: 10px !important;
  }

  .cd54-event-card .cd54-event-content {
    padding: 10px 12px !important;
  }

  .cd54-event-card h3 {
    font-size: 0.85rem !important;
  }

  /* Cartes formation très compactes */
  .cd54-training-card .cd54-training-image {
    max-height: 150px !important;
  }

  .cd54-training-card .cd54-training-content {
    padding: 16px !important;
  }

  .cd54-training-card h3 {
    font-size: 1.1rem !important;
  }

  .cd54-training-card p {
    font-size: 13px !important;
  }

  /* Carte clubs très compacte */
  .cd54-clubs-map {
    min-height: 35vh !important;
    height: 35vh !important;
  }

  .cd54-clubs-map .leaflet-container,
  .cd54-clubs-map .wp-block-shortcode {
    min-height: 35vh !important;
    height: 35vh !important;
  }

  .cd54-clubs-list-items {
    max-height: 220px !important;
  }

  .cd54-club-item .cd54-club-info h4,
  .cd54-club-item .cd54-club-info h4 a {
    font-size: 12px !important;
  }

  .cd54-club-item .cd54-club-info p,
  .cd54-club-item .cd54-club-info span {
    font-size: 10px !important;
  }
}

/* --- TRÈS PETITS ÉCRANS (max 360px) --- */
@media (max-width: 360px) {
  .cd54-hero-content h2,
  .cd54-hero-content .wp-block-heading {
    font-size: 1.1rem !important;
  }

  .cd54-hero-buttons .wp-block-button__link {
    padding: 10px 16px !important;
    font-size: 13px !important;
  }

  .cd54-event-card .cd54-event-date {
    min-width: 55px !important;
    max-width: 55px !important;
    border-radius: 0 !important;
  }

  .cd54-event-card .cd54-event-date .day {
    font-size: 1.3rem !important;
  }
}

/* === FIX: Garantir le padding-left sur mobile pour éviter le contenu coupé === */
@media (max-width: 782px) {
  /* Forcer le padding sur les sections pour éviter le contenu coupé à gauche */
  body.home .cd54-training-section,
  body.home .cd54-clubs-section,
  body.home .cd54-events-section,
  body.home .cd54-news-section {
    padding-left: 16px !important;
    padding-right: 16px !important;
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: hidden !important;
  }

  /* Titres de sections - s'assurer qu'ils ne débordent pas */
  body.home .cd54-section-title,
  body.home .cd54-clubs-section > h2,
  body.home .cd54-training-section > h2 {
    padding-left: 0 !important;
    margin-left: 0 !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
}

/* ============================================================
   11. HEADER OPAQUE SUR HOMEPAGE (masquer le hero derrière)
   ============================================================ */

/* Forcer le header opaque sur la homepage pour masquer l'image hero */
body.home .site-header,
body.home .ast-primary-header,
body.home #masthead {
  background: #fff !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

/* Garder le logo au-dessus avec z-index élevé */
body.home .site-branding,
body.home .custom-logo-link {
  z-index: 1000 !important;
}

/* ============================================================
   12. HEADER - RESPONSIVE GRANDS ÉCRANS (Logo & Titre)
   ============================================================ */

/* --- Écrans Full HD (1601px - 1920px) - Moniteurs 22"-24" --- */
@media (min-width: 1601px) and (max-width: 1920px) {
  /* Logo - léger décalage vers la gauche */
  body.home header .custom-logo-link img,
  body.home .site-header .custom-logo-link img {
    left: -100px !important;
  }

  /* Logo scrollé */
  body.home.scrolled header .custom-logo-link img,
  body.home.scrolled .site-header .custom-logo-link img {
    left: -100px !important;
  }
}

/* --- Écrans QHD 2K (1921px - 2560px) - Moniteurs 24"-27" --- */
@media (min-width: 1921px) and (max-width: 2560px) {
  /* Logo - décalage modéré vers la gauche */
  body.home header .custom-logo-link img,
  body.home .site-header .custom-logo-link img {
    left: -320px !important;
  }

  /* Logo scrollé */
  body.home.scrolled header .custom-logo-link img,
  body.home.scrolled .site-header .custom-logo-link img {
    left: -320px !important;
  }
}

/* --- Écrans 4K (2561px - 3840px) - Moniteurs 27"+ haut de gamme --- */
@media (min-width: 2561px) and (max-width: 3840px) {
  /* Logo - décalage important vers la gauche */
  body.home header .custom-logo-link img,
  body.home .site-header .custom-logo-link img {
    left: -700px !important;
  }

  /* Logo scrollé */
  body.home.scrolled header .custom-logo-link img,
  body.home.scrolled .site-header .custom-logo-link img {
    left: -700px !important;
  }
}

/* --- Écrans Ultra-larges / TV (> 3840px) - Cas exceptionnel --- */
@media (min-width: 3841px) {
  /* Logo - décalage très important vers la gauche */
  body.home header .custom-logo-link img,
  body.home .site-header .custom-logo-link img {
    left: -1250px !important;
  }

  /* Logo scrollé */
  body.home.scrolled header .custom-logo-link img,
  body.home.scrolled .site-header .custom-logo-link img {
    left: -1250px !important;
  }
}

/* ============================================================
   13. TITRE HEADER DESKTOP - "Le billard en Meurthe-et-Moselle"
   ============================================================ */

/* Container du branding - permettre le positionnement du titre */
body.home .site-branding,
body.home .ast-site-identity {
  position: relative !important;
}

/* Header bar wrap au scroll */
body.home.scrolled .main-header-bar-wrap {
  position: relative !important;
  height: 0 !important;
}

/* Titre desktop - styles de base avec position dynamique via JavaScript */
body.home .ast-primary-header::after {
  content: '« Le billard en Meurthe‑et‑Moselle »' !important;
  position: fixed !important;
  top: 75px !important;
  /* Position dynamique calculée par header.js (fallback 320px si JS non chargé) */
  left: var(--cd54-title-left, 320px) !important;
  font-family: 'Outfit', Arial, sans-serif !important;
  font-size: 15px !important;
  font-weight: 500 !important;
  font-style: italic !important;
  color: #374151 !important;
  letter-spacing: 0.5px !important;
  white-space: nowrap !important;
  z-index: 100 !important;
  transition: all 0.3s ease !important;
  /* Relief élégant */
  text-shadow:
    0 1px 0 rgb(255 255 255),
    0 -1px 0 rgb(0 0 0 / 0.03) !important;
  /* Soulignement dégradé */
  padding-bottom: 6px !important;
  background-image: linear-gradient(90deg, transparent, #DD183B 15%, #DD183B 85%, transparent) !important;
  background-size: 100% 2px !important;
  background-repeat: no-repeat !important;
  background-position: bottom !important;
}

/* Titre desktop - suit le logo lors du scroll */
body.home.scrolled .ast-primary-header::after {
  top: 65px !important;
  position: fixed !important;
}

/* Masquer sur mobile */
@media (max-width: 782px) {
  body.home .ast-primary-header::after {
    display: none !important;
  }
}

