/* =================================================
   OPINIMATARAM.ID – WORDPRESS EDITORIAL THEME
   (MATCH DENGAN VERSI STATIS)
================================================= */

/* ================= ROOT ================= */
:root{
 --primary:#0b3c5d;
 --secondary:#38bdf8;
 --text:#0f172a;
 --gray:#475569;
 --bg:#f8fafc;
 --card:#ffffff;
}

/* ================= RESET ================= */
*{
 margin:0;
 padding:0;
 box-sizing:border-box;
}

body{
 background:var(--bg);
 color:var(--text);
 font-family:Arial,Helvetica,sans-serif;
}

a{
 text-decoration:none;
 color:inherit;
}

img{
 max-width:100%;
 height:auto;
 display:block;
}

/* ================= HEADER ================= */
.site-header{
 background:linear-gradient(180deg,#0b3c5d,#092f48);
 position:sticky;
 top:0;
 z-index:99;
}

.header-inner{
 max-width:1200px;
 margin:auto;
 padding:12px 16px;
}

.header-top{
 display:flex;
 justify-content:space-between;
 align-items:center;
}

.logo a{
 font-size:14px;
 font-weight:700;
 letter-spacing:.12em;
 color:#fff;
 font-family:Georgia,"Times New Roman",serif;
 text-transform:uppercase;
}

.hamburger{
 display:none;
 font-size:24px;
 color:#fff;
 background:none;
 border:0;
 cursor:pointer;
}

/* ================= NAV ================= */
#nav-menu{
 transition:.25s;
}

#nav-menu ul{
 display:flex;
 gap:16px;
 list-style:none;
 margin-top:8px;
}

#nav-menu a{
 font-size:13px;
 font-weight:600;
 color:#e5f0f9;
}

/* ================= CONTAINER ================= */
.container{
 max-width:1200px;
 margin:auto;
 padding:16px;
}

/* ================= HOMEPAGE GRID ================= */
.headline{
 display:grid;
 grid-template-columns:repeat(3,1fr);
 gap:18px;
}

/* ================= CARD ================= */
.card{
 background:var(--card);
 border-radius:14px;
 overflow:hidden;
 box-shadow:0 6px 18px rgba(0,0,0,.08);
 display:flex;
 flex-direction:column;
}

.card img{
 width:100%;
 aspect-ratio:16/9;
 object-fit:cover;
}

.card-body{
 padding:12px;
 display:flex;
 flex-direction:column;
 gap:6px;
}

.tag{
 background:var(--secondary);
 color:#fff;
 font-size:11px;
 padding:3px 9px;
 border-radius:20px;
 align-self:flex-start;
}

.card h2{
 font-size:16px;
 line-height:1.35;
 color:var(--primary);
}

.card h2 a{
 display:-webkit-box;
 -webkit-line-clamp:2;
 -webkit-box-orient:vertical;
 overflow:hidden;
}

.card p{
 font-size:13px;
 color:var(--gray);
 line-height:1.5;
}

/* ================= LOAD MORE ================= */
.load-more{
 text-align:center;
 margin:24px 0;
}

.load-more button{
 background:none;
 border:1px solid var(--primary);
 padding:10px 20px;
 border-radius:24px;
 font-size:14px;
 font-weight:600;
 color:var(--primary);
 cursor:pointer;
}

/* ================= FOOTER ================= */
.site-footer,
footer{
 margin-top:50px;
 background:#020617;
 color:#cbd5f5;
 padding:32px 16px;
}

footer p{
 font-size:12px;
 text-align:center;
}

/* ================= TABLET ================= */
@media(max-width:1024px){
 .headline{
   grid-template-columns:repeat(2,1fr);
 }
}

/* ================= MOBILE ================= */
@media (max-width:768px){

 .hamburger{
   display:block;
 }

 #nav-menu{
   display:none;
 }

 #nav-menu.show{
   display:block;
 }

 #nav-menu ul{
   flex-direction:column;
   background:#092f48;
   padding:10px;
   border-radius:10px;
 }

 #nav-menu li{
   padding:6px 0;
 }

 .container{
   padding:12px;
 }

 .headline{
   display:flex;
   flex-direction:column;
   gap:0;
 }

 /* headline utama */
 .card:first-child{
   background:transparent;
   box-shadow:none;
   margin-bottom:20px;
 }

 .card:first-child img{
   border-radius:18px;
 }

 .card:first-child .card-body{
   padding:12px 4px 0;
 }

 .card:first-child .tag{
   font-size:12px;
   font-weight:700;
   padding:4px 12px;
 }

 .card:first-child h2{
   font-size:20px;
   line-height:1.3;
   font-weight:700;
 }

 .card:first-child p{
   display:none;
 }

 /* list */
 .card:not(:first-child){
   display:grid;
   grid-template-columns:110px 1fr;
   gap:12px;
   padding:14px 0;
   border-top:1px solid #e5e7eb;
   background:transparent;
   box-shadow:none;
   border-radius:0;
 }

 .card:not(:first-child) img{
   aspect-ratio:1/1;
   border-radius:10px;
 }

 .card:not(:first-child) .card-body{
   padding:0;
 }

 .card:not(:first-child) h2{
   font-size:15px;
   line-height:1.35;
   font-weight:600;
 }

 .card:not(:first-child) p{
   display:-webkit-box;
   -webkit-line-clamp:2;
   -webkit-box-orient:vertical;
   overflow:hidden;
   font-size:13px;
   line-height:1.45;
   color:#475569;
   margin-top:4px;
 }

 .headline .card:nth-child(n+13){
   display:none;
 }

 .headline.show-all .card{
   display:grid;
 }
}

/* ================= DESKTOP LARGE ================= */
@media (min-width:1200px){

 .headline{
   grid-template-columns:2fr 1fr 1fr;
   gap:24px;
 }

 .headline > .card:first-child{
   grid-column:span 2;
   position:relative;
   border-radius:24px;
 }

 .headline > .card:first-child img{
   height:460px;
   filter:brightness(1.10) contrast(1.05) saturate(1.06);
 }

 .headline > .card:first-child::after{
   content:"";
   position:absolute;
   inset:0;
   background:linear-gradient(
     to top,
     rgba(0,0,0,.40) 0%,
     rgba(0,0,0,.20) 35%,
     rgba(0,0,0,.08) 60%,
     rgba(0,0,0,0) 80%
   );
 }

 .headline > .card:first-child .card-body{
   position:absolute;
   bottom:24px;
   left:24px;
   right:24px;
   background:none;
   padding:0;
 }

 .headline > .card:first-child h2{
   font-size:38px;
   font-weight:800;
 }

 .headline > .card:first-child h2 a{
   color:#fff;
   text-shadow:0 2px 8px rgba(0,0,0,.6);
 }

 .headline > .card:first-child p{
   font-size:16px;
   color:#e5e7eb;
   max-width:80%;
 }

 /* hover desktop */
 .headline > .card{
   transition:transform .25s ease, box-shadow .25s ease;
 }

 .headline > .card:hover{
   transform:translateY(-4px);
   box-shadow:0 14px 32px rgba(0,0,0,.12);
 }

 .headline > .card:first-child:hover{
   transform:none;
   box-shadow:none;
 }
}

/* FIX: HEADER TITLE PUTIH DI MOBILE */
@media (max-width:768px){
  .site-header .logo a{
    color:#ffffff !important;
  }
}

/* =================================================
   CATEGORY – DESKTOP ONLY
================================================= */
@media (min-width:769px){

  .archive-container{
    max-width: 900px;
    margin: auto;
    padding: 32px 16px 48px;
  }

  .archive-item{
    display: flex;
    gap: 18px;
    padding: 18px 0;
    border-bottom: 1px solid #e5e7eb;
  }

  .archive-thumb{
    flex: 0 0 120px;
  }

  .archive-thumb img{
    width: 120px;
    height: 88px;
    object-fit: cover;
    border-radius: 8px;
  }

  .archive-content{
    flex: 1;
  }

  .archive-title-post{
    font-size: 18px;
    line-height: 1.35;
    margin: 0 0 6px;
  }

  .archive-title-post a{
    font-weight: 700;
    color: var(--primary);
  }

  .archive-excerpt{
    font-size: 14px;
    line-height: 1.55;
    color: #374151;
  }

}
/* =================================================
   CATEGORY – MOBILE ONLY
================================================= */
@media (max-width:768px){

  .archive-container{
    padding: 20px 12px 32px;
  }

  .archive-item{
    display: flex;
    gap: 12px;
    padding: 14px 0;
    border-bottom: 1px solid #e5e7eb;
  }

  .archive-thumb{
    flex: 0 0 90px;
  }

  .archive-thumb img{
    width: 90px;
    height: 66px;
    object-fit: cover;
    border-radius: 6px;
  }

  .archive-title-post{
    font-size: 16px;
    line-height: 1.35;
    margin-bottom: 4px;
  }

  .archive-excerpt{
    font-size: 13px;
    line-height: 1.45;
    color: #475569;
  }

}

/* =================================================
   HEADER SEARCH – DESKTOP
================================================= */
@media (min-width:769px){

  .header-search{
    display:flex;
    align-items:center;
    gap:8px;
  }

  .header-search .search-field{
    height:34px;
    padding:0 14px;
    font-size:13px;
    border-radius:999px;
    border:1px solid rgba(255,255,255,.35);
    background:rgba(255,255,255,.15);
    color:#fff;
    outline:none;
    width:180px;
    transition:all .2s ease;
  }

  .header-search .search-field::placeholder{
    color:rgba(255,255,255,.75);
  }

  .header-search .search-field:focus{
    background:#fff;
    color:#0b3c5d;
    border-color:#fff;
  }

  .header-search button,
  .header-search .search-submit{
    height:34px;
    padding:0 14px;
    border-radius:999px;
    border:none;
    background:#38bdf8;
    color:#0b3c5d;
    font-size:13px;
    font-weight:700;
    cursor:pointer;
    transition:background .2s ease;
  }

  .header-search button:hover,
  .header-search .search-submit:hover{
    background:#7dd3fc;
  }
}
/* =================================================
   HEADER SEARCH – MOBILE
================================================= */
@media (max-width:768px){

  .header-search{
    display:flex;
    gap:8px;
    margin-top:10px;
    padding:6px 0;
  }

  .header-search .search-field{
    flex:1;
    height:36px;
    padding:0 14px;
    font-size:14px;
    border-radius:999px;
    border:1px solid rgba(255,255,255,.4);
    background:rgba(255,255,255,.18);
    color:#fff;
  }

  .header-search .search-field::placeholder{
    color:rgba(255,255,255,.85);
  }

  .header-search .search-submit{
    height:36px;
    padding:0 16px;
    border-radius:999px;
    border:none;
    background:#38bdf8;
    color:#0b3c5d;
    font-size:14px;
    font-weight:700;
  }
}

/* =================================================
   SINGLE ARTICLE – DESKTOP
================================================= */
@media (min-width:769px){

  /* Kontainer fokus baca */
  .single-container{
    max-width:760px;
    margin:auto;
    padding:32px 16px 56px;
  }

  /* Judul */
  .single-title{
    font-size:36px;
    line-height:1.25;
    font-weight:800;
    letter-spacing:-0.02em;
    color:var(--primary);
    margin-bottom:10px;
  }

  /* Meta */
  .single-meta{
    font-size:13px;
    color:#64748b;
  }

  /* Konten */
  .single-content{
    margin-top:28px;
    font-size:18px;
    line-height:1.9;
    color:#0f172a;
  }

  .single-content p{
    margin-bottom:1.6em;
    text-align:justify;
  }

  /* ===============================
     AJAKAN KATEGORI (PARAGRAF 3)
  ================================= */
  .mid-category-link{
    margin:36px 0;
    padding-left:16px;
    border-left:3px solid #cbd5e1;
    font-size:15px;
    line-height:1.7;
    color:#475569;
    font-style:italic;
  }

  .mid-category-link a{
    color:var(--primary);
    font-weight:700;
    text-decoration:none;
  }

  .mid-category-link a:hover{
    text-decoration:underline;
  }

  /* ===============================
     BACA JUGA (BAWAH ARTIKEL)
  ================================= */
  .related-posts{
    margin-top:56px;
    padding-top:28px;
    border-top:1px solid #e5e7eb;
  }

  .related-posts h3{
    font-size:18px;
    font-weight:800;
    margin-bottom:12px;
    color:var(--primary);
  }

  .related-posts ul{
    list-style:none;
    padding:0;
    margin:0;
  }

  .related-posts li{
    margin-bottom:8px;
  }

  .related-posts a{
    font-size:16px;
    font-weight:600;
    color:#1e293b;
    text-decoration:none;
  }

  .related-posts a:hover{
    color:var(--primary);
    text-decoration:underline;
  }
}

/* =================================================
   SINGLE ARTICLE – MOBILE
================================================= */
@media (max-width:768px){

  .single-container{
    padding:24px 14px 40px;
  }

  .single-title{
    font-size:26px;
    line-height:1.3;
    font-weight:800;
    margin-bottom:8px;
  }

  .single-meta{
    font-size:12.5px;
    color:#64748b;
  }

  .single-content{
    margin-top:22px;
    font-size:17px;
    line-height:1.75;
    color:#0f172a;
  }

  .single-content p{
    margin-bottom:1.5em;
    text-align:left; /* lebih nyaman di mobile */
  }

  /* ===============================
     AJAKAN KATEGORI (TENGAH)
  ================================= */
  .mid-category-link{
    margin:28px 0;
    padding-left:12px;
    border-left:3px solid #e5e7eb;
    font-size:14.5px;
    line-height:1.65;
    color:#64748b;
    font-style:italic;
  }

  .mid-category-link a{
    color:#0b3c5d;
    font-weight:700;
    text-decoration:none;
  }

  /* ===============================
     BACA JUGA
  ================================= */
  .related-posts{
    margin-top:40px;
    padding-top:20px;
    border-top:1px solid #e5e7eb;
  }

  .related-posts h3{
    font-size:16px;
    font-weight:800;
    margin-bottom:10px;
    color:#0b3c5d;
  }

  .related-posts a{
    font-size:15px;
    font-weight:600;
    color:#334155;
  }
}

/* =================================================
   SINGLE ARTICLE – DESKTOP POLISH
================================================= */
@media (min-width:769px){

  /* ===== Navigasi kecil (Beranda / Kategori) ===== */
  .single-nav{
    font-size:13px;
    margin-bottom:14px;
    color:#64748b;
  }

  .single-nav a{
    color:#0b3c5d;
    font-weight:600;
    text-decoration:none;
  }

  .single-nav a:hover{
    text-decoration:underline;
  }

  .single-nav-sep{
    margin:0 6px;
    color:#cbd5e1;
  }

  /* ===== Badge kategori (atas judul) ===== */
  .single-category a{
    display:inline-block;
    font-size:12px;
    font-weight:700;
    letter-spacing:.04em;
    text-transform:uppercase;
    color:#0b3c5d;
    background:#e0f2fe;
    padding:4px 12px;
    border-radius:999px;
    margin-bottom:10px;
    text-decoration:none;
  }

  .single-category a:hover{
    background:#bae6fd;
  }

  /* ===== Judul artikel ===== */
  .single-title{
    font-size:36px;
    line-height:1.25;
    font-weight:800;
    letter-spacing:-0.02em;
    margin-bottom:8px;
  }

  /* ===== Meta ===== */
  .single-meta{
    font-size:13px;
    color:#64748b;
  }
}
/* =================================================
   SINGLE ARTICLE – MOBILE POLISH
================================================= */
@media (max-width:768px){

  /* ===== Navigasi kecil ===== */
  .single-nav{
    font-size:12.5px;
    margin-bottom:10px;
    color:#64748b;
  }

  .single-nav a{
    color:#0b3c5d;
    font-weight:600;
    text-decoration:none;
  }

  .single-nav-sep{
    margin:0 5px;
    color:#cbd5e1;
  }

  /* ===== Badge kategori ===== */
  .single-category a{
    display:inline-block;
    font-size:11.5px;
    font-weight:700;
    letter-spacing:.04em;
    text-transform:uppercase;
    color:#0b3c5d;
    background:#e0f2fe;
    padding:4px 10px;
    border-radius:999px;
    margin-bottom:8px;
  }

  /* ===== Judul ===== */
  .single-title{
    font-size:26px;
    line-height:1.3;
    font-weight:800;
    margin-bottom:6px;
  }

  .single-meta{
    font-size:12px;
    color:#64748b;
  }
}

/* =================================================
   SINGLE TITLE – DESKTOP (ELEGANT EDITORIAL)
================================================= */
@media (min-width:769px){

  .single-title{
    font-size:34px;              /* sedikit turun dari 36 */
    line-height:1.28;            /* lebih bernafas */
    font-weight:800;
    letter-spacing:-0.018em;     /* rapat halus */
    color:#0b3c5d;
    margin-bottom:12px;
  }
}
/* =================================================
   SINGLE TITLE – DESKTOP (ELEGANT EDITORIAL)
================================================= */
@media (min-width:769px){

  .single-title{
    font-size:34px;              /* sedikit turun dari 36 */
    line-height:1.28;            /* lebih bernafas */
    font-weight:800;
    letter-spacing:-0.018em;     /* rapat halus */
    color:#0b3c5d;
    margin-bottom:12px;
  }
}

/* =================================================
   SINGLE TITLE – DESKTOP (HIGH EDITORIAL)
================================================= */
@media (min-width:769px){

  .single-title{
    font-family: Georgia, "Times New Roman", serif; /* rasa editorial */
    font-size:32px;            /* lebih tenang dari sebelumnya */
    line-height:1.35;          /* napas panjang */
    font-weight:700;           /* tidak terlalu tebal */
    letter-spacing:-0.01em;    /* rapat halus */
    color:#0b3c5d;
    max-width:720px;           /* cegah baris terlalu panjang */
    margin-bottom:14px;
  }
}

/* =================================================
   SINGLE TITLE – MOBILE (EDITORIAL CLEAN)
================================================= */
@media (max-width:768px){

  .single-title{
    font-family: Georgia, "Times New Roman", serif;
    font-size:24px;
    line-height:1.38;
    font-weight:700;
    letter-spacing:-0.005em;
    color:#0b3c5d;
    margin-bottom:12px;
  }
}

/* =================================================
   BACA JUGA – DESKTOP (EDITORIAL)
================================================= */
@media (min-width:769px){

  .related-posts{
    margin-top:56px;
    padding-top:28px;
    border-top:1px solid #e5e7eb;
  }

  /* Judul kecil editorial */
  .related-posts h3{
    font-family: Georgia, "Times New Roman", serif;
    font-size:16px;
    font-weight:700;
    letter-spacing:.08em;
    text-transform:uppercase;
    color:#64748b;
    margin-bottom:14px;
  }

  .related-posts ul{
    list-style:none;
    padding:0;
    margin:0;
  }

  .related-posts li{
    margin-bottom:10px;
  }

  /* Link artikel */
  .related-posts a{
    display:inline-block;
    font-size:17px;
    line-height:1.45;
    font-weight:600;
    color:#0b3c5d;
    text-decoration:none;
    transition:color .2s ease;
  }

  .related-posts a:hover{
    color:#0369a1;
    text-decoration:underline;
  }
}

/* =================================================
   BACA JUGA – MOBILE (CLEAN)
================================================= */
@media (max-width:768px){

  .related-posts{
    margin-top:40px;
    padding-top:20px;
    border-top:1px solid #e5e7eb;
  }

  .related-posts h3{
    font-size:14px;
    font-weight:700;
    letter-spacing:.06em;
    text-transform:uppercase;
    color:#64748b;
    margin-bottom:12px;
  }

  .related-posts li{
    margin-bottom:8px;
  }

  .related-posts a{
    font-size:15px;
    line-height:1.4;
    font-weight:600;
    color:#1e293b;
    text-decoration:none;
  }

  .related-posts a:hover{
    color:#0b3c5d;
    text-decoration:underline;
  }
}

/* =================================================
   FIX SEARCH MOBILE – SPACING & WIDTH
================================================= */
@media (max-width:768px){

  .header-search{
    margin-top:12px;
    padding-right:8px;
    padding-left:8px;
  }

  .header-search .search-field{
    width:100%;
    max-width:220px;   /* <<< INI KUNCINYA */
  }

  .header-search .search-submit{
    padding:0 14px;
    white-space:nowrap;
  }
}

/* =================================================
   FIX: DUPLICATE IMAGE IN SINGLE ARTICLE
   (DESKTOP & MOBILE – AMAN)
================================================= */

/* Sembunyikan gambar pertama di dalam konten
   karena sudah ditampilkan sebagai featured image */
.single-content > figure:first-child,
.single-content > p:first-child img{
  display:none;
}

.pagination {
  margin-top: 40px;
  display: flex;
  justify-content: center;
}

.pagination .page-numbers {
  padding: 8px 12px;
  margin: 0 4px;
  border: 1px solid #e5e7eb;
}

.pagination .current {
  background: #0b3c5d;
  color: #fff;
}

/* ===== HEADER DESKTOP ===== */
@media (min-width: 1024px) {

  .site-header,
  .header-inner {
    display: flex;
    align-items: center;
  }

  .site-branding {
    margin-right: 32px;
    flex-shrink: 0;
  }

  .main-navigation {
    margin-top: 0;
  }

  .main-navigation ul {
    display: flex;
    align-items: center;
    gap: 20px;
  }
}

/* ===== HEADER DESKTOP FIX ===== */
@media (min-width: 1024px) {

  /* Container header */
  .site-header,
  .header-inner {
    display: flex;
    align-items: center;
  }

  /* OPINI MATARAM (branding) */
  .site-branding {
    flex-shrink: 0;
    margin-right: 32px;
  }

  .site-branding .site-title,
  .site-branding a {
    font-size: 32px;        /* BESARKAN JUDUL */
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
  }

  /* Menu kategori */
  .main-navigation {
    flex: 1;               /* menu ambil ruang tengah */
  }

  .main-navigation ul {
    display: flex;
    align-items: center;
    gap: 20px;
  }

  .main-navigation a {
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: .5px;
  }

  /* Search dipaksa ke kanan */
  .header-search,
  .search-form,
  .search-toggle {
    margin-left: auto;     /* KUNCI: geser ke kanan */
    flex-shrink: 0;
  }

}

@media (min-width: 1024px) {
  .header-search {
    padding-left: 24px;
  }
}

@media (min-width: 1024px) {
  .header-search {
    position: relative;
    z-index: 5;
  }
}

/* ===== HEADER DESKTOP FINAL FIX ===== */
@media (min-width: 1024px) {

  /* Header satu baris */
  .site-header,
  .header-inner {
    display: flex;
    align-items: center;
  }

  /* OPINI MATARAM - dibuat dominan */
  .site-branding {
    margin-right: 40px;
    flex-shrink: 0;
  }

  .site-branding a,
  .site-title {
    font-size: 34px;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
  }

  /* NAVIGATION JADI FLEX */
  .main-navigation {
    display: flex;
    align-items: center;
    width: 100%;
  }

  /* MENU KATEGORI */
  .main-navigation ul {
    display: flex;
    align-items: center;
    gap: 20px;
  }

  .main-navigation a {
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: .5px;
  }

  /* SEARCH DIPAKSA KE KANAN */
  .main-navigation .search-form,
  .main-navigation .search-toggle,
  .main-navigation .header-search {
    margin-left: auto;   /* INI KUNCI UTAMA */
    flex-shrink: 0;
    padding-left: 24px;
  }

}

@media (min-width: 1024px) {
  .main-navigation ul {
    margin-right: auto;
  }
}

/* ===== HEADER DESKTOP: SEARCH POJOK KANAN ===== */
@media (min-width: 1024px) {

  /* Header jadi patokan posisi */
  .site-header,
  .header-inner {
    position: relative;
    display: flex;
    align-items: center;
  }

  /* Branding lebih dominan */
  .site-branding {
    margin-right: 40px;
    flex-shrink: 0;
  }

  .site-branding a,
  .site-title {
    font-size: 34px;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
  }

  /* Menu kategori tetap di tengah */
  .main-navigation ul {
    display: flex;
    align-items: center;
    gap: 20px;
  }

/* ===== HEADER DESKTOP : GRID FIX FINAL ===== */
@media (min-width: 1024px) {

  /* HEADER JADI GRID 3 KOLOM */
  .site-header,
  .header-inner {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    column-gap: 32px;
  }

  /* BRANDING - OPINI MATARAM */
  .site-branding {
    grid-column: 1;
    white-space: nowrap;
  }

  .site-branding a,
  .site-title {
    font-size: 34px;
    font-weight: 800;
    line-height: 1;
  }

  /* MENU KATEGORI DI TENGAH */
  .main-navigation {
    grid-column: 2;
  }

  .main-navigation ul {
    display: flex;
    align-items: center;
    gap: 20px;
    justify-content: flex-start;
  }

  .main-navigation a {
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: .5px;
  }

  /* SEARCH DI KOLOM KANAN (AMAN 100%) */
  .header-search,
  .search-toggle,
  .search-form {
    grid-column: 3;
    justify-self: end;
    position: static; /* PENTING: matikan absolute */
  }

}

/* ===== HEADER DESKTOP : GRID FIX FINAL ===== */
@media (min-width: 1024px) {

  /* HEADER JADI GRID 3 KOLOM */
  .site-header,
  .header-inner {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    column-gap: 32px;
  }

  /* BRANDING - OPINI MATARAM */
  .site-branding {
    grid-column: 1;
    white-space: nowrap;
  }

  .site-branding a,
  .site-title {
    font-size: 34px;
    font-weight: 800;
    line-height: 1;
  }

  /* MENU KATEGORI DI TENGAH */
  .main-navigation {
    grid-column: 2;
  }

  .main-navigation ul {
    display: flex;
    align-items: center;
    gap: 20px;
    justify-content: flex-start;
  }

  .main-navigation a {
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: .5px;
  }
}

/* ===== FIX HEADER DESKTOP – LOGO BISA DIKLIK ===== */
@media (min-width: 1024px) {

  /* Header top JANGAN jadi overlay */
  .header-top {
    display: flex;
    align-items: center;
    position: relative;
  }

  /* Logo dipastikan di atas */
  .logo {
    position: relative;
    z-index: 5;
  }

  .logo a {
    pointer-events: auto;
  }

  /* Nav menu jangan menutup header-top */
  #nav-menu {
    position: relative;
    z-index: 1;
  }

}

@media (min-width: 1024px) {
  .header-inner {
    display: flex;
    align-items: center;
    gap: 32px;
  }

  .logo a {
    font-size: 32px;
    font-weight: 800;
    white-space: nowrap;
  }
}
@media (min-width: 1024px) {
  .logo a {
    pointer-events: auto;
  }
}

/* ===== FIX FINAL: NAV MENU TIDAK MENUTUP LOGO (DESKTOP) ===== */
@media (min-width: 1024px) {

  #nav-menu {
    position: static !important;
    width: auto !important;
    height: auto !important;
    pointer-events: auto;
  }

}
@media (min-width: 1024px) {
  #nav-menu.show {
    position: static !important;
  }
}

/* ===== FIX: HEADLINE HOMEPAGE TIDAK BISA DIKLIK (DESKTOP) ===== */
@media (min-width: 1024px) {

  /* Matikan semua overlay headline */
  .headline::before,
  .headline::after,
  .headline *::before,
  .headline *::after {
    pointer-events: none;
  }

  /* Pastikan link headline bisa diklik */
  .headline a {
    position: relative;
    z-index: 5;
    pointer-events: auto;
  }

}

/* =================================================
   MOBILE OVERRIDE FINAL
   MENETRALISIR CSS DESKTOP YANG BOCOR
   ================================================= */
@media (max-width: 1023px) {

  /* RESET STRUKTUR HEADER */
  .site-header,
  .header-inner,
  .header-top {
    display: block !important;
  }

  /* HEADER BAR */
  .header-top {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
  }

  /* LOGO */
  .logo {
    flex: 1 !important;
  }

  .logo a {
    font-size: 20px !important;
    font-weight: 700 !important;
    white-space: nowrap !important;
  }

  /* SEARCH – PAKSA 1 SAJA */
  .header-search {
    display: block !important;
    width: auto !important;
    margin: 0 !important;
  }

  .header-search input {
    width: 140px !important;
    height: 34px !important;
  }

  /* HAMBURGER – PAKSA SATU */
  .hamburger {
    display: inline-flex !important;
  }

  /* kalau ada hamburger dobel dari CSS lama */
  .hamburger + .hamburger,
  .header-top .hamburger ~ .hamburger {
    display: none !important;
  }

  /* MENU MOBILE */
  #nav-menu {
    display: none !important;
    position: static !important;
    width: 100% !important;
  }

  #nav-menu.show {
    display: block !important;
  }

}

@media (min-width: 1024px) {

  /* Container utama */
  header.site-header .header-top {
    display: flex !important;
    align-items: center !important;
  }

  /* LOGO: jangan ikut fleksibel */
  header.site-header .logo {
    flex: 0 0 auto !important;
    margin-right: 32px !important;
  }

  header.site-header .logo a {
    font-size: 36px !important;
    font-weight: 800 !important;
    white-space: nowrap !important;
  }

  /* SEARCH: dipaksa ke kanan */
  header.site-header .header-search {
    flex: 0 0 260px !important;
    margin-left: auto !important;
  }

  header.site-header .header-search input {
    width: 100% !important;
  }

  /* HAMBURGER MATI DI DESKTOP */
  header.site-header .hamburger {
    display: none !important;
  }
}

@media (max-width: 1023px) {

  header.site-header .header-top {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
  }

  /* LOGO: boleh 2 baris, lebih besar */
  header.site-header .logo {
    flex: 0 0 120px !important;
  }

  header.site-header .logo a {
    font-size: 22px !important;
    font-weight: 800 !important;
    line-height: 1.1 !important;
    white-space: normal !important;
  }

  /* SEARCH: benar-benar di tengah */
  header.site-header .header-search {
    flex: 1 1 auto !important;
    margin: 0 6px !important;
  }

  header.site-header .header-search input {
    width: 100% !important;
    height: 36px !important;
  }

  /* HAMBURGER kanan */
  header.site-header .hamburger {
    flex: 0 0 auto !important;
    font-size: 22px !important;
  }
}
 
/* === TEST CSS AKTIF === */
.site-header {
  outline: 5px solid red !important;
}

/* ================= SEARCH RESULT ================= */
.search .site-main {
  max-width: 900px;
  margin: 0 auto;
  padding: 1rem;
}

.search-item {
  border-bottom: 1px solid #e5e7eb;
  padding: 1rem 0;
}

.search-inner {
  display: flex;
  gap: 1rem;
}

.search-thumb img {
  width: 160px;
  height: 110px;
  object-fit: cover;
  border-radius: 6px;
}

.search-content {
  flex: 1;
}

.search .entry-title {
  font-size: 1.1rem;
  line-height: 1.4;
  margin: 0 0 0.4rem;
}

.search .entry-title a {
  color: #0f172a;
  text-decoration: none;
}

.search .entry-title a:hover {
  color: #2563eb;
}

.search .entry-summary {
  font-size: 0.9rem;
  color: #475569;
}

/* MOBILE */
@media (max-width: 640px) {
  .search-inner {
    flex-direction: column;
  }

  .search-thumb img {
    width: 100%;
    height: auto;
  }
}

/* ================= ARCHIVE / SEARCH ================= */
.archive-main {
  max-width: 980px;
  margin: 0 auto;
  padding: 1rem;
}

.archive-item {
  display: flex;
  gap: 1rem;
  padding: 1rem 0;
  border-bottom: 1px solid #e5e7eb;
}

.archive-thumb img {
  width: 180px;
  height: 120px;
  object-fit: cover;
  border-radius: 6px;
}

.archive-content {
  flex: 1;
}

.archive-title {
  font-size: 1.1rem;
  line-height: 1.4;
  margin: 0 0 0.4rem;
}

.archive-title a {
  color: #0f172a;
  text-decoration: none;
}

.archive-title a:hover {
  color: #2563eb;
}

.archive-meta {
  font-size: 0.8rem;
  color: #64748b;
  margin-bottom: 0.4rem;
}

.archive-excerpt {
  font-size: 0.95rem;
  color: #334155;
}

/* MOBILE */
@media (max-width: 640px) {
  .archive-item {
    flex-direction: column;
  }

  .archive-thumb img {
    width: 100%;
    height: auto;
  }
}

.featured-image {
  margin-bottom: 1rem;
}

.photo-credit {
  font-size: 0.75rem;
  color: #64748b;
  margin-top: 0.3rem;
  text-align: right;
  font-style: italic;
}

/* ================= SINGLE ARTICLE ================= */

.single-header {
  margin-bottom: 1rem;
}

.single-title {
  font-size: 2rem;
  line-height: 1.3;
  margin: 0.5rem 0;
}

.single-meta {
  font-size: 0.85rem;
  color: #64748b;
}

.featured-image {
  margin: 1.2rem 0;
}

.featured-image img {
  width: 100%;
  height: auto;
  border-radius: 6px;
}

.photo-credit {
  font-size: 0.75rem;
  color: #64748b;
  margin-top: 0.4rem;
  text-align: right;
  font-style: italic;
}

.single-content {
  font-size: 1rem;
  line-height: 1.7;
  color: #0f172a;
}

.related-posts {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid #e5e7eb;
}

.related-posts h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.related-posts ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.related-posts li {
  margin-bottom: 0.4rem;
}

.related-posts a {
  text-decoration: none;
  color: #2563eb;
}

.related-posts a:hover {
  text-decoration: underline;
}

/* HEADLINE EXCERPT – DESKTOP ONLY */
@media (min-width: 769px){
  .headline-main .headline-excerpt{
    display:block;
    font-size:16px;
    line-height:1.55;
    color:#e5e7eb;
    max-width:80%;
  }
}

/* MOBILE – SEMBUNYIKAN EXCERPT HEADLINE */
@media (max-width:768px){
  .headline-main .headline-excerpt{
    display:none;
  }
}


