/*
Theme Name: Syntax Blog
Theme URI: https://syntax-blog.com
Description: A modern, editorial-style tech blog theme with dark aesthetics and bold typography. Features animated backgrounds, smooth transitions, and a magazine-inspired layout perfect for technology content.
Version: 1.0.0
Author: Your Name
Author URI: https://yoursite.com
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: syntax-blog
Tags: blog, dark, modern, tech, magazine, editorial, two-columns, custom-colors, custom-menu, featured-images, threaded-comments
*/

:root {
    --bg-dark: #0a0a0a;
    --bg-card: #111111;
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --accent: #00ff88;
    --accent-dim: #00cc6a;
    --border: #222222;
    --overlay: rgba(0, 255, 136, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Work Sans', sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Animated background gradient */
body::before {
    content: '';
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: 
        radial-gradient(circle at 20% 30%, rgba(0, 255, 136, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(0, 255, 136, 0.02) 0%, transparent 50%);
    animation: drift 20s ease-in-out infinite;
    pointer-events: none;
    z-index: 0;
}

@keyframes drift {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    50% { transform: translate(5%, 5%) rotate(2deg); }
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    position: relative;
    z-index: 1;
}

/* Header */
header {
    padding: 3rem 0 2rem;
    border-bottom: 1px solid var(--border);
    margin-bottom: 4rem;
    animation: fadeInDown 0.8s ease-out;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.logo {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    font-weight: 900;
    letter-spacing: -0.03em;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.logo a {
    text-decoration: none;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tagline {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.9rem;
    color: var(--text-secondary);
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

nav {
    margin-top: 2rem;
    display: flex;
    gap: 2.5rem;
}

nav a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    position: relative;
    transition: color 0.3s ease;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 0.3s ease;
}

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

nav a:hover::after {
    width: 100%;
}

nav a.current-menu-item,
nav a.current_page_item {
    color: var(--text-primary);
}

/* Featured Post */
.featured {
    margin-bottom: 5rem;
    position: relative;
    animation: fadeIn 1s ease-out 0.2s backwards;
}

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

.featured-label {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.75rem;
    color: var(--accent);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
    display: inline-block;
}

.featured-content {
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 4rem;
    position: relative;
    overflow: hidden;
    transition: border-color 0.3s ease;
}

.featured-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--accent) 0%, var(--accent-dim) 100%);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s ease;
}

.featured-content:hover::before {
    transform: scaleX(1);
}

.featured-content:hover {
    border-color: var(--accent);
}

.featured h2 {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

.featured h2 a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.featured h2 a:hover {
    color: var(--accent);
}

.featured-meta {
    display: flex;
    gap: 2rem;
    margin-bottom: 2rem;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.featured-excerpt {
    font-size: 1.2rem;
    line-height: 1.8;
    color: var(--text-secondary);
    max-width: 800px;
    margin-bottom: 2rem;
}

.read-more {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--accent);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    transition: gap 0.3s ease;
}

.read-more:hover {
    gap: 1rem;
}

.read-more::after {
    content: '→';
    font-size: 1.2rem;
}

/* Grid Layout */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 2rem;
    margin-bottom: 5rem;
}

.post-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 2.5rem;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    animation: fadeIn 1s ease-out backwards;
}

.post-card:nth-child(1) { animation-delay: 0.3s; }
.post-card:nth-child(2) { animation-delay: 0.4s; }
.post-card:nth-child(3) { animation-delay: 0.5s; }
.post-card:nth-child(4) { animation-delay: 0.6s; }
.post-card:nth-child(5) { animation-delay: 0.7s; }
.post-card:nth-child(6) { animation-delay: 0.8s; }

.post-card::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 0;
    height: 100%;
    background: var(--overlay);
    transition: width 0.4s ease;
}

.post-card:hover::after {
    width: 100%;
    left: 0;
}

.post-card:hover {
    border-color: var(--accent);
    transform: translateY(-5px);
}

.post-category {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.75rem;
    color: var(--accent);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 1rem;
    display: inline-block;
    position: relative;
    z-index: 2;
}

.post-category a {
    color: var(--accent);
    text-decoration: none;
}

.post-card h3 {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
    position: relative;
    z-index: 2;
}

.post-card h3 a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.post-card h3 a:hover {
    color: var(--accent);
}

.post-meta {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    position: relative;
    z-index: 2;
}

.post-excerpt {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 2;
}

/* Single Post */
.single-post {
    max-width: 800px;
    margin: 0 auto;
}

.single-post .post-header {
    margin-bottom: 3rem;
}

.single-post .post-title {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

.single-post .post-meta {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.single-post .post-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-secondary);
}

.single-post .post-content p {
    margin-bottom: 1.5rem;
}

.single-post .post-content h2 {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    color: var(--text-primary);
    margin: 3rem 0 1.5rem;
}

.single-post .post-content h3 {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    color: var(--text-primary);
    margin: 2.5rem 0 1.5rem;
}

.single-post .post-content a {
    color: var(--accent);
    text-decoration: none;
    border-bottom: 1px solid var(--accent);
    transition: border-color 0.3s ease;
}

.single-post .post-content a:hover {
    border-bottom-color: transparent;
}

/* Newsletter Section */
.newsletter {
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 4rem;
    text-align: center;
    margin-bottom: 5rem;
    position: relative;
    overflow: hidden;
    animation: fadeIn 1s ease-out 0.9s backwards;
}

.newsletter::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
    opacity: 0.03;
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.newsletter h2 {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    position: relative;
}

.newsletter p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 2rem;
    position: relative;
}

.newsletter-form {
    display: flex;
    gap: 1rem;
    max-width: 500px;
    margin: 0 auto;
    position: relative;
}

.newsletter-form input {
    flex: 1;
    padding: 1rem 1.5rem;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    color: var(--text-primary);
    font-family: 'Work Sans', sans-serif;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.newsletter-form input:focus {
    outline: none;
    border-color: var(--accent);
}

.newsletter-form button {
    padding: 1rem 2rem;
    background: var(--accent);
    color: var(--bg-dark);
    border: none;
    font-family: 'Work Sans', sans-serif;
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
}

.newsletter-form button:hover {
    background: var(--accent-dim);
    transform: translateY(-2px);
}

/* Footer */
footer {
    border-top: 1px solid var(--border);
    padding: 3rem 0;
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

footer a {
    color: var(--accent);
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--text-primary);
}

/* Comments */
.comments-area {
    margin-top: 5rem;
    padding-top: 3rem;
    border-top: 1px solid var(--border);
}

.comments-title {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    margin-bottom: 2rem;
}

.comment-list {
    list-style: none;
}

.comment {
    margin-bottom: 2rem;
    padding: 2rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
}

.comment-author {
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 0.5rem;
}

.comment-meta {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 0 1.5rem;
    }

    .logo {
        font-size: 2.5rem;
    }

    nav {
        flex-wrap: wrap;
        gap: 1.5rem;
    }

    .featured-content {
        padding: 2rem;
    }

    .featured h2 {
        font-size: 2.5rem;
    }

    .posts-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .post-card h3 {
        font-size: 1.75rem;
    }

    .newsletter {
        padding: 2.5rem 2rem;
    }

    .newsletter h2 {
        font-size: 2rem;
    }

    .newsletter-form {
        flex-direction: column;
    }

    .single-post .post-title {
        font-size: 2.5rem;
    }
}
