/* === Qi Lounge Patch v8.3 Uniform Card Aspect === */

/* Apply uniform aspect ratio and contain-fit for all cards */
.events-grid .card .media {
  aspect-ratio: 4 / 3;
  background-color: #000;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 10px;
}

.events-grid .card .media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background-color: #000;
  border-radius: 10px;
}

/* Optional per-page adjustment */
.page-home .events-grid .card .media { aspect-ratio: 4 / 3; }
.page-menus .events-grid .card .media {   aspect-ratio: 5 / 3; }
.page-events .events-grid .card .media { aspect-ratio: 4 / 3; }

.card .media a {
  display: block;
  width: 100%;
  height: 100%;
}

/* supaya area klik mengisi frame */
.card .media a,
.card .img-link { display:block; width:100%; height:100%; }

/* Index Highlights: besarkan tanpa memotong */
.home-highlights .card .media img{
  width: 80%;         /* naikkan 90 → 96–98% sesuai selera */
  height: 80%;
  object-fit: contain;
  margin: 0 auto;
}
@media (min-width: 1200px){
  .home-highlights .card .media img{ width: 100%; }
}

/* ==== Center image secara vertikal dan horizontal di dalam frame ==== */
.home-highlights .card .media {
  display: flex;              /* aktifkan flexbox */
  align-items: center;        /* pusat vertikal */
  justify-content: center;    /* pusat horizontal */
  background: #000;           /* latar hitam tetap */
  aspect-ratio: 16/9;         /* pertahankan frame */
  overflow: hidden;
}

/* Gambar tidak terpotong, tapi tetap di tengah */
.home-highlights .card .media img {
  width: 100%;                /* jangan paksa lebar penuh */
  height: 100%;               /* isi tinggi frame */
  object-fit: contain;        /* biar tidak crop */
}