/* ==========================================================================
   Ather Daily Islamic Prayer Times (নামাজের সময়সূচী)
   Powered by UmmahAPI - Unified Ather Dark Glassmorphic Theme
   ========================================================================== */

/* Header & Category Badges */
.prayer-times-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  position: relative;
  transition: all 0.2s ease;
}

.prayer-badge-emerald {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.7rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: var(--radius-full, 9999px);
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.35);
  letter-spacing: 0.02em;
}

.prayer-badge-pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: prayerPulse 1.8s infinite;
}

@keyframes prayerPulse {
  0% { transform: scale(0.9); opacity: 0.7; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.9); opacity: 0.7; }
}

.prayer-times-chip {
  background: rgba(16, 185, 129, 0.1) !important;
  border-color: rgba(16, 185, 129, 0.3) !important;
  color: var(--text-primary) !important;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.prayer-times-chip:hover {
  background: rgba(16, 185, 129, 0.22) !important;
  border-color: #10b981 !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.25);
}

/* ==========================================================================
   Prayer Times Modal Backdrop & Container
   ========================================================================== */
.prayer-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1050;
  background: rgba(4, 9, 16, 0.78);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.prayer-modal-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.prayer-modal-dialog {
  width: 100%;
  max-width: 820px;
  max-height: 92vh;
  overflow-y: auto;
  background: var(--bg-card, #0e1726);
  border: 1px solid rgba(16, 185, 129, 0.28);
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.65), 0 0 30px rgba(16, 185, 129, 0.12);
  padding: 28px;
  position: relative;
  transform: scale(0.94) translateY(12px);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.prayer-modal-backdrop.active .prayer-modal-dialog {
  transform: scale(1) translateY(0);
}

/* Modal Header Bar */
.prayer-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
}

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

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

.prayer-modal-title {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--text-primary, #f8fafc);
  margin: 0;
  line-height: 1.2;
}

.prayer-modal-subtitle {
  font-size: 0.82rem;
  color: var(--text-muted, #94a3b8);
  margin: 2px 0 0;
}

.prayer-modal-close-btn {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-muted, #94a3b8);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.prayer-modal-close-btn:hover {
  background: rgba(239, 68, 68, 0.18);
  border-color: rgba(239, 68, 68, 0.35);
  color: #ef4444;
  transform: rotate(90deg);
}

/* ==========================================================================
   Hero Status & Live Countdown Card
   ========================================================================== */
.prayer-hero-card {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.12) 0%, rgba(6, 78, 59, 0.22) 100%), var(--bg-subtle, #142034);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: 16px;
  padding: 22px 24px;
  margin-bottom: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  position: relative;
  overflow: hidden;
}

.prayer-hero-card::after {
  content: "";
  position: absolute;
  top: -40px;
  right: -40px;
  width: 140px;
  height: 140px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.2) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.prayer-hero-left {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.prayer-next-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #10b981;
}

.prayer-next-name {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--text-primary, #f8fafc);
  line-height: 1.2;
}

.prayer-next-time-at {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-secondary, #cbd5e1);
}

.prayer-countdown-box {
  background: rgba(7, 13, 24, 0.6);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: 14px;
  padding: 12px 20px;
  text-align: center;
  min-width: 190px;
}

.prayer-countdown-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-muted, #94a3b8);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 2px;
}

.prayer-countdown-timer {
  font-family: 'SF Mono', 'Fira Code', 'Consolas', monospace;
  font-size: 1.55rem;
  font-weight: 800;
  color: #10b981;
  letter-spacing: 0.04em;
  text-shadow: 0 0 12px rgba(16, 185, 129, 0.3);
}

.prayer-dates-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 6px;
  font-size: 0.84rem;
  color: var(--text-muted, #94a3b8);
  flex-wrap: wrap;
}

.prayer-hijri-badge {
  background: rgba(245, 158, 11, 0.14);
  border: 1px solid rgba(245, 158, 11, 0.3);
  color: #f59e0b;
  padding: 2px 10px;
  border-radius: 9999px;
}

.prayer-current-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  padding: 4px 12px;
  border-radius: 9999px;
  font-size: 0.84rem;
  margin-bottom: 6px;
  width: fit-content;
}

.prayer-offset-badge {
  background: rgba(59, 130, 246, 0.15);
  border: 1px solid rgba(59, 130, 246, 0.35);
  color: #60a5fa;
  padding: 2px 10px;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 0.76rem;
}

/* ==========================================================================
   Time Adjustment (সময় সমন্বয় / Manual Offset) Bar
   ========================================================================== */
.prayer-adjust-bar {
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: 14px;
  padding: 14px 18px;
  margin-bottom: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.prayer-adjust-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.prayer-adjust-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
  font-weight: 700;
  color: #f8fafc;
}

.prayer-adjust-title svg {
  color: #10b981;
}

.prayer-adjust-hint {
  font-size: 0.78rem;
  font-weight: 400;
  color: #94a3b8;
  margin-left: 6px;
}

.prayer-current-offset-value {
  font-size: 0.8rem;
  font-weight: 700;
  color: #10b981;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  padding: 3px 12px;
  border-radius: 9999px;
  white-space: nowrap;
}

.prayer-offset-pills {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.prayer-offset-btn {
  background: rgba(22, 29, 44, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
  padding: 6px 14px;
  border-radius: 10px;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.prayer-offset-btn:hover {
  background: rgba(16, 185, 129, 0.2);
  border-color: #10b981;
  color: #ffffff;
  transform: translateY(-1px);
}

.prayer-offset-btn.active {
  background: #10b981;
  border-color: #10b981;
  color: #042f2e !important;
  font-weight: 800;
  box-shadow: 0 0 14px rgba(16, 185, 129, 0.45);
}

/* ==========================================================================
   Filter & Location Controls Bar
   ========================================================================== */
.prayer-controls-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 22px;
  background: rgba(20, 32, 52, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  padding: 12px 18px;
}

.prayer-control-group {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.prayer-select {
  background: #0e1726;
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #f8fafc;
  border-radius: 10px;
  padding: 8px 14px;
  font-family: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  outline: none;
  cursor: pointer;
  min-height: 40px;
  transition: all 0.15s ease;
}

.prayer-select:focus {
  border-color: #10b981;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

.prayer-locate-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid rgba(16, 185, 129, 0.35);
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.prayer-locate-btn:hover {
  background: rgba(16, 185, 129, 0.25);
  transform: translateY(-1px);
}

.madhab-toggle-group {
  display: inline-flex;
  background: #0e1726;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 3px;
}

.madhab-pill {
  padding: 6px 12px;
  font-size: 0.8rem;
  font-weight: 700;
  border-radius: 8px;
  background: transparent;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  transition: all 0.15s ease;
}

.madhab-pill.active {
  background: #10b981;
  color: #042f2e;
  font-weight: 800;
}

/* ==========================================================================
   The 7 Daily Prayer Times Cards Grid
   ========================================================================== */
.prayer-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

@media (max-width: 1100px) {
  .prayer-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 640px) {
  .prayer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.prayer-card {
  background: rgba(20, 32, 52, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 16px;
  padding: 18px 12px;
  text-align: center;
  position: relative;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 180px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.prayer-card:hover {
  border-color: rgba(16, 185, 129, 0.45);
  transform: translateY(-4px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

.prayer-card.active-prayer {
  background: linear-gradient(180deg, rgba(16, 185, 129, 0.25) 0%, rgba(14, 23, 38, 0.95) 100%);
  border: 1.5px solid #10b981;
  box-shadow: 0 0 25px rgba(16, 185, 129, 0.35);
  transform: translateY(-3px);
}

.prayer-card.next-prayer {
  border: 1.5px solid rgba(245, 158, 11, 0.65);
  background: linear-gradient(180deg, rgba(245, 158, 11, 0.16) 0%, rgba(14, 23, 38, 0.95) 100%);
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.25);
}

.prayer-card-header {
  margin-bottom: 8px;
}

.prayer-card-arabic {
  font-family: 'Amiri', 'Cairo', serif;
  font-size: 1.35rem;
  font-weight: 700;
  color: #ffffff;
  direction: rtl;
  line-height: 1.1;
  margin-bottom: 4px;
}

.prayer-card-en {
  font-size: 0.92rem;
  font-weight: 800;
  color: #f8fafc;
  margin-bottom: 2px;
}

.prayer-card-bn {
  font-size: 0.78rem;
  font-weight: 600;
  color: #94a3b8;
}

.prayer-card-time {
  font-size: 1.25rem;
  font-weight: 800;
  color: #10b981;
  margin: 12px 0;
  letter-spacing: 0.02em;
}

.prayer-card.next-prayer .prayer-card-time {
  color: #f59e0b;
}

.prayer-card-status {
  font-size: 0.7rem;
  font-weight: 800;
  padding: 4px 8px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.06);
  color: #94a3b8;
  display: inline-block;
  margin-top: auto;
}

.prayer-card-status.status-current,
.prayer-card.active-prayer .prayer-card-status {
  background: rgba(16, 185, 129, 0.25);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.prayer-card-status.status-next,
.prayer-card.next-prayer .prayer-card-status {
  background: rgba(245, 158, 11, 0.25);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

/* ==========================================================================
   Footer Info & Embed Widget Option
   ========================================================================== */
.prayer-modal-footer-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding-top: 14px;
  border-top: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
  font-size: 0.78rem;
  color: var(--text-muted, #94a3b8);
}

.prayer-api-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-secondary, #cbd5e1);
}

.prayer-widget-toggle-btn {
  background: transparent;
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.12));
  color: var(--text-secondary, #cbd5e1);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s;
}

.prayer-widget-toggle-btn:hover {
  background: rgba(16, 185, 129, 0.12);
  color: #10b981;
  border-color: rgba(16, 185, 129, 0.3);
}

.prayer-widget-embed-box {
  margin-top: 14px;
  padding: 16px;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 12px;
  display: none;
}

.prayer-widget-embed-box.active {
  display: block;
}

/* Standalone Page Container */
.prayer-page-main {
  padding: 30px 0 60px;
}

/* ==========================================================================
   Responsive Adaptations
   ========================================================================== */
@media (max-width: 768px) {
  .prayer-modal-dialog {
    padding: 20px 16px;
    border-radius: 16px;
  }
  .prayer-hero-card {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    gap: 16px;
  }
  .prayer-next-tag {
    justify-content: center;
  }
  .prayer-countdown-box {
    width: 100%;
  }
  .prayer-dates-row {
    justify-content: center;
  }
  .prayer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .prayer-controls-bar {
    flex-direction: column;
    align-items: stretch;
  }
  .prayer-control-group {
    justify-content: space-between;
    width: 100%;
  }
  .prayer-select {
    flex: 1;
  }
}

@media (max-width: 480px) {
  .prayer-grid {
    grid-template-columns: 1fr;
  }
}
