/* ========================================
   CRYPTO INSIGHT v3 — Modern Dark/Light
   Inspired by journalducoin.com, elevated
   Accent: Amber/Gold (#F59E0B)
   ======================================== */

/* ─── THEME VARIABLES ─── */
:root {
  --bg: #0B0F19;
  --bg-secondary: #0F1525;
  --bg-card: #141B2D;
  --bg-hover: #1A2342;
  --bg-elevated: #1E2948;
  --text: #E2E8F0;
  --text-muted: #94A3B8;
  --text-dim: #64748B;
  --accent: #F59E0B;
  --accent-hover: #D97706;
  --accent-light: #FEF3C7;
  --accent-glow: rgba(245,158,11,0.15);
  --border: #1E293B;
  --border-light: #334155;
  --success: #10B981;
  --danger: #EF4444;
  --info: #3B82F6;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-serif: 'Merriweather', Georgia, serif;
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 16px;
  --shadow: 0 4px 24px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 40px rgba(0,0,0,0.5);
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.2);
  --max-w: 1280px;
  --header-h: 68px;
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="light"] {
  --bg: #F8FAFC;
  --bg-secondary: #F1F5F9;
  --bg-card: #FFFFFF;
  --bg-hover: #F1F5F9;
  --bg-elevated: #FFFFFF;
  --text: #0F172A;
  --text-muted: #475569;
  --text-dim: #94A3B8;
  --accent: #D97706;
  --accent-hover: #B45309;
  --accent-light: #FEF3C7;
  --accent-glow: rgba(245,158,11,0.08);
  --border: #E2E8F0;
  --border-light: #CBD5E1;
  --shadow: 0 4px 24px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 40px rgba(0,0,0,0.12);
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: #F8FAFC;
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  font-size: 16px;
  transition: background 0.3s ease, color 0.3s ease;
}

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

/* ─── ANIMATIONS ─── */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes slideInRight {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}
@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}
.fade-in { animation: fadeIn 0.5s ease forwards; }
.stagger-1 { animation-delay: 0.1s; }
.stagger-2 { animation-delay: 0.2s; }
.stagger-3 { animation-delay: 0.3s; }

/* ─── EDUCATIONAL HERO ─── */
.edu-hero-section {
  padding: 32px 0 24px;
}
.edu-hero-inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 32px;
  align-items: start;
}
.edu-hero-content {
  background: linear-gradient(135deg, var(--accent-glow), var(--bg-hover));
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 32px;
}
.edu-badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  background: var(--accent-glow);
  padding: 6px 14px;
  border-radius: 20px;
  margin-bottom: 16px;
}
.edu-hero-title {
  font-size: 28px;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 14px;
  letter-spacing: -0.02em;
}
.edu-hero-desc {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 24px;
}
.edu-hero-cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 12px 24px;
  background: var(--accent);
  color: var(--bg);
  font-weight: 700;
  font-size: 14px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: background 0.2s, transform 0.2s;
}
.btn-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
}
.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 12px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  color: var(--text);
  font-weight: 600;
  font-size: 14px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: all 0.2s;
}
.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.edu-guides-grid {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
}
.edu-guides-title {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text);
}
.edu-guide-cards {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.edu-guide-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  background: #F8FAFC;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: all 0.2s;
}
.edu-guide-card:hover {
  border-color: var(--accent);
  background: var(--accent-glow);
}
.edu-guide-num {
  font-size: 14px;
  font-weight: 800;
  color: var(--accent);
  min-width: 24px;
  text-align: center;
  line-height: 1.4;
}
.edu-guide-text {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  line-height: 1.5;
}
.edu-guide-card:hover .edu-guide-text {
  color: var(--text);
}

/* ─── HEADER ─── */
.site-header {
  background: #F8FAFC;
  border-bottom: none;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-top {
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-size: 24px;
  font-weight: 800;
  color: var(--accent);
  text-decoration: none;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 10px;
}
.logo-img {
  width: auto;
  height: auto; max-height: 70px;
  border-radius: 0;
  object-fit: contain;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Theme Toggle */
.theme-toggle {
  width: auto;
  height: auto; max-height: 70px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  transition: var(--transition);
}
.theme-toggle:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-glow);
}

/* Language Widget */
.lang-widget { position: relative; }
.lang-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}
.lang-btn:hover { border-color: var(--accent); color: var(--text); }
.lang-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px;
  min-width: 180px;
  box-shadow: var(--shadow-lg);
  z-index: 1001;
}
.lang-dropdown.active { display: block; animation: fadeIn 0.15s ease; }
.lang-dropdown a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.15s;
}
.lang-dropdown a:hover {
  background: var(--accent-glow);
  color: var(--accent);
}
.lang-flag { font-size: 16px; }

/* Category Nav */
.cat-nav {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.cat-nav::-webkit-scrollbar { display: none; }
.cat-nav .container {
  display: flex;
  gap: 4px;
  padding: 8px 24px;
}
.cat-nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 20px;
  white-space: nowrap;
  transition: var(--transition);
}
.cat-nav a:hover,
.cat-nav a.active {
  color: var(--accent);
  background: var(--accent-glow);
}

/* Mobile Menu */
.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  cursor: pointer;
  padding: 8px;
  font-size: 24px;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
}

.mobile-nav {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: #F8FAFC;
  z-index: 999;
  padding: 80px 24px 24px;
  flex-direction: column;
  gap: 8px;
  overflow-y: auto;
}
.mobile-nav.active { display: flex; }
.mobile-nav a {
  color: var(--text);
  text-decoration: none;
  font-size: 18px;
  font-weight: 600;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  min-height: 44px;
  display: flex;
  align-items: center;
}
.mobile-nav .mobile-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  color: var(--text);
  font-size: 28px;
  cursor: pointer;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ─── HERO ─── */
.hero-section { padding: 40px 0 32px; }
.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 24px;
}
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; } }

.featured-main {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  transition: var(--transition);
}
.featured-main:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--border-light);
}
.featured-main .card-img {
  height: 280px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
}
.featured-main .card-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.5s ease;
}
.featured-main:hover .card-img img { transform: scale(1.03); }
.featured-main .card-img::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 100px;
  background: linear-gradient(transparent, var(--bg-card));
}
.featured-main .card-body {
  padding: 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.featured-main .category-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  margin-bottom: 12px;
}
.featured-main h2 {
  font-size: 26px;
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 12px;
}
.featured-main h2 a {
  color: var(--text);
  text-decoration: none;
}
.featured-main h2 a:hover { color: var(--accent); }
.featured-main p {
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.6;
  flex: 1;
}
.featured-main .meta {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 16px;
  font-size: 13px;
  color: var(--text-dim);
}

.hero-secondary {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.hero-secondary .article-card {
  flex-direction: row;
  display: flex;
}
.hero-secondary .article-card .card-img {
  width: 160px;
  min-width: 160px;
  height: 120px;
}
.hero-secondary .article-card .card-body {
  padding: 16px;
  flex: 1;
}
.hero-secondary .article-card h3 {
  font-size: 15px;
  margin-bottom: 8px;
}

/* ─── SECTIONS ─── */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}
.section-title {
  font-size: 20px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 10px;
}
.section-title .icon {
  width: 8px; height: 8px;
  background: var(--accent);
  border-radius: 2px;
}
.section-link {
  font-size: 13px;
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
}
.section-link:hover { text-decoration: underline; }

/* ─── ARTICLES ─── */
.articles-section { padding: 24px 0 48px; }
.articles-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 32px;
}
@media (max-width: 960px) { .articles-layout { grid-template-columns: 1fr; } }

.articles-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
@media (max-width: 640px) { .articles-grid { grid-template-columns: 1fr; } }

.article-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: var(--transition);
}
.article-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  border-color: var(--border-light);
}
.article-card .card-img {
  height: 180px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
}
.article-card .card-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.4s ease;
}
.article-card:hover .card-img img { transform: scale(1.05); }
.article-card .card-img::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--accent-glow) 0%, transparent 60%);
  z-index: 1;
}
.article-card .card-body { padding: 20px; }
.article-card .category-tag {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  margin-bottom: 10px;
  display: block;
}
.article-card h3 {
  font-size: 17px;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: 10px;
}
.article-card h3 a {
  color: var(--text) !important;
  text-decoration: none !important;
}
.article-card h3 a:hover { color: var(--accent) !important; }
.article-card p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 14px;
}
.article-card .meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-dim);
}

/* ─── SIDEBAR ─── */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.sidebar-widget {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}
.sidebar-widget h4 {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

/* TOC Widget */
.toc-widget { position: sticky; top: calc(var(--header-h) + 20px); }
.toc-list { list-style: none; }
.toc-list li { margin-bottom: 4px; }
.toc-list a {
  display: block;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.15s;
  border-left: 2px solid transparent;
}
.toc-list a:hover,
.toc-list a.active {
  background: var(--accent-glow);
  color: var(--accent);
  border-left-color: var(--accent);
}

.popular-list { list-style: none; }
.popular-list li {
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.popular-list li:last-child { border-bottom: none; }
.popular-list a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  line-height: 1.5;
  transition: color 0.2s;
}
.popular-list a:hover { color: var(--accent); }
.popular-list .num {
  font-size: 18px;
  font-weight: 800;
  color: var(--border-light);
  min-width: 24px;
  line-height: 1;
}
.popular-list a:hover .num { color: var(--accent); }

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.tag-cloud a {
  font-size: 12px;
  padding: 6px 12px;
  background: #F8FAFC;
  border: 1px solid var(--border);
  border-radius: 20px;
  color: var(--text-muted);
  text-decoration: none;
  transition: var(--transition);
}
.tag-cloud a:hover,
.tag-cloud a.active {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-glow);
}

.newsletter-widget p {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 14px;
}
.newsletter-form {
  display: flex;
  gap: 8px;
}
.newsletter-form input {
  flex: 1;
  padding: 10px 14px;
  background: #F8FAFC;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 14px;
  outline: none;
  transition: var(--transition);
}
.newsletter-form input:focus { border-color: var(--accent); }
.newsletter-form input::placeholder { color: var(--text-dim); }
.newsletter-form button {
  padding: 10px 18px;
  background: var(--accent);
  border: none;
  border-radius: var(--radius-sm);
  color: var(--bg);
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  transition: background 0.2s;
}
.newsletter-form button:hover { background: var(--accent-hover); }

/* ─── ADS ─── */
.ad-container {
  text-align: center;
  padding: 16px 0;
  min-height: 90px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin: 20px 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.ad-top { border-bottom: 1px solid var(--border); }
.ad-bottom { border-top: 1px solid var(--border); margin-top: 24px; }
.ad-sidebar { min-height: 250px; }
.ad-home { max-width: var(--max-w); margin: 0 auto 24px; padding: 0 24px; }

/* Mobile Anchor Ad */
.ad-anchor-mobile {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 998;
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  padding: 8px 0;
  min-height: 60px;
  display: none;
  text-align: center;
}
@media (max-width: 768px) {
  .ad-anchor-mobile { display: flex; align-items: center; justify-content: center; }
  body { padding-bottom: 70px !important; }
}

/* ─── FOOTER ─── */
.site-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  margin-top: 48px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  gap: 32px;
  padding: 48px 0 32px;
}
@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 24px; padding: 32px 0; }
}
@media (max-width: 480px) {
  .footer-grid { grid-template-columns: 1fr; }
}

.footer-brand .logo {
  margin-bottom: 16px;
}
.footer-brand p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 20px;
}
.footer-social {
  display: flex;
  gap: 10px;
}
.footer-social a {
  width: 36px;
  height: 36px;
  border-radius: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 16px;
  transition: var(--transition);
}
.footer-social a:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-glow);
}

.footer-section h4 {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text);
  margin-bottom: 16px;
}
.footer-section ul { list-style: none; }
.footer-section ul li { margin-bottom: 10px; }
.footer-section ul a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.2s;
}
.footer-section ul a:hover { color: var(--accent); }

.footer-newsletter {
  grid-column: 1 / -1;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
@media (max-width: 768px) {
  .footer-newsletter { flex-direction: column; text-align: center; }
}
.footer-newsletter h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 6px;
}
.footer-newsletter p {
  font-size: 14px;
  color: var(--text-muted);
}
.footer-newsletter form {
  display: flex;
  gap: 8px;
  min-width: 320px;
}
.footer-newsletter input {
  flex: 1;
  padding: 12px 16px;
  background: #F8FAFC;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 14px;
  outline: none;
}
.footer-newsletter button {
  padding: 12px 24px;
  background: var(--accent);
  border: none;
  border-radius: var(--radius-sm);
  color: var(--bg);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}
.footer-newsletter button:hover { background: var(--accent-hover); }

.footer-bottom {
  border-top: 1px solid var(--border);
  padding: 20px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.footer-bottom p {
  font-size: 13px;
  color: var(--text-dim);
}
.footer-bottom-links {
  display: flex;
  gap: 20px;
}
.footer-bottom-links a {
  font-size: 13px;
  color: var(--text-dim);
  text-decoration: none;
}
.footer-bottom-links a:hover { color: var(--accent); }

/* ─── ARTICLE PAGE ─── */
.article-page { padding: 24px 0 48px; }
.article-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 40px;
}
@media (max-width: 960px) { .article-layout { grid-template-columns: 1fr; } }

.article-main {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.article-header {
  padding: 32px 40px 24px;
  border-bottom: 1px solid var(--border);
}
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-dim);
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.breadcrumb a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
}
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb .sep {
  color: var(--text-dim);
  font-size: 11px;
}
.breadcrumb .current { color: var(--text-muted); }

.article-header .category-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent);
  margin-bottom: 16px;
}
.article-header h1 {
  font-size: 34px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
  color: var(--text);
}
.article-header .excerpt {
  font-size: 17px;
  color: var(--text-muted);
  line-height: 1.6;
}
.article-header .meta {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 20px;
  font-size: 13px;
  color: var(--text-dim);
}

.article-body {
  padding: 32px 40px;
  font-family: var(--font-serif);
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-muted);
}
.article-body h2 {
  font-family: var(--font);
  font-size: 26px;
  font-weight: 700;
  color: var(--text);
  margin-top: 40px;
  margin-bottom: 16px;
  letter-spacing: -0.01em;
  scroll-margin-top: calc(var(--header-h) + 20px);
}
.article-body h3 {
  font-family: var(--font);
  font-size: 21px;
  font-weight: 600;
  color: var(--text);
  margin-top: 32px;
  margin-bottom: 12px;
  scroll-margin-top: calc(var(--header-h) + 20px);
}
.article-body p { margin-bottom: 20px; }
.article-body strong { color: var(--text); font-weight: 600; }
.article-body a { color: var(--accent); text-decoration: none; }
.article-body a:hover { text-decoration: underline; }
.article-body blockquote {
  border-left: 3px solid var(--accent);
  padding: 16px 20px;
  margin: 24px 0;
  background: var(--bg-hover);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
  color: var(--text);
}
.article-body ul, .article-body ol { margin: 16px 0 24px 24px; }
.article-body li { margin-bottom: 10px; }
.article-body hr { border: none; border-top: 1px solid var(--border); margin: 40px 0; }
.article-body code {
  font-family: 'SF Mono', Monaco, monospace;
  font-size: 14px;
  background: #F8FAFC;
  padding: 2px 8px;
  border-radius: 4px;
  color: var(--accent);
}
.article-body img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius);
  margin: 16px 0;
}

.article-footer-section {
  padding: 24px 40px;
  border-top: 1px solid var(--border);
}
.article-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}
.article-tags .tag {
  font-size: 12px;
  padding: 6px 14px;
  background: #F8FAFC;
  border: 1px solid var(--border);
  border-radius: 20px;
  color: var(--text-muted);
  text-decoration: none;
  transition: var(--transition);
}
.article-tags .tag:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* Article Share */
.article-share h4 {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text);
  margin-bottom: 14px;
}
.share-buttons {
  display: flex;
  gap: 10px;
}
.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #F8FAFC;
  border: 1px solid var(--border);
  color: var(--text-muted);
  text-decoration: none;
  font-size: 15px;
  font-weight: 700;
  transition: var(--transition);
}
.share-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-glow);
}
.share-btn.twitter { font-family: sans-serif; }
.share-btn.facebook { font-family: sans-serif; }
.share-btn.linkedin { font-family: sans-serif; }

/* Newsletter CTA in article */
.article-newsletter-cta {
  padding: 0 40px;
  margin: 24px 0;
}
.newsletter-cta-inner {
  background: linear-gradient(135deg, var(--accent-glow), var(--bg-hover));
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 28px 32px;
  text-align: center;
}
.newsletter-cta-inner h3 {
  font-family: var(--font);
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}
.newsletter-cta-inner p {
  font-family: var(--font);
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 16px;
  line-height: 1.6;
}
.newsletter-cta-inner small {
  font-family: var(--font);
  display: block;
  margin-top: 10px;
  font-size: 12px;
  color: var(--text-dim);
}

/* ─── RELATED ARTICLES ─── */
.related-section { margin-top: 40px; }
.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
@media (max-width: 768px) { .related-grid { grid-template-columns: 1fr; } }

/* ─── CATEGORY PAGE ─── */
.category-header {
  padding: 40px 0 24px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 32px;
}
.category-header h1 {
  font-size: 36px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
}
.category-header p {
  color: var(--text-muted);
  margin-top: 8px;
  font-size: 16px;
}

/* ─── PAGINATION ─── */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 40px;
}
.pagination a, .pagination span {
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: var(--transition);
}
.pagination a {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-muted);
}
.pagination a:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.pagination .current {
  background: var(--accent);
  color: var(--bg);
}

/* ─── 404 ─── */
.not-found {
  text-align: center;
  padding: 80px 20px;
}
.not-found h1 {
  font-size: 120px;
  font-weight: 800;
  color: var(--border-light);
  line-height: 1;
}
.not-found h2 {
  font-size: 24px;
  font-weight: 700;
  color: var(--text);
  margin: 16px 0;
}
.not-found p { color: var(--text-muted); margin-bottom: 24px; }
.not-found a {
  display: inline-block;
  padding: 12px 24px;
  background: var(--accent);
  color: var(--bg);
  text-decoration: none;
  border-radius: var(--radius-sm);
  font-weight: 600;
  transition: background 0.2s;
}
.not-found a:hover { background: var(--accent-hover); }

/* ─── CHATBOT ─── */
.chatbot-widget {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
}
.chatbot-toggle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-hover));
  border: none;
  color: white;
  font-size: 24px;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(245,158,11,0.4);
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}
.chatbot-toggle:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 28px rgba(245,158,11,0.5);
}
.chatbot-panel {
  position: absolute;
  bottom: 72px;
  right: 0;
  width: 360px;
  max-height: 500px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: none;
  flex-direction: column;
  overflow: hidden;
}
.chatbot-panel.active { display: flex; animation: slideInRight 0.2s ease; }
.chatbot-header {
  padding: 16px 20px;
  background: linear-gradient(135deg, var(--accent), var(--accent-hover));
  color: white;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.chatbot-header h4 {
  font-size: 15px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}
.chatbot-close {
  background: none;
  border: none;
  color: white;
  font-size: 20px;
  cursor: pointer;
}
.chatbot-body {
  flex: 1;
  padding: 16px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.chatbot-msg {
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  line-height: 1.5;
  max-width: 85%;
}
.chatbot-msg.bot {
  background: var(--bg-hover);
  color: var(--text);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}
.chatbot-msg.user {
  background: var(--accent);
  color: var(--bg);
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}
.chatbot-input {
  display: flex;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  background: #F8FAFC;
}
.chatbot-input input {
  flex: 1;
  padding: 10px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  color: var(--text);
  font-size: 16px;
  outline: none;
}
.chatbot-input button {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--accent);
  border: none;
  color: var(--bg);
  cursor: pointer;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}
.chatbot-input button:hover { background: var(--accent-hover); }

/* ─── BACK TO TOP ─── */
.back-to-top {
  position: fixed;
  bottom: 24px;
  left: 24px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  z-index: 999;
}
.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}
.back-to-top:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-glow);
}

/* ─── SCROLLBAR ─── */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #F8FAFC; }
::-webkit-scrollbar-thumb { background: var(--border-light); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-dim); }

/* ─── RESPONSIVE ─── */
@media (max-width: 768px) {
  .mobile-menu-btn { display: flex; }
  .cat-nav .container { padding: 8px 16px; }

  .edu-hero-inner { grid-template-columns: 1fr; }
  .edu-hero-title { font-size: 22px; }
  .edu-hero-cta { flex-direction: column; }
  .btn-primary, .btn-secondary { width: 100%; justify-content: center; }

  .hero-grid { grid-template-columns: 1fr; }
  .articles-layout { grid-template-columns: 1fr; }
  .articles-grid { grid-template-columns: 1fr; }
  .article-layout { grid-template-columns: 1fr; }
  .related-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }

  .article-header { padding: 24px 20px; }
  .article-header h1 { font-size: 24px; }
  .article-body { padding: 24px 20px; font-size: 16px; }
  .article-body h2 { font-size: 20px; }
  .article-newsletter-cta { padding: 0 20px; }
  .newsletter-cta-inner { padding: 20px 24px; }

  .featured-main .card-img { height: 180px; }
  .featured-main h2 { font-size: 20px; }
  .hero-secondary .article-card { flex-direction: column; }
  .hero-secondary .article-card .card-img { width: 100%; height: 160px; }

  .sidebar { display: none; }
  .sidebar-mobile-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    margin-bottom: 16px;
  }
  .sidebar-mobile-content {
    display: none;
    margin-bottom: 16px;
  }
  .sidebar-mobile-content.active { display: block; }

  .chatbot-panel { width: calc(100vw - 32px); right: -12px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }

  .newsletter-form { flex-direction: column; }
  .newsletter-form input, .newsletter-form button { width: 100%; }
  .newsletter-form button { padding: 12px; font-size: 16px; }

  .footer-newsletter { padding: 24px; }
  .footer-newsletter form { min-width: auto; width: 100%; flex-direction: column; }
  .footer-newsletter input, .footer-newsletter button { width: 100%; }
  .footer-newsletter button { padding: 12px; font-size: 16px; }

  .ad-home { padding: 0 16px; }
}

@media (max-width: 480px) {
  .container { padding: 0 16px; }
  .section-header { flex-direction: column; align-items: flex-start; gap: 8px; }
  .share-buttons { gap: 6px; }
}

/* Google Translate hide banner */
.goog-te-banner-frame { display: none !important; }
body { top: 0 !important; }
