/* ==========================================================
   ReptiTrack Blog Stylesheet
   Matches the landing page design system exactly.
   ========================================================== */

/* ========== RESET & BASE ========== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg: #fafbfe;
  --bg-dark: #0f0f1a;
  --text: #1e293b;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  --primary: #6366f1;
  --primary-hover: #4f46e5;
  --primary-light: #eef2ff;
  --primary-dark: #4338ca;
  --border: #e2e8f0;
  --card-bg: #ffffff;
  --success: #10b981;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
  --shadow: 0 4px 12px rgba(0,0,0,0.06);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.1);
  --shadow-xl: 0 25px 60px rgba(0,0,0,0.12);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}


/* ========== BRAND LOGO ========== */
.brand-logo {
  font-family: 'Outfit', -apple-system, sans-serif;
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--text);
  text-decoration: none;
  line-height: 1;
  display: inline-flex;
  align-items: center;
}

.brand-logo-img {
  height: 36px;
  width: auto;
  border-radius: 6px;
  margin-right: 0.45rem;
}

.brand-logo span {
  color: var(--primary);
}


/* ========== BUTTONS ========== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border: none;
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 2px 8px rgba(99,102,241,0.3);
}

.btn-primary:hover {
  background: var(--primary-hover);
  box-shadow: 0 4px 16px rgba(99,102,241,0.4);
  transform: translateY(-1px);
}

.btn-secondary {
  background: var(--card-bg);
  color: var(--text);
  border: 1.5px solid var(--border);
}

.btn-secondary:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.btn-white {
  background: #fff;
  color: var(--primary);
  font-weight: 700;
  box-shadow: 0 2px 12px rgba(0,0,0,0.1);
}

.btn-white:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(0,0,0,0.15);
}

.btn-lg {
  padding: 16px 32px;
  font-size: 1.05rem;
  border-radius: 12px;
}

.btn-sm {
  padding: 8px 18px;
  font-size: 0.85rem;
  border-radius: 8px;
}

.btn-full {
  width: 100%;
}


/* ========== NAVBAR ========== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 16px 0;
  transition: all 0.3s ease;
}

.navbar.scrolled {
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(226,232,240,0.6);
  padding: 10px 0;
  box-shadow: 0 2px 16px rgba(0,0,0,0.04);
}

.navbar-inner {
  display: flex;
  align-items: center;
  gap: 40px;
}

.nav-links {
  display: flex;
  gap: 32px;
  margin-left: auto;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-links a:hover {
  color: var(--text);
}

.nav-links a.active {
  color: var(--primary);
  font-weight: 600;
}

.btn-nav {
  padding: 10px 22px;
  font-size: 0.9rem;
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  cursor: pointer;
  padding: 4px;
}

.mobile-menu {
  display: none;
}


/* ========== BLOG HERO ========== */
.blog-hero {
  position: relative;
  padding: 160px 0 80px;
  text-align: center;
  overflow: hidden;
  background: linear-gradient(180deg, var(--primary-light) 0%, var(--bg) 100%);
}

.blog-hero::before {
  content: '';
  position: absolute;
  top: -120px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 600px;
  background: radial-gradient(ellipse at center, rgba(99,102,241,0.1) 0%, transparent 70%);
  pointer-events: none;
}

.blog-hero-inner {
  position: relative;
  z-index: 1;
}

.blog-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--card-bg);
  color: var(--primary);
  padding: 8px 18px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 28px;
  border: 1px solid rgba(99,102,241,0.15);
  box-shadow: var(--shadow-sm);
}

.blog-hero h1 {
  font-family: 'Outfit', sans-serif;
  font-size: 3.2rem;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 18px;
  color: var(--text);
}

.blog-hero .gradient-text {
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #a855f7 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.blog-hero p {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 580px;
  margin: 0 auto;
  line-height: 1.7;
}


/* ========== CATEGORY FILTER ========== */
.category-filter {
  padding: 0 0 48px;
  background: var(--bg);
}

.category-filter-inner {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
}

.category-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 20px;
  border-radius: 50px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--card-bg);
  border: 1.5px solid var(--border);
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  white-space: nowrap;
}

.category-pill:hover {
  border-color: #cbd5e1;
  color: var(--text);
  background: #f8fafc;
}

.category-pill.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(99,102,241,0.25);
}

.category-pill.active:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
}

.category-pill-count {
  font-size: 0.75rem;
  font-weight: 700;
  background: rgba(0,0,0,0.08);
  padding: 1px 8px;
  border-radius: 50px;
  line-height: 1.6;
}

.category-pill.active .category-pill-count {
  background: rgba(255,255,255,0.25);
}


/* ========== ARTICLE CARDS GRID ========== */
.articles-section {
  padding: 0 0 100px;
  background: var(--bg);
}

.articles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.article-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all 0.3s ease;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
}

.article-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}

/* Placeholder image area - 16:9 ratio */
.article-card-image {
  position: relative;
  width: 100%;
  padding-top: 56.25%; /* 16:9 */
  background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
  overflow: hidden;
}

.article-card-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.article-card:hover .article-card-image img {
  transform: scale(1.04);
}

.article-card-image-placeholder {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
}

.article-card-image-placeholder svg {
  width: 48px;
  height: 48px;
  opacity: 0.4;
}

/* Category tag on image */
.article-card-category {
  position: absolute;
  top: 14px;
  left: 14px;
  padding: 4px 12px;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  z-index: 1;
}

.article-card-category.cat-zucht {
  background: #fef3c7;
  color: #92400e;
}

.article-card-category.cat-business {
  background: #dbeafe;
  color: #1e40af;
}

.article-card-category.cat-software {
  background: var(--primary-light);
  color: var(--primary-dark);
}

.article-card-category.cat-rechtliches {
  background: #fce7f3;
  color: #9d174d;
}

.article-card-category.cat-allgemein {
  background: #f1f5f9;
  color: var(--text-muted);
}

/* Card body */
.article-card-body {
  padding: 22px 24px 16px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.article-card-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text);
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.article-card:hover .article-card-title {
  color: var(--primary);
}

.article-card-teaser {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 16px;
  flex: 1;
  /* Clamp to ~3 lines */
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Card footer */
.article-card-footer {
  padding: 14px 24px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.82rem;
  color: var(--text-light);
}

.article-card-date {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.article-card-readtime {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.article-card-readtime svg,
.article-card-date svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

/* Empty state / no results */
.articles-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px 24px;
}

.articles-empty p {
  font-size: 1.05rem;
  color: var(--text-muted);
}


/* ==========================================================
   ARTICLE DETAIL PAGE
   ========================================================== */

/* ========== ARTICLE HEADER ========== */
.article-header {
  padding: 140px 0 48px;
  background: linear-gradient(180deg, var(--primary-light) 0%, var(--bg) 100%);
  position: relative;
}

.article-header::before {
  content: '';
  position: absolute;
  top: -120px;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 500px;
  background: radial-gradient(ellipse at center, rgba(99,102,241,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.article-header-inner {
  position: relative;
  z-index: 1;
  max-width: 1080px;
  margin: 0 auto;
}

.article-header-inner h1 {
  max-width: 720px;
}

/* Breadcrumb */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.breadcrumb a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}

.breadcrumb a:hover {
  color: var(--primary);
}

.breadcrumb-separator {
  color: var(--text-light);
  font-size: 0.75rem;
}

.breadcrumb-current {
  color: var(--text);
  font-weight: 500;
}

/* Article meta */
.article-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.article-meta-category {
  padding: 5px 14px;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 600;
}

.article-meta-category.cat-zucht {
  background: #fef3c7;
  color: #92400e;
}

.article-meta-category.cat-business {
  background: #dbeafe;
  color: #1e40af;
}

.article-meta-category.cat-software {
  background: var(--primary-light);
  color: var(--primary-dark);
}

.article-meta-category.cat-rechtliches {
  background: #fce7f3;
  color: #9d174d;
}

.article-meta-category.cat-allgemein {
  background: #f1f5f9;
  color: var(--text-muted);
}

.article-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.article-meta-item svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.article-meta-divider {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--text-light);
}

/* Article title */
.article-header h1 {
  font-family: 'Outfit', sans-serif;
  font-size: 2.8rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--text);
  margin-bottom: 0;
}


/* ========== ARTICLE LAYOUT (Content + TOC Sidebar) ========== */
.article-layout {
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 48px;
  max-width: 1080px;
  margin: 0 auto;
  padding: 48px 24px 80px;
  align-items: start;
}

/* ========== ARTICLE CONTENT ========== */
.article-content {
  max-width: 720px;
  font-size: 18px;
  line-height: 1.8;
  color: var(--text);
}

.article-content h2 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.65rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-top: 48px;
  margin-bottom: 18px;
  line-height: 1.3;
}

.article-content h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text);
  margin-top: 36px;
  margin-bottom: 14px;
  line-height: 1.35;
}

.article-content p {
  margin-bottom: 20px;
  color: var(--text);
}

.article-content p a {
  color: var(--primary);
  text-decoration: underline;
  text-decoration-color: rgba(99,102,241,0.3);
  text-underline-offset: 3px;
  transition: text-decoration-color 0.2s;
}

.article-content p a:hover {
  text-decoration-color: var(--primary);
}

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

.article-content ul,
.article-content ol {
  margin-bottom: 20px;
  padding-left: 24px;
}

.article-content ul {
  list-style: disc;
}

.article-content ol {
  list-style: decimal;
}

.article-content li {
  margin-bottom: 8px;
  padding-left: 6px;
  line-height: 1.75;
}

.article-content li::marker {
  color: var(--primary);
}

.article-content blockquote {
  margin: 28px 0;
  padding: 20px 24px;
  border-left: 4px solid var(--primary);
  background: var(--primary-light);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
  color: var(--text);
}

.article-content blockquote p {
  margin-bottom: 0;
  font-size: 1rem;
  line-height: 1.75;
}

.article-content img {
  border-radius: var(--radius);
  margin: 28px 0;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.article-content code {
  font-family: 'JetBrains Mono', 'Fira Code', monospace;
  font-size: 0.88em;
  background: #f1f5f9;
  padding: 2px 7px;
  border-radius: 5px;
  color: var(--primary-dark);
  border: 1px solid var(--border);
}

.article-content pre {
  margin: 28px 0;
  padding: 20px 24px;
  background: var(--bg-dark);
  border-radius: var(--radius-sm);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.article-content pre code {
  background: none;
  border: none;
  padding: 0;
  color: #e2e8f0;
  font-size: 0.9rem;
  line-height: 1.7;
}

.article-content hr {
  border: none;
  height: 1px;
  background: var(--border);
  margin: 40px 0;
}

/* Tables in content */
.article-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 28px 0;
  font-size: 0.95rem;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border);
}

.article-content thead {
  background: #f8fafc;
}

.article-content th {
  font-weight: 600;
  text-align: left;
  padding: 12px 16px;
  border-bottom: 2px solid var(--border);
  color: var(--text);
  font-size: 0.88rem;
}

.article-content td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
}

.article-content tbody tr:last-child td {
  border-bottom: none;
}

.article-content tbody tr:hover {
  background: #fafbfe;
}


/* ========== CTA BOX (in-article ReptiTrack CTAs) ========== */
.article-cta-box {
  margin: 36px 0;
  padding: 28px 28px 28px 24px;
  background: linear-gradient(135deg, #ecfdf5 0%, #f0fdf4 100%);
  border: 1px solid #a7f3d0;
  border-left: 5px solid var(--success);
  border-radius: 0 var(--radius) var(--radius) 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.article-cta-box-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: #065f46;
  display: flex;
  align-items: center;
  gap: 8px;
}

.article-cta-box-title svg {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  color: var(--success);
}

.article-cta-box p {
  font-size: 0.95rem;
  color: #047857;
  line-height: 1.65;
  margin-bottom: 0;
}

.article-cta-box .btn {
  align-self: flex-start;
  background: var(--success);
  color: #fff;
  box-shadow: 0 2px 8px rgba(16,185,129,0.3);
}

.article-cta-box .btn:hover {
  background: #059669;
  box-shadow: 0 4px 16px rgba(16,185,129,0.4);
  transform: translateY(-1px);
}


/* ========== TABLE OF CONTENTS ========== */
.toc {
  position: sticky;
  top: 100px;
}

.toc-inner {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.toc-title {
  font-family: 'Outfit', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.toc-list {
  list-style: none;
  padding: 0;
}

.toc-list li {
  margin-bottom: 2px;
}

.toc-list a {
  display: block;
  padding: 7px 12px;
  font-size: 0.85rem;
  color: var(--text-muted);
  text-decoration: none;
  border-radius: 8px;
  transition: all 0.2s ease;
  line-height: 1.45;
}

.toc-list a:hover {
  color: var(--text);
  background: #f8fafc;
}

.toc-list a.active {
  color: var(--primary);
  background: var(--primary-light);
  font-weight: 600;
}

/* Indent for H3 sub-items */
.toc-list .toc-h3 a {
  padding-left: 24px;
  font-size: 0.82rem;
}

/* Mobile TOC toggle */
.toc-mobile-toggle {
  display: none;
  width: 100%;
  padding: 14px 20px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 20px;
}

.toc-mobile-toggle svg {
  transition: transform 0.3s ease;
}

.toc-mobile-toggle.open svg {
  transform: rotate(180deg);
}


/* ========== SOCIAL SHARE BUTTONS ========== */
.article-share {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
}

.article-share-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 14px;
}

.share-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1.5px solid var(--border);
  border-radius: 50px;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--card-bg);
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.share-btn:hover {
  border-color: #cbd5e1;
  color: var(--text);
  background: #f8fafc;
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.share-btn svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.share-btn.whatsapp:hover {
  border-color: #25d366;
  color: #128c7e;
  background: #f0fdf4;
}

.share-btn.facebook:hover {
  border-color: #1877f2;
  color: #1877f2;
  background: #eff6ff;
}

.share-btn.copy-link:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

.share-btn.copy-link.copied {
  border-color: var(--success);
  color: var(--success);
  background: #ecfdf5;
}


/* ========== WEITERE ARTIKEL (Related Articles) ========== */
.related-articles {
  padding: 80px 0 100px;
  background: #fff;
}

.related-articles-header {
  text-align: center;
  margin-bottom: 40px;
}

.related-articles-header h2 {
  font-family: 'Outfit', sans-serif;
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 10px;
}

.related-articles-header p {
  font-size: 1rem;
  color: var(--text-muted);
}

.related-articles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}


/* ========== FOOTER ========== */
.footer {
  background: var(--bg-dark);
  padding: 64px 0 0;
  color: #94a3b8;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(148,163,184,0.15);
}

.footer-brand {
  max-width: 280px;
}

.footer .brand-logo {
  color: #f1f5f9;
  margin-bottom: 12px;
  display: inline-block;
}

.footer-brand p {
  font-size: 0.9rem;
  line-height: 1.6;
  margin-top: 12px;
}

.footer-links {
  display: flex;
  gap: 64px;
}

.footer-col h4 {
  color: #f1f5f9;
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.footer-col a {
  display: block;
  color: #94a3b8;
  text-decoration: none;
  font-size: 0.9rem;
  padding: 4px 0;
  transition: color 0.2s;
}

.footer-col a:hover {
  color: #f1f5f9;
}

.footer-bottom {
  padding: 24px 0;
  text-align: center;
}

.footer-bottom p {
  font-size: 0.82rem;
  color: #64748b;
}


/* ========== ANIMATIONS ========== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.blog-hero-inner {
  animation: fadeInUp 0.8s ease-out;
}

.article-header-inner {
  animation: fadeInUp 0.8s ease-out;
}

.article-card {
  animation: fadeInUp 0.6s ease-out both;
}

.article-card:nth-child(2) {
  animation-delay: 0.08s;
}

.article-card:nth-child(3) {
  animation-delay: 0.16s;
}

.article-card:nth-child(4) {
  animation-delay: 0.2s;
}

.article-card:nth-child(5) {
  animation-delay: 0.24s;
}

.article-card:nth-child(6) {
  animation-delay: 0.28s;
}


/* ==========================================================
   RESPONSIVE BREAKPOINTS
   ========================================================== */

/* ========== 1080px - TOC collapses, layout adjusts ========== */
@media (max-width: 1080px) {
  .article-layout {
    grid-template-columns: 1fr;
    max-width: 720px;
    gap: 0;
  }

  /* Sidebar TOC becomes collapsible above content */
  .toc {
    position: relative;
    top: auto;
    order: -1;
    margin-bottom: 32px;
  }

  .toc-inner {
    max-height: 0;
    overflow: hidden;
    padding: 0 24px;
    border: none;
    transition: max-height 0.35s ease, padding 0.35s ease, border 0.35s ease;
  }

  .toc-inner.open {
    max-height: 600px;
    padding: 24px;
    border: 1px solid var(--border);
  }

  .toc-mobile-toggle {
    display: flex;
  }

  .toc-title {
    display: none;
  }

  .related-articles-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
}


/* ========== 768px - Tablet ========== */
@media (max-width: 768px) {
  /* Navbar mobile */
  .nav-links,
  .btn-nav {
    display: none;
  }

  .mobile-menu-btn {
    display: flex;
    margin-left: auto;
  }

  .mobile-menu {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 0 24px 16px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
  }

  .mobile-menu.open {
    max-height: 300px;
    padding: 16px 24px;
  }

  .mobile-menu a {
    text-decoration: none;
    color: var(--text);
    font-weight: 500;
    padding: 10px 0;
    font-size: 1rem;
  }

  /* Blog hero */
  .blog-hero {
    padding: 120px 0 56px;
  }

  .blog-hero h1 {
    font-size: 2.4rem;
  }

  .blog-hero p {
    font-size: 1.05rem;
    padding: 0 8px;
  }

  /* Category filter */
  .category-filter-inner {
    justify-content: flex-start;
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 4px;
    gap: 8px;
  }

  .category-filter-inner::-webkit-scrollbar {
    display: none;
  }

  .category-pill {
    flex-shrink: 0;
  }

  /* Article grid - 2 cols */
  .articles-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  /* Article detail */
  .article-header {
    padding: 120px 0 36px;
  }

  .article-header h1 {
    font-size: 2.1rem;
  }

  .article-layout {
    padding: 36px 24px 64px;
  }

  .article-content {
    font-size: 17px;
  }

  .article-content h2 {
    font-size: 1.45rem;
    margin-top: 40px;
  }

  .article-content h3 {
    font-size: 1.15rem;
    margin-top: 28px;
  }

  /* Related articles - 2 cols stays */

  /* Footer */
  .footer-inner {
    flex-direction: column;
    gap: 32px;
  }

  .footer-links {
    gap: 40px;
  }
}


/* ========== 480px - Mobile ========== */
@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }

  /* Blog hero */
  .blog-hero {
    padding: 110px 0 40px;
  }

  .blog-hero h1 {
    font-size: 1.9rem;
  }

  .blog-hero p {
    font-size: 0.98rem;
  }

  /* Articles - 1 col */
  .articles-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .articles-section {
    padding: 0 0 64px;
  }

  /* Article detail */
  .article-header h1 {
    font-size: 1.75rem;
  }

  .article-meta {
    gap: 10px;
  }

  .article-meta-divider {
    display: none;
  }

  .article-content {
    font-size: 16px;
  }

  .article-content h2 {
    font-size: 1.3rem;
    margin-top: 32px;
  }

  .article-content h3 {
    font-size: 1.1rem;
  }

  .article-content blockquote {
    padding: 16px 18px 16px 16px;
    margin: 20px 0;
  }

  .article-cta-box {
    padding: 22px 20px 22px 18px;
    margin: 28px 0;
  }

  .article-layout {
    padding: 28px 16px 48px;
  }

  /* Share buttons stack */
  .share-buttons {
    flex-direction: column;
  }

  .share-btn {
    justify-content: center;
  }

  /* Related articles - 1 col */
  .related-articles-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .related-articles {
    padding: 56px 0 64px;
  }

  .related-articles-header h2 {
    font-size: 1.6rem;
  }

  /* Footer */
  .footer-links {
    flex-direction: column;
    gap: 28px;
  }

  .footer {
    padding: 48px 0 0;
  }
}


/* ==========================================================
   ADDITIONAL STYLES - Blog Overview Page (index.html)
   ========================================================== */

/* Blog grid section */
.blog-grid-section {
  padding: 0 0 100px;
  background: var(--bg);
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

/* Filter buttons (overview page) */
.filter-buttons {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
}

.filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 20px;
  border-radius: 50px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--card-bg);
  border: 1.5px solid var(--border);
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
  white-space: nowrap;
}

.filter-btn:hover {
  border-color: #cbd5e1;
  color: var(--text);
  background: #f8fafc;
}

.filter-btn.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(99,102,241,0.25);
}

.filter-btn.active:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
}

/* Article card - image placeholder area */
.article-image {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.article-image svg {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: var(--text-light);
  opacity: 0.4;
}

/* Article card - body */
.article-body {
  padding: 22px 24px 16px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.article-body h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text);
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.article-card:hover .article-body h3 {
  color: var(--primary);
}

.article-body p {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 16px;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Article card category tag */
.article-category {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  margin-bottom: 10px;
  background: var(--primary-light);
  color: var(--primary-dark);
}

/* Article card footer */
.article-footer {
  padding-top: 14px;
  margin-top: auto;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--text-light);
}

.article-date {
  color: var(--text-light);
}

.article-divider {
  color: var(--text-light);
}

.article-read-time {
  color: var(--text-light);
}

/* Blog hero additional elements */
.blog-hero-bg-glow {
  position: absolute;
  top: -120px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 600px;
  background: radial-gradient(ellipse at center, rgba(99,102,241,0.1) 0%, transparent 70%);
  pointer-events: none;
}

.blog-hero-sub {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 580px;
  margin: 0 auto;
  line-height: 1.7;
}


/* ==========================================================
   ADDITIONAL STYLES - Article Detail Pages
   ========================================================== */

/* Main container */
.blog-main {
  min-height: 100vh;
}

.blog-container {
  max-width: 1080px;
  margin: 0 auto;
}

/* Article header (detail page specific) */
.article-header {
  padding: 140px 0 48px;
  background: linear-gradient(180deg, var(--primary-light) 0%, var(--bg) 100%);
  position: relative;
}

/* Breadcrumb separator */
.breadcrumb-sep {
  color: var(--text-light);
  font-size: 0.85rem;
}

/* Category tag in article header */
.category-tag {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 600;
  background: var(--primary-light);
  color: var(--primary-dark);
  margin-bottom: 16px;
}

/* Article meta */
.article-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-top: 16px;
}

.meta-sep {
  color: var(--text-light);
}

/* Article layout wrapper - content first, TOC sidebar right */
.article-layout {
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 48px;
  max-width: 1080px;
  margin: 0 auto;
  padding: 48px 24px 80px;
  align-items: start;
}

/* TOC sidebar */
.toc-sidebar {
  position: sticky;
  top: 100px;
}

.toc-sidebar .toc-inner {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.toc-toggle {
  display: none;
  width: 100%;
  padding: 14px 20px;
  background: none;
  border: none;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text);
  cursor: pointer;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.toc-chevron {
  transition: transform 0.3s ease;
}

.toc-sidebar.open .toc-chevron {
  transform: rotate(180deg);
}

.toc-nav {
  margin: 0;
}

.toc-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.toc-nav li {
  margin-bottom: 2px;
}

.toc-nav a,
.toc-link {
  display: block;
  padding: 7px 12px;
  font-size: 0.85rem;
  color: var(--text-muted);
  text-decoration: none;
  border-radius: 8px;
  transition: all 0.2s ease;
  line-height: 1.45;
}

.toc-nav a:hover,
.toc-link:hover {
  color: var(--text);
  background: #f8fafc;
}

.toc-nav a.active,
.toc-link.active {
  color: var(--primary);
  background: var(--primary-light);
  font-weight: 600;
}

/* TOC title (desktop) */
.toc-sidebar .toc-inner::before {
  content: 'Inhaltsverzeichnis';
  display: block;
  font-family: 'Outfit', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Article CTA (in-article CTA box) */
.article-cta {
  margin: 36px 0;
  padding: 28px 28px 28px 24px;
  background: linear-gradient(135deg, #ecfdf5 0%, #f0fdf4 100%);
  border: 1px solid #a7f3d0;
  border-left: 5px solid var(--success);
  border-radius: 0 var(--radius) var(--radius) 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.article-cta p {
  font-size: 0.95rem;
  color: #047857;
  line-height: 1.65;
  margin-bottom: 0;
}

.article-cta .btn {
  align-self: flex-start;
  background: var(--success);
  color: #fff;
  box-shadow: 0 2px 8px rgba(16,185,129,0.3);
}

.article-cta .btn:hover {
  background: #059669;
  box-shadow: 0 4px 16px rgba(16,185,129,0.4);
  transform: translateY(-1px);
}

/* Share buttons (article pages) */
.share-label {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
  margin-right: 4px;
}

.share-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1.5px solid var(--border);
  border-radius: 50px;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--card-bg);
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.share-btn:hover {
  border-color: #cbd5e1;
  color: var(--text);
  background: #f8fafc;
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.share-btn svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.share-whatsapp:hover {
  border-color: #25d366;
  color: #128c7e;
  background: #f0fdf4;
}

.share-facebook:hover {
  border-color: #1877f2;
  color: #1877f2;
  background: #eff6ff;
}

.share-copy:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

/* Related articles (article pages) */
.related-articles {
  padding: 80px 0 100px;
  background: #fff;
}

.related-articles h2 {
  font-family: 'Outfit', sans-serif;
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 32px;
  text-align: center;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.related-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  text-decoration: none;
  color: inherit;
  transition: all 0.3s ease;
}

.related-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}

.related-tag {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  background: var(--primary-light);
  color: var(--primary-dark);
  margin-bottom: 12px;
}

.related-card h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.4;
  color: var(--text);
}

.related-card:hover h3 {
  color: var(--primary);
}


/* ==========================================================
   RESPONSIVE - Additional styles
   ========================================================== */

@media (max-width: 1080px) {
  .article-layout {
    grid-template-columns: 1fr;
    max-width: 720px;
    gap: 0;
  }

  .toc-sidebar {
    position: relative;
    top: auto;
    order: -1;
    margin-bottom: 24px;
  }

  .toc-sidebar .toc-inner {
    padding: 0;
    border: 1px solid var(--border);
  }

  .toc-sidebar .toc-inner::before {
    display: none;
  }

  .toc-toggle {
    display: flex;
  }

  .toc-nav {
    max-height: 0;
    overflow: hidden;
    padding: 0 20px;
    transition: max-height 0.35s ease, padding 0.35s ease;
  }

  .toc-sidebar.open .toc-nav {
    max-height: 600px;
    padding: 0 20px 20px;
  }

  .related-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
}

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

  .filter-buttons {
    justify-content: flex-start;
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 4px;
    gap: 8px;
  }

  .filter-buttons::-webkit-scrollbar {
    display: none;
  }

  .filter-btn {
    flex-shrink: 0;
  }

  .article-header {
    padding: 120px 0 36px;
  }

  .article-header h1 {
    font-size: 2.1rem;
  }

  .share-buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .share-btn {
    justify-content: center;
  }

  .share-label {
    width: 100%;
  }
}

@media (max-width: 480px) {
  .blog-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .blog-grid-section {
    padding: 0 0 64px;
  }

  .article-header h1 {
    font-size: 1.75rem;
  }

  .related-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .article-cta {
    padding: 22px 20px 22px 18px;
    margin: 28px 0;
  }
}
