/**
 * Mesada Landing - FAQ Accordion Component
 * Accessible accordion with smooth animations
 */

/* ===== FAQ Container ===== */
.faq-container {
  background-color: var(--color-white);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

/* ===== FAQ Item ===== */
.faq-item {
  border-bottom: 1px solid var(--color-slate-200);
}

.faq-item:last-child {
  border-bottom: none;
}

/* ===== FAQ Summary (Question) ===== */
.faq-item summary {
  display: flex;
  width: 100%;
  cursor: pointer;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-5);
  text-align: left;
  font-weight: 500;
  color: var(--color-slate-900);
  transition: background-color var(--transition-fast);
  list-style: none; /* Remove default marker */
}

.faq-item summary::-webkit-details-marker {
  display: none; /* Remove Safari marker */
}

.faq-item summary:hover {
  background-color: var(--color-slate-50);
}

.faq-item summary:focus-visible {
  outline: none;
  box-shadow: inset 0 0 0 2px var(--mesada-primary);
}

/* First item rounded top */
.faq-item:first-child summary {
  border-radius: var(--radius-2xl) var(--radius-2xl) 0 0;
}

/* Last item rounded bottom when closed */
.faq-item:last-child summary {
  border-radius: 0 0 var(--radius-2xl) var(--radius-2xl);
}

/* ===== FAQ Icon ===== */
.faq-icon {
  width: 1.25rem;
  height: 1.25rem;
  flex-shrink: 0;
  color: var(--color-slate-400);
  transition: transform var(--transition-slow);
}

.faq-item[open] .faq-icon {
  transform: rotate(45deg);
}

/* ===== FAQ Content (Answer) ===== */
.faq-content {
  padding: 0 var(--space-5) var(--space-5);
  color: var(--color-slate-600);
  line-height: 1.7;
  animation: faq-slide-down var(--transition-slow) ease-out;
}

/* ===== Slide Down Animation ===== */
@keyframes faq-slide-down {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== FAQ Links ===== */
.faq-content a {
  color: #4F46E5; /* indigo-600 */
  text-decoration: underline;
  transition: color var(--transition-fast);
}

.faq-content a:hover {
  color: #3730A3; /* indigo-800 */
}

/* ===== FAQ Strong Text ===== */
.faq-content strong {
  font-weight: 600;
  color: var(--color-slate-700);
}
