/*
Theme Name: Nadi Berita v3
Theme URI: https://pancuran.online/
Author: Yusuf Bimbi
Description: Tema WordPress modern dengan 6 gaya header, sidebar populer & terbaru (5 item), serta artikel terkait.
Version: 3.0.0
License: Commercial Proprietary License
License URI: https://yusufbimbi.my.id
Text Domain: nadi-berita-v3
Tags: news, magazine, podcast, e-learning, dakwah, responsive
*/

body { font-family: system-ui, -apple-system, sans-serif; background: #f4f6f9; color:#1e293b; margin:0; padding:0; transition: background-color 0.3s, color 0.3s; }
body.dark-mode { background-color: #0f172a !important; color: #f1f5f9 !important; }
body.dark-mode .wp-card-magazine { background-color: #1e293b !important; color: #f1f5f9 !important; border-color: #334155 !important; }
body.dark-mode .wp-card-magazine h1, body.dark-mode .wp-card-magazine h2, body.dark-mode .wp-card-magazine h3, body.dark-mode .wp-card-magazine h4, body.dark-mode .wp-card-magazine a { color: #f8fafc !important; }
.wp-container-max { max-width:1200px; margin:0 auto; padding:0 20px; }
.wp-card-magazine { background:#fff; border:1px solid #e2e8f0; border-radius:12px; padding:18px; box-sizing:border-box; margin-bottom: 14px; box-shadow: 0 2px 6px rgba(0,0,0,0.02); transition: background-color 0.3s; }

.wp-two-col-layout { display: grid; grid-template-columns: 1fr; gap: 22px; width: 100%; margin-bottom: 16px; align-items: start; }
@media(min-width: 820px) {
    .wp-two-col-layout.layout-70-30 { grid-template-columns: minmax(0, 2.35fr) minmax(270px, 1fr); }
    .wp-two-col-layout.layout-30-70 { grid-template-columns: minmax(270px, 1fr) minmax(0, 2.35fr); }
}
.wp-main-col { min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.wp-sidebar-col { min-width: 0; display: flex; flex-direction: column; gap: 14px; position: sticky; top: 20px; }
body.focus-mode-active .wp-two-col-layout { grid-template-columns: 1fr !important; }
body.focus-mode-active .wp-sidebar-col { display: none !important; }
.related-posts-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }

.wp-custom-nav-bar ul { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 20px; }
.wp-custom-nav-bar ul li a { color: #334155; text-decoration: none; font-size: 14px; font-weight: 600; }
.wp-custom-nav-bar ul li a:hover { color: #2563eb; }
.widget-title { font-size: 14px; font-weight: 800; text-transform: uppercase; color: #0f172a; border-bottom: 2px solid #2563eb; padding-bottom: 6px; margin: 0 0 12px 0; }
.widget-popular-item { display: flex; gap: 10px; align-items: flex-start; border-bottom: 1px solid #f1f5f9; padding-bottom: 8px; margin-bottom: 8px; font-size: 12.5px; font-weight: 600; line-height: 1.35; }
.widget-popular-rank { background: #2563eb; color: #fff; width: 22px; height: 22px; border-radius: 5px; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 800; flex-shrink: 0; margin-top: 1px; }
.widget-recent-item { display: flex; gap: 10px; align-items: center; border-bottom: 1px solid #f1f5f9; padding-bottom: 8px; margin-bottom: 8px; }
.widget-recent-thumb { width: 62px; height: 46px; border-radius: 6px; overflow: hidden; flex-shrink: 0; background: #e2e8f0; }
.cat-badge-tag { background: #2563eb; color: #ffffff; font-size: 9px; font-weight: 800; padding: 2px 6px; border-radius: 4px; text-transform: uppercase; display: inline-block; margin-bottom: 6px; }
#reading-progress { position: fixed; top: 0; left: 0; height: 4px; background: #2563eb; width: 0%; z-index: 9999; transition: width 0.1s; }
#back-to-top { position: fixed; bottom: 30px; right: 30px; background: #2563eb; color: #fff; border: none; border-radius: 50%; width: 44px; height: 44px; font-size: 18px; cursor: pointer; display: none; z-index: 999; box-shadow: 0 4px 10px rgba(0,0,0,0.2); }
.share-btn { padding: 6px 12px; border-radius: 6px; color: #fff; font-size: 11px; font-weight: bold; text-decoration: none; display: inline-flex; align-items: center; gap: 4px; }
.share-wa { background: #25d366; } .share-fb { background: #1877f2; } .share-tw { background: #1da1f2; } .share-tg { background: #0088cc; } .share-copy { background: #64748b; cursor: pointer; border: none; }
/* Styling Alignment Gambar standar WordPress */
.wp-card-magazine img.alignleft, 
figure.alignleft {
    float: left;
    margin: 0 20px 20px 0;
    max-width: 50%;
    height: auto;
}

.wp-card-magazine img.alignright, 
figure.alignright {
    float: right;
    margin: 0 0 20px 20px;
    max-width: 50%;
    height: auto;
}

.wp-card-magazine img.aligncenter, 
figure.aligncenter {
    display: block;
    margin: 15px auto;
    height: auto;
}

/* Clearfix agar tata letak konten tidak pecah */
.wp-card-magazine::after {
    content: "";
    display: table;
    clear: both;
}