/* skill 目录 — 分类索引与 hub 布局（与 styles.css 令牌对齐） */
.page-skill-hub {
  --sh-accent: var(--accent-3);
  --sh-accent-soft: var(--accent-soft);
  --sh-line: rgba(100, 130, 200, 0.12);
  --sh-surface: rgba(10, 14, 26, 0.48);
  --sh-glow: rgba(56, 189, 248, 0.2);
}

html[data-theme="light"] .page-skill-hub {
  --sh-accent: var(--accent-3);
  --sh-accent-soft: rgba(8, 145, 178, 0.08);
  --sh-line: rgba(55, 75, 120, 0.12);
  --sh-surface: rgba(255, 255, 255, 0.76);
  --sh-glow: rgba(2, 132, 199, 0.16);
}

.page-skill-hub .case-hub {
  position: relative;
  padding-top: 1.5rem;
  padding-bottom: 4rem;
}

.page-skill-hub .case-hub::before {
  content: "";
  pointer-events: none;
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(900px, 100%);
  height: 320px;
  background: radial-gradient(ellipse 70% 60% at 50% 0%, var(--sh-accent-soft), transparent 65%);
  z-index: 0;
}

.page-skill-hub .case-hub__shell {
  position: relative;
  z-index: 1;
  width: min(1220px, 100% - 3rem);
}

/* Hero */
.page-skill-hub .case-hub__hero {
  margin-bottom: 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--sh-line);
}

.page-skill-hub .case-hub__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--sh-accent);
}

.page-skill-hub .case-hub__eyebrow-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--sh-accent);
  box-shadow: 0 0 12px var(--sh-glow);
  animation: sh-pulse 2.4s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
  .page-skill-hub .case-hub__eyebrow-dot {
    animation: none;
  }
}

.page-skill-hub .case-hub__title {
  margin: 0 0 1rem;
  font-size: clamp(1.85rem, 4vw, 2.35rem);
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 1.15;
  background: linear-gradient(120deg, var(--text) 0%, var(--text) 40%, var(--accent) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

html[data-theme="light"] .page-skill-hub .case-hub__title {
  background: linear-gradient(120deg, var(--text) 0%, var(--text) 35%, var(--accent-3) 95%);
  -webkit-background-clip: text;
  background-clip: text;
}

.page-skill-hub .case-hub__stats {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.75rem;
  margin: 0 0 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
}

.page-skill-hub .case-hub__stats strong {
  color: var(--text);
  font-weight: 600;
}

.page-skill-hub .case-hub__stats-sep {
  opacity: 0.35;
  user-select: none;
}

.page-skill-hub .case-hub__lead {
  display: grid;
  gap: 0.85rem;
}

.page-skill-hub .case-hub__lead p {
  margin: 0;
  font-size: 0.94rem;
  line-height: 1.65;
  color: var(--text-muted);
}

.page-skill-hub .case-hub__lead a {
  color: var(--accent-3);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.page-skill-hub .case-hub__lead a:hover {
  color: var(--accent);
}

/* 分类序号 */
.page-skill-hub .case-hub {
  counter-reset: case-cat;
}

.page-skill-hub .case-hub .skill-index-cat-title {
  display: flex;
  align-items: baseline;
  gap: 0.65rem;
  margin: 0 0 0.65rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.page-skill-hub .case-hub .skill-index-cat-title::before {
  content: counter(case-cat, decimal-leading-zero);
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--sh-accent);
  opacity: 0.85;
}

.page-skill-hub .case-hub .skill-index-cat-title a:hover {
  color: var(--sh-accent);
  text-decoration: none;
}

/* 区块间距 */
.page-skill-hub .case-hub .skill-index-category {
  counter-increment: case-cat;
  margin-bottom: 2.25rem;
  padding-left: 0.25rem;
  border-left: 2px solid transparent;
  transition: border-color 0.2s;
}

.page-skill-hub .case-hub .skill-index-category:hover {
  border-left-color: rgba(56, 189, 248, 0.18);
}

/* 网格：更疏、更扁 */
.page-skill-hub .case-hub .skill-index-category .cat-strip {
  gap: 0.5rem 0.75rem;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}

@media (min-width: 720px) {
  .page-skill-hub .case-hub .skill-index-category .cat-strip {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  }
}

/* 卡片：极简线框 + 微光 */
.page-skill-hub .case-hub .skill-index-category .cat-tile {
  padding: 0.65rem 0.75rem;
  border-radius: 4px;
  background: var(--sh-surface);
  border: 1px solid var(--sh-line);
  border-left: 2px solid rgba(56, 189, 248, 0.15);
  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    box-shadow 0.2s ease;
}

.page-skill-hub .case-hub .skill-index-category .cat-tile:hover {
  border-color: rgba(56, 189, 248, 0.32);
  border-left-color: var(--sh-accent);
  background: var(--accent-soft);
  box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.07);
}

.page-skill-hub .case-hub .skill-index-category .cat-tile h3 {
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.4;
}

.page-skill-hub .case-hub .skill-index-category .cat-tile p {
  margin-top: 0.35rem;
  font-size: 0.7rem;
  line-height: 1.45;
  opacity: 0.92;
  -webkit-line-clamp: 2;
}

.page-skill-hub .case-hub a.cat-tile:focus-visible {
  outline: 2px solid var(--sh-accent);
  outline-offset: 2px;
}

.page-skill-hub .page-first.case-hub {
  padding-top: 1.75rem;
}

.page-skill-hub .case-hub .skill-index-cta {
  margin-top: 2.25rem;
  text-align: center;
}

/* 技能子分类 index：条目详解（与技能中心 case-hub 一致） */
.page-skill-hub .case-hub .skill-sub-index-detail {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--sh-line);
}

.page-skill-hub .case-hub .skill-sub-index-detail > .skill-page-h2 {
  margin-bottom: 1.1rem;
}

.page-skill-hub .case-hub .skill-sub-index-detail__item {
  margin-bottom: 1.5rem;
}

.page-skill-hub .case-hub .skill-sub-index-detail__item:last-child {
  margin-bottom: 0;
}

.page-skill-hub .case-hub .skill-sub-index-detail__item h3 {
  font-size: 0.98rem;
  font-weight: 600;
  margin: 0 0 0.45rem;
  letter-spacing: -0.02em;
  line-height: 1.35;
}

.page-skill-hub .case-hub .skill-sub-index-detail__item h3 a {
  color: var(--text);
  text-decoration: none;
}

.page-skill-hub .case-hub .skill-sub-index-detail__item h3 a:hover {
  color: var(--accent-3);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.page-skill-hub .case-hub .skill-sub-index-detail__item p {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.65;
  color: var(--text-muted);
}
