.page-home {
  font-size: var(--text-base);
  color: var(--text-strong);
  line-height: 1.75;
}

.page-home img {
  max-width: 100%;
  height: auto;
}

.page-home .home-hero,
.page-home .home-section,
.page-home .home-cta {
  scroll-margin-top: 120px;
}

/* ========== Hero ========== */
.page-home .home-hero {
  padding: clamp(5.5rem, 10vw, 9rem) 0 clamp(2.5rem, 5vw, 4rem);
  border-bottom: 1px solid var(--line);
}

.page-home .home-hero__inner {
  display: grid;
  gap: 2.5rem;
}

.page-home .home-hero__title {
  font-size: clamp(2.25rem, 5vw, 3.75rem);
  font-weight: 900;
  line-height: 1.15;
  letter-spacing: 0.01em;
  margin: 1rem 0 1.25rem;
}

.page-home .home-hero__lead {
  font-size: var(--text-lg);
  line-height: 1.8;
  color: var(--text-body);
  max-width: 42em;
  margin: 0 0 2.25rem;
}

/* 章节索引 */
.page-home .home-toc {
  display: flex;
  flex-direction: column;
  border-top: 1px solid var(--line);
}

.page-home .home-toc__item {
  display: grid;
  grid-template-columns: 3rem 1fr;
  gap: 1rem;
  align-items: baseline;
  padding: 1rem 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: inherit;
  transition: background 0.2s ease, padding-left 0.2s ease;
}

.page-home .home-toc__item:hover {
  background: var(--hover-bg);
  padding-left: 0.5rem;
}

.page-home .home-toc__num {
  font-family: var(--font-mono);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--accent-gold-strong);
}

.page-home .home-toc__body {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.page-home .home-toc__title {
  font-size: var(--text-lg);
  font-weight: 700;
  line-height: 1.4;
}

.page-home .home-toc__desc {
  font-size: var(--text-xs);
  color: var(--text-muted);
  letter-spacing: 0.04em;
}

/* 数据快照 */
.page-home .home-snapshot {
  background: var(--surface-card);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  padding: 1.5rem;
  min-width: 0;
}

.page-home .home-snapshot__header {
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--line);
  margin-bottom: 0.5rem;
}

.page-home .home-snapshot__label {
  font-size: var(--text-xs);
  letter-spacing: 0.1em;
  color: var(--text-muted);
}

.page-home .home-snapshot__item {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.9rem 0.5rem;
  border-bottom: 1px solid var(--grid-line);
  border-radius: var(--radius-sm);
  transition: background 0.2s ease, transform 0.2s ease;
}

.page-home .home-snapshot__item:last-child {
  border-bottom: none;
}

.page-home .home-snapshot__item:hover {
  background: var(--surface-elevated);
  transform: translateX(4px);
}

.page-home .home-snapshot__key,
.page-home .home-snapshot__value,
.page-home .home-snapshot__extra {
  margin: 0;
}

.page-home .home-snapshot__key {
  font-size: var(--text-xs);
  color: var(--text-muted);
  letter-spacing: 0.03em;
}

.page-home .home-snapshot__value {
  font-size: var(--text-xl);
  font-weight: 700;
}

.page-home .home-snapshot__num {
  font-family: var(--font-mono);
  font-size: var(--text-3xl);
  font-weight: 700;
  color: var(--accent-gold-strong);
  margin-right: 0.2rem;
}

.page-home .home-snapshot__extra {
  font-size: var(--text-xs);
  color: var(--text-muted);
  opacity: 0.65;
  transition: opacity 0.2s ease;
}

.page-home .home-snapshot__item:hover .home-snapshot__extra {
  opacity: 1;
}

.page-home .home-snapshot__note {
  font-size: var(--text-xs);
  color: var(--text-muted);
  padding-top: 0.75rem;
  margin-top: 0.5rem;
  border-top: 1px solid var(--line);
}

/* ========== 章节通用 ========== */
.page-home .home-section {
  padding: clamp(3rem, 7vw, 5.5rem) 0;
  border-bottom: 1px solid var(--line);
}

.page-home .home-section__grid {
  display: grid;
  gap: 2rem;
}

.page-home .home-section__side,
.page-home .home-section__main {
  min-width: 0;
}

.page-home .home-section__side {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.page-home .home-section__index {
  font-family: var(--font-mono);
  font-size: clamp(3rem, 5vw, 4.5rem);
  line-height: 1;
  font-weight: 700;
  color: var(--accent-gold-strong);
  letter-spacing: -0.02em;
}

.page-home .home-section__title {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 900;
  line-height: 1.25;
  margin: 0;
}

.page-home .home-section__sub {
  font-size: var(--text-sm);
  color: var(--text-muted);
  letter-spacing: 0.03em;
}

/* 章节锚点高亮 */
.page-home .home-section:target .home-section__side {
  animation: dafaSectionFlash 1.2s ease;
}

@keyframes dafaSectionFlash {
  0% {
    background: rgba(201, 162, 39, 0.14);
  }
  100% {
    background: transparent;
  }
}

/* ========== 开奖规则 ========== */
.page-home .home-rules__panel {
  display: grid;
  gap: 1.5rem;
  background: var(--surface-card);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 1.75rem;
}

.page-home .home-rules__lead {
  font-size: var(--text-lg);
  font-weight: 700;
  margin: 0 0 1rem;
}

.page-home .home-rules__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.page-home .home-rules__list li {
  position: relative;
  padding-left: 1.25rem;
  font-size: var(--text-sm);
  color: var(--text-body);
}

.page-home .home-rules__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-gold);
}

.page-home .home-rules__code {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  background: var(--surface-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 1.25rem;
}

.page-home .home-rules__code-label {
  margin: 0;
  font-size: var(--text-xs);
  color: var(--text-muted);
  letter-spacing: 0.06em;
}

.page-home .home-lottery-code {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.page-home .home-rules__code-note {
  margin: 0;
  font-size: var(--text-xs);
  color: var(--text-muted);
}

/* ========== 苹果查开奖 + 公告栏 ========== */
.page-home .home-apple__duo {
  display: grid;
  gap: 1.5rem;
}

.page-home .home-apple__panel {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  background: var(--surface-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 1.5rem;
}

.page-home .home-apple__panel--news {
  background: var(--surface-card);
}

.page-home .home-apple__panel-title,
.page-home .home-newsboard__title {
  font-size: var(--text-lg);
  font-weight: 700;
  margin: 0;
}

.page-home .home-apple__panel-text {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--text-body);
  line-height: 1.7;
}

.page-home .home-apple__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.page-home .home-apple__list li {
  position: relative;
  padding-left: 1.5rem;
  font-size: var(--text-sm);
  color: var(--text-body);
}

.page-home .home-apple__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.35em;
  width: 0.6rem;
  height: 0.6rem;
  border: 2px solid var(--accent-blue);
  border-radius: 2px;
}

.page-home .home-apple__panel .btn {
  align-self: flex-start;
  margin-top: 0.25rem;
}

.page-home .home-newsboard__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.page-home .home-newsboard__item {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  font-size: var(--text-sm);
  color: var(--text-body);
  line-height: 1.55;
}

.page-home .home-newsboard__text {
  flex: 1;
}

.page-home .home-newsboard__more {
  align-self: flex-start;
  margin-top: 0.25rem;
}

.page-home .home-apple__image {
  margin-top: 1.5rem;
}

.page-home .home-apple__img,
.page-home .home-updates__img,
.page-home .home-archive__img,
.page-home .home-trend__img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: var(--radius-md);
}

/* ========== WELCOME更新记录 ========== */
.page-home .home-updates {
  background: linear-gradient(90deg, rgba(74, 144, 217, 0.07), transparent 65%);
}

.page-home .home-updates__layout {
  display: grid;
  gap: 1.5rem;
}

.page-home .home-updates__timeline {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  border-left: 2px solid var(--accent-blue);
  padding-left: 1.25rem;
}

.page-home .home-updates__slot {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.page-home .home-updates__time {
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--accent-blue-deep);
  letter-spacing: 0.04em;
}

.page-home .home-updates__desc {
  font-size: var(--text-sm);
  color: var(--text-body);
}

.page-home .home-updates__changelog {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  background: var(--surface-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 1.25rem;
}

.page-home .home-updates__changelog-title {
  font-size: var(--text-base);
  font-weight: 700;
  margin: 0;
}

.page-home .home-updates__changelog-list {
  margin: 0;
  padding-left: 1.1rem;
  font-size: var(--text-sm);
  color: var(--text-body);
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.page-home .home-updates__changelog .btn {
  align-self: flex-start;
}

.page-home .home-updates__image {
  margin-top: 1.5rem;
}

/* ========== 国内板块资料库 ========== */
.page-home .home-archive__layout {
  display: grid;
  gap: 1.5rem;
}

.page-home .home-archive__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.page-home .home-archive__cell {
  background: var(--surface-card);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.9rem 0.5rem;
  text-align: center;
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--text-strong);
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.page-home .home-archive__cell:hover {
  border-color: var(--accent-gold);
  background: var(--surface-elevated);
  transform: translateY(-2px);
}

.page-home .home-archive__desc {
  font-size: var(--text-sm);
  color: var(--text-body);
  line-height: 1.8;
  margin-bottom: 1rem;
}

.page-home .home-archive__image {
  max-width: 100%;
  margin: 0 auto;
}

/* ========== 走势图 ========== */
.page-home .home-trend {
  background: linear-gradient(90deg, rgba(201, 162, 39, 0.06), transparent 60%);
}

.page-home .home-trend__layout {
  display: grid;
  gap: 1.5rem;
}

.page-home .home-trend__lead {
  font-size: var(--text-lg);
  font-weight: 700;
  margin: 0 0 1rem;
}

.page-home .home-trend__list {
  margin: 0 0 1.25rem;
  padding-left: 1.25rem;
  font-size: var(--text-sm);
  color: var(--text-body);
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.page-home .home-trend__note {
  margin: 0.75rem 0 0;
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.page-home .home-trend__image {
  background: var(--surface-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 0.75rem;
}

/* ========== CTA ========== */
.page-home .home-cta {
  padding: clamp(3.5rem, 7vw, 5.5rem) 0;
  background: var(--ink);
  color: var(--paper);
}

.page-home .home-cta__inner {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.page-home .home-cta__inner .section-label {
  color: var(--accent-gold);
}

.page-home .home-cta__title {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 900;
  line-height: 1.2;
  margin: 0;
}

.page-home .home-cta__text {
  font-size: var(--text-sm);
  line-height: 1.8;
  color: rgba(245, 241, 232, 0.78);
  margin: 0;
}

.page-home .home-cta__text--secondary {
  color: rgba(245, 241, 232, 0.55);
  font-size: var(--text-xs);
}

.page-home .home-cta__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  margin-top: 0.75rem;
}

.page-home .home-cta .btn--ghost {
  border-color: rgba(245, 241, 232, 0.5);
  color: var(--paper);
}

.page-home .home-cta .btn--ghost:hover {
  background: rgba(245, 241, 232, 0.12);
  border-color: var(--paper);
}

/* ========== 媒体查询：桌面端 ========== */
@media (min-width: 800px) {
  .page-home .home-rules__panel {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }

  .page-home .home-apple__duo {
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
  }

  .page-home .home-updates__layout {
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
  }

  .page-home .home-archive__layout {
    grid-template-columns: 1fr 300px;
    gap: 2rem;
    align-items: start;
  }

  .page-home .home-trend__layout {
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    gap: 2rem;
    align-items: center;
  }
}

@media (min-width: 900px) {
  .page-home .home-hero__inner {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
    gap: 3rem;
    align-items: start;
  }

  .page-home .home-snapshot {
    position: sticky;
    top: 120px;
  }

  .page-home .home-section__grid {
    grid-template-columns: 220px 1fr;
    gap: 3rem;
    align-items: start;
  }
}
