/**
 * FAQ Accordion Component Styles
 * WCAG 2.1 AA compliant with smooth animations
 * 
 * Feature: 016-main-landing-page
 */

.faq-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

.faq-item {
  margin-bottom: 1rem;
  border: 1px solid rgba(0, 255, 255, 0.2);
  border-radius: 8px;
  background: rgba(0, 20, 40, 0.5);
  backdrop-filter: blur(10px);
  overflow: hidden;
  transition: border-color 0.3s ease;
}

.faq-item:hover {
  border-color: rgba(0, 255, 255, 0.4);
}

.faq-button {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem;
  background: transparent;
  border: none;
  color: var(--text-primary, #e0f7ff);
  font-size: 1.125rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.faq-button:hover {
  color: var(--cyan-primary, #00ffff);
}

.faq-button:focus {
  outline: 2px solid var(--cyan-primary, #00ffff);
  outline-offset: -2px;
}

.faq-button:focus-visible {
  outline: 2px solid var(--cyan-primary, #00ffff);
  outline-offset: 2px;
}

.faq-question {
  flex: 1;
  padding-right: 1rem;
}

.faq-chevron {
  flex-shrink: 0;
  color: var(--cyan-primary, #00ffff);
  transition: transform 0.3s ease;
  transform-origin: center;
}

.faq-button.active .faq-chevron {
  transform: rotate(180deg);
}

.faq-content {
  overflow: hidden;
  transition: height 0.3s ease-out;
}

.faq-content[hidden] {
  display: none;
}

.faq-content.open {
  display: block;
}

.faq-content-inner {
  padding: 0 1.5rem 1.5rem 1.5rem;
  color: var(--text-secondary, #b0d7e0);
  line-height: 1.6;
  font-size: 1rem;
}

.faq-content-inner p {
  margin: 0 0 1rem 0;
}

.faq-content-inner p:last-child {
  margin-bottom: 0;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .faq-container {
    padding: 1rem 0.5rem;
  }

  .faq-button {
    padding: 1rem;
    font-size: 1rem;
  }

  .faq-content-inner {
    padding: 0 1rem 1rem 1rem;
    font-size: 0.9375rem;
  }

  .faq-chevron {
    width: 18px;
    height: 18px;
  }
}

/* Touch-friendly targets on mobile */
@media (max-width: 768px) {
  .faq-button {
    min-height: 48px; /* WCAG touch target size */
  }
}

/* Smooth animation performance */
@media (prefers-reduced-motion: reduce) {
  .faq-button,
  .faq-chevron,
  .faq-content,
  .faq-item {
    transition: none !important;
    animation: none !important;
  }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  .faq-item {
    border-color: currentColor;
  }

  .faq-button:focus {
    outline-width: 3px;
  }
}
