/* ============================================================
   faq.css — FAQ 페이지 전용 스타일 (인라인 스타일에서 분리)
   ============================================================ */

/* ── Q 배지 ── */
.q-badge {
  background-color: var(--color-primary);
  color: white;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 3px 9px;
  border-radius: 6px;
  flex-shrink: 0;
  line-height: 1;
}

/* ── 관련근거 블록 ── */
.faq-ref-note {
  font-size: 0.82em;
  color: #64748b;
  margin-top: 8px;
  padding: 8px 12px;
  background: #f8fafc;
  border-radius: 6px;
  border-left: 3px solid #94a3b8;
  display: flex;
  align-items: flex-start;
}
.faq-ref-note .ref-icon {
  margin-right: 6px;
  flex-shrink: 0;
}
.faq-ref-note .ref-label {
  font-weight: 600;
}

/* ── 바로가기 블록 ── */
.faq-link-note {
  font-size: 0.82em;
  color: #d97706;
  margin-top: 8px;
  padding: 8px 12px;
  background: #fefbf6;
  border-radius: 6px;
  border-left: 3px solid #f59e0b;
  display: flex;
  align-items: flex-start;
}
.faq-link-note .ref-icon {
  margin-right: 6px;
  flex-shrink: 0;
}
.faq-link-note .ref-label {
  font-weight: 600;
}
.faq-link-note a {
  color: #d97706;
  text-decoration: underline;
  font-weight: 500;
}

/* ── 해시태그 ── */
.faq-hashtags {
  font-size: 0.85em;
  color: var(--color-primary);
  margin-top: 10px;
}

/* ── 데스크톱 컨트롤 / 페이지네이션 ── */
.faq-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  gap: 12px;
  flex-wrap: wrap;
}
.faq-controls select {
  padding: 8px 16px;
  border-radius: 8px;
  border: 1px solid var(--border-light);
  font-size: 0.88rem;
  color: var(--text-medium);
  background-color: white;
  cursor: pointer;
  outline: none;
  transition: border-color 0.2s;
}
.faq-controls select:focus {
  border-color: var(--color-primary);
}

.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  margin-top: 50px;
}
.pagination button {
  min-width: 38px;
  height: 38px;
  padding: 0 12px;
  border-radius: 8px;
  border: 1px solid var(--border-light);
  background: white;
  color: var(--text-medium);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
}
.pagination button:hover:not(:disabled) {
  border-color: var(--color-primary);
  color: var(--color-primary);
  background: #f0f7ff;
}
.pagination button.active {
  background: var(--color-primary);
  color: white;
  border-color: var(--color-primary);
}
.pagination button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  background: #f8fafc;
}
.pagination span {
  color: var(--text-light);
  padding: 0 4px;
}

@media (max-width: 768px) {
  .faq-controls {
    flex-direction: column;
    align-items: flex-start;
  }
  .faq-controls select {
    width: 100%;
  }
}

/* ── 모바일 듀얼-렌더링 래퍼 ── */
.stitch-mobile .material-symbols-outlined {
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}
.stitch-mobile .hide-scrollbar::-webkit-scrollbar {
  display: none;
}
.stitch-mobile .hide-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* ── 스켈레톤 로딩 애니메이션 ── */
@keyframes faq-shimmer {
  0%   { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.faq-skeleton .accordion-header {
  pointer-events: none;
}

.skeleton-line {
  display: inline-block;
  height: 1em;
  border-radius: 4px;
  background: linear-gradient(90deg, #e2e8f0 25%, #f1f5f9 50%, #e2e8f0 75%);
  background-size: 200% 100%;
  animation: faq-shimmer 1.5s ease-in-out infinite;
}

/* ── FAQ 탭(카테고리 칩) 스크롤 그라데이션 힌트 ── */
@media (max-width: 768px) {
  .faq-tabs {
    position: relative;
  }
  .faq-tabs::after {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 40px;
    background: linear-gradient(to right, transparent, var(--bg-body, #F5F7FA));
    pointer-events: none;
    z-index: 1;
  }
  /* 하단 검색바와 컨텐츠 겹침 방지 */
  .mobile-bottom-search-bar ~ .faq-tabs,
  .mobile-bottom-search-bar ~ .faq-controls,
  .mobile-bottom-search-bar ~ .accordion-group {
    margin-bottom: 0;
  }
}
