/* ===== Errin — Newspaper Theme ===== */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;500;600;700;800;900&family=Source+Serif+4:wght@400;500;600;700&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --bg: #faf8f5;
  --bg-card: #ffffff;
  --bg-card-hover: #fff9f0;
  --surface: #f3efe9;
  --text: #1a1a1a;
  --text-muted: #6b6560;
  --accent: #c0392b;
  --accent-hover: #a93226;
  --accent-glow: rgba(192, 57, 43, 0.08);
  --accent-secondary: #d4a059;
  --gradient: linear-gradient(135deg, #c0392b 0%, #d4a059 100%);
  --border: rgba(0, 0, 0, 0.08);
  --border-strong: rgba(0, 0, 0, 0.15);
  --radius: 6px;
  --radius-lg: 10px;
  --shadow: 0 2px 16px rgba(0,0,0,0.06);
  --shadow-hover: 0 8px 32px rgba(0,0,0,0.10);
  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --font-display: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-body: 'Source Serif 4', Georgia, serif;
  --max-width: 1200px;
  --header-height: 0px;
  --top-bar-height: 40px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

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

a { color: var(--accent); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--accent-hover); }
img { max-width: 100%; display: block; }

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ===== Header Ad Banner ===== */
.header-ad-banner {
  background: linear-gradient(135deg, #1a1a1a 0%, #2c2c2c 100%);
  text-align: center;
  padding: 10px 1rem;
  position: relative;
  z-index: 101;
  min-height: var(--top-bar-height);
  display: flex;
  align-items: center;
  justify-content: center;
}

.header-ad-banner a {
  color: #f5c842;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: color 0.2s;
  animation: adPulse 3s ease-in-out infinite;
}

.header-ad-banner a:hover {
  color: #ffe082;
}

@keyframes adPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.85; }
}

/* ===== Top Bar ===== */
.top-bar {
  background: #1a1a1a;
  color: #ccc;
  font-size: 0.78rem;
  padding: 0 1.5rem;
  height: var(--top-bar-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.top-bar-date { font-weight: 500; }
.top-bar-links { display: flex; gap: 1.25rem; }
.top-bar-links a { color: #aaa; transition: color 0.2s; }
.top-bar-links a:hover { color: #fff; }

/* ===== Header ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(250, 248, 245, 0.97);
  backdrop-filter: blur(12px);
  border-bottom: 3px double var(--border-strong);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.65rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.logo-icon {
  width: 38px;
  height: 38px;
  background: var(--accent);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  color: #fff;
  font-weight: 900;
  font-family: var(--font-display);
}

.nav-links {
  display: flex;
  gap: 0.25rem;
  list-style: none;
}

.nav-links a {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.45rem 1rem;
  border-radius: var(--radius);
  transition: all 0.2s;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.nav-links a:hover {
  color: var(--accent);
  background: var(--accent-glow);
}

.menu-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border-strong);
  color: var(--text);
  font-size: 1.25rem;
  cursor: pointer;
  width: 40px;
  height: 40px;
  border-radius: var(--radius);
  transition: all 0.2s;
}

.menu-toggle:hover {
  background: var(--surface);
}

/* ===== Hero / Featured Section ===== */
.hero {
  padding: 4rem 0 3.5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(ellipse at center top, rgba(192,57,43,0.04) 0%, transparent 70%);
  pointer-events: none;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--accent);
  color: #fff;
  padding: 0.35rem 1rem;
  border-radius: 3px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  font-weight: 900;
  line-height: 1.15;
  margin-bottom: 1.25rem;
  color: var(--text);
  letter-spacing: -0.02em;
}

.hero p {
  font-family: var(--font-body);
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 2rem;
  line-height: 1.75;
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 3rem;
  flex-wrap: wrap;
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

.stat-item { text-align: center; }

.stat-number {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 900;
  color: var(--accent);
}

.stat-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
}

/* ===== Section Titles ===== */
.section-title {
  font-family: var(--font-display);
  font-size: 1.85rem;
  font-weight: 800;
  margin-bottom: 0.35rem;
  color: var(--text);
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: '';
  display: block;
  width: 50px;
  height: 3px;
  background: var(--accent);
  margin-top: 0.5rem;
}

.section-subtitle {
  color: var(--text-muted);
  margin-bottom: 2rem;
  font-family: var(--font-body);
}

/* ===== Filters ===== */
.filter-bar {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}

.filter-btn {
  background: transparent;
  border: 1px solid var(--border-strong);
  color: var(--text-muted);
  padding: 0.45rem 1.1rem;
  border-radius: 3px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  font-family: var(--font);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

/* ===== Topic Grid — Newspaper Cards ===== */
#topics { padding-top: 3rem; padding-bottom: 1rem; }

.topics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1.5rem;
  padding-bottom: 4rem;
}

.topic-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem 1.5rem 1.25rem;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  text-decoration: none;
  color: inherit;
  position: relative;
}

.topic-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent);
  opacity: 0;
  transition: opacity 0.3s;
}

.topic-card:hover {
  background: var(--bg-card-hover);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

.topic-card:hover::before { opacity: 1; }

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.category-tag {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.25rem 0.6rem;
  border-radius: 2px;
  background: var(--accent);
  color: #fff;
}

.read-time {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 500;
}

.topic-card h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.35;
  flex: 1;
  color: var(--text);
}

.topic-card p {
  font-family: var(--font-body);
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
}

.read-more {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.trending-badge {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #d4a059;
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

/* ===== Article Page ===== */
.article-header {
  padding: 2.5rem 0 2rem;
  border-bottom: 2px solid var(--text);
  margin-bottom: 2.5rem;
}

.breadcrumb {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 500;
}

.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--accent); }

.article-header h1 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 900;
  line-height: 1.2;
  margin-bottom: 1rem;
  color: var(--text);
  letter-spacing: -0.01em;
}

.article-meta {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 500;
}

.article-meta span {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

/* Article Layout with Sidebar */
.article-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 3rem;
  padding-bottom: 4rem;
}

.article-content {
  max-width: 720px;
}

.article-content h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  margin: 2.5rem 0 1rem;
  color: var(--text);
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}

.article-content h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  margin: 1.75rem 0 0.5rem;
  color: var(--text);
  line-height: 1.4;
}

.article-content p {
  font-family: var(--font-body);
  margin-bottom: 1.25rem;
  color: #333;
  font-size: 1.05rem;
  line-height: 1.8;
}

.article-content ul,
.article-content ol {
  margin: 0 0 1.25rem 1.5rem;
  color: #333;
  font-family: var(--font-body);
}

.article-content li { margin-bottom: 0.5rem; }

.article-content blockquote {
  border-left: 4px solid var(--accent);
  padding: 1rem 1.5rem;
  margin: 1.5rem 0;
  background: var(--accent-glow);
  border-radius: 0 var(--radius) var(--radius) 0;
  color: var(--text-muted);
  font-style: italic;
  font-family: var(--font-body);
}

.article-content strong { color: var(--text); }

.article-content .disclaimer {
  font-size: 0.85rem;
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  margin-top: 2.5rem;
  background: var(--surface);
  font-family: var(--font);
}

/* ===== In-Article Ad Containers ===== */
.ad-container-inline {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 1.25rem;
  margin: 2rem 0;
  text-align: center;
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  position: relative;
}

.ad-container-inline::before {
  content: 'Advertisement';
  position: absolute;
  top: 4px;
  right: 8px;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #aaa;
  font-weight: 600;
}

.ad-container-sidebar {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  margin-bottom: 1.5rem;
  text-align: center;
  min-height: 250px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  position: relative;
}

.ad-container-sidebar::before {
  content: 'Sponsored';
  display: block;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #aaa;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

/* ===== Sidebar ===== */
.article-sidebar {
  position: sticky;
  top: calc(var(--header-height) + 5.5rem);
  align-self: start;
}

.sidebar-box {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}

.sidebar-box h4 {
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--text);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--accent);
}

.toc-list { list-style: none; margin: 0; }
.toc-list li { margin-bottom: 0.4rem; }

.toc-list a {
  font-size: 0.85rem;
  color: var(--text-muted);
  display: block;
  padding: 0.3rem 0;
  border-left: 2px solid transparent;
  padding-left: 0.75rem;
  transition: all 0.2s;
}

.toc-list a:hover {
  color: var(--accent);
  border-left-color: var(--accent);
}

.related-list { list-style: none; margin: 0; }

.related-list li {
  margin-bottom: 0.6rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--border);
}

.related-list li:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.related-list a {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.4;
  display: block;
  font-weight: 500;
}

.related-list a:hover { color: var(--accent); }

/* ===== Page Content (About, Contact, Privacy) ===== */
.page-content {
  max-width: 760px;
  margin: 0 auto;
  padding: 3rem 0 4rem;
}

.page-content h1 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 900;
  margin-bottom: 1.5rem;
  color: var(--text);
}

.page-content h2 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  margin: 2rem 0 0.75rem;
  color: var(--text);
}

.page-content p {
  color: #444;
  margin-bottom: 1.25rem;
  line-height: 1.75;
  font-family: var(--font-body);
}

.page-content ul {
  margin: 0 0 1.25rem 1.5rem;
  color: #444;
  font-family: var(--font-body);
}

.page-content li { margin-bottom: 0.5rem; }

/* ===== Newsletter CTA ===== */
.newsletter {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 3rem;
  text-align: center;
  margin: 2rem 0 4rem;
  position: relative;
  overflow: hidden;
}

.newsletter::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(192,57,43,0.03) 0%, transparent 70%);
  pointer-events: none;
}

.newsletter h2 {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 800;
  margin-bottom: 0.75rem;
  position: relative;
  color: var(--text);
}

.newsletter p {
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  position: relative;
  font-family: var(--font-body);
}

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

.newsletter-form input {
  flex: 1;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  color: var(--text);
  font-family: var(--font);
  font-size: 0.925rem;
  outline: none;
  transition: border-color 0.2s;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--accent);
  color: #fff;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.btn:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
}

/* ===== Footer ===== */
.site-footer {
  background: #1a1a1a;
  color: #ccc;
  border-top: 4px solid var(--accent);
  padding: 3rem 0 2rem;
}

.site-footer .logo { color: #fff; }
.site-footer .logo-icon { background: var(--accent); color: #fff; }

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 2.5rem;
}

.footer-brand p {
  color: #999;
  font-size: 0.9rem;
  margin-top: 1rem;
  max-width: 320px;
  font-family: var(--font-body);
}

.footer-col h4 {
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #fff;
  margin-bottom: 1rem;
}

.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 0.5rem; }

.footer-col a {
  color: #999;
  font-size: 0.9rem;
  transition: color 0.2s;
}

.footer-col a:hover { color: var(--accent); }

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-bottom p {
  color: #777;
  font-size: 0.85rem;
}

/* Hidden cards for filter */
.topic-card.hidden { display: none; }

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .article-layout { grid-template-columns: 1fr; }
  .article-sidebar { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-card);
    border-bottom: 2px solid var(--accent);
    flex-direction: column;
    padding: 0.5rem 1.5rem;
    gap: 0;
    box-shadow: var(--shadow);
  }

  .nav-links.open { display: flex; }

  .nav-links li {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border);
  }

  .nav-links li:last-child { border-bottom: none; }

  .menu-toggle { display: block; }
  .topics-grid { grid-template-columns: 1fr; }
  .hero-stats { gap: 1.5rem; }
  .newsletter-form { flex-direction: column; }
  .footer-grid { grid-template-columns: 1fr; }
  .top-bar { display: none; }
  .header-ad-banner { font-size: 0.78rem; }
}
