/* ─── Report Detail Page ──────────────────────────────────── */

#report-detail {
  min-height: 60vh;
}

.rd-page {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 28px 0 60px;
}

/* Breadcrumb */
.rd-breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 0 20px;
  color: #617087;
  font-size: 14px;
  line-height: 1.5;
}

.rd-breadcrumb a {
  color: #2c49d8;
  text-decoration: none;
  transition: opacity 0.15s ease;
}

.rd-breadcrumb a:hover {
  opacity: 0.75;
}

.rd-breadcrumb-sep {
  color: #e3e9f1;
  font-size: 13px;
}

.rd-breadcrumb span[aria-current="page"] {
  color: #101827;
  font-weight: 600;
  max-width: 360px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Header */
.rd-header {
  padding: 32px 36px;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, #112b55, #2c49d8);
  margin-bottom: 20px;
}

.rd-header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.rd-broker-name {
  font-weight: 800;
  font-size: 20px;
  color: rgba(255, 255, 255, 0.92);
}

.rd-date-badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.18);
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  color: #fff;
}

.rd-title {
  margin: 0;
  font-size: clamp(26px, 3.6vw, 42px);
  line-height: 1.18;
  color: #fff;
  font-weight: 800;
}

.rd-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 18px;
}

.rd-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.85);
}

.rd-meta-item svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  opacity: 0.8;
}

/* Header color variants by report type */
.rd-header-industry-report {
  background: linear-gradient(135deg, #112b55, #2c49d8);
}

.rd-header-market-report {
  background: linear-gradient(135deg, #0c777c, #0f9b9b);
}

.rd-header-company-report {
  background: linear-gradient(135deg, #aa5720, #f28c28);
}

.rd-header-economic-report {
  background: linear-gradient(135deg, #5b21b6, #8b5cf6);
}

.rd-header-fixed-income-report {
  background: linear-gradient(135deg, #065f46, #10b981);
}

/* Actions */
.rd-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.rd-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    transform 0.15s ease;
}

.rd-action-btn:hover {
  background: rgba(255, 255, 255, 0.22);
  border-color: rgba(255, 255, 255, 0.5);
  transform: translateY(-1px);
}

.rd-action-btn svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

/* Content layout */
.rd-content-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 36px;
  align-items: start;
}

.rd-main {
  min-width: 0;
}

/* Content sections */
.rd-section {
  margin-bottom: 36px;
}

.rd-section h2 {
  margin: 0 0 16px;
  font-size: 22px;
  font-weight: 800;
  color: #101827;
  line-height: 1.25;
}

.rd-prose {
  color: #101827;
  line-height: 1.8;
  font-size: 16px;
}

.rd-prose p {
  margin: 0 0 14px;
}

.rd-prose p:last-child {
  margin-bottom: 0;
}

/* Takeaways list */
.rd-takeaway-list {
  margin: 0;
  padding: 0 0 0 22px;
  list-style: none;
}

.rd-takeaway-list li {
  position: relative;
  padding: 12px 0 12px 14px;
  color: #101827;
  font-size: 15px;
  line-height: 1.7;
  border-bottom: 1px solid #e3e9f1;
}

.rd-takeaway-list li:last-child {
  border-bottom: none;
}

.rd-takeaway-list li::before {
  content: "";
  position: absolute;
  left: -14px;
  top: 20px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #2c49d8;
}

/* Tags */
.rd-tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.rd-tag {
  display: inline-flex;
  align-items: center;
  padding: 7px 14px;
  border-radius: 99px;
  background: #eef5fb;
  color: #112b55;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
}

.rd-tag-company {
  background: #edf2ff;
  color: #2c49d8;
  border: 1px solid rgba(44, 73, 216, 0.12);
}

/* Sidebar */
.rd-sidebar {
  position: sticky;
  top: 90px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.rd-info-card {
  padding: 22px;
  border: 1px solid #e3e9f1;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 12px 30px rgba(22, 39, 68, 0.08);
}

.rd-info-card h3 {
  margin: 0 0 16px;
  font-size: 16px;
  font-weight: 800;
  color: #112b55;
}

.rd-info-list {
  margin: 0;
}

.rd-info-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid #e3e9f1;
}

.rd-info-row:last-child {
  border-bottom: none;
}

.rd-info-row dt {
  color: #617087;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}

.rd-info-row dd {
  margin: 0;
  color: #101827;
  font-size: 14px;
  font-weight: 700;
  text-align: right;
}

/* Table of contents */
.rd-toc-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.rd-toc-list li {
  margin: 0;
}

.rd-toc-list a {
  display: block;
  padding: 9px 12px;
  border-radius: 6px;
  color: #101827;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition:
    background 0.15s ease,
    color 0.15s ease;
}

.rd-toc-list a:hover {
  background: #f5f8fb;
  color: #2c49d8;
}

.rd-sidebar-cta {
  width: 100%;
  justify-content: center;
  text-align: center;
}

.rd-sidebar-cta svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

/* Preview images */
.rd-preview-section {
  margin-top: 8px;
}

.rd-preview-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}

.rd-preview-figure {
  margin: 0;
  border: 1px solid #e3e9f1;
  border-radius: 10px;
  overflow: hidden;
  background: #f5f8fb;
}

.rd-preview-figure img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}

.rd-preview-figure figcaption {
  padding: 10px 14px;
  color: #617087;
  font-size: 13px;
  line-height: 1.5;
  border-top: 1px solid #e3e9f1;
}

/* PDF embed */
.rd-pdf-section {
  margin-top: 8px;
}

.rd-intent-section {
  padding: 22px;
  border: 1px solid #e3e9f1;
  border-radius: 10px;
  background: #f8fbff;
}

.rd-intent-copy {
  margin: -6px 0 14px;
  color: #617087;
  line-height: 1.7;
}

.rd-intent-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rd-intent-list a {
  color: #1f66d1;
  font-weight: 700;
  text-decoration: none;
}

.rd-intent-list a:hover {
  text-decoration: underline;
}

.rd-pdf-link {
  margin: -4px 0 14px;
  font-size: 14px;
}

.rd-pdf-link a {
  color: #1f66d1;
  font-weight: 700;
  text-decoration: none;
}

.rd-pdf-link a:hover {
  text-decoration: underline;
}

.rd-pdf-container {
  border: 1px solid #e3e9f1;
  border-radius: 10px;
  overflow: hidden;
  background: #f5f8fb;
}

.rd-pdf-container iframe {
  display: block;
  width: 100%;
  height: 600px;
  border: none;
}

.rd-pdf-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 48px 32px;
  border: 2px dashed #e3e9f1;
  border-radius: 12px;
  background: #f5f8fb;
  text-align: center;
}

.rd-pdf-placeholder-icon {
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #edf2ff;
  color: #2c49d8;
}

.rd-pdf-placeholder-icon svg {
  width: 32px;
  height: 32px;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.rd-pdf-placeholder p {
  margin: 0;
  color: #617087;
  font-size: 15px;
  line-height: 1.6;
  max-width: 380px;
}

/* Related reports */
.rd-related {
  padding: 60px 0;
  background: #f5f8fb;
  border-top: 1px solid #e3e9f1;
}

.rd-related-inner {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

.rd-related-heading {
  margin: 0 0 24px;
  font-size: clamp(24px, 3vw, 34px);
  font-weight: 800;
  color: #101827;
}

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

/* Responsive */
@media (max-width: 980px) {
  .rd-content-layout {
    grid-template-columns: 1fr;
  }

  .rd-sidebar {
    position: static;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .rd-sidebar-cta {
    grid-column: 1 / -1;
  }

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

@media (max-width: 720px) {
  .rd-page {
    padding: 16px 0 40px;
  }

  .rd-header {
    padding: 22px 20px;
    border-radius: 10px;
  }

  .rd-title {
    font-size: clamp(22px, 5.5vw, 30px);
  }

  .rd-broker-name {
    font-size: 16px;
  }

  .rd-actions {
    flex-direction: column;
  }

  .rd-action-btn {
    justify-content: center;
    width: 100%;
  }

  .rd-sidebar {
    grid-template-columns: 1fr;
  }

  .rd-related-grid {
    grid-template-columns: 1fr;
  }

  .rd-related {
    padding: 40px 0;
  }

  .rd-pdf-container iframe {
    height: 400px;
  }

  .rd-preview-gallery {
    grid-template-columns: 1fr;
  }

  .rd-breadcrumb span[aria-current="page"] {
    max-width: 200px;
  }
}
