/* ===== 问题排查 · page-faq ===== */
.page-faq {
  --faq-rule: rgba(42, 31, 26, 0.16);
  --faq-rule-strong: rgba(42, 31, 26, 0.34);
  --faq-surface: #FFFFFF;
  --faq-gutter: 20px;
  background: var(--bw-cream);
  color: var(--bw-ink);
}

.page-faq .faq-sr,
.page-faq .bw-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- 面包屑 ---------- */
.page-faq .faq-crumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 1220px;
  margin: 0 auto;
  padding: 16px var(--faq-gutter) 0;
  font-family: var(--bw-font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: rgba(42, 31, 26, 0.62);
}

.page-faq .faq-crumb a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.16s ease, color 0.16s ease;
}

.page-faq .faq-crumb a:hover {
  color: var(--bw-orange);
  border-bottom-color: var(--bw-orange);
}

.page-faq .faq-crumb__sep {
  color: var(--bw-silver);
}

/* ---------- 首屏 ---------- */
.page-faq .faq-hero {
  position: relative;
  margin-top: 14px;
  padding: clamp(48px, 8vw, 96px) 0 clamp(36px, 5vw, 64px);
  background: var(--bw-inkblue);
  color: var(--bw-cream);
  overflow: hidden;
}

.page-faq .faq-hero::after {
  content: "";
  position: absolute;
  right: -70px;
  bottom: -100px;
  width: 280px;
  height: 280px;
  background: var(--bw-orange);
  opacity: 0.13;
  transform: rotate(45deg);
  z-index: 1;
  pointer-events: none;
}

.page-faq .faq-hero__media {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.page-faq .faq-hero__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.26;
}

.page-faq .faq-hero__inner {
  position: relative;
  z-index: 2;
  max-width: 1220px;
  margin: 0 auto;
  padding: 0 var(--faq-gutter);
}

.page-faq .faq-hero .bw-eyebrow {
  color: var(--bw-orange);
}

.page-faq .faq-hero .bw-title--xl {
  margin: 14px 0 0;
  max-width: 16em;
  color: var(--bw-cream);
}

.page-faq .faq-hero .bw-lede {
  margin: 20px 0 0;
  max-width: 58ch;
  color: rgba(245, 239, 227, 0.84);
}

.page-faq .faq-hero__stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1px;
  margin: 34px 0 0;
  padding: 1px;
  background: rgba(201, 210, 220, 0.22);
  border: 1px solid rgba(201, 210, 220, 0.22);
}

.page-faq .faq-hero__stats > div {
  background: rgba(7, 20, 38, 0.82);
  padding: 16px 18px;
}

.page-faq .faq-hero__stats dt {
  margin: 0;
  font-family: var(--bw-font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  color: rgba(201, 210, 220, 0.72);
}

.page-faq .faq-hero__stats dd {
  margin: 8px 0 0;
  font-family: var(--bw-font-display);
  font-weight: 900;
  font-style: italic;
  font-size: clamp(19px, 2.6vw, 26px);
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--bw-cream);
}

.page-faq .faq-hero__stats .bw-num {
  font-family: var(--bw-font-mono);
  font-style: normal;
  color: var(--bw-orange);
}

/* ---------- 热门问题速查 ---------- */
.page-faq .faq-hot {
  background: var(--bw-cream);
}

.page-faq .faq-hot__head {
  margin-bottom: 26px;
}

.page-faq .faq-hot__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.page-faq .faq-hot__card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 22px 22px 26px;
  background: var(--faq-surface);
  border: 2px solid var(--bw-ink);
  color: var(--bw-ink);
  text-decoration: none;
  overflow: hidden;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.page-faq .faq-hot__card::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, transparent 50%, var(--bw-orange) 50%);
  opacity: 0;
  transition: opacity 0.18s ease;
}

.page-faq .faq-hot__card:hover,
.page-faq .faq-hot__card:focus-visible {
  transform: translateY(-3px);
  border-color: var(--bw-orange);
  box-shadow: 0 16px 30px rgba(7, 20, 38, 0.18);
  outline: none;
}

.page-faq .faq-hot__card:hover::after,
.page-faq .faq-hot__card:focus-visible::after {
  opacity: 1;
}

.page-faq .faq-hot__card h3 {
  margin: 0;
  font-family: var(--bw-font-display);
  font-weight: 900;
  font-style: italic;
  font-size: clamp(16px, 1.6vw, 20px);
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--bw-navy);
}

.page-faq .faq-hot__card p {
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
  color: rgba(42, 31, 26, 0.74);
}

.page-faq .faq-hot__go {
  margin-top: auto;
  padding-top: 12px;
  font-family: var(--bw-font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--bw-orange);
}

.page-faq .faq-hot__go::after {
  content: " ↓";
}

/* ---------- 排查工作台 ---------- */
.page-faq .faq-workbench {
  background: var(--bw-cream);
}

.page-faq .faq-desk {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
}

.page-faq .faq-desk__main {
  min-width: 0;
}

/* 主题索引 */
.page-faq .faq-index {
  align-self: start;
}

.page-faq .faq-index__title {
  margin: 0 0 12px;
  font-family: var(--bw-font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  color: rgba(42, 31, 26, 0.6);
}

.page-faq .faq-index__list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--faq-rule-strong);
}

.page-faq .faq-index__list li {
  border-bottom: 1px solid var(--faq-rule);
}

.page-faq .faq-index__list a {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 12px 4px;
  color: var(--bw-ink);
  text-decoration: none;
  font-size: 14px;
  line-height: 1.5;
  transition: color 0.15s ease, padding-left 0.15s ease;
}

.page-faq .faq-index__list a:hover,
.page-faq .faq-index__list a:focus-visible {
  color: var(--bw-orange);
  padding-left: 9px;
  outline: none;
}

.page-faq .faq-index__n {
  font-family: var(--bw-font-mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--bw-orange);
  letter-spacing: 0.04em;
}

.page-faq .faq-index__note {
  margin-top: 22px;
  padding: 16px 16px 18px;
  background: var(--bw-navy);
  border-left: 4px solid var(--bw-orange);
  color: var(--bw-cream);
}

.page-faq .faq-index__note-k {
  margin: 0;
  font-family: var(--bw-font-display);
  font-weight: 900;
  font-style: italic;
  font-size: 15px;
  letter-spacing: -0.01em;
}

.page-faq .faq-index__note-v {
  margin: 8px 0 14px;
  font-size: 13px;
  line-height: 1.7;
  color: rgba(245, 239, 227, 0.78);
}

/* ---------- 主题与问答 ---------- */
.page-faq .faq-topic {
  scroll-margin-top: calc(var(--bw-bar-h) + 24px);
  padding-top: 20px;
  border-top: 4px solid var(--bw-navy);
}

.page-faq .faq-topic + .faq-topic {
  margin-top: 52px;
}

.page-faq .faq-topic__head {
  margin-bottom: 20px;
}

.page-faq .faq-topic__title {
  margin: 12px 0 0;
  font-family: var(--bw-font-display);
  font-weight: 900;
  font-style: italic;
  font-size: clamp(24px, 3.2vw, 34px);
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--bw-navy);
}

.page-faq .faq-topic__desc {
  margin: 12px 0 0;
  max-width: 62ch;
  font-size: 15px;
  line-height: 1.75;
  color: rgba(42, 31, 26, 0.74);
}

.page-faq .faq-fig {
  margin: 0 0 20px;
  background: var(--bw-navy);
  border: 1px solid var(--bw-navy);
}

.page-faq .faq-fig img {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
  object-fit: cover;
}

.page-faq .faq-fig figcaption {
  padding: 10px 14px;
  font-family: var(--bw-font-mono);
  font-size: 11px;
  line-height: 1.6;
  letter-spacing: 0.05em;
  color: rgba(245, 239, 227, 0.72);
}

.page-faq .faq-q {
  margin-bottom: 10px;
  background: var(--faq-surface);
  border: 1px solid var(--faq-rule);
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.page-faq .faq-q[open] {
  border-color: var(--bw-orange);
  box-shadow: 0 14px 30px rgba(7, 20, 38, 0.09);
}

.page-faq .faq-q > summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  cursor: pointer;
  list-style: none;
  font-family: var(--bw-font-body);
  font-weight: 700;
  font-size: 15px;
  line-height: 1.5;
  color: var(--bw-ink);
}

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

.page-faq .faq-q > summary::marker {
  content: "";
}

.page-faq .faq-q > summary:focus-visible {
  outline: 2px solid var(--bw-orange);
  outline-offset: -2px;
}

.page-faq .faq-q__n {
  font-family: var(--bw-font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--bw-orange);
}

.page-faq .faq-q__t {
  min-width: 0;
}

.page-faq .faq-q__ico {
  position: relative;
  width: 16px;
  height: 16px;
  flex: none;
}

.page-faq .faq-q__ico::before,
.page-faq .faq-q__ico::after {
  content: "";
  position: absolute;
  background: var(--bw-orange);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.page-faq .faq-q__ico::before {
  left: 0;
  top: 7px;
  width: 16px;
  height: 2px;
}

.page-faq .faq-q__ico::after {
  left: 7px;
  top: 0;
  width: 2px;
  height: 16px;
}

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

.page-faq .faq-q__a {
  padding: 16px 18px 20px;
  border-top: 1px solid var(--faq-rule);
  font-size: 14.5px;
  line-height: 1.78;
  color: rgba(42, 31, 26, 0.84);
}

.page-faq .faq-q__a p {
  margin: 0 0 10px;
}

.page-faq .faq-q__a p:last-child {
  margin-bottom: 0;
}

.page-faq .faq-q__a a {
  color: var(--bw-navy);
  text-decoration: none;
  border-bottom: 1px solid var(--bw-orange);
  transition: color 0.15s ease;
}

.page-faq .faq-q__a a:hover {
  color: var(--bw-orange);
}

.page-faq .faq-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: fstep;
}

.page-faq .faq-steps li {
  position: relative;
  padding-left: 32px;
  margin-bottom: 10px;
  counter-increment: fstep;
}

.page-faq .faq-steps li:last-child {
  margin-bottom: 0;
}

.page-faq .faq-steps li::before {
  content: counter(fstep, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 3px;
  font-family: var(--bw-font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--bw-orange);
}

/* ---------- 工单区 ---------- */
.page-faq .faq-ticket {
  background: var(--bw-navy);
  color: var(--bw-cream);
}

.page-faq .faq-ticket__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
}

.page-faq .faq-ticket__intro {
  min-width: 0;
}

.page-faq .faq-ticket .bw-title {
  color: var(--bw-cream);
}

.page-faq .faq-ticket .bw-lede {
  margin: 16px 0 0;
  max-width: 56ch;
  color: rgba(245, 239, 227, 0.82);
}

.page-faq .faq-ticket__panel {
  padding: 22px 20px;
  background: rgba(7, 20, 38, 0.5);
  border: 1px solid rgba(201, 210, 220, 0.24);
  border-top: 3px solid var(--bw-orange);
}

.page-faq .faq-ticket__panel-title {
  margin: 0 0 16px;
  font-family: var(--bw-font-display);
  font-weight: 900;
  font-style: italic;
  font-size: 18px;
  letter-spacing: -0.01em;
  color: var(--bw-cream);
}

.page-faq .faq-ticket__list {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
}

.page-faq .faq-ticket__list li {
  display: flex;
  gap: 12px;
  align-items: baseline;
  padding: 10px 0;
  border-bottom: 1px solid rgba(201, 210, 220, 0.18);
  font-size: 14px;
  line-height: 1.65;
  color: rgba(245, 239, 227, 0.9);
}

.page-faq .faq-ticket__list li:last-child {
  border-bottom: 0;
}

.page-faq .faq-ticket__n {
  font-family: var(--bw-font-mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--bw-orange);
  letter-spacing: 0.05em;
}

.page-faq .faq-ticket__acts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.page-faq .faq-ticket .bw-btn--ghost {
  color: var(--bw-cream);
  border-color: rgba(245, 239, 227, 0.45);
}

.page-faq .faq-ticket .bw-btn--ghost:hover {
  border-color: var(--bw-orange);
  color: var(--bw-orange);
}

.page-faq .faq-ticket__meta {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1px;
  margin: 34px 0 0;
  padding: 1px;
  background: rgba(201, 210, 220, 0.2);
  border: 1px solid rgba(201, 210, 220, 0.2);
}

.page-faq .faq-ticket__meta > div {
  background: rgba(11, 31, 58, 0.9);
  padding: 16px 18px;
}

.page-faq .faq-ticket__meta dt {
  margin: 0 0 6px;
  font-family: var(--bw-font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  color: rgba(201, 210, 220, 0.7);
}

.page-faq .faq-ticket__meta dd {
  margin: 0;
  font-family: var(--bw-font-mono);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--bw-cream);
  overflow-wrap: anywhere;
}

/* ---------- 回到顶部 ---------- */
.page-faq .faq-totop {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 40;
  display: inline-flex;
  align-items: center;
  padding: 10px 14px;
  background: var(--bw-navy);
  color: var(--bw-cream);
  border: 1px solid var(--bw-orange);
  font-family: var(--bw-font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-decoration: none;
  transition: background 0.16s ease, color 0.16s ease;
}

.page-faq .faq-totop:hover,
.page-faq .faq-totop:focus-visible {
  background: var(--bw-orange);
  color: var(--bw-inkblue);
  outline: none;
}

/* ---------- 窄屏适配 ---------- */
@media (max-width: 639px) {
  .page-faq .faq-index__list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .page-faq .faq-index__list li:first-child {
    border-top: 0;
  }

  .page-faq .faq-index__list a {
    padding: 11px 4px;
    font-size: 13px;
  }

  .page-faq .faq-q > summary {
    gap: 10px;
    padding: 14px 14px;
    font-size: 14.5px;
  }

  .page-faq .faq-q__a {
    padding: 14px 14px 18px;
    font-size: 14px;
  }

  .page-faq .faq-steps li {
    padding-left: 28px;
  }

  .page-faq .faq-totop {
    right: 12px;
    bottom: 12px;
    padding: 9px 12px;
    font-size: 10px;
  }
}

/* ---------- 桌面栅格 ---------- */
@media (min-width: 640px) {
  .page-faq .faq-hot__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .page-faq .faq-ticket__meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 980px) {
  .page-faq .faq-desk {
    grid-template-columns: 262px minmax(0, 1fr);
    gap: 48px;
  }

  .page-faq .faq-index {
    position: sticky;
    top: calc(var(--bw-bar-h) + 24px);
  }

  .page-faq .faq-ticket__grid {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    gap: 44px;
    align-items: start;
  }

  .page-faq .faq-ticket__meta {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .page-faq .faq-hot__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* ---------- 动效降级 ---------- */
@media (prefers-reduced-motion: reduce) {
  .page-faq .faq-hot__card,
  .page-faq .faq-hot__card::after,
  .page-faq .faq-q,
  .page-faq .faq-q__ico::before,
  .page-faq .faq-q__ico::after,
  .page-faq .faq-index__list a,
  .page-faq .faq-totop {
    transition: none;
  }

  .page-faq .faq-hot__card:hover {
    transform: none;
  }
}
