:root {
  --yellow: #ffcf00;
  --blue: #063b70;
  --darkblue: #052b50;
  --red: #e52232;
  --black: #171717;
  --gray: #777;
  --light: #f4f5f7;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  color: var(--black);
  background: #fff;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  max-width: 1240px;
  margin: auto;
  padding: 0 20px;
}

/* TOP BAR */
.topbar {
  background: var(--darkblue);
  color: white;
  font-size: 12px;
  padding: 9px 0;
}

.topbar-content {
  display: flex;
  justify-content: space-between;
  gap: 15px;
}

/* HEADER */
header {
  background: white;
  border-bottom: 4px solid var(--yellow);
}

.header-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 19px 0;
}

.logo {
  font-size: 35px;
  font-weight: 900;
  letter-spacing: -2px;
  color: var(--blue);
}

.logo span {
  color: var(--red);
}

.logo small {
  display: block;
  font-size: 9px;
  letter-spacing: 3px;
  color: #777;
  font-weight: bold;
  margin-top: 3px;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 18px;
}

.search {
  border: 1px solid #ddd;
  padding: 10px 14px;
  border-radius: 3px;
}

.search input {
  border: none;
  outline: none;
  width: 145px;
  font-size: 13px;
}

.search button {
  background: none;
  border: none;
  cursor: pointer;
}

/* NAVIGATION */
nav {
  background: var(--blue);
  color: white;
}

.nav-content {
  display: flex;
  align-items: center;
  gap: 0;
  overflow-x: auto;
}

.nav-content a {
  padding: 14px 15px;
  font-size: 12px;
  font-weight: bold;
  white-space: nowrap;
  text-transform: uppercase;
}

.nav-content a:hover,
.nav-content a.active {
  background: var(--yellow);
  color: #111;
}

.menu-button {
  display: none;
  border: 0;
  background: none;
  font-size: 24px;
  cursor: pointer;
}

/* BREAKING NEWS */
.breaking {
  display: flex;
  align-items: center;
  background: #f2f2f2;
  margin: 20px auto;
  overflow: hidden;
}

.breaking-label {
  background: var(--red);
  color: white;
  padding: 13px 17px;
  font-size: 12px;
  font-weight: bold;
  white-space: nowrap;
}

.breaking-text {
  padding: 12px 18px;
  font-size: 13px;
  font-weight: bold;
}

/* SECTION */
.section-title {
  font-size: 20px;
  font-weight: 900;
  text-transform: uppercase;
  border-left: 5px solid var(--yellow);
  padding-left: 12px;
  margin-bottom: 20px;
}

.section-title span {
  color: var(--blue);
}

/* HERO */
.hero-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 22px;
  margin-bottom: 35px;
}

.hero-main {
  position: relative;
  height: 440px;
  overflow: hidden;
  background: #ddd;
}

.hero-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: .4s;
}

.hero-main:hover img,
.news-card:hover img {
  transform: scale(1.04);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(transparent 25%, rgba(0,0,0,.9));
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 30px;
  color: white;
}

.category {
  display: inline-block;
  background: var(--yellow);
  color: #111;
  font-size: 10px;
  font-weight: bold;
  padding: 6px 9px;
  margin-bottom: 12px;
  width: fit-content;
}

.hero-overlay h1 {
  font-size: 34px;
  line-height: 1.2;
  margin-bottom: 12px;
}

.meta {
  font-size: 11px;
  color: #aaa;
}

.hero-side {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.side-news {
  display: grid;
  grid-template-columns: 115px 1fr;
  gap: 13px;
  padding-bottom: 15px;
  border-bottom: 1px solid #eee;
}

.side-news img {
  width: 115px;
  height: 88px;
  object-fit: cover;
}

.side-news h3 {
  font-size: 14px;
  line-height: 1.4;
  margin-bottom: 8px;
}

.side-news h3:hover {
  color: var(--red);
}

/* MAIN CONTENT */
.main-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 30px;
}

.news-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
}

.news-card {
  overflow: hidden;
  border-bottom: 1px solid #ddd;
  padding-bottom: 16px;
}

.news-image {
  width: 100%;
  height: 190px;
  overflow: hidden;
  background: #eee;
}

.news-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: .4s;
}

.news-card h3 {
  font-size: 17px;
  line-height: 1.4;
  margin: 8px 0;
}

.news-card h3:hover {
  color: var(--blue);
}

.news-card p {
  font-size: 13px;
  color: var(--gray);
  line-height: 1.6;
  margin-bottom: 10px;
}

/* SIDEBAR */
.sidebar-box {
  margin-bottom: 30px;
}

.sidebar-title {
  font-size: 17px;
  font-weight: 900;
  padding-bottom: 12px;
  border-bottom: 3px solid var(--blue);
  margin-bottom: 15px;
}

.trending-item {
  display: flex;
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px solid #eee;
}

.trending-number {
  font-size: 25px;
  font-weight: 900;
  color: var(--red);
}

.trending-item h4 {
  font-size: 13px;
  line-height: 1.4;
}

/* BLUE BANNER */
.blue-banner {
  background: var(--blue);
  color: white;
  padding: 25px;
  margin: 25px 0;
}

.blue-banner h2 {
  font-size: 23px;
  margin-bottom: 8px;
}

.blue-banner p {
  font-size: 13px;
  line-height: 1.6;
  color: #ddd;
}

/* CATEGORY BLOCK */
.category-section {
  margin: 35px 0;
}

.category-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.category-card {
  background: var(--light);
  padding: 18px;
  border-top: 4px solid var(--yellow);
}

.category-card:nth-child(2) {
  border-color: var(--blue);
}

.category-card:nth-child(3) {
  border-color: var(--red);
}

.category-card h3 {
  font-size: 16px;
  margin-bottom: 12px;
}

.category-card p {
  font-size: 13px;
  line-height: 1.5;
  padding: 10px 0;
  border-top: 1px solid #ddd;
}

/* NEWSLETTER */
.newsletter {
  background: var(--yellow);
  padding: 30px;
  margin: 40px 0;
  text-align: center;
}

.newsletter h2 {
  font-size: 23px;
  margin-bottom: 10px;
}

.newsletter p {
  font-size: 13px;
  margin-bottom: 15px;
}

.newsletter input {
  padding: 13px;
  width: 260px;
  max-width: 65%;
  border: none;
}

.newsletter button {
  padding: 13px 20px;
  border: none;
  background: var(--blue);
  color: white;
  font-weight: bold;
  cursor: pointer;
}

/* FOOTER */
footer {
  background: var(--darkblue);
  color: white;
  padding: 40px 0 20px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 35px;
}

footer h3 {
  color: var(--yellow);
  margin-bottom: 15px;
}

footer p, footer a {
  font-size: 13px;
  line-height: 2;
  color: #ccc;
}

footer a {
  display: block;
}

.copyright {
  border-top: 1px solid #34506c;
  margin-top: 30px;
  padding-top: 20px;
  text-align: center;
  font-size: 11px;
  color: #aaa;
}

/* RESPONSIVE */
@media(max-width: 800px) {
  .logo {
    font-size: 27px;
  }

  .menu-button {
    display: block;
  }

  .nav-content {
    display: none;
    flex-direction: column;
    align-items: stretch;
  }

  .nav-content.show {
    display: flex;
  }

  .nav-content a {
    border-bottom: 1px solid #ffffff22;
  }

  .header-right .search {
    display: none;
  }

  .hero-grid,
  .main-layout {
    grid-template-columns: 1fr;
  }

  .hero-main {
    height: 350px;
  }

  .hero-overlay h1 {
    font-size: 25px;
  }

  .hero-side {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media(max-width: 500px) {
  .container {
    padding: 0 14px;
  }

  .hero-main {
    height: 290px;
  }

  .hero-overlay {
    padding: 18px;
  }

  .hero-overlay h1 {
    font-size: 22px;
  }

  .hero-side,
  .news-grid,
  .category-cards,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .side-news img {
    width: 105px;
  }

  .breaking-text {
    font-size: 11px;
  }

  .newsletter input {
    width: 100%;
    max-width: 100%;
    margin-bottom: 8px;
  }
}

/* TAMBAHAN HALAMAN DINAMIS */
img { max-width: 100%; }
.logo img { display: block; max-height: 60px; max-width: 260px; }
.search { display: flex; gap: 6px; }
.side-news.no-image { grid-template-columns: 1fr; }
.side-news a, .news-card a, .trending-item a { display: block; }
.empty { padding: 40px 20px; background: var(--light); text-align: center; line-height: 1.7; }
.notice { background: #eef7ee; border-left: 4px solid #2b8a3e; padding: 12px 16px; margin: 16px 0; font-size: 14px; }
.article { min-width: 0; }
.article h1 { font-size: 32px; line-height: 1.25; margin: 6px 0 12px; }
.article figure { margin: 18px 0; }
.article figure img { width: 100%; }
.article figcaption { font-size: 12px; color: var(--gray); margin-top: 6px; }
.article-body { font-size: 17px; line-height: 1.8; margin-top: 18px; overflow-wrap: anywhere; }
.article-body p, .article-body ul, .article-body ol, .article-body blockquote { margin-bottom: 16px; }
.article-body h2, .article-body h3 { margin: 24px 0 10px; line-height: 1.35; }
.article-body ul, .article-body ol { padding-left: 24px; }
.article-body blockquote { border-left: 4px solid var(--yellow); padding-left: 16px; color: #555; }
.article-body a { color: var(--blue); text-decoration: underline; }
.article-body img { height: auto; }
.pager { display: flex; justify-content: space-between; margin: 24px 0; font-weight: bold; color: var(--blue); }
.channel-link { display: block; padding: 10px 0; border-bottom: 1px solid #eee; font-size: 13px; }
.hp { position: absolute; left: -9999px; }
.main-layout > * { min-width: 0; }
@media(max-width: 800px) { .article h1 { font-size: 25px; } }
.header-main { padding-left: 20px; padding-right: 20px; }
@media(max-width: 500px) { .header-main { padding-left: 14px; padding-right: 14px; } }
