/* ============================================
   GPbaike (GPTeslaWiki) - Tesla Finance & Tech
   Dark Theme | Modern Tech Style
   ============================================ */

:root {
    --bg-primary: #0a1628;
    --bg-secondary: #0f1d32;
    --bg-card: #132238;
    --bg-card-hover: #1a3050;
    --bg-header: rgba(10, 22, 40, 0.95);
    --text-primary: #e8edf2;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --accent: #0ea5e9;
    --accent-light: #38bdf8;
    --accent-dark: #0284c7;
    --accent-red: #e82127;
    --accent-cyan: #06b6d4;
    --accent-green: #10b981;
    --accent-purple: #8b5cf6;
    --border: #1e3a5f;
    --border-light: #2a4a7f;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.5);
    --gradient-hero: linear-gradient(135deg, #0a1628 0%, #0f1d32 40%, #0c1f3f 70%, #071126 100%);
    --gradient-blue: linear-gradient(135deg, #0ea5e9, #06b6d4);
    --gradient-card: linear-gradient(180deg, rgba(14, 165, 233, 0.05), rgba(14, 165, 233, 0.01));
    --radius-sm: 6px;
    --radius: 10px;
    --radius-lg: 16px;
    --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Noto Sans SC', sans-serif;
}

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

html { scroll-behavior: smooth; font-size: 16px; }

body {
    font-family: var(--font-sans);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; transition: all 0.3s ease; }
a:hover { color: var(--accent-light); }
img { max-width: 100%; height: auto; display: block; }
ul { list-style: none; }

.container { max-width: 1260px; margin: 0 auto; padding: 0 20px; }

/* ===== Buttons ===== */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 12px 28px; border-radius: var(--radius);
    font-size: 0.95rem; font-weight: 600; border: 2px solid transparent;
    cursor: pointer; transition: all 0.3s ease; text-decoration: none;
}
.btn-primary {
    background: var(--gradient-blue); color: #fff;
    box-shadow: 0 4px 16px rgba(14, 165, 233, 0.3);
}
.btn-primary:hover { box-shadow: 0 6px 24px rgba(14, 165, 233, 0.45); transform: translateY(-1px); color: #fff; }
.btn-outline {
    background: transparent; color: var(--accent); border-color: var(--accent);
}
.btn-outline:hover { background: rgba(14, 165, 233, 0.1); border-color: var(--accent-light); color: var(--accent-light); }

/* ===== Header ===== */
.header { position: sticky; top: 0; z-index: 1000; }

.header-top {
    background: rgba(5, 12, 24, 0.98);
    border-bottom: 1px solid var(--border);
    padding: 8px 0; font-size: 0.82rem;
}
.header-top-inner { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }

.trending-ticker {
    display: flex; align-items: center; gap: 8px;
    flex: 1; min-width: 0; overflow: hidden;
}
.trending-ticker i { color: var(--accent-red); animation: pulse 1.5s infinite; }
.ticker-label { color: var(--text-secondary); white-space: nowrap; font-weight: 600; }
.ticker-content { overflow: hidden; position: relative; flex: 1; }
.ticker-content a {
    display: none; color: var(--text-secondary);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 400px;
}
.ticker-content a.active { display: inline-block; animation: fadeIn 0.5s ease; }
.ticker-content a:hover { color: var(--accent-light); }

.header-utility { display: flex; gap: 16px; align-items: center; }
.header-utility a { color: var(--text-muted); font-size: 0.8rem; white-space: nowrap; }
.header-utility a:hover { color: var(--accent); }

.date-time { display: flex; align-items: center; gap: 12px; font-size: 0.8rem; color: var(--text-muted); }

.lang-selector { position: relative; }
.lang-btn {
    background: transparent; border: 1px solid var(--border);
    color: var(--text-secondary); padding: 4px 10px; border-radius: var(--radius-sm);
    cursor: pointer; display: flex; align-items: center; gap: 6px; font-size: 0.8rem;
}
.lang-btn:hover { border-color: var(--accent); color: var(--text-primary); }
.lang-dropdown {
    display: none; position: absolute; top: calc(100% + 6px); right: 0;
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-sm); min-width: 120px; z-index: 50; overflow: hidden;
}
.lang-dropdown.show { display: block; animation: fadeIn 0.2s ease; }
.lang-item {
    display: block; padding: 8px 14px; color: var(--text-secondary);
    font-size: 0.82rem; transition: all 0.2s ease;
}
.lang-item:hover, .lang-item.active { background: rgba(14, 165, 233, 0.1); color: var(--accent); }

.header-main { background: var(--bg-header); backdrop-filter: blur(12px); padding: 16px 0; border-bottom: 1px solid rgba(30, 58, 95, 0.5); }
.header-main-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; }

.header-left .logo {
    display: flex; align-items: center; gap: 10px; text-decoration: none;
}
.logo-icon {
    width: 42px; height: 42px; border-radius: 50%;
    background: var(--gradient-blue); display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 1.2rem; box-shadow: 0 4px 12px rgba(14, 165, 233, 0.4);
}
.logo-text { display: flex; flex-direction: column; }
.logo-title { font-size: 1.2rem; font-weight: 700; color: var(--text-primary); letter-spacing: 0.5px; }
.logo-subtitle { font-size: 0.7rem; color: var(--text-muted); letter-spacing: 1px; text-transform: uppercase; }

.header-right { flex: 1; max-width: 420px; }
.header-search-form { display: flex; position: relative; }
.header-search-form input {
    width: 100%; padding: 10px 48px 10px 18px;
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: 24px; color: var(--text-primary);
    font-size: 0.9rem; outline: none; transition: all 0.3s ease;
}
.header-search-form input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.15); }
.header-search-form input::placeholder { color: var(--text-muted); }
.header-search-form button {
    position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
    background: var(--gradient-blue); border: none; width: 36px; height: 36px;
    border-radius: 50%; color: #fff; cursor: pointer; display: flex;
    align-items: center; justify-content: center; transition: all 0.3s ease;
}
.header-search-form button:hover { box-shadow: 0 4px 12px rgba(14, 165, 233, 0.4); }

/* ===== Navigation ===== */
.nav { background: var(--bg-secondary); border-bottom: 2px solid var(--border); }
.nav-inner { display: flex; align-items: center; }

.mobile-toggle {
    display: none; background: none; border: none; color: var(--text-primary);
    font-size: 1.5rem; cursor: pointer; padding: 12px 0;
}

.nav-menu { display: flex; gap: 2px;  padding: 0; margin: 0; }
.nav-menu li { flex-shrink: 0; }
.nav-menu a {
    display: block; padding: 14px 4px; color: var(--text-secondary);
    font-size: 0.9rem; font-weight: 500; position: relative; transition: all 0.3s ease;
    white-space: nowrap;
}
.nav-menu a::after {
    content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%);
    width: 0; height: 2px; background: var(--gradient-blue); transition: width 0.3s ease;
}
.nav-menu a:hover, .nav-menu a.active {
    color: var(--accent-light);
}
.nav-menu a:hover::after, .nav-menu a.active::after { width: 70%; }

/* ===== Main Content ===== */
.main-content { min-height: 60vh; padding-bottom: 60px; }

/* ===== Hero Section ===== */
.hero-section {
    position: relative; padding: 80px 0 60px;
    background: var(--gradient-hero); overflow: hidden;
}
.hero-bg { position: absolute; inset: 0; overflow: hidden; }
.hero-particles { position: absolute; inset: 0; }
.particle {
    position: absolute; background: var(--accent); border-radius: 50%;
    opacity: 0.3; animation: float 6s ease-in-out infinite;
}
@keyframes float {
    0%, 100% { transform: translateY(0) scale(1); opacity: 0.2; }
    50% { transform: translateY(-20px) scale(1.5); opacity: 0.5; }
}
.hero-content { position: relative; z-index: 2; text-align: center; max-width: 800px; margin: 0 auto; }
.hero-title {
    font-size: 2.8rem; font-weight: 800; line-height: 1.3;
    background: linear-gradient(135deg, #e8edf2 0%, #0ea5e9 50%, #38bdf8 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text; margin-bottom: 16px;
}
.hero-desc {
    font-size: 1.1rem; color: var(--text-secondary); max-width: 650px;
    margin: 0 auto 30px; line-height: 1.6;
}
.hero-actions { display: flex; gap: 14px; justify-content: center; margin-bottom: 50px; }
.hero-stats {
    display: flex; justify-content: center; gap: 40px; flex-wrap: wrap;
    padding-top: 30px; border-top: 1px solid var(--border);
}
.stat-item { text-align: center; }
.stat-num {
    display: block; font-size: 2rem; font-weight: 700;
    background: var(--gradient-blue); -webkit-background-clip: text;
    -webkit-text-fill-color: transparent; background-clip: text;
}
.stat-label { font-size: 0.85rem; color: var(--text-muted); }

/* ===== Category Sections ===== */
.category-section { padding: 60px 0 0; }
.section-header {
    display: flex; align-items: flex-start; justify-content: space-between;
    margin-bottom: 28px; gap: 16px;
}
.section-header-left { flex: 1; }
.section-title {
    font-size: 1.5rem; font-weight: 700; color: var(--text-primary);
    margin-bottom: 6px;
    padding-left: 14px; border-left: 3px solid var(--accent);
}
.section-desc { font-size: 0.9rem; color: var(--text-muted); padding-left: 17px; }
.section-more {
    flex-shrink: 0; display: inline-flex; align-items: center; gap: 6px;
    color: var(--accent); font-size: 0.9rem; font-weight: 500; padding: 6px 0;
    transition: all 0.3s ease;
}
.section-more:hover { color: var(--accent-light); gap: 10px; }

/* ===== Post Grid ===== */
.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 24px; }
.post-card {
    background: var(--bg-card); border-radius: var(--radius);
    overflow: hidden; border: 1px solid var(--border);
    transition: all 0.3s ease;
}
.post-card:hover {
    border-color: var(--accent); transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(14, 165, 233, 0.12);
}
.post-card-image { position: relative; overflow: hidden; aspect-ratio: 16/10; background: var(--bg-secondary); }
.post-card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.post-card:hover .post-card-image img { transform: scale(1.06); }
.post-card-category {
    position: absolute; top: 12px; left: 12px;
    background: var(--gradient-blue); color: #fff; font-size: 0.72rem;
    padding: 4px 10px; border-radius: 20px; font-weight: 600;
}
.post-card-content { padding: 18px; }
.post-card-title { font-size: 1.05rem; font-weight: 600; line-height: 1.45; margin-bottom: 10px; }
.post-card-title a { color: var(--text-primary); }
.post-card-title a:hover { color: var(--accent-light); }
.post-card-excerpt {
    font-size: 0.85rem; color: var(--text-muted); line-height: 1.55;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
    margin-bottom: 14px;
}
.post-card-meta { display: flex; gap: 16px; font-size: 0.78rem; color: var(--text-muted); }
.post-card-meta i { margin-right: 4px; color: var(--accent); }

/* ===== Post List ===== */
.post-list { display: flex; flex-direction: column; gap: 20px; }
.post-list-item {
    display: flex; gap: 20px; background: var(--bg-card); border-radius: var(--radius);
    overflow: hidden; border: 1px solid var(--border); transition: all 0.3s ease;
}
.post-list-item:hover { border-color: var(--accent); box-shadow: 0 6px 20px rgba(14, 165, 233, 0.08); }
.post-list-image { flex-shrink: 0; width: 240px; aspect-ratio: 16/10; background: var(--bg-secondary); overflow: hidden; }
.post-list-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.post-list-item:hover .post-list-image img { transform: scale(1.05); }
.post-list-content { flex: 1; padding: 18px; display: flex; flex-direction: column; justify-content: flex-start; min-width: 0; }
.post-list-category {
    display: inline-block; color: var(--accent); font-size: 0.78rem;
    font-weight: 600; margin-bottom: 8px; text-transform: uppercase; letter-spacing: 0.5px;
}
.post-list-title { font-size: 1.15rem; font-weight: 600; line-height: 1.45; margin-bottom: 8px; }
.post-list-title a { color: var(--text-primary); }
.post-list-title a:hover { color: var(--accent-light); }
.post-list-excerpt {
    font-size: 0.88rem; color: var(--text-muted); line-height: 1.55;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
    margin-bottom: auto;
}
.post-list-meta { display: flex; gap: 16px; font-size: 0.78rem; color: var(--text-muted); margin-top: 12px; }
.post-list-meta i { color: var(--accent); margin-right: 4px; }

/* ===== Latest Section ===== */
.latest-section { padding: 60px 0 0; }

/* ===== Content Grid (sidebar layout) ===== */
.content-grid { display: grid; grid-template-columns: 1fr 320px; gap: 32px; align-items: start; }
.main-column { min-width: 0; }

/* ===== Sidebar ===== */
.sidebar { display: flex; flex-direction: column; gap: 24px; position: sticky; top: 140px; }
.sidebar-widget {
    background: var(--bg-card); border-radius: var(--radius);
    padding: 22px; border: 1px solid var(--border);
}
.widget-title {
    font-size: 1.05rem; font-weight: 700; color: var(--text-primary);
    margin-bottom: 16px; padding-bottom: 10px; border-bottom: 2px solid var(--border);
}

.sub-cat-list { display: flex; flex-direction: column; gap: 6px; }
.sub-cat-list a {
    display: block; padding: 8px 14px; color: var(--text-secondary);
    font-size: 0.88rem; border-radius: var(--radius-sm); transition: all 0.2s ease;
}
.sub-cat-list a:hover { background: rgba(14, 165, 233, 0.08); color: var(--accent-light); }

.popular-list { display: flex; flex-direction: column; gap: 4px; }
.popular-item {
    display: flex; align-items: center; gap: 12px; padding: 9px 10px;
    color: var(--text-secondary); border-radius: var(--radius-sm);
    font-size: 0.88rem; transition: all 0.2s ease; text-decoration: none;
}
.popular-item:hover { background: rgba(14, 165, 233, 0.06); color: var(--accent); }
.popular-num {
    flex-shrink: 0; width: 24px; height: 24px; border-radius: 6px;
    background: var(--bg-secondary); display: flex; align-items: center;
    justify-content: center; font-size: 0.72rem; font-weight: 700; color: var(--accent);
}

.tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-link {
    display: inline-block; padding: 5px 14px; background: rgba(14, 165, 233, 0.08);
    color: var(--accent-light); font-size: 0.82rem; border-radius: 20px;
    border: 1px solid rgba(14, 165, 233, 0.15); transition: all 0.3s ease;
}
.tag-link:hover { background: rgba(14, 165, 233, 0.2); border-color: var(--accent); color: #fff; }
.tag-link-lg { font-size: 0.92rem; padding: 8px 18px; }

/* ===== Page Header ===== */
.page-header {
    background: var(--gradient-hero); padding: 40px 0; border-bottom: 1px solid var(--border);
}
.page-title { font-size: 1.8rem; font-weight: 700; color: var(--text-primary); }
.page-desc { font-size: 0.95rem; color: var(--text-muted); margin-top: 8px; max-width: 700px; }

/* ===== Page Content Card ===== */
.page-content { padding: 30px 0; }
.content-card {
    background: var(--bg-card); border-radius: var(--radius); padding: 32px;
    border: 1px solid var(--border); line-height: 1.8; color: var(--text-secondary);
}
.content-card h2 { color: var(--text-primary); margin: 24px 0 12px; font-size: 1.3rem; }
.content-card h3 { color: var(--text-primary); margin: 20px 0 10px; font-size: 1.1rem; }
.content-card p { margin-bottom: 14px; }
.content-card ul { list-style: disc; margin-left: 20px; margin-bottom: 14px; }
.content-card ul li { margin-bottom: 6px; }

/* ===== Article Detail ===== */
.article-detail { padding: 30px 0; }
.article-header { margin-bottom: 24px; }
.article-category a {
    display: inline-block; color: var(--accent); font-size: 0.82rem;
    font-weight: 600; text-transform: uppercase; letter-spacing: 1px;
    margin-bottom: 10px;
}
.article-title {
    font-size: 2rem; font-weight: 800; color: var(--text-primary);
    line-height: 1.35; margin-bottom: 14px;
}
.article-meta { display: flex; gap: 20px; font-size: 0.85rem; color: var(--text-muted); }
.article-meta i { color: var(--accent); margin-right: 5px; }

.article-featured-image {
    margin-bottom: 28px; border-radius: var(--radius-lg); overflow: hidden;
    background: var(--bg-secondary);
}
.article-featured-image img { width: 100%; }

.article-content {
    font-size: 1.02rem; line-height: 1.85; color: var(--text-secondary);
}
.article-content p { margin-bottom: 18px; }
.article-content h2 { color: var(--text-primary); font-size: 1.4rem; margin: 32px 0 16px; padding-bottom: 8px; border-bottom: 1px solid var(--border); }
.article-content h3 { color: var(--text-primary); font-size: 1.15rem; margin: 24px 0 12px; }
.article-content strong { color: var(--text-primary); }
.article-content blockquote {
    border-left: 3px solid var(--accent); background: rgba(14, 165, 233, 0.05);
    padding: 16px 20px; margin: 20px 0; border-radius: 0 var(--radius) var(--radius) 0;
    color: var(--text-secondary); font-style: italic;
}
.article-content ul, .article-content ol { margin: 14px 0 14px 22px; }
.article-content li { margin-bottom: 6px; }
.article-content a { text-decoration: underline; }

.article-tags {
    margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--border);
    display: flex; align-items: center; flex-wrap: wrap; gap: 10px;
}
.tags-label { color: var(--text-muted); font-size: 0.88rem; }
.tags-label i { color: var(--accent); }

/* Article prev/next */
.article-pagination {
    display: grid; grid-template-columns: 1fr 1fr; gap: 20px;
    margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--border);
}
.article-prev, .article-next {
    display: flex; flex-direction: column; gap: 6px; padding: 16px 20px;
    background: var(--bg-card); border-radius: var(--radius); border: 1px solid var(--border);
    transition: all 0.3s ease;
}
.article-prev:hover, .article-next:hover { border-color: var(--accent); }
.article-next { text-align: right; }
.article-prev.disabled, .article-next.disabled {
    color: var(--text-muted); cursor: default; opacity: 0.5;
}
.pagination-label { font-size: 0.78rem; color: var(--text-muted); font-weight: 500; }
.pagination-title {
    font-size: 0.9rem; color: var(--text-secondary); font-weight: 500;
    display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden;
}

/* ===== Search ===== */
.search-form-page { margin: 20px 0; }
.search-input-group {
    display: flex; gap: 12px; max-width: 600px;
}
.search-input-group input {
    flex: 1; padding: 12px 20px; background: var(--bg-card);
    border: 1px solid var(--border); border-radius: var(--radius);
    color: var(--text-primary); font-size: 0.95rem; outline: none;
}
.search-input-group input:focus { border-color: var(--accent); }
.search-input-group button {
    padding: 12px 28px; background: var(--gradient-blue); border: none;
    border-radius: var(--radius); color: #fff; font-weight: 600; cursor: pointer;
    display: flex; align-items: center; gap: 8px; transition: all 0.3s ease;
}
.search-input-group button:hover { box-shadow: 0 4px 16px rgba(14, 165, 233, 0.4); }
.search-result-info { margin: 16px 0; color: var(--text-muted); font-size: 0.9rem; }

/* ===== Tag Cloud Page ===== */
.tag-cloud-page {
    display: flex; flex-wrap: wrap; gap: 12px; padding: 24px 0;
    justify-content: center;
}

/* ===== Pagination ===== */
.pagination { display: flex; justify-content: center; gap: 6px; padding: 30px 0; }
.pagination a, .pagination .current, .pagination .disabled {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 38px; height: 38px; padding: 0 12px;
    border-radius: var(--radius-sm); font-size: 0.88rem;
    border: 1px solid var(--border); color: var(--text-secondary);
    background: var(--bg-card); transition: all 0.3s ease;
}
.pagination a:hover { border-color: var(--accent); color: var(--accent); background: rgba(14, 165, 233, 0.1); }
.pagination .current { background: var(--gradient-blue); color: #fff; border-color: transparent; }
.pagination .disabled { opacity: 0.4; }

/* ===== Empty State ===== */
.empty-state {
    text-align: center; padding: 60px 20px; color: var(--text-muted);
}
.empty-state i { font-size: 3rem; margin-bottom: 16px; opacity: 0.4; display: block; }

/* ===== Error Page ===== */
.error-page { padding: 80px 0; }
.error-content { text-align: center; max-width: 500px; margin: 0 auto; }
.error-code {
    font-size: 8rem; font-weight: 900; line-height: 1;
    background: var(--gradient-blue); -webkit-background-clip: text;
    -webkit-text-fill-color: transparent; background-clip: text;
    margin-bottom: 10px;
}
.error-title { font-size: 1.6rem; font-weight: 700; margin-bottom: 12px; color: var(--text-primary); }
.error-desc { color: var(--text-muted); margin-bottom: 28px; line-height: 1.6; }
.error-actions { display: flex; gap: 14px; justify-content: center; }

/* ===== Footer ===== */
.footer { background: var(--bg-secondary); border-top: 2px solid var(--border); margin-top: 40px; }
.footer-wave { height: 4px; background: var(--gradient-blue); }
.footer-main { padding: 50px 0 30px; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 30px; }

.footer-widget h4 {
    font-size: 1.05rem; font-weight: 700; color: var(--text-primary);
    margin-bottom: 16px; display: flex; align-items: center; gap: 8px;
}
.footer-widget h4 i { color: var(--accent); }
.footer-about p { font-size: 0.88rem; color: var(--text-muted); line-height: 1.6; }
.footer-contact { margin-top: 12px; }
.footer-contact p { font-size: 0.85rem; color: var(--text-secondary); }

.footer-links { display: flex; flex-direction: column; gap: 8px; }
.footer-links a {
    font-size: 0.88rem; color: var(--text-muted); transition: all 0.2s ease;
    display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden;
}
.footer-links a:hover { color: var(--accent); padding-left: 6px; }

.footer-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.footer-tags a {
    font-size: 0.78rem; padding: 4px 12px; background: rgba(14, 165, 233, 0.06);
    color: var(--text-secondary); border-radius: 20px;
    border: 1px solid var(--border); transition: all 0.3s ease;
}
.footer-tags a:hover { background: rgba(14, 165, 233, 0.15); color: var(--accent-light); border-color: var(--accent); }

.footer-bottom {
    border-top: 1px solid var(--border); padding: 18px 0;
    text-align: center;
}
.footer-bottom p { font-size: 0.82rem; color: var(--text-muted); }

/* ===== Back to Top ===== */
.back-to-top {
    position: fixed; bottom: 30px; right: 30px; z-index: 99;
    width: 44px; height: 44px; border-radius: 50%; background: var(--gradient-blue);
    color: #fff; border: none; cursor: pointer; font-size: 1rem;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; transform: translateY(20px); pointer-events: none;
    transition: all 0.3s ease; box-shadow: 0 4px 16px rgba(14, 165, 233, 0.4);
}
.back-to-top.show { opacity: 1; transform: translateY(0); pointer-events: auto; }
.back-to-top:hover { transform: translateY(-3px); box-shadow: 0 6px 20px rgba(14, 165, 233, 0.5); }

/* ===== Animations ===== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    .hero-title { font-size: 1.8rem; }
    .hero-desc { font-size: 0.95rem; }
    .hero-stats { gap: 24px; }
    .hero-actions { flex-direction: column; align-items: center; }

    .content-grid { grid-template-columns: 1fr; }
    .sidebar { position: static; }

    .header-top-inner { flex-wrap: wrap; }
    .trending-ticker { max-width: 100%; }
    .header-utility { display: none; }

    .mobile-toggle { display: block; }
    .nav-menu {
        display: none; position: absolute; top: 100%; left: 0; right: 0;
        background: var(--bg-secondary); flex-direction: column;
        border-top: 1px solid var(--border); z-index: 40;
    }
    .nav-menu.active { display: flex; }
    .nav-menu a { padding: 14px 20px; border-bottom: 1px solid var(--border); }

    .post-list-item { flex-direction: column; }
    .post-list-image { width: 100%; aspect-ratio: 16/9; }

    .article-title { font-size: 1.4rem; }
    .article-pagination { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .article-content { font-size: 0.95rem; }

    .page-header { padding: 28px 0; }
    .page-title { font-size: 1.4rem; }
}

@media (max-width: 480px) {
    .hero-title { font-size: 1.4rem; }
    .post-grid { grid-template-columns: 1fr; }
    .error-code { font-size: 5rem; }
    .error-actions { flex-direction: column; align-items: center; }
    .search-input-group { flex-direction: column; }
}
