.page-home {
  --home-gap: clamp(0.875rem, 2.2vw, 1.5rem);
  background: var(--ice);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--step-body);
  line-height: 1.75;
  overflow-x: clip;
}

.page-home h1,
.page-home h2,
.page-home h3 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.15;
  margin: 0;
}

.page-home p {
  margin: 0;
}

.page-home .mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

.page-home a:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

.page-home .home-open a:focus-visible,
.page-home .home-save a:focus-visible {
  outline-color: var(--cyan);
}

.page-home [data-reveal] {
  opacity: 1;
  transform: none;
}

/* ---------- 首屏刻度带 ---------- */
.page-home .home-open {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  background: var(--ink);
  color: var(--ice);
  border-bottom: 1px solid var(--ink-line);
}

.page-home .home-open__panel {
  padding: clamp(1.5rem, 5vw, 3rem) var(--gutter) clamp(2rem, 5vw, 3.25rem);
  background:
    radial-gradient(120% 90% at 88% 0%, rgba(24, 214, 196, 0.16), transparent 62%),
    var(--ink);
  min-width: 0;
}

.page-home .home-open__meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: var(--step-caption);
  letter-spacing: 0.12em;
  color: var(--frost);
}

.page-home .home-open__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 0 3px rgba(24, 214, 196, 0.2);
}

.page-home .home-rail {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.page-home .home-rail__line {
  flex: 1 1 auto;
  min-width: 0;
  height: 14px;
  border-bottom: 1px solid var(--line-ice);
  background-image: repeating-linear-gradient(90deg, var(--cyan) 0 1px, transparent 1px 22px);
  background-repeat: repeat-x;
  background-position: left bottom;
  opacity: 0.72;
}

.page-home .home-rail__mark {
  flex: 0 0 auto;
  font-size: var(--step-caption);
  letter-spacing: 0.08em;
  color: var(--cyan);
  white-space: nowrap;
}

.page-home .home-count {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.25rem 0.75rem;
  margin-top: 1.25rem;
  padding-left: 1rem;
  border-left: 3px solid var(--cyan);
}

.page-home .home-count__num {
  font-family: var(--font-mono);
  font-size: clamp(3.2rem, 13vw, 5.5rem);
  font-weight: 600;
  line-height: 0.85;
  letter-spacing: -0.04em;
  color: var(--ice);
}

.page-home .home-count__unit {
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 3vw, 1.5rem);
  letter-spacing: 0.08em;
  color: var(--cyan);
}

.page-home .home-count__note {
  flex: 1 1 12rem;
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--frost);
}

.page-home .home-open__title {
  margin-top: 1.75rem;
  max-width: 16em;
  font-size: clamp(2rem, 7vw, 3.4rem);
  line-height: 1.06;
  color: var(--ice);
}

.page-home .home-open__lead {
  margin-top: 1rem;
  max-width: 40em;
  font-size: clamp(1rem, 2.4vw, 1.0625rem);
  line-height: 1.8;
  color: var(--frost);
}

.page-home .home-lines {
  list-style: none;
  margin: 2.25rem 0 0;
  padding: 0;
  display: grid;
  gap: 0;
}

.page-home .home-line {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-areas:
    "idx name go"
    "idx desc go";
  column-gap: 0.875rem;
  row-gap: 0.25rem;
  padding: 0.9rem 0.25rem;
  border-top: 1px solid var(--line-ice);
  text-decoration: none;
  color: var(--ice);
  transition: background 0.18s var(--ease);
}

.page-home .home-line:hover,
.page-home .home-line:focus-visible {
  background: rgba(24, 214, 196, 0.09);
}

.page-home .home-line__idx {
  grid-area: idx;
  align-self: start;
  padding-top: 0.35rem;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  color: var(--cyan);
}

.page-home .home-line__name {
  grid-area: name;
  font-family: var(--font-display);
  font-size: 1.125rem;
  letter-spacing: 0.02em;
}

.page-home .home-line__desc {
  grid-area: desc;
  font-size: 0.875rem;
  line-height: 1.65;
  color: var(--frost);
}

.page-home .home-line__go {
  grid-area: go;
  align-self: center;
  color: var(--cyan);
}

/* ---------- 首屏玻璃目录 ---------- */
.page-home .home-open__aside {
  position: relative;
  display: flex;
  align-items: flex-end;
  min-height: 320px;
  background: var(--ink-soft);
  overflow: hidden;
}

.page-home .home-hero {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.page-home .home-directory {
  position: relative;
  width: 100%;
  padding: 1rem var(--gutter) 1.25rem;
  background: var(--glass-dark);
  backdrop-filter: blur(14px) saturate(1.2);
  border-top: 1px solid var(--line-ice);
}

.page-home .home-directory__title {
  margin-bottom: 0.5rem;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  color: var(--cyan);
}

.page-home .home-directory__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.35rem;
}

.page-home .home-directory__list a {
  display: inline-block;
  font-size: 0.875rem;
  color: var(--ice);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.18s var(--ease), border-color 0.18s var(--ease);
}

.page-home .home-directory__list a:hover,
.page-home .home-directory__list a:focus-visible {
  color: var(--cyan);
  border-bottom-color: var(--cyan);
}

/* ---------- 章节头 ---------- */
.page-home .home-scenes,
.page-home .home-rhythm {
  max-width: var(--shell);
  margin-inline: auto;
  padding: clamp(2.5rem, 6vw, 4.5rem) var(--gutter);
}

.page-home .home-head {
  display: grid;
  gap: 0.5rem;
  max-width: 46em;
  margin-bottom: clamp(1.5rem, 3vw, 2.25rem);
}

.page-home .home-head__index {
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  color: var(--clay);
}

.page-home .home-head__title {
  font-size: var(--step-h2);
  line-height: 1.18;
}

.page-home .home-head__note {
  font-size: 0.9375rem;
  line-height: 1.7;
  color: var(--slate-deep);
}

/* ---------- Bento 场景 ---------- */
.page-home .home-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--home-gap);
}

.page-home .home-tile {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-width: 0;
  padding: clamp(1.125rem, 3vw, 1.75rem);
  border: 1px solid var(--line-ink);
  border-radius: var(--radius);
  background: var(--cream);
  color: var(--ink);
}

.page-home .home-tile h3 {
  font-size: var(--step-h3);
  line-height: 1.32;
}

.page-home .home-tile p {
  font-size: 0.9375rem;
  line-height: 1.75;
  color: var(--slate-deep);
}

.page-home .home-tile--ink {
  background: var(--ink-soft);
  border-color: var(--ink-line);
  color: var(--ice);
}

.page-home .home-tile--ink h3 {
  color: var(--ice);
}

.page-home .home-tile--ink p {
  color: var(--frost);
}

.page-home .home-tile--frost {
  background: var(--frost);
}

.page-home .home-tile--accent {
  background: var(--cream);
  border-left: 3px solid var(--moss);
}

.page-home .home-tile--media {
  padding: 0;
  overflow: hidden;
  background: var(--frost);
}

.page-home .home-tile--media img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 260px;
  object-fit: cover;
}

.page-home .home-tile--media figcaption {
  padding: 0.7rem 1rem;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  color: var(--slate-deep);
  background: var(--cream);
}

.page-home .tag {
  align-self: flex-start;
  display: inline-block;
  padding: 0.25rem 0.5rem;
  border-radius: 2px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  background: var(--ink);
  color: var(--ice);
}

.page-home .tag--cyan {
  background: var(--cyan);
  color: var(--ink);
}

.page-home .tag--clay {
  background: var(--clay);
  color: var(--ice);
}

.page-home .tag--mint {
  background: var(--moss);
  color: var(--ice);
}

.page-home .tag--amber {
  background: var(--amber);
  color: var(--ink);
}

.page-home .home-tile__more {
  margin-top: auto;
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding-bottom: 2px;
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--line-ink-strong);
  transition: color 0.18s var(--ease), border-color 0.18s var(--ease);
}

.page-home .home-tile__more:hover,
.page-home .home-tile__more:focus-visible {
  color: var(--cyan-deep);
  border-bottom-color: var(--cyan-deep);
}

.page-home .home-tile--ink .home-tile__more {
  color: var(--cyan);
  border-bottom-color: rgba(24, 214, 196, 0.5);
}

/* ---------- 更新节奏 ---------- */
.page-home .home-rhythm__body {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--home-gap);
}

.page-home .home-beats {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line-ink);
}

.page-home .home-beat {
  display: grid;
  gap: 0.35rem;
  padding: 1.125rem 0;
  border-bottom: 1px solid var(--line-ink);
}

.page-home .home-beat__time {
  font-size: 0.8125rem;
  letter-spacing: 0.06em;
  color: var(--clay);
}

.page-home .home-beat h3 {
  font-size: 1.0625rem;
  line-height: 1.35;
}

.page-home .home-beat p {
  font-size: 0.9375rem;
  line-height: 1.75;
  color: var(--slate-deep);
}

.page-home .home-rhythm__media {
  margin: 0;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--frost);
}

.page-home .home-rhythm__media img {
  display: block;
  width: 100%;
  height: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
}

.page-home .home-rhythm__media figcaption {
  padding: 0.7rem 1rem;
  font-size: 0.72rem;
  color: var(--slate-deep);
  background: var(--cream);
}

.page-home .home-journal {
  display: grid;
  gap: 0.75rem;
  margin-top: clamp(1.75rem, 4vw, 2.5rem);
  padding: clamp(1rem, 3vw, 1.5rem);
  background: var(--frost);
  border-left: 3px solid var(--clay);
}

.page-home .home-journal__label {
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  color: var(--slate-deep);
}

.page-home .home-journal__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.page-home .home-journal__list a {
  display: inline-block;
  padding: 0.4rem 0.75rem;
  border: 1px solid var(--line-ink);
  border-radius: 2px;
  background: var(--ice);
  font-size: 0.875rem;
  color: var(--ink);
  text-decoration: none;
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease);
}

.page-home .home-journal__list a:hover,
.page-home .home-journal__list a:focus-visible {
  background: var(--cream);
  border-color: var(--ink);
}

/* ---------- 收藏与动作 ---------- */
.page-home .home-save {
  background: var(--ink);
  color: var(--ice);
  padding: clamp(2.5rem, 6vw, 4.5rem) var(--gutter);
}

.page-home .home-save__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--home-gap);
  max-width: var(--shell);
  margin-inline: auto;
  align-items: center;
}

.page-home .home-save__text > p {
  margin-top: 0.75rem;
  font-size: 0.9375rem;
  line-height: 1.8;
  color: var(--frost);
}

.page-home p.home-save__index {
  margin-top: 0;
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  color: var(--cyan);
}

.page-home .home-save__text h2 {
  font-size: var(--step-h2);
  line-height: 1.15;
  margin-top: 0.5rem;
  color: var(--ice);
}

.page-home .home-save__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
  margin-top: 1.5rem;
}

.page-home .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.7rem 1.15rem;
  border: 1px solid transparent;
  border-radius: 2px;
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
  text-decoration: none;
  transition: background 0.18s var(--ease), color 0.18s var(--ease), border-color 0.18s var(--ease);
}

.page-home .btn--primary {
  background: var(--cyan);
  color: var(--ink);
}

.page-home .btn--primary:hover,
.page-home .btn--primary:focus-visible {
  background: var(--ice);
}

.page-home .btn--ghost {
  border-color: var(--line-ice);
  color: var(--ice);
}

.page-home .btn--ghost:hover,
.page-home .btn--ghost:focus-visible {
  border-color: var(--cyan);
  color: var(--cyan);
}

.page-home .btn--outline {
  border-color: var(--cyan);
  color: var(--cyan);
}

.page-home .btn--outline:hover,
.page-home .btn--outline:focus-visible {
  background: var(--cyan);
  color: var(--ink);
}

.page-home p.home-save__meta {
  margin-top: 1rem;
  font-size: 0.72rem;
  line-height: 1.7;
  color: var(--frost);
  opacity: 0.85;
}

.page-home .home-save__history {
  display: inline-block;
  margin-top: 1.25rem;
  padding-bottom: 2px;
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  color: var(--ice);
  text-decoration: none;
  border-bottom: 1px solid var(--line-ice);
  transition: color 0.18s var(--ease), border-color 0.18s var(--ease);
}

.page-home .home-save__history:hover,
.page-home .home-save__history:focus-visible {
  color: var(--cyan);
  border-bottom-color: var(--cyan);
}

.page-home .home-save__figure {
  margin: 0;
}

.page-home .home-save__figure img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  object-fit: cover;
}

/* ---------- 平板起 ---------- */
@media (min-width: 760px) {
  .page-home .home-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .page-home .home-tile--8,
  .page-home .home-tile--media {
    grid-column: span 2;
  }

  .page-home .home-open__aside {
    min-height: 380px;
  }
}

/* ---------- 桌面 ---------- */
@media (min-width: 1000px) {
  .page-home .home-open {
    grid-template-columns: minmax(0, 1.22fr) minmax(0, 0.78fr);
    align-items: stretch;
  }

  .page-home .home-open__aside {
    min-height: 100%;
  }

  .page-home .home-grid {
    grid-template-columns: repeat(12, minmax(0, 1fr));
  }

  .page-home .home-tile--8 {
    grid-column: span 8;
  }

  .page-home .home-tile--5 {
    grid-column: span 5;
  }

  .page-home .home-tile--4 {
    grid-column: span 4;
  }

  .page-home .home-tile--3 {
    grid-column: span 3;
  }

  .page-home .home-tile--media {
    grid-column: span 4;
  }

  .page-home .home-rhythm__body {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    align-items: start;
  }

  .page-home .home-journal {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
  }

  .page-home .home-save__inner {
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr);
    gap: clamp(1.5rem, 4vw, 3rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  .page-home [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .page-home .home-line,
  .page-home .home-tile__more,
  .page-home .home-journal__list a,
  .page-home .home-save__history,
  .page-home .btn {
    transition: none;
  }
}
