/* ============================================================
   TikSave - Main Stylesheet
   ============================================================ */

/* --- CSS Variables (Dark Mode Default) --- */
:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    --secondary: #06b6d4;
    --dark: #0f172a;
    --dark-card: #1e293b;
    --text: #e2e8f0;
    --text-muted: #94a3b8;
    --border: #334155;
    --success: #10b981;
    --error: #ef4444;
    --warning: #f59e0b;
    --gradient: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #06b6d4 100%);
    --radius: 12px;
    --radius-lg: 20px;
    --font-display: 'Sora', sans-serif;
    --font-body: 'DM Sans', sans-serif;
    --shadow: 0 4px 24px rgba(0,0,0,0.3);
    --header-height: 68px;
}

/* Light Mode */
[data-theme="light"] {
    --dark: #f1f5f9;
    --dark-card: #ffffff;
    --text: #0f172a;
    --text-muted: #64748b;
    --border: #cbd5e1;
    --shadow: 0 4px 24px rgba(0,0,0,0.08);
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font-body);
    background: var(--dark);
    color: var(--text);
    font-size: 16px;
    line-height: 1.6;
    transition: background 0.3s, color 0.3s;
}
a { color: var(--primary-light); text-decoration: none; }
a:hover { color: var(--primary); }
img { max-width: 100%; display: block; }
input, textarea, select, button { font-family: var(--font-body); }

/* --- Layout --- */
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.section { padding: 80px 0; }
.header-spacer { height: var(--header-height); }

/* --- Header --- */
.site-header {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    height: var(--header-height);
    background: rgba(15,23,42,0.85);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(51,65,85,0);
    transition: border-color 0.3s, box-shadow 0.3s;
}
[data-theme="light"] .site-header { background: rgba(241,245,249,0.9); }
.site-header.scrolled { border-bottom-color: var(--border); box-shadow: 0 4px 20px rgba(0,0,0,0.15); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-height); gap: 24px; }

/* Logo */
.logo { display: flex; align-items: center; gap: 8px; text-decoration: none; }
.logo-icon { font-size: 26px; }
.logo-text { font-family: var(--font-display); font-size: 22px; font-weight: 700; background: var(--gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }

/* Desktop nav */
.desktop-nav { display: flex; gap: 4px; }
.nav-link { padding: 8px 14px; border-radius: 8px; font-size: 14px; font-weight: 500; color: var(--text-muted); transition: all 0.2s; text-decoration: none; }
.nav-link:hover, .nav-link.active { background: rgba(99,102,241,0.12); color: var(--primary-light); }

/* Header actions */
.header-actions { display: flex; align-items: center; gap: 10px; }
.btn-sm { padding: 8px 16px; font-size: 13px; }

/* Theme toggle */
.theme-toggle {
    display: flex; align-items: center; justify-content: center;
    width: 38px; height: 38px; border-radius: 10px;
    background: rgba(255,255,255,0.06); border: 1px solid var(--border);
    cursor: pointer; color: var(--text-muted); transition: all 0.2s; gap: 6px;
}
.theme-toggle:hover { background: rgba(99,102,241,0.15); color: var(--primary-light); }
.icon-sun { display: none; }
.icon-moon { display: block; }
[data-theme="light"] .icon-sun { display: block; }
[data-theme="light"] .icon-moon { display: none; }

/* Hamburger */
.hamburger {
    display: none; flex-direction: column; gap: 5px; cursor: pointer;
    background: none; border: none; padding: 8px;
}
.hamburger span { display: block; width: 22px; height: 2px; background: var(--text-muted); border-radius: 2px; transition: all 0.3s; }

/* Mobile menu */
.mobile-menu {
    display: none; padding: 16px 20px 24px;
    background: var(--dark-card); border-top: 1px solid var(--border);
}
.mobile-menu.open { display: block; }
.mobile-nav { display: flex; flex-direction: column; gap: 4px; margin-bottom: 16px; }
.mobile-nav .nav-link { padding: 12px 14px; font-size: 15px; border-radius: var(--radius); }
.mobile-actions { display: flex; gap: 10px; }
.mobile-actions .theme-toggle { width: auto; padding: 10px 16px; gap: 8px; font-size: 14px; }

/* --- Buttons --- */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 12px 24px; border-radius: var(--radius);
    font-family: var(--font-display); font-weight: 600; font-size: 15px;
    cursor: pointer; border: none; text-decoration: none;
    transition: all 0.2s; line-height: 1;
}
.btn-primary {
    background: var(--gradient); color: white;
    box-shadow: 0 0 20px rgba(99,102,241,0.35);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 0 30px rgba(99,102,241,0.55); color: white; }
.btn-secondary {
    background: rgba(99,102,241,0.12); color: var(--primary-light);
    border: 1px solid rgba(99,102,241,0.3);
}
.btn-secondary:hover { background: rgba(99,102,241,0.2); color: var(--primary-light); }
.btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none !important; }

/* Spinner */
.spinner {
    width: 20px; height: 20px;
    border: 3px solid rgba(255,255,255,0.25);
    border-top-color: white; border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Gradient text */
.gradient-text { background: var(--gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }

/* --- Cards --- */
.card {
    background: var(--dark-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); padding: 24px;
}

/* Alerts */
.alert { padding: 14px 18px; border-radius: var(--radius); font-size: 14px; margin-bottom: 16px; }
.alert-success { background: rgba(16,185,129,0.1); border: 1px solid rgba(16,185,129,0.3); color: #6ee7b7; }
.alert-error   { background: rgba(239,68,68,0.1);  border: 1px solid rgba(239,68,68,0.3);  color: #fca5a5; }
.alert-warning { background: rgba(245,158,11,0.1); border: 1px solid rgba(245,158,11,0.3); color: #fde68a; }

/* --- Hero Section --- */
.hero {
    position: relative; overflow: hidden;
    padding: 80px 0 60px; text-align: center;
    background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(99,102,241,0.15) 0%, transparent 70%);
}
.hero-glow {
    position: absolute; top: -100px; left: 50%; transform: translateX(-50%);
    width: 600px; height: 600px; border-radius: 50%;
    background: radial-gradient(circle, rgba(99,102,241,0.12) 0%, transparent 70%);
    pointer-events: none;
}
.hero-content { position: relative; z-index: 1; }
.hero-badge {
    display: inline-block; padding: 6px 16px; border-radius: 100px;
    background: rgba(99,102,241,0.15); border: 1px solid rgba(99,102,241,0.3);
    font-size: 14px; font-weight: 600; color: var(--primary-light); margin-bottom: 24px;
}
.hero-title {
    font-family: var(--font-display); font-size: clamp(32px, 6vw, 60px);
    font-weight: 800; line-height: 1.15; margin-bottom: 20px; letter-spacing: -1px;
}
.hero-subtitle {
    font-size: clamp(16px, 2vw, 20px); color: var(--text-muted);
    max-width: 600px; margin: 0 auto 36px;
}

/* Downloader card */
.downloader-card {
    background: var(--dark-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); padding: 28px; max-width: 780px;
    margin: 0 auto 28px; box-shadow: var(--shadow);
}
.downloader-input-wrap {
    display: flex; gap: 10px; align-items: center;
    background: rgba(255,255,255,0.04); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 6px 6px 6px 16px;
}
.input-icon { font-size: 20px; flex-shrink: 0; }
.downloader-input {
    flex: 1; background: none; border: none; outline: none;
    color: var(--text); font-size: 15px; min-width: 0;
    padding: 8px 0;
}
.downloader-input::placeholder { color: var(--text-muted); }
.downloader-hint {
    display: flex; gap: 20px; justify-content: center; flex-wrap: wrap;
    margin-top: 14px; font-size: 13px; color: var(--text-muted);
}

/* Result card */
.result-card {
    margin-top: 20px; padding: 20px; border-radius: var(--radius);
    border: 1px solid rgba(16,185,129,0.3); background: rgba(16,185,129,0.05);
}
.result-video-info {
    display: flex; gap: 16px; align-items: flex-start; margin-bottom: 16px;
}
.result-thumbnail {
    width: 120px; height: 80px; object-fit: cover;
    border-radius: 8px; flex-shrink: 0; background: var(--border);
}
.result-title { font-weight: 600; font-size: 15px; margin-bottom: 4px; }
.result-author { color: var(--text-muted); font-size: 13px; }
.download-links { display: flex; flex-wrap: wrap; gap: 10px; }
.download-link {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 10px 18px; border-radius: var(--radius);
    background: var(--gradient); color: white;
    font-weight: 600; font-size: 14px; text-decoration: none;
    transition: all 0.2s;
}
.download-link:hover { transform: translateY(-2px); box-shadow: 0 0 20px rgba(99,102,241,0.4); color: white; }
.download-link.audio-link {
    background: rgba(6,182,212,0.15); color: var(--secondary);
    border: 1px solid rgba(6,182,212,0.3);
}

/* Trust badges */
.trust-badges {
    display: flex; flex-wrap: wrap; gap: 10px; justify-content: center;
}
.trust-badge {
    padding: 6px 14px; border-radius: 100px;
    background: rgba(255,255,255,0.05); border: 1px solid var(--border);
    font-size: 13px; color: var(--text-muted);
}

/* --- Section Headers --- */
.section-header { text-align: center; margin-bottom: 56px; }
.section-badge {
    display: inline-block; padding: 6px 14px; border-radius: 100px;
    background: rgba(99,102,241,0.12); border: 1px solid rgba(99,102,241,0.25);
    font-size: 13px; font-weight: 600; color: var(--primary-light); margin-bottom: 16px;
}
.section-title {
    font-family: var(--font-display); font-size: clamp(26px, 4vw, 42px);
    font-weight: 700; margin-bottom: 12px; line-height: 1.2;
}
.section-subtitle { color: var(--text-muted); font-size: 17px; max-width: 560px; margin: 0 auto; }

/* --- Features Grid --- */
.features-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px;
}
.feature-card { text-align: center; transition: all 0.3s; cursor: default; }
.feature-card:hover { transform: translateY(-4px); border-color: var(--primary); }
.feature-icon { font-size: 40px; margin-bottom: 14px; }
.feature-card h3 { font-family: var(--font-display); font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.feature-card p { color: var(--text-muted); font-size: 14px; line-height: 1.6; }

/* --- How It Works --- */
.hiw-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 28px; }
.hiw-card { text-align: center; }
.hiw-number {
    width: 56px; height: 56px; border-radius: 50%;
    background: var(--gradient); display: flex; align-items: center; justify-content: center;
    font-family: var(--font-display); font-size: 22px; font-weight: 800; color: white;
    margin: 0 auto 18px; box-shadow: 0 0 20px rgba(99,102,241,0.35);
}
.hiw-card h3 { font-family: var(--font-display); font-size: 19px; font-weight: 700; margin-bottom: 8px; }
.hiw-card p { color: var(--text-muted); font-size: 14px; }

/* --- Use Cases --- */
.usecases-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.usecase-card {
    background: var(--dark-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 20px; text-align: center; transition: all 0.2s;
}
.usecase-card:hover { border-color: var(--primary); transform: translateY(-3px); }
.usecase-icon { font-size: 32px; margin-bottom: 10px; display: block; }
.usecase-card h4 { font-weight: 700; font-size: 15px; margin-bottom: 6px; }
.usecase-card p { color: var(--text-muted); font-size: 13px; }

/* --- Testimonials --- */
.testimonials-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.testimonial-card { display: flex; flex-direction: column; }
.stars { color: #f59e0b; font-size: 18px; margin-bottom: 12px; letter-spacing: 2px; }
.testimonial-text { color: var(--text-muted); font-size: 15px; line-height: 1.7; flex: 1; margin-bottom: 16px; font-style: italic; }
.testimonial-author { display: flex; align-items: center; gap: 12px; }
.author-avatar {
    width: 42px; height: 42px; border-radius: 50%; flex-shrink: 0;
    background: var(--gradient); display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 16px; color: white;
}
.author-name { font-weight: 700; font-size: 14px; }
.author-role { color: var(--text-muted); font-size: 12px; }

/* --- Blog --- */
.blog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; }
.blog-grid-full { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.blog-card { overflow: hidden; padding: 0; transition: all 0.3s; }
.blog-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.blog-card-img { width: 100%; height: 200px; object-fit: cover; transition: transform 0.4s; }
.blog-card:hover .blog-card-img { transform: scale(1.04); }
.blog-card-body { padding: 20px; }
.blog-cat-badge {
    display: inline-block; padding: 3px 10px; border-radius: 100px; font-size: 12px; font-weight: 600;
    background: rgba(99,102,241,0.15); color: var(--primary-light); margin-bottom: 10px; text-decoration: none;
}
.blog-cat-badge-lg { font-size: 14px; padding: 5px 14px; margin-bottom: 14px; }
.blog-card h2, .blog-card h3 { font-family: var(--font-display); font-size: 17px; font-weight: 700; margin-bottom: 8px; line-height: 1.4; }
.blog-card h2 a, .blog-card h3 a { color: var(--text); text-decoration: none; }
.blog-card h2 a:hover, .blog-card h3 a:hover { color: var(--primary-light); }
.blog-card p { color: var(--text-muted); font-size: 14px; margin-bottom: 14px; }
.blog-meta { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; font-size: 13px; color: var(--text-muted); }
.read-more { color: var(--primary-light); font-weight: 600; margin-left: auto; }

/* Blog listing category tabs */
.category-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 36px; }
.cat-tab {
    padding: 8px 18px; border-radius: 100px; font-size: 14px; font-weight: 600;
    background: rgba(255,255,255,0.05); border: 1px solid var(--border);
    color: var(--text-muted); text-decoration: none; transition: all 0.2s;
}
.cat-tab:hover, .cat-tab.active {
    background: rgba(99,102,241,0.15); border-color: rgba(99,102,241,0.4);
    color: var(--primary-light);
}
.cat-count { background: rgba(99,102,241,0.2); padding: 2px 7px; border-radius: 100px; font-size: 11px; margin-left: 4px; }

/* Blog post page */
.blog-post-container { padding-top: 32px; padding-bottom: 60px; }
.breadcrumb { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-bottom: 28px; font-size: 13px; color: var(--text-muted); }
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--primary-light); }
.breadcrumb span { color: var(--border); }
.blog-post-layout { display: grid; grid-template-columns: 1fr 320px; gap: 40px; }
.post-title { font-family: var(--font-display); font-size: clamp(24px, 4vw, 40px); font-weight: 800; line-height: 1.2; margin-bottom: 16px; }
.post-meta { display: flex; gap: 14px; flex-wrap: wrap; font-size: 13px; color: var(--text-muted); margin-bottom: 24px; }
.post-feature-image { width: 100%; border-radius: var(--radius-lg); margin-bottom: 32px; max-height: 420px; object-fit: cover; }
.post-content { font-size: 16px; line-height: 1.8; }
.post-content h2 { font-family: var(--font-display); font-size: 26px; font-weight: 700; margin: 32px 0 14px; }
.post-content h3 { font-family: var(--font-display); font-size: 21px; font-weight: 700; margin: 24px 0 12px; }
.post-content h4 { font-family: var(--font-display); font-size: 18px; font-weight: 700; margin: 20px 0 10px; }
.post-content p { margin-bottom: 16px; }
.post-content ul, .post-content ol { margin: 16px 0 16px 24px; }
.post-content li { margin-bottom: 6px; }
.post-content blockquote { border-left: 4px solid var(--primary); padding: 12px 20px; margin: 20px 0; background: rgba(99,102,241,0.07); border-radius: 0 var(--radius) var(--radius) 0; color: var(--text-muted); font-style: italic; }
.post-content a { color: var(--primary-light); }
.post-content img { border-radius: var(--radius); margin: 16px 0; }
.post-content hr { border: none; border-top: 1px solid var(--border); margin: 28px 0; }
.post-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.tag { padding: 5px 12px; border-radius: 100px; font-size: 13px; background: rgba(99,102,241,0.1); border: 1px solid rgba(99,102,241,0.2); color: var(--primary-light); }

/* Sidebar */
.blog-sidebar { display: flex; flex-direction: column; gap: 20px; }
.sidebar-widget { padding: 20px; }
.widget-title { font-family: var(--font-display); font-size: 15px; font-weight: 700; margin-bottom: 14px; }
.sidebar-post { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid rgba(51,65,85,0.4); text-decoration: none; color: var(--text); }
.sidebar-post:last-child { border: none; }
.sidebar-post-img { width: 52px; height: 40px; border-radius: 6px; object-fit: cover; flex-shrink: 0; }
.sidebar-post-placeholder { width: 52px; height: 40px; background: rgba(99,102,241,0.1); border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; }
.sidebar-post-title { font-size: 13px; font-weight: 600; line-height: 1.4; }
.sidebar-post-date { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.sidebar-cta { text-align: center; }
.sidebar-cta h4 { font-family: var(--font-display); font-size: 16px; font-weight: 700; margin-bottom: 6px; }
.sidebar-cta p { color: var(--text-muted); font-size: 13px; }
.related-posts h2 { font-family: var(--font-display); font-size: 24px; font-weight: 700; margin-bottom: 24px; }

/* --- FAQ --- */
.faq-list { max-width: 780px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.faq-item { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: border-color 0.2s; }
.faq-item:hover { border-color: rgba(99,102,241,0.4); }
.faq-question {
    padding: 18px 20px; cursor: pointer; display: flex;
    justify-content: space-between; align-items: center;
    font-weight: 600; font-size: 15px; list-style: none;
}
.faq-question::-webkit-details-marker { display: none; }
.faq-icon { font-size: 22px; color: var(--primary-light); transition: transform 0.25s; flex-shrink: 0; }
details[open] .faq-icon { transform: rotate(45deg); }
.faq-answer { padding: 0 20px 18px; color: var(--text-muted); font-size: 15px; line-height: 1.7; }

/* --- Footer --- */
.site-footer { background: var(--dark-card); border-top: 1px solid var(--border); padding: 60px 0 32px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer-brand .logo { margin-bottom: 12px; }
.footer-desc { color: var(--text-muted); font-size: 14px; line-height: 1.7; margin-bottom: 16px; }
.social-links { display: flex; gap: 10px; }
.social-btn {
    width: 36px; height: 36px; border-radius: 8px;
    background: rgba(255,255,255,0.06); border: 1px solid var(--border);
    display: flex; align-items: center; justify-content: center; font-size: 16px;
    text-decoration: none; transition: all 0.2s;
}
.social-btn:hover { background: rgba(99,102,241,0.15); border-color: rgba(99,102,241,0.4); }
.footer-links h4 { font-family: var(--font-display); font-size: 14px; font-weight: 700; margin-bottom: 16px; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-muted); }
.footer-links a { display: block; color: var(--text-muted); font-size: 14px; margin-bottom: 10px; text-decoration: none; transition: color 0.2s; }
.footer-links a:hover { color: var(--primary-light); }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 24px; text-align: center; }
.footer-bottom p { color: var(--text-muted); font-size: 13px; margin-bottom: 4px; }
.footer-disclaimer { font-size: 12px !important; }

/* --- Static Pages --- */
.page-hero {
    padding: 60px 0 40px; text-align: center;
    background: radial-gradient(ellipse 70% 60% at 50% 0%, rgba(99,102,241,0.1) 0%, transparent 70%);
}
.page-hero h1 { font-family: var(--font-display); font-size: clamp(28px, 5vw, 48px); font-weight: 800; margin-bottom: 10px; }
.page-hero p { color: var(--text-muted); font-size: 18px; }
.static-page-content { max-width: 780px; margin: 0 auto; }

/* --- Ads --- */
.adsense-ad {
    background: rgba(255,255,255,0.03); border: 1px dashed rgba(255,255,255,0.1);
    border-radius: var(--radius); display: flex; align-items: center;
    justify-content: center; color: var(--text-muted); font-size: 12px;
}
.adsense-728x90 { width: 100%; max-width: 728px; height: 90px; margin: 0 auto; }
.adsense-300x250 { width: 300px; height: 250px; }
.ad-wrap { display: flex; justify-content: center; padding: 16px 0; }

/* --- Pagination --- */
.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 40px; flex-wrap: wrap; }
.page-btn {
    padding: 8px 14px; border-radius: var(--radius); font-size: 14px; font-weight: 600;
    background: var(--dark-card); border: 1px solid var(--border);
    color: var(--text-muted); text-decoration: none; transition: all 0.2s;
}
.page-btn:hover, .page-btn.active {
    background: rgba(99,102,241,0.15); border-color: rgba(99,102,241,0.4);
    color: var(--primary-light);
}

/* Empty state */
.empty-state { text-align: center; padding: 80px 20px; }
.empty-state h3 { font-size: 20px; font-weight: 700; margin-bottom: 8px; }
.empty-state p { color: var(--text-muted); }

/* Card header row */
.card-header-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.card-header-row h3, .card-header-row h4 { font-family: var(--font-display); font-weight: 700; }

/* --- WYSIWYG --- */
.wysiwyg-wrap { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.wysiwyg-toolbar {
    display: flex; flex-wrap: wrap; gap: 4px; padding: 10px 12px;
    background: rgba(255,255,255,0.03); border-bottom: 1px solid var(--border);
}
.toolbar-group { display: flex; gap: 2px; padding-right: 8px; margin-right: 4px; border-right: 1px solid var(--border); }
.toolbar-group:last-child { border: none; padding: 0; }
.tb-btn {
    padding: 5px 9px; border-radius: 6px; font-size: 13px; font-weight: 600;
    background: none; border: 1px solid transparent; color: var(--text-muted);
    cursor: pointer; transition: all 0.15s; white-space: nowrap;
}
.tb-btn:hover { background: rgba(99,102,241,0.15); color: var(--primary-light); border-color: rgba(99,102,241,0.3); }
.tb-html-toggle.active { background: rgba(99,102,241,0.2); color: var(--primary-light); border-color: rgba(99,102,241,0.4); }
.wysiwyg-editor {
    min-height: 280px; padding: 16px; outline: none;
    color: var(--text); font-size: 15px; line-height: 1.7;
}
.wysiwyg-editor:empty::before { content: 'Start writing...'; color: var(--text-muted); pointer-events: none; }
.wysiwyg-source {
    width: 100%; min-height: 280px; padding: 16px; border: none; outline: none;
    background: #0a0f1e; color: #6ee7b7; font-family: 'Courier New', monospace;
    font-size: 13px; line-height: 1.7; resize: vertical;
}

/* Feature image upload zone */
.feature-image-upload {
    border: 2px dashed var(--border); border-radius: var(--radius);
    padding: 16px; transition: border-color 0.2s;
}
#image-placeholder {
    text-align: center; padding: 24px; cursor: pointer; color: var(--text-muted);
}
#image-placeholder p { margin-top: 8px; font-size: 14px; }

/* Post editor layout */
.post-editor-layout { display: grid; grid-template-columns: 1fr 300px; gap: 24px; }
.post-title-input {
    width: 100%; padding: 14px 0; background: none; border: none; border-bottom: 2px solid var(--border);
    outline: none; font-family: var(--font-display); font-size: 22px; font-weight: 700;
    color: var(--text); transition: border-color 0.2s;
}
.post-title-input:focus { border-bottom-color: var(--primary); }
.post-title-input::placeholder { color: var(--text-muted); font-weight: 400; }
.form-label { display: block; font-size: 13px; font-weight: 600; color: var(--text-muted); margin-bottom: 6px; text-transform: uppercase; letter-spacing: 0.5px; }

/* --- Responsive --- */
@media (max-width: 1024px) {
    .blog-post-layout { grid-template-columns: 1fr; }
    .blog-sidebar { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .post-editor-layout { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
    .desktop-nav { display: none; }
    .hamburger { display: flex; }
    .hero { padding: 48px 0 40px; }
    .section { padding: 60px 0; }
    .features-grid { grid-template-columns: 1fr 1fr; }
    .hiw-grid { grid-template-columns: 1fr; }
    .testimonials-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .blog-sidebar { grid-template-columns: 1fr; }
    .downloader-input-wrap { flex-direction: column; align-items: stretch; padding: 12px; gap: 8px; }
    .input-icon { display: none; }
    .downloader-input { padding: 8px 4px; }
    .download-links { flex-direction: column; }
}
@media (max-width: 480px) {
    .features-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .usecases-grid { grid-template-columns: 1fr 1fr; }
    .header-actions .btn-primary { display: none; }
}
