/*
Theme Name: JavaNews Online Child
Theme URI: https://javanews.online/
Description: Penyempurnaan aman WpBerita untuk JavaNews Online.
Author: JavaNews Online
Template: wpberita
Version: 1.3.3
*/

:root {
  --jn-navy: #0b1f4d;
  --jn-blue: #174ea6;
  --jn-red: #d71920;
  --jn-gold: #d4af37;
  --jn-ink: #172033;
  --jn-muted: #667085;
  --jn-surface: #ffffff;
  --jn-soft: #f5f7fb;
  --jn-line: #e6eaf0;
}

body.home { background: #fff; color: var(--jn-ink); }
body.home #page { overflow: hidden; }

/* Balanced masthead: stronger logo presence without overpowering the news grid. */
.gmr-logo-wrap { padding-top: 12px !important; padding-bottom: 12px !important; }
.gmr-logo-wrap .custom-logo-link { display: inline-block; line-height: 0; }
.gmr-logo-wrap img.custom-logo { width: 250px !important; max-width: min(100%, 250px) !important; height: auto !important; }

/* Remove legacy demo banners until real ad inventory is available. */
.gmr-banner-logo img[src*="blogger.googleusercontent.com"],
.gmr-topbanner img[src*="blogger.googleusercontent.com"] { display: none !important; }

/* Avoid the duplicated publish/update date seen in the existing theme. */
.posted-on time.published + time.updated { display: none !important; }

.jn-header-tagline { margin: 8px 0 0; color: var(--jn-muted); font-size: 13px; line-height: 1.45; font-weight: 600; }
.jn-header-tagline strong { display: block; color: var(--jn-ink); font-size: 15px; }
.jn-ad-shell { min-height: 82px; display: flex; align-items: center; justify-content: center; background: #f6f7f9; border: 1px solid #eceff3; color: #98a2b3; font-size: 10px; letter-spacing: .1em; text-transform: uppercase; }
.gmr-banner-logo .jn-ad-shell { min-height: 76px; }
.gmr-topbanner .jn-ad-shell { min-height: 108px; margin: 18px 0 22px; }

body.home .modulehome-wrap,
body.home #primary,
body.home #secondary .widget,
body.home .module-widget {
  border-radius: 12px;
}
body.home #primary,
body.home #secondary .widget,
body.home .module-widget {
  background: var(--jn-surface);
  border: 1px solid var(--jn-line);
  box-shadow: 0 5px 20px rgba(16, 24, 40, .05);
}
body.home .modulehome-wrap { margin-top: 10px; }
body.home .gmr-slider-content { border-radius: 12px; overflow: hidden; }
body.home .module-home img { transition: transform .35s ease; }
body.home .module-home:hover img { transform: scale(1.025); }
body.home article { transition: transform .2s ease, box-shadow .2s ease; }
body.home article:hover { transform: translateY(-2px); }
body.home .entry-title a,
body.home .recent-title { color: var(--jn-ink); }
body.home .entry-title a:hover,
body.home .recent-title:hover { color: var(--jn-red); }
body.home .page-title,
body.home .module-title { color: var(--jn-navy); }
body.home .cat-links-content a {
  color: var(--jn-red);
  font-weight: 700;
}
body.home img { object-fit: cover; }
body.home #infinite-container article { padding: 18px 0; border-bottom: 1px solid var(--jn-line); }
body.home #infinite-container article .entry-title { margin-top: 6px; font-size: clamp(18px, 2vw, 24px); }
body.home #infinite-container article .entry-summary,
body.home #infinite-container article .entry-content { color: var(--jn-muted); line-height: 1.65; }
body.home .wpberita-featured-content img,
body.home #infinite-container article img { border-radius: 9px; }
body.home .widget-title,
body.home .module-title,
body.home .page-title { position: relative; padding-bottom: 10px; border-bottom: 1px solid var(--jn-line); }
body.home .widget-title::after,
body.home .module-title::after,
body.home .page-title::after { content: ""; position: absolute; left: 0; bottom: -1px; width: 42px; height: 3px; background: var(--jn-red); border-radius: 3px; }
body.home #secondary { position: relative; }
body.home #secondary .widget { margin-bottom: 20px; padding: 18px; }
body.home .site-footer { margin-top: 28px; background: var(--jn-navy); color: rgba(255,255,255,.8); }
body.home .site-footer a { color: #fff; }
.site-footer .gmr-footer-logo,
.site-footer .gmr-social-icons { display: none !important; }
.site-footer .heading-text.text-center { display: block !important; }
.site-footer .site-info { display: block; margin: 0 !important; padding: 4px 0 10px !important; border: 0 !important; text-align: center; }
.site-footer .footer-menu { margin: 0 !important; }
.site-footer .footer-menu ul { line-height: 1.9; }
.site-footer .footer-menu li a { padding: 0 7px; font-size: 13px; }
.jn-copyright { max-width: 1170px; margin: 12px auto 0; padding: 14px 18px 0; border-top: 1px solid rgba(255,255,255,.1); color: rgba(255,255,255,.62); text-align: center; font-size: 12px; }
.jn-infeed-ad { margin: 24px 0; min-height: 96px; }
.jn-footer-ad { max-width: 1170px; margin: 30px auto 0; min-height: 90px; }
.jn-kriez-credit { max-width: 1170px; margin: 0 auto; padding: 22px 18px; display: flex; align-items: center; justify-content: center; gap: 9px; color: rgba(255,255,255,.7); font-size: 13px; border-bottom: 1px solid rgba(255,255,255,.11); }
.jn-kriez-credit a { color: #ffe48a !important; font-weight: 800; letter-spacing: .02em; text-decoration: none; }
.jn-kriez-credit a:hover { color: #fff !important; }

.jn-ad-note {
  color: #98a2b3;
  font-size: 10px;
  letter-spacing: .08em;
  text-align: center;
  text-transform: uppercase;
  margin-bottom: 7px;
}

@media (max-width: 768px) {
  .gmr-logo-wrap { padding-top: 10px !important; padding-bottom: 10px !important; text-align: center; }
  .gmr-logo-wrap img.custom-logo { width: 195px !important; max-width: 76vw !important; }
  .jn-header-tagline { text-align: center; margin: 6px 12px 0; }
  .gmr-banner-logo .jn-ad-shell { display: none; }
  .gmr-topbanner .jn-ad-shell { min-height: 72px; margin: 10px 0 16px; }
  .jn-kriez-credit { flex-direction: column; gap: 3px; text-align: center; padding: 18px 14px; }
  #main-nav { overflow: hidden; }
  #primary-menu { display: flex !important; flex-wrap: nowrap !important; overflow-x: auto; overscroll-behavior-inline: contain; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  #primary-menu::-webkit-scrollbar { display: none; }
  #primary-menu > li { flex: 0 0 auto; }
  .jn-footer-ad { min-height: 74px; margin-top: 12px; }
  body.home .site-footer { margin-top: 12px; padding: 0 0 20px; }
  .site-footer .container { padding-left: 14px; padding-right: 14px; }
  .site-footer .footer-menu li a { padding: 0 5px; font-size: 12px; }
  .jn-copyright { margin-top: 10px; padding-top: 12px; line-height: 1.6; }
  body.home article { transform: none !important; }
  body.home .entry-title { line-height: 1.35; }
  body.home #infinite-container article { padding: 15px 0; }
}

@media (prefers-reduced-motion: reduce) {
  body.home article { transition: none; }
}


/* v1.3.2 — Latest-story hero: newest post is always visually dominant. */
body.home .wpberita-moduleslide,
body.home #moduleslide-mw,
body.home .gmr-module-slider {
  display: none !important;
}

body.home .gmr-bigheadline {
  display: grid !important;
  grid-template-columns: minmax(0, 1.72fr) minmax(230px, .88fr);
  gap: 22px;
  margin: 12px 0 32px;
  padding: 0;
  overflow: visible;
}

body.home .gmr-big-headline,
body.home .gmr-bigheadline-right {
  float: none !important;
  width: auto !important;
  max-width: none !important;
}

body.home .gmr-big-headline {
  overflow: hidden;
  border: 1px solid var(--jn-line);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(11,31,77,.09);
}

body.home .gmr-big-headline > .post-thumbnail {
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--jn-soft);
}

body.home .gmr-big-headline > .post-thumbnail img {
  display: block;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
  transition: transform .25s ease;
}

body.home .gmr-big-headline:hover > .post-thumbnail img {
  transform: scale(1.025);
}

body.home .gmr-bigheadline-content {
  padding: 18px 20px 20px;
}

body.home .gmr-bigheadline-content .gmr-meta-topic {
  margin-bottom: 8px;
  color: var(--jn-muted);
  font-size: 12px;
}

body.home .gmr-bigheadline-content .gmr-rp-biglink {
  margin: 0 0 10px;
  font-size: clamp(23px, 2.15vw, 31px) !important;
  line-height: 1.18 !important;
  letter-spacing: -.02em;
}

body.home .gmr-bigheadline-content .gmr-rp-biglink a {
  color: var(--jn-ink);
}

body.home .gmr-bigheadline-content .entry-content {
  color: var(--jn-muted);
  font-size: 14px;
  line-height: 1.65;
}

body.home .gmr-bigheadline-right {
  display: grid;
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

body.home .gmr-bigheadline-right .wrap-headline-right {
  position: relative;
  min-height: 190px;
  overflow: hidden;
  border-radius: 13px;
  background: var(--jn-navy);
  box-shadow: 0 8px 22px rgba(11,31,77,.10);
}

body.home .gmr-bigheadline-right .post-thumbnail,
body.home .gmr-bigheadline-right .post-thumbnail img {
  display: block;
  width: 100% !important;
  height: 100% !important;
}

body.home .gmr-bigheadline-right .post-thumbnail img {
  position: absolute;
  inset: 0;
  object-fit: cover;
}

body.home .gmr-bigheadline-right .wrap-headline-right::after {
  content: "";
  position: absolute;
  inset: 35% 0 0;
  z-index: 1;
  background: linear-gradient(180deg, transparent, rgba(5,15,38,.88));
  pointer-events: none;
}

body.home .gmr-bigheadline-right .recent-title-wrap {
  position: absolute !important;
  z-index: 2;
  right: 0;
  bottom: 0;
  left: 0;
  margin: 0 !important;
  padding: 48px 15px 15px !important;
  background: none !important;
}

body.home .gmr-bigheadline-right .recent-title {
  display: -webkit-box;
  overflow: hidden;
  color: #fff !important;
  font-size: 16px !important;
  font-weight: 700;
  line-height: 1.32;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

@media (max-width: 767px) {
  body.home .gmr-bigheadline {
    display: block !important;
    margin-top: 8px;
  }

  body.home .gmr-big-headline {
    margin-bottom: 16px;
  }

  body.home .gmr-big-headline > .post-thumbnail {
    aspect-ratio: 16 / 10;
  }

  body.home .gmr-bigheadline-content {
    padding: 14px 15px 17px;
  }

  body.home .gmr-bigheadline-content .gmr-rp-biglink {
    font-size: 22px !important;
  }

  body.home .gmr-bigheadline-content .entry-content {
    display: none;
  }

  body.home .gmr-bigheadline-right {
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: none;
    gap: 12px;
  }

  body.home .gmr-bigheadline-right .wrap-headline-right {
    min-height: 205px;
  }

  body.home .gmr-bigheadline-right .recent-title {
    font-size: 17px !important;
  }
}


/* Keep legacy clearfix pseudo-elements out of the CSS grid. */
body.home .gmr-bigheadline::before,
body.home .gmr-bigheadline::after {
  display: none !important;
  content: none !important;
}
