.page-faq {
  --faq-num-w: 44px;
  --faq-rail-w: 208px;
  --faq-answer-shift: 56px;

  background: var(--ink);
  color: var(--paper);
  overflow-x: clip;
}

/* ---------- Hero ---------- */

.page-faq .faq-hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(120% 95% at 8% 4%, rgba(198, 255, 62, .11), transparent 58%),
    radial-gradient(95% 85% at 96% 98%, rgba(255, 107, 26, .11), transparent 60%),
    var(--ink);
}

.page-faq .faq-hero::after {
  content: "";
  position: absolute;
  top: -30%;
  right: -12%;
  width: 46%;
  height: 150%;
  background: linear-gradient(160deg, rgba(62, 208, 196, .10), transparent 62%);
  transform: skewX(-14deg);
  pointer-events: none;
}

.page-faq .faq-hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(26px, 4vw, 48px);
  padding-top: clamp(26px, 4.5vw, 52px);
  padding-bottom: clamp(36px, 6vw, 76px);
}

.page-faq .faq-hero-copy {
  min-width: 0;
}

.page-faq .faq-hero-title {
  margin: 14px 0 0;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(34px, 6.6vw, 68px);
  line-height: 1.02;
  letter-spacing: -.022em;
  color: var(--paper);
}

.page-faq .faq-hero-lede {
  max-width: 34em;
  margin: 18px 0 0;
  font-size: clamp(15px, 1.4vw, 17px);
  line-height: 1.75;
  color: var(--silver);
}

.page-faq .faq-hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}

.page-faq .faq-hero-media {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  background: var(--moss);
  clip-path: polygon(0 0, 100% 0, 100% 86%, 88% 100%, 0 100%);
}

.page-faq .faq-hero-media img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  filter: saturate(.82) contrast(1.06);
}

.page-faq .faq-hero-media::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 52%;
  height: 3px;
  background: linear-gradient(90deg, var(--lime), rgba(198, 255, 62, 0));
  pointer-events: none;
}

@media (min-width: 900px) {
  .page-faq .faq-hero-inner {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.04fr);
    align-items: center;
  }

  .page-faq .faq-hero-media {
    order: -1;
  }
}

/* ---------- 速查表 ---------- */

.page-faq .faq-quick-wrap {
  padding: clamp(28px, 4vw, 48px) 0 clamp(8px, 1.5vw, 16px);
  background: var(--charcoal);
  border-bottom: 1px solid var(--line);
}

.page-faq .faq-quick-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px 18px;
  margin-bottom: 12px;
}

.page-faq .faq-quick-title {
  margin: 0;
  font-size: clamp(18px, 2vw, 22px);
  font-weight: 800;
  letter-spacing: -.01em;
}

.page-faq .faq-quick-note {
  margin: 0;
  font-size: 12px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--silver);
}

.page-faq .faq-quick {
  border: 1px solid var(--line-strong);
  background: rgba(10, 31, 25, .72);
  overflow: hidden;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 20px), calc(100% - 20px) 100%, 0 100%);
}

.page-faq .faq-quick table {
  width: 100%;
  min-width: 520px;
  border-collapse: collapse;
}

.page-faq .faq-quick th {
  padding: 11px 16px;
  background: var(--lime);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  text-align: left;
}

.page-faq .faq-quick td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--line);
  font-size: 14.5px;
  line-height: 1.5;
  vertical-align: top;
}

.page-faq .faq-quick td:first-child {
  color: var(--silver);
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0;
  white-space: nowrap;
}

.page-faq .faq-quick tbody tr {
  transition: background .2s var(--ease);
}

.page-faq .faq-quick tbody tr:hover {
  background: rgba(198, 255, 62, .07);
}

.page-faq .faq-quick tbody tr:hover td:first-child {
  box-shadow: inset 3px 0 0 var(--lime);
  color: var(--paper);
}

.page-faq .faq-quick tbody tr:last-child td {
  border-bottom: 0;
}

.page-faq .faq-quick-scroll {
  overflow-x: auto;
}

/* ---------- 主体布局 ---------- */

.page-faq .faq-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(24px, 3vw, 52px);
  padding-top: clamp(36px, 5vw, 76px);
  padding-bottom: clamp(48px, 7vw, 96px);
}

.page-faq .faq-rail {
  position: sticky;
  top: var(--header-h);
  z-index: 4;
  margin: 0 calc(var(--shell-pad) * -1);
  padding: 10px var(--shell-pad);
  background: rgba(10, 31, 25, .94);
  border-bottom: 1px solid var(--line);
}

.page-faq .faq-rail-title {
  display: none;
}

.page-faq .faq-rail-list {
  display: flex;
  gap: 8px;
  margin: 0;
  padding: 0 0 2px;
  list-style: none;
  overflow-x: auto;
  scrollbar-width: none;
}

.page-faq .faq-rail-list::-webkit-scrollbar {
  display: none;
}

.page-faq .faq-rail-link {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  padding: 7px 12px;
  border: 1px solid var(--line-strong);
  background: var(--moss);
  color: var(--silver);
  font-size: 13.5px;
  line-height: 1.4;
  white-space: nowrap;
  text-decoration: none;
  clip-path: polygon(0 0, 100% 0, 100% 68%, calc(100% - 9px) 100%, 0 100%);
  transition: color .2s var(--ease), border-color .2s var(--ease), background .2s var(--ease);
}

.page-faq .faq-rail-link:hover,
.page-faq .faq-rail-link:focus-visible {
  color: var(--paper);
  border-color: var(--lime);
}

.page-faq .faq-rail-num {
  font-size: 11px;
  color: var(--lime);
}

.page-faq .faq-body {
  min-width: 0;
  max-width: 720px;
}

@media (min-width: 1000px) {
  .page-faq .faq-layout {
    grid-template-columns: var(--faq-rail-w) minmax(0, 1fr);
    align-items: start;
  }

  .page-faq .faq-rail {
    position: sticky;
    top: calc(var(--header-h-slim) + 26px);
    margin: 0;
    padding: 0;
    background: none;
    border-bottom: 0;
  }

  .page-faq .faq-rail-title {
    display: block;
    margin: 0 0 12px;
    font-size: 11px;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--lime);
  }

  .page-faq .faq-rail-list {
    flex-direction: column;
    gap: 0;
    overflow: visible;
  }

  .page-faq .faq-rail-link {
    display: flex;
    width: 100%;
    padding: 9px 0 9px 15px;
    border: 0;
    border-left: 1px solid var(--line-strong);
    background: none;
    color: var(--silver);
    white-space: normal;
    text-decoration: none;
    clip-path: none;
  }

  .page-faq .faq-rail-link:hover,
  .page-faq .faq-rail-link:focus-visible {
    color: var(--paper);
    border-left-color: var(--line-strong);
    background: none;
  }

  .page-faq .faq-rail-link[data-active="true"] {
    color: var(--paper);
    border-left-color: var(--lime);
  }
}

/* ---------- 章节 ---------- */

.page-faq .faq-section {
  padding-top: clamp(32px, 4.5vw, 56px);
  scroll-margin-top: calc(var(--header-h) + 76px);
}

.page-faq .faq-section:first-child {
  padding-top: 0;
}

.page-faq .faq-section-head {
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding-top: 16px;
  border-top: 1px solid var(--line-strong);
}

.page-faq .faq-section-index {
  font-size: clamp(26px, 4vw, 38px);
  font-weight: 700;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px var(--lime);
}

.page-faq .faq-section-title {
  margin: 0;
  font-size: clamp(19px, 2.3vw, 25px);
  font-weight: 800;
  letter-spacing: -.012em;
  color: var(--paper);
}

.page-faq .faq-section-lede {
  max-width: 34em;
  margin: 10px 0 6px;
  font-size: 14.5px;
  line-height: 1.75;
  color: var(--silver);
}

/* ---------- 折叠条目 ---------- */

.page-faq .faq-item {
  border-bottom: 1px solid var(--line);
  transition: background .24s var(--ease), box-shadow .24s var(--ease);
}

.page-faq .faq-item[open] {
  background: rgba(22, 51, 43, .5);
  box-shadow: inset 3px 0 0 var(--lime);
}

.page-faq .faq-q {
  display: grid;
  grid-template-columns: var(--faq-num-w) minmax(0, 1fr) 14px;
  align-items: baseline;
  gap: 12px;
  padding: 16px 6px 16px 0;
  cursor: pointer;
  list-style: none;
  color: var(--silver);
  transition: color .2s var(--ease);
}

.page-faq .faq-q::-webkit-details-marker {
  display: none;
}

.page-faq .faq-q:hover,
.page-faq .faq-q:focus-visible {
  color: var(--paper);
}

.page-faq .faq-item[open] .faq-q {
  color: var(--paper);
}

.page-faq .faq-num {
  font-size: 12px;
  line-height: 1.6;
  color: var(--silver);
  transition: color .2s var(--ease);
}

.page-faq .faq-item[open] .faq-num {
  color: var(--lime);
}

.page-faq .faq-q-text {
  font-size: clamp(15.5px, 1.5vw, 17px);
  font-weight: 600;
  line-height: 1.55;
}

.page-faq .faq-mark {
  position: relative;
  display: block;
  width: 14px;
  height: 14px;
  align-self: center;
}

.page-faq .faq-mark::before,
.page-faq .faq-mark::after {
  content: "";
  position: absolute;
  background: var(--silver);
  transition: transform .24s var(--ease), background .24s var(--ease);
}

.page-faq .faq-mark::before {
  left: 0;
  right: 0;
  top: 6px;
  height: 2px;
}

.page-faq .faq-mark::after {
  top: 0;
  bottom: 0;
  left: 6px;
  width: 2px;
}

.page-faq .faq-item[open] .faq-mark::before {
  background: var(--lime);
}

.page-faq .faq-item[open] .faq-mark::after {
  transform: scaleY(0);
}

.page-faq .faq-a {
  padding: 0 6px 22px var(--faq-answer-shift);
}

.page-faq .faq-a p {
  max-width: 34em;
  margin: 0;
  font-size: 15px;
  line-height: 1.78;
  color: var(--silver);
  transition: color .24s var(--ease);
}

.page-faq .faq-item[open] .faq-a p {
  color: rgba(243, 239, 227, .84);
}

.page-faq .faq-a a {
  color: var(--lime);
  text-decoration: none;
  border-bottom: 1px solid rgba(198, 255, 62, .45);
  transition: border-color .2s var(--ease);
}

.page-faq .faq-a a:hover,
.page-faq .faq-a a:focus-visible {
  border-bottom-color: var(--lime);
}

/* ---------- 章节内嵌图 ---------- */

.page-faq .faq-figure {
  position: relative;
  margin: 6px 0 22px;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  background: var(--moss);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 26px), calc(100% - 26px) 100%, 0 100%);
}

.page-faq .faq-figure img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  filter: saturate(.86) contrast(1.05);
}

.page-faq .faq-figure figcaption {
  padding: 10px 16px 14px;
  font-size: 12px;
  line-height: 1.6;
  letter-spacing: .04em;
  color: var(--silver);
  border-top: 1px solid var(--line);
}

@media (min-width: 640px) {
  .page-faq .faq-figure img {
    aspect-ratio: 16 / 9;
  }
}

/* ---------- 收尾 ---------- */

.page-faq .faq-closing {
  position: relative;
  border-top: 1px solid var(--line-strong);
  background:
    radial-gradient(90% 120% at 88% 0%, rgba(255, 107, 26, .13), transparent 58%),
    var(--charcoal);
}

.page-faq .faq-closing::before {
  content: "";
  position: absolute;
  left: var(--shell-pad);
  top: -1px;
  width: 84px;
  height: 4px;
  background: var(--lime);
}

.page-faq .faq-closing-inner {
  padding-top: clamp(40px, 6vw, 76px);
  padding-bottom: clamp(44px, 6vw, 80px);
}

.page-faq .faq-closing-title {
  margin: 12px 0 0;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(24px, 3.6vw, 40px);
  line-height: 1.08;
  letter-spacing: -.02em;
}

.page-faq .faq-closing-lede {
  max-width: 34em;
  margin: 16px 0 0;
  font-size: 15.5px;
  line-height: 1.78;
  color: var(--silver);
}

.page-faq .faq-closing-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

@media (prefers-reduced-motion: reduce) {
  .page-faq .faq-item,
  .page-faq .faq-q,
  .page-faq .faq-num,
  .page-faq .faq-a p,
  .page-faq .faq-mark::before,
  .page-faq .faq-mark::after,
  .page-faq .faq-rail-link,
  .page-faq .faq-quick tbody tr {
    transition: none;
  }
}
