/**
 * Tools Ninja - Blog Styles
 */

/* ============================================
   BLOG HERO
   ============================================ */

.blog-hero {
    background: var(--bg-secondary);
    padding: 4rem 0 3rem;
    text-align: center;
    border-bottom: var(--border-thick) solid var(--accent-neon-green);
    box-shadow: 0 4px 0px rgba(0, 0, 0, 0.3);
}

.blog-hero-content h1 {
    font-size: 3rem;
    color: var(--accent-neon-green);
    text-shadow: 3px 3px 0px rgba(0, 0, 0, 0.5);
    margin-bottom: 0.75rem;
}

.blog-hero-content p {
    color: var(--text-secondary);
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto 2rem;
}

.blog-search {
    max-width: 500px;
    margin: 0 auto;
    position: relative;
}

.blog-search svg {
    position: absolute;
    left: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
}

.blog-search input {
    width: 100%;
    padding: 1rem 1rem 1rem 3.5rem;
    background: var(--bg-card);
    border: 3px solid var(--border-color);
    border-radius: 0;
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.2s ease;
}

.blog-search input:focus {
    outline: none;
    border-color: var(--accent-purple);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.2);
}

.blog-search input::placeholder {
    color: var(--text-secondary);
}

/* ============================================
   SECTION TITLES
   ============================================ */

.section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.section-title svg {
    color: var(--accent-purple);
}

/* ============================================
   FEATURED ARTICLES
   ============================================ */

.blog-featured {
    padding: 3rem 0;
    background: var(--bg-primary);
}

.featured-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.featured-card {
    background: var(--bg-card);
    border: 3px solid var(--border-color);
    border-radius: 0;
    overflow: hidden;
    transition: all 0.2s ease;
}

.featured-card:hover {
    transform: translateY(-4px);
    border-color: var(--accent-purple);
    box-shadow: 0 20px 40px rgba(139, 92, 246, 0.15);
}

.featured-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

.featured-image {
    height: 200px;
    background: rgba(57, 255, 20, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.featured-placeholder svg {
    width: 80px;
    height: 80px;
    stroke: var(--accent-purple);
    opacity: 0.6;
}

.featured-content {
    padding: 1.5rem;
}

.featured-content h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    line-height: 1.4;
}

.featured-content p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1rem;
}

/* ============================================
   ARTICLE CATEGORY BADGE
   ============================================ */

.article-category {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: rgba(139, 92, 246, 0.15);
    color: var(--accent-purple);
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 0;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ============================================
   ARTICLE META
   ============================================ */

.article-meta {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.article-meta span {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.article-meta svg {
    opacity: 0.7;
}

/* ============================================
   BLOG LAYOUT
   ============================================ */

.blog-articles {
    padding: 3rem 0;
}

.blog-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 3rem;
}

/* ============================================
   SIDEBAR
   ============================================ */

.blog-sidebar {
    position: sticky;
    top: 100px;
    height: fit-content;
}

.sidebar-section {
    background: var(--bg-card);
    border: 3px solid var(--border-color);
    border-radius: 0;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.sidebar-section h3 {
    font-size: 1rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.category-list,
.tool-list {
    list-style: none;
}

.category-list li,
.tool-list li {
    margin-bottom: 0.25rem;
}

.category-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    border-radius: 0;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.category-list a:hover,
.category-list a.active {
    background: rgba(139, 92, 246, 0.15);
    color: var(--accent-purple);
}

.category-count {
    background: var(--bg-secondary);
    padding: 0.15rem 0.5rem;
    border-radius: 10px;
    font-size: 0.75rem;
    font-weight: 600;
}

.category-list a.active .category-count {
    background: var(--accent-purple);
    color: white;
}

.tool-list a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 0.75rem;
    border-radius: 0;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.tool-list a:hover {
    background: rgba(139, 92, 246, 0.15);
    color: var(--accent-purple);
}

.tool-list a svg {
    opacity: 0.7;
}

.tool-list a:hover svg {
    opacity: 1;
}

/* ============================================
   ARTICLES GRID
   ============================================ */

.articles-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.article-card {
    background: var(--bg-card);
    border: 3px solid var(--border-color);
    border-radius: 0;
    overflow: hidden;
    transition: all 0.2s ease;
}

.article-card:hover {
    transform: translateY(-4px);
    border-color: var(--accent-purple);
    box-shadow: 0 12px 30px rgba(139, 92, 246, 0.12);
}

.article-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

.article-image {
    height: 140px;
    background: rgba(57, 255, 20, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
}

.article-placeholder svg {
    width: 50px;
    height: 50px;
    stroke: var(--accent-purple);
    opacity: 0.5;
}

.article-content {
    padding: 1.25rem;
}

.article-content h3 {
    font-size: 1.05rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    line-height: 1.4;
}

.article-content p {
    color: var(--text-secondary);
    font-size: 0.85rem;
    line-height: 1.5;
    margin-bottom: 0.75rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ============================================
   NO RESULTS
   ============================================ */

.no-results {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-secondary);
}

.no-results svg {
    opacity: 0.3;
    margin-bottom: 1rem;
}

.no-results h3 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

/* ============================================
   NEWSLETTER
   ============================================ */

.blog-newsletter {
    padding: 3rem 0 4rem;
}

.newsletter-card {
    background: var(--gradient-primary);
    border-radius: 0;
    padding: 3rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.newsletter-content h2 {
    color: white;
    font-size: 1.75rem;
    margin-bottom: 0.5rem;
}

.newsletter-content p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1rem;
}

.newsletter-form {
    display: flex;
    gap: 0.75rem;
    flex-shrink: 0;
}

.newsletter-form input {
    padding: 0.875rem 1.25rem;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 10px;
    font-size: 0.95rem;
    min-width: 280px;
    color: #1a1a2e;
}

.newsletter-form input:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.3);
}

.newsletter-form button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    background: rgba(0, 0, 0, 0.25);
    color: white;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.newsletter-form button:hover {
    background: rgba(0, 0, 0, 0.4);
    border-color: rgba(255, 255, 255, 0.5);
}

/* ============================================
   ARTICLE PAGE STYLES
   ============================================ */

.article-page {
    padding: 2rem 0 4rem;
}

.article-header {
    max-width: 800px;
    margin: 0 auto 2rem;
    text-align: center;
}

.article-header .article-category {
    margin-bottom: 1rem;
}

.article-header h1 {
    font-size: 2.5rem;
    line-height: 1.3;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.article-header .article-meta {
    justify-content: center;
}

.article-body {
    max-width: 800px;
    margin: 0 auto;
    background: var(--bg-card);
    border: 3px solid var(--border-color);
    border-radius: 0;
    padding: 3rem;
}

.article-body h2 {
    font-size: 1.5rem;
    margin: 2.5rem 0 1rem;
    color: var(--text-primary);
}

.article-body h3 {
    font-size: 1.25rem;
    margin: 2rem 0 0.75rem;
    color: var(--text-primary);
}

.article-body p {
    margin-bottom: 1.25rem;
    line-height: 1.8;
    color: var(--text-secondary);
}

.article-body ul,
.article-body ol {
    margin-bottom: 1.25rem;
    padding-left: 1.5rem;
    color: var(--text-secondary);
}

.article-body li {
    margin-bottom: 0.5rem;
    line-height: 1.7;
}

.article-body code {
    background: var(--code-bg);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.9em;
    color: var(--accent-purple);
}

.article-body pre {
    background: var(--code-bg);
    border: 3px solid var(--border-color);
    border-radius: 0;
    padding: 1.5rem;
    overflow-x: auto;
    margin-bottom: 1.5rem;
}

.article-body pre code {
    background: none;
    padding: 0;
    color: var(--text-primary);
}

.article-body blockquote {
    border-left: 4px solid var(--accent-purple);
    padding-left: 1.5rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: var(--text-secondary);
}

.article-body a {
    color: var(--accent-purple);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease;
}

.article-body a:hover {
    border-bottom-color: var(--accent-purple);
}

/* Info Box */
.info-box {
    background: rgba(139, 92, 246, 0.1);
    border: 3px solid rgba(139, 92, 246, 0.3);
    border-radius: 0;
    padding: 1.5rem;
    margin: 1.5rem 0;
}

.info-box.warning {
    background: rgba(245, 158, 11, 0.1);
    border-color: rgba(245, 158, 11, 0.3);
}

.info-box.danger {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
}

.info-box h4 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    color: var(--accent-purple);
}

.info-box.warning h4 {
    color: #f59e0b;
}

.info-box.danger h4 {
    color: #ef4444;
}

/* Table of Contents */
.toc {
    background: var(--bg-secondary);
    border: 3px solid var(--border-color);
    border-radius: 0;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.toc h4 {
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.toc ul {
    list-style: none;
    padding-left: 0;
    margin-bottom: 0;
}

.toc li {
    margin-bottom: 0.5rem;
}

.toc a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s ease;
}

.toc a:hover {
    color: var(--accent-purple);
}

/* Related Tools Box */
.related-tools {
    background: var(--bg-secondary);
    border: 3px solid var(--border-color);
    border-radius: 0;
    padding: 1.5rem;
    margin: 2rem 0;
}

.related-tools h4 {
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.related-tools-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.related-tools a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    background: var(--bg-card);
    border: 3px solid var(--border-color);
    border-radius: 10px;
    color: var(--text-primary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.related-tools a:hover {
    border-color: var(--accent-purple);
    transform: translateY(-2px);
}

.related-tools a svg {
    color: var(--accent-purple);
}

/* Article Navigation */
.article-nav {
    max-width: 800px;
    margin: 3rem auto 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.article-nav a {
    display: flex;
    flex-direction: column;
    padding: 1.5rem;
    background: var(--bg-card);
    border: 3px solid var(--border-color);
    border-radius: 0;
    text-decoration: none;
    transition: all 0.2s ease;
}

.article-nav a:hover {
    border-color: var(--accent-purple);
    transform: translateY(-2px);
}

.article-nav a span:first-child {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.article-nav a span:last-child {
    color: var(--text-primary);
    font-weight: 600;
}

.article-nav a.next {
    text-align: right;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 1024px) {
    .blog-layout {
        grid-template-columns: 1fr;
    }

    .blog-sidebar {
        position: static;
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .sidebar-section {
        margin-bottom: 0;
    }
}

@media (max-width: 768px) {
    .blog-hero-content h1 {
        font-size: 2rem;
    }

    .blog-hero-content p {
        font-size: 1rem;
    }

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

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

    .blog-sidebar {
        grid-template-columns: 1fr;
    }

    .newsletter-card {
        flex-direction: column;
        text-align: center;
        padding: 2rem;
    }

    .newsletter-form {
        flex-direction: column;
        width: 100%;
    }

    .newsletter-form input {
        min-width: auto;
        width: 100%;
    }

    .article-header h1 {
        font-size: 1.75rem;
    }

    .article-body {
        padding: 1.5rem;
    }

    .related-tools-grid {
        grid-template-columns: 1fr;
    }

    .article-nav {
        grid-template-columns: 1fr;
    }

    .article-nav a.next {
        text-align: left;
    }
}
