/* ============================================================
   SAC AERO DESIGN — faq.css
   Styles specific to the FAQ page
============================================================ */

/* Reuse page-hero from shop.css — included here too for standalone use */
.page-hero {
  padding: calc(var(--nav-height) + 4rem) 0 4rem;
  position: relative;
  background: var(--bg-dark);
  border-bottom: 1px solid var(--border);
}
.page-hero-bg-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,200,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,200,255,0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
}

/* ---- FAQ LAYOUT ---- */
.faq-section { background: var(--bg-dark); overflow-x: hidden; }

.faq-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 4rem;
  align-items: start;
  min-width: 0;  /* prevents grid blowout */
}

/* Ensure all grid children can't overflow their column */
.faq-layout > * {
  min-width: 0;
}

/* ---- SIDEBAR ---- */
.faq-sidebar {
  position: sticky;
  top: calc(var(--nav-height) + 2rem);
}

.sidebar-label {
  font-family: var(--font-display);
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.faq-sidebar-nav ul {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.faq-nav-link {
  display: block;
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius);
  font-size: 0.95rem;
  color: var(--text-muted);
  border-left: 2px solid transparent;
  transition: all var(--transition);
}
.faq-nav-link:hover,
.faq-nav-link.active {
  color: var(--accent);
  background: rgba(0,200,255,0.06);
  border-left-color: var(--accent);
}

/* ---- FAQ GROUPS ---- */
.faq-content {
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

.faq-group { display: flex; flex-direction: column; gap: 0.75rem; }

.faq-group-title {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0.25rem;
}

/* ---- FAQ ACCORDION ITEMS ---- */
.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: border-color var(--transition);
}
.faq-item:has(.faq-question[aria-expanded="true"]) {
  border-color: var(--accent-dim);
}

/* Question button */
.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem 1.4rem;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  font-family: var(--font-body);
  font-size: 1.0rem;
  font-weight: 500;
  color: var(--text);
  transition: color var(--transition);
  overflow-wrap: break-word;
  word-break: break-word;
}
.faq-question:hover { color: #fff; }
.faq-question[aria-expanded="true"] { color: #fff; }

.faq-chevron {
  font-size: 0.82rem;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: transform var(--transition);
}
.faq-question[aria-expanded="true"] .faq-chevron {
  transform: rotate(180deg);
  color: var(--accent);
}

/* Answer panel */
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease, padding 0.25s ease;
}
.faq-answer.open {
  max-height: 1000px; /* large enough for any content */
}
.faq-answer p,
.faq-answer ul,
.faq-answer ol {
  padding: 0 1.4rem 1.25rem;
  color: var(--text-muted);
  font-size: 0.97rem;
  line-height: 1.7;
  overflow-wrap: break-word;
  word-break: break-word;
}
.faq-answer p + p { padding-top: 0; }

.faq-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.faq-list li {
  position: relative;
  padding-left: 1.2rem;
}
.faq-list li::before {
  content: '›';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
}

/* Ordered list */
.faq-answer ol.faq-list {
  counter-reset: faq-counter;
}
.faq-answer ol.faq-list li::before {
  content: counter(faq-counter) '.';
  counter-increment: faq-counter;
  font-family: var(--font-display);
  font-size: 0.84rem;
  color: var(--accent);
}

/* ---- STILL HAVE QUESTIONS CTA ---- */
.faq-cta {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  background: linear-gradient(135deg, rgba(0,200,255,0.08), rgba(0,200,255,0.03));
  border: 1px solid rgba(0,200,255,0.2);
  border-radius: var(--radius-lg);
  padding: 1.75rem 2rem;
  margin-top: 1rem;
}
.faq-cta > i { font-size: 1.8rem; color: var(--accent); flex-shrink: 0; }
.faq-cta > div { flex: 1; }
.faq-cta h4 {
  font-family: var(--font-display);
  font-size: 0.97rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.3rem;
}
.faq-cta p { font-size: 0.95rem; color: var(--text-muted); }

/* ---- RESPONSIVE ---- */

/* At 1100px the sidebar + content starts feeling tight — reduce gap */
@media (max-width: 1100px) {
  .faq-layout {
    grid-template-columns: 180px 1fr;
    gap: 2.5rem;
  }
}

@media (max-width: 900px) {
  .faq-layout {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .faq-sidebar { display: none; }
}

@media (max-width: 600px) {
  .faq-cta { flex-direction: column; text-align: center; }
  .faq-cta > i { font-size: 2rem; }
}