<div class="modern-faq-container">
  <div class="faq-header">
    <h1>Modern FAQ</h1>
    <p>Glassmorphism design with smooth animations</p>
  </div>
  
  <div class="faq-wrapper">
    <div class="faq-item">
      <div class="faq-question">
        <h3>What makes this FAQ modern?</h3>
        <div class="question-icon">+</div>
      </div>
      <div class="faq-answer">
        <p>This FAQ features glassmorphism design, smooth micro-interactions, and modern UI patterns with advanced CSS animations and backdrop filters.</p>
      </div>
    </div>
    
    <div class="faq-item">
      <div class="faq-question">
        <h3>How does the glassmorphism effect work?</h3>
        <div class="question-icon">+</div>
      </div>
      <div class="faq-answer">
        <p>The glassmorphism effect uses backdrop-filter: blur() combined with semi-transparent backgrounds to create a frosted glass appearance.</p>
      </div>
    </div>
    
    <div class="faq-item">
      <div class="faq-question">
        <h3>Is this design responsive?</h3>
        <div class="question-icon">+</div>
      </div>
      <div class="faq-answer">
        <p>Yes, the design is fully responsive and adapts beautifully to all screen sizes with optimized touch interactions for mobile devices.</p>
      </div>
    </div>
    
    <div class="faq-item">
      <div class="faq-question">
        <h3>What browsers support this?</h3>
        <div class="question-icon">+</div>
      </div>
      <div class="faq-answer">
        <p>Modern browsers including Chrome, Firefox, Safari, and Edge support all the features. Graceful fallbacks are provided for older browsers.</p>
      </div>
    </div>
  </div>
</div>
     .modern-faq-container {
  min-height: 100vh;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  padding: 2rem;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  position: relative;
  overflow: hidden;
}
.modern-faq-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="20" cy="20" r="2" fill="%23ffffff" opacity="0.1"/><circle cx="80" cy="80" r="2" fill="%23ffffff" opacity="0.1"/><circle cx="40" cy="60" r="1" fill="%23ffffff" opacity="0.2"/></svg>');
  pointer-events: none;
}
.faq-header {
  text-align: center;
  margin-bottom: 3rem;
  position: relative;
  z-index: 2;
}
.faq-header h1 {
  font-size: 3rem;
  color: white;
  margin-bottom: 0.5rem;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
  font-weight: 300;
}
.faq-header p {
  font-size: 1.2rem;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 300;
}
.faq-wrapper {
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}
.faq-item {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 20px;
  margin-bottom: 1.5rem;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}
.faq-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
  background: rgba(255, 255, 255, 0.15);
}
.faq-question {
  padding: 2rem;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}
.faq-question::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, rgba(255, 255, 255, 0.1), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}
.faq-question:hover::before {
  opacity: 1;
}
.faq-question h3 {
  margin: 0;
  font-size: 1.3rem;
  color: white;
  font-weight: 400;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}
.question-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: white;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.3);
}
.faq-item.active .question-icon {
  transform: rotate(45deg);
  background: rgba(255, 255, 255, 0.3);
}
.faq-answer {
  padding: 0 2rem;
  max-height: 0;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  background: rgba(255, 255, 255, 0.05);
}
.faq-item.active .faq-answer {
  padding: 2rem;
  max-height: 300px;
}
.faq-answer p {
  margin: 0;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.7;
  font-size: 1.1rem;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.faq-item {
  animation: fadeInUp 0.6s ease forwards;
}
.faq-item:nth-child(1) { animation-delay: 0.1s; }
.faq-item:nth-child(2) { animation-delay: 0.2s; }
.faq-item:nth-child(3) { animation-delay: 0.3s; }
.faq-item:nth-child(4) { animation-delay: 0.4s; }
@media (max-width: 768px) {
  .modern-faq-container {
    padding: 1rem;
  }
  
  .faq-header h1 {
    font-size: 2.5rem;
  }
  
  .faq-question {
    padding: 1.5rem;
  }
  
  .faq-question h3 {
    font-size: 1.1rem;
  }
  
  .faq-item.active .faq-answer {
    padding: 1.5rem;
  }
}
     document.addEventListener('DOMContentLoaded', function() {
  const faqItems = document.querySelectorAll('.faq-item');
  
  faqItems.forEach(item => {
    const question = item.querySelector('.faq-question');
    
    question.addEventListener('click', () => {
      const isActive = item.classList.contains('active');
      
      // Close all other items
      faqItems.forEach(otherItem => {
        if (otherItem !== item) {
          otherItem.classList.remove('active');
        }
      });
      
      // Toggle current item
      if (isActive) {
        item.classList.remove('active');
      } else {
        item.classList.add('active');
      }
    });
  });
  
  // Add smooth scroll behavior for better UX
  document.querySelectorAll('.faq-question').forEach(question => {
    question.addEventListener('click', function() {
      setTimeout(() => {
        this.scrollIntoView({
          behavior: 'smooth',
          block: 'nearest'
        });
      }, 200);
    });
  });
})