/**
 * FAQ Page – Complete Stylesheet
 * Prefix: fq-
 */

/* ==========================================================================
   HERO (uses pp-hero from product-page.css)
   ========================================================================== */

/* ==========================================================================
   SEARCH BAR
   ========================================================================== */
.fq-search {
  max-width: 540px;
  margin: 0 auto 2.5rem;
  position: relative;
}

.fq-search__icon {
  position: absolute;
  left: auto;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  color: #999;
  pointer-events: none;
  z-index: 1;
}

.fq-search__input {
  width: 100%;
  padding: 0.875rem 3rem 0.875rem 1rem;
  border: 1.5px solid #e5e7eb;
  border-radius: 12px;
  font-size: 0.9375rem;
  background: #fff;
  color: #1a1a2e;
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}

.fq-search__input::placeholder { color: #aaa; }

.fq-search__input:focus {
  border-color: #660099;
  box-shadow: 0 0 0 3px rgba(102,0,153,0.08);
}

.fq-search__clear {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  display: none;
  align-items: center;
  justify-content: center;
  background: #f3f4f6;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  color: #666;
  padding: 0;
  transition: background 0.15s;
}

.fq-search__clear:hover { background: #e5e7eb; }
.fq-search__clear svg { width: 14px; height: 14px; }
.fq-search__clear.is-visible { display: flex; }

.fq-search.has-text .fq-search__icon { display: none; }

.fq-search__count {
  text-align: center;
  font-size: 0.8125rem;
  color: #888;
  margin-top: 0.625rem;
}

/* ==========================================================================
   ACCORDION
   ========================================================================== */
.fq-accordion {
  max-width: 780px;
  margin: 0 auto;
}

.fq-item {
  border: 1.5px solid #eee;
  border-radius: 14px;
  margin-bottom: 0.875rem;
  overflow: hidden;
  background: #fff;
  transition: border-color 0.25s, box-shadow 0.25s;
  animation: fqFadeIn 0.4s ease both;
}

.fq-item:nth-child(2) { animation-delay: 0.04s; }
.fq-item:nth-child(3) { animation-delay: 0.08s; }
.fq-item:nth-child(4) { animation-delay: 0.12s; }
.fq-item:nth-child(5) { animation-delay: 0.16s; }
.fq-item:nth-child(6) { animation-delay: 0.2s; }

.fq-item:hover {
  border-color: rgba(102,0,153,0.15);
  box-shadow: 0 4px 16px rgba(102,0,153,0.06);
}

.fq-item.is-open {
  border-color: rgba(102,0,153,0.2);
  box-shadow: 0 6px 24px rgba(102,0,153,0.08);
}

.fq-item.is-hidden { display: none; }

/* Question button */
.fq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  border: none;
  background: none;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
}

.fq-question__text {
  font-size: 1rem;
  font-weight: 600;
  color: #1a1a2e;
  line-height: 1.4;
  flex: 1;
}

.fq-question__number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(102,0,153,0.06);
  color: #660099;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
  margin-right: 0.75rem;
  transition: background 0.2s, color 0.2s;
}

.fq-item.is-open .fq-question__number {
  background: #660099;
  color: #fff;
}

.fq-question__icon {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(102,0,153,0.06);
  border-radius: 50%;
  transition: background 0.25s, transform 0.3s;
}

.fq-question__icon svg {
  width: 16px;
  height: 16px;
  color: #660099;
  transition: transform 0.3s;
}

.fq-item.is-open .fq-question__icon {
  background: #660099;
}

.fq-item.is-open .fq-question__icon svg {
  color: #fff;
  transform: rotate(180deg);
}

.fq-question:hover .fq-question__icon {
  background: rgba(102,0,153,0.12);
}

.fq-item.is-open .fq-question:hover .fq-question__icon {
  background: #4a0066;
}

/* Answer panel */
.fq-answer {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.35s cubic-bezier(0.4,0,0.2,1),
              opacity 0.25s ease;
  opacity: 0;
}

.fq-item.is-open .fq-answer {
  opacity: 1;
}

.fq-answer__inner {
  padding: 0 1.5rem 1.5rem;
  padding-left: calc(1.5rem + 28px + 0.75rem);
}

.fq-answer__inner p {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.75;
  color: #555;
}

.fq-answer__inner p + p { margin-top: 0.75rem; }

/* Divider line above answer */
.fq-answer__divider {
  height: 1px;
  background: linear-gradient(90deg, rgba(102,0,153,0.08) 0%, rgba(102,0,153,0.15) 50%, rgba(102,0,153,0.08) 100%);
  margin: 0 1.5rem;
}

/* ==========================================================================
   EMPTY STATE
   ========================================================================== */
.fq-empty {
  text-align: center;
  padding: 3rem 2rem;
  background: #f9fafb;
  border: 2px dashed #e5e7eb;
  border-radius: 16px;
  max-width: 780px;
  margin: 0 auto;
}

.fq-empty svg {
  width: 48px;
  height: 48px;
  color: #9ca3af;
  margin-bottom: 1rem;
}

.fq-empty__title {
  font-size: 1.0625rem;
  font-weight: 600;
  color: #374151;
  margin: 0 0 0.375rem;
}

.fq-empty__text {
  font-size: 0.9375rem;
  color: #6b7280;
  margin: 0;
}

/* ==========================================================================
   CTA BANNER (inline)
   ========================================================================== */
.fq-cta-banner {
  max-width: 780px;
  margin: 3rem auto 0;
  padding: 2.5rem;
  background: linear-gradient(135deg, #1a0a2e 0%, #3b1562 50%, #581c87 100%);
  border-radius: 20px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.fq-cta-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 80%, rgba(255,255,255,0.05) 0%, transparent 50%),
              radial-gradient(circle at 80% 20%, rgba(255,255,255,0.04) 0%, transparent 50%);
  pointer-events: none;
}

.fq-cta-banner__inner { position: relative; z-index: 1; }

.fq-cta-banner__icon {
  width: 52px;
  height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.1);
  border-radius: 14px;
  margin-bottom: 1.25rem;
}

.fq-cta-banner__icon svg {
  width: 24px;
  height: 24px;
  color: #fff;
}

.fq-cta-banner__title {
  font-size: 1.375rem;
  font-weight: 700;
  color: #fff;
  margin: 0 0 0.5rem;
}

.fq-cta-banner__text {
  font-size: 0.9375rem;
  color: rgba(255,255,255,0.8);
  line-height: 1.6;
  max-width: 480px;
  margin: 0 auto 1.75rem;
}

.fq-cta-banner__actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

.fq-cta-banner__actions .c-btn--secondary {
  background: #fff;
  color: #660099;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  font-size: 0.9375rem;
  border-radius: 10px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.2s;
  border: none;
}

.fq-cta-banner__actions .c-btn--secondary:hover {
  background: #f3e8ff;
  transform: translateY(-1px);
}

.fq-cta-banner__actions .c-btn--outline-white {
  background: transparent;
  color: #fff;
  border: 1.5px solid rgba(255,255,255,0.35);
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  font-size: 0.9375rem;
  border-radius: 10px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.2s;
}

.fq-cta-banner__actions .c-btn--outline-white:hover {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.6);
}

/* ==========================================================================
   SECTION WRAPPER
   ========================================================================== */
.fq-section {
  padding: 4rem 1.5rem 4.5rem;
  background: #f9fafb;
}

.fq-section__inner {
  max-width: 1120px;
  margin: 0 auto;
}

.fq-section__header {
  text-align: center;
  max-width: 580px;
  margin: 0 auto 2.5rem;
}

.fq-section__pretitle {
  display: inline-block;
  padding: 0.3rem 0.875rem;
  background: rgba(102,0,153,0.08);
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #660099;
  margin-bottom: 0.75rem;
}

.fq-section__title {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  color: #1a1a2e;
  margin: 0 0 0.75rem;
  line-height: 1.2;
}

.fq-section__subtitle {
  font-size: 1rem;
  line-height: 1.6;
  color: #555;
  margin: 0;
}

/* ==========================================================================
   ANIMATIONS
   ========================================================================== */
@keyframes fqFadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .fq-item { animation: none; }
  .fq-answer { transition: none; }
  .fq-question__icon svg { transition: none; }
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 768px) {
  .fq-section { padding: 3rem 1rem 3.5rem; }

  .fq-question { padding: 1rem 1.125rem; }
  .fq-answer__inner {
    padding: 0 1.125rem 1.25rem;
    padding-left: 1.125rem;
  }
  .fq-answer__divider { margin: 0 1.125rem; }
  .fq-question__number { display: none; }

  .fq-cta-banner { padding: 2rem 1.25rem; border-radius: 16px; }
}
