/* Mia FAQ page */
.faq-page {
  --faq-accent: #a78bfa;
  --faq-accent-dim: rgba(167, 139, 250, 0.14);
  --faq-border: #2a2d3a;
  --faq-card: #1a1c24;
  --faq-muted: #a3a3a3;
}

.faq-hero {
  max-width: 44rem;
  margin: 0 auto 1.75rem;
  padding: 2rem 1.25rem 1.5rem;
  text-align: center;
  border-radius: 1.25rem;
  border: 1px solid var(--faq-border);
  background:
    radial-gradient(
      ellipse 80% 60% at 50% -20%,
      rgba(167, 139, 250, 0.16),
      transparent 55%
    ),
    var(--faq-card);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}

.faq-hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--faq-accent);
  margin-bottom: 0.65rem;
}

.faq-hero h1 {
  font-size: clamp(1.85rem, 4.5vw, 2.5rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 0.55rem;
  color: #f5f5f5;
}

.faq-hero-lead {
  color: var(--faq-muted);
  font-size: 0.92rem;
  line-height: 1.6;
  max-width: 34rem;
  margin: 0 auto;
}

.faq-toolbar {
  max-width: 40rem;
  margin: 0 auto 1.5rem;
  padding: 0 0.25rem;
}

.faq-search {
  width: 100%;
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid var(--faq-border);
  border-radius: 999px;
  padding: 0.75rem 1rem 0.75rem 2.5rem;
  color: #f5f5f5;
  font-size: 0.9rem;
  margin-bottom: 1rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23737373'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M21 21l-4.35-4.35M10.5 18a7.5 7.5 0 100-15 7.5 7.5 0 000 15z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 0.85rem center;
  background-size: 1rem;
}

.faq-search:focus {
  outline: none;
  border-color: rgba(167, 139, 250, 0.45);
  box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.12);
}

.faq-search-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.76rem;
  color: var(--faq-muted);
  min-height: 1.25rem;
}

.faq-categories {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.45rem;
  margin-bottom: 2rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.category-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  border: 1px solid var(--faq-border);
  background: rgba(255, 255, 255, 0.03);
  color: #d4d4d4;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition:
    color 0.2s,
    border-color 0.2s,
    background 0.2s;
}

.category-btn:hover {
  color: #f5f5f5;
  border-color: rgba(255, 255, 255, 0.12);
}

.category-btn.active {
  color: #ede9fe;
  border-color: rgba(167, 139, 250, 0.45);
  background: var(--faq-accent-dim);
}

.category-btn[data-category="premium"].active {
  color: #fde047;
  border-color: rgba(253, 224, 71, 0.4);
  background: rgba(253, 224, 71, 0.1);
}

.category-btn[data-category="api"].active {
  color: #7dd3fc;
  border-color: rgba(0, 191, 255, 0.4);
  background: rgba(0, 191, 255, 0.1);
}

.faq-content {
  max-width: 44rem;
  margin: 0 auto;
}

.faq-category.hidden {
  display: none;
}

.faq-panel-head {
  margin-bottom: 1rem;
}

.faq-panel-head h2 {
  font-size: 1.1rem;
  font-weight: 800;
  color: #f5f5f5;
  margin-bottom: 0.25rem;
}

.faq-panel-head p {
  font-size: 0.82rem;
  color: var(--faq-muted);
}

.faq-item {
  border: 1px solid var(--faq-border);
  border-radius: 0.85rem;
  background: rgba(255, 255, 255, 0.02);
  margin-bottom: 0.65rem;
  overflow: hidden;
  transition: border-color 0.2s;
}

.faq-item:hover {
  border-color: rgba(167, 139, 250, 0.22);
}

.faq-item.is-open {
  border-color: rgba(167, 139, 250, 0.35);
  background: rgba(167, 139, 250, 0.04);
}

.faq-item.hidden-by-search {
  display: none;
}

.faq-question {
  width: 100%;
  padding: 1rem 1.1rem;
  text-align: left;
  background: transparent;
  border: none;
  color: #f5f5f5;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
}

.faq-question span {
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.45;
}

.faq-arrow {
  flex-shrink: 0;
  color: var(--faq-accent);
  transition: transform 0.25s ease;
}

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

.faq-answer {
  padding: 0 1.1rem 1rem;
  color: #d4d4d4;
  font-size: 0.88rem;
  line-height: 1.6;
}

.faq-answer.hidden {
  display: none;
}

.faq-answer a {
  color: #93c5fd;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.faq-answer a:hover {
  color: #bfdbfe;
}

.faq-answer code {
  font-size: 0.82rem;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--faq-border);
  border-radius: 0.35rem;
  padding: 0.1rem 0.35rem;
  color: #fde047;
}

.faq-empty {
  display: none;
  text-align: center;
  padding: 2rem 1rem;
  color: var(--faq-muted);
  font-size: 0.9rem;
}

.faq-empty.visible {
  display: block;
}

.faq-cta {
  max-width: 36rem;
  margin: 2.5rem auto 0;
  padding: 1.35rem;
  text-align: center;
  border-radius: 1rem;
  border: 1px solid rgba(167, 139, 250, 0.22);
  background: var(--faq-accent-dim);
}

.faq-cta h2 {
  font-size: 1.1rem;
  font-weight: 800;
  color: #ede9fe;
  margin-bottom: 0.45rem;
}

.faq-cta p {
  font-size: 0.88rem;
  color: var(--faq-muted);
  margin-bottom: 1rem;
}

.faq-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.7rem 1.15rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.86rem;
  text-decoration: none;
  color: #111;
  background: linear-gradient(135deg, #c4b5fd, #7c3aed);
}

.faq-cta-btn:hover {
  opacity: 0.92;
}
