/* Saintngelic WA Card */

.elementor-widget-sng_wa_card {
  width: 100%;
  max-width: 100%;
}

.elementor-widget-sng_wa_card .elementor-widget-container {
  width: 100%;
  max-width: 100%;
  overflow: visible;
}

.sng-wa-card {
  position: relative;
  display: block;
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  aspect-ratio: 2 / 3;
  height: auto;
  min-height: 200px;
  background: #000;
  overflow: hidden;
  -webkit-tap-highlight-color: transparent;
}

@supports not (aspect-ratio: 2 / 3) {
  .sng-wa-card {
    height: 0;
    min-height: 0;
    padding-bottom: 150%;
  }
}

.sng-wa-card__link {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  text-decoration: none;
  color: inherit;
}

.sng-wa-card__media {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  line-height: 0;
  font-size: 0;
}

.sng-wa-card__image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  min-width: 100%;
  min-height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  margin: 0;
  padding: 0;
  border: 0;
  transition: opacity 0.5s cubic-bezier(0.12, 0.06, 0.3, 1) 0.05s;
}

.sng-wa-card__image--primary {
  opacity: 1;
  z-index: 1;
}

.sng-wa-card__image--hover {
  opacity: 0;
  z-index: 2;
}

@media (hover: hover) and (pointer: fine) {
  .sng-wa-card:hover .sng-wa-card__image--primary,
  .sng-wa-card__link:hover .sng-wa-card__image--primary {
    opacity: 0;
  }

  .sng-wa-card:hover .sng-wa-card__image--hover,
  .sng-wa-card__link:hover .sng-wa-card__image--hover {
    opacity: 1;
  }
}

.sng-wa-card__btn {
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: #fefcf5;
  color: #250903;
  text-decoration: none;
  cursor: pointer;
  opacity: 0;
  transform: translateY(6px);
  transition:
    opacity 0.25s ease,
    transform 0.25s ease,
    background 0.2s ease;
}

.sng-wa-card__btn-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

@media (hover: hover) and (pointer: fine) {
  .sng-wa-card:hover .sng-wa-card__btn,
  .sng-wa-card__btn:focus {
    opacity: 1;
    transform: translateY(0);
  }

  .sng-wa-card__btn:hover,
  .sng-wa-card__btn:focus {
    background: #f5f0e6;
    color: #250903;
  }
}

/* Tablet & mobile: tombol selalu terlihat */
@media (hover: none), (pointer: coarse), (max-width: 1024px) {
  .sng-wa-card__btn {
    opacity: 1;
    transform: translateY(0);
  }
}

.sng-wa-card__placeholder {
  margin: 0;
  padding: 12px;
  font-size: 13px;
  color: #666;
}

@media screen and (max-width: 1024px) {
  .sng-wa-card {
    min-height: 180px;
  }

  .sng-wa-card__btn {
    right: 12px;
    bottom: 12px;
    width: 38px;
    height: 38px;
  }

  .sng-wa-card__btn-icon {
    width: 17px;
    height: 17px;
  }
}

@media screen and (max-width: 767px) {
  .sng-wa-card {
    min-height: 160px;
  }

  .sng-wa-card__btn {
    right: 10px;
    bottom: 10px;
    width: 36px;
    height: 36px;
  }

  .sng-wa-card__btn-icon {
    width: 16px;
    height: 16px;
  }
}

/* Loop Grid */
.elementor-loop-container:has(.elementor-widget-sng_wa_card),
.elementor-widget-loop-grid:has(.elementor-widget-sng_wa_card) {
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.elementor-loop-container:has(.elementor-widget-sng_wa_card) .e-loop-item,
.elementor-widget-loop-grid:has(.elementor-widget-sng_wa_card) .e-loop-item {
  min-width: 0;
  max-width: 100%;
}

.elementor-loop-container:has(.elementor-widget-sng_wa_card) .elementor-grid-1,
.elementor-widget-loop-grid:has(.elementor-widget-sng_wa_card) .elementor-grid-1 {
  grid-template-columns: repeat(1, minmax(0, 1fr)) !important;
}

.elementor-loop-container:has(.elementor-widget-sng_wa_card) .elementor-grid-2,
.elementor-widget-loop-grid:has(.elementor-widget-sng_wa_card) .elementor-grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

.elementor-loop-container:has(.elementor-widget-sng_wa_card) .elementor-grid-3,
.elementor-widget-loop-grid:has(.elementor-widget-sng_wa_card) .elementor-grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
}

.elementor-loop-container:has(.elementor-widget-sng_wa_card) .elementor-grid-4,
.elementor-widget-loop-grid:has(.elementor-widget-sng_wa_card) .elementor-grid-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
}

.elementor-loop-container:has(.elementor-widget-sng_wa_card) .elementor-grid-5,
.elementor-widget-loop-grid:has(.elementor-widget-sng_wa_card) .elementor-grid-5 {
  grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
}

.elementor-loop-container:has(.elementor-widget-sng_wa_card) .elementor-grid-6,
.elementor-widget-loop-grid:has(.elementor-widget-sng_wa_card) .elementor-grid-6 {
  grid-template-columns: repeat(6, minmax(0, 1fr)) !important;
}
