.page-services {
  --svc-ink-dim: color-mix(in srgb, var(--color-contrast-ink) 72%, transparent);
}

/* ---------- 首屏 ---------- */
.page-services .services-hero {
  position: relative;
  overflow: hidden;
}

.page-services .services-hero::after {
  content: "";
  position: absolute;
  top: calc(-1 * var(--space-8));
  right: calc(-1 * var(--space-8));
  width: clamp(220px, 40vw, 520px);
  aspect-ratio: 1;
  border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--color-primary) 20%, transparent);
  pointer-events: none;
}

.page-services .services-hero__intro {
  position: relative;
  z-index: 1;
}

.page-services .services-hero__title {
  margin-top: var(--space-2);
  font-family: var(--font-heading);
  font-size: var(--text-display);
  font-weight: var(--weight-heading);
  line-height: var(--leading-heading);
  letter-spacing: var(--tracking-heading);
  color: var(--color-ink);
  max-width: 18ch;
}

.page-services .services-hero__lede {
  margin-top: var(--space-3);
  max-width: var(--measure);
  color: var(--color-ink-soft);
}

.page-services .services-stat-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-3);
  margin-top: var(--space-6);
  padding-top: var(--space-4);
  border-top: 1px solid var(--color-line);
}

.page-services .services-stat {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  min-width: 0;
}

.page-services .services-stat .stat-figure {
  font-family: var(--font-mono);
  font-size: var(--text-figure);
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--color-primary);
}

.page-services .services-stat__label {
  font-size: var(--text-sm);
  line-height: var(--leading-body);
  color: var(--color-ink-muted);
}

.page-services .services-hero__cards {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-3);
  margin-top: var(--space-6);
}

.page-services .services-hero-card {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  padding: var(--space-3);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  box-shadow: var(--shadow-1);
  transition: transform 260ms ease, box-shadow 260ms ease, border-color 260ms ease;
}

.page-services .services-hero-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-2);
  border-color: color-mix(in srgb, var(--color-primary) 40%, var(--color-line));
}

.page-services .services-hero-card__title {
  font-family: var(--font-heading);
  font-size: var(--text-xl);
  font-weight: var(--weight-heading);
  line-height: var(--leading-heading);
  color: var(--color-ink);
}

.page-services .services-hero-card__text {
  flex: 1;
  font-size: var(--text-base);
  line-height: var(--leading-body);
  color: var(--color-ink-soft);
}

.page-services .services-hero-card__link {
  align-self: flex-start;
  font-size: var(--text-sm);
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.page-services .services-hero__band {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-3);
  margin-top: var(--space-6);
  padding: var(--space-3);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  background: var(--color-primary-soft);
}

.page-services .services-hero__band p {
  max-width: var(--measure);
  font-size: var(--text-base);
  line-height: var(--leading-body);
  color: var(--color-ink);
}

/* ---------- 通用区头 ---------- */
.page-services .services-section-head {
  max-width: var(--measure);
  margin-bottom: var(--space-6);
}

.page-services .services-section-head__title {
  margin-top: var(--space-2);
  font-family: var(--font-heading);
  font-size: var(--text-3xl);
  font-weight: var(--weight-heading);
  line-height: var(--leading-heading);
  letter-spacing: var(--tracking-heading);
  color: var(--color-ink);
}

.page-services .services-section-head .lede {
  margin-top: var(--space-2);
  color: var(--color-ink-soft);
}

.page-services .services-section-head--dark .services-section-head__title {
  color: var(--color-contrast-ink);
}

.page-services .services-section-head--dark .lede {
  color: var(--svc-ink-dim);
}

/* ---------- 三类方案大卡 ---------- */
.page-services .services-cat {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: flex-end;
  min-height: 400px;
  overflow: hidden;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-1);
}

.page-services .services-cat + .services-cat {
  margin-top: var(--space-6);
}

.page-services .services-cat__bg {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.page-services .services-cat__scrim {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--overlay-scrim);
}

.page-services .services-cat__body {
  position: relative;
  width: 100%;
  padding: var(--space-4) var(--space-3);
  color: var(--color-contrast-ink);
}

.page-services .services-cat__title {
  margin-top: var(--space-2);
  font-family: var(--font-heading);
  font-size: var(--text-2xl);
  font-weight: var(--weight-heading);
  line-height: var(--leading-heading);
  color: var(--color-contrast-ink);
}

.page-services .services-cat__lede {
  margin-top: var(--space-2);
  max-width: var(--measure);
  font-size: var(--text-base);
  line-height: var(--leading-body);
  color: var(--color-contrast-ink);
}

.page-services .services-cat__specs {
  display: grid;
  gap: var(--space-3);
  margin-top: var(--space-4);
}

.page-services .services-cat__specs dt {
  padding-bottom: var(--space-1);
  border-bottom: 1px solid var(--color-contrast-line);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.08em;
  color: var(--svc-ink-dim);
}

.page-services .services-cat__specs dd {
  margin-top: var(--space-2);
  font-size: var(--text-sm);
  line-height: var(--leading-body);
  color: var(--color-contrast-ink);
}

/* ---------- 编号关系图 ---------- */
.page-services .services-code-map {
  display: block;
  width: 100%;
  max-width: 520px;
  height: auto;
  margin-top: var(--space-4);
}

.page-services .services-code-map__rail {
  stroke: var(--color-contrast-line);
  stroke-width: 1;
}

.page-services .services-code-map__node circle {
  fill: var(--color-contrast-surface);
  stroke: var(--color-contrast-accent);
  stroke-width: 1.5;
  transition: fill 240ms ease;
}

.page-services .services-code-map__node text {
  fill: var(--color-contrast-ink);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  text-anchor: middle;
}

.page-services .services-code-map__node .services-code-map__sub {
  fill: var(--svc-ink-dim);
}

.page-services .services-code-map__node:hover circle {
  fill: var(--color-contrast-accent);
}

/* ---------- 八项能力 ---------- */
.page-services .services-skills .filter-bar {
  margin-bottom: var(--space-2);
}

.page-services .services-skills .filter-status {
  margin-bottom: var(--space-4);
  min-height: 1.4em;
  font-size: var(--text-sm);
  color: var(--color-ink-muted);
}

.page-services .services-skill-group + .services-skill-group {
  margin-top: var(--space-8);
}

.page-services .services-skill-group__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--space-2);
  padding-bottom: var(--space-2);
  border-bottom: 1px solid var(--color-line);
}

.page-services .services-skill-group__title {
  font-family: var(--font-heading);
  font-size: var(--text-xl);
  font-weight: var(--weight-heading);
  line-height: var(--leading-heading);
  color: var(--color-ink);
}

.page-services .services-skill-group__note {
  font-size: var(--text-sm);
  color: var(--color-ink-muted);
}

.page-services .services-skill-group__figure {
  margin-top: var(--space-3);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--color-surface-deep);
}

.page-services .services-skill-group__figure img {
  display: block;
  width: 100%;
  max-height: 260px;
  height: auto;
  object-fit: cover;
}

.page-services .services-skill-group__figure figcaption {
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-sm);
  line-height: var(--leading-body);
  color: var(--color-ink-muted);
}

.page-services .services-skill-list {
  display: grid;
  gap: var(--space-3);
  margin-top: var(--space-3);
}

.page-services .services-skill {
  padding: var(--space-3);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  transition: background-color 260ms ease, border-color 260ms ease, box-shadow 260ms ease, transform 260ms ease;
}

.page-services .services-skill:hover {
  background: var(--color-primary-soft);
  border-color: color-mix(in srgb, var(--color-primary) 42%, var(--color-line));
  box-shadow: var(--shadow-1);
}

.page-services .services-skill__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
}

.page-services .services-skill__title {
  margin-right: auto;
  font-family: var(--font-heading);
  font-size: var(--text-lg);
  font-weight: var(--weight-heading);
  line-height: var(--leading-heading);
  color: var(--color-ink);
}

.page-services .services-skill__specs {
  display: grid;
  gap: var(--space-2);
  margin-top: var(--space-3);
  padding-top: var(--space-3);
  border-top: 1px solid var(--color-line);
}

.page-services .services-skill__spec dt {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.08em;
  color: var(--color-ink-muted);
}

.page-services .services-skill__spec dd {
  margin-top: var(--space-1);
  font-size: var(--text-sm);
  line-height: var(--leading-body);
  color: var(--color-ink);
}

/* ---------- 不接范围 ---------- */
.page-services .services-limits__list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--color-contrast-line);
}

.page-services .services-limits__list li {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--space-3);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--color-contrast-line);
}

.page-services .services-limits__num {
  padding-top: 2px;
  font-size: var(--text-sm);
  color: var(--color-contrast-accent);
}

.page-services .services-limits__list h3 {
  font-family: var(--font-heading);
  font-size: var(--text-lg);
  font-weight: var(--weight-heading);
  line-height: var(--leading-heading);
  color: var(--color-contrast-ink);
}

.page-services .services-limits__list p {
  margin-top: var(--space-1);
  max-width: var(--measure);
  font-size: var(--text-base);
  line-height: var(--leading-body);
  color: var(--svc-ink-dim);
}

/* ---------- 行动出口 ---------- */
.page-services .services-outro__panel {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-1);
}

.page-services .services-outro__bg {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.page-services .services-outro__scrim {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--overlay-scrim);
}

.page-services .services-outro__body {
  padding: var(--space-6) var(--space-3);
  color: var(--color-contrast-ink);
}

.page-services .services-outro__eyebrow {
  color: var(--color-contrast-accent);
}

.page-services .services-outro__title {
  margin-top: var(--space-2);
  font-family: var(--font-heading);
  font-size: var(--text-3xl);
  font-weight: var(--weight-heading);
  line-height: var(--leading-heading);
  letter-spacing: var(--tracking-heading);
  color: var(--color-contrast-ink);
}

.page-services .services-outro__text {
  margin-top: var(--space-3);
  max-width: var(--measure);
  font-size: var(--text-base);
  line-height: var(--leading-body);
  color: var(--color-contrast-ink);
}

.page-services .services-outro__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-4);
}

.page-services .services-outro__body .btn--ghost {
  background: transparent;
  color: var(--color-contrast-ink);
  border: 1px solid color-mix(in srgb, var(--color-contrast-ink) 42%, transparent);
}

.page-services .services-outro__body .btn--ghost:hover {
  background: color-mix(in srgb, var(--color-contrast-ink) 14%, transparent);
}

.page-services .services-outro__aside {
  margin-top: var(--space-4);
  font-size: var(--text-sm);
  line-height: var(--leading-body);
  color: var(--svc-ink-dim);
}

.page-services .services-outro__aside a {
  color: var(--color-contrast-accent);
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* ---------- 响应式 ---------- */
@media (min-width: 720px) {
  .page-services .services-stat-row {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: var(--space-4);
  }

  .page-services .services-hero__band {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-3) var(--space-4);
  }

  .page-services .services-cat {
    min-height: 440px;
  }

  .page-services .services-cat__body {
    padding: var(--space-6) var(--space-4);
  }

  .page-services .services-cat__specs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--space-4);
  }

  .page-services .services-outro__body {
    max-width: 740px;
    padding: var(--space-8) var(--space-6);
  }
}

@media (min-width: 780px) {
  .page-services .services-skill__specs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--space-4);
  }
}

@media (min-width: 900px) {
  .page-services .services-hero__cards {
    grid-template-columns: 1.5fr 1fr 1.15fr;
    align-items: end;
    gap: var(--space-4);
  }

  .page-services .services-hero-card {
    padding: var(--space-4);
  }

  .page-services .services-hero-card--wide {
    min-height: 250px;
  }

  .page-services .services-hero-card--mid {
    min-height: 208px;
  }

  .page-services .services-hero-card--tall {
    min-height: 330px;
  }

  .page-services .services-skill-list {
    gap: var(--space-2);
  }

  .page-services .services-skill:hover {
    transform: translateX(4px);
  }
}
