/* =========================================================
   TheSpaceLaunches · News Article Detail Styles
   Template: /news/{date}-{slug}.html
   Spec: 10-接口契约设计-v1.1.md §3 (page skeleton) + §6 (modules)
   Notes:
     - PC-first: desktop layout is primary; a single narrow
       breakpoint keeps phones readable (per 2026-10-21 PM
       request: detail page must adapt to PC and mobile).
     - Centered reading column: everything (breadcrumb, hero,
       figure, body, entity cards, related news) aligns inside
       one centered container (per 2026-10-21 PM request:
       no full-bleed, beautiful centered detail page).
     - Uses .news-detail-* namespaces for the article chrome and
       the concrete class names emitted by the pipeline for
       entity cards / related news cards.

   Layout spec (centered column):
     main            max-width var(--container-max), centered, padding 40px 24px 72px
     hero card       padding 36px 40px, margin-bottom 28px
     figure          margin-bottom 32px, radius 14px
     body text       16px / line-height 1.85, p-gap 20px
     entities        margin-top 40px, grid (min 260px), gap 16px
     related         margin-top 48px, grid (min 340px), gap 16px
   ========================================================= */

/* —— Centered reading column —— */
.news-detail-page main {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 40px 24px 72px;
}

/* —— Breadcrumb (provided by base.html) —— */
.news-detail-page .breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-3);
  margin: 0 0 28px 0;
  flex-wrap: wrap;
}
.news-detail-page .breadcrumb a {
  color: var(--text-2);
  text-decoration: none;
  transition: color .15s ease;
}
.news-detail-page .breadcrumb a:hover { color: var(--accent-blue); }
.news-detail-page .breadcrumb .sep { color: var(--text-3); opacity: .55; }
.news-detail-page .breadcrumb [aria-current="page"] {
  color: var(--text-0);
  font-weight: 500;
}

/* —— Article shell —— */
.news-detail {
  width: 100%;
}

/* —— Hero (h1 + source + date) —— */
.news-detail__hero {
  position: relative;
  padding: 36px 40px;
  margin-bottom: 28px;
  background: var(--glass-bg);
  border: var(--border-glow);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  overflow: hidden;
}
.news-detail__hero::before {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse at 92% 0%, rgba(76, 201, 255, 0.16), transparent 55%),
    radial-gradient(ellipse at 0% 100%, rgba(255, 138, 61, 0.10), transparent 60%);
  pointer-events: none;
}
.news-detail__title {
  position: relative;
  font-family: var(--font-display);
  font-size: clamp(28px, 3vw, 38px);
  line-height: 1.22;
  letter-spacing: 0.01em;
  color: var(--text-0);
  margin: 0 0 18px 0;
}
.news-detail__meta {
  position: relative;
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 13px;
  color: var(--text-2);
}
.news-detail__source {
  color: var(--accent-blue);
  font-weight: 600;
  letter-spacing: 0.04em;
}
.news-detail__date {
  color: var(--text-3);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.news-detail__date::before {
  content: "";
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--accent-orange);
  display: inline-block;
}

/* —— Hero image (Module: lead visual) —— */
.news-detail__figure {
  margin: 0 0 32px 0;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid rgba(76, 201, 255, 0.16);
}
.news-detail__figure img {
  display: block;
  width: 100%;
  height: auto;
}
.news-detail__figure figcaption {
  padding: 10px 16px;
  font-size: 12px;
  color: var(--text-3);
  background: rgba(15, 28, 61, 0.55);
  border-top: 1px solid rgba(76, 201, 255, 0.10);
}

/* —— Article body (sanitized full text) —— */
.news-detail__body {
  color: var(--text-1);
  font-size: 16px;
  line-height: 1.85;
  margin-bottom: 40px;
}
.news-detail__body > :first-child { margin-top: 0; }
.news-detail__body > :last-child { margin-bottom: 0; }
.news-detail__body p { margin: 0 0 20px 0; }
.news-detail__body h2 {
  font-family: var(--font-display);
  font-size: 24px;
  color: var(--text-0);
  margin: 36px 0 16px;
  letter-spacing: 0.01em;
}
.news-detail__body h3 {
  font-family: var(--font-display);
  font-size: 19px;
  color: var(--text-0);
  margin: 28px 0 12px;
}
.news-detail__body ul,
.news-detail__body ol {
  margin: 0 0 20px 0;
  padding-left: 24px;
}
.news-detail__body li { margin-bottom: 8px; }
.news-detail__body a {
  color: var(--accent-blue);
  text-decoration: underline;
  text-decoration-color: rgba(76, 201, 255, 0.4);
  text-underline-offset: 3px;
  transition: color .15s ease, text-decoration-color .15s ease;
}
.news-detail__body a:hover {
  color: var(--text-0);
  text-decoration-color: var(--accent-blue);
}
.news-detail__body blockquote {
  margin: 24px 0;
  padding: 14px 22px;
  border-left: 3px solid var(--accent-orange);
  background: rgba(255, 138, 61, 0.07);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  color: var(--text-2);
}
.news-detail__body img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-md);
  margin: 20px 0;
}
.news-detail__body figure {
  margin: 24px 0;
}
.news-detail__body figure img {
  margin: 0;
}
.news-detail__body figcaption {
  font-size: 12px;
  color: var(--text-3);
  margin-top: 8px;
}

/* =========================================================
   Module 2 · Linked entity cards
   Missions / rockets / launch sites → internal detail links only
   (R2-01: no live status, no snapshots, hover intent only).
   ========================================================= */
.news-detail__entities {
  margin: 40px 0 0 0;
}
.news-detail__entities-title {
  font-family: var(--font-display);
  font-size: 20px;
  letter-spacing: 0.02em;
  color: var(--text-0);
  margin: 0 0 18px 0;
}
.entity-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}
.entity-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px 22px;
  background: var(--glass-bg);
  border: 1px solid rgba(76, 201, 255, 0.16);
  border-radius: var(--radius-md);
  text-decoration: none;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.entity-card:hover {
  transform: translateY(-3px);
  border-color: rgba(76, 201, 255, 0.45);
  box-shadow: 0 0 22px rgba(76, 201, 255, 0.12);
}
.entity-card__type {
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--accent-orange);
}
.entity-card__name {
  font-family: var(--font-display);
  font-size: 17px;
  color: var(--text-0);
  line-height: 1.3;
}

/* =========================================================
   Module 3 · Related news
   Same source / same rocket / time-adjacent, latest N static.
   ========================================================= */
.news-detail__related {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid rgba(76, 201, 255, 0.14);
}
.news-detail__related-title {
  font-family: var(--font-display);
  font-size: 20px;
  letter-spacing: 0.02em;
  color: var(--text-0);
  margin: 0 0 18px 0;
}
.related-news {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 16px;
}
.related-card {
  display: flex;
  align-items: stretch;
  gap: 14px;
  padding: 14px;
  background: var(--glass-bg);
  border: 1px solid rgba(76, 201, 255, 0.16);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.related-card:hover {
  transform: translateY(-3px);
  border-color: rgba(76, 201, 255, 0.45);
  box-shadow: 0 0 22px rgba(76, 201, 255, 0.12);
}
.related-card img {
  width: 96px;
  height: 96px;
  object-fit: cover;
  border-radius: 10px;
  flex: 0 0 auto;
}
.related-card__body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.related-card__source {
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-orange);
  font-weight: 600;
}
.related-card__title {
  margin: 0;
  font-size: 15px;
  line-height: 1.45;
  font-weight: 500;
}
.related-card__title a {
  color: var(--text-1);
  text-decoration: none;
  transition: color .15s ease;
}
.related-card:hover .related-card__title a {
  color: var(--text-0);
}
.related-card__date {
  font-size: 12px;
  color: var(--text-3);
}

/* —— Last-updated footer strip (base page_updated_html) —— */
.news-detail-page .page-updated-wrap {
  margin-top: 48px;
  padding-top: 20px;
  border-top: 1px solid rgba(76, 201, 255, 0.10);
}
.news-detail-page .page-updated {
  font-size: 12px;
  color: var(--text-3);
}

/* =========================================================
   Mobile adaptation (2026-10-21 PM request: detail page must
   adapt to PC and mobile). Single breakpoint at 720px:
   below it the 800px column becomes fluid and paddings shrink.
   ========================================================= */
@media (max-width: 720px) {
  .news-detail-page main {
    padding: 24px 16px 56px;
  }
  .news-detail__hero {
    padding: 24px 20px;
  }
  .news-detail__title {
    font-size: 24px;
  }
  .news-detail__meta {
    flex-wrap: wrap;
    gap: 10px 14px;
  }
  .entity-cards,
  .related-news {
    grid-template-columns: 1fr;
  }
}