/* =========================================================
   SriDiGi News - Global Styles
   ========================================================= */

* { box-sizing: border-box; margin: 0; padding: 0; }
body {
    background: #f7f7f7;
    font-family: 'Mukta', 'Noto Sans Devanagari', -apple-system, sans-serif;
    color: #222222;
    line-height: 1.5;
}
.container { max-width: 1240px; margin: 0 auto; padding: 0 15px; }

/* 1. TOP BLACK UTILITY STRIP */
.jagran-topbar { background: #000000; color: #d1d5db; font-size: 11.5px; padding: 6px 0; font-weight: 500; border-bottom: 1px solid #1f2937; }
.topbar-flex { display: flex; justify-content: space-between; align-items: center; }
.topbar-left { display: flex; align-items: center; gap: 12px; }
.topbar-right-links { display: flex; align-items: center; gap: 15px; }
.topbar-right-links a { color: #9ca3af; text-decoration: none; font-size: 11.5px; transition: color 0.15s; }
.topbar-right-links a:hover { color: #ffffff; }

/* 2. MAIN BRAND MASTHEAD */
.jagran-masthead { background: #ffffff; padding: 12px 0; border-bottom: 1px solid #e5e7eb; }
.masthead-flex { display: flex; justify-content: space-between; align-items: center; }
.brand-logo-wrap { display: flex; align-items: center; gap: 14px; text-decoration: none; }
.brand-logo-img { height: 48px; max-width: 180px; object-fit: contain; display: block; }
.brand-text-wrap { display: flex; flex-direction: column; justify-content: center; }
.brand-name { font-size: 30px; font-weight: 800; color: #0f172a; line-height: 1; letter-spacing: -0.5px; }
.brand-name span { color: #eb1c24; }
.brand-motto { font-size: 11.5px; color: #64748b; font-weight: 600; margin-top: 4px; }
.masthead-actions { display: flex; align-items: center; gap: 14px; }
.btn-subscribe { background: #eb1c24; color: #ffffff; font-size: 13.5px; font-weight: 700; padding: 7px 18px; border-radius: 4px; text-decoration: none; transition: background 0.15s; }
.btn-subscribe:hover { background: #c9182b; }
.user-auth-btn { color: #334155; font-size: 20px; text-decoration: none; padding: 4px; }

/* 3. NAVIGATION BAR */
.jagran-navbar { background: #ffffff; border-bottom: 2px solid #eaeaea; position: sticky; top: 0; z-index: 100; box-shadow: 0 2px 5px rgba(0,0,0,0.03); }
.nav-flex { display: flex; justify-content: space-between; align-items: center; }
.primary-nav-links { display: flex; align-items: center; overflow-x: auto; overflow-y: hidden; white-space: nowrap; scrollbar-width: none; -ms-overflow-style: none; }
.primary-nav-links::-webkit-scrollbar { display: none; }
.primary-nav-links a { padding: 12px 14px; font-size: 15px; font-weight: 700; color: #1e293b; text-decoration: none; position: relative; transition: color 0.15s; display: inline-block; }
.primary-nav-links a:hover, .primary-nav-links a.active { color: #eb1c24; }
.primary-nav-links a.active::after { content: ''; position: absolute; bottom: -2px; left: 10px; right: 10px; height: 3px; background: #eb1c24; }
.nav-action-icons { display: flex; align-items: center; gap: 16px; padding-left: 14px; border-left: 1px solid #e2e8f0; flex-shrink: 0; }
.icon-item { display: flex; flex-direction: column; align-items: center; color: #475569; text-decoration: none; font-size: 11px; font-weight: 600; }
.icon-item span.emoji { font-size: 15px; }

/* 4. FOCUS STRIP */
.jagran-focus-strip { background: #ffffff; border-bottom: 1px solid #eaeaea; padding: 8px 0; }
.focus-flex { display: flex; align-items: center; gap: 8px; overflow-x: auto; overflow-y: hidden; white-space: nowrap; scrollbar-width: none; }
.focus-flex::-webkit-scrollbar { display: none; }
.focus-label { font-size: 13px; font-weight: 800; color: #1e293b; flex-shrink: 0; margin-right: 4px; }
.focus-badge { font-size: 12px; font-weight: 700; padding: 3px 12px; border-radius: 50px; text-decoration: none; display: inline-block; border: 1px solid transparent; }
.badge-red { background: #fee2e2; color: #b91c1c; border-color: #fecaca; }
.badge-orange { background: #ffedd5; color: #c2410c; border-color: #fed7aa; }
.badge-blue { background: #e0f2fe; color: #0369a1; border-color: #bae6fd; }
.badge-green { background: #dcfce7; color: #15803d; border-color: #bbf7d0; }
.badge-gray { background: #f1f5f9; color: #334155; border-color: #e2e8f0; }

/* Category Header Strip */
.category-header-strip { background: #ffffff; border-bottom: 1px solid #e5e7eb; padding: 16px 0; margin-bottom: 24px; }
.breadcrumb { font-size: 12.5px; color: #64748b; margin-bottom: 6px; }
.breadcrumb a { color: #64748b; text-decoration: none; }
.breadcrumb a:hover { color: #eb1c24; }
.category-title { font-size: 24px; font-weight: 800; color: #0f172a; border-left: 4px solid #eb1c24; padding-left: 10px; }

/* Content Grid */
.news-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.mini-card { background: #fff; border-radius: 6px; border: 1px solid #e5e7eb; overflow: hidden; display: flex; flex-direction: column; }
.mini-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.06); }
.mini-card-img { height: 180px; width: 100%; background: #e2e8f0; overflow: hidden; }
.mini-card-img img { width: 100%; height: 100%; object-fit: cover; }
.mini-card-body { padding: 16px; flex: 1; display: flex; flex-direction: column; }
.category-tag { color: #eb1c24; font-size: 12px; font-weight: 800; text-transform: uppercase; margin-bottom: 4px; }
.mini-card-title { font-size: 16.5px; font-weight: 700; line-height: 1.4; margin: 4px 0 10px 0; }
.mini-card-title a { color: #1e293b; text-decoration: none; }
.mini-card-title a:hover { color: #eb1c24; }
.mini-card-footer { margin-top: auto; font-size: 12px; color: #94a3b8; padding-top: 10px; border-top: 1px solid #f1f5f9; }

.empty-state { background: #fff; border-radius: 8px; padding: 60px 20px; text-align: center; border: 1px solid #e5e7eb; }

/* Mega Footer */
.jagran-footer { background: #151515; color: #a3a3a3; padding: 45px 0 25px 0; font-size: 13px; margin-top: 60px; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 30px; margin-bottom: 35px; }
.footer-col-title { color: #fff; font-size: 14px; font-weight: 800; margin-bottom: 16px; text-transform: uppercase; }
.footer-links-list { list-style: none; }
.footer-links-list li { margin-bottom: 8px; }
.footer-links-list a { color: #9ca3af; text-decoration: none; }
.footer-links-list a:hover { color: #eb1c24; }
.footer-bottom-bar { border-top: 1px solid #262626; padding-top: 20px; display: flex; justify-content: space-between; font-size: 12px; }
.app-store-badges { display: flex; gap: 10px; }
.badge-store { background: #262626; color: #ffffff; padding: 6px 14px; border-radius: 4px; font-size: 11px; font-weight: 700; text-decoration: none; border: 1px solid #333; }
/* =========================================================
   MOBILE RESPONSIVE FIXES (JAGRAN STYLE)
   ========================================================= */

/* Default hidden elements for desktop */
.mobile-menu-btn { display: none; }
.mobile-bottom-nav { display: none; }

@media (max-width: 768px) {
    /* 1. Show Top Black Strip & Center Date (Jagran Style) */
    .jagran-topbar { display: block; padding: 4px 0; background: #000; text-align: center; }
    .topbar-flex { justify-content: center; }
    .topbar-left { justify-content: center; width: 100%; }
    .topbar-left span.hide-mobile { display: none; }
    .topbar-right-links { display: none; }
    .mobile-datetime { font-size: 10px; font-weight: 600; color: #fff; letter-spacing: 0.5px; text-transform: uppercase; }

    /* 2. STICKY HEADER FIX & Spacing for 320px screens */
    .jagran-masthead { 
        padding: 0; 
        position: sticky; /* Header ko top par fix karne ke liye */
        top: 0; 
        z-index: 1000; 
        background: #ffffff; 
        box-shadow: 0 2px 5px rgba(0,0,0,0.08); /* Scroll hone par shadow dikhegi */
    }
    .masthead-flex { 
        flex-direction: row !important; 
        flex-wrap: nowrap !important; 
        justify-content: space-between; 
        align-items: center; 
        padding: 8px 10px; 
    }
    
    .brand-logo-wrap { gap: 4px; flex-shrink: 1; min-width: 0; }
    .brand-logo-img { height: auto; max-height: 32px; max-width: 100px; width: 100%; object-fit: contain; }
    .brand-name { font-size: 18px; white-space: nowrap; } 
    .brand-motto { display: none; }

    /* Actions (Button & Icons) */
    .masthead-actions { gap: 8px; width: auto !important; justify-content: flex-end; flex-shrink: 0; }
    .btn-subscribe { padding: 4px 8px; font-size: 11px; white-space: nowrap; } 
    .user-auth-btn { font-size: 18px; padding: 0; }
    .mobile-menu-btn { display: block !important; font-size: 20px; color: #000; cursor: pointer; font-weight: bold; line-height: 1; }

    /* 3. Fix Navbar Overlap */
    .jagran-navbar { position: relative; top: auto; z-index: 10; box-shadow: none; border-top: 1px solid #eaeaea; }
    .jagran-navbar .container { padding: 0; }
    .jagran-focus-strip .container { padding: 0; }
    .primary-nav-links { padding: 0 10px; }
    .focus-flex { padding: 0 10px; }
    .primary-nav-links a { padding: 10px 10px; font-size: 14px; }
    .nav-action-icons { display: none; }
    
    body[data-site-layout="public"] { padding-bottom: 65px; }

    /* 4. Mobile Bottom Navigation */
    .mobile-bottom-nav {
        display: flex; position: fixed; bottom: 0; left: 0; width: 100%;
        background: #ffffff; border-top: 1px solid #e2e8f0; z-index: 1000;
        box-shadow: 0 -2px 5px rgba(0,0,0,0.05); justify-content: space-around;
        align-items: center; padding: 6px 2px 8px 2px; 
    }
    .bottom-nav-item {
        display: flex; flex-direction: column; align-items: center; text-decoration: none;
        color: #475569; font-size: 9.5px; font-weight: 600; gap: 2px;
    }
    .bottom-nav-item span.icon { font-size: 16px; line-height: 1; }
    .bottom-nav-item.active { color: #eb1c24; }
    .bottom-nav-item.active span.icon { filter: hue-rotate(320deg) saturate(300%); }
}

/* Extra safety for extremely small screens (below 340px) */
@media (max-width: 340px) {
    .brand-name { display: none; } 
    .btn-subscribe { font-size: 10px; padding: 3px 6px; }
}