/**
 * Página: Preguntas Frecuentes (FAQ)
 * Metodología: BEM (Block Element Modifier)
 * 
 * Block: faq-page
 * Elements: __hero, __content, __container, __intro, __categories, __list, __item, 
 *           __question, __answer, __cta
 */

/* Box-sizing universal */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Prevenir scroll horizontal */
html,
body {
  overflow-x: hidden;
  max-width: 100%;
  margin: 0;
  padding: 0;
}

/* Block: Página de FAQ */
.faq-page {
  width: 100%;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Element: Hero/Portada */
.faq-page__hero {
  width: 100vw;
  max-width: none;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  margin-bottom: 60px;
  background-color: #fff;
}

.faq-page__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

/* Element: Contenido principal */
.faq-page__content {
  width: 100%;
  padding: 0 20px 80px 20px;
  box-sizing: border-box;
}

.faq-page__container {
  max-width: 1000px;
  margin: 0 auto;
  width: 100%;
  box-sizing: border-box;
}

/* Element: Título principal */
.faq-page__title {
  color: #1a1a1a;
  font-size: clamp(2rem, 5vw, 2.5rem);
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 30px 0;
  text-align: center;
}

/* Element: Introducción */
.faq-page__intro {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border-left: 4px solid #FF6600;
  padding: 30px;
  border-radius: 8px;
  margin-bottom: 60px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  width: 100%;
  box-sizing: border-box;
}

.faq-page__intro p {
  color: #333;
  font-size: 1.125rem;
  line-height: 1.8;
  margin: 0;
}

.faq-page__intro strong {
  color: #FF6600;
  font-weight: 600;
}

/* Element: Categorías */
.faq-page__categories {
  margin-bottom: 50px;
}

.faq-page__categories-title {
  color: #1a1a1a;
  font-size: 1.5rem;
  font-weight: 600;
  margin: 0 0 20px 0;
  text-align: center;
}

.faq-page__categories-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

.faq-page__category-btn {
  background: #ffffff;
  color: #666666;
  border: 2px solid #e0e0e0;
  padding: 10px 20px;
  border-radius: 25px;
  font-size: 0.9375rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.faq-page__category-btn:hover {
  border-color: #FF6600;
  color: #FF6600;
  transform: translateY(-2px);
}

.faq-page__category-btn--active {
  background: #FF6600;
  color: #ffffff;
  border-color: #FF6600;
}

/* Element: Lista de FAQs */
.faq-page__list {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 60px;
}

/* Element: Item de FAQ */
.faq-page__item {
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.faq-page__item:hover {
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
  border-color: #FF6600;
}

/* Element: Pregunta (botón) */
.faq-page__question {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 25px 30px;
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: left;
  transition: all 0.3s ease;
}

.faq-page__question:hover {
  background: #f8f9fa;
}

.faq-page__question--active {
  background: #fff5f0;
}

.faq-page__question-number {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, #FF6600 0%, #e55a00 100%);
  color: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.875rem;
}

.faq-page__question-text {
  flex: 1;
  color: #1a1a1a;
  font-size: 1.125rem;
  font-weight: 600;
  line-height: 1.4;
}

.faq-page__question-icon {
  flex-shrink: 0;
  color: #FF6600;
  transition: transform 0.3s ease;
}

.faq-page__question--active .faq-page__question-icon {
  transform: rotate(180deg);
}

/* Element: Respuesta */
.faq-page__answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.faq-page__answer-content {
  padding: 0 30px 30px 85px;
}

.faq-page__answer-content p {
  color: #666666;
  font-size: 1rem;
  line-height: 1.8;
  margin: 0 0 15px 0;
}

.faq-page__answer-category {
  display: inline-block;
  background: #fff5f0;
  color: #FF6600;
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 0.875rem;
  font-weight: 500;
}

/* Element: CTA Section */
.faq-page__cta {
  background: linear-gradient(135deg, #FF6600 0%, #e55a00 100%);
  border-radius: 16px;
  padding: 50px 40px;
  text-align: center;
  box-shadow: 0 8px 30px rgba(255, 102, 0, 0.3);
  position: relative;
  overflow: hidden;
}

.faq-page__cta::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
  animation: pulse 3s ease-in-out infinite;
}

.faq-page__cta-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100px;
  height: 100px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  margin-bottom: 25px;
  color: #ffffff;
  backdrop-filter: blur(10px);
  position: relative;
  z-index: 1;
}

.faq-page__cta-icon svg {
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.faq-page__cta-title {
  color: #ffffff;
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 700;
  margin: 0 0 20px 0;
  position: relative;
  z-index: 1;
}

.faq-page__cta-text {
  color: #ffffff;
  font-size: 1.125rem;
  line-height: 1.7;
  margin: 0 0 30px 0;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
  opacity: 0.95;
  position: relative;
  z-index: 1;
}

.faq-page__cta-button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #ffffff;
  color: #FF6600;
  font-size: 1.125rem;
  font-weight: 700;
  padding: 16px 40px;
  border-radius: 50px;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  position: relative;
  z-index: 1;
}

.faq-page__cta-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
  background: #f8f9fa;
}

.faq-page__cta-button svg {
  width: 20px;
  height: 20px;
}

/* Accesibilidad */
@media (prefers-reduced-motion: reduce) {
  .faq-page__hero::before,
  .faq-page__cta::before {
    animation: none;
  }
  
  .faq-page__item:hover,
  .faq-page__category-btn:hover,
  .faq-page__cta-button:hover {
    transform: none;
  }
  
  .faq-page__question-icon {
    transition: none;
  }
}

/* Responsive - Tablet */
@media (max-width: 1024px) {
  .faq-page__content {
    padding: 0 30px 60px 30px;
  }

  .faq-page__intro {
    padding: 25px;
    margin-bottom: 50px;
  }

  .faq-page__cta {
    padding: 40px 30px;
  }
}

/* Responsive - Mobile */
@media (max-width: 768px) {
  .faq-page__hero {
    margin-bottom: 40px;
  }

  .faq-page__content {
    padding: 0 20px 50px 20px;
  }

  .faq-page__title {
    margin-bottom: 25px;
  }

  .faq-page__intro {
    padding: 20px;
    margin-bottom: 40px;
  }

  .faq-page__intro p {
    font-size: 1rem;
  }

  .faq-page__categories {
    margin-bottom: 40px;
  }

  .faq-page__categories-title {
    font-size: 1.25rem;
  }

  .faq-page__categories-list {
    gap: 10px;
  }

  .faq-page__category-btn {
    padding: 8px 16px;
    font-size: 0.875rem;
  }

  .faq-page__list {
    gap: 15px;
    margin-bottom: 50px;
  }

  .faq-page__question {
    padding: 20px;
    gap: 12px;
  }

  .faq-page__question-number {
    width: 35px;
    height: 35px;
    font-size: 0.8125rem;
  }

  .faq-page__question-text {
    font-size: 1rem;
  }

  .faq-page__answer-content {
    padding: 0 20px 20px 67px;
  }

  .faq-page__answer-content p {
    font-size: 0.9375rem;
  }

  .faq-page__cta {
    padding: 35px 25px;
    border-radius: 12px;
  }

  .faq-page__cta-icon {
    width: 80px;
    height: 80px;
    margin-bottom: 20px;
  }

  .faq-page__cta-icon svg {
    width: 48px;
    height: 48px;
  }

  .faq-page__cta-text {
    font-size: 1rem;
    margin-bottom: 25px;
  }

  .faq-page__cta-button {
    font-size: 1rem;
    padding: 14px 30px;
  }
}
