/* =====================================
    GLOBAL RESET
===================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Inter", sans-serif;
}

body {
  background: #f5f6f8;
  color: #1d1d1d;
}

/* =====================================
    TOP HEADER (Logo + Search + User Icon)
===================================== */
.header {
  width: 100%;
  background: #2c3546;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 15px;
  margin-bottom: 2px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.header-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  flex: 1;
  max-width: 600px; /* Limit width of centered content */
  margin: 0 auto; /* Center the container */
}

.logo {
  font-size: 20px;
  font-weight: 800;
  color: #fff;
  white-space: nowrap;
  display: flex;
  align-items: center;
  justify-content: center;
}

.search-box {
  background: #fff;
  padding: 8px 12px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 2;
  min-width: 200px;
  max-width: 500px;
  width: 100%;
  margin-right: auto;
}

/* Mobile header adjustments */
@media (max-width: 767.98px) {
  .header {
    padding: 10px 15px;
    align-items: center;
  }

  .header-center {
    flex-direction: row;
    align-items: center;
    gap: 10px;
    max-width: calc(100% - 60px); /* Account for menu button */
  }

  .logo {
    order: 2; /* Place logo in the middle */
    flex: 1;
    justify-content: center;
  }

  .search-box.d-none.d-md-block {
    display: none !important; /* Hide desktop search on mobile */
  }
}

.search-box input {
  border: none;
  outline: none;
  width: 100%;
  font-size: 14px;
}

.search-box i {
  color: #333;
  align-items: center;
}

.header-right i {
  color: #fff;
  font-size: 20px;
  cursor: pointer;
}

/* =====================================
    NAVBAR KATEGORI
===================================== */
.nav-kategori {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  background: #2c3546;
  padding: 10px 15px;
  justify-content: center;
}

.nav-kategori a {
  text-decoration: none;
  color: #dfe6ee;
  font-weight: 500;
  transition: 0.2s;
  padding: 5px 10px;
  border-radius: 4px;
  white-space: nowrap;
}

.nav-kategori a:hover {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.1);
}

/* =====================================
    LAYOUT BERITA UTAMA
===================================== */
.container {
  width: 100%;
  max-width: 1100px;
  margin-right: auto;
  margin-left: auto;
  padding-right: 15px;
  padding-left: 15px;
}

/* Kolom kiri (headline) */
.headline {
  width: 100%;
  max-width: 72%;
}

.headline img {
  width: 100%;
  border-radius: 16px;
  margin-bottom: 10px;
}

.headline-title {
  font-size: 22px;
  font-weight: 700;
  color: #111;
  margin-top: 10px;
}

/* Berita kecil di bawah headline */
.small-news {
  display: flex;
  gap: 15px;
  margin-top: 15px;
  flex-wrap: wrap;
}

.small-card {
  width: calc(33.333% - 10px);
  flex: 1;
  min-width: 250px;
}

.small-card img {
  width: 100%;
  border-radius: 12px;
}

.small-card-title {
  font-size: 14px;
  font-weight: 600;
  margin: 6px 0;
}

.small-card-cat {
  font-size: 12px;
  color: #777;
}

/* =====================================
    SIDEBAR (Tag Terpopuler + Berita Populer)
===================================== */
.sidebar {
  width: 100%;
  max-width: 28%;
}

.sidebar h3 {
  font-size: 18px;
  margin-bottom: 12px;
}

.tag-list a {
  display: block;
  text-decoration: none;
  color: #444;
  padding: 4px 0;
}

.tag-list a:hover {
  text-decoration: underline;
}

.popular-number {
  font-size: 26px;
  font-weight: bold;
  color: #2c3546;
  margin-right: 10px;
}

.popular-item {
  display: flex;
  gap: 10px;
  margin-bottom: 15px;
}

.popular-item-title {
  font-size: 15px;
  font-weight: 600;
}

.popular-meta {
  font-size: 13px;
  color: #777;
}

/* ======================================css terbaru==================================== */

/* ===============================
   WRAPPER LAYOUT
================================ */
.news-wrapper {
  width: 100%;
  max-width: 1250px;
  margin: 20px auto;
  padding: 0 15px;
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

/* ===============================
   LEFT COLUMN (BERITA)
================================ */
.left-news {
  width: 100%;
  max-width: 72%;
  flex: 1;
  min-width: 300px;
}

/* ===============================
   HEADLINE NEWS (KARTU BESAR)
================================ */
.headline-card {
  background: #000;
  border-radius: 18px;
  overflow: hidden;
  margin-bottom: 20px;
}

.headline-card img {
  width: 100%;
  display: block;
  height: 250px;
  object-fit: cover;
}

.headline-card-title {
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  padding: 15px;
}

/* ===============================
   3 SMALL NEWS BELOW HEADLINE
================================ */
.small-news-row {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.small-news-card {
  background: #fff;
  width: calc(33.333% - 10px);
  border-radius: 16px;
  overflow: hidden;
  flex: 1;
  min-width: 200px;
}

.small-news-card img {
  width: 100%;
  height: 150px;
  object-fit: cover;
}

.small-news-title {
  font-size: 14px;
  font-weight: 600;
  margin: 8px 12px;
}

.small-news-cat {
  font-size: 12px;
  color: #777;
  margin: 0 12px 12px;
}

.news-card-list {
  background: #fff;
  width: calc(33.333% - 10px);
  border-radius: 16px;
  overflow: hidden;
  flex: 1;
  min-width: 200px;
}

/* ===============================
   SIDEBAR KANAN
================================ */
.sidebar-right {
  width: 100%;
  max-width: 28%;
  flex: 0 0 auto;
  min-width: 250px;
}

/* --- Tag Terpopuler --- */
.sidebar-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 12px;
  color: #2d3648;
}

.tag-list {
  padding-bottom: 20px;
  border-bottom: 1px solid #ddd;
  margin-bottom: 20px;
}

.tag-list a {
  display: block;
  font-size: 14px;
  color: #444;
  padding: 6px 0;
  text-decoration: none;
}

.tag-list a:hover {
  text-decoration: underline;
}

/* --- Berita Terpopuler Section --- */
.popular-block h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 12px;
  color: #2d3648;
}

.popular-item {
  margin-bottom: 12px;
  display: flex;
  align-items: flex-start;
}

.popular-rank {
  font-size: 18px;
  font-weight: bold;
  color: #2a2a2a;
  margin-right: 8px;
  min-width: 20px;
}

.popular-text {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  flex: 1;
}

.popular-meta {
  font-size: 12px;
  color: #777;
  margin-top: 3px;
}

/* ===============================
   RESPONSIVE
================================ */
@media (max-width: 1024px) {
  .news-wrapper {
    gap: 15px;
  }
  .left-news {
    max-width: 70%;
  }
  .sidebar-right {
    max-width: 28%;
  }
  .small-news-card {
    width: calc(33.333% - 10px);
    min-width: 180px;
  }
}

@media (max-width: 900px) {
  .news-wrapper {
    flex-direction: column;
  }
  .left-news,
  .sidebar-right {
    width: 100%;
    max-width: 100%;
  }
  .small-news-row {
    flex-direction: row;
    justify-content: space-between;
  }
  .small-news-card {
    width: calc(50% - 10px);
    min-width: auto;
  }
  .headline-card img {
    height: 200px;
  }
  .headline-card-title {
    font-size: 20px;
    padding: 12px;
  }
}

@media (max-width: 768px) {
  .small-news-row {
    flex-direction: column;
  }
  .small-news-card {
    width: 100%;
  }
  .nav-kategori {
    gap: 8px;
    padding: 8px 10px;
  }
  .nav-kategori a {
    padding: 4px 8px;
    font-size: 14px;
  }
  .header {
    padding: 8px 10px;
    gap: 8px;
  }
  .header-left {
    min-width: 150px;
    gap: 8px;
  }
  .logo {
    font-size: 18px;
  }
  .search-box {
    min-width: 150px;
    padding: 6px 10px;
  }
  .headline-card img {
    height: 180px;
  }
  .headline-card-title {
    font-size: 18px;
    padding: 10px;
  }
}

@media (max-width: 576px) {
  .header {
    flex-direction: column;
    align-items: stretch;
  }
  .header-left {
    order: 1;
    justify-content: center;
  }
  .logo {
    justify-content: center;
    text-align: center;
  }
  .search-box {
    order: 2;
    max-width: 100%;
    margin: 10px 0;
  }
  .news-wrapper {
    padding: 0 10px;
  }
  .popular-item {
    flex-direction: column;
    align-items: normal;
  }
  .popular-rank {
    margin-bottom: 5px;
  }
  .footer-top {
    flex-direction: column;
  }
  .small-news-card {
    min-width: auto;
  }
  .headline-card-title {
    font-size: 16px;
  }
  .headline-card img {
    height: 150px;
  }
}

@media (max-width: 480px) {
  .nav-kategori {
    justify-content: flex-start;
    overflow-x: auto;
    white-space: nowrap;
    padding: 5px;
  }
  .nav-kategori a {
    flex-shrink: 0;
  }
  .small-news-card img {
    height: 120px;
  }
  .logo {
    font-size: 16px;
  }
  .search-box input {
    font-size: 13px;
  }
}

/* =========================================================================css footer=============================================== */

/* ===============================
   FOOTER STYLE (AFU.ID Style)
================================ */

footer {
  background: #1f1f1f; /* warna gelap */
  color: #ddd;
  padding: 40px 0 20px;
  font-family: "Inter", Arial, sans-serif;
  font-size: 14px;
}

.footer-container {
  width: 100%;
  max-width: 1300px;
  margin: auto;
  padding: 0 15px;
}

/* --- Footer Top (3 kolom) --- */
.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 25px;
  padding-bottom: 25px;
  border-bottom: 1px solid #3a3a3a;
  flex-wrap: wrap;
}

/* Kolom Kiri */
.footer-left {
  width: 40%;
  color: #cfcfcf;
  line-height: 1.6;
  min-width: 250px;
  flex: 1;
}

/* Kolom Tengah (Dewan Pers) */
.footer-middle {
  width: 35%;
  min-width: 250px;
  flex: 1;
}

.footer-middle strong {
  color: #fff;
  font-weight: 700;
}

/* Kolom Kanan (Ikuti Kami) */
.footer-right {
  width: 25%;
  text-align: right;
  min-width: 200px;
  flex: 0 0 auto;
}

.footer-right h4 {
  color: #fff;
  margin-bottom: 12px;
}

/* --- Social Icons --- */
.footer-social {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.footer-social a {
  width: 32px;
  height: 32px;
  background: #3a3a3a;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  text-decoration: none;
  transition: 0.2s;
}

.footer-social a:hover {
  background: #ffffff;
}

.footer-social i,
.footer-social svg {
  color: #fff;
  font-size: 14px;
}

.footer-social a:hover i,
.footer-social a:hover svg {
  color: #000;
}

/* --- Footer Bottom --- */
.footer-bottom {
  text-align: center;
  padding-top: 20px;
  color: #bdbdbd;
  font-size: 13px;
}

.footer-links {
  margin-bottom: 10px;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}

.footer-links a {
  color: #bdbdbd;
  text-decoration: none;
  padding: 0 5px;
  font-size: 13px;
}

.footer-links a:hover {
  text-decoration: underline;
}

/* ===============================
   RESPONSIVE
================================ */
@media (max-width: 900px) {
  .footer-top {
    flex-direction: column;
    text-align: left;
    gap: 20px;
  }
  .footer-right {
    text-align: left;
  }
  .footer-social {
    justify-content: flex-start;
  }
  .footer-left,
  .footer-middle {
    width: 100%;
  }
}

@media (max-width: 576px) {
  footer {
    padding: 30px 0 15px;
  }
  .footer-links {
    flex-direction: column;
    align-items: center;
  }
  .footer-links a {
    display: block;
    margin: 3px 0;
  }
  .footer-social {
    gap: 6px;
  }
  .footer-social a {
    width: 30px;
    height: 30px;
  }
  .footer-social i,
  .footer-social svg {
    font-size: 13px;
  }
}

@media (max-width: 480px) {
  .footer-container {
    padding: 0 10px;
  }
  .footer-top {
    align-items: center;
  }
  .footer-right h4 {
    margin-top: 10px;
  }
}
