/* ===================================================
   Layout: Three card hover section
   File:   template-parts/flexible/three_card_hover_section/three_card_hover_section.css
=================================================== */

.three-card-hover-section {
  position: relative;
  width: 100%;
}

.three-card-hover-section__container {
  padding: 60px 0;
}

.three-card-hover-section .icon-heading {
  display: flex;
  align-items: center;
  gap: 12px;
}

.three-card-hover-section .icon-heading img {
  width: auto;
  height: auto;
  display: inline-block;
}

.hover-cards-row {
  --bs-gutter-x: 24px;
  --bs-gutter-y: 24px;
}

/* Card Container */
.hover-card {
  height: 460px;
  width: 100%;
  background-color: var(--color-17, #fefefd);
  border-radius: 16px;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.04);
}

/* Text Container */
.heading-container-hc {
  padding: 28px 24px 16px;
  position: relative;
  z-index: 2;
}

.hover-card .hc-heading {
  color: var(--color-18, #282828);
  margin: 0 0 16px 0;
  padding: 0 0 24px 0 !important;
}

.hover-card .hc-para {
  color: var(--color-19, #4c4c4c);
  margin: 0;
  padding: 0;
}

/* Animated SVG Background Overlay */
.hover-bg-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: auto;
  pointer-events: none;
  z-index: 1;
  transform: translateY(100%);
  will-change: transform;
}

/* Bottom Card Image */
.hover-card-img {
  height: 250px;
  width: 100%;
  border-radius: 12px;
  object-fit: cover;
  object-position: center;
  transform: none;
  margin-top: auto;
  position: relative;
  z-index: 2;
  display: block;
}

/* ===================================================
   DESKTOP ONLY: Hover Effects (>=992px)
=================================================== */
@media (min-width: 992px) {
  .hover-card {
    cursor: pointer;
    transition:
      transform 0.35s ease,
      box-shadow 0.35s ease,
      background-color 0.4s ease 0.15s;
  }

  .hover-card .hc-heading {
    transition: color 0.35s ease 0.1s;
  }

  .hover-card .hc-para {
    transition: color 0.35s ease 0.1s;
  }

  .hover-bg-overlay {
    transition: transform 1.3s cubic-bezier(0.22, 1, 0.36, 1);
  }

  .hover-card-img {
    transform: translateX(35%);
    transition: transform 1.3s cubic-bezier(0.22, 1, 0.36, 1);
  }

  /* Desktop Hover State */
  .hover-card:hover .hc-heading,
  .hover-card.is-hovered .hc-heading {
    color: var(--color-17, #fefefd);
  }

  .hover-card:hover .hc-para,
  .hover-card.is-hovered .hc-para {
    color: rgba(254, 254, 253, 0.9);
  }

  .hover-card:hover .hover-bg-overlay,
  .hover-card.is-hovered .hover-bg-overlay {
    transform: translateY(0);
  }

  .hover-card:hover .hover-card-img,
  .hover-card.is-hovered .hover-card-img {
    transform: translateX(0);
  }
}

/* ===================================================
   MOBILE & TABLET ADJUSTMENTS (<992px)
=================================================== */
@media (max-width: 991.98px) {
  .hover-card {
    height: 400px;
    cursor: default;
  }

  .hover-bg-overlay {
    display: none !important;
  }
  .three-card-hover-section__container {
    padding: 40px 0;
  }

  .hover-card {
    height: 420px;
  }

  .hover-card-img {
    height: 220px;
    margin: 0;
    transform: none !important;
  }

  .heading-container-hc {
    padding: 20px 20px 12px;
  }

  .three-card-hover-section__container-row-1 {
    gap: 24px;
  }
}
