/* ═══════════════════════════════════════════════════════════════
   AUTOVEN BLOG — COMPLETE CSS STYLESHEET
   Unified for Blog Posts + Product Page Navigation
   Version: 3.0 — Production Ready
   ═══════════════════════════════════════════════════════════════ */


/* ── Reset & Base ─────────────────────────────────────────────── */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}


/* ── CSS Variables ────────────────────────────────────────────── */
:root {
    /* Brand Blues */
    --primary-blue:       #0071e3;
    --dark-blue:          #005bb5;
    --accent-blue:        #0071e3;
    --accent-blue-hover:  #005bb5;
    --accent-cyan:        #00a3ff;

    /* Text */
    --text-primary:   #1a1a1a;
    --text-secondary: #4a4a4a;
    --text-tertiary:  #666;

    /* Backgrounds */
    --bg-white:   #ffffff;
    --bg-light:   #f8f8f8;
    --bg-lighter: #fafafa;

    /* UI */
    --border-color:   #e5e5e5;
    --success-green:  #34c759;
    --warning-orange: #ff9800;
    --error-red:      #f44336;
    --info-blue:      #2196f3;

    /* Glass / Shadows */
    --glass-border: rgba(255, 255, 255, 0.15);
    --shadow-sm:    0 2px 8px  rgba(0, 0, 0, 0.06);
    --shadow-md:    0 4px 16px rgba(0, 0, 0, 0.10);
    --shadow-lg:    0 20px 40px rgba(0, 0, 0, 0.30);

    /* Typography */
    --font-weight-medium:   500;
    --font-weight-semibold: 600;
    --font-weight-bold:     700;

    /* Transitions */
    --transition-fast:   0.2s ease;
    --transition-normal: 0.3s ease;
}


/* ── Body ─────────────────────────────────────────────────────── */
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto',
                 'Helvetica', 'Arial', sans-serif;
    background: var(--bg-lighter);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}


/* ═══════════════════════════════════════════════════════════════
   NAVIGATION — Unified (matches product pages exactly)
   ═══════════════════════════════════════════════════════════════ */

/* ========== NAVIGATION ========== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 0;
    background: rgba(220, 214, 208, 0.55); /* light, logo visible */
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.22);
    backdrop-filter: blur(35px);
    -webkit-backdrop-filter: blur(35px);
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.2);
}

/* Remove any overlay effects */
.navbar::after,
.navbar::before {
    display: none !important;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
}

/* Desktop menu */
.nav-menu {
    display: flex;
    align-items: center;
    gap: 2rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-item {
    position: relative;
}

.nav-link {
    text-decoration: none; /* ✅ removes underline */
    font-size: 0.9375rem;
    font-weight: 500;
    color: rgba(30, 41, 59, 0.95);
    transition: color 0.2s ease;
    position: relative;
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav-link:hover {
    color: var(--text-primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-blue);
    transition: width var(--transition-normal);
}

.nav-link:hover::after {
    width: 100%;
}

/* Dropdown */
.dropdown-arrow {
    margin-left: 4px;
    transition: transform var(--transition-fast);
}

.has-dropdown:hover .dropdown-arrow {
    transform: rotate(180deg);
}

.nav-dropdown {
    position: absolute;
    top: calc(100% + 20px);
    left: 50%;
    transform: translateX(-50%) translateY(-10px);
    background: rgba(17, 17, 17, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 0.5rem 0;
    min-width: 160px;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-normal);
    box-shadow: var(--shadow-lg);
    z-index: 100;
}

.has-dropdown:hover .nav-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.nav-dropdown li {
    list-style: none;
}

.nav-dropdown a {
    display: block;
    padding: 0.75rem 1.25rem;
    color: var(--text-secondary);
    font-size: 0.9375rem;
    transition: all var(--transition-fast);
}

.nav-dropdown a:hover {
    background: rgba(0, 113, 227, 0.1);
    color: var(--accent-blue);
}

/* CTA Button */
.nav-cta {
    background: #0071e3;
    color: #ffffff !important; /* ✅ white text on blue button */
    padding: 0.5rem 1.25rem;
    border-radius: 20px;
    transition: all 0.2s ease;
    font-weight: 600;
    text-decoration: none;
}

.nav-cta:hover {
    background: #005bb5;
    color: #ffffff !important;
    transform: translateY(-1px);
}
 .nav-item-cta {
        display: block; /* show inside dropdown */
    }

    .nav-link-cta {
        font-weight: var(--font-weight-semibold);
        color: #ffffff;
    }


.nav-cta::after {
    display: none;
}

/* Logo */
.logo-img {
    height: 42px;
    width: auto;
    display: block;
    object-fit: contain;
    filter: drop-shadow(0 3px 8px rgba(0, 0, 0, 0.35));
    transition: transform 0.2s ease, filter 0.2s ease;
}

.nav-logo:hover .logo-img {
    transform: scale(1.08);
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.45));
}

.logo-text {
    display: none; /* ✅ hides "AUTOVEN" text under logo */
}

/* Mobile toggle */
.nav-toggle {
    display: none;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    z-index: 1100;
}

.nav-toggle span {
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    transition: all var(--transition-fast);
}

/* MOBILE NAVIGATION*/  

@media (max-width: 768px) {
         .nav-cta {
        display: none !important;
    }

    .nav-menu {
        position: absolute;
        top: calc(100% + 12px);
        left: 0;
        right: 0;
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
        padding: 1rem 1.25rem;
        background: rgba(20, 20, 30, 0.96);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border: 1px solid rgba(255, 255, 255, 0.08);
        border-radius: 12px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transform: translateY(-10px);
        transition: all 0.3s ease;
        z-index: 1050;
    }

    .nav-menu.active {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateY(0);
    }

    .nav-item {
        width: 100%;
    }

    /* ✅ KEY FIX — hardcoded white, NOT var(--text-primary) */
    .nav-menu .nav-link,
    .nav-menu .nav-item .nav-link {
        display: block !important;
        width: 100%;
        padding: 0.9rem 0;
        color: #1a1a1a !important;          /* ← force white text */
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
        font-size: 1rem;
        text-decoration: none;
        opacity: 1 !important;
        visibility: visible !important;
    }

    .nav-menu .nav-item:last-child .nav-link {
        border-bottom: none;
    }

    .nav-menu .nav-link:hover {
        color: #1a1a1a !important;
        opacity: 0.8 !important;
    }

    /* ✅ Also fix mobile CTA inside menu */
    .nav-item-mobile-cta {
        display: block;
        width: 100%;
        margin-top: 0.5rem;
    }

    .nav-link-mobile-cta {
        display: block !important;
        width: 100%;
        padding: 0.95rem 1rem;
        color: #1a1a1a !important;
        font-weight: 600;
        background: linear-gradient(135deg, #0071e3 0%, #00a3ff 100%);
        border-radius: 12px;
        text-align: center;
        border-bottom: none !important;
        text-decoration: none;
    }

    .nav-link::after { display: none !important; }
}
/* ═══════════════════════════════════════════════════════════════
   READING PROGRESS BAR
   ═══════════════════════════════════════════════════════════════ */

.reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: rgba(0, 0, 0, 0.05);
    z-index: 1001;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-blue) 0%, var(--accent-cyan) 100%);
    width: 0%;
    transition: width 0.1s linear;
}


/* ═══════════════════════════════════════════════════════════════
   BLOG CONTAINER — 3-COLUMN LAYOUT
   ═══════════════════════════════════════════════════════════════ */

.blog-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 110px 2rem 60px;
    display: grid;
    grid-template-columns: 280px 1fr 320px;
    gap: 3rem;
    align-items: start;
}


/* ═══════════════════════════════════════════════════════════════
   LEFT SIDEBAR — TABLE OF CONTENTS
   ═══════════════════════════════════════════════════════════════ */

.blog-sidebar-left {
    position: sticky;
    top: 90px;
}

.toc-wrapper {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.toc-title {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.toc-nav {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.toc-link {
    padding: 0.625rem 0.875rem;
    color: var(--text-tertiary);
    font-size: 0.9375rem;
    border-left: 2px solid transparent;
    transition: all var(--transition-fast);
    border-radius: 4px;
    text-decoration: none;
    display: block;
    line-height: 1.4;
}

.toc-link:hover {
    color: var(--primary-blue);
    background: rgba(0, 113, 227, 0.05);
}

.toc-link.active {
    color: var(--primary-blue);
    background: rgba(0, 113, 227, 0.08);
    border-left-color: var(--primary-blue);
    font-weight: 600;
}


/* ═══════════════════════════════════════════════════════════════
   MAIN CONTENT AREA
   ═══════════════════════════════════════════════════════════════ */

.blog-main {
    background: var(--bg-white);
    border-radius: 12px;
    padding: 3rem;
    box-shadow: var(--shadow-sm);
    animation: fadeInUp 0.5s ease;
    min-width: 0; /* prevent grid blowout */
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Breadcrumbs */
.breadcrumbs {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    font-size: 0.875rem;
    flex-wrap: wrap;
}

.breadcrumbs a {
    color: var(--text-tertiary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.breadcrumbs a:hover {
    color: var(--primary-blue);
}

.breadcrumbs .separator {
    color: #ccc;
}

/* Article Header */
.article-header {
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.article-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-bottom: 1.5rem;
    font-size: 0.875rem;
}

.meta-badge {
    padding: 0.25rem 0.75rem;
    background: var(--primary-blue);
    color: white;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.meta-divider { color: #ccc; }

.meta-date,
.meta-read {
    color: var(--text-tertiary);
}

.article-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    line-height: 1.2;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

.article-lead {
    font-size: 1.25rem;
    line-height: 1.7;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

/* Author */
.author-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.author-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--primary-blue);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.author-avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.author-name {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 1rem;
}

.author-title {
    font-size: 0.875rem;
    color: var(--text-tertiary);
}

/* Article Body */
.article-content {
    font-size: 1.0625rem;
    line-height: 1.8;
    color: #333;
}

.content-section {
    margin-bottom: 3rem;
}

.content-section h2 {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-top: 3rem;
    margin-bottom: 1.25rem;
    line-height: 1.3;
    scroll-margin-top: 100px;
}

.content-section h3 {
    font-size: 1.375rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-top: 2rem;
    margin-bottom: 1rem;
    scroll-margin-top: 100px;
}

.content-section h4 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
    margin-top: 1.5rem;
}

.content-section p {
    margin-bottom: 1.25rem;
}

.content-section p strong {
    color: var(--text-primary);
    font-weight: 600;
}

.content-section ul,
.content-section ol {
    margin: 1.5rem 0;
    padding-left: 1.5rem;
}

.content-section li {
    margin-bottom: 0.75rem;
    line-height: 1.7;
}

.content-section a {
    color: var(--primary-blue);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color var(--transition-fast);
}

.content-section a:hover {
    border-bottom-color: var(--primary-blue);
}


/* ═══════════════════════════════════════════════════════════════
   CALLOUT BOXES
   ═══════════════════════════════════════════════════════════════ */

.callout {
    display: flex;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    border-radius: 8px;
    margin: 2rem 0;
}

.callout-info    { background: #e3f2fd; border-left: 4px solid var(--info-blue); }
.callout-warning { background: #fff3e0; border-left: 4px solid var(--warning-orange); }
.callout-success { background: #e8f5e9; border-left: 4px solid var(--success-green); }
.callout-error   { background: #ffebee; border-left: 4px solid var(--error-red); }

.callout-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.callout-content strong {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    font-size: 1.0625rem;
}

.callout-content p { margin-bottom: 0; }


/* ═══════════════════════════════════════════════════════════════
   STATS GRID
   ═══════════════════════════════════════════════════════════════ */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.stat-card {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1.5rem;
    text-align: center;
    transition: all var(--transition-normal);
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary-blue);
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-tertiary);
    font-weight: 500;
}


/* ═══════════════════════════════════════════════════════════════
   LISTS
   ═══════════════════════════════════════════════════════════════ */

/* Check List */
.check-list {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
}

.check-list li {
    padding: 0.75rem 0 0.75rem 2rem;
    position: relative;
    color: var(--text-secondary);
    line-height: 1.7;
}

.check-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--success-green);
    font-weight: 700;
    font-size: 1.25rem;
}

/* Numbered List */
.numbered-list {
    counter-reset: item;
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
}

.numbered-list li {
    padding: 0.75rem 0 0.75rem 2.5rem;
    position: relative;
    color: var(--text-secondary);
}

.numbered-list li::before {
    content: counter(item);
    counter-increment: item;
    position: absolute;
    left: 0;
    width: 24px;
    height: 24px;
    background: var(--primary-blue);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    font-weight: 700;
}


/* ═══════════════════════════════════════════════════════════════
   CTA BOX (inline in article)
   ═══════════════════════════════════════════════════════════════ */

.cta-box {
    background: linear-gradient(135deg, rgba(0,113,227,0.10) 0%, rgba(0,163,255,0.05) 100%);
    border: 2px solid var(--primary-blue);
    border-radius: 12px;
    padding: 2rem;
    margin: 2.5rem 0;
    text-align: center;
}

.cta-box h3 {
    color: var(--text-primary);
    margin-bottom: 1rem;
    margin-top: 0;
}

.cta-box p {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
}


/* ═══════════════════════════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════════════════════════ */

.btn {
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.9375rem;
    transition: all var(--transition-fast);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: none;
    text-decoration: none;
    font-family: inherit;
}

.btn-primary {
    background: var(--primary-blue);
    color: white;
}

.btn-primary:hover {
    background: var(--dark-blue);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 113, 227, 0.3);
}

.btn-block { width: 100%; }


/* ═══════════════════════════════════════════════════════════════
   ARTICLE FOOTER
   ═══════════════════════════════════════════════════════════════ */

.article-footer {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.article-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tag {
    padding: 0.375rem 0.875rem;
    background: #f0f0f0;
    color: var(--text-tertiary);
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: all var(--transition-fast);
}

.tag:hover {
    background: var(--primary-blue);
    color: white;
}

.article-share {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.share-label {
    font-weight: 600;
    color: var(--text-tertiary);
    font-size: 0.9375rem;
}

.share-btn {
    padding: 0.5rem 1rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-tertiary);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-fast);
    text-decoration: none;
}

.share-btn:hover {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
    color: white;
    transform: translateY(-2px);
}


/* ═══════════════════════════════════════════════════════════════
   RIGHT SIDEBAR
   ═══════════════════════════════════════════════════════════════ */

.blog-sidebar-right {
    position: sticky;
    top: 90px;
}

.sidebar-card {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.sidebar-card h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1.25rem;
    margin-top: 0;
}

/* Subscribe */
.subscribe-card {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.subscribe-card h3,
.subscribe-card p { text-align: center; }

.subscribe-card p {
    color: var(--text-tertiary);
    font-size: 0.9375rem;
    margin-bottom: 1.25rem;
}

.subscribe-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.subscribe-form input {
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 0.9375rem;
    font-family: inherit;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.subscribe-form input:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(0, 113, 227, 0.1);
}

/* Recent Posts */
.recent-posts {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.recent-post {
    display: flex;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: 6px;
    transition: all var(--transition-fast);
    text-decoration: none;
    color: inherit;
}

.recent-post:hover { background: var(--bg-light); }

.post-thumb {
    width: 48px;
    height: 48px;
    background: #f0f0f0;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.post-thumb img {
    width: 100%;
    height: 100%;
    border-radius: 6px;
    object-fit: cover;
}

.post-title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.4;
    margin-bottom: 0.25rem;
}

.post-date {
    font-size: 0.8125rem;
    color: #999;
}

/* Categories */
.categories {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.category-tag {
    padding: 0.375rem 0.875rem;
    background: #f0f0f0;
    color: var(--text-tertiary);
    border-radius: 20px;
    font-size: 0.8125rem;
    font-weight: 500;
    transition: all var(--transition-fast);
    text-decoration: none;
}

.category-tag:hover {
    background: var(--primary-blue);
    color: white;
}

/* CTA Card */
.cta-card {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
    text-align: center;
}

.cta-card h3 { text-align: center; }

.cta-card p {
    color: var(--text-tertiary);
    font-size: 0.9375rem;
    margin-bottom: 1.25rem;
}


/* ═══════════════════════════════════════════════════════════════
   FAQ ACCORDION
   ═══════════════════════════════════════════════════════════════ */

.faq-section { margin-top: 3rem; }

.faq-item {
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: var(--bg-light);
    margin-bottom: 0.75rem;
    overflow: hidden;
}

.faq-question {
    width: 100%;
    text-align: left;
    padding: 0.9rem 1rem;
    background: var(--bg-white);
    border: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    font-family: inherit;
    transition: background var(--transition-fast);
}

.faq-question:hover { background: #f3f7ff; }

.faq-question-text {
    flex: 1;
    padding-right: 0.75rem;
}

.faq-icon {
    font-size: 1.25rem;
    transition: transform var(--transition-fast);
    color: var(--text-tertiary);
}

.faq-item.open .faq-icon {
    transform: rotate(90deg);
    color: var(--primary-blue);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    padding: 0 1rem;
    background: var(--bg-light);
    transition: max-height 0.3s ease;
}

.faq-item.open .faq-answer { max-height: 600px; }

.faq-answer-inner {
    padding: 0.75rem 0 1rem;
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.7;
}


/* ═══════════════════════════════════════════════════════════════
   BACK TO TOP
   ═══════════════════════════════════════════════════════════════ */

.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 48px;
    height: 48px;
    background: var(--primary-blue);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 1.25rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-normal);
    box-shadow: 0 4px 12px rgba(0, 113, 227, 0.3);
    z-index: 998;
    display: flex;
    align-items: center;
    justify-content: center;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: var(--dark-blue);
    transform: translateY(-4px);
    box-shadow: 0 6px 16px rgba(0, 113, 227, 0.4);
}


/* ═══════════════════════════════════════════════════════════════
   FOOTER — Unified (matches product pages)
   ═══════════════════════════════════════════════════════════════ */

.footer {
    background: #0f172a;
    color: #94a3b8;
    padding: 4rem 0 2rem;
    margin-top: 4rem;
}

.footer .container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.footer-logo .logo-img {
    height: 36px;
    filter: brightness(0) invert(1);
}

.footer-logo .logo-text {
    color: #f8fafc;
    font-size: 1.1rem;
    font-weight: 800;
    text-shadow: none;
}

.footer-tagline {
    font-size: 0.9rem;
    color: #64748b;
    margin-bottom: 1.5rem;
}

.footer-social {
    display: flex;
    gap: 1rem;
}

.footer-social a {
    color: #64748b;
    text-decoration: none;
    font-size: 0.875rem;
    transition: color var(--transition-fast);
}

.footer-social a:hover { color: #f8fafc; }

.footer-col h4 {
    color: #f8fafc;
    font-size: 0.875rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 1.25rem;
}

.footer-col ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-col ul li a {
    color: #64748b;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color var(--transition-fast);
}

.footer-col ul li a:hover { color: #f8fafc; }

.footer-bottom {
    border-top: 1px solid #1e293b;
    padding-top: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.875rem;
}

.footer-links {
    display: flex;
    gap: 1.5rem;
}

.footer-links a {
    color: #64748b;
    text-decoration: none;
    transition: color var(--transition-fast);
}

.footer-links a:hover { color: #f8fafc; }


/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════ */

/* 1200px — tighten columns */
@media (max-width: 1200px) {
    .blog-container {
        grid-template-columns: 240px 1fr 280px;
        gap: 2rem;
    }
    .blog-main { padding: 2rem; }
}

/* 1024px — hide left TOC sidebar */
@media (max-width: 1024px) {
    .blog-container {
        grid-template-columns: 1fr 300px;
    }
    .blog-sidebar-left { display: none; }
}

/* 768px — mobile layout */
@media (max-width: 768px) {

    /* ── Mobile Nav ── */
    .nav-menu {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 70px);
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: flex-start;
        padding: 2rem;
        gap: 1.5rem;
        transition: left var(--transition-normal);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        z-index: 999;
        overflow-y: auto;
    }

    .nav-menu.active { left: 0; }

    .nav-toggle { display: flex; }

    .nav-link { font-size: 1.125rem; }

    .nav-link::after { display: none; }

    /* Dropdown inline on mobile */
    .nav-dropdown {
        position: static;
        transform: none !important;
        opacity: 1;
        visibility: visible;
        background: transparent;
        border: none;
        box-shadow: none;
        backdrop-filter: none;
        padding: 0.5rem 0 0 1rem;
        min-width: unset;
        display: none;
    }

    .has-dropdown.open .nav-dropdown { display: block; }

    .nav-dropdown a {
        color: var(--text-secondary);
        font-size: 1rem;
        padding: 0.5rem 0.75rem;
    }

    .nav-dropdown a:hover {
        background: rgba(0, 113, 227, 0.08);
        color: var(--primary-blue);
    }

    /* ── Blog Layout ── */
    .blog-container {
        grid-template-columns: 1fr;
        padding: 90px 1rem 40px;
        gap: 2rem;
    }

    .blog-sidebar-right { position: static; }

    .blog-main { padding: 1.5rem; }

    .article-title { font-size: 1.75rem; }

    .article-lead { font-size: 1.0625rem; }

    .article-footer {
        flex-direction: column;
        align-items: flex-start;
    }

    .stats-grid { grid-template-columns: 1fr; }

    /* ── Footer ── */
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }
}

/* 480px — small phones */
@media (max-width: 480px) {
    .article-content { font-size: 1rem; }

    .content-section h2 { font-size: 1.5rem; }

    .article-share {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
    }

    .share-btn { width: 100%; text-align: center; }

    .footer-grid { grid-template-columns: 1fr; }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}


/* ═══════════════════════════════════════════════════════════════
   END OF STYLESHEET
   Version: 3.0 — Production Ready
   ═══════════════════════════════════════════════════════════════ */

/* Footer social icons */
.footer-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(248, 250, 252, 0.2);
    background: rgba(248, 250, 252, 0.06);
    color: #cbd5e1;
    transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}

.footer-social a svg {
    display: block;
}

.footer-social a:hover {
    background: #0071e3;
    border-color: #0071e3;
    color: #ffffff;
    transform: translateY(-3px);
}

/* Minimum readable size for small badges/labels */
.cs-m-label,
.chem-badge,
.fc-eta,
.india-label,
.rec-avoid,
.rec-primary,
.rec-secondary {
    font-size: 0.75rem;
}

/* Wide tables scroll inside their own box instead of widening the page on phones */
.table-scroll {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 1rem 0;
}

.table-scroll > table {
    margin: 0;
    min-width: 520px;
}

/* Code samples and long unbroken text never push the page wider than the screen */
pre, .code-block {
    max-width: 100%;
    overflow-x: auto;
}

@media (max-width: 480px) {
    .benefit-grid {
        grid-template-columns: 1fr !important;
    }
}


/* ===== Accessibility fixes (focus ring, skip link, reduced motion) ===== */
.skip-link {
    position: absolute;
    left: 16px;
    top: -60px;
    z-index: 100000;
    padding: 10px 16px;
    background: #0071e3;
    color: #fff;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    transition: top 0.15s ease;
}
.skip-link:focus { top: 12px; }
main:focus { outline: none; }
:focus-visible {
    outline: 2px solid #4da3ff;
    outline-offset: 3px;
}
.footer :focus-visible,
.navbar :focus-visible,
.site-header :focus-visible {
    outline-color: #0071e3;
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    [data-scroll-fade] { opacity: 1 !important; transform: none !important; }
}
