/* ... Previous Styles ... */
/* Existing styles preserved, just adding/modifying off-canvas */

/* Navigation Container */
.nav-wrapper {
    position: -webkit-sticky;
    /* Safari */
    position: sticky;
    top: 0;
    z-index: 99999;
    /* Ultra high to stay above everything */
    width: 100%;
    background-color: #434344;
    /* Ensure it has background when stuck */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}


/* Fix sticky context */
body,
html {
    overflow-x: clip;
    overflow-y: visible;
}

.site-header {
    overflow: visible;
}

.nagarikpana-navbar {
    background-color: #434344;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    position: relative;
    z-index: 999;
}

.nagarikpana-navbar .container {
    display: flex;
    align-items: center;
    height: 50px;
    padding: 0 15px;
}

/* Sticky Logo Styling */
.sticky-nav-logo {
    display: none;
    /* Hidden by default */
    align-items: center;
    justify-content: center;
    height: 100%;
    align-self: stretch;
    background-color: #fff;
    padding: 0 15px;
    margin-right: 0;
    /* Remove gap between logo and menu icon */
}

.sticky-nav-logo img {
    max-height: 40px;
    width: auto;
}

.nav-wrapper.is-stuck .sticky-nav-logo {
    display: flex;
    /* Show when scrolled */
}

.home-icon {
    background: #e11b22;
    color: #fff;
    padding: 0 15px;
    height: 100%;
    align-self: stretch;
    display: flex;
    align-items: center;
    justify-content: center;
    /* Center horizontally */
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    margin-right: 0;
}

.home-icon .dashicons {
    font-size: 28px;
    width: auto;
    height: auto;
}

.home-icon:hover,
.home-icon.active-home {
    background: #434344;
    color: #fff;
}

.menu-container {
    flex-grow: 1;
    height: 100%;
}

.menu-container.hide-on-mobile {
    display: block;
}

.nagarikpana-navbar .menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    height: 100%;
}

.nagarikpana-navbar .menu>li {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
}

.nagarikpana-navbar .menu>li>a {
    color: #fff;
    padding: 0 15px;
    font-weight: 600;
    font-size: 19px;
    text-decoration: none;
    height: 100%;
    display: flex;
    align-items: center;
    transition: color 0.3s;
}

.nagarikpana-navbar .menu>li>a:hover,
.nagarikpana-navbar .menu>li.current-menu-item>a,
.nagarikpana-navbar .menu>li.current-menu-ancestor>a,
.nagarikpana-navbar .menu>li.current_page_item>a {
    color: #fff;
    background-color: #000;
}

/* Second to last menu item special styling */
.nagarikpana-navbar .menu>li:nth-last-child(2)>a {
    background: #0d4776;
    color: #fff;
}

.nagarikpana-navbar .menu>li:nth-last-child(2)>a:hover {
    background: #093355;
    color: #fff;
}

.nagarikpana-navbar .menu-item-has-children>a,
.nagarikpana-navbar .page_item_has_children>a {
    padding-right: 32px !important;
}

.nagarikpana-navbar .menu-item-has-children>a::after,
.nagarikpana-navbar .page_item_has_children>a::after {
    content: "\f347";
    font-family: "dashicons";
    font-size: 17px;
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.8;
}

.nagarikpana-navbar .sub-menu,
.nagarikpana-navbar .children {
    display: none;
    position: absolute;
    top: 50px;
    left: 0;
    background: #fff;
    min-width: 200px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 0;
    list-style: none;
    z-index: 1000;
}

.nagarikpana-navbar .menu>li:hover .sub-menu,
.nagarikpana-navbar .menu>li:hover .children {
    display: block;
}

.nagarikpana-navbar .sub-menu li a,
.nagarikpana-navbar .children li a {
    color: #1a1a1a;
    padding: 12px 20px;
    display: block;
    border-bottom: 1px solid #f0f0f0;
    height: auto;
    font-size: 17px;
}

.nagarikpana-navbar .sub-menu li a:hover,
.nagarikpana-navbar .children li a:hover {
    background: #f9f9f9;
    color: var(--primary-color);
    padding-left: 25px;
}

.nav-right-icons {
    display: flex;
    align-items: center;
    margin-left: auto;
}

.nav-right-icons .nav-icon-link {
    color: #fff;
    background: none;
    border: none;
    padding: 0 15px;
    height: 50px;
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 20px;
    transition: color 0.3s;
}

.online-tv-btn {
    background-color: #e11b22;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    padding: 0 15px;
    height: 50px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background-color 0.3s;
    font-size: 16px;
}

.online-tv-btn:hover {
    background-color: #c4000a;
    color: #fff;
}

.nav-right-icons .menu-toggle-desktop {
    color: #fff;
    background-color: #e11b22;
    border: none;
    padding: 0 15px;
    height: 50px;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 20px;
    transition: background-color 0.3s ease;
}

.nav-right-icons .nav-icon-link:hover {
    color: #e11b22;
}

.nav-right-icons .menu-toggle-desktop:hover {
    background-color: #ff4d53;
    /* Lighter red */
}

.nav-right-icons .dashicons {
    font-size: 24px;
    width: 24px;
    height: 24px;
}

.menu-toggle {
    display: none;
}

.trending-bar {
    background: #fdfdfd;
    border-bottom: 1px solid #eaeaea;
    padding: 12px 0;
    box-shadow: inset 0 -1px 3px rgba(0, 0, 0, 0.02);
}

.trending-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.trending-left {
    display: flex;
    align-items: center;
    flex-grow: 1;
}

.trending-label {
    font-weight: 700;
    color: var(--secondary-color);
    margin-right: 20px;
    font-size: 16px;
    white-space: nowrap;
    display: flex;
    align-items: center;
}

.trending-label i {
    margin-right: 8px;
    font-size: 15px;
    animation: pulse-fire 2s infinite ease-in-out;
}

@keyframes pulse-fire {
    0% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.7;
        transform: scale(1.15);
    }

    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.trending-tags {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}

.trending-tags a {
    color: var(--text-dark);
    font-size: 13.5px;
    font-weight: 600;
    background: #f0f2f5;
    padding: 5px 14px;
    border-radius: 20px;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.trending-tags a:hover {
    color: #fff;
    background: var(--primary-color);
    box-shadow: 0 4px 8px rgba(1, 32, 82, 0.2);
    transform: translateY(-2px);
}

.trending-right-search {
    width: 280px;
    position: relative;
}

.header-search-form {
    display: flex;
    border: 1px solid #e0e0e0;
    border-radius: 25px;
    overflow: hidden;
    background: #fff;
    transition: all 0.3s ease;
}

.header-search-form:focus-within {
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(225, 27, 34, 0.1);
}

.header-search-form .search-field {
    border: none;
    padding: 10px 15px;
    width: 100%;
    font-size: 14px;
    outline: none;
    background: transparent;
}

.header-search-form .search-submit {
    background: transparent;
    border: none;
    color: var(--primary-color);
    padding: 0 15px;
    cursor: pointer;
    transition: color 0.3s;
}

.header-search-form .search-submit:hover {
    color: var(--secondary-color);
}

/* --- OFF-CANVAS / DRAWERS --- */

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    display: none;
}

/* Generic Side Drawer Class */
.side-drawer {
    position: fixed;
    top: 0;
    right: -350px;
    /* Hidden off-screen */
    width: 320px;
    max-width: 80%;
    height: 100%;

    background: #fff;
    z-index: 9999;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
    transition: right 0.3s ease;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.side-drawer.active {
    right: 0;
}

/* Main Menu Drawer Specifics */
.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    border-bottom: 2px solid #434344;
    background: #8f8f8f;
}

.mobile-logo img {
    max-height: 40px;
    width: auto;
}

.side-drawer-close {
    background: #434344;
    color: #fff;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-menu-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.mobile-menu-list li {
    border-bottom: 1px solid #f5f5f5;
}

.mobile-menu-list li a {
    display: block;
    padding: 15px 20px;
    color: #333;
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    position: relative;
}

.mobile-menu-list li a:hover {
    background: #f9f9f9;
    color: var(--primary-color);
}



.mobile-menu-list .menu-item-has-children>a::after {
    content: "\f347";
    font-family: "dashicons";
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 12px;
}

.mobile-menu-list .sub-menu,
.mobile-menu-list .children {
    display: none;
    background: #f9f9f9;
    padding-left: 0;
    list-style: none;
}

.mobile-menu-list .sub-menu li a {
    padding-left: 40px;
    font-size: 15px;
    border-bottom: 1px solid #eee;
}

.mobile-menu-list li.submenu-open>.sub-menu {
    display: block;
}

/* Updates Drawer Specifics (For Latest Posts) */
.updates-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    padding: 0;
    border-bottom: 1px solid #ddd;
}

.updates-tabs {
    display: flex;
    flex-grow: 1;
}

.tab-btn {
    flex: 1;
    background: #f1f1f1;
    border: none;
    padding: 15px 0;
    font-family: var(--font-primary);
    font-weight: 700;
    font-size: 16px;
    cursor: pointer;
    color: #666;
    border-bottom: 3px solid transparent;
}

.tab-btn.active {
    background: #fff;
    color: #e11b22;
    /* Reddish color for active tab as per screenshot */
    border-bottom-color: #e11b22;
}

.side-drawer-close.from-updates {
    background: #e11b22;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    margin: 0 10px;
}

.updates-body {
    padding: 0;
    flex-grow: 1;
    overflow-y: auto;
    background: #f9f9f9;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.updates-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.updates-list li {
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
    background: #fff;
    display: flex;
    align-items: flex-start;
}

.update-count {
    font-size: 40px;
    color: #cbdceb;
    line-height: 1;
    margin-right: 15px;
    font-weight: 400;
    min-width: 30px;
}

.updates-list li a {
    text-decoration: none;
    color: #333;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.4;
}

.updates-list li a:hover {
    color: var(--primary-color);
}

/* Update Thumbnails hidden by default on mobile */
.update-thumb {
    display: none;
}

/* Desktop override for updates drawer to act as a mega menu */
@media (min-width: 992px) {
    .updates-drawer {
        top: 50px;
        right: auto;
        left: 50%;
        height: auto;
        max-height: calc(100vh - 50px);
        width: 100%;
        max-width: 1140px;
        /* Match standard container */
        box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
        border-radius: 0 0 8px 8px;
        opacity: 0;
        visibility: hidden;
        transform: translate(-50%, -20px) !important;
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
        background: #f4f5f7;
        /* Very light grey */
    }

    .updates-drawer.active {
        right: auto !important;
        opacity: 1;
        visibility: visible;
        transform: translate(-50%, 0) !important;
    }

    /* Redesign Header */
    .updates-header {
        background: transparent;
        padding: 20px 30px 0;
        border-bottom: 1px solid #e0e0e0;
    }

    .updates-tabs {
        flex-grow: 1;
    }

    .tab-btn {
        background: transparent;
        color: #434344;
        /* Classic news blue */
        font-size: 24px;
        padding: 0 10px 15px;
        margin-right: 20px;
        border-bottom: 3px solid transparent;
        flex: 0 0 auto;
    }

    .tab-btn.active {
        background: transparent;
        color: #434344;
        border-bottom-color: #e11b22;
    }

    .side-drawer-close.from-updates {
        background: transparent;
        color: #434344;
        border: 1px solid #434344;
        border-radius: 50%;
        width: 28px;
        height: 28px;
        display: flex;
        align-items: center;
        justify-content: center;
        margin-bottom: 15px;
    }

    .side-drawer-close.from-updates .dashicons {
        color: #434344;
        font-size: 16px;
        width: 16px;
        height: 16px;
    }

    /* Redesign Body & Grid */
    .updates-body {
        background: transparent;
        padding: 30px;
        overflow-x: hidden;
    }

    .updates-list {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        column-gap: 40px;
        row-gap: 20px;
    }

    .updates-list li {
        background: transparent;
        border: none;
        padding: 10px 0;
        border-bottom: 1px dashed #ccc;
        align-items: center;
        justify-content: space-between;
        height: 76px;
        /* Force consistent height to prevent layout shift */
        box-sizing: border-box;
    }

    .update-count {
        font-size: 36px;
        color: #92b8d4;
        flex: 0 0 35px;
        margin-right: 15px;
        line-height: 1;
    }

    .update-link {
        flex: 1;
        font-size: 17px;
        font-weight: 500;
        padding-right: 10px;
        color: #333;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        line-height: 1.4;
    }

    .update-link:hover {
        color: #e11b22;
    }

    .update-thumb {
        display: block;
        flex: 0 0 80px;
        height: 55px;
        border-radius: 4px;
        overflow: hidden;
    }

    .update-thumb img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
}

/* Responsive Adjustments */
@media (max-width: 991px) {
    .menu-container.hide-on-mobile {
        display: none;
    }

    .menu-toggle {
        display: block;
        background: none;
        border: none;
        color: #fff;
        font-size: 24px;
        margin-left: auto;
    }

    .nav-right-icons .menu-toggle-desktop {
        display: flex;
        margin-left: 10px;
    }

    .nav-right-icons {
        display: flex;
        margin-left: auto;
    }


    .trending-bar {
        display: none;
    }

    /* Full width drawer on mobile */
    .side-drawer {
        width: 100%;
        max-width: 100%;
        right: -100%;
        /* Fully hide off screen */
    }
}

/* --- ARTHA DRAWER STYLES --- */
.artha-drawer {
    right: auto !important;
    left: -100%;
    width: 85%;
    max-width: 350px;
    background: #e9e9e9;
    display: flex;
    flex-direction: column;
}

.artha-drawer.active {
    left: 0;
    right: auto !important;
}

.artha-drawer-header {
    background: #434344;
    justify-content: flex-start;
    position: relative;
    padding: 15px;
    border-bottom: 3px solid #e11b22;
}

.artha-drawer-header .mobile-logo {
    background: #fff;
    border-radius: 4px;
    padding: 5px 15px;
    display: inline-block;
}

.artha-drawer-header .mobile-logo img {
    max-height: 55px;
}

.artha-drawer-header .side-drawer-close {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    color: #fff;
    border: none;
    font-size: 24px;
}

.drawer-search-container {
    background: #f5f8fa;
    padding: 15px;
    border-bottom: 1px solid #e1e8ed;
}

.drawer-search-form {
    display: flex;
    position: relative;
    background: #fff;
    border-radius: 20px;
    border: 1px solid #d1d9e0;
    overflow: hidden;
}

.drawer-search-field {
    width: 100%;
    background: transparent;
    border: none;
    color: var(--text-dark);
    font-size: 15px;
    outline: none;
    padding: 8px 35px 8px 15px;
}

.drawer-search-field::placeholder {
    color: #999;
}

.drawer-search-submit {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: #e11b22;
    cursor: pointer;
    padding: 5px;
}

.artha-menu-body {
    flex-grow: 1;
    overflow-y: auto;
    background: #ffffff;
}

.artha-menu-body .mobile-menu-list li {
    border-bottom: 1px solid #f0f0f0;
}

.artha-menu-body .mobile-menu-list li a {
    color: var(--text-dark);
    font-weight: 600;
    font-size: 17px;
    padding: 14px 20px;
    border-left: 3px solid transparent;
    transition: all 0.2s ease;
}

.artha-menu-body .mobile-menu-list li a:hover {
    background: #f8f9fa;
    color: #e11b22;
    border-left-color: #e11b22;
}

.drawer-footer-actions {
    background: #f5f5f5;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    gap: 10px;
    border-top: 1px solid #e0e0e0;
}

.drawer-btn {
    flex: 1;
    color: #fff;
    text-align: center;
    padding: 10px 0;
    border-radius: 4px;
    font-weight: 600;
    font-size: 15px;
    text-decoration: none;
    transition: background 0.3s;
}

.drawer-btn:first-child {
    background: #434344;
}

.drawer-btn:first-child:hover {
    background: #333333;
    color: #fff !important;
}

.drawer-btn:last-child {
    background: #e11b22;
}

.drawer-btn:last-child:hover {
    background: #c62828;
    color: #fff !important;
}