/* ===== HOVER CARDS - BASE ===== */

.elementor-widget-hover_cards,
.elementor-widget-hover_cards > .elementor-widget-container,
.elementor-widget-hover_cards .elementor-widget-container,
.elementor-element.elementor-widget-hover_cards,
.elementor-widget-hover_cards .elementor-element,
.elementor-widget-hover_cards .elementor-element-populated,
.elementor-widget-hover_cards .elementor-container,
.elementor-widget-hover_cards .elementor-column,
.elementor-widget-hover_cards .elementor-column-wrap,
.elementor-widget-hover_cards .elementor-widget-wrap,
.hc2-section,
.hc2-section > .elementor-container,
.hc2-section .elementor-column,
.hc2-section .elementor-widget-wrap{
  overflow:visible !important;
  clip:auto !important;
  clip-path:none !important;
}

html,
body{
  overflow-x:hidden;
}

.hc2{
  --hc-height:420px;
  --hc-gap:20px;
  --hc-radius:8px;
  --hc-card-width:320px;
  --hc-grid-cols:3;
  --hc-grid-rows:2;
  --hc-overlay:linear-gradient(180deg, rgba(0,0,0,0.05) 0%, rgba(0,0,0,0.55) 100%);
  --hc-hover-bg:rgba(0,0,0,0.75);
  --hc-image-tint:rgba(53, 74, 68, 0.38);
  --hc-image-tint-opacity:0.38;
  --hc-hover-gradient:transparent;
  --hc-arrow-size:56px;

  position:relative;
  width:100%;
  overflow:visible !important;
}

.hc2[style*="--hc-hover-gradient"] .hc2-hover-panel{
  background:var(--hc-card-hover-bg, var(--hc-hover-gradient, var(--hc-hover-bg)));
}

.hc2 *,
.hc2 *::before,
.hc2 *::after{
  box-sizing:border-box;
}

.hc2-track{
  position:relative;
  z-index:1;
  width:100%;
}

/* ===== SLIDER ===== */

.hc2--slider{
  overflow:visible !important;
}

.hc2--slider .hc2-track{
  display:flex;
  gap:var(--hc-gap);
  align-items:stretch;
  width:100%;
  overflow-x:auto;
  overflow-y:hidden;
  scroll-behavior:smooth;
  scrollbar-width:none;
  -ms-overflow-style:none;
  padding-bottom:2px;
  background:transparent;
}

.hc2--slider .hc2-track::-webkit-scrollbar{
  display:none;
}

.hc2--slider .hc2-card{
  flex:0 0 var(--hc-card-width);
  width:var(--hc-card-width);
}

.hc2--slider .hc2-card:last-child{
  margin-right:0;
}

/* ===== GRILLE ===== */

.hc2.hc2--grid .hc2-track{
  display:grid !important;
  grid-template-columns:repeat(var(--hc-grid-cols), minmax(0, 1fr)) !important;
  gap:var(--hc-gap) !important;
  width:100% !important;
}

.hc2.hc2--grid.hc2--grid-fixed .hc2-track{
  grid-template-columns:repeat(var(--hc-grid-cols), var(--hc-card-width)) !important;
  justify-content:start !important;
}

.hc2.hc2--grid.hc2--grid-fixed .hc2-card{
  width:var(--hc-card-width) !important;
  max-width:var(--hc-card-width) !important;
}

/* ===== CARD ===== */

.hc2-card{
  position:relative;
  display:block;
  overflow:hidden;
  border-radius:var(--hc-radius);
  text-decoration:none;
  color:inherit;
  height:var(--hc-height);
  min-height:var(--hc-height);
  isolation:isolate;
}

.hc2-bg,
.hc2-shade,
.hc2-hover-panel,
.hc2-footer{
  position:absolute;
  inset:0;
}

.hc2-bg{
  z-index:1;
  background-size:cover;
  background-position:center;
  background-repeat:no-repeat;
  transform:scale(1);
  transition:transform .35s ease;
}

.hc2-card:hover .hc2-bg,
.hc2-card:focus-within .hc2-bg,
.hc2-card.is-open .hc2-bg{
  transform:scale(1.03);
}

.hc2-shade{
  z-index:2;
  background:var(--hc-overlay);
}

.hc2-shade::before{
  content:"";
  position:absolute;
  inset:0;
  background:var(--hc-image-tint);
  opacity:var(--hc-image-tint-opacity);
  pointer-events:none;
}

/* ===== HOVER ===== */

.hc2-hover-panel{
  z-index:3;
  padding:26px 22px 110px;
  background:var(--hc-card-hover-bg, var(--hc-hover-bg));
  opacity:0;
  visibility:hidden;
  transition:opacity .25s ease, visibility .25s ease;
  pointer-events:none;
}

.hc2-card:hover .hc2-hover-panel,
.hc2-card:focus-within .hc2-hover-panel,
.hc2-card.is-open .hc2-hover-panel{
  opacity:1;
  visibility:visible;
  pointer-events:auto;
}

.hc2-hover-content{
  max-width:260px;
  color:#fff;
  text-shadow:0 2px 12px rgba(0,0,0,0.20);
}

.hc2-hover-content,
.hc2-hover-content p,
.hc2-hover-content li{
  color:inherit;
}

.hc2-hover-content p:last-child{
  margin-bottom:0;
}

/* ===== BOUTON ===== */

.hc2-button{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  margin-top:20px;
  padding:10px 18px;
  border-radius:999px;
  background:#fff;
  color:#354a44;
  text-decoration:none;
  font-weight:600;
  line-height:1.2;
  pointer-events:auto;
  transition:transform .2s ease, opacity .2s ease;
}

.hc2-button:hover{
  transform:translateY(-1px);
  opacity:.9;
}

/* ===== FOOTER ===== */

.hc2-footer{
  z-index:4;
  top:auto;
  inset:auto 0 0 0;
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:16px;
  padding:22px;
}

.hc2-title{
  margin:0;
  color:#fff;
  line-height:1.05;
  text-shadow:0 2px 10px rgba(0,0,0,0.18);
}

/* ===== ICÔNES ===== */

.hc2-icon{
  flex:0 0 auto;
  min-width:20px;
  min-height:20px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  color:#fff;
  position:relative;
  line-height:1;
  font-family:Arial, Helvetica, sans-serif;
  font-weight:300;
}

.hc2-icon-closed,
.hc2-icon-open{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  line-height:1;
  font-size:28px;
  font-weight:300;
}

.hc2-icon-open{
  display:none !important;
}

.hc2-card:hover .hc2-icon-open,
.hc2-card:focus-within .hc2-icon-open,
.hc2-card.is-open .hc2-icon-open{
  display:inline-flex !important;
}

.hc2-card:hover .hc2-icon-closed,
.hc2-card:focus-within .hc2-icon-closed,
.hc2-card.is-open .hc2-icon-closed{
  display:none !important;
}

/* ===== FLÈCHES ===== */

.hc2-nav{
  display:flex;
  justify-content:flex-end;
  gap:12px;
  margin-bottom:28px;
  position:relative;
  z-index:999;
  overflow:visible !important;
}

.hc2-arrow{
  width:38px;
  height:38px;
  border:0;
  border-radius:4px;
  background:#f2eee8;
  color:#2d3a36;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:0;
  font-size:20px;
  line-height:1;
  box-shadow:none;
  cursor:pointer;
  transition:opacity .2s ease, transform .2s ease;
  position:relative;
  z-index:1000;
  pointer-events:auto;
}

.hc2-arrow:hover{
  transform:translateY(-1px);
}

.hc2-arrow:disabled{
  opacity:.45;
  cursor:not-allowed;
  transform:none;
}

.hc2-arrow img{
  width:18px;
  height:18px;
  object-fit:contain;
  display:block;
}

/* ===== TABLETTE ===== */

@media (max-width:1024px){
  .hc2-card{
    cursor:pointer;
  }

  .hc2-card.is-open .hc2-hover-panel{
    opacity:1 !important;
    visibility:visible !important;
    pointer-events:auto;
  }

  .hc2-card.is-open .hc2-bg{
    transform:scale(1.03);
  }

  .hc2-card.is-open .hc2-icon-open{
    display:inline-flex !important;
  }

  .hc2-card.is-open .hc2-icon-closed{
    display:none !important;
  }
}

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

@media (max-width:767px){
  .hc2{
    --hc-height:360px;
  }

  .hc2-nav{
    margin-bottom:16px;
    gap:12px;
  }

  .hc2.hc2--grid .hc2-track,
  .hc2.hc2--grid.hc2--grid-fixed .hc2-track{
    grid-template-columns:1fr !important;
  }

  .hc2.hc2--grid.hc2--grid-fixed .hc2-card{
    width:100% !important;
    max-width:100% !important;
  }

  .hc2--slider .hc2-card{
    flex:0 0 var(--hc-card-width);
    width:var(--hc-card-width);
  }

  .hc2-hover-panel{
    background:var(--hc-hover-gradient);
    padding:20px 18px 110px;
  }

  .hc2-hover-content{
    max-width:none;
  }

  .hc2-card:hover .hc2-bg,
  .hc2-card:focus-within .hc2-bg{
    transform:none;
  }

  .hc2-card:hover .hc2-hover-panel,
  .hc2-card:focus-within .hc2-hover-panel{
    opacity:0;
    visibility:hidden;
    pointer-events:none;
  }

  .hc2-card.is-open .hc2-hover-panel{
    opacity:1 !important;
    visibility:visible !important;
    pointer-events:auto;
  }

  .hc2-card:hover .hc2-icon-open,
  .hc2-card:focus-within .hc2-icon-open{
    display:none !important;
  }

  .hc2-card:hover .hc2-icon-closed,
  .hc2-card:focus-within .hc2-icon-closed{
    display:inline-flex !important;
  }

  .hc2-card.is-open .hc2-icon-open{
    display:inline-flex !important;
  }

  .hc2-card.is-open .hc2-icon-closed{
    display:none !important;
  }
}


/* ===== MODE GRILLE STYLE CARTE MODERNE ===== */

/* Hover = fond plein */
.hc2.hc2--grid .hc2-hover-panel{
  background:var(--hc-card-hover-bg, var(--hc-grid-hover-bg, #A92B23)) !important;
  padding:40px;
  display:flex;
  align-items:center;
  justify-content:center;
}

/* Alignement contenu */
.hc2.hc2--grid .hc2-hover-content{
  text-align:var(--hc-grid-content-align, center);
  max-width:600px;
  width:100%;
}

/* Bouton en lien simple */
.hc2.hc2--grid .hc2-button{
  background:none !important;
  padding:0 !important;
  margin-top:25px;
  text-decoration:underline;
}

/* Titre caché uniquement au hover */
.hc2.hc2--grid.hc2-grid-title--hover_only .hc2-card:hover .hc2-footer{
  opacity:0;
}

/* Titre totalement supprimé */
.hc2.hc2--grid.hc2-grid-title--hidden .hc2-footer{
  display:none;
}



/* ===== TITRE SLIDER ===== */

.hc2.hc2--slider.hc2-slider-title--hover_only .hc2-card:hover .hc2-footer,
.hc2.hc2--slider.hc2-slider-title--hover_only .hc2-card:focus-within .hc2-footer,
.hc2.hc2--slider.hc2-slider-title--hover_only .hc2-card.is-open .hc2-footer{
  opacity:0;
}

.hc2.hc2--slider.hc2-slider-title--hidden .hc2-footer{
  display:none;
}

.hc2-nav{
  margin-bottom:28px;
}

.hc2 .hc2-track + .hc2-nav{
  margin-top:28px;
  margin-bottom:0;
}


.hc2.hc2--slider .hc2-hover-panel{
  background:var(--hc-slider-hover-bg, var(--hc-hover-gradient)) !important;
}


.hc2-title-v-top .hc2-footer{
  align-items:flex-start;
}

.hc2-title-v-center .hc2-footer{
  align-items:center;
}

.hc2-title-v-bottom .hc2-footer{
  align-items:flex-end;
}

.hc2-footer{
  text-align:var(--hc-title-align, left);
}

.hc2[style*="--hc-title-align: center"] .hc2-footer{
  justify-content:center;
}

.hc2[style*="--hc-title-align: right"] .hc2-footer{
  justify-content:flex-end;
}

.hc2[style*="--hc-title-align: left"] .hc2-footer{
  justify-content:flex-start;
}

/* ===== POSITION TITRE DANS LA CARD ===== */

.hc2 .hc2-footer{
  top:0 !important;
  right:0 !important;
  bottom:0 !important;
  left:0 !important;
  inset:0 !important;
  padding:22px !important;
  display:flex !important;
  gap:0 !important;
  pointer-events:none;
}

.hc2 .hc2-title{
  width:100%;
  max-width:100%;
}

/* Vertical */
.hc2.hc2-title-v-top .hc2-footer{
  align-items:flex-start !important;
}

.hc2.hc2-title-v-center .hc2-footer{
  align-items:center !important;
}

.hc2.hc2-title-v-bottom .hc2-footer{
  align-items:flex-end !important;
}

/* Horizontal */
.hc2[style*="--hc-title-align: left"] .hc2-footer{
  justify-content:flex-start !important;
  text-align:left !important;
}

.hc2[style*="--hc-title-align: center"] .hc2-footer{
  justify-content:center !important;
  text-align:center !important;
}

.hc2[style*="--hc-title-align: right"] .hc2-footer{
  justify-content:flex-end !important;
  text-align:right !important;
}

/* L’icône ne doit plus décaler le titre */
.hc2 .hc2-icon{
  position:absolute;
  right:22px;
  bottom:22px;
}