/* ══════════════════════════════════════════════
   ARTICLE DETAIL — Premium Editorial Design
   ══════════════════════════════════════════════ */

/* ── Hero ── */
.ad-hero {
  position: relative;
  background: linear-gradient(135deg, #0f0c29 0%, #302b63 55%, #1a1a3e 100%);
  padding: 80px 0 24px;
  overflow: hidden;
}
.ad-hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.ad-hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.12;
}
.orb-1 {
  width: 400px;
  height: 400px;
  background: #6366f1;
  top: -200px;
  right: -150px;
}
.orb-2 {
  width: 250px;
  height: 250px;
  background: #8b5cf6;
  bottom: 0;
  left: -100px;
}

.ad-hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
}

/* Breadcrumb */
.ad-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 14px;
}
.ad-breadcrumb a {
  color: rgba(255, 255, 255, 0.55);
  text-decoration: none;
  transition: color 0.2s;
  display: flex;
  align-items: center;
  gap: 4px;
}
.ad-breadcrumb a:hover {
  color: #a5b4fc;
}
.bc-sep {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.25);
}

/* Category chip */
.ad-category-chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 100px;
  background: rgba(129, 140, 248, 0.2);
  border: 1px solid rgba(165, 180, 252, 0.35);
  color: #c4b5fd;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 10px;
}

/* Title */
.ad-title {
  font-family: "Playfair Display", serif;
  font-size: clamp(20px, 3vw, 34px);
  color: white;
  line-height: 1.25;
  margin-bottom: 16px;
  font-weight: 700;
}

/* Meta Bar */
.ad-meta-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
}
.ad-meta-item {
  display: flex;
  align-items: center;
  gap: 10px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 14px;
}
.ad-meta-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 14px;
}
.ad-meta-text {
  display: flex;
  flex-direction: column;
}
.ad-meta-text strong {
  color: white;
  font-weight: 600;
  font-size: 13px;
}
.ad-meta-text span {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.55);
}
.ad-meta-sep {
  width: 1px;
  height: 24px;
  background: rgba(255, 255, 255, 0.15);
}
.ad-meta-item sl-icon {
  color: rgba(165, 180, 252, 0.8);
  font-size: 16px;
}
.ad-ref-chip {
  font-family: "Outfit", monospace;
  font-size: 13px;
  font-weight: 700;
  background: rgba(99, 102, 241, 0.3);
  color: #c4b5fd;
  padding: 4px 12px;
  border-radius: 6px;
  border: 1px solid rgba(165, 180, 252, 0.3);
}

.ad-hero-image-wrap {
  width: 100%;
  border-radius: 12px 12px 0 0;
  overflow: hidden;
  max-height: 280px;
  margin-top: 12px;
}
.ad-hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
/* Hide placeholder entirely — no space wasted when no image */
.ad-hero-placeholder {
  display: none;
}

/* ── Body Section ── */
.ad-body-section {
  padding: 28px 0 48px;
  background: #f8fafc;
}

.ad-layout {
  display: flex;
  gap: 28px;
  align-items: flex-start;
}
.ad-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.ad-sidebar {
  width: 250px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: sticky;
  top: 80px;
}

/* ── Abstract Card ── */
.ad-abstract-card {
  background: white;
  border-radius: 12px;
  padding: 20px 24px;
  border: 1px solid #e0e7ff;
  border-left: 4px solid #6366f1;
  box-shadow: var(--shadow-sm);
}
.ad-abstract-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}
.ad-abstract-header sl-icon {
  font-size: 18px;
  color: #6366f1;
}
.ad-abstract-header h2 {
  font-size: 15px;
  font-weight: 700;
  color: #1e1b4b;
  margin: 0;
  font-family: "Playfair Display", serif;
}
.ad-abstract-text {
  font-size: 15px;
  color: #374151;
  line-height: 1.7;
  margin: 0;
  font-style: italic;
}

/* ── In-article Ad ── */
.ad-inline-wrap {
  border-radius: 12px;
  overflow: hidden;
  background: white;
  border: 1px solid var(--gray-200);
}
.ad-inline-banner {
  display: block;
}
.ad-inline-banner img {
  width: 100%;
  display: block;
}
.ad-label-tag {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: #9ca3af;
  padding: 4px 10px;
}

/* ── Article Content Body ── */
.ad-content-body {
  background: white;
  border-radius: 12px;
  padding: 28px 32px;
  border: 1px solid var(--gray-200);
  box-shadow: var(--shadow-sm);
  font-size: 16px;
  color: #374151;
  line-height: 1.85;
}
.ad-content-body h2,
.ad-content-body h3 {
  font-family: "Playfair Display", serif;
  color: #1e1b4b;
  margin-top: 32px;
  margin-bottom: 12px;
}
.ad-content-body p {
  margin-bottom: 20px;
}
.ad-content-body blockquote {
  border-left: 3px solid #6366f1;
  padding: 12px 24px;
  margin: 24px 0;
  background: #f5f3ff;
  border-radius: 0 8px 8px 0;
  color: #4f46e5;
  font-style: italic;
}

/* ── PDF Download CTA ── */
.ad-download-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  background: linear-gradient(135deg, #1e1b4b, #312e81);
  border-radius: 16px;
  padding: 28px 32px;
  box-shadow: 0 8px 32px rgba(30, 27, 75, 0.25);
}
.download-cta-text {
  display: flex;
  align-items: center;
  gap: 16px;
  color: white;
}
.download-cta-text sl-icon {
  font-size: 36px;
  color: #a5b4fc;
  flex-shrink: 0;
}
.download-cta-text strong {
  display: block;
  font-size: 17px;
  margin-bottom: 4px;
}
.download-cta-text span {
  font-size: 13px;
  color: rgba(165, 180, 252, 0.8);
}
.download-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  padding: 14px 28px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 15px;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: white;
  text-decoration: none;
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.5);
  transition:
    transform 0.2s,
    box-shadow 0.2s;
}
.download-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.65);
  color: white;
}

/* ── Certificate Block ── */
.ad-cert-block {
  background: linear-gradient(135deg, #f0fdf4, #dcfce7);
  border: 1.5px solid #86efac;
  border-radius: 16px;
  overflow: hidden;
}
.ad-cert-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 28px 32px;
  flex-wrap: wrap;
}
.ad-cert-icon {
  font-size: 44px;
  color: #16a34a;
  flex-shrink: 0;
}
.ad-cert-info {
  flex: 1;
  min-width: 0;
}
.ad-cert-info h3 {
  font-size: 18px;
  font-weight: 700;
  color: #14532d;
  margin-bottom: 6px;
}
.ad-cert-info p {
  font-size: 14px;
  color: #15803d;
  margin-bottom: 12px;
  line-height: 1.5;
}
.ad-cert-ref {
  display: flex;
  align-items: center;
  gap: 10px;
}
.cert-ref-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #16a34a;
  font-weight: 700;
}
.cert-ref-val {
  font-family: "Outfit", monospace;
  font-size: 14px;
  font-weight: 800;
  color: #14532d;
  background: rgba(22, 163, 74, 0.1);
  padding: 4px 12px;
  border-radius: 6px;
  border: 1px solid rgba(22, 163, 74, 0.3);
}
.ad-cert-verify-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  padding: 12px 24px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 14px;
  background: white;
  color: #15803d;
  border: 1.5px solid #86efac;
  text-decoration: none;
  box-shadow: 0 2px 8px rgba(22, 163, 74, 0.15);
  transition: all 0.2s ease;
}
.ad-cert-verify-btn:hover {
  background: #15803d;
  color: white;
  border-color: #15803d;
}

/* ── Sidebar Cards ── */
.ad-sidebar-card {
  background: white;
  border-radius: 12px;
  padding: 18px;
  border: 1px solid var(--gray-200);
  box-shadow: var(--shadow-sm);
}
.sidebar-card-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 700;
  color: #1e1b4b;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--gray-100);
}
.sidebar-card-title sl-icon {
  color: #6366f1;
}

/* Author Card */
.author-sidebar-card {
  text-align: center;
}
.author-avatar-lg {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 36px;
  margin: 0 auto 16px;
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.35);
}
.author-sidebar-card h4 {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: #9ca3af;
  font-weight: 700;
  margin-bottom: 8px;
}
.author-sidebar-name {
  font-size: 18px;
  font-weight: 700;
  color: #1e1b4b;
  margin-bottom: 4px;
  font-family: "Playfair Display", serif;
}
.author-sidebar-inst {
  font-size: 13px;
  color: #6b7280;
  margin-bottom: 12px;
}
.author-sidebar-category {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #f5f3ff;
  color: #6366f1;
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 13px;
  font-weight: 600;
  border: 1px solid #e0e7ff;
}

/* Sidebar Actions */
.sidebar-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.sidebar-action-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 16px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
  cursor: pointer;
  border: none;
  width: 100%;
}
.primary-sa {
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: white;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
}
.primary-sa:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(99, 102, 241, 0.5);
  color: white;
}
.outline-sa {
  background: white;
  color: #374151;
  border: 1.5px solid var(--gray-200);
}
.outline-sa:hover {
  border-color: #c4b5fd;
  color: #4f46e5;
  background: #f5f3ff;
}

/* Related articles */
.related-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.related-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  color: #374151;
  text-decoration: none;
  transition: color 0.2s;
  line-height: 1.5;
}
.related-item:hover {
  color: #6366f1;
}
.related-item-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: #f5f3ff;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6366f1;
  font-size: 16px;
  flex-shrink: 0;
}

/* Sidebar Ad */
.sidebar-ad-card {
  background: white;
  padding: 16px;
  border-radius: 16px;
  border: 1px solid var(--gray-200);
  box-shadow: var(--shadow-sm);
}
.sidebar-ad-card img {
  width: 100%;
  border-radius: 8px;
}

/* ── Responsive ── */
@media (max-width: 1024px) {
  .ad-layout {
    flex-direction: column;
  }
  .ad-sidebar {
    width: 100%;
    position: static;
    flex-direction: row;
    flex-wrap: wrap;
  }
  .ad-sidebar-card {
    flex: 1;
    min-width: 260px;
  }
}
@media (max-width: 640px) {
  .ad-cert-inner {
    flex-direction: column;
    text-align: center;
  }
  .ad-cert-ref {
    justify-content: center;
  }
  .ad-download-cta {
    flex-direction: column;
    text-align: center;
  }
  .ad-meta-bar {
    gap: 12px;
  }
  .ad-meta-sep {
    display: none;
  }
  .ad-content-body {
    padding: 24px 20px;
  }
  .ad-abstract-card {
    padding: 24px 20px;
  }
}
