/*
Theme Name: Berita Simpel
Theme URI: https://example.com/berita-simpel
Author: OpenAI
Description: Tema WordPress portal berita modern dengan alur editorial sederhana, headline, breaking news, trending, kategori, dan tampilan feed responsif.
Version: 2.4.0
Requires at least: 6.6
Tested up to: 7.1
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: berita-simpel
Tags: news, blog, two-columns, right-sidebar, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready
*/

:root {
  --bs-primary: #1478c8;
  --bs-primary-dark: #0e5f9e;
  --bs-ink: #17191c;
  --bs-muted: #737982;
  --bs-line: #e7e9ec;
  --bs-soft: #f5f6f7;
  --bs-card: #ffffff;
  --bs-white: #ffffff;
  --bs-danger: #e53935;
  --bs-max: 1160px;
  --bs-radius: 6px;
  --bs-radius-sm: 4px;
  --bs-shadow: 0 1px 5px rgba(24, 35, 48, .045);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--bs-ink);
  background: var(--bs-soft);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
a:hover { color: var(--bs-primary); }
img { max-width: 100%; height: auto; display: block; }
button, input, textarea, select { font: inherit; }
.container { width: min(calc(100% - 32px), var(--bs-max)); margin: 0 auto; }
.screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  width: 1px;
  word-wrap: normal !important;
}
.screen-reader-text:focus {
  clip: auto !important;
  clip-path: none;
  display: block;
  height: auto;
  left: 8px;
  top: 8px;
  width: auto;
  z-index: 99999;
  background: #fff;
  padding: 8px 12px;
  border-radius: 6px;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #fff;
  box-shadow: 0 1px 0 rgba(0, 0, 0, .06);
}
.admin-bar .site-header { top: 32px; }
.brand-shell { background: #fff; }
.brand-row {
  min-height: 74px;
  display: grid;
  grid-template-columns: minmax(190px, 1fr) minmax(280px, 520px) minmax(130px, 1fr);
  gap: 24px;
  align-items: center;
}
.site-branding { min-width: 0; }
.custom-logo { max-height: 48px; width: auto; }
.site-title { margin: 0; font-size: 28px; line-height: 1; font-weight: 850; letter-spacing: -.8px; }
.site-title a { color: var(--bs-primary); }
.site-description { margin: 5px 0 0; color: var(--bs-muted); font-size: 12px; }
.header-search { min-width: 0; }
.search-form {
  display: flex;
  width: 100%;
  position: relative;
}
.search-form label { width: 100%; }
.search-field {
  width: 100%;
  height: 42px;
  border: 1px solid #dfe3e7;
  border-radius: 999px;
  background: #f7f8f9;
  padding: 0 48px 0 16px;
  outline: none;
  transition: .2s ease;
}
.search-field:focus {
  background: #fff;
  border-color: #b9d8ee;
  box-shadow: 0 0 0 3px rgba(20, 120, 200, .08);
}
.search-submit {
  position: absolute;
  right: 4px;
  top: 4px;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  font-size: 15px;
}
.header-actions { display: flex; align-items: center; justify-content: flex-end; }
.write-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  border: 1px solid var(--bs-primary);
  color: var(--bs-primary);
  border-radius: 999px;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 750;
}
.write-button:hover { background: var(--bs-primary); color: #fff; }

.nav-wrap {
  background: #fff;
  border-top: 1px solid #f2f2f2;
  border-bottom: 1px solid #e9e9e9;
}
.nav-inner { min-height: 46px; display: flex; align-items: center; }
.main-navigation { flex: 1; min-width: 0; overflow: hidden; }
.main-navigation ul {
  list-style: none;
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0;
  margin: 0;
  padding: 0;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.main-navigation ul::-webkit-scrollbar { display: none; }
.main-navigation li { flex: 0 0 auto; position: relative; }
.main-navigation a {
  display: block;
  padding: 11px 10px;
  font-size: 15px;
  line-height: 1.35;
  font-weight: 750;
  color: #111;
  white-space: nowrap;
}
.main-navigation a:hover,
.main-navigation .current-menu-item > a,
.main-navigation .current-menu-ancestor > a,
.main-navigation .current_page_item > a,
.main-navigation .current-post-ancestor > a { color: var(--bs-primary); }
.main-navigation ul ul { display: none; }

.breaking {
  background: #fff;
  border-bottom: 1px solid var(--bs-line);
}
.breaking-inner {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 12px;
  overflow: hidden;
}
.breaking-label {
  flex: 0 0 auto;
  background: #fff0ef;
  color: var(--bs-danger);
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 11px;
  line-height: 1.4;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: .35px;
}
.breaking-link {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 700;
}
.breaking-time { flex: 0 0 auto; color: var(--bs-muted); font-size: 11px; }

/* Shared media elements */
.site-main { padding: 20px 0 42px; }
.media-card {
  background: var(--bs-card);
  border: 1px solid var(--bs-line);
  border-radius: var(--bs-radius);
  box-shadow: var(--bs-shadow);
}
.category-badge {
  display: inline-block;
  color: var(--bs-primary);
  background: transparent;
  font-size: 12px;
  line-height: 1.2;
  font-weight: 800;
}
.category-badge:hover { color: var(--bs-primary-dark); }
.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 5px 7px;
  align-items: center;
  color: var(--bs-muted);
  font-size: 12px;
  line-height: 1.4;
}
.image-placeholder {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 110px;
  background: linear-gradient(135deg, #eff2f4, #e3e7eb);
}
.eyebrow {
  display: inline-block;
  margin-bottom: 3px;
  color: var(--bs-primary);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: .7px;
  text-transform: uppercase;
}
.section-heading-row {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 18px;
  margin-bottom: 14px;
}
.section-title { margin: 0; font-size: 23px; line-height: 1.25; letter-spacing: -.25px; }
.section-title.clean-title::before,
.section-title.clean-title::after { display: none; }
.section-link { color: var(--bs-primary); font-size: 13px; font-weight: 750; white-space: nowrap; }

/* Homepage feature */
.home-feature {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(300px, .75fr);
  gap: 12px;
  margin-bottom: 18px;
}
.lead-story { overflow: hidden; }
.lead-story-image {
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #edf0f2;
}
.lead-story-image img { width: 100%; height: 100%; object-fit: cover; }
.lead-story-body { padding: 14px 16px 16px; }
.lead-story-body h2 {
  margin: 6px 0 8px;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.18;
  letter-spacing: -.5px;
}
.lead-story-body p { margin: 0 0 12px; color: #555d66; font-size: 14px; }
.feature-side { display: flex; flex-direction: column; gap: 8px; }
.side-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 28px;
  padding: 0 4px;
  font-size: 14px;
  font-weight: 800;
}
.side-heading span::after {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-left: 7px;
  vertical-align: middle;
  border-radius: 50%;
  background: var(--bs-primary);
}
.feature-mini {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 10px;
  padding: 10px;
}
.feature-mini-image {
  aspect-ratio: 1.2 / 1;
  overflow: hidden;
  border-radius: 4px;
  background: #edf0f2;
}
.feature-mini-image img { width: 100%; height: 100%; object-fit: cover; }
.feature-mini h3 { margin: 4px 0 8px; font-size: 16px; line-height: 1.35; }

/* Feed and sidebar */
.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 16px;
  align-items: start;
}
.home-content-grid { margin-top: 2px; }
.feed-list { display: grid; gap: 8px; }
.list-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 14px;
  padding: 12px;
  overflow: hidden;
}
.list-card-body { min-width: 0; }
.list-card h2 {
  margin: 5px 0 8px;
  font-size: 20px;
  line-height: 1.35;
  letter-spacing: -.18px;
}
.list-card p {
  margin: 0 0 12px;
  color: #5d646c;
  font-size: 13px;
  line-height: 1.55;
}
.list-card .news-thumb {
  display: block;
  align-self: stretch;
  aspect-ratio: 16 / 10;
  border-radius: 4px;
  overflow: hidden;
  background: #edf0f2;
}
.list-card .news-thumb img { width: 100%; height: 100%; object-fit: cover; }

.sidebar {
  position: sticky;
  top: 140px;
  display: grid;
  gap: 10px;
}
.widget {
  background: #fff;
  border: 1px solid var(--bs-line);
  border-radius: var(--bs-radius);
  padding: 14px;
  box-shadow: var(--bs-shadow);
}
.widget-title {
  margin: 0 0 13px;
  padding: 0;
  color: var(--bs-ink);
  background: transparent;
  font-size: 17px;
  line-height: 1.2;
  font-weight: 800;
  text-transform: none;
  letter-spacing: 0;
}
.widget-heading-row { display: flex; align-items: center; gap: 8px; }
.widget-heading-row .widget-title { margin-bottom: 12px; }
.live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--bs-danger); transform: translateY(-5px); }
.trending-list { display: grid; }
.trending-item {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 11px;
  padding: 13px 0;
  border-top: 1px solid var(--bs-line);
}
.trending-item:first-child { border-top: 0; padding-top: 3px; }
.trending-rank {
  color: var(--bs-primary);
  font-size: 24px;
  line-height: 1;
  font-weight: 850;
}
.trending-item h3 { margin: 0 0 7px; font-size: 14px; line-height: 1.4; }
.widget-note { margin: 0; color: var(--bs-muted); font-size: 13px; }
.widget ul { list-style: none; padding: 0; margin: 0; }
.widget li { padding: 8px 0; border-bottom: 1px solid var(--bs-line); font-size: 13px; }
.widget li:last-child { border-bottom: 0; }
.tag-cloud-wrap { display: flex; flex-wrap: wrap; gap: 7px; }
.tag-cloud-wrap a {
  display: inline-flex;
  align-items: center;
  background: #f3f6f8;
  border: 1px solid #e7ebee;
  border-radius: 999px;
  padding: 6px 10px;
  color: #4f5963;
  font-weight: 650;
}

/* Category showcase */
.category-showcase { margin-top: 24px; display: grid; gap: 20px; }
.category-block { padding-top: 24px; border-top: 1px solid #dde1e5; }
.compact-heading { align-items: center; }
.category-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.news-card { overflow: hidden; }
.news-card .news-thumb {
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #edf0f2;
}
.news-card .news-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .22s ease; }
.news-card:hover .news-thumb img { transform: scale(1.02); }
.news-card-body { padding: 13px 14px 14px; }
.news-card h2 { margin: 5px 0 9px; font-size: 15px; line-height: 1.42; }

/* Archive/search */
.archive-column { min-width: 0; }
.page-header { padding: 20px; margin-bottom: 14px; }
.page-title { margin: 2px 0 0; font-size: 30px; line-height: 1.2; letter-spacing: -.45px; }
.archive-description { margin-top: 7px; color: var(--bs-muted); font-size: 14px; }
.archive-description p { margin: 0; }
.navigation.pagination { margin-top: 20px; }
.nav-links { display: flex; flex-wrap: wrap; gap: 6px; }
.page-numbers {
  min-width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--bs-line);
  border-radius: 5px;
  background: #fff;
  font-size: 13px;
}
.page-numbers.current { color: #fff; background: var(--bs-primary); border-color: var(--bs-primary); }

/* Article */
.article-layout { grid-template-columns: minmax(0, 1fr) 330px; }
.single-article { min-width: 0; }
.article-card {
  background: #fff;
  border: 1px solid var(--bs-line);
  border-radius: var(--bs-radius);
  box-shadow: var(--bs-shadow);
  padding: 28px;
}
.entry-header { margin-bottom: 20px; }
.article-breadcrumb { display: flex; flex-wrap: wrap; gap: 7px; align-items: center; color: var(--bs-muted); font-size: 12px; }
.article-breadcrumb .category-badge { font-size: 12px; }
.entry-title {
  margin: 11px 0 10px;
  font-size: clamp(31px, 5vw, 46px);
  line-height: 1.12;
  letter-spacing: -.75px;
}
.article-summary {
  margin: 0 0 16px;
  color: #59616a;
  font-size: 17px;
  line-height: 1.55;
}
.author-row { display: flex; gap: 11px; align-items: center; padding-top: 7px; }
.author-avatar img { width: 44px; height: 44px; border-radius: 50%; }
.author-info { min-width: 0; }
.author-info strong { display: block; margin-bottom: 3px; font-size: 14px; }
.entry-thumbnail { margin: 0 0 24px; }
.entry-thumbnail img { width: 100%; border-radius: 10px; }
.entry-thumbnail figcaption { margin-top: 8px; color: var(--bs-muted); font-size: 12px; line-height: 1.5; }
.entry-thumbnail figcaption span::before { content: " - "; }
.article-body-wrap { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 18px; }
.share-rail { position: sticky; top: 150px; align-self: start; display: grid; gap: 8px; }
.share-label { color: var(--bs-muted); font-size: 10px; text-transform: uppercase; text-align: center; font-weight: 750; }
.share-rail a {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--bs-line);
  border-radius: 50%;
  background: #fff;
  font-size: 12px;
  font-weight: 800;
}
.share-rail a:hover { border-color: #b8d8ef; color: var(--bs-primary); }
.entry-content {
  min-width: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
  line-height: 1.83;
  color: #22282f;
}
.entry-content p { margin: 0 0 1.35em; }
.entry-content h2,
.entry-content h3,
.entry-content h4 {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.3;
  margin: 1.55em 0 .65em;
}
.entry-content h2 { font-size: 27px; }
.entry-content h3 { font-size: 22px; }
.entry-content a { color: var(--bs-primary); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; }
.entry-content blockquote {
  margin: 1.5em 0;
  padding: 4px 0 4px 20px;
  border-left: 4px solid var(--bs-primary);
  color: #4b545e;
  font-size: 1.04em;
}
.entry-content img { border-radius: 8px; }
.article-dateline { display: inline; }
.article-dateline + p { display: inline; }
.article-dateline + p::after { content: ""; display: block; margin-bottom: 1.35em; }
.post-tags {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid var(--bs-line);
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  align-items: center;
  font-size: 13px;
}
.post-tags a { display: inline-flex; border: 1px solid #e1e6ea; background: #f6f8f9; border-radius: 999px; padding: 5px 10px; }
.related-section { margin-top: 22px; }
.related-section > .section-title { margin-bottom: 13px; }
.related-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.related-grid .news-card h2 { font-size: 14px; }

/* Ads */
.ad-slot {
  margin: 18px 0 0;
  min-height: 88px;
  border: 1px dashed #d5d9dc;
  border-radius: 6px;
  background: rgba(255, 255, 255, .6);
  padding: 10px;
  text-align: center;
}
.ad-label { display: block; margin-bottom: 6px; color: #9aa0a6; font-size: 9px; letter-spacing: .5px; text-transform: uppercase; }
.ad-widget { margin: 0; }
.article-ad { margin-top: 24px; }

/* Comments */
.comments-area {
  margin-top: 22px;
  background: #fff;
  border: 1px solid var(--bs-line);
  border-radius: var(--bs-radius);
  padding: 22px;
  box-shadow: var(--bs-shadow);
}
.comments-title { margin-top: 0; }
.comment-list { list-style: none; padding: 0; }
.comment-list li { margin: 18px 0; }
.comment-body { padding: 14px; background: #f7f8f9; border-radius: 10px; }
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
  width: 100%;
  border: 1px solid #d8dde1;
  border-radius: 5px;
  padding: 10px 12px;
  background: #fff;
}
.comment-form .submit {
  border: 0;
  background: var(--bs-primary);
  color: #fff;
  padding: 10px 17px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 700;
}

/* Compact Footer */
.site-footer {
  background: #15191d;
  color: #aeb6bc;
  border-top: 1px solid #262c31;
}
.footer-bottom {
  padding: 11px 0;
}
.footer-bottom-inner {
  min-height: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  font-size: 12px;
  line-height: 1.4;
  color: #929ba2;
}
.site-footer a {
  color: #dfe4e7;
}
.site-footer a:hover {
  color: #fff;
}
.footer-mini-nav .menu {
  display: flex;
  align-items: center;
  gap: 14px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.footer-mini-nav .menu li {
  margin: 0;
  padding: 0;
}
.footer-mini-nav .menu a {
  font-size: 12px;
}

/* Utility and empty */
.empty-state {
  padding: 34px;
  background: #fff;
  border: 1px solid var(--bs-line);
  border-radius: var(--bs-radius);
  text-align: center;
  box-shadow: var(--bs-shadow);
}
.empty-state h2, .empty-state h1 { margin-top: 0; }
.alignwide { max-width: 1100px; margin-left: auto; margin-right: auto; }
.alignfull { width: 100vw; margin-left: calc(50% - 50vw); }
.wp-caption, .gallery-caption { color: var(--bs-muted); font-size: 12px; }
.sticky { outline: 2px solid rgba(20, 120, 200, .08); }
.bypostauthor { box-shadow: inset 3px 0 var(--bs-primary); }

@media (max-width: 1020px) {
  .brand-row { grid-template-columns: minmax(160px, .7fr) minmax(260px, 1.4fr) auto; }
  .content-grid, .article-layout { grid-template-columns: minmax(0, 1fr) 300px; }
  .home-feature { grid-template-columns: minmax(0, 1.3fr) minmax(280px, .8fr); }
  .category-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 860px) {
  .site-header { position: relative; }
  .admin-bar .site-header { top: 0; }
  .brand-row { grid-template-columns: 1fr auto; min-height: 66px; gap: 16px; }
  .header-search { grid-column: 1 / -1; grid-row: 2; padding-bottom: 12px; }
  .header-actions { grid-column: 2; grid-row: 1; }
  .site-description { display: none; }
  .home-feature { grid-template-columns: 1fr; }
  .feature-side { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .side-heading { grid-column: 1 / -1; }
  .content-grid, .article-layout { grid-template-columns: 1fr; }
  .sidebar { position: static; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article-card { padding: 24px; }
}

@media (max-width: 640px) {
  .container { width: min(calc(100% - 20px), var(--bs-max)); }
  .site-main { padding-top: 18px; }
  .brand-row { min-height: 58px; }
  .site-title { font-size: 24px; }
  .custom-logo { max-height: 40px; }
  .write-button { min-height: 34px; padding: 5px 11px; font-size: 12px; }
  .header-search { padding-bottom: 9px; }
  .search-field { height: 39px; }
  .nav-inner { min-height: 43px; }
  .main-navigation a { padding: 10px 9px; font-size: 15px; }
  .breaking-inner { min-height: 39px; gap: 8px; }
  .breaking-label { font-size: 10px; padding: 4px 8px; }
  .breaking-time { display: none; }

  .lead-story-body { padding: 15px; }
  .lead-story-body h2 { font-size: 25px; }
  .feature-side { grid-template-columns: 1fr; }
  .side-heading { grid-column: auto; }
  .feature-mini { grid-template-columns: 108px 1fr; }

  .section-title { font-size: 21px; }
  .list-card { grid-template-columns: minmax(0, 1fr) 118px; gap: 12px; padding: 13px; }
  .list-card h2 { font-size: 17px; margin-bottom: 8px; }
  .list-card p { display: none; }
  .list-card .news-thumb { aspect-ratio: 1 / 1; }
  .post-meta { font-size: 11px; }

  .sidebar { grid-template-columns: 1fr; }
  .category-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .news-card-body { padding: 11px; }
  .news-card h2 { font-size: 14px; }
  .news-card .post-meta span:nth-child(n+2) { display: none; }

  .article-card { padding: 18px 15px; border-radius: 10px; }
  .entry-title { font-size: 31px; }
  .article-summary { font-size: 16px; }
  .article-body-wrap { grid-template-columns: 1fr; gap: 12px; }
  .share-rail { position: static; display: flex; align-items: center; }
  .share-label { margin-right: 3px; }
  .share-rail a { width: 34px; height: 34px; }
  .entry-content { font-size: 17px; line-height: 1.76; }
  .related-grid { grid-template-columns: 1fr; }
  .related-grid .news-card { display: grid; grid-template-columns: 120px 1fr; }
  .related-grid .news-card .news-thumb { aspect-ratio: 1 / 1; }
  .related-grid .news-card .post-meta { display: none; }

  .footer-bottom-inner { display: flex; flex-direction: column; align-items: flex-start; gap: 5px; }
  .footer-bottom-inner span { display: block; margin: 0; }
  .footer-mini-nav .menu { gap: 10px; flex-wrap: wrap; }
}

@media (max-width: 420px) {
  .category-grid { grid-template-columns: 1fr; }
  .feature-mini { grid-template-columns: 100px 1fr; }
  .list-card { grid-template-columns: minmax(0, 1fr) 104px; }
  .list-card h2 { font-size: 16px; }
  .entry-title { font-size: 28px; }
}

/* =========================================================
   Header v3 - modern two-row news navigation
   Inspired by contemporary Indonesian media layouts without
   copying a third-party brand or logo.
   ========================================================= */
:root {
  --header-accent: #008b8d;
  --header-accent-dark: #006f71;
  --header-ink: #555b60;
  --header-line: #eceff1;
}

.modern-news-header.site-header {
  background: #fff;
  box-shadow: 0 1px 0 rgba(17, 24, 39, .08);
}
.modern-news-header .brand-shell {
  background: #fff;
  border-bottom: 1px solid #f1f2f3;
}
.modern-news-header .brand-row {
  min-height: 60px;
  display: grid;
  grid-template-columns: minmax(170px, 190px) minmax(280px, 1fr) auto;
  gap: 18px;
  align-items: center;
}
.modern-news-header .site-branding {
  display: flex;
  align-items: center;
  min-width: 0;
}
.modern-news-header .custom-logo-link {
  display: inline-flex;
  align-items: center;
  max-width: 185px;
}
.modern-news-header .custom-logo {
  max-width: 185px;
  max-height: 46px;
  width: auto;
  object-fit: contain;
}
.modern-news-header .brand-text-wrap {
  min-width: 0;
}
.modern-news-header .site-title {
  font-size: 27px;
  font-weight: 850;
  line-height: .95;
  letter-spacing: -1px;
}
.modern-news-header .site-title a {
  color: var(--header-accent);
}
.modern-news-header .site-description {
  margin: 4px 0 0;
  color: #6c7379;
  font-size: 10px;
  line-height: 1.2;
  white-space: nowrap;
}
.modern-news-header .header-search {
  min-width: 0;
  max-width: 440px;
  width: 100%;
}
.modern-news-header .search-form {
  position: relative;
  display: block;
  width: 100%;
}
.modern-news-header .search-form label {
  position: relative;
  display: block;
  width: 100%;
}
.modern-news-header .search-field {
  width: 100%;
  height: 36px;
  border: 1px solid #aeb3b7;
  border-radius: 999px;
  background: #fafafa;
  color: #33383d;
  padding: 0 16px 0 48px;
  outline: 0;
  font-size: 14px;
  transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
}
.modern-news-header .search-field::placeholder {
  color: #6c7074;
  opacity: 1;
}
.modern-news-header .search-field:focus {
  background: #fff;
  border-color: var(--header-accent);
  box-shadow: 0 0 0 3px rgba(0, 139, 141, .10);
}
.modern-news-header .search-icon {
  position: absolute;
  z-index: 2;
  left: 15px;
  top: 50%;
  width: 18px;
  height: 18px;
  transform: translateY(-50%);
  color: #63686d;
  pointer-events: none;
}
.modern-news-header .search-icon svg {
  width: 100%;
  height: 100%;
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}
.modern-news-header .search-submit {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  clip: rect(0, 0, 0, 0);
  overflow: hidden;
  border: 0;
}
.modern-news-header .search-submit:focus {
  clip: auto;
  width: auto;
  height: 30px;
  margin: 0;
  right: 3px;
  top: 3px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--header-accent);
  color: #fff;
  z-index: 3;
}

.modern-news-header .header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 9px;
  white-space: nowrap;
}
.header-icon-button,
.nav-more-toggle {
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  background: transparent;
  cursor: pointer;
}
.header-icon-button {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: #60666b;
  transition: background .16s ease, color .16s ease;
}
.header-icon-button:hover,
.header-icon-button:focus-visible,
.header-icon-button.is-active,
.header-popover.is-open > .header-icon-button {
  color: var(--header-accent);
  background: #edf8f8;
  outline: 0;
}
.header-icon-button svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.65;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.theme-toggle .sun-icon { display: none; }
html.berita-dark .theme-toggle .moon-icon { display: none; }
html.berita-dark .theme-toggle .sun-icon { display: block; }

.modern-news-header .login-button,
.modern-news-header .write-button {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 3px;
  padding: 5px 12px;
  font-size: 12px;
  line-height: 1;
  font-weight: 800;
  transition: background .16s ease, border-color .16s ease, color .16s ease;
}
.modern-news-header .login-button {
  background: var(--header-accent);
  border: 1px solid var(--header-accent);
  color: #fff;
}
.modern-news-header .login-button:hover,
.modern-news-header .login-button:focus-visible {
  background: var(--header-accent-dark);
  border-color: var(--header-accent-dark);
  color: #fff;
}
.modern-news-header .write-button {
  background: var(--header-accent);
  border: 1px solid var(--header-accent);
  color: #fff;
}
.modern-news-header .write-button:hover,
.modern-news-header .write-button:focus-visible {
  background: var(--header-accent-dark);
  border-color: var(--header-accent-dark);
  color: #fff;
}

.modern-news-header .nav-wrap {
  background: #fff;
  border-top: 0;
  border-bottom: 1px solid #e7e9eb;
}
.modern-news-header .nav-inner {
  min-height: 40px;
  display: flex;
  align-items: stretch;
  gap: 4px;
}
.modern-news-header .main-navigation {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
}
.modern-news-header .main-navigation ul {
  height: 40px;
  display: flex;
  align-items: center;
  gap: 0;
}
.modern-news-header .main-navigation a {
  position: relative;
  display: flex;
  align-items: center;
  height: 40px;
  padding: 0 12px;
  color: #555b60;
  font-size: 14px;
  font-weight: 800;
}
.modern-news-header .main-navigation a:hover,
.modern-news-header .main-navigation .current-menu-item > a,
.modern-news-header .main-navigation .current-menu-ancestor > a,
.modern-news-header .main-navigation .current_page_item > a,
.modern-news-header .main-navigation .current-post-ancestor > a {
  color: var(--header-accent);
}
.modern-news-header .main-navigation .current-menu-item > a::after,
.modern-news-header .main-navigation .current-menu-ancestor > a::after,
.modern-news-header .main-navigation .current_page_item > a::after,
.modern-news-header .main-navigation .current-post-ancestor > a::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 0;
  height: 2px;
  background: var(--header-accent);
  border-radius: 2px 2px 0 0;
}

.header-popover {
  position: relative;
}
.header-popover-panel {
  position: absolute;
  z-index: 1200;
  top: calc(100% + 10px);
  right: 0;
  width: 330px;
  max-width: calc(100vw - 24px);
  border: 1px solid #e1e4e6;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 14px 38px rgba(25, 35, 45, .14);
  overflow: hidden;
}
.header-popover-panel[hidden] { display: none !important; }
.popover-heading {
  padding: 12px 14px;
  border-bottom: 1px solid #edf0f1;
  color: #343a3f;
  font-size: 13px;
  font-weight: 850;
}
.notification-list { display: grid; }
.notification-item {
  display: grid;
  gap: 3px;
  padding: 10px 14px;
  border-bottom: 1px solid #f0f2f3;
}
.notification-item:last-child { border-bottom: 0; }
.notification-item:hover { background: #f7fbfb; }
.notification-title {
  color: #30363b;
  font-size: 13px;
  line-height: 1.35;
  font-weight: 700;
}
.notification-time,
.notification-empty {
  color: #8a9095;
  font-size: 11px;
}
.notification-empty { margin: 0; padding: 15px; }

.more-popover {
  flex: 0 0 auto;
  display: flex;
  align-items: stretch;
}
.nav-more-toggle {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  min-height: 40px;
  padding: 0 2px 0 9px;
  color: #555b60;
  font-size: 14px;
  font-weight: 800;
}
.nav-more-toggle:hover,
.nav-more-toggle:focus-visible,
.more-popover.is-open .nav-more-toggle {
  color: var(--header-accent);
  outline: 0;
}
.nav-more-toggle svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}
.more-panel {
  top: calc(100% + 1px);
  width: 390px;
}
.more-category-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  padding: 6px;
}
.more-category-grid a {
  padding: 9px 10px;
  border-radius: 6px;
  color: #4e555a;
  font-size: 13px;
  font-weight: 700;
}
.more-category-grid a:hover { background: #f1f8f8; color: var(--header-accent); }

/* Header-scale responsive behavior */
@media (max-width: 1040px) {
  .modern-news-header .brand-row {
    grid-template-columns: minmax(145px, 170px) minmax(230px, 1fr) auto;
    gap: 12px;
  }
  .modern-news-header .header-search { max-width: 380px; }
  .modern-news-header .header-actions { gap: 5px; }
  .modern-news-header .login-button,
  .modern-news-header .write-button { padding-left: 9px; padding-right: 9px; }
}

@media (max-width: 860px) {
  .modern-news-header.site-header { position: sticky; top: 0; }
  .admin-bar .modern-news-header.site-header { top: 46px; }
  .modern-news-header .brand-row {
    min-height: 58px;
    grid-template-columns: minmax(130px, 1fr) auto;
    gap: 10px;
    padding-top: 6px;
    padding-bottom: 6px;
  }
  .modern-news-header .header-search {
    grid-column: 1 / -1;
    grid-row: 2;
    max-width: none;
    padding-bottom: 0;
  }
  .modern-news-header .header-actions {
    grid-column: 2;
    grid-row: 1;
  }
  .modern-news-header .site-description { display: none; }
  .modern-news-header .home-icon-button { display: none; }
  .modern-news-header .nav-inner { min-height: 40px; }
  .modern-news-header .main-navigation a { padding-left: 10px; padding-right: 10px; }
}

@media (max-width: 640px) {
  .modern-news-header .brand-row {
    grid-template-columns: minmax(100px, 1fr) auto;
    min-height: 52px;
  }
  .modern-news-header .site-title { font-size: 23px; }
  .modern-news-header .custom-logo { max-height: 36px; max-width: 145px; }
  .modern-news-header .header-actions { gap: 2px; }
  .header-icon-button { width: 33px; height: 33px; }
  .header-icon-button svg { width: 20px; height: 20px; }
  .modern-news-header .login-button { display: none; }
  .modern-news-header .write-button {
    min-height: 29px;
    padding: 5px 8px;
    font-size: 11px;
  }
  .modern-news-header .search-field { height: 35px; }
  .modern-news-header .main-navigation a { font-size: 13px; padding: 0 9px; }
  .nav-more-toggle { font-size: 13px; padding-left: 6px; }
  .header-popover-panel { right: -7px; }
  .notification-panel { width: 300px; }
  .more-panel { width: 320px; }
}

/* Dark mode, toggled by the header moon button */
html.berita-dark {
  --bs-ink: #e8ecef;
  --bs-muted: #a9b0b6;
  --bs-line: #2f363c;
  --bs-soft: #161a1e;
  --bs-card: #20252a;
  --bs-white: #20252a;
}
html.berita-dark body { background: #161a1e; color: #e8ecef; }
html.berita-dark .modern-news-header.site-header,
html.berita-dark .modern-news-header .brand-shell,
html.berita-dark .modern-news-header .nav-wrap,
html.berita-dark .breaking,
html.berita-dark .widget,
html.berita-dark .article-card,
html.berita-dark .news-card,
html.berita-dark .lead-story,
html.berita-dark .feature-mini,
html.berita-dark .list-card,
html.berita-dark .empty-state,
html.berita-dark .header-popover-panel {
  background: #20252a;
  color: #e8ecef;
  border-color: #30373d;
}
html.berita-dark .modern-news-header .brand-shell { border-bottom-color: #2d343a; }
html.berita-dark .modern-news-header .nav-wrap { border-bottom-color: #30373d; }
html.berita-dark .modern-news-header .site-description,
html.berita-dark .modern-news-header .main-navigation a,
html.berita-dark .nav-more-toggle,
html.berita-dark .header-icon-button { color: #c0c6cb; }
html.berita-dark .modern-news-header .main-navigation a:hover,
html.berita-dark .modern-news-header .main-navigation .current-menu-item > a,
html.berita-dark .nav-more-toggle:hover,
html.berita-dark .header-icon-button:hover { color: #3dc5c6; }
html.berita-dark .modern-news-header .search-field {
  background: #2a3035;
  border-color: #555d63;
  color: #f1f3f4;
}
html.berita-dark .modern-news-header .search-field::placeholder { color: #aeb5ba; }
html.berita-dark .popover-heading,
html.berita-dark .notification-title,
html.berita-dark .more-category-grid a { color: #e3e7ea; }
html.berita-dark .popover-heading,
html.berita-dark .notification-item { border-color: #30373d; }
html.berita-dark .notification-item:hover,
html.berita-dark .more-category-grid a:hover { background: #293237; }
html.berita-dark .entry-content,
html.berita-dark .list-card p,
html.berita-dark .news-card p,
html.berita-dark .archive-description { color: #c0c6cb; }

@media (min-width: 783px) and (max-width: 860px) {
  .admin-bar .modern-news-header.site-header { top: 32px; }
}
@media (max-width: 782px) {
  .admin-bar .modern-news-header.site-header { top: 46px; }
}
\n\n/* v2.2 compact layout refinements */\n.home-main .media-card,\n.home-main .widget,\n.archive-main .media-card {\n  border-radius: 6px;\n}\n.home-main .section-heading-row {\n  margin-bottom: 10px;\n}\n.home-main .lead-story-body {\n  padding: 14px 16px 15px;\n}\n.home-main .feature-mini {\n  padding: 10px;\n  gap: 10px;\n}\n.home-main .feature-mini-image,\n.home-main .list-card .news-thumb {\n  border-radius: 4px;\n}\n.home-main .content-grid {\n  gap: 16px;\n}\n.home-main .feed-list {\n  gap: 8px;\n}\n.home-main .list-card {\n  gap: 14px;\n  padding: 12px;\n}\n.home-main .sidebar {\n  gap: 10px;\n}\n.home-main .widget {\n  padding: 14px;\n}\n.home-main .category-showcase {\n  margin-top: 24px;\n  gap: 20px;\n}\n@media (max-width: 760px) {\n  .site-main { padding-top: 14px; }\n  .home-feature { gap: 10px; margin-bottom: 14px; }\n  .home-main .content-grid { gap: 12px; }\n  .home-main .list-card { padding: 10px; gap: 10px; }\n}\n