/* FAQ Accordion Widget Styles */

/* Layout */
.faq-accordion-widget {
  width: 100%;
}

.faq-accordion-item {
  position: relative;
  display: block;
  border-bottom: 1px solid #e0e0e0;
  border-bottom-style: solid;
  transition: all 0.3s ease;
}

/* Header */
.faq-header {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 20px 0;
  transition: all 0.3s ease;
}

.faq-header:hover {
  opacity: 0.8;
}

.faq-title {
  max-width: 730px;
  margin: 0 !important;
  padding: 0;
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.4;
  color: #333;
  transition: color 0.3s ease;
}

/* Arrow */
.faq-accordion-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  margin-left: 15px;
  flex-shrink: 0;
  transition: transform 0.3s ease;
}

.faq-accordion-arrow svg,
.faq-accordion-arrow img {
  width: 100%;
  height: 100%;
  display: block;
  transition: transform 0.3s ease;
}

.faq-accordion-arrow svg {
  fill: currentColor;
}

.faq-accordion-arrow.rotated {
  transform: rotate(180deg);
}

/* Content */
.faq-content {
  padding: 0 0 32px 0;
  color: #666;
  line-height: 1.6;
  display: none;
}

.faq-content p {
  margin: 0 0 15px 0;
}

.faq-content a {
  color: var(--primary);
  text-decoration: underline;
}

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

.faq-content ul,
.faq-content ol {
  margin: 0 0 15px 20px;
  padding: 0;
}

.faq-content li {
  margin-bottom: 5px;
}

.faq-content h1,
.faq-content h2,
.faq-content h3,
.faq-content h4,
.faq-content h5,
.faq-content h6 {
  margin: 0 0 10px 0;
  line-height: 1.3;
}

/* States */
.faq-accordion-item.expanded .faq-header {
  padding-bottom: 10px;
}

.faq-accordion-item:focus-within .faq-header {
  outline: 2px solid #0073aa;
  outline-offset: 2px;
}

/* Responsive Design */
@media (max-width: 768px) {
  .faq-header {
    padding: 15px 0;
  }

  .faq-title {
    font-size: 16px;
    padding-right: 10px;
  }

  .faq-accordion-arrow {
    width: 18px;
    height: 18px;
    margin-left: 10px;
  }

  .faq-content {
    padding: 0 0 15px 0;
  }
}

@media (max-width: 480px) {
  .faq-header {
    padding: 12px 0;
  }

  .faq-title {
    font-size: 15px;
  }

  .faq-accordion-arrow {
    width: 16px;
    height: 16px;
    margin-left: 8px;
  }

  .faq-content {
    padding: 0 0 12px 0;
    font-size: 14px;
  }
}

/* Accessibility */
.faq-header:focus {
  outline: 2px solid #0073aa;
  outline-offset: 2px;
}

.faq-header:focus:not(:focus-visible) {
  outline: none;
}

.faq-header:focus-visible {
  outline: 2px solid #0073aa;
  outline-offset: 2px;
}

/* Animation Performance */
.faq-accordion-arrow,
.faq-accordion-arrow svg,
.faq-accordion-arrow img {
  will-change: transform;
}

.faq-content {
  will-change: height, opacity;
}

/* Print Styles */
@media print {
  .faq-accordion-item {
    page-break-inside: avoid;
    border-bottom: 1px solid #ccc !important;
  }

  .faq-content {
    display: block !important;
    padding: 10px 0 !important;
  }

  .faq-accordion-arrow {
    display: none;
  }
}
