/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  background: var(--color-background);
}

.hero-section {
  padding-top: 32px;
  margin-bottom: 4rem;
}

.hero-lead-grid .grid-wrapper {
  display: grid;
  grid-template-columns: 2fr 1fr; /* kiri hero, kanan subheadline */
  gap: 14px;
  align-items: start;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 var(--container-gap);
}

/* ====== Hero utama ====== */
.hero-lead-main {
  background: #fff;
  overflow: hidden;
  width: 100%; /* pastikan tetap penuh grid */
}

.hero-image {
  width: auto;
  max-width: 100%;
  height: 390px;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  margin: 0;
  margin-left: auto;
  margin-right: auto;
}

.hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-content {
  max-width: 100%;
  margin: 0;
  padding-top: 1rem;
  margin-left: auto;
  margin-right: auto;
}

.hero-title {
  font-family: "Inter", sans-serif;
  font-size: 2.4rem;
  font-weight: 600;
  color: #000;
  line-height: 1.3;
  margin: 12px 0 0.6rem 0;
}

.hero-title a {
  color: inherit;
  text-decoration: none;
  display: inline-block;
  position: relative;
  padding-bottom: 3px;
}
.hero-title a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background: red;
  transition: width 0.3s ease;
}

.hero-title a:hover {
  color: var(--color-primary);
}

.hero-title a:hover::after {
  width: 100%;
}

.hero-excerpt {
  font-family: "Inter", sans-serif;
  font-size: 1.4rem;
  color: #000;
  line-height: 1.6;
  margin: 0 0 0.8rem 0;
}

.hero-content .post-date {
  font-family: "Inter", sans-serif;
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--color-text-light);
  margin-top: 4px;
  text-align: left;
  display: block;
}

/* ====== Subheadline (kanan) ====== */
.hero-lead-side {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px; /* rapatkan jarak antar kartu */
  align-content: start;
}

.subheadline-card {
  display: flex;
  flex-direction: row; /* thumbnail kiri, teks kanan */
  align-items: flex-start;
  gap: 12px;
  background: #fff;
  margin: 0;
  padding: 0;
  margin-bottom: 4px;
}

.subheadline-thumb {
  flex-shrink: 0;
  flex: 0 0 220px;
  width: 220px;
  height: 140px;
  overflow: hidden;
}

.subheadline-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.subheadline-info {
  flex: 1;
}

.subheadline-title {
  font-family: "Inter", sans-serif;
  font-size: 1.6rem;
  font-weight: 600;
  color: #000;
  line-height: 1.4;
  margin: 8px 0 4px 0;
}

.subheadline-date {
  font-family: "Inter", sans-serif;
  font-weight: 400;
  font-size: 1.3rem;
  color: var(--color-text-light);
  margin-top: 2px;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 1024px) {
  .hero-lead-grid .grid-wrapper {
    grid-template-columns: 1fr; /* satu kolom, hero di atas subheadline */
  }
  .hero-content {
    padding-top: 1rem;
  }
  .hero-title {
    font-size: 2.2rem;
    line-height: 1.28;
  }
  /* excerpt masih tampil di tablet */
}

/* Tambahan untuk tablet landscape/medium (769–1024px) */
@media (min-width: 769px) and (max-width: 1024px) {
  .hero-lead-side {
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }

  .subheadline-thumb {
    width: 100%;
    height: auto; /* biar proporsional */
    aspect-ratio: 16 / 9; /* menjaga rasio */
    overflow: hidden;
  }

  .subheadline-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  .subheadline-title {
    font-size: 1.6rem; /* samakan dengan featured-grid */
    line-height: 1.4;
  }
}

@media (max-width: 768px) {
  .hero-image {
    height: auto; /* override height 320px global */
    margin: 0;
  }

  .hero-image img {
    height: auto;
    aspect-ratio: 16 / 9;
    object-position: center center;
  }

  .hero-title {
    font-size: 2.2rem;
    line-height: 1.3;
    margin: 6px 0 0.4rem 0;
  }

  .hero-content {
    padding-top: 0;
  }

  .hero-excerpt {
    display: none; /* dihapus mulai mobile */
  }

  .hero-lead-side {
    grid-template-columns: 1fr 1fr; /* subheadline jadi 2 kolom */
    gap: 12px;
    align-items: start;
  }

  .subheadline-card {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding: 0;
    margin-bottom: 6px;
  }

  .subheadline-thumb {
    flex: none;
    width: 100%;
    max-width: 100%;
    height: 140px;
    overflow: hidden;
  }

  .subheadline-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
  }

  .subheadline-info {
    padding: 0.35rem 0;
  }

  .subheadline-title {
    font-size: 1.8rem; /* sama besar dengan featured-grid */
    line-height: 1.4;
    margin: 6px 0 4px 0;
  }

  .subheadline-date {
    font-size: 1.2rem;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 2rem; /* tetap besar di small mobile */
    line-height: 1.25;
    margin: 6px 0 0.4rem 0;
  }

  .subheadline-thumb {
    height: 120px; /* lebih pendek di small mobile */
  }

  .subheadline-title {
    font-size: 1.6rem; /* konsisten dengan featured-grid */
  }
}
