/* ============================================================
   blog.css — Styles fuer /blog (Uebersicht) + /blog/{slug} (Detail)
   Dark theme, Brand-Gradient #7C3AED → #A855F7 → #EC4899.
   ============================================================ */

:root {
  --bd-grad-1: #7C3AED;
  --bd-grad-2: #A855F7;
  --bd-grad-3: #EC4899;
  --bd-gradient: linear-gradient(135deg, #7C3AED 0%, #A855F7 50%, #EC4899 100%);
  --bd-bg: #0a0a0f;
  --bd-card: rgba(255,255,255,0.04);
  --bd-card-hover: rgba(255,255,255,0.06);
  --bd-border: rgba(168,85,247,0.18);
  --bd-border-strong: rgba(168,85,247,0.40);
  --bd-text: #fff;
  --bd-text-muted: rgba(255,255,255,0.72);
  --bd-text-dim: rgba(255,255,255,0.50);
  --bd-text-faint: rgba(255,255,255,0.35);
}

/* ============ /blog Uebersicht — Card Polish ============ */

.post-card {
  display: block;
  padding: 0;
  overflow: hidden;
  background: var(--bd-card);
  border: 1px solid var(--bd-border);
  border-radius: 16px;
  text-decoration: none;
  color: inherit;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.post-card:hover {
  transform: translateY(-3px);
  border-color: var(--bd-border-strong);
  box-shadow: 0 18px 40px -16px rgba(168,85,247,0.45);
}
.post-card-img {
  aspect-ratio: 1200 / 630;
  background: #0d081a;
  overflow: hidden;
  border-bottom: 1px solid var(--bd-border);
}
.post-card-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.post-card-body { padding: 22px 26px 26px; }
.post-meta {
  display: flex; gap: 8px; align-items: center;
  margin-bottom: 12px;
  color: var(--bd-text-faint);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  flex-wrap: wrap;
}
.post-card h2 {
  font-size: 1.35rem;
  margin: 0 0 10px;
  line-height: 1.3;
  letter-spacing: -0.01em;
}
.post-card p {
  color: var(--bd-text-muted);
  margin: 0 0 14px;
  font-size: 0.95rem;
  line-height: 1.55;
}
.post-link {
  color: var(--bd-grad-2);
  font-size: 13.5px;
  font-weight: 600;
}
.post-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--bd-text-faint);
  font-style: italic;
}

/* ============ /blog/{slug} Detail-Page ============ */

body.blog-detail {
  background: var(--bd-bg);
  color: var(--bd-text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.65;
}
body.blog-detail .container {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Breadcrumb */
.bd-breadcrumb {
  margin: 24px 0 0;
  font-size: 12.5px;
  color: var(--bd-text-faint);
}
.bd-breadcrumb a { color: var(--bd-text-dim); text-decoration: none; }
.bd-breadcrumb a:hover { color: var(--bd-text); }
.bd-breadcrumb-current { color: var(--bd-text-muted); }

/* Header */
.bd-header { margin: 28px 0 32px; }
.bd-tags {
  display: flex; gap: 8px; flex-wrap: wrap;
  margin-bottom: 16px;
}
.bd-tag {
  padding: 4px 11px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--bd-border);
  border-radius: 99px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--bd-text-muted);
}
.bd-tag-primary {
  background: rgba(168,85,247,0.10);
  border-color: var(--bd-border-strong);
  color: #c4b5fd;
}
.bd-title {
  font-size: clamp(2rem, 4.5vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0 0 16px;
  color: var(--bd-text);
}
.bd-subtitle {
  font-size: 1.15rem;
  color: var(--bd-text-muted);
  line-height: 1.55;
  margin: 0 0 24px;
}
.bd-author-bar {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 0;
  border-top: 1px solid var(--bd-border);
  border-bottom: 1px solid var(--bd-border);
}
.bd-author-avatar {
  width: 44px; height: 44px;
  border-radius: 50%;
  display: grid; place-items: center;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -0.02em;
  flex-shrink: 0;
  overflow: hidden;
  position: relative;
  /* Brand-Gradient als Border via background-clip */
  padding: 2px;
  background:
    linear-gradient(#0a0a0f, #0a0a0f) padding-box,
    var(--bd-gradient) border-box;
  border: 2px solid transparent;
  box-shadow: 0 2px 12px -2px rgba(217,70,239,0.5);
}
.bd-author-avatar img {
  width: 100%; height: 100%;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}
.bd-author-avatar.bd-author-avatar-fallback {
  background: var(--bd-gradient);
  padding: 0;
  border: 0;
}
.bd-author-info { display: flex; flex-direction: column; gap: 2px; }
.bd-author-name {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--bd-text);
}
.bd-author-name a { color: var(--bd-grad-2); text-decoration: none; }
.bd-author-name a:hover { text-decoration: underline; }
.bd-author-meta {
  font-size: 12px;
  color: var(--bd-text-faint);
}

/* Hero Image */
.bd-hero {
  margin: 0 -8px 32px;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--bd-border);
}
.bd-hero img {
  width: 100%;
  height: auto;
  display: block;
}

/* Key Takeaways */
.bd-takeaways {
  margin: 0 0 36px;
  padding: 22px 24px;
  background: linear-gradient(135deg, rgba(124,58,237,0.10), rgba(236,72,153,0.06));
  border: 1px solid var(--bd-border);
  border-left: 3px solid var(--bd-grad-2);
  border-radius: 14px;
}
.bd-takeaways h2 {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: #c4b5fd;
  margin: 0 0 12px;
  font-weight: 700;
}
.bd-takeaways ul {
  margin: 0;
  padding-left: 18px;
  list-style: none;
}
.bd-takeaways li {
  position: relative;
  padding: 6px 0 6px 18px;
  color: var(--bd-text);
  font-size: 14.5px;
  line-height: 1.55;
}
.bd-takeaways li::before {
  content: "";
  position: absolute;
  left: 0; top: 14px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--bd-gradient);
  box-shadow: 0 0 8px rgba(217,70,239,0.55);
}
.bd-takeaways code {
  background: rgba(168,85,247,0.12);
  padding: 1px 5px;
  border-radius: 4px;
  font-size: 13px;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
}

/* Inhaltsverzeichnis */
.bd-toc {
  margin: 0 0 36px;
  padding: 18px 22px;
  background: var(--bd-card);
  border: 1px solid var(--bd-border);
  border-radius: 12px;
}
.bd-toc h3 {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--bd-text-faint);
  margin: 0 0 10px;
  font-weight: 700;
}
.bd-toc ol {
  margin: 0;
  padding-left: 22px;
  color: var(--bd-text-muted);
}
.bd-toc li { margin: 6px 0; font-size: 14px; }
.bd-toc a {
  color: var(--bd-text-muted);
  text-decoration: none;
  transition: color .15s;
}
.bd-toc a:hover { color: var(--bd-grad-2); }
.bd-toc a.is-active {
  color: var(--bd-grad-2);
  font-weight: 600;
}

/* Article-Content */
.bd-article { padding: 0 0 40px; }
.bd-section {
  padding: 24px 0 12px;
  scroll-margin-top: 80px;
}
.bd-section h2 {
  font-size: 1.55rem;
  font-weight: 700;
  margin: 0 0 16px;
  letter-spacing: -0.015em;
  color: var(--bd-text);
}
.bd-section h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 28px 0 10px;
  color: #c4b5fd;
}
.bd-section p {
  color: var(--bd-text-muted);
  margin: 14px 0;
  font-size: 1.02rem;
  line-height: 1.72;
}
.bd-section p strong { color: var(--bd-text); font-weight: 600; }
.bd-section ul, .bd-section ol {
  color: var(--bd-text-muted);
  padding-left: 24px;
  margin: 14px 0;
}
.bd-section li {
  margin: 8px 0;
  font-size: 1rem;
  line-height: 1.65;
}
.bd-section li strong { color: var(--bd-text); }
.bd-section a {
  color: var(--bd-grad-2);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.bd-section a:hover { color: var(--bd-grad-3); }
.bd-section em { color: var(--bd-text); font-style: italic; }
.bd-section code {
  background: rgba(168,85,247,0.12);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 13.5px;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  color: #e9d5ff;
  border: 1px solid rgba(168,85,247,0.18);
}

/* Code-Blöcke */
.bd-section pre {
  margin: 18px 0;
  padding: 16px 20px;
  background: #0b0617;
  border: 1px solid rgba(192,132,252,0.18);
  border-radius: 12px;
  overflow-x: auto;
  position: relative;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 12.5px;
  line-height: 1.65;
  color: #d8d2e2;
}
.bd-section pre code {
  background: transparent;
  padding: 0;
  border: none;
  font-size: inherit;
  color: inherit;
}
.bd-copy-btn {
  position: absolute;
  top: 10px; right: 10px;
  padding: 4px 9px;
  background: rgba(168,85,247,0.10);
  border: 1px solid rgba(168,85,247,0.30);
  border-radius: 5px;
  color: #c4b5fd;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all .15s;
}
.bd-copy-btn:hover {
  background: rgba(168,85,247,0.20);
  border-color: rgba(168,85,247,0.50);
  color: #fff;
}

/* Vergleichstabelle */
.compare-table-wrap {
  margin: 18px 0;
  overflow-x: auto;
  border-radius: 12px;
  border: 1px solid var(--bd-border);
}
.compare-table {
  width: 100%;
  min-width: 540px;
  border-collapse: collapse;
  font-size: 13.5px;
}
.compare-table thead { background: rgba(168,85,247,0.08); }
.compare-table th {
  padding: 12px 16px;
  text-align: left;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #c4b5fd;
  border-bottom: 1px solid var(--bd-border-strong);
}
.compare-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--bd-border);
  color: var(--bd-text-muted);
  vertical-align: top;
}
.compare-table tr:last-child td { border-bottom: 0; }
.compare-table strong { color: var(--bd-text); }

/* CTA-Box */
.bd-cta-box {
  margin: 40px 0;
  padding: 32px 28px;
  background: linear-gradient(135deg, rgba(124,58,237,0.14), rgba(236,72,153,0.10));
  border: 1px solid var(--bd-border-strong);
  border-radius: 16px;
  text-align: center;
}
.bd-cta-box p {
  color: var(--bd-text);
  font-size: 1.05rem;
  margin: 0 0 18px;
  line-height: 1.55;
}
.bd-cta-btn {
  display: inline-block;
  padding: 14px 28px;
  background: var(--bd-gradient);
  color: #fff;
  text-decoration: none;
  border-radius: 12px;
  font-weight: 600;
  font-size: 14.5px;
  box-shadow: 0 8px 24px rgba(168,85,247,0.40);
  transition: transform .15s, box-shadow .2s;
}
.bd-cta-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 30px rgba(236,72,153,0.55);
}

/* FAQs */
.bd-faqs {
  margin: 40px 0;
  padding: 0;
}
.bd-faqs h2 {
  font-size: 1.55rem;
  font-weight: 700;
  margin: 0 0 20px;
  letter-spacing: -0.015em;
}
.bd-faq-item {
  margin: 8px 0;
  padding: 0;
  background: var(--bd-card);
  border: 1px solid var(--bd-border);
  border-radius: 10px;
  overflow: hidden;
}
.bd-faq-item summary {
  padding: 14px 18px;
  cursor: pointer;
  font-weight: 600;
  font-size: 15px;
  color: var(--bd-text);
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.bd-faq-item summary::-webkit-details-marker { display: none; }
.bd-faq-item summary::after {
  content: "+";
  color: var(--bd-grad-2);
  font-size: 18px;
  font-weight: 700;
  transition: transform .15s;
  margin-left: 12px;
}
.bd-faq-item[open] summary::after { transform: rotate(45deg); }
.bd-faq-item[open] summary { border-bottom: 1px solid var(--bd-border); }
.bd-faq-item p {
  padding: 14px 18px;
  margin: 0;
  color: var(--bd-text-muted);
  line-height: 1.65;
  font-size: 14.5px;
}

/* Related Posts */
.bd-related {
  margin: 48px 0;
  padding-top: 32px;
  border-top: 1px solid var(--bd-border);
}
.bd-related h2 {
  font-size: 1.4rem;
  margin: 0 0 20px;
}
.bd-related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}
.bd-related-card {
  display: flex;
  flex-direction: column;
  background: var(--bd-card);
  border: 1px solid var(--bd-border);
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  overflow: hidden;
  transition: transform .15s, border-color .15s;
}
.bd-related-card:hover {
  transform: translateY(-2px);
  border-color: var(--bd-border-strong);
}
.bd-related-card img {
  width: 100%;
  aspect-ratio: 1200/630;
  object-fit: cover;
  display: block;
}
.bd-related-meta { padding: 14px 16px; }
.bd-related-cat {
  display: inline-block;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #c4b5fd;
  margin-bottom: 6px;
  font-weight: 600;
}
.bd-related-card h3 {
  font-size: 1rem;
  margin: 0 0 8px;
  color: var(--bd-text);
  line-height: 1.4;
}
.bd-related-time {
  font-size: 12px;
  color: var(--bd-text-faint);
}

/* Glossar-Chips */
.bd-glossar {
  margin: 36px 0;
}
.bd-glossar h3 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--bd-text-faint);
  font-weight: 700;
  margin: 0 0 14px;
}
.bd-glossar-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.bd-glossar-chip {
  padding: 6px 12px;
  background: var(--bd-card);
  border: 1px solid var(--bd-border);
  border-radius: 99px;
  font-size: 13px;
  color: var(--bd-text-muted);
  text-decoration: none;
  text-transform: capitalize;
  transition: all .15s;
}
.bd-glossar-chip:hover {
  background: rgba(168,85,247,0.10);
  border-color: var(--bd-border-strong);
  color: #fff;
}

/* Author Bio (Footer-Bereich) */
.bd-author-bio {
  display: flex;
  gap: 22px;
  align-items: flex-start;
  margin: 48px 0 60px;
  padding: 26px 28px;
  background: var(--bd-card);
  border: 1px solid var(--bd-border);
  border-radius: 16px;
}
.bd-author-photo {
  flex-shrink: 0;
  width: 92px; height: 92px;
  border-radius: 50%;
  display: grid; place-items: center;
  color: #fff;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  overflow: hidden;
  position: relative;
  /* Brand-Gradient als 2.5px Border via background-clip */
  padding: 2.5px;
  background:
    linear-gradient(#0a0a0f, #0a0a0f) padding-box,
    var(--bd-gradient) border-box;
  border: 2.5px solid transparent;
  box-shadow: 0 6px 22px -4px rgba(217,70,239,0.55);
}
.bd-author-photo img {
  width: 100%; height: 100%;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}
.bd-author-photo.bd-author-photo-fallback {
  background: var(--bd-gradient);
  padding: 0;
  border: 0;
}
.bd-author-bio-text h3 {
  font-size: 0.85rem;
  margin: 0 0 8px;
  color: var(--bd-text-faint);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.bd-author-bio-text p {
  color: var(--bd-text-muted);
  margin: 0 0 12px;
  font-size: 14.5px;
  line-height: 1.65;
}
.bd-author-cta-line {
  color: var(--bd-text) !important;
  font-style: italic;
  font-size: 14px !important;
  border-left: 2px solid var(--bd-grad-2);
  padding-left: 12px;
  margin-bottom: 16px !important;
}
/* Auffälliger LinkedIn-Button: Brand-Gradient + Hover-Lift */
.bd-author-linkedin {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 18px;
  background: var(--bd-gradient);
  color: #fff;
  text-decoration: none;
  border-radius: 99px;
  font-size: 13.5px;
  font-weight: 600;
  letter-spacing: 0.01em;
  box-shadow: 0 6px 18px -4px rgba(217,70,239,0.5);
  transition: transform .15s, box-shadow .2s;
}
.bd-author-linkedin:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 26px -4px rgba(217,70,239,0.7);
  color: #fff;
}
.bd-author-linkedin svg { flex-shrink: 0; }

/* Reading-Progress-Bar */
.bd-progress-bar {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  background: var(--bd-gradient);
  z-index: 999;
  transition: width .12s ease-out;
  box-shadow: 0 0 8px rgba(217,70,239,0.6);
  pointer-events: none;
}

/* Mobile */
@media (max-width: 720px) {
  body.blog-detail .container { padding: 0 16px; }
  .bd-title { font-size: 1.85rem; }
  .bd-subtitle { font-size: 1rem; }
  .bd-takeaways { padding: 18px; }
  .bd-toc { padding: 14px 16px; }
  .bd-section h2 { font-size: 1.3rem; }
  .bd-section { padding: 20px 0 8px; }
  .bd-cta-box { padding: 24px 18px; }
  .bd-author-bio { flex-direction: column; }
  .bd-related-grid { grid-template-columns: 1fr; }
}
