/* ==========================================================================
   1. GLOBAL STYLES & RESET 
   -------------------------------------------------------------------------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', system-ui, -apple-system, Roboto, Helvetica, Arial, sans-serif;
}

html, body {
    width: 100%;
    overflow-x: hidden !important;
}

body {
    background: #f4f6f8;
    color: #1e293b;
    line-height: 1.5;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* ==========================================================================
   2. MEDIA HOUSE HEADER & NAVIGATION
   -------------------------------------------------------------------------- */
.top-header {
    background: linear-gradient(135deg, #cc0000 0%, #990000 50%, #800000 100%);
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 40px;
    box-shadow: 0 4px 20px rgba(153, 0, 0, 0.35);
    border-bottom: 3px solid #ffcc00;
}

.logo {
    font-size: 32px;
    font-weight: 900;
    letter-spacing: -0.8px;
    text-transform: uppercase;
    cursor: pointer;
    color: #ffffff;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    gap: 8px;
    transition: transform 0.2s ease;
    white-space: nowrap;
}

.logo span {
    color: #ffcc00;
}

.logo:hover {
    transform: scale(1.02);
}

.right-side {
    display: flex;
    align-items: center;
    gap: 18px;
}

.search-box {
    display: flex;
    border-radius: 30px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    border: 2px solid #ffcc00;
}

.search-box:focus-within {
    box-shadow: 0 0 15px rgba(255, 204, 0, 0.6);
    transform: scale(1.02);
}

.search-box input {
    padding: 10px 20px;
    border: none;
    outline: none;
    width: 240px;
    font-size: 14px;
    background: transparent;
    color: #1e293b;
    font-weight: 600;
}

.search-box button {
    padding: 10px 22px;
    background: #111111;
    color: #ffcc00;
    border: none;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.25s ease;
    border-radius: 0 30px 30px 0;
}

.search-box button:hover {
    background: #000000;
    color: #ffffff;
}

#theme-btn {
    background: rgba(0, 0, 0, 0.35);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 8px 18px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    backdrop-filter: blur(8px);
    transition: all 0.25s ease;
}

#theme-btn:hover {
    background: #ffffff;
    color: #cc0000;
    border-color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

#stickyNav {
    width: 100%;
    background: #0b1329;
    box-shadow: 0 5px 15px rgba(0,0,0,0.25);
    border-bottom: 1px solid rgba(255,255,255,0.1);
    transition: all 0.2s ease;
}

#stickyNav.fixed-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 9999;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
}

.nav-links {
    display: flex;
    justify-content: center;
    list-style: none;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
}

.nav-links li {
    position: relative;
}

.nav-links li a {
    display: inline-block;
    color: #e2e8f0;
    text-decoration: none;
    font-size: 17px;
    font-weight: 600;
    padding: 14px 16px;
    letter-spacing: 0.3px;
    transition: color 0.2s ease;
}

.nav-links li a:hover {
    color: #ffcc00 !important;
    background-color: rgba(255, 255, 255, 0.05) !important;
}

.nav-links li a.active {
    color: #ffcc00 !important;
    font-weight: 800;
}

.nav-links li a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;    
    right: 0;    
    height: 4px;
    background: #cc0000;
    border-radius: 4px 4px 0 0;
    box-shadow: 0 0 10px #cc0000;
}

.menu-btn {
    display: none;
    color: white;
    font-size: 26px;
    padding: 10px;
    cursor: pointer;
}

/* ==========================================================================
   3. STYLISH BREAKING NEWS BAR
   -------------------------------------------------------------------------- */
.breaking-bar {
    display: flex;
    width: 100%;
    height: 46px;
    background: #ffffff;
    color: #1a1a1a;
    align-items: center;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    border-bottom: 2px solid #e2e8f0;
}

.breaking-label {
    background: linear-gradient(135deg, #e60000 0%, #990000 100%);
    color: #ffffff;
    height: 100%;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 28px 0 20px;
    font-weight: 800;
    font-size: 14px;
    letter-spacing: 1px;
    text-transform: uppercase;
    position: relative;
    z-index: 2;
    box-shadow: 3px 0 10px rgba(211, 16, 39, 0.3);
}

.breaking-label::after {
    content: '';
    position: absolute;
    right: -16px;
    top: 0;
    width: 0;
    height: 0;
    border-top: 46px solid #990000;
    border-right: 16px solid transparent;
}

.breaking-label::before {
    content: '';
    width: 9px;
    height: 9px;
    background-color: #ffffff;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 8px #ffffff;
    animation: pulse-dot 1.2s infinite ease-in-out;
}

@keyframes pulse-dot {
    0% { transform: scale(0.8); opacity: 0.5; }
    50% { transform: scale(1.2); opacity: 1; }
    100% { transform: scale(0.8); opacity: 0.5; }
}

.breaking-text {
    flex: 1;
    padding-left: 30px;
    font-size: 14.5px;
    font-weight: 600;
    color: #1e293b;
}

.breaking-text marquee {
    line-height: 46px;
}

/* ==========================================================================
   4. MAIN CONTENT LAYOUT & NEWS CARDS
   -------------------------------------------------------------------------- */
.main-content {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 24px;
    max-width: 1400px;
    margin: 24px auto;
    padding: 0 20px;
    align-items: start;
}

.news-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.news-card {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: #1e293b;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: 0 2px 6px rgba(0,0,0,0.04);
    height: 280px;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.08);
    border-color: #cbd5e1;
}

.news-image {
    width: 100%;
    height: 175px;
    background: #f1f5f9;
    overflow: hidden;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.4s ease;
}

.news-card:hover .news-image img {
    transform: scale(1.05);
}

.news-content {
    height: 105px;
    padding: 12px 14px;
    display: flex;
    align-items: flex-start;
}

.news-content h3 {
    font-size: 14.5px;
    line-height: 1.4;
    margin: 0;
    font-weight: 600;
    color: #0f172a;
    display: -webkit-box;
    -webkit-line-clamp: 3;    
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-content p {
    display: none;
}

/* ==========================================================================
   5. TRENDING SIDEBAR
   -------------------------------------------------------------------------- */
.trending-sidebar {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0,0,0,0.06);
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
}

.trending-title {
    background: linear-gradient(135deg, #d31027 0%, #990000 100%);
    color: #ffffff;
    padding: 16px;
    font-size: 17px;
    font-weight: 800;
    text-align: center;
    letter-spacing: 0.5px;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(211, 16, 39, 0.3);
}
.trending-sidebar-scroll {
    max-height: 350px !important; /* यहाँ आप अपने हिसाब से height कम-ज्यादा कर सकते हैं ताकि साढ़े तीन खबरें ही दिखें */
    overflow-y: auto !important;
    scrollbar-width: thin;
    padding: 8px;
    box-sizing: border-box;
}

/* स्क्रॉल बार को सुंदर और मॉडर्न दिखने के लिए */
.trending-sidebar-scroll::-webkit-scrollbar {
    width: 6px;
}

.trending-sidebar-scroll::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 10px;
}

.trending-sidebar-scroll::-webkit-scrollbar-thumb {
    background: #d31027;
    border-radius: 10px;
}

.trending-item {
    background: #ffffff;
    border: 1px solid #edf2f7;
    border-radius: 10px;
    margin-bottom: 10px;
    transition: all 0.25s ease;
    box-sizing: border-box;
}

.trending-item:hover {
    background-color: #f8fafc;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    border-color: #cbd5e1;
}

.trending-item a {
    display: flex;
    gap: 14px;
    padding: 10px;
    text-decoration: none;
    color: inherit;
    align-items: center;
}

.trending-image {
    width: 115px;      
    height: 72px;      
    flex-shrink: 0;
    overflow: hidden;
    border-radius: 8px;
    background: #f1f5f9;
}

.trending-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.3s ease;
}

.trending-item:hover .trending-image img {
    transform: scale(1.05);
}

.trending-text {
    flex: 1;
}

.trending-text h4 {
    margin: 0;
    font-size: 14.5px;  
    line-height: 1.35;
    font-weight: 700;
    color: #1e293b;
    display: -webkit-box;
    -webkit-line-clamp: 3;   
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ==========================================================================
   6. SHORTS VIDEOS SECTION
   -------------------------------------------------------------------------- */
.short-section {
    padding: 30px 20px;
    background: #ffffff;
    margin-top: 40px;
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    border-top: 1px solid #e2e8f0;
    clear: both;
}

.short-section h2 {
    margin-bottom: 20px;
    font-size: 20px;
    color: #0f172a;
    font-weight: 700;
}

.short-slider {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    padding-bottom: 12px;
    scrollbar-width: thin;
    scroll-snap-type: x mandatory;
}

.short-slider::-webkit-scrollbar {
    height: 5px;
}

.short-slider::-webkit-scrollbar-thumb {
    background-color: #cbd5e1;
    border-radius: 10px;
}

.short-card {
    flex: 0 0 calc((100% - (16px * 8)) / 9);
    min-width: 130px;
    text-decoration: none;
    display: block;
    scroll-snap-align: start;
}

.short-thumb-wrapper img {
    transition: transform 0.3s ease;
    border-radius: 10px;
    object-fit: cover;
}

.short-card:hover .short-thumb-wrapper img {
    transform: scale(1.03);
}

/* ==========================================================================
   7. PREMIUM DARK MODE (Updated for HTML & Body Selectors)
   -------------------------------------------------------------------------- */
body.dark, 
html.dark body {
    background: #090d16 !important;
    color: #f1f5f9 !important;
}

html.dark .top-utility-bar,
body.dark .top-utility-bar {
    background: #030712;
}

html.dark .top-header,
body.dark .top-header {
    background: linear-gradient(135deg, #660000 0%, #990000 50%, #400000 100%) !important;
    border-bottom-color: #e6b800;
}

html.dark nav,
html.dark #stickyNav,
body.dark nav,
body.dark #stickyNav {
    background: #030712 !important;
    border-bottom: 1px solid #1e293b !important;
}

html.dark .logo,
html.dark .nav-links a,
body.dark .logo,
body.dark .nav-links a {
    color: #ffffff !important;
}

html.dark .search-box input,
body.dark .search-box input {
    background: transparent;
    color: #fff;
}

html.dark .search-box,
body.dark .search-box {
    background: #1e293b;
}

html.dark .search-box button,
body.dark .search-box button {
    background: #0f172a;
}

html.dark .breaking-bar,
body.dark .breaking-bar {
    background: #0f172a !important;
    border-bottom-color: #1e293b !important;
}

html.dark .breaking-label,
body.dark .breaking-label {
    background: linear-gradient(135deg, #cc0000 0%, #770000 100%) !important;
}

html.dark .breaking-label::after,
body.dark .breaking-label::after {
    border-top-color: #770000 !important;
}

html.dark .breaking-text,
body.dark .breaking-text {
    color: #e2e8f0 !important;
}

html.dark .news-card,
html.dark .paper-card,
body.dark .news-card,
body.dark .paper-card {
    background: #0f172a;
    border-color: #1e293b;
}

html.dark .news-card:hover,
html.dark .paper-card:hover,
body.dark .news-card:hover,
body.dark .paper-card:hover {
    border-color: #334155;
    box-shadow: 0 10px 20px rgba(0,0,0,0.5);
}

html.dark .news-image,
html.dark .paper-thumbnail,
body.dark .news-image,
body.dark .paper-thumbnail {
    background: #030712 !important;
}

html.dark .news-content,
html.dark .paper-details,
body.dark .news-content,
body.dark .paper-details {
    background: #0f172a;
}

html.dark .news-content h3,
html.dark .paper-details h3,
body.dark .news-content h3,
body.dark .paper-details h3 {
    color: #f1f5f9 !important;
}

html.dark .sleek-category-header,
body.dark .sleek-category-header {
    border-bottom-color: #334155;
}

html.dark .sleek-category-header h2,
body.dark .sleek-category-header h2 {
    color: #ffffff !important;
}

html.dark .trending-sidebar,
body.dark .trending-sidebar {
    background-color: #111318 !important;
    border-color: #242731 !important;
}

html.dark .trending-title,
body.dark .trending-title {
    background: #8b0000 !important;
}

html.dark .trending-item,
body.dark .trending-item {
    background-color: #17191f !important;
    border-color: #242731 !important;
}

html.dark .trending-item:hover,
body.dark .trending-item:hover {
    background-color: #1e222d !important;
    border-color: #334155 !important;
}

html.dark .trending-item a,
body.dark .trending-item a {
    color: #f1f5f9 !important;
}

html.dark .trending-item h4,
body.dark .trending-item h4 {
    color: #f1f5f9 !important;
}

html.dark .trending-sidebar-scroll::-webkit-scrollbar-track,
body.dark .trending-sidebar-scroll::-webkit-scrollbar-track {
    background: #111318;
}

html.dark .trending-sidebar-scroll::-webkit-scrollbar-thumb,
body.dark .trending-sidebar-scroll::-webkit-scrollbar-thumb {
    background: #8b0000;
}

html.dark .short-section,
body.dark .short-section {
    background: #090d16;
    border-top-color: #1e293b;
}

html.dark .short-section h2,
body.dark .short-section h2 {
    color: #fff;
}

/* ==========================================================================
   8. RESPONSIVE MEDIA QUERIES
   -------------------------------------------------------------------------- */
@media(max-width: 1024px) {
    .main-content {
        grid-template-columns: 1fr 340px !important;
        gap: 20px;
    }
    .news-container {
        display: grid !important;
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 16px !important;
    }
    .nav-links li a {
        padding: 12px 10px !important;
        font-size: 13px !important;
    }
}

@media(max-width: 768px) {
    .top-header {
        flex-direction: column;
        padding: 15px;
        gap: 15px;
    }

    .right-side {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
    }

    .search-box {
        max-width: 220px;
    }

    .search-box input {
        width: 140px;
        padding: 8px 12px;
        font-size: 13px;
    }

    .search-box button {
        padding: 8px 14px;
    }

    .menu-btn {
        display: block;
    }

    .nav-links {
        display: none;
        flex-direction: column;
        width: 100%;
        background: #0b1329;
    }

    .nav-links.active {
        display: flex;
    }

    .main-content {
        grid-template-columns: 1fr !important;
    }

    .news-container {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 16px !important;
        width: 100% !important;
    }

    .news-card {
        width: 100% !important;
        max-width: 100% !important;
        height: auto !important;
        display: flex !important;
        flex-direction: column !important;
    }

    .news-image {
        width: 100% !important;
        height: auto !important;
        background: #0f172a;
    }

    .news-image img {
        width: 100% !important;
        height: auto !important;
        object-fit: contain !important;
    }

    .news-content {
        width: 100% !important;
        height: auto !important;
        padding: 12px;
    }

    .news-content h3 {
        font-size: 15px !important;
        line-height: 1.4;
    }

    .trending-sidebar-scroll {
        max-height: 400px !important; 
    }
}

@media(max-width: 480px) {
    .top-header {
        padding: 10px 12px;
    }

    .logo {
        font-size: 24px !important;
    }

    .right-side {
        gap: 10px;
    }

    .search-box {
        max-width: 160px;
    }

    .search-box input {
        width: 100px;
        padding: 6px 10px;
        font-size: 12px;
    }

    .search-box button {
        padding: 6px 10px;
        font-size: 12px;
    }

    #theme-btn {
        padding: 6px 12px;
        font-size: 12px;
    }

    .news-container {
        display: grid !important;
        grid-template-columns: 1fr !important;
        width: 100% !important;
    }
    
    .news-card {
        width: 100% !important;
        max-width: 100% !important;
    }

    .breaking-label {
        padding: 0 12px;
        font-size: 12px;
    }
}

