/*
Theme Name: Automotive Zone
Theme URI: https://automotivezone.in
Author: Automotive Zone
Description: High-performance automotive blog theme. Mobile-first, Dark Mode, Auto-TOC.
Version: 2.3.0
Requires at least: 6.0
Requires PHP: 7.4
License: GPL v2 or later
Text Domain: autoblog
*/


/* --------------------------------------------------------------------------
   LOCAL TYPOGRAPHY — no Google Fonts / no third-party font requests
--------------------------------------------------------------------------- */
@font-face {
    font-family: "Inter";
    src: url("assets/fonts/inter-400.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: optional;
}
@font-face {
    font-family: "Inter";
    src: url("assets/fonts/inter-500.woff2") format("woff2");
    font-weight: 500;
    font-style: normal;
    font-display: optional;
}
@font-face {
    font-family: "Inter";
    src: url("assets/fonts/inter-600.woff2") format("woff2");
    font-weight: 600;
    font-style: normal;
    font-display: optional;
}
@font-face {
    font-family: "Inter";
    src: url("assets/fonts/inter-700.woff2") format("woff2");
    font-weight: 700;
    font-style: normal;
    font-display: optional;
}
@font-face {
    font-family: "Inter";
    src: url("assets/fonts/inter-800.woff2") format("woff2");
    font-weight: 800 900;
    font-style: normal;
    font-display: optional;
}
@font-face {
    font-family: "Inter Display";
    src: url("assets/fonts/inter-display-800.woff2") format("woff2");
    font-weight: 800 900;
    font-style: normal;
    font-display: optional;
}

/* --------------------------------------------------------------------------
   VARIABLES & PREMIUM DESIGN TOKENS
--------------------------------------------------------------------------- */
:root {
    /* Colors */
    --bg-body: #f8fafc; 
    --bg-card: #ffffff;
    --text-main: #0f172a; 
    --text-muted: #64748b; 
    --border: #e2e8f0;
    --primary: #E63946;
    --primary-dark: #be1226;
    --hero-pattern: #f1f5f9;
    
    /* Premium Shadows */
    --shadow-sm: 0 2px 4px rgba(15, 23, 42, 0.04);
    --shadow-md: 0 10px 25px rgba(15, 23, 42, 0.06);
    --shadow-hover: 0 20px 40px rgba(15, 23, 42, 0.12);
    
    /* Layout */
    --container-width: 1100px;
    --radius-md: 12px;
    --radius-lg: 20px;
}

body.dark-mode {
    --bg-body: #0f172a;
    --bg-card: #1e293b;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --border: #334155;
    --primary: #E63946;
    --primary-dark: #ff6b77;
    --hero-pattern: #1e293b; 
    
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 10px 25px rgba(0, 0, 0, 0.3);
    --shadow-hover: 0 20px 40px rgba(0, 0, 0, 0.5);
}

body {
    background-color: var(--bg-body);
    color: var(--text-main);
    font-family: 'Inter', system-ui, sans-serif;
    line-height: 1.6;
    margin: 0;
    transition: background-color 0.3s ease, color 0.3s ease;
}

*, *::before, *::after { box-sizing: border-box; }

html { overflow-x: hidden; }

h1, h2, h3, h4, h5, h6 {
    font-family: 'Inter Display', sans-serif;
    font-weight: 700;
    margin-top: 0;
    margin-bottom: 1rem;
    line-height: 1.2;
    letter-spacing: -0.5px;
}

a { color: var(--primary-dark); text-decoration: none; transition: color 0.2s ease; }
a:hover { color: var(--primary); }
img { max-width: 100%; height: auto; display: block; }

.screen-reader-text { border: 0; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; width: 1px; word-wrap: normal !important; }

/* --------------------------------------------------------------------------
   LAYOUT
--------------------------------------------------------------------------- */
.container, .ab-container, .hero-container { width: 100%; max-width: var(--container-width); margin: 0 auto; padding: 0 20px; box-sizing: border-box; }
.post-grid, .main-wrapper, .content-container { width: 100%; max-width: var(--container-width); margin-left: auto; margin-right: auto; }
.site-main { padding: 40px 0; min-height: 60vh; display: flex; flex-direction: column; align-items: center; width: 100%; }

/* --------------------------------------------------------------------------
   HEADER (Premium Clean Look)
--------------------------------------------------------------------------- */
.ab-header { background: var(--bg-card); border-bottom: 1px solid var(--border); height: 80px; position: sticky; top: 0; z-index: 99999; box-shadow: var(--shadow-sm); }
.ab-container { height: 100%; display: flex; justify-content: space-between; align-items: center; position: relative; }

/* LOGO STYLING & DARK MODE LOGO SWITCHING */
.ab-logo { font-size: 26px; font-weight: 800; font-family: 'Inter Display', sans-serif; color: var(--primary); text-transform: uppercase; text-decoration: none; white-space: nowrap; letter-spacing: -1px; display: flex; align-items: center; margin: 0; }
.custom-logo-link { display: flex; align-items: center; text-decoration: none; }
.site-logo { max-height: 50px; width: auto; object-fit: contain; }

/* Hide dark logo by default */
.dark-logo { display: none !important; }

/* When dark mode is active, hide light logo and show dark logo */
body.dark-mode .light-logo { display: none !important; }
body.dark-mode .dark-logo { display: block !important; }

ul.ab-menu-list, ul.ab-menu-list ul { margin: 0; padding: 0; list-style: none !important; }
ul.ab-menu-list a { text-decoration: none; color: var(--text-main); font-weight: 600; font-size: 15px; transition: color 0.2s; }
ul.ab-menu-list a:hover { color: var(--primary); }

@media (min-width: 993px) {
    .ab-toggle { display: none !important; }
    ul.ab-menu-list { display: flex; flex-direction: row; align-items: center; gap: 35px; }
    ul.ab-menu-list > li { position: relative; padding: 25px 0; }
    ul.ab-menu-list ul.sub-menu { 
        display: none; 
        position: absolute; 
        top: 100%; 
        left: -20px; 
        background: var(--bg-card); 
        min-width: 240px; 
        width: max-content; 
        max-width: 320px; 
        box-shadow: var(--shadow-md); 
        border-top: 3px solid var(--primary); 
        border-radius: 0 0 8px 8px; 
        flex-direction: column; 
        z-index: 1000; 
        padding: 10px 0; 
    }
    ul.ab-menu-list li:hover > ul.sub-menu { display: flex; }
    ul.ab-menu-list ul.sub-menu li { width: 100%; }
    ul.ab-menu-list ul.sub-menu a { display: block; padding: 12px 25px; white-space: normal; font-size: 14px; color: var(--text-main); box-sizing: border-box; }
    ul.ab-menu-list ul.sub-menu a:hover { background-color: var(--bg-body); color: var(--primary); padding-left: 30px; }
}

@media (max-width: 992px) {
    /* Critical Fix: Release the position context to allow the mobile menu to span the full screen */
    .ab-container { position: static; }
    
    .ab-toggle { display: block; background: transparent; border: 1px solid var(--border); color: var(--text-main); font-size: 24px; cursor: pointer; padding: 6px 12px; border-radius: 6px; }
    
    /* Critical Fix: width: 100% and z-index added */
    .ab-nav { display: none; position: absolute; top: 80px; left: 0; width: 100%; background: var(--bg-card); border-top: 2px solid var(--primary); padding: 20px; box-shadow: var(--shadow-md); z-index: 1000; box-sizing: border-box; }
    .ab-nav.active { display: block; }
    
    ul.ab-menu-list { flex-direction: column; align-items: flex-start; gap: 0; }
    ul.ab-menu-list li { width: 100%; border-bottom: 1px solid var(--border); }
    ul.ab-menu-list a { display: block; padding: 15px 0; width: 100%; color: var(--text-main); box-sizing: border-box; }
    ul.ab-menu-list ul.sub-menu { padding-left: 20px; background: transparent; display: block; }
}

.theme-btn { background: transparent; border: none; cursor: pointer; color: var(--text-main); padding: 8px; border-radius: 50%; transition: background 0.2s; display: flex; align-items: center; justify-content: center; }
.theme-btn:hover { background-color: var(--border); color: var(--primary); }

/* --------------------------------------------------------------------------
   PREMIUM PORTAL HOMEPAGE
--------------------------------------------------------------------------- */
.homepage-portal .container { max-width: 1100px; }

.search-hero { background: linear-gradient(to bottom, var(--bg-card) 0%, var(--bg-body) 100%); padding: 110px 20px 90px; text-align: center; margin-bottom: 50px; display: flex; justify-content: center; width: 100%; position: relative; overflow: hidden; border-bottom: 1px solid var(--border); }
.hero-container { max-width: 1000px; margin: 0 auto; width: 100%; position: relative; z-index: 2; }
.hero-heading { font-family: 'Inter', sans-serif; font-size: 4.5rem; line-height: 1.1; font-weight: 800; color: var(--text-main); margin-bottom: 25px; letter-spacing: -2px; }
.hero-highlight { color: var(--primary); position: relative; }
.hero-subtext { font-size: 1.35rem; color: var(--text-muted); margin-bottom: 50px; font-weight: 500; letter-spacing: -0.2px; }

.search-wrapper { display: flex; align-items: center; background: var(--bg-card); border: 2px solid var(--border); border-radius: 60px; padding: 8px 8px 8px 30px; box-shadow: var(--shadow-md); transition: all 0.3s ease; max-width: 750px; margin: 0 auto; }
.search-wrapper:hover, .search-wrapper:focus-within { box-shadow: var(--shadow-hover); border-color: rgba(230, 57, 70, 0.4); transform: translateY(-3px); }
.search-input { border: none; background: transparent; font-size: 1.15rem; color: var(--text-main); flex-grow: 1; outline: none; padding: 14px 0; font-family: 'Inter', sans-serif; }
.search-btn { background-color: var(--primary); border: none; color: white; width: 55px; height: 55px; border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: background 0.2s, transform 0.2s, box-shadow 0.2s; margin-left: 10px; flex-shrink: 0; box-shadow: 0 4px 10px rgba(230, 57, 70, 0.3); }
.search-btn:hover { background-color: var(--primary-dark); transform: scale(1.05); box-shadow: 0 6px 15px rgba(230, 57, 70, 0.4); }

.hero-quick-links { display: flex; justify-content: center; gap: 15px; margin-top: 45px; flex-wrap: wrap; }
.quick-btn { display: inline-flex; align-items: center; gap: 10px; background: var(--primary); color: #fff; padding: 14px 32px; border-radius: 50px; font-weight: 700; font-size: 1.05rem; text-decoration: none; transition: all 0.3s; box-shadow: 0 8px 20px rgba(230, 57, 70, 0.25); }
.quick-btn:hover { color: #fff; transform: translateY(-3px); box-shadow: 0 12px 25px rgba(230, 57, 70, 0.35); }
.quick-btn-outline { background: var(--bg-card); border: 2px solid var(--border); color: var(--text-main); box-shadow: var(--shadow-sm); }
.quick-btn-outline:hover { background: var(--bg-body); border-color: var(--text-muted); color: var(--text-main); box-shadow: var(--shadow-md); }

@media (max-width: 768px) {
    .hero-heading { font-size: 2.8rem; letter-spacing: -1px; }
    .hero-subtext { font-size: 1.1rem; }
    .search-hero { padding: 60px 20px; }
    .search-wrapper { padding: 5px 5px 5px 20px; border-radius: 50px; }
    .search-input { font-size: 1rem; padding: 10px 0; }
    .search-btn { width: 45px; height: 45px; flex-shrink: 0; }
    .hero-quick-links { flex-direction: column; width: 100%; max-width: 300px; margin: 30px auto 0; }
    .quick-btn { justify-content: center; width: 100%; }
}

.category-strip { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; padding: 0 0 30px 0; }
.cat-pill { background: var(--bg-card); border: 1px solid var(--border); padding: 10px 26px; border-radius: 50px; font-size: 0.95rem; font-weight: 600; color: var(--text-main); transition: all 0.3s; box-shadow: var(--shadow-sm); }
.cat-pill:hover { border-color: var(--primary); color: var(--primary); transform: translateY(-2px); box-shadow: var(--shadow-md); }

.news-ticker-wrap { display: flex; align-items: center; background: var(--bg-card); border: 1px solid var(--border); border-radius: 50px; margin: 0 0 60px; overflow: hidden; box-shadow: var(--shadow-sm); }
.ticker-label { background: var(--primary); color: #fff; padding: 14px 28px; font-weight: 800; font-family: 'Inter Display', sans-serif; text-transform: uppercase; font-size: 1rem; flex-shrink: 0; letter-spacing: 1px; }
.ticker-content { padding: 0 20px; font-weight: 600; color: var(--text-main); font-size: 0.95rem; }
.ticker-content a { color: var(--text-main); text-decoration: none; transition: color 0.2s; }
.ticker-content a:hover { color: var(--primary); }

.portal-section { margin-bottom: 80px; width: 100%; }
.section-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 30px; flex-wrap: wrap; gap: 15px; padding-bottom: 15px; border-bottom: 2px solid var(--border); position: relative; }
.section-header::after { content: ''; position: absolute; left: 0; bottom: -2px; height: 2px; width: 60px; background: var(--primary); }
.section-title { font-family: 'Inter Display', sans-serif; font-size: 2.2rem; margin: 0; color: var(--text-main); text-transform: uppercase; letter-spacing: -0.5px; }
.view-all-link { font-weight: 700; color: var(--text-muted); font-size: 0.95rem; text-decoration: none; padding: 8px 20px; border: 1px solid var(--border); border-radius: 50px; transition: all 0.2s; background: var(--bg-card); }
.view-all-link:hover { color: var(--primary); border-color: var(--primary); background: rgba(230, 57, 70, 0.05); }

.bg-light-wrap { background: var(--bg-card); padding: 50px 40px; border-radius: var(--radius-lg); max-width: 100%; border: 1px solid var(--border); box-shadow: var(--shadow-sm); }

.post-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 30px; width: 100%; }
.blog-card { position: relative; border-radius: var(--radius-md); overflow: hidden; background-color: #0f172a; box-shadow: var(--shadow-md); transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1); height: 420px; border: 1px solid var(--border); }
.blog-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-hover); }
.card-link-wrapper { display: block; width: 100%; height: 100%; position: relative; text-decoration: none; }
.card-image { width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1); }
.blog-card:hover .card-image { transform: scale(1.06); }
.card-overlay { position: absolute; bottom: 0; left: 0; right: 0; top: 0; background: linear-gradient(to top, rgba(15, 23, 42, 0.95) 0%, rgba(15, 23, 42, 0.4) 50%, transparent 100%); z-index: 1; pointer-events: none; }
.card-content { position: absolute; bottom: 0; left: 0; width: 100%; padding: 30px; z-index: 2; box-sizing: border-box; }
.card-cat-badge { position: absolute; top: 20px; left: 20px; background: rgba(230, 57, 70, 0.9); backdrop-filter: blur(8px); color: #ffffff; font-size: 0.75rem; font-weight: 800; text-transform: uppercase; padding: 6px 14px; border-radius: 50px; z-index: 3; letter-spacing: 1px; box-shadow: 0 2px 10px rgba(0,0,0,0.2); }
.card-title { color: #fff; font-family: 'Inter Display', sans-serif; font-size: 1.8rem; line-height: 1.3; margin: 0 0 12px 0; text-shadow: 0 2px 8px rgba(0,0,0,0.5); }
.card-meta { font-size: 0.9rem; color: rgba(255,255,255,0.7); font-weight: 500; display: flex; align-items: center; gap: 8px; }

.badge-gold { background: rgba(255, 215, 0, 0.95) !important; color: #000 !important; }
.badge-vs { background: rgba(0, 0, 0, 0.8) !important; color: #fff !important; border: 1px solid rgba(255,255,255,0.3); }
.card-image-placeholder { width: 100%; height: 100%; background: #1e293b; }

.tools-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.tool-card { background: var(--bg-card); border: 1px solid var(--border); padding: 40px 30px; border-radius: var(--radius-md); text-align: center; text-decoration: none; color: var(--text-main); transition: all 0.3s; box-shadow: var(--shadow-sm); position: relative; overflow: hidden; }
.tool-card::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 4px; background: var(--primary); transform: scaleX(0); transition: transform 0.3s cubic-bezier(0.165, 0.84, 0.44, 1); transform-origin: left; }
.tool-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); border-color: var(--primary); }
.tool-card:hover::before { transform: scaleX(1); }
.tool-icon { font-size: 3.5rem; margin-bottom: 20px; transition: transform 0.3s; }
.tool-card:hover .tool-icon { transform: scale(1.1); }
.tool-title { font-size: 1.6rem; font-weight: 800; margin-bottom: 12px; color: var(--text-main); }
.tool-desc { color: var(--text-muted); font-size: 1.05rem; margin: 0; line-height: 1.6; }

/* Newsletter Box (High-End) */
.newsletter-box { background: #111827; color: #fff; padding: 60px 50px; border-radius: var(--radius-lg); display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 40px; box-shadow: var(--shadow-hover); position: relative; overflow: hidden; border: 1px solid rgba(255,255,255,0.05); width: 100%; }
.newsletter-box::after { content: ''; position: absolute; top: -50%; right: -10%; width: 500px; height: 500px; background: radial-gradient(circle, rgba(230,57,70,0.15) 0%, transparent 70%); border-radius: 50%; pointer-events: none; }
.nl-content { flex: 1.5; min-width: 300px; position: relative; z-index: 2; }
.nl-content h2 { font-family: 'Inter Display', sans-serif; color: #fff; font-size: 2.6rem; margin-bottom: 12px; letter-spacing: -0.5px; }
.nl-content p { font-size: 1.1rem; margin: 0; color: #cbd5e1; line-height: 1.6; }
.nl-form-wrap { flex: 1; min-width: 320px; position: relative; z-index: 2; width: 100%; }

/* Desktop Overlapping Form Styling */
.nl-form { display: flex; width: 100%; position: relative; }
.nl-form input { width: 100%; padding: 18px 160px 18px 20px; border: 1px solid rgba(255,255,255,0.15); border-radius: 12px; background: rgba(255,255,255,0.05); color: #fff; font-size: 1.05rem; outline: none; font-family: 'Inter', sans-serif; transition: border-color 0.3s; }
.nl-form input:focus { border-color: rgba(255,255,255,0.3); }
.nl-form input::placeholder { color: #94a3b8; }
.nl-form button { position: absolute; right: 6px; top: 6px; bottom: 6px; padding: 0 24px; border: none; border-radius: 8px; background: var(--primary); color: #fff; font-weight: 700; font-size: 1rem; cursor: pointer; transition: all 0.3s; white-space: nowrap; box-shadow: 0 4px 15px rgba(230,57,70,0.3); }
.nl-form button:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: 0 6px 20px rgba(230,57,70,0.5); }

/* Mobile Subscribe Form Fix */
@media (max-width: 992px) {
    .newsletter-box { flex-direction: column; text-align: left; padding: 40px 30px; }
    .nl-form-wrap { min-width: 100%; }
}
@media (max-width: 576px) {
    .nl-form { flex-direction: column; gap: 12px; }
    .nl-form input { padding: 16px 20px; } 
    .nl-form button { position: static; width: 100%; padding: 16px 20px; } 
}

/* --------------------------------------------------------------------------
   SINGLE POST LAYOUT & FLOATING SIDEBAR
--------------------------------------------------------------------------- */
.pt-40 { padding-top: 40px; }
.single-layout-wrapper { display: flex; gap: 50px; align-items: flex-start; justify-content: center; padding-top: 50px; width: 100%; max-width: var(--container-width); margin: 0 auto; }
.primary-content { flex: 1; min-width: 0; width: 100%; max-width: 780px; }
.single-sidebar { width: 340px; flex-shrink: 0; }

@media (min-width: 992px) {
    .single-sidebar { position: sticky; top: 110px; height: max-content; align-self: flex-start; z-index: 10; padding-bottom: 30px; }
}
@media (max-width: 991px) {
    .single-layout-wrapper { flex-direction: column; gap: 40px; }
    .single-sidebar { width: 100%; }
}

.article-with-share { display: flex; gap: 25px; align-items: flex-start; }
.article-main-body { flex: 1; min-width: 0; width: 100%; }
.floating-social-share { position: sticky; top: 100px; width: 50px; display: flex; flex-direction: column; align-items: center; gap: 12px; flex-shrink: 0; z-index: 10; }
.share-text { font-size: 0.75rem; color: var(--text-muted); text-align: center; text-transform: uppercase; line-height: 1.2; margin-bottom: 5px; font-weight: 700; }
.social-circle { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; text-decoration: none; transition: transform 0.2s; box-shadow: var(--shadow-sm); }
.social-circle:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.social-circle svg { width: 18px; height: 18px; fill: currentColor; }
.sc-fb { background-color: #3b5998; }
.sc-x { background-color: #000; }
.sc-gn { background-color: #fff; color: #4285F4; border: 1px solid var(--border); box-shadow: none; }
@media (max-width: 768px) { .floating-social-share { display: none; } }

/* --------------------------------------------------------------------------
   ARTICLE HEADER & CONTENT
--------------------------------------------------------------------------- */
.post-header-clean { margin-bottom: 30px; }
.post-header-clean .entry-title { font-family: 'Inter', sans-serif; font-size: 2.8rem; font-weight: 800; color: var(--text-main); line-height: 1.3; margin-bottom: 20px; letter-spacing: -1px; }
.post-header-clean .post-excerpt { border-left: 3px solid var(--primary); padding-left: 15px; font-size: 1.2rem; color: var(--text-muted); margin-bottom: 25px; line-height: 1.6; }
.post-meta-bar { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--border); padding-bottom: 15px; margin-bottom: 15px; font-size: 0.85rem; color: var(--text-muted); }
.meta-left { text-transform: uppercase; color: var(--text-muted); }
.meta-left .author-name { color: var(--primary-dark); font-weight: 600; text-transform: none; }
.meta-right { display: flex; align-items: center; gap: 5px; color: var(--text-muted); }
.write-comment-link { display: inline-flex; align-items: center; gap: 8px; color: var(--text-muted); font-size: 0.9rem; text-decoration: none; margin-bottom: 25px; font-weight: 600; }
.write-comment-link:hover { color: var(--primary-dark); }
.post-featured-image { margin-bottom: 30px; }
.post-featured-image img { width: 100%; border-radius: var(--radius-lg); object-fit: cover; box-shadow: var(--shadow-md); }

@media (max-width: 768px) {
    .post-header-clean .entry-title { font-size: 2rem; letter-spacing: -0.5px; }
    .post-meta-bar { flex-direction: column; align-items: flex-start; gap: 10px; }
}

.entry-content { font-size: 1.125rem; line-height: 1.85; color: var(--text-main); }
.entry-content p { margin-bottom: 1.6em; }
.entry-content h2, .entry-content h3, .entry-content h4 { line-height: 1.3; margin-top: 1.8em; margin-bottom: 0.8em; }
.entry-content ul { list-style-type: disc; margin-bottom: 1.6em; padding-left: 2em; line-height: 1.85; }
.entry-content ol { list-style-type: decimal; margin-bottom: 1.6em; padding-left: 2em; line-height: 1.85; }
.entry-content li { margin-bottom: 0.5em; }
.entry-content img { border-radius: 8px; margin: 1.5em auto; display: block; }
.entry-content blockquote { border-left: 4px solid var(--primary); padding-left: 20px; margin: 1.5em 0; font-style: italic; color: var(--text-muted); }

/* Feedback Widget */
.article-feedback-box { display: flex; align-items: center; flex-wrap: wrap; gap: 15px; margin: 40px 0; padding: 20px; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-md); box-shadow: var(--shadow-sm); }
.feedback-question { font-weight: 700; color: var(--text-main); font-size: 1.05rem; }
.feedback-buttons { display: flex; gap: 10px; }
.feedback-btn { background: transparent; border: 1px solid var(--border); color: var(--text-main); padding: 6px 16px; border-radius: 4px; cursor: pointer; font-weight: 600; transition: all 0.2s; }
.feedback-btn:hover { border-color: var(--primary-dark); color: var(--primary-dark); background: rgba(0,0,0,0.02); }

/* TAGS */
.tags-links { font-size: 0.95rem; font-weight: 600; color: var(--text-muted); }
.tags-links a { color: var(--primary-dark); text-decoration: underline; margin-right: 8px; }
.tags-links a:hover { color: var(--primary); }

/* Author Bio Box */
.author-bio-box { display: flex; gap: 20px; background: var(--bg-card); padding: 30px; border: 1px solid var(--border); border-radius: var(--radius-md); box-shadow: var(--shadow-sm); margin-top: 50px; align-items: center; }
.author-avatar img { border-radius: 50%; display: block; }
.author-info h4 { margin: 0 0 10px 0; font-size: 1.3rem; color: var(--text-main); }
.author-desc { margin: 0 0 10px 0; line-height: 1.6; color: var(--text-main); }
.author-link { font-weight: bold; text-decoration: underline; color: var(--primary-dark); }

/* --------------------------------------------------------------------------
   SIDEBAR WIDGETS
--------------------------------------------------------------------------- */
.sidebar-widget { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-md); margin-bottom: 30px; box-shadow: 0 2px 10px rgba(0,0,0,0.03); }
.sidebar-widget .widget-title { font-family: 'Inter', sans-serif; font-size: 1.35rem; font-weight: 800; color: var(--text-main); margin: 0; padding: 20px 20px 15px; border-bottom: none; }
.widget-tabs { display: flex; border-bottom: 1px solid var(--border); margin-bottom: 20px; padding: 0 20px; gap: 20px; }
.tab-btn { background: none; border: none; padding: 0 0 12px 0; font-family: 'Inter', sans-serif; font-size: 0.95rem; font-weight: 600; color: var(--text-muted); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; transition: all 0.2s; }
.tab-btn.active { color: var(--text-main); border-bottom: 2px solid #f97316; }

.sidebar-post-list { list-style: none !important; padding: 0 20px 20px !important; margin: 0 !important; }
.sidebar-post-item { border: 1px solid var(--border); border-radius: 10px; margin-bottom: 15px; box-shadow: 0 4px 6px rgba(0,0,0,0.02); background: var(--bg-card); transition: box-shadow 0.2s; }
.sidebar-post-item:last-child { margin-bottom: 0; }
.sidebar-post-item a { display: flex; gap: 15px; align-items: center; text-decoration: none; padding: 12px; }
.sidebar-post-thumb { width: 95px; height: 65px; flex-shrink: 0; border-radius: 6px; overflow: hidden; background-color: var(--bg-body); }
.sidebar-post-thumb img { width: 100%; height: 100%; object-fit: cover; }
.sidebar-post-info h4 { margin: 0; font-size: 0.92rem; line-height: 1.4; font-family: 'Inter', sans-serif; font-weight: 600; color: var(--text-main); transition: color 0.2s; }
.sidebar-post-item a:hover .sidebar-post-info h4 { color: var(--primary-dark); }
.sidebar-post-item:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.06); }

/* --------------------------------------------------------------------------
   TRENDING NEWS CARDS & PAGE SPECIFICS
--------------------------------------------------------------------------- */
.trending-filter-bar { display: flex; margin-bottom: 30px; width: 100%; }
.trending-filter-bar form { width: 100%; display: flex; gap: 15px; }
.trending-filter-bar input { flex: 1; padding: 14px 20px; border: 1px solid var(--border); border-radius: 6px; background: var(--bg-card); color: var(--text-main); font-family: 'Inter', sans-serif; font-size: 1.05rem; transition: border-color 0.2s; outline: none; }
.trending-filter-bar input:focus { border-color: var(--primary); }
.trending-filter-bar button { padding: 14px 35px; background: #f97316; color: #fff; border: none; border-radius: 6px; font-weight: 700; font-size: 1rem; cursor: pointer; transition: background 0.2s; flex-shrink: 0;}
.trending-filter-bar button:hover { background: #ea580c; }

.news-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; margin-bottom: 40px; width: 100%; }
.news-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; overflow: hidden; display: flex; flex-direction: column; transition: box-shadow 0.3s, transform 0.3s; box-shadow: var(--shadow-sm); }
.news-card:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.news-card-thumb { position: relative; height: 170px; overflow: hidden; }
.news-card-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.news-card:hover .news-card-thumb img { transform: scale(1.05); }
.news-card-img-overlay { position: absolute; bottom: 0; left: 0; right: 0; padding: 25px 15px 10px; background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, transparent 100%); color: #fff; font-size: 0.95rem; font-weight: 700; line-height: 1.3; pointer-events: none; }

.news-card-content { padding: 18px; display: flex; flex-direction: column; flex-grow: 1; }
.news-card-title { font-family: 'Inter', sans-serif; font-size: 1.05rem; font-weight: 700; margin: 0 0 10px; line-height: 1.4; color: var(--text-main); }
.news-card-excerpt { font-size: 0.9rem; color: var(--text-muted); line-height: 1.5; margin-bottom: 15px; flex-grow: 1; }
.news-card-meta { font-size: 0.8rem; color: var(--text-muted); font-weight: 600; display: flex; align-items: center; gap: 5px; }

.trending-pagination { display: flex; flex-wrap: wrap; gap: 6px; margin: 20px 0 10px; }
.trending-pagination .page-numbers { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; height: 40px; padding: 0 10px; border: 1px solid var(--border); background: var(--bg-card); color: var(--text-muted); font-weight: 600; border-radius: 4px; text-decoration: none; transition: all 0.2s; }
.trending-pagination .page-numbers:hover { border-color: var(--text-muted); color: var(--text-main); }
.trending-pagination .current { border-color: var(--text-main); color: var(--text-main); background: transparent; }
.page-count-text { font-size: 0.9rem; font-weight: 600; color: var(--text-muted); margin-bottom: 40px; }

.trending-feedback { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 15px; padding: 25px 30px; background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; margin-top: 20px; box-shadow: var(--shadow-sm); width: 100%; }
.tf-question { font-weight: 600; color: var(--text-main); font-size: 1.05rem; }
.tf-buttons { display: flex; gap: 10px; }
.tf-btn { padding: 10px 30px; border: 1px solid var(--border); background: transparent; border-radius: 6px; font-weight: 600; color: var(--text-main); cursor: pointer; transition: all 0.2s; font-size: 0.95rem; }
.tf-btn:hover { border-color: var(--text-muted); background: var(--bg-body); }

@media (max-width: 768px) {
    .trending-filter-bar form { flex-direction: column; }
    .trending-filter-bar button { width: 100%; }
    .trending-feedback { flex-direction: column; align-items: flex-start; }
}

/* --------------------------------------------------------------------------
   COMMENTS SECTION
--------------------------------------------------------------------------- */
.post-comments-wrapper { margin-top: 60px; padding-top: 40px; border-top: 1px solid var(--border); width: 100%; }
#comments { margin-top: 0; padding-top: 0; border-top: none; }
.comments-title { font-family: 'Inter Display', sans-serif; font-size: 1.8rem; font-weight: 800; color: var(--text-main); margin-bottom: 30px; }
.comment-list { list-style: none; padding: 0; margin: 0 0 40px 0; }
.comment-list li.comment { margin-bottom: 25px; }
.comment-list li.comment ul.children { margin-top: 25px; margin-left: 5%; padding-left: 0; list-style: none; border-left: 2px solid var(--border); padding-left: 20px; }
.comment-body { background: var(--bg-card); padding: 25px; border-radius: var(--radius-md); border: 1px solid var(--border); box-shadow: var(--shadow-sm); }
.comment-meta { display: flex; align-items: center; gap: 15px; margin-bottom: 15px; }
.comment-meta img { border-radius: 50%; width: 45px; height: 45px; }
.comment-author { font-weight: 700; color: var(--text-main); font-size: 1.1rem; }
.comment-metadata { font-size: 0.85rem; color: var(--text-muted); }
.comment-metadata a { color: var(--text-muted); text-decoration: none; }
.comment-content { font-size: 1.05rem; line-height: 1.6; color: var(--text-main); }
.reply { margin-top: 15px; }
.reply a { font-size: 0.85rem; font-weight: 700; color: var(--primary-dark); text-transform: uppercase; text-decoration: none; display: inline-flex; align-items: center; gap: 5px; transition: opacity 0.2s; }
.reply a:hover { opacity: 0.8; }

.comment-respond { background: var(--bg-card); padding: 30px; border-radius: var(--radius-md); border: 1px solid var(--border); box-shadow: var(--shadow-sm); }
.comment-reply-title { font-family: 'Inter Display', sans-serif; font-size: 1.5rem; margin-bottom: 20px; font-weight: 800; color: var(--text-main); }
.comment-form label { display: block; margin-bottom: 8px; font-weight: 600; color: var(--text-main); font-size: 0.95rem; }
.comment-form input[type="text"], .comment-form input[type="email"], .comment-form input[type="url"], .comment-form textarea { width: 100%; padding: 12px 15px; border: 1px solid var(--border); border-radius: 6px; background: var(--bg-body); color: var(--text-main); font-family: 'Inter', sans-serif; margin-bottom: 20px; }
.comment-form input:focus, .comment-form textarea:focus { outline: none; border-color: var(--primary); }
.form-submit { margin-bottom: 0; }
.form-submit input[type="submit"] { background: var(--primary); color: #ffffff; border: none; padding: 12px 30px; font-weight: 700; font-size: 1rem; border-radius: 6px; cursor: pointer; transition: background 0.2s; }
.form-submit input[type="submit"]:hover { opacity: 0.9; }
.comment-notes, .logged-in-as { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 20px; }

/* --------------------------------------------------------------------------
   PREMIUM FOOTER
--------------------------------------------------------------------------- */
.site-footer { 
    background: #0f172a; 
    color: #94a3b8;
    padding: 80px 0 30px; 
    margin-top: 100px; 
    font-size: 0.95rem;
    border-top: 4px solid var(--primary);
    width: 100%;
}

.footer-grid { 
    width: 100%; 
    max-width: var(--container-width); 
    margin: 0 auto 60px; 
    display: grid; 
    grid-template-columns: 2fr 1fr 1fr 1fr; 
    gap: 50px; 
    padding: 0 20px; 
}

.footer-col h3 { 
    font-size: 1.25rem; 
    margin-bottom: 25px; 
    color: #ffffff; 
    font-family: 'Inter Display', sans-serif;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.footer-col h3::after {
    content: '';
    display: block;
    width: 40px;
    height: 3px;
    background: var(--primary);
    margin-top: 15px;
    border-radius: 2px;
}

.footer-logo {
    font-family: 'Inter Display', sans-serif;
    font-size: 2rem;
    font-weight: 800;
    color: #ffffff;
    text-transform: uppercase;
    text-decoration: none;
    display: block;
    margin-bottom: 20px;
    letter-spacing: -1px;
}

.footer-logo span { color: var(--primary); }

.footer-desc {
    line-height: 1.8;
    margin-bottom: 25px;
}

.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col ul li { margin-bottom: 15px; }
.footer-col a { color: #94a3b8; text-decoration: none; transition: color 0.2s, padding-left 0.2s; display: inline-block; }
.footer-col a:hover { color: #ffffff; padding-left: 5px; }

.footer-socials { display: flex; gap: 15px; }
.footer-socials a { display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; background: #1e293b; border-radius: 50%; color: #fff; transition: all 0.3s; }
.footer-socials a:hover { background: var(--primary); transform: translateY(-3px); padding-left: 0; }
.footer-socials svg { width: 18px; height: 18px; fill: currentColor; }

.site-info { 
    width: 100%; 
    max-width: var(--container-width); 
    margin: 0 auto; 
    border-top: 1px solid #1e293b; 
    padding-top: 30px; 
    text-align: center; 
    color: #64748b; 
    font-size: 0.9rem;
}

@media (max-width: 992px) {
    .footer-grid { grid-template-columns: repeat(2, 1fr); gap: 40px; }
}
@media (max-width: 576px) {
    .footer-grid { grid-template-columns: 1fr; gap: 40px; }
    .site-footer { padding: 60px 0 30px; }
}

/* --------------------------------------------------------------------------
   PAGINATION
--------------------------------------------------------------------------- */
.pagination-wrapper { margin: 60px 0; text-align: center; width: 100%; }
.nav-links { display: inline-flex; gap: 8px; }
.nav-links a, .nav-links span { padding: 12px 18px; border: 1px solid var(--border); color: var(--text-main); font-weight: 600; border-radius: 4px; }
.nav-links .current { background: var(--primary); color: white; border-color: var(--primary); }
/* Dark mode logo fallback: keep the configured primary logo visible when no separate dark logo is set. */
body.dark-mode .light-logo.no-dark-logo { display: block !important; }
