:root {
  --bg: #f4f7fb;
  --surface: #ffffff;
  --surface-soft: #edf3f7;
  --surface-warm: #fff6ef;
  --ink: #1f2f40;
  --muted: #627587;
  --line: #d9e3ec;
  --accent: #ef8d73;
  --accent-deep: #d56d4d;
  --blue: #5c7fa7;
  --sage: #6da292;
  --gold: #f1c76d;
  --lavender: #d9d8f8;
  --shadow: 0 18px 44px rgba(24, 42, 60, 0.08);
  --max: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  line-height: 1.7;
  background:
    radial-gradient(circle at top left, rgba(241, 199, 109, 0.18), transparent 26%),
    linear-gradient(180deg, #f9fbfd 0%, var(--bg) 100%);
}

img,
video {
  display: block;
  width: 100%;
}

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

p {
  margin: 0;
}

h1,
h2 {
  text-wrap: balance;
}

.container {
  width: min(calc(100% - 32px), var(--max));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(14px);
  background: rgba(249, 251, 253, 0.9);
  border-bottom: 1px solid rgba(217, 227, 236, 0.95);
}

.header-inner {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--accent), var(--gold));
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  flex: 0 0 auto;
}

.brand-copy {
  min-width: 0;
}

.brand-copy strong,
.brand-copy span {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-copy strong {
  font-size: 16px;
}

.brand-copy span {
  color: var(--muted);
  font-size: 13px;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 18px;
  color: var(--muted);
  font-size: 14px;
}

.nav a {
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.nav a:hover,
.nav a:focus-visible,
.nav a.is-active {
  color: var(--accent-deep);
  border-color: var(--accent);
  outline: none;
}

.hero {
  position: relative;
  min-height: 82vh;
  display: flex;
  align-items: flex-end;
  color: #fff;
  background-image:
    linear-gradient(180deg, rgba(14, 28, 43, 0.22) 0%, rgba(14, 28, 43, 0.74) 88%),
    url("../photos/site/hero-stone.jpg");
  background-position:
    center,
    58% 18%;
  background-size:
    auto,
    cover;
  background-repeat:
    no-repeat,
    no-repeat;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 120px;
  background: linear-gradient(180deg, transparent 0%, var(--bg) 100%);
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(calc(100% - 32px), var(--max));
  margin: 0 auto 64px;
  max-width: 700px;
  display: grid;
  gap: 18px;
}

.hero-kicker,
.page-kicker {
  width: fit-content;
  min-height: 34px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  font-size: 13px;
  letter-spacing: 0;
}

.hero-kicker {
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.hero h1,
.page-hero h1 {
  margin: 0;
  line-height: 1.08;
}

.hero h1 {
  font-size: clamp(40px, 5.2vw, 64px);
}

.hero p {
  max-width: 34ch;
  color: rgba(255, 255, 255, 0.92);
  font-size: clamp(17px, 1.95vw, 20px);
}

.hero-actions,
.button-row,
.entry-meta,
.page-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button-row {
  margin-top: 28px;
  align-items: center;
}

.button {
  min-height: 48px;
  padding: 0 20px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-1px);
  outline: none;
}

.button-primary {
  background: var(--accent);
  color: #fff;
}

.button-primary:hover,
.button-primary:focus-visible {
  background: var(--accent-deep);
}

.button-secondary {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.36);
}

.button-secondary:hover,
.button-secondary:focus-visible {
  background: rgba(255, 255, 255, 0.16);
}

.button-soft {
  color: var(--blue);
  background: rgba(92, 127, 167, 0.12);
  border: 1px solid rgba(92, 127, 167, 0.22);
}

.button-soft:hover,
.button-soft:focus-visible {
  background: rgba(92, 127, 167, 0.18);
}

main {
  display: block;
}

section {
  padding: 72px 0;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.section-copy {
  flex: 1 1 680px;
  max-width: 780px;
  min-width: 0;
}

.section-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-self: flex-end;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 8px;
  color: var(--accent-deep);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

h2 {
  margin: 0;
  font-size: clamp(30px, 3.5vw, 44px);
  line-height: 1.15;
}

h3 {
  margin: 0;
}

.section-head p,
.story-card p,
.spotlight-copy p,
.memory-copy p,
.stat-card p,
.time-card p,
.closing-note p,
.closing-list li,
.video-copy p,
.page-hero p,
.info-card p,
.profile-card p,
.diary-card p,
.prose p {
  color: var(--muted);
}

.section-head p {
  margin-top: 10px;
  max-width: 58ch;
}

.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.about-grid,
.spotlight-grid,
.closing-grid,
.detail-grid {
  display: grid;
  gap: 24px;
}

.about-grid,
.closing-grid {
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
}

.story-card,
.spotlight-copy,
.closing-note,
.closing-list,
.info-card,
.profile-card,
.diary-card,
.prose {
  padding: 30px;
}

.story-card,
.spotlight-copy,
.closing-note {
  display: grid;
  gap: 16px;
}

.stats-grid,
.entry-grid,
.video-grid,
.timeline-grid,
.profile-grid,
.diary-grid {
  display: grid;
  gap: 18px;
}

.stats-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.stat-card {
  min-height: 178px;
  padding: 22px;
  display: grid;
  align-content: start;
  gap: 10px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(237, 243, 247, 0.92));
}

.stat-card:nth-child(1) {
  border-top: 4px solid var(--accent);
}

.stat-card:nth-child(2) {
  border-top: 4px solid var(--gold);
}

.stat-card:nth-child(3) {
  border-top: 4px solid var(--sage);
}

.stat-card:nth-child(4) {
  border-top: 4px solid var(--blue);
}

.stat-card strong {
  font-size: 30px;
  line-height: 1;
}

.stat-card span,
.time-card span {
  font-weight: 700;
}

.spotlight-band,
.note-band {
  background:
    linear-gradient(135deg, rgba(239, 141, 115, 0.08), rgba(92, 127, 167, 0.08)),
    rgba(255, 255, 255, 0.55);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.spotlight-grid {
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  align-items: center;
}

.spotlight-photo {
  padding: 0;
  overflow: hidden;
}

.spotlight-photo img {
  min-height: 420px;
  height: 100%;
  object-fit: cover;
}

.pill {
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  background: var(--surface-soft);
  color: var(--blue);
  font-size: 13px;
  font-weight: 700;
}

.pill-warm {
  background: rgba(239, 141, 115, 0.14);
  color: var(--accent-deep);
}

.pill-sage {
  background: rgba(109, 162, 146, 0.14);
  color: #4d7f70;
}

.pill-lavender {
  background: rgba(217, 216, 248, 0.42);
  color: #6561a8;
}

.entry-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.entry-card,
.gallery-item {
  overflow: hidden;
}

.entry-card figure {
  margin: 0;
  display: grid;
  grid-template-rows: 230px auto;
  height: 100%;
}

.entry-card img {
  height: 100%;
  object-fit: cover;
}

.memory-copy {
  padding: 24px;
  display: grid;
  gap: 14px;
}

.memory-copy h3,
.video-copy h3,
.time-card strong,
.closing-list h3,
.info-card h3,
.profile-card h3,
.diary-card h3 {
  display: block;
}

.entry-link,
.back-link {
  display: inline-flex;
  align-items: center;
  color: var(--accent-deep);
  font-weight: 700;
}

.route-grid,
.archive-grid,
.facts-grid,
.chart-grid,
.summary-grid {
  display: grid;
  gap: 18px;
}

.route-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.archive-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.facts-grid,
.chart-grid,
.summary-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.route-card,
.fact-card,
.chart-card,
.table-card,
.summary-card {
  padding: 24px;
}

.route-card,
.fact-card,
.summary-card {
  min-height: 210px;
  display: grid;
  align-content: start;
  gap: 12px;
}

.route-card strong,
.fact-card strong,
.summary-card strong {
  font-size: 30px;
  line-height: 1;
}

.route-card span,
.fact-card span,
.summary-card span {
  color: var(--blue);
  font-weight: 700;
}

.route-card p,
.fact-card p,
.summary-card p,
.table-card p {
  color: var(--muted);
}

.archive-entry {
  overflow: hidden;
}

.archive-entry figure {
  margin: 0;
  display: grid;
  grid-template-rows: 240px auto;
  height: 100%;
}

.archive-entry img {
  height: 100%;
  object-fit: cover;
}

.archive-copy {
  padding: 24px;
  display: grid;
  gap: 14px;
}

.anchor-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 28px;
}

.anchor-row a {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  background: var(--surface-soft);
  color: var(--blue);
  font-size: 14px;
  font-weight: 700;
}

.gallery-stack {
  display: grid;
  gap: 42px;
}

.gallery-section {
  display: grid;
  gap: 18px;
}

.gallery-wall {
  columns: 4 220px;
  column-gap: 18px;
}

.gallery-wall-item {
  break-inside: avoid;
  margin: 0 0 18px;
}

.gallery-wall-item img {
  border-radius: 8px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  background: #fff;
}

.media-feature {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(300px, 0.92fr);
  gap: 24px;
  align-items: start;
}

.media-stage,
.photo-stage {
  padding: 0;
  overflow: hidden;
}

.media-stage video {
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #111922;
}

.media-stage.is-vertical {
  max-width: 420px;
  margin: 0 auto;
}

.media-stage.is-vertical video {
  aspect-ratio: 9 / 16;
}

.photo-stage img {
  height: auto;
}

.meta-list {
  display: grid;
  gap: 14px;
}

.meta-list li {
  color: var(--muted);
}

.chart-card {
  display: grid;
  gap: 16px;
}

.chart-shell {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: linear-gradient(180deg, #ffffff 0%, #f7fbfe 100%);
}

.chart-shell svg {
  width: 100%;
  height: auto;
  display: block;
}

.chart-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.legend-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
}

.legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  display: inline-block;
}

.legend-dot.height {
  background: var(--blue);
}

.legend-dot.weight {
  background: var(--accent);
}

.data-note {
  padding: 18px 20px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--surface-warm);
  color: var(--muted);
}

.table-card {
  overflow-x: auto;
}

.record-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 620px;
}

.record-table th,
.record-table td {
  padding: 12px 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  color: var(--muted);
  font-size: 14px;
}

.record-table th {
  color: var(--ink);
}

.related-strip {
  display: grid;
  gap: 18px;
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-auto-rows: 195px;
  grid-auto-flow: dense;
  gap: 18px;
}

.gallery-item {
  position: relative;
  min-height: 195px;
  grid-column: span 4;
}

.gallery-item.is-feature {
  grid-column: span 4;
  grid-row: span 2;
}

.gallery-item.is-wide {
  grid-column: span 8;
  grid-row: span 2;
}

.gallery-item img {
  height: 100%;
  object-fit: cover;
}

.gallery-item figcaption {
  position: absolute;
  inset: auto 0 0;
  padding: 18px;
  background: linear-gradient(180deg, transparent 0%, rgba(15, 25, 37, 0.84) 100%);
  color: #fff;
}

.gallery-item strong {
  display: block;
  margin-bottom: 6px;
  font-size: 18px;
  line-height: 1.2;
}

.gallery-item span {
  color: rgba(255, 255, 255, 0.86);
  font-size: 14px;
  line-height: 1.5;
}

.video-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
}

.video-card {
  padding: 18px;
  display: grid;
  gap: 16px;
}

.video-shell {
  background: #111922;
  border-radius: 8px;
  overflow: hidden;
}

.video-shell.is-landscape video {
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.video-shell.is-vertical {
  max-width: 360px;
  margin: 0 auto;
}

.video-shell.is-vertical video {
  aspect-ratio: 9 / 16;
  object-fit: cover;
}

.timeline-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.time-card {
  min-height: 220px;
  padding: 24px;
  display: grid;
  align-content: start;
  gap: 12px;
}

.time-card strong {
  font-size: 30px;
  line-height: 1;
  color: var(--blue);
}

.time-card:nth-child(1) {
  background: linear-gradient(180deg, rgba(239, 141, 115, 0.12), #fff 52%);
}

.time-card:nth-child(2) {
  background: linear-gradient(180deg, rgba(241, 199, 109, 0.16), #fff 52%);
}

.time-card:nth-child(3) {
  background: linear-gradient(180deg, rgba(217, 216, 248, 0.26), #fff 52%);
}

.time-card:nth-child(4) {
  background: linear-gradient(180deg, rgba(109, 162, 146, 0.16), #fff 52%);
}

.closing-list ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
}

.closing-list li + li {
  margin-top: 10px;
}

.page-shell {
  padding-bottom: 48px;
}

.page-hero {
  padding: 56px 0 20px;
  background: linear-gradient(180deg, rgba(239, 141, 115, 0.08), transparent 72%);
}

.back-link {
  margin-bottom: 14px;
  color: var(--blue);
}

.page-kicker {
  margin-bottom: 14px;
  background: rgba(239, 141, 115, 0.12);
  color: var(--accent-deep);
}

.page-hero h1 {
  font-size: clamp(34px, 5vw, 58px);
}

.page-hero p {
  margin-top: 14px;
  max-width: 58ch;
  font-size: 18px;
}

.detail-grid {
  grid-template-columns: minmax(0, 1.06fr) minmax(300px, 0.94fr);
  align-items: start;
}

.lead-image {
  padding: 0;
  overflow: hidden;
}

.lead-image img {
  height: auto;
}

.info-stack {
  display: grid;
  gap: 18px;
}

.info-card,
.profile-card,
.diary-card {
  min-height: 180px;
}

.profile-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.prose p + p {
  margin-top: 14px;
}

.prose blockquote {
  margin: 24px 0;
  padding: 18px 20px;
  border-left: 4px solid var(--accent);
  background: var(--surface-warm);
  border-radius: 0 8px 8px 0;
  color: var(--ink);
}

.diary-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.diary-card {
  display: grid;
  align-content: start;
  gap: 12px;
}

.site-footer {
  padding: 28px 0 44px;
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.78);
  color: var(--muted);
  font-size: 14px;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
}

@media (max-width: 1024px) {
  .about-grid,
  .spotlight-grid,
  .closing-grid,
  .detail-grid,
  .media-feature {
    grid-template-columns: 1fr;
  }

  .entry-grid,
  .video-grid,
  .timeline-grid,
  .profile-grid,
  .diary-grid,
  .route-grid,
  .archive-grid,
  .facts-grid,
  .chart-grid,
  .summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .photo-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-rows: 220px;
  }

  .gallery-item,
  .gallery-item.is-feature {
    grid-column: span 1;
  }

  .gallery-item.is-wide,
  .gallery-item.is-feature {
    grid-column: span 2;
  }

  .gallery-item.is-feature,
  .gallery-item.is-wide {
    grid-row: span 2;
  }
}

@media (max-width: 720px) {
  .site-header {
    position: static;
  }

  .header-inner,
  .section-head,
  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .nav {
    width: 100%;
    justify-content: flex-start;
    gap: 10px 18px;
  }

  .hero {
    min-height: 74vh;
    background-position:
      center,
      68% 16%;
  }

  .hero-content {
    margin-bottom: 48px;
  }

  .hero h1 {
    font-size: clamp(36px, 11vw, 54px);
  }

  section {
    padding: 58px 0;
  }

  .stats-grid,
  .entry-grid,
  .video-grid,
  .timeline-grid,
  .profile-grid,
  .diary-grid,
  .route-grid,
  .archive-grid,
  .facts-grid,
  .chart-grid,
  .summary-grid {
    grid-template-columns: 1fr;
  }

  .photo-grid {
    grid-template-columns: 1fr;
    grid-auto-rows: 240px;
  }

  .gallery-item,
  .gallery-item.is-feature,
  .gallery-item.is-wide {
    grid-column: span 1;
    grid-row: span 1;
  }

  .story-card,
  .spotlight-copy,
  .closing-note,
  .closing-list,
  .info-card,
  .profile-card,
  .diary-card,
  .prose {
    padding: 24px;
  }

  .entry-card figure {
    grid-template-rows: 220px auto;
  }

  .spotlight-photo img {
    min-height: 320px;
  }

  .gallery-wall {
    columns: 2 140px;
  }
}
