* {
    padding: 0;
    margin: 0;
    scrollbar-width: none;
    box-sizing: border-box;
    font-family: "Times New Roman", Times, serif;
}

body {
    padding: 0;
    scrollbar-width: none;
    margin: 0;
}

header {
    background: white;
    height: 60px;
    padding: 0 20px;
    padding-left: 10px;
    border-bottom: 1px solid #d1d5db;
    width: 100%;
    display: flex;
    align-items: start;
    justify-content: space-between;
    position: fixed;
    top: 0;
    z-index: 1000;
}

.logo-area {
    display: flex;
    align-items: end;
    gap: 8px;
    font-style: italic;
    font-weight: bold;
    font-size: 25px;
    color: #2c3e50;
    min-width: fit-content;
}

nav {
    display: flex;
    gap: 20px;
}

nav a {
    text-decoration: none;
    color: #555;
    font-size: 20px;
}

/* आपके पुराने कोड में केवल एक लाइन (position: relative) जोड़ी है */
.search-container {
    flex-grow: 0.4;
    display: flex;
    background: #f0f2f5;
    border-radius: 20px;
    padding: 5px 15px;
    position: relative; /* इसके अंदर के रिजल्ट बॉक्स को अलाइन करने के लिए ज़रूरी है */
}
.search-box {
    position: relative; /* इसके अंदर के रिजल्ट बॉक्स को नीचे फिक्स करने के लिए */
    width: 100%;        /* पूरी चौड़ाई लेगा */
    display: block;     /* flex हटा दिया ताकि रिजल्ट बॉक्स बगल में जगह न घेरे */
}
#searchInput {
    width: 100% !important;
    display: block;
}
.search-container input {
    border: none;
    background: transparent;
    outline: none;
    padding: 5px;
    width: 100%;
}

.search-container i {
    color: #888;
    align-self: center;
}

#resultsBox {
    position: absolute;
    top: 100%;          /* इनपुट बॉक्स के ठीक नीचे से शुरू होगा */
    left: 0;
    width: 100%;        /* इनपुट बॉक्स जितनी ही पूरी चौड़ाई लेगा */
    height: 300px;      /* फिक्स्ड हाइट */
    
    /* दोनों स्क्रॉल बार हमेशा चालू रहेंगे */
    overflow-y: scroll !important; 
    overflow-x: scroll !important; 

    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    border: 1px solid #eee;
    z-index: 999;       /* ताकि यह बाकी सभी एलिमेंट्स के ऊपर तैरता हुआ दिखे */
}

/* रिजल्ट के अंदर के आइटम्स की स्टाइलिंग */
.result-item {
    padding: 10px 15px;
    cursor: pointer;
    border-bottom: 1px solid #f0f2f5;
    white-space: nowrap !important;
    width: max-content !important;
    min-width: 100%;
    display: block;
}


.result-item:hover {
    background: #f9fafb;
}

/* छुपाने के लिए क्लास */
.hidden {
    display: none !important;
}


header img {
    width: 30px;
    height: 30px;
    transform: skewX(-12deg);
}

.header-actions {
    display: flex !important;
    /* row-reverse se aakhiri element (Dashboard) pehle dikhega */
    flex-direction: row-reverse !important;
    align-items: center !important;
    justify-content: flex-end !important;
    /* Right side mein chipka rahega */
    gap: 15px !important;
    width: auto !important;
}


.icon-btn {
    font-size: 1.2rem;
    color: #555;
    cursor: pointer;
    position: relative;
}

.auth-btns {
    display: flex;
    gap: 10px;
}

.btn {
    padding: 8px 18px;
    border-radius: 5px;
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
}

.btn-signin {
    background: transparent;
    border: 1px solid #3776ab;
    color: #3776ab;
}

.btn-login {
    background: #3776ab;
    color: white;
}

.btn-dashboard {
    background: #3776ab;
    color: white;
    text-decoration: none;
}

/* 🔔 Bell Fix: Fixed se hata kar Relative kiya */
#bellBtn {
    position: relative;
    font-size: 25px;
    cursor: pointer;
    display: flex;
    align-items: center;
    margin: 0 !important;
}

#bellBadge {
    position: absolute;
    top: -2px;
    right: -2px;
    background: #ef4444;
    color: white;
    font-size: 10px;
    padding: 2px 5px;
    border-radius: 50%;
    border: 2px solid white;
}

.auth-btns {
    display: flex;
    gap: 8px;
    margin: 0 !important;
}

#notificationBox {
    position: absolute;
    top: 55px;
    right: 20px;
    width: 300px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    display: none;
    flex-direction: column;
    border: 1px solid #eee;
}

.box-header {
    padding: 10px;
    border-bottom: 1px solid #ddd;
    display: flex;
    justify-content: space-between;
}

#notificationList {
    max-height: 400px;
    overflow-y: auto;
}

.notification-item {
    padding: 10px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
}

.notification-item:hover {
    background: #f9fafb;
}

.empty {
    padding: 20px;
    text-align: center;
    color: gray;
}


/* course section */

.courses {
    height: 30px;
    width: 100%;
    position: fixed;
    background: #f8fafc;
    display: flex;
    overflow-x: auto;
    align-items: center;
    gap: 10px;
    border: 1px solid #d1d5db;
    border-top: none;
    top: 60px;
    scrollbar-width: none;
    z-index: 999;
    border-left: none;
    border-right: none;
}

.courses a {
    display: inline-flex; /* Isse anchor ke andar ka text bhi center ho jayega */
    align-items: center;  
    padding:2px 13px; 
    text-decoration: none;
    background: #e5e7eb;
    margin-left: 10px;
    color: black; 
    border-radius: 1px; 
}


/* sidebar  section */

.sidebar button {
    width: 100%;
    text-align: left;
    padding: 9px 0px;
    border-top: none;
    background: whitesmoke;
    font-size: 15px;
    cursor: pointer;
    border-left: none;
    border-right: none;
    border-bottom:none;
    padding-left: 15px;

}
#active{
    padding: 12px 12px;
    padding-left: 15px;

}
.sidebar.active {
    left: 0;
}

.sidebar li {
    padding: 8px 10px;
    color: black;
    font-weight: bold;
    font-size: 22px;
    text-align: center;
    list-style-type: none;
    border-bottom: 1px solid black;
}

.sidebar .space button {
    border: none;
}

/* content section */

.sidebar {
    position: fixed;
    width: 270px;
    height: 100vh;
    overflow-y: auto;
    font-size: 18px;
    padding-top: 10px;
    box-sizing: border-box;
    background: whitesmoke;
    color: white;
    border: 1px solid black; 
    border-top: none;
    transition: left 0.3s ease;
    z-index: 999;
}


.sidebar.active {
    left: 0;
}
#googleToggle{
    display: none;
    background: #3b82f6;
    color: white;
}
#active{
                background: #334155;
            color: white;
            border-left:3px solid #3776ab;
}
main { 
    background-color: white;
    width: calc(100% - 270px); 
    border-top: none;
    margin-left: 270px;  
    overflow-x: hidden;   
}
main .page-intro{
    padding-bottom:20px;
}
main .page-intro p{
padding-bottom:10px;
    position: relative;

    background: var(--white);
padding-top:35px;
    border: 1px solid #e2e8f0;
 
    margin-bottom: 40px; 

    font-size: 16px;
margin:0 !important;
    line-height: 2;

    color: var(--text);

    overflow: hidden;  
}

main .page-intro p::before{
    content: "";

    position: absolute;

    top: -80px;
    right: -80px;

    width: 180px;
    height: 180px;

    border-radius: 50%;

    background: rgba(59,130,246,0.08);
}

main .page-intro p::after{
    content: "INTRODUCTION";

    position: absolute;

    top: 18px;
    right: 24px;

    font-size: 11px;
    font-weight: 800;

    letter-spacing: 2px;

    color: var(--primary);
}

.main-chapter-header { 
    margin: -20px -20px 40px -20px;     
    padding: 35px 50px;
    background: linear-gradient(135deg, #ffffff 0%, #f1f5f9 100%); 
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
    box-sizing: border-box;
}

/* Left Section Styling */
.main-header-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.main-top-nav {
    display: flex;
    align-items: center;
    gap: 12px;
}

.main-chapter-header  .main-tag-primary {
    font-size: 11px;
    font-weight: 700;
    color: #3b82f6;
    text-transform: uppercase;
    letter-spacing: 1px;
    background: #eff6ff;
    padding: 4px 10px;
    border-radius: 6px;
    border: 1px solid #dbeafe;
}

.main-chapter-header .main-tag-secondary {
    font-size: 11px;
    font-weight: 600;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.main-tag-dot {
    color: #cbd5e1;
}

.main-chapter-title {
    margin: 0;
    font-size: 1.8rem;
    color: #0f172a;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.main-text-highlight {
    color: #3b82f6;
}

/* Right Section Buttons */
.main-header-actions {
    display: flex;
    gap: 12px;
}

.main-btn {
    cursor: pointer;
    padding: 12px 24px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.9rem;
    transition: all 0.25s ease;
    border: none;
    outline: none;
}
.main-chapter-header .main-btn-test {
    background: #3b82f6;
    color: white;     
}
 

.main-chapter-header .main-btn-practice {
    background: white;
    color: #475569;
    border: 1px solid #e2e8f0;
}
 
.main-chapter-header .main-btn-help {
    background: white;
    color: #64748b;
    font-weight: 600;
}

.main-btn-help:hover {
    background: #e2e8f0;
    color: #1e293b;
}

/* Container Logic */
.top{
    padding: 40px;

}
.main-completion-container {
    margin-top: 50px; 
    padding-bottom: 0;
    background: #ffffff;
    border: 1px solid #e2e8f0; 
    font-family: 'Segoe UI', system-ui, sans-serif;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.02);
}

.main-completion-header h2 {
    font-size: 1.6rem;
    color: #1e293b;
    margin: 0 0 10px 0;
    font-weight: 800;
}

.main-completion-header p {
    color: #64748b;
    font-size: 1rem;
    margin-bottom: 30px;
}

/* Grid Layout */
.main-completion-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

/* Individual Cards */
.main-option-card {
    padding: 30px 20px;
    border: 1px solid #f1f5f9;
    border-radius: 20px;
    background: #fafafa;
    text-align: center;
    transition: all 0.3s ease;
}

.main-option-card:hover { 
    background: #ffffff; 
    border-color: #e2e8f0;
}

.main-option-icon {
    font-size: 2rem;
    margin-bottom: 15px;
}

.main-option-title {
    margin: 0 0 8px 0;
    color: #1e293b;
    font-size: 1.1rem;
}

.main-option-desc {
    font-size: 16px;
    color: #64748b;
    text-align: center;
}

/* Button Theming */
.main-option-btn {
    display: inline-block;
    padding: 10px 24px;
    color: white;
    text-decoration: none;
    border-radius: 10px;
    font-size: 0.9rem;margin-top:10px;
    font-weight: 700;
    transition: opacity 0.2s;
}

.main-option-btn:hover { opacity: 0.9; }
.main-btn-test { background: #ef4444; }
.main-btn-practice { background: #10b981; }
.main-btn-help { background: #3b82f6; }

/* Footer */
.main-completion-footer {
    margin-top: 35px;
    padding-top: 25px;
    border-top: 1px dashed #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.main-footer-text { font-size: 0.9rem; color: #475569; }
.main-footer-link {
    color: #3b82f6;
    font-weight: 700;
    font-size: 0.95rem;
    text-decoration: none;
}

/* --- Help Strip Logic --- */
.main-help-strip {
    min-height: 80px;
    width: 100%;
    background: #ffffff;
    border: 1px solid #e2e8f0; 
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 25px;
    font-family: 'Segoe UI', sans-serif;
    box-shadow: 0 8px 20px rgba(0,0,0,0.04);
    margin: 30px 0;
    margin-bottom: 0;
    box-sizing: border-box;
}

.main-strip-left {
    display: flex;
    align-items: center;
    gap: 15px;
    border-right: 2px solid #f1f5f9;
    padding-right: 25px;
    height: 45px;
}

.main-strip-icon-box {
    background: #eff6ff;
    padding: 10px;
    border-radius: 12px;
    font-size: 25px;
}

.main-strip-text h4 { margin: 0; font-size: 17px; color: #1e293b; }
.main-strip-text p { margin: 0; font-size: 14px; color: #64748b; }

.main-strip-middle {
    display: flex;
    flex: 1;
    justify-content: space-evenly;
    align-items: center;
    padding: 0 20px;
}

.main-point {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #475569;
}

.main-check { color: #3b82f6; font-weight: 800; }

.main-strip-right {
    padding-left: 25px;
    border-left: 2px solid #f1f5f9;
    height: 45px;
    display: flex;
    align-items: center;
}

.main-ask-btn {
    background: #1e293b;
    color: white;
    text-decoration: none;
    padding: 10px 22px;
    border-radius: 10px;
    font-size: 0.85rem;
    font-weight: 700;
    transition: background 0.3s;
}

.main-ask-btn:hover { background: #334155; }
 






/* Banner 320x50 */
.ad-box {
    float: left;
    margin-right: 10px;
    margin-bottom: 0px !important; 
    padding: 0;
}

.ad-box iframe {
    display: block; 
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
    vertical-align: bottom;
}

.content-text {
    display: inline;
    vertical-align: top;
}


/* ad2  160 x 300 */
.ad2-container {
    width: 100%;
    margin: 15px 0;
    font-family: sans-serif;
}

.ad2-box {
    float: left;
    margin-right: 15px; 
} 

.ad2-clear {
    clear: both;
}
@media screen and (max-width: 380px) {
    .ad2-box {
        float: left !important;
        transform: scale(0.8) !important;
        transform-origin: left top !important;
        width: 160px !important;  
        height: 300px !important;
        margin-right: -25px !important; 
        margin-bottom: -55px !important;
    }
}
.ad2a-container {
    display: flex;
    flex-direction: row-reverse; 
    flex-wrap: nowrap;           
    gap: 15px;
    width: 100%;
    margin: 15px 0;
    font-family: sans-serif;
    align-items: flex-start;
}

.ad2a-box {
    flex-shrink: 0;             
    width: 160px;               
}

 
.ad2a-content {
    flex-grow: 1;            
    min-width: 200px;        
}

.ad2a-clear {
    display: none;     
}

@media screen and (max-width: 680px) { 
    .ad2a-container {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        width: 100% !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        -webkit-overflow-scrolling: touch;
    }

    .ad2a-content {
        order: 1 !important;              
        flex: 0 0 100% !important;       
        width: 100% !important;
        min-width: 100% !important;
        box-sizing: border-box !important;
        padding: 0 10px !important;
    }

    .ad2a-box {
        order: 2 !important;         
        flex: 0 0 160px !important;    
        width: 160px !important;
        min-width: 160px !important; /* Force width */
        margin-left: 15px !important;  
        margin-right: 15px !important; /* Ye scroll area ko end mein space dega */
        display: block !important;    /* Ensure visible */
    }

    .codebox {
        width: 100% !important;
    }
}



/* ad3 160x600  */
.ad3-container {
    width: 100%;
    overflow: hidden;  
    margin-top: 10px;
}

.ad3-box {
    float: left;  
    width: 160px;
    height: 600px;
    margin-right: 15px;
    margin-bottom: 0px;
    background-color: transparent;  
}

.ad3-content {
    display: block;
    line-height: 1.6;
    font-size: 16px;
    word-wrap: break-word;
}
@media screen and (max-width: 480px) {
    .ad3-box {
        float: left !important;
        transform: scale(0.7) !important;
        transform-origin: left top !important;
        width: 160px !important; 
        height: 600px !important;
        margin-right: -45px !important; 
        margin-bottom: -180px !important; 
    }
} 
.ad3a-container {
    display: flex;
    flex-direction: row-reverse;
    flex-wrap: nowrap;
    gap: 15px;
    align-items: flex-start;
    width: 100%;
    margin-top: 10px;
}

.ad3a-content {
    flex-grow: 1;
    min-width: 250px;
}

.ad3a-box {
    flex-shrink: 0;
    width: 160px;
}
 
@media screen and (max-width: 680px) {
    .ad3a-container {
        flex-direction: row !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch; 
        margin-bottom: 20px; 
    }

    .ad3a-content {
        order: 1 !important;
        flex: 0 0 100% !important;
        width: 100% !important;
        min-width: 100% !important;
        box-sizing: border-box;
        padding-right: 5px; 
        padding-left:5px;
    }

    .ad3a-box {
        order: 2 !important;
        flex: 0 0 160px !important;
        width: 160px !important; 
        transform-origin: left top;
        margin-left: 10px; 
        margin-bottom: -120px !important; 
    }
    
    .codebox {
        width: 100% !important;
        overflow-x: auto !important;
    }
}




/* ad4 Banner 300x250 */
.ad4-wrapper {
    width: 100%;
    margin-top: 15px;
    display: block;
}

.ad4-box {
    float: left !important;
    width: 300px !important;
    height: 250px !important;
    margin-right: 15px !important;
    line-height: 0;
    display: block;
}

.ad4-text-area {
    display: block;
    font-size: 16px;
    color: #333;
}
 
.ad4-wrapper::after {
    content: "";
    display: table;
    clear: both;
}
 
@media screen and (max-width: 500px) {
    .ad4-box {
        float: left !important;
        transform: scale(0.42) !important;
        transform-origin: left top !important;
        width: 300px !important;
        height: 250px !important;
        margin-right: -165px !important; 
        margin-bottom: -140px !important;
    }
}

@media screen and (min-width: 501px) and (max-width: 1050px) {
    .ad4-box {
        float: left !important;
        display: block !important;
        
        transform: scale(0.65) !important;
        transform-origin: left top !important; 
 
        width: 195px !important; 
        height: 162px !important;

        margin: 0 15px 10px 0 !important;
        padding: 0 !important;
    }
 
    .ad4-box + * { 
        display: inline;
    }
}
 


.ad4r-wrapper {
    width: 100%;
    margin-top: 15px;
    display: block;
}

.ad4r-box {
    float: right !important;
    width: 300px !important;
    height: 250px !important;
    margin-right: 15px !important;
    line-height: 0;
    display: block;
}

.ad4r-text-area {
    display: block;
    font-size: 16px;
    color: #333;
}
 
.ad4r-wrapper::after {
    content: "";
    display: table;
    clear: both;
}
 
@media screen and (max-width: 500px) {
    .ad4r-box {
        float: right !important;
        transform: scale(0.42) !important;
        transform-origin: left top !important;
        width: 300px !important;
        height: 250px !important;
        margin-right: -165px !important; 
        margin-bottom: -140px !important;
    }
}

@media screen and (min-width: 501px) and (max-width: 1050px) {
    .ad4r-box {
        float: right !important;
        display: block !important;
        
        transform: scale(0.65) !important;
        transform-origin: left top !important; 
 
        width: 195px !important; 
        height: 162px !important;

        margin: 0 15px 10px 0 !important;
        padding: 0 !important;
    }
 
    .ad4r-box + * { 
        display: inline;
    }
}


.ad4a-wrapper {
    display: flex;
    flex-direction: row-reverse; /* Editor Left, Ad Right */
    gap: 15px;
    width: 100%;
    margin-top: 15px;
    align-items: flex-start;
}

.ad4a-text-area {
    flex: 1;
    min-width: 0;
}

.ad4a-box {
    flex: 0 0 300px;
    width: 300px;
    height: 250px;
}

/* Mobile (480px and below) */
@media screen and (max-width: 680px) {
    .ad4a-wrapper {
        flex-direction: row !important; /* Visual order fix for mobile */
        overflow-x: auto !important;    /* Horizontal scroll enable */
        flex-wrap: nowrap !important;
        -webkit-overflow-scrolling: touch;
        gap: 0px !important;
    }

    .ad4a-text-area {
        order: 1 !important;
        flex: 0 0 100% !important;      /* Editor takes full screen */
        width: 100% !important;
        min-width: 100% !important;
        box-sizing: border-box;
        padding: 0 10px;
    }

    .ad4a-box {
        order: 2 !important;
        flex: 0 0 300px !important;     /* Keep original width for scroll math */
        width: 300px !important;
        transform: scale(0.8);          /* Scale ad for small screens */
        transform-origin: left top;
        margin-left: 15px !important;
        /* Closing the gap created by scale */
        margin-right: -120px !important; 
        margin-bottom: -100px !important;
    }
}

/* ad5 Banner 728x90  */
 
.ad5-wrapper {
    width: 100%;
    margin-top: 15px;
    clear: both;
    overflow: visible; 
}
 
.ad5-box {
    float: left !important;
    width: 728px !important;
    height: 90px !important;
    margin-right: 15px !important;
    margin-bottom: 10px !important;
    display: block;
} 
.ad5-wrapper {
    width: 100%;
    margin-top: 15px;
    clear: both;
}
 
.ad5-box {
    float: left !important;
    width: 728px !important;
    height: 90px !important;
    margin-right: 15px !important;
    margin-bottom: 10px !important;
    display: block;
}
 
@media screen and (min-width: 501px) and (max-width: 1050px) {
    .ad5-box {
        float: left !important;
        transform: scale(0.6) !important;
        transform-origin: left top !important;
        width: 728px !important;  
        height: 90px !important;
        margin-right: -285px !important;
        margin-bottom: -35px !important;
    }
}
@media screen and (max-width: 500px) {
    .ad5-box {
        float: left !important;
        transform: scale(0.42) !important;
        transform-origin: left top !important;
        width: 728px !important; 
        height: 90px !important;
        margin-right: -415px !important;
        margin-bottom: -50px !important;
    }
}


/* ad6  Banner 468x60 */
.ad6-wrapper {
    width: 100%;
    margin-top: 15px;
    clear: both;
}

.ad6-box {
    float: left !important;
    width: 468px !important;
    height: 60px !important;
    margin-right: 15px !important;
    margin-bottom: 10px !important;
    display: block;
}

@media screen and (max-width: 480px) {
    .ad6-box {
        float: left !important;
        transform: scale(0.7) !important;
        transform-origin: left top !important;
        width: 468px !important;
        height: 60px !important;
        margin-right: -135px !important; 
        margin-bottom: -18px !important;
    }
}


/* native ad */
    .native-ad-row {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important; /* Forcefully ek line mein rakhega */
        overflow-x: auto; /* Mobile par scroll allow karega */
        width: 100% !important;
        gap: 10px;
        padding: 10px 0;
    }

    /* Adsterra ke har ad block ko chhota karne ke liye */
    #container-f805c80d0c6f7a10d5c94704185af9ca .container-f805c80d0c6f7a10d5c94704185af9ca__bn-container {
        flex: 0 0 23% !important; /* Ek line mein 4 ads fit karne ke liye */
        min-width: 150px !important;
        max-width: 25% !important;
    }

    /* Image aur layout ko fix karne ke liye */
    .container-f805c80d0c6f7a10d5c94704185af9ca__stand {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
    }