/* ==========================================================================
   Ruqyah Shariah Audio Section Styles
   Ather Radio (Quran Activities)
   ========================================================================== */

/* Ruqyah Hero Section */
.ruqyah-hero {
  margin: 18px 0 28px;
  padding: 36px 30px;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.12) 0%, rgba(15, 23, 42, 0.75) 100%);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: 20px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 16px 40px -10px rgba(0, 0, 0, 0.4);
}

[data-theme="light"] .ruqyah-hero {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.15) 0%, rgba(241, 245, 249, 0.95) 100%);
  border-color: rgba(16, 185, 129, 0.35);
  box-shadow: 0 10px 30px rgba(16, 185, 129, 0.08);
}

.ruqyah-hero::before {
  content: '';
  position: absolute;
  top: -60px;
  right: -60px;
  width: 220px;
  height: 220px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.22) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.ruqyah-badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(16, 185, 129, 0.18);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #34d399;
  padding: 6px 16px;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  margin-bottom: 14px;
}

.ruqyah-hero-title {
  font-size: 2.1rem;
  font-weight: 800;
  color: #f8fafc;
  margin: 0 0 10px;
  line-height: 1.3;
}

[data-theme="light"] .ruqyah-hero-title {
  color: #0f172a;
}

.ruqyah-hero-desc {
  font-size: 1.02rem;
  color: #94a3b8;
  max-width: 720px;
  line-height: 1.6;
  margin: 0 0 24px;
}

[data-theme="light"] .ruqyah-hero-desc {
  color: #475569;
}

/* Ruqyah Search & Filter Bar */
.ruqyah-filter-wrap {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.ruqyah-search-box {
  position: relative;
  max-width: 520px;
  width: 100%;
}

.ruqyah-search-input {
  width: 100%;
  padding: 13px 18px 13px 44px;
  background: rgba(15, 23, 42, 0.85);
  border: 1.5px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  color: #f8fafc;
  font-size: 0.95rem;
  font-family: inherit;
  outline: none;
  transition: all 0.25s ease;
  box-sizing: border-box;
}

[data-theme="light"] .ruqyah-search-input {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.15);
  color: #0f172a;
}

.ruqyah-search-input:focus {
  border-color: #10b981;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.25);
}

.ruqyah-search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  pointer-events: none;
}

/* Category Filter Tabs */
.ruqyah-tabs-container,
.ruqyah-category-pills {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.ruqyah-tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #cbd5e1;
  border-radius: 9999px;
  font-size: 0.86rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

[data-theme="light"] .ruqyah-tab-btn {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.1);
  color: #334155;
}

.ruqyah-tab-btn:hover {
  background: rgba(16, 185, 129, 0.15);
  border-color: rgba(16, 185, 129, 0.35);
  color: #34d399;
}

.ruqyah-tab-btn.active {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  border-color: #10b981;
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.35);
}

.ruqyah-tab-badge {
  padding: 1px 7px;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 9999px;
  font-size: 0.75rem;
}

.ruqyah-tab-btn.active .ruqyah-tab-badge {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

/* Ruqyah Grid Layout */
.ruqyah-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
  gap: 22px;
  margin-bottom: 70px;
}

@media (max-width: 640px) {
  .ruqyah-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

/* Individual Ruqyah Audio Card */
.ruqyah-card {
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  position: relative;
  transition: all 0.28s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 8px 24px -6px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
}

[data-theme="light"] .ruqyah-card {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.08);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.05);
}

.ruqyah-card:hover {
  transform: translateY(-4px);
  border-color: rgba(16, 185, 129, 0.4);
  box-shadow: 0 16px 32px -8px rgba(16, 185, 129, 0.15);
}

.ruqyah-card.is-playing {
  border-color: #10b981;
  background: linear-gradient(145deg, rgba(16, 185, 129, 0.1) 0%, rgba(15, 23, 42, 0.9) 100%);
  box-shadow: 0 16px 36px -6px rgba(16, 185, 129, 0.25);
}

[data-theme="light"] .ruqyah-card.is-playing {
  background: linear-gradient(145deg, rgba(16, 185, 129, 0.08) 0%, #ffffff 100%);
}

/* Card Header: Category & Duration */
.ruqyah-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.ruqyah-category-badge {
  padding: 4px 10px;
  background: rgba(59, 130, 246, 0.12);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 600;
}

.ruqyah-duration-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #94a3b8;
  font-size: 0.78rem;
  font-weight: 500;
}

/* Card Content: Title & Reciter */
.ruqyah-card-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ruqyah-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: #f8fafc;
  margin: 0;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

[data-theme="light"] .ruqyah-title {
  color: #0f172a;
}

.ruqyah-reciter {
  font-size: 0.88rem;
  color: #94a3b8;
  display: flex;
  align-items: center;
  gap: 6px;
}

[data-theme="light"] .ruqyah-reciter {
  color: #64748b;
}

/* Audio Player Section in Card */
.ruqyah-player-box {
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 14px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

[data-theme="light"] .ruqyah-player-box {
  background: rgba(241, 245, 249, 0.8);
  border-color: rgba(0, 0, 0, 0.06);
}

.ruqyah-ctrl-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.ruqyah-play-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4);
  flex-shrink: 0;
}

.ruqyah-play-btn:hover {
  transform: scale(1.06);
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.55);
}

.ruqyah-play-btn:active {
  transform: scale(0.96);
}

.ruqyah-time-display {
  font-size: 0.82rem;
  font-family: 'Outfit', monospace;
  color: #94a3b8;
  font-weight: 500;
}

/* Progress Slider */
.ruqyah-progress-slider {
  width: 100%;
  height: 6px;
  -webkit-appearance: none;
  appearance: none;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 4px;
  outline: none;
  cursor: pointer;
  position: relative;
  transition: background 0.2s ease;
}

[data-theme="light"] .ruqyah-progress-slider {
  background: rgba(0, 0, 0, 0.12);
}

.ruqyah-progress-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #10b981;
  cursor: pointer;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.6);
  transition: transform 0.15s ease;
}

.ruqyah-progress-slider::-webkit-slider-thumb:hover {
  transform: scale(1.3);
}

/* Card Action Footer: Info/Details Button */
.ruqyah-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 4px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

[data-theme="light"] .ruqyah-card-footer {
  border-top-color: rgba(0, 0, 0, 0.05);
}

/* Optional Info Button (only rendered when description or instructions exist) */
.ruqyah-info-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(59, 130, 246, 0.3);
  color: #60a5fa;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.ruqyah-info-btn:hover {
  background: rgba(59, 130, 246, 0.22);
  border-color: rgba(59, 130, 246, 0.5);
  color: #93c5fd;
  transform: translateY(-1px);
}

.ruqyah-speed-btn {
  padding: 5px 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 6px;
  color: #cbd5e1;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

[data-theme="light"] .ruqyah-speed-btn {
  background: rgba(0, 0, 0, 0.05);
  border-color: rgba(0, 0, 0, 0.1);
  color: #334155;
}

.ruqyah-speed-btn:hover {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
}

/* Sound Waves Animation on active card */
.ruqyah-wave-bars {
  display: inline-flex;
  align-items: flex-end;
  gap: 3px;
  height: 16px;
}

.ruqyah-wave-bar {
  width: 3px;
  height: 100%;
  background: #10b981;
  border-radius: 3px;
  animation: wavePulse 1s ease-in-out infinite;
}

.ruqyah-wave-bar:nth-child(2) { animation-delay: 0.2s; height: 60%; }
.ruqyah-wave-bar:nth-child(3) { animation-delay: 0.4s; height: 80%; }
.ruqyah-wave-bar:nth-child(4) { animation-delay: 0.1s; height: 40%; }

@keyframes wavePulse {
  0%, 100% { transform: scaleY(0.3); }
  50% { transform: scaleY(1); }
}

/* ==========================================================================
   Details Modal (Description & How to Listen)
   ========================================================================== */
.ruqyah-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn 0.25s ease;
}

.ruqyah-modal-overlay.open {
  display: flex;
}

.ruqyah-modal-card {
  background: #0f172a;
  border: 1.5px solid rgba(16, 185, 129, 0.35);
  border-radius: 20px;
  max-width: 620px;
  width: 100%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.7), 0 0 35px rgba(16, 185, 129, 0.15);
  animation: modalSlideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-theme="light"] .ruqyah-modal-card {
  background: #ffffff;
  border-color: rgba(16, 185, 129, 0.35);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
}

@keyframes modalSlideUp {
  from { opacity: 0; transform: translateY(20px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.ruqyah-modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

[data-theme="light"] .ruqyah-modal-header {
  border-bottom-color: rgba(0, 0, 0, 0.08);
}

.ruqyah-modal-title-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.ruqyah-modal-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: #10b981;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ruqyah-modal-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #f8fafc;
  margin: 0;
  line-height: 1.35;
}

[data-theme="light"] .ruqyah-modal-title {
  color: #0f172a;
}

.ruqyah-modal-close-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: #94a3b8;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

[data-theme="light"] .ruqyah-modal-close-btn {
  background: rgba(0, 0, 0, 0.06);
  color: #64748b;
}

.ruqyah-modal-close-btn:hover {
  background: rgba(239, 68, 68, 0.2);
  color: #f87171;
  transform: rotate(90deg);
}

.ruqyah-modal-body {
  padding: 24px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Info Box in Modal */
.ruqyah-info-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 16px 18px;
}

[data-theme="light"] .ruqyah-info-box {
  background: rgba(241, 245, 249, 0.7);
  border-color: rgba(0, 0, 0, 0.08);
}

.ruqyah-info-heading {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.95rem;
  font-weight: 700;
  color: #34d399;
  margin: 0 0 10px;
}

.ruqyah-info-text {
  font-size: 0.92rem;
  line-height: 1.65;
  color: #cbd5e1;
  white-space: pre-line;
  margin: 0;
}

[data-theme="light"] .ruqyah-info-text {
  color: #334155;
}

/* Guidelines Box */
.ruqyah-rules-box {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.28);
  border-radius: 14px;
  padding: 18px;
}

.ruqyah-rules-heading {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.98rem;
  font-weight: 700;
  color: #10b981;
  margin: 0 0 10px;
}

/* Quick Sunnah Tips List */
.ruqyah-tips-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}

@media (max-width: 500px) {
  .ruqyah-tips-list {
    grid-template-columns: 1fr;
  }
}

.ruqyah-tip-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.84rem;
  color: #94a3b8;
  line-height: 1.45;
  background: rgba(0, 0, 0, 0.2);
  padding: 10px;
  border-radius: 8px;
}

[data-theme="light"] .ruqyah-tip-item {
  background: #ffffff;
  color: #475569;
}

.ruqyah-tip-dot {
  color: #10b981;
  font-weight: 800;
}

.ruqyah-modal-footer {
  padding: 16px 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

[data-theme="light"] .ruqyah-modal-footer {
  border-top-color: rgba(0, 0, 0, 0.08);
}

.ruqyah-btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 22px;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #ffffff;
  border: none;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.35);
  transition: all 0.2s ease;
}

.ruqyah-btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(16, 185, 129, 0.45);
}

.ruqyah-btn-secondary {
  padding: 10px 18px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

[data-theme="light"] .ruqyah-btn-secondary {
  background: rgba(0, 0, 0, 0.05);
  border-color: rgba(0, 0, 0, 0.1);
  color: #334155;
}

/* Empty State */
.ruqyah-empty-state {
  text-align: center;
  padding: 60px 20px;
  color: #94a3b8;
  grid-column: 1 / -1;
}

.ruqyah-empty-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 16px;
  color: #64748b;
}

.ruqyah-empty-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: #f8fafc;
  margin: 0 0 6px;
}

[data-theme="light"] .ruqyah-empty-title {
  color: #0f172a;
}



/* ==========================================================================
   Ruqyah Mobile Responsive Styles
   ========================================================================== */
@media (max-width: 768px) {
  .ruqyah-hero {
    margin: 12px 0 20px;
    padding: 20px 16px;
    border-radius: 16px;
  }

  .ruqyah-badge-pill {
    padding: 4px 12px;
    font-size: 0.78rem;
    margin-bottom: 10px;
  }

  .ruqyah-hero-title {
    font-size: 1.4rem;
    font-weight: 800;
    margin-bottom: 8px;
    line-height: 1.25;
  }

  .ruqyah-hero-desc {
    font-size: 0.88rem;
    line-height: 1.5;
    margin-bottom: 16px;
  }

  .ruqyah-filter-wrap {
    gap: 12px;
  }

  .ruqyah-search-box {
    max-width: 100%;
  }

  .ruqyah-search-input {
    padding: 11px 16px 11px 40px;
    font-size: 0.88rem;
    border-radius: 10px;
  }

  .ruqyah-search-icon {
    left: 14px;
    width: 16px;
    height: 16px;
  }

  /* Smooth scrollable category pills on mobile */
  .ruqyah-category-pills,
  .ruqyah-tabs-container {
    display: flex;
    align-items: center;
    gap: 8px;
    overflow-x: auto;
    padding: 4px 2px 10px;
    margin: 0 -4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    flex-wrap: nowrap;
  }

  .ruqyah-category-pills::-webkit-scrollbar,
  .ruqyah-tabs-container::-webkit-scrollbar {
    display: none;
  }

  .ruqyah-tab-btn {
    white-space: nowrap;
    flex-shrink: 0;
    padding: 7px 14px;
    font-size: 0.82rem;
  }

  /* Ruqyah Grid & Cards on Mobile */
  .ruqyah-grid {
    grid-template-columns: 1fr;
    gap: 14px;
    margin-bottom: 90px;
  }

  .ruqyah-card {
    padding: 16px;
    border-radius: 14px;
    gap: 14px;
  }

  .ruqyah-card-title {
    font-size: 1.02rem;
    line-height: 1.35;
  }

  .ruqyah-card-reciter {
    font-size: 0.82rem;
  }

  .ruqyah-card-footer {
    padding-top: 12px;
  }

  .ruqyah-card-play-btn {
    padding: 8px 16px;
    font-size: 0.85rem;
  }

  .ruqyah-card-info-btn {
    width: 36px;
    height: 36px;
  }
}
