/*
Theme Name: Every Shade of Life Custom
Author: Himanshu Shukla
Version: 1.1.0
Description: Custom coded high-performance grid magazine theme for Every Shade of Life.
*/

/* --- 1. CORE COLOR PALETTE & VARIABLES (LOGO THEME) --- */
:root {
    --accent-gold: #FFC72C;     /* लोगो का मस्टर्ड येलो */
    --ink-black: #0F0F11;       /* दरीबा/स्याही वाला डीप रिच ब्लैक */
    --quill-cream: #F9F6F0;     /* कलम वाला क्लासिक क्रीम */
    
    --bg-main: #FFFFFF;
    --bg-surface: #FBF9F6;      /* हल्का विंटेज क्रीम टच */
    --text-primary: #0F0F11;    
    --text-muted: #5C5B61;
    --border-color: #E2DFD8;    
    
    /* कैटेगरीज के लिए क्लासिक म्यूटेड शेड्स */
    --clr-finance: #2E5A44;     /* विंटेज ग्रीन */
    --clr-wellness: #A94A42;    /* म्यूटेड टेराकोटा रेड */
    --clr-lifestyle: #2A4B7C;   /* क्लासिक इंक ब्लू */
    --clr-travel: #C68B59;      /* वॉर्म अर्थी ब्राउन */
}

[data-theme="dark"] {
    --bg-main: #0B0B0C;
    --bg-surface: #141416;
    --text-primary: #F4F3F0;    /* डार्क मोड विजिबिलिटी फिक्स */
    --text-muted: #9A98A0;
    --border-color: #262529;
    --accent-gold: #FFD043;     
}

/* --- 2. GLOBAL RESET & BASE --- */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    background-color: var(--bg-main);
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    transition: background-color 0.3s, color 0.3s;
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { width: 100%; height: 100%; object-fit: cover; border-radius: 4px; }

/* Dynamic Reading Progress Bar */
.progress-bar {
    position: fixed; top: 0; left: 0; height: 4px;
    background: var(--accent-gold); width: 0%; z-index: 2000;
    transition: width 0.1s ease-out;
}

/* --- 3. PREMIUM CSS GRID HEADER LINEUP (OVERLAP FIXED) --- */
.site-header {
    position: sticky; 
    top: 0; 
    z-index: 1000; /* कंटेंट हमेशा हेडर के नीचे स्क्रॉल होगा */
    background: var(--bg-main);
    border-bottom: 2px solid var(--text-primary);
    height: 90px; 
    width: 100%;
    transition: background-color 0.3s;
}

.header-container {
    max-width: 1300px; 
    margin: 0 auto; 
    padding: 0 20px;
    height: 100%;
    
    /* 3-कॉलम फिक्स ग्रिड अलाइनमेंट */
    display: grid;
    grid-template-columns: 200px 1fr auto; /* लोगो, मेनू और बटन्स को अलग डिब्बों में लॉक किया */
    align-items: center; 
}

/* लोगो ब्लॉक */
.logo {
    display: flex; 
    align-items: center;
    width: 100%;
    height: 100%;
}
.site-logo-img {
    display: block;
    width: auto; 
    height: 55px; 
    object-fit: contain;
    transition: transform 0.2s ease;
}
.site-logo-img:hover { transform: scale(1.02); }

/* बीच का नेविगेशन मेनू */
.main-nav-center {
    display: flex; 
    align-items: center; 
    justify-content: center; /* मेनू को बिल्कुल सेंटर में रखेगा */
    height: 100%;
}
.main-nav-center ul {
    display: flex; 
    list-style: none; 
    gap: 25px; 
    margin: 0; 
    padding: 0;
}
.main-nav-center a {
    font-size: 14px; 
    font-weight: 700; 
    text-transform: uppercase;
    letter-spacing: 0.5px; 
    white-space: nowrap;
    color: var(--text-primary);
    transition: color 0.2s;
}
.main-nav-center a:hover, .main-nav-center a.active { 
    color: var(--accent-gold); 
}

/* राइट साइड बटन्स (एकदम राइट कॉर्नर में लॉक) */
.header-right {
    display: flex; 
    align-items: center; 
    justify-content: flex-end; 
    gap: 15px; 
    height: 100%;
}
.theme-toggle { 
    background: transparent; 
    border: none; 
    cursor: pointer; 
    font-size: 18px; 
    padding: 5px;
}
.btn-signin {
    background: transparent; 
    border: none; 
    color: var(--text-primary);
    cursor: pointer; 
    font-weight: 700; 
    font-size: 14px; 
    white-space: nowrap;
    padding: 5px 10px;
}
.btn-join {
    background: var(--text-primary); 
    color: var(--bg-main);
    padding: 10px 18px; 
    border: none; 
    font-weight: 700; 
    font-size: 13px;
    cursor: pointer; 
    text-transform: uppercase; 
    letter-spacing: 0.5px; 
    white-space: nowrap;
    border-radius: 4px;
}

/* --- 4. MAGAZINE LAYOUT GRID SYSTEM --- */
.main-layout { max-width: 1300px; margin: 30px auto; padding: 0 20px; }
.hero-magazine-grid {
    display: grid; 
    grid-template-columns: 2.2fr 1.3fr 1fr; 
    gap: 30px;
    align-items: start;
}

/* Column 1: Featured Card */
.featured-card-big h2 { font-family: 'Playfair Display', serif; font-size: 30px; margin: 15px 0 10px; line-height: 1.2; }
.post-meta { font-size: 12px; color: var(--text-muted); margin-bottom: 10px; }
.post-meta strong { color: var(--text-primary); border-bottom: 1px dotted var(--accent-gold); }
.featured-card-big p { color: var(--text-muted); line-height: 1.5; font-size: 14px; text-align: justify; }

/* Containers & Category Badges */
.card-img-box { position: relative; width: 100%; height: 360px; overflow: hidden; border-radius: 4px; }
.mini-img { position: relative; width: 100%; height: 160px; overflow: hidden; border-radius: 4px; }
.category-badge {
    position: absolute; top: 12px; left: 12px; z-index: 10;
    color: #fff; padding: 4px 10px; font-size: 10px; font-weight: 700; text-transform: uppercase; border-radius: 2px;
}
.finance { background: var(--clr-finance); }
.wellness { background: var(--clr-wellness); }
.lifestyle { background: var(--clr-lifestyle); }
.travel { background: var(--clr-travel); }

.bookmark-btn {
    position: absolute; bottom: 12px; right: 12px; z-index: 12;
    background: rgba(15, 15, 17, 0.8); border: none; color: white; border-radius: 50%; width: 34px; height: 34px; cursor: pointer;
}

/* Column 2: Medium Stack */
.medium-posts-stack { display: flex; flex-direction: column; gap: 20px; }
.horizontal-mini-card h3 { font-family: 'Playfair Display', serif; font-size: 16px; margin-top: 10px; line-height: 1.3; }

/* Column 3: Sidebar Feed */
.block-title-header { border-bottom: 2px solid var(--text-primary); padding-bottom: 5px; margin-bottom: 15px; }
.block-title-header span { font-weight: 700; text-transform: uppercase; font-size: 12px; letter-spacing: 0.5px; }
.feed-wrapper { display: flex; flex-direction: column; gap: 15px; }
.feed-item { padding-bottom: 12px; border-bottom: 1px solid var(--border-color); }
.feed-tag-inline { font-size: 10px; font-weight: 700; text-transform: uppercase; margin-bottom: 4px; display: inline-block; color: var(--accent-gold); }
.feed-item h4 { font-size: 14px; line-height: 1.3; font-weight: 600; }

/* --- 5. ANTI-CLS FIXED AD SLOTS (ADSENSE APPROVED) --- */
.ad-container-outer { width: 100%; display: flex; justify-content: center; margin: 15px 0; }
.ad-slot-placeholder {
    background: var(--bg-surface); border: 1px dashed var(--border-color);
    color: var(--text-muted); display: flex; align-items: center; justify-content: center;
    font-size: 10px; font-weight: 600; text-transform: uppercase; text-align: center;
}
.leaderboard-ad { width: 100%; max-width: 1260px; height: 90px; }
.sidebar-square-ad { width: 100%; height: 250px; margin-top: 15px; }

/* --- 6. SINGLE POST PAGE (ARTICLE READING VIEW) --- */
.article-container-grid { display: grid; grid-template-columns: 2.3fr 1fr; gap: 40px; }
.post-header-area { margin-bottom: 25px; }
.entry-title { font-family: 'Playfair Display', serif; font-size: 36px; font-weight: 800; line-height: 1.2; margin: 15px 0 10px; }
.single-featured-image { width: 100%; height: auto; max-height: 480px; overflow: hidden; border-radius: 6px; margin-bottom: 30px; }
.single-article-ad { width: 100%; height: 100px; margin: 30px 0; }

.entry-content { font-size: 17px; line-height: 1.7; color: var(--text-primary); }
.entry-content p { margin-bottom: 20px; text-align: justify; }

/* Premium Author Bio Card */
.author-bio-card {
    display: flex; background: var(--bg-surface); border: 2px solid var(--text-primary);
    padding: 25px; margin-top: 50px; border-radius: 4px; gap: 20px; align-items: center;
}
.author-avatar {
    background: var(--text-primary); color: var(--bg-main); width: 60px; height: 60px;
    border-radius: 50%; display: flex; align-items: center; justify-content: center;
    font-family: 'Playfair Display', serif; font-weight: 700; font-size: 20px;
}
.author-info h4 { font-family: 'Playfair Display', serif; font-size: 20px; margin-bottom: 2px; }
.author-title { font-size: 12px; font-weight: 700; color: var(--accent-gold); text-transform: uppercase; margin-bottom: 8px; }
.author-desc { font-size: 13.5px; color: var(--text-muted); line-height: 1.5; }

/* --- 7. AUTH MODAL POPUP --- */
.modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.5); backdrop-filter: blur(4px);
    z-index: 1000; display: none; justify-content: center; align-items: center;
}
.modal-overlay.active { display: flex; }
.modal-card { background: var(--bg-main); width: 100%; max-width: 380px; padding: 30px; border: 2px solid var(--text-primary); position: relative; }
.close-modal { position: absolute; top: 10px; right: 15px; background: transparent; border: none; font-size: 24px; cursor: pointer; }
.form-group { margin-bottom: 15px; }
.form-group label { display: block; font-size: 11px; font-weight: 700; margin-bottom: 5px; text-transform: uppercase; }
.form-group input { width: 100%; padding: 10px; border: 1px solid var(--border-color); background: var(--bg-surface); color: var(--text-primary); }
.btn-submit-auth { width: 100%; padding: 12px; background: var(--text-primary); color: var(--bg-main); border: none; font-weight: 600; cursor: pointer; }

/* --- 8. PREMIUM COMPLIANT FOOTER --- */
.site-footer {
    background: var(--ink-black); color: #FFFFFF;
    margin-top: 60px; border-top: 4px solid var(--accent-gold); font-family: 'Inter', sans-serif;
}
[data-theme="dark"] .site-footer { border-top: 4px solid var(--accent-gold); background: #050506; }
.footer-container {
    max-width: 1300px; margin: 0 auto; padding: 60px 20px 40px;
    display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 50px;
}
.footer-column h3 { font-family: 'Playfair Display', serif; font-size: 28px; font-weight: 800; margin-bottom: 15px; letter-spacing: -0.5px; }
.footer-column h3 span { color: var(--accent-gold); }
.footer-column h4 { font-family: 'Playfair Display', serif; font-size: 18px; margin-bottom: 20px; position: relative; padding-bottom: 8px; }
.footer-column h4::after { content: ''; position: absolute; bottom: 0; left: 0; width: 30px; height: 2px; background: var(--accent-gold); }
.footer-column p { color: #CBCACF; font-size: 14px; line-height: 1.6; margin-bottom: 20px; }

.founder-tag { border-left: 2px solid var(--accent-gold); padding-left: 12px; font-size: 13px; }
.founder-tag strong { color: #FFFFFF; }
.founder-tag span { color: #9A98A0; font-size: 12px; }

.footer-column ul { list-style: none; }
.footer-column ul li { margin-bottom: 12px; }
.footer-column ul a { color: #CBCACF; font-size: 14px; transition: color 0.2s; }
.footer-column ul a:hover { color: var(--accent-gold); }

.footer-bottom { border-top: 1px solid #262529; padding: 20px 0; font-size: 13px; color: #9A98A0; }
.footer-bottom-container { max-width: 1300px; margin: 0 auto; padding: 0 20px; display: flex; justify-content: space-between; align-items: center; }
.footer-socials { display: flex; gap: 15px; }
.footer-socials a { color: #9A98A0; font-weight: 600; font-size: 12px; letter-spacing: 1px; transition: color 0.2s; }
.footer-socials a:hover { color: var(--accent-gold); }

/* --- 9. FLUID RESPONSIVE BREAKPOINTS --- */
@media (max-width: 1024px) {
    .hero-magazine-grid, .article-container-grid { grid-template-columns: 1fr; }
    .entry-title { font-size: 28px; }
    .author-bio-card { flex-direction: column; text-align: center; }
}
@media (max-width: 991px) {
    .header-container { grid-template-columns: 180px auto; /* मोबाइल पर बीच का मेनू गायब */ }
    .main-nav-center { display: none; } 
}
@media (max-width: 768px) {
    .footer-container { grid-template-columns: 1fr; gap: 30px; padding: 40px 20px; }
    .footer-bottom-container { flex-direction: column; gap: 15px; text-align: center; }
    .site-logo-img { height: 45px; }
}


/* --- FOOTER LOGO IMAGE STYLES --- */
.footer-logo-box {
    display: flex;
    align-items: center;
    margin-bottom: 20px; /* नीचे वाले पैराग्राफ से थोड़ी दूरी */
    max-width: 180px;
    height: auto;
}

.footer-logo-img {
    display: block;
    width: auto;
    height: 50px; /* फुटर के हिसाब से परफेक्ट और डिसेंट हाइट */
    object-fit: contain;
    filter: drop-shadow(0px 2px 4px rgba(255, 255, 255, 0.1)); /* डार्क बैकग्राउंड पर लोगो को उभारने के लिए हल्का सा शैडो */
}


/* --- CATEGORY ARCHIVE PAGE STYLES --- */
.category-page-header {
    border-bottom: 2px solid var(--text-primary);
    padding-bottom: 20px;
    margin-bottom: 40px;
}
.archive-subtitle {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--accent-gold);
    letter-spacing: 1px;
    display: block;
    margin-bottom: 5px;
}
.archive-title {
    font-family: 'Playfair Display', serif;
    font-size: 38px;
    font-weight: 800;
    text-transform: capitalize;
}

.archive-layout-grid {
    display: grid;
    grid-template-columns: 2.3fr 1fr;
    gap: 40px;
}

.archive-posts-list {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.archive-post-card {
    display: flex;
    gap: 25px;
    padding-bottom: 25px;
    border-bottom: 1px solid var(--border-color);
    align-items: center;
}

.archive-post-img {
    width: 240px;
    height: 150px;
    flex-shrink: 0;
    overflow: hidden;
    border-radius: 4px;
}

.archive-post-details h2 {
    font-family: 'Playfair Display', serif;
    font-size: 22px;
    line-height: 1.3;
    margin-bottom: 8px;
}

.archive-post-details p {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.5;
}

@media (max-width: 768px) {
    .archive-layout-grid { grid-template-columns: 1fr; }
    .archive-post-card { flex-direction: column; align-items: flex-start; gap: 15px; }
    .archive-post-img { width: 100%; height: 200px; }
    .archive-title { font-size: 28px; }
}


/* --- UPGRADE: SIMILAR BLOGS & SUBSCRIBE WIDGET --- */

.main-content-area-left {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

/* Similar Blogs Layout */
.related-posts-section {
    margin-top: 20px;
    padding-top: 20px;
}
.related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}
.related-card {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.related-img-box {
    width: 100%;
    height: 140px;
    overflow: hidden;
    border-radius: 4px;
}
.related-card h3 {
    font-family: 'Playfair Display', serif;
    font-size: 15px;
    line-height: 1.4;
    font-weight: 700;
}
.no-related {
    font-size: 14px;
    color: var(--text-muted);
    grid-column: span 3;
}

/* Sidebar Subscribe Widget Box */
.subscribe-widget-box {
    background: var(--bg-surface);
    border: 2px solid var(--text-primary);
    padding: 25px;
    border-radius: 4px;
}
.subscribe-widget-box h4 {
    font-family: 'Playfair Display', serif;
    font-size: 20px;
    margin-bottom: 10px;
    font-weight: 800;
}
.subscribe-widget-box p {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 15px;
}
.sidebar-sub-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.sidebar-sub-form input {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    background: var(--bg-main);
    color: var(--text-primary);
    border-radius: 4px;
    font-size: 13px;
}
.sidebar-sub-form button {
    width: 100%;
    padding: 12px;
    background: var(--accent-gold);
    color: #000000; /* मस्टर्ड येलो पर ब्लैक टेक्स्ट कड़क दिखता है */
    border: none;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.2s;
}
.sidebar-sub-form button:hover {
    background: var(--text-primary);
    color: var(--bg-main);
}

@media (max-width: 600px) {
    .related-grid { grid-template-columns: 1fr; }
}


.skeleton {
    background: linear-gradient(90deg, var(--bg-surface) 25%, var(--border-color) 50%, var(--bg-surface) 75%);
    background-size: 200% 100%;
    animation: loading-wave 1.5s infinite;
}
@keyframes loading-wave {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}


.share-ribbon {
    display: flex; gap: 10px; margin: 20px 0; padding: 10px 0;
    border-top: 1px dashed var(--border-color); border-bottom: 1px dashed var(--border-color);
}
.share-btn { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; cursor: pointer; }
.share-btn.tw { color: #1DA1F2; }
.share-btn.wa { color: #25D366; }


/* आर्टिकल के अंदर की हेडिंग्स और लिस्ट्स को प्रीमियम लुक दें */
.entry-content h2, .entry-content h3 {
    font-family: 'Playfair Display', serif;
    color: var(--text-primary);
    margin: 35px 0 15px 0;
    line-height: 1.3;
}

.entry-content ul, .entry-content ol {
    margin: 0 0 25px 25px;
    padding: 0;
    color: var(--text-primary);
}

.entry-content li {
    margin-bottom: 10px;
    line-height: 1.6;
    font-size: 16px;
}


/* प्रीमियम ब्लॉककोट स्टाइल */
.entry-content blockquote {
    border-left: 4px solid var(--accent-gold);
    background: var(--bg-surface);
    padding: 20px;
    margin: 30px 0;
    font-style: italic;
    font-family: 'Playfair Display', serif;
    font-size: 18px;
    color: var(--text-primary);
}


/* आर्टिकल के अंदर की इमेजेस का साइज फिक्स करें */
.entry-content img {
    max-width: 100%;
    height: auto;
    margin: 20px 0;
    border-radius: 6px;
    display: block;
}

/* वर्डप्रेस के अलाइनमेंट को सपोर्ट करने के लिए */
.aligncenter { display: block; margin: 25px auto; text-align: center; }
.alignleft { float: left; margin: 0 20px 20px 0; max-width: 50%; }
.alignright { float: right; margin: 0 0 20px 20px; max-width: 50%; }

/* फ्लोट को क्लियर करने के लिए ताकि लेआउट न टूटे */
.entry-content::after {
    content: ""; display: table; clear: both;
}


/* एडसेंस डिब्बों की स्पेसिंग दुरुस्त करें */
.single-article-ad {
    width: 100%;
    height: 90px;
    margin: 40px 0; /* ऊपर और नीचे 40px का फिक्स गैप ताकि कंटेंट खुलकर दिखे */
    background: var(--bg-surface);
    border: 1px dashed var(--border-color);
}


/* मोबाइल पर साइडबार और कंटेंट के बीच का गैप */
@media (max-width: 1024px) {
    .main-content-area-left {
        margin-bottom: 50px; /* इसके नीचे साइडबार आने पर स्पेस रहे */
    }
    .sidebar-feed {
        margin-top: 20px;
    }
}

/* --- BULLETPROOF SINGLE POST GRID MATRIX --- */
.article-container-grid {
    display: grid !important;
    grid-template-columns: 2.3fr 1fr !important;
    gap: 40px !important;
    align-items: start !important;
    width: 100% !important;
}

.main-content-area-left {
    display: flex !important;
    flex-direction: column !important;
    gap: 40px !important;
    width: 100% !important;
    overflow: hidden;
}

.sidebar-feed {
    display: flex !important;
    flex-direction: column !important;
    gap: 20px !important;
    width: 100% !important;
}

/* रेसिपी और ब्लॉग की इमेजेस/लिस्ट्स को सुव्यवस्थित करें */
.entry-content ul, .entry-content ol {
    margin: 15px 0 25px 25px !important;
    padding: 0 !important;
}
.entry-content li {
    margin-bottom: 12px !important;
    line-height: 1.7 !important;
    font-size: 16.5px !important;
}
.entry-content img {
    max-width: 100% !important;
    height: auto !important;
    border-radius: 6px !important;
    margin: 25px 0 !important;
}

/* मोबाइल रिस्पॉन्सिवनेस फ़ोर्स */
@media (max-width: 1024px) {
    .article-container-grid {
        grid-template-columns: 1fr !important;
    }
}