/* ===== 蝉脉 · 常见问题（FAQ） =====
   设计语言沿用站点主色 #f95901 / 渐变 linear-gradient(135deg,#ff8845,#f94400)
   内容区最大宽 720px；浅色主题；无绝对定位装饰物；不使用 100vw。
   注意：本文件注释内不出现星号加斜杠的序列。
   ================================== */

.faq-body {
  width: 100%;
}

.faq-wrap {
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding: 14px 14px 30px;
  box-sizing: border-box;
  color: var(--text, #3a2a1e);
  font-size: 15px;
  line-height: 1.65;
  overflow-wrap: break-word;
  word-break: break-word;
}

/* ---------- 搜索框 ---------- */
.faq-search {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  box-sizing: border-box;
  background: #ffffff;
  border: 1px solid #f2e2d6;
  border-radius: 16px;
  padding: 10px 12px;
  box-shadow: 0 4px 16px rgba(249, 89, 1, 0.06);
}

.faq-search:focus-within {
  border-color: #ffb98c;
  box-shadow: 0 4px 18px rgba(249, 89, 1, 0.14);
}

.faq-search-ic {
  flex: 0 0 auto;
  color: #f95901;
}

.faq-input {
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text, #3a2a1e);
  font-size: 15px;
  font-family: inherit;
  line-height: 1.5;
  padding: 2px 0;
}

.faq-input::placeholder {
  color: #bda99a;
}

.faq-input::-webkit-search-cancel-button,
.faq-input::-webkit-search-decoration {
  -webkit-appearance: none;
  appearance: none;
  display: none;
}

.faq-clear {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border: 0;
  padding: 0;
  border-radius: 50%;
  background: #f4ebe4;
  color: #a08c7c;
  cursor: pointer;
  font-family: inherit;
}

.faq-clear:hover {
  background: #ffe6d5;
  color: #f95901;
}

.faq-clear[hidden] {
  display: none !important;
}

/* ---------- 分类 chips（横向可滑，不撑宽外层） ---------- */
.faq-cats {
  display: flex;
  gap: 8px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  margin-top: 12px;
  padding: 2px 0 10px;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.faq-cats::-webkit-scrollbar {
  display: none;
}

.faq-chip {
  flex: 0 0 auto;
  white-space: nowrap;
  border: 1px solid #f2e2d6;
  background: #ffffff;
  color: #6b5647;
  border-radius: 999px;
  padding: 7px 14px;
  font-size: 13.5px;
  font-family: inherit;
  line-height: 1.3;
  cursor: pointer;
  transition: background .18s ease, color .18s ease, border-color .18s ease;
}

.faq-chip:hover {
  border-color: #ffc39b;
  color: #f95901;
}

.faq-chip.on {
  background: linear-gradient(135deg, #ff8845 0%, #f94400 100%);
  border-color: transparent;
  color: #ffffff;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(249, 89, 1, 0.28);
}

/* ---------- 手风琴列表 ---------- */
.faq-list {
  width: 100%;
  margin-top: 4px;
}

.faq-item {
  display: block;
  width: 100%;
  box-sizing: border-box;
  background: #ffffff;
  border: 1px solid #f4e8de;
  border-radius: 18px;
  margin-bottom: 10px;
  overflow: hidden;
}

.faq-item[hidden] {
  display: none !important;
}

.faq-item.open {
  border-color: #ffd0ad;
  box-shadow: 0 6px 20px rgba(249, 89, 1, 0.09);
}

.faq-q {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  width: 100%;
  box-sizing: border-box;
  border: 0;
  background: transparent;
  padding: 14px 14px;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  color: inherit;
}

.faq-q-t {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.55;
  color: #3a2a1e;
}

.faq-hot {
  flex: 0 0 auto;
  align-self: center;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.6;
  padding: 0 8px;
  border-radius: 999px;
  color: #f95901;
  background: #fff1e7;
}

.faq-arrow {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  margin-top: 1px;
  color: #c0aa99;
  transition: transform .22s ease, color .22s ease;
}

.faq-item.open .faq-arrow {
  transform: rotate(180deg);
  color: #f95901;
}

.faq-a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows .24s ease;
}

.faq-item.open .faq-a {
  grid-template-rows: 1fr;
}

.faq-a-clip {
  min-height: 0;
  overflow: hidden;
}

.faq-a-inner {
  padding: 0 14px 14px;
  font-size: 14.5px;
  line-height: 1.75;
  color: #5b4738;
}

.faq-a-inner b {
  color: #3a2a1e;
  font-weight: 600;
}

.faq-go {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 12px;
  border: 0;
  border-radius: 999px;
  padding: 8px 16px;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 600;
  color: #ffffff;
  background: linear-gradient(135deg, #ff8845 0%, #f94400 100%);
  box-shadow: 0 4px 14px rgba(249, 89, 1, 0.26);
  cursor: pointer;
}

.faq-go:active {
  transform: translateY(1px);
}

/* ---------- 空态 ---------- */
.faq-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  width: 100%;
  box-sizing: border-box;
  background: #fffbf7;
  border: 1px dashed #f2d9c4;
  border-radius: 18px;
  padding: 30px 18px;
  margin-top: 4px;
  text-align: center;
}

.faq-empty[hidden] {
  display: none !important;
}

.faq-empty-ic {
  color: #f0b48d;
}

.faq-empty-t {
  font-size: 15px;
  font-weight: 600;
  color: #3a2a1e;
}

.faq-empty-s {
  font-size: 13px;
  color: #a08c7c;
  line-height: 1.6;
}

.faq-empty-btn {
  margin-top: 4px;
  border: 0;
  border-radius: 999px;
  padding: 9px 20px;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 600;
  color: #f95901;
  background: #fff1e7;
  cursor: pointer;
}

/* ---------- 底部 ---------- */
.faq-foot {
  width: 100%;
  box-sizing: border-box;
  margin-top: 18px;
  padding: 16px 16px 18px;
  background: #fffbf7;
  border: 1px solid #f7e9dd;
  border-radius: 18px;
  text-align: center;
}

.faq-foot-t {
  font-size: 14px;
  color: #6b5647;
  line-height: 1.7;
}

.faq-foot-t b {
  color: #f95901;
  font-weight: 700;
}

.faq-legal {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px 18px;
  margin-top: 12px;
}

.faq-legal a {
  font-size: 13px;
  color: #a08c7c;
  text-decoration: none;
  border-bottom: 1px solid #ecdbcd;
  padding-bottom: 1px;
  cursor: pointer;
}

.faq-legal a:hover {
  color: #f95901;
  border-bottom-color: #ffbb90;
}

/* ---------- 窄屏微调 ---------- */
@media (max-width: 400px) {
  .faq-wrap {
    padding: 12px 12px 26px;
  }
  .faq-q {
    padding: 13px 12px;
  }
  .faq-a-inner {
    padding: 0 12px 13px;
  }
}
