/* AI Tool Drift — Main Stylesheet */
:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    --accent: #06b6d4;
    --dark: #0f172a;
    --dark-soft: #1e293b;
    --text: #334155;
    --text-light: #64748b;
    --text-muted: #94a3b8;
    --border: #e2e8f0;
    --border-light: #f1f5f9;
    --bg: #ffffff;
    --bg-soft: #f8fafc;
    --bg-card: #ffffff;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --radius: 12px;
    --radius-sm: 8px;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
    --shadow: 0 4px 12px rgba(0,0,0,0.08);
    --shadow-lg: 0 12px 40px rgba(0,0,0,0.12);
    --transition: 0.2s ease;
    --max-width: 1200px;
    --content-width: 720px;
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body { font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif; font-size: 16px; line-height: 1.7; color: var(--text); background: var(--bg); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--primary-dark); }

/* Container */
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }
.container-narrow { max-width: var(--content-width); margin: 0 auto; padding: 0 24px; }

/* Header */
.site-header {
    position: sticky; top: 0; z-index: 100;
    background: rgba(255,255,255,0.92); backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
}
.header-inner {
    display: flex; align-items: center; justify-content: space-between;
    height: 64px;
}
.site-logo {
    display: flex; align-items: center; gap: 8px;
    font-size: 1.25rem; font-weight: 800; color: var(--dark);
    text-decoration: none;
}
.logo-icon { font-size: 1.4rem; }
.logo-text { background: linear-gradient(135deg, var(--primary), var(--accent)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.nav-links { display: flex; list-style: none; gap: 32px; }
.nav-links a { color: var(--text); font-weight: 500; font-size: 0.9rem; transition: color var(--transition); }
.nav-links a:hover { color: var(--primary); }
.mobile-toggle { display: none; background: none; border: none; cursor: pointer; padding: 4px; }
.mobile-toggle span { display: block; width: 24px; height: 2px; background: var(--dark); margin: 5px 0; transition: 0.3s; border-radius: 2px; }

/* Hero */
.hero {
    padding: 80px 0 60px;
    background: linear-gradient(135deg, #f8fafc 0%, #eef2ff 50%, #f0f9ff 100%);
    border-bottom: 1px solid var(--border-light);
}
.hero-content { max-width: 700px; }
.hero-tag {
    display: inline-block; padding: 6px 16px; border-radius: 50px;
    background: rgba(99,102,241,0.1); color: var(--primary);
    font-size: 0.85rem; font-weight: 600; margin-bottom: 20px;
}
.hero h1 { font-size: 3rem; font-weight: 800; color: var(--dark); line-height: 1.15; margin-bottom: 20px; letter-spacing: -0.02em; }
.gradient-text { background: linear-gradient(135deg, var(--primary), var(--accent)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero p { font-size: 1.15rem; color: var(--text-light); margin-bottom: 32px; line-height: 1.7; }
.hero-cta { display: flex; gap: 12px; margin-bottom: 40px; flex-wrap: wrap; }
.hero-stats { display: flex; gap: 40px; }
.hero-stats .stat strong { display: block; font-size: 1.5rem; color: var(--dark); }
.hero-stats .stat span { font-size: 0.8rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; }

/* Buttons */
.btn {
    display: inline-flex; align-items: center; gap: 8px; padding: 12px 24px;
    border-radius: var(--radius-sm); font-weight: 600; font-size: 0.9rem;
    transition: all var(--transition); cursor: pointer; border: 2px solid transparent;
    text-decoration: none;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); color: #fff; transform: translateY(-1px); box-shadow: var(--shadow); }
.btn-outline { border-color: var(--border); color: var(--text); background: var(--bg); }
.btn-outline:hover { border-color: var(--primary); color: var(--primary); }

/* Articles Section */
.articles-section { padding: 60px 0 80px; }
.section-header { margin-bottom: 40px; }
.section-header h2 { font-size: 1.75rem; font-weight: 700; color: var(--dark); margin-bottom: 8px; }
.section-header p { color: var(--text-light); font-size: 1rem; }

/* Article Cards */
.articles-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.article-card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); overflow: hidden;
    transition: all 0.3s ease; box-shadow: var(--shadow-sm);
}
.article-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--primary-light); }
.card-link { display: flex; flex-direction: column; height: 100%; text-decoration: none; color: inherit; }
.card-image { height: 200px; overflow: hidden; background: var(--bg-soft); }
.card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s ease; }
.article-card:hover .card-image img { transform: scale(1.05); }
.card-image-placeholder { display: flex; align-items: center; justify-content: center; font-size: 3rem; background: linear-gradient(135deg, #eef2ff, #f0f9ff); }
.card-body { padding: 20px; flex: 1; display: flex; flex-direction: column; }
.card-cat { display: inline-block; font-size: 0.75rem; font-weight: 600; color: var(--primary); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 8px; }
.card-title { font-size: 1.1rem; font-weight: 700; color: var(--dark); margin-bottom: 8px; line-height: 1.4; }
.card-excerpt { font-size: 0.88rem; color: var(--text-light); line-height: 1.6; flex: 1; margin-bottom: 12px; }
.card-meta { display: flex; justify-content: space-between; font-size: 0.78rem; color: var(--text-muted); }

/* Single Post */
.single-post { padding: 48px 0 80px; }
.post-header { margin-bottom: 32px; }
.post-cats { display: flex; gap: 8px; margin-bottom: 16px; }
.post-cat { display: inline-block; padding: 4px 12px; border-radius: 50px; background: rgba(99,102,241,0.1); color: var(--primary); font-size: 0.8rem; font-weight: 600; }
.post-header h1 { font-size: 2.25rem; font-weight: 800; color: var(--dark); line-height: 1.25; letter-spacing: -0.02em; }
.post-meta { display: flex; align-items: center; gap: 8px; margin-top: 16px; font-size: 0.88rem; color: var(--text-muted); }
.meta-sep { color: var(--border); }
.post-featured-image { margin-bottom: 32px; border-radius: var(--radius); overflow: hidden; }
.post-featured-image img { width: 100%; }

/* Post Content */
.post-content { font-size: 1.05rem; line-height: 1.8; color: var(--text); }
.post-content h2 { font-size: 1.5rem; font-weight: 700; color: var(--dark); margin: 40px 0 16px; }
.post-content h3 { font-size: 1.25rem; font-weight: 600; color: var(--dark); margin: 32px 0 12px; }
.post-content p { margin-bottom: 20px; }
.post-content ul, .post-content ol { margin: 0 0 20px 24px; }
.post-content li { margin-bottom: 8px; }
.post-content a { color: var(--primary); text-decoration: underline; text-underline-offset: 3px; }
.post-content a:hover { color: var(--primary-dark); }
.post-content blockquote {
    border-left: 4px solid var(--primary); padding: 16px 24px; margin: 24px 0;
    background: var(--bg-soft); border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    font-style: italic; color: var(--text-light);
}
.post-content img { border-radius: var(--radius-sm); margin: 24px 0; }
.post-content table { width: 100%; border-collapse: collapse; margin: 24px 0; font-size: 0.9rem; }
.post-content th, .post-content td { padding: 12px 16px; border: 1px solid var(--border); text-align: left; }
.post-content th { background: var(--bg-soft); font-weight: 600; color: var(--dark); }
.post-content tr:hover { background: var(--bg-soft); }

/* Affiliate Disclosure */
.affiliate-disclosure {
    padding: 16px 20px; margin-bottom: 32px;
    background: #fffbeb; border: 1px solid #fcd34d; border-radius: var(--radius-sm);
    font-size: 0.85rem; color: #92400e; line-height: 1.6;
}
.affiliate-disclosure strong { color: #78350f; }

/* Post Tags */
.post-footer { margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--border); }
.post-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.post-tag { padding: 4px 14px; border-radius: 50px; background: var(--bg-soft); border: 1px solid var(--border); color: var(--text-light); font-size: 0.8rem; font-weight: 500; transition: all var(--transition); }
.post-tag:hover { border-color: var(--primary); color: var(--primary); }

/* Related Posts */
.related-posts { padding: 60px 0; background: var(--bg-soft); border-top: 1px solid var(--border-light); }
.related-posts h2 { font-size: 1.5rem; font-weight: 700; color: var(--dark); margin-bottom: 24px; }

/* Archive */
.archive-header { padding: 48px 0 24px; background: var(--bg-soft); border-bottom: 1px solid var(--border-light); }
.archive-header h1 { font-size: 2rem; font-weight: 700; color: var(--dark); }
.archive-header p { color: var(--text-light); margin-top: 8px; }

/* Pagination */
.pagination { margin-top: 48px; text-align: center; }
.pagination .nav-links { display: flex; justify-content: center; gap: 8px; }
.pagination a, .pagination span { display: inline-block; padding: 8px 16px; border-radius: var(--radius-sm); border: 1px solid var(--border); color: var(--text); font-weight: 500; font-size: 0.9rem; }
.pagination a:hover { border-color: var(--primary); color: var(--primary); }
.pagination .current { background: var(--primary); color: #fff; border-color: var(--primary); }

/* Footer */
.site-footer { background: var(--dark); color: #cbd5e1; padding: 64px 0 32px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer-logo { display: flex; align-items: center; gap: 8px; font-size: 1.2rem; font-weight: 800; color: #fff; text-decoration: none; margin-bottom: 12px; }
.footer-logo .logo-text { background: linear-gradient(135deg, var(--primary-light), var(--accent)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.footer-brand p { font-size: 0.9rem; line-height: 1.6; color: #94a3b8; }
.footer-links h4 { color: #fff; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 16px; }
.footer-links ul { list-style: none; }
.footer-links li { margin-bottom: 8px; }
.footer-links a { color: #94a3b8; font-size: 0.9rem; transition: color var(--transition); }
.footer-links a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid #1e293b; padding-top: 24px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
.footer-bottom p { font-size: 0.8rem; color: #64748b; }
.footer-disclaimer { font-size: 0.75rem !important; }

/* No Posts */
.no-posts { text-align: center; padding: 80px 0; }
.no-posts h2 { font-size: 1.75rem; color: var(--dark); margin-bottom: 8px; }
.no-posts p { color: var(--text-light); }

/* Responsive */
@media (max-width: 1024px) {
    .articles-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
    .hero h1 { font-size: 2rem; }
    .hero { padding: 48px 0 40px; }
    .articles-grid { grid-template-columns: 1fr; }
    .nav-links { display: none; }
    .mobile-toggle { display: block; }
    .hero-stats { gap: 24px; }
    .hero-cta { flex-direction: column; }
    .hero-cta .btn { text-align: center; justify-content: center; }
    .post-header h1 { font-size: 1.75rem; }
    .footer-grid { grid-template-columns: 1fr; gap: 32px; }
    .footer-bottom { flex-direction: column; text-align: center; }
}
@media (max-width: 480px) {
    .hero h1 { font-size: 1.6rem; }
    .hero-stats { flex-direction: column; gap: 12px; }
}
