/* ── Live Sanctuary ── */

.sac-sanctuary {
  position: relative;
  min-height: 100vh;
  background: #0d0a1a;
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* ── Ambient Background ── */
.sac-sanctuary__bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}
.sac-sanctuary__bg-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: .25;
}
.sac-sanctuary__bg-glow--1 {
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(81,71,134,0.6) 0%, transparent 70%);
  top: -10%;
  left: -10%;
  animation: sac-glow-drift 20s ease-in-out infinite alternate;
}
.sac-sanctuary__bg-glow--2 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(138,92,246,0.4) 0%, transparent 70%);
  bottom: -15%;
  right: -5%;
  animation: sac-glow-drift 25s ease-in-out infinite alternate-reverse;
}
.sac-sanctuary__bg-glow--3 {
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(255,200,80,0.15) 0%, transparent 70%);
  top: 30%;
  left: 50%;
  transform: translateX(-50%);
  animation: sac-glow-pulse 8s ease-in-out infinite;
}
@keyframes sac-glow-drift {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(40px, 30px) scale(1.15); }
}
@keyframes sac-glow-pulse {
  0%, 100% { opacity: .15; transform: translateX(-50%) scale(1); }
  50%      { opacity: .3;  transform: translateX(-50%) scale(1.1); }
}

/* When live — warmer ambient */
.sac-sanctuary.is-live .sac-sanctuary__bg-glow--3 {
  opacity: .35;
  width: 500px;
  height: 500px;
}

/* ── Welcome (offline) ── */
.sac-sanctuary__welcome {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  width: 100%;
  padding: 80px 24px;
}
.sac-sanctuary__welcome-inner {
  text-align: center;
  max-width: 520px;
}
.sac-sanctuary__candle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  background: rgba(255,200,80,0.08);
  border-radius: 50%;
  border: 1px solid rgba(255,200,80,0.12);
  margin-bottom: 28px;
  color: rgba(255,200,80,0.7);
  animation: sac-candle-flicker 3s ease-in-out infinite;
}
@keyframes sac-candle-flicker {
  0%, 100% { opacity: .7; transform: scale(1); }
  30%      { opacity: 1;  transform: scale(1.04); }
  60%      { opacity: .8; transform: scale(0.98); }
}
.sac-sanctuary__welcome-title {
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 900;
  margin: 0 0 16px;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.sac-sanctuary__welcome-sub {
  font-size: 17px;
  line-height: 1.7;
  color: rgba(255,255,255,0.6);
  margin: 0 0 36px;
}
.sac-sanctuary__service-times {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  margin-bottom: 36px;
}
.sac-sanctuary__service-time {
  text-align: center;
}
.sac-sanctuary__service-day {
  display: block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: rgba(255,255,255,0.4);
  margin-bottom: 4px;
}
.sac-sanctuary__service-hour {
  display: block;
  font-size: 18px;
  font-weight: 800;
  color: #fff;
}
.sac-sanctuary__service-divider {
  width: 1px;
  height: 36px;
  background: rgba(255,255,255,0.12);
}
.sac-sanctuary__welcome-verse {
  font-size: 14px;
  font-style: italic;
  color: rgba(255,255,255,0.35);
  line-height: 1.6;
  margin: 0;
}

/* ── Live Stream ── */
.sac-sanctuary__stream {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1100px;
  padding: 40px 24px 0;
}
.sac-sanctuary__stream-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
}
.sac-sanctuary__live-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #e53e3e;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .12em;
  padding: 5px 12px;
  border-radius: 4px;
  flex-shrink: 0;
}
.sac-sanctuary__live-dot {
  width: 7px;
  height: 7px;
  background: #fff;
  border-radius: 50%;
  animation: sac-live-pulse 1.4s ease-in-out infinite;
}
@keyframes sac-live-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: .4; transform: scale(.8); }
}
.sac-sanctuary__stream-title {
  font-size: 15px;
  font-weight: 600;
  color: rgba(255,255,255,0.75);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sac-sanctuary__player-wrap {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  background: #000;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 32px 80px rgba(0,0,0,0.6);
}
.sac-sanctuary__player-wrap #sac-yt-player,
.sac-sanctuary__player-wrap iframe {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  border: none;
}

/* ── Action Buttons ── */
/* ── Floating Sidebar ── */
.sac-sanctuary__sidebar {
  position: fixed;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  z-index: 999;
  display: flex;
  flex-direction: row;
  align-items: center;
}
.sac-sanctuary__sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: rgba(10,8,20,0.85);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.1);
  border-left: none;
  border-radius: 0 12px 12px 0;
  padding: 14px 10px;
  width: 56px;
  overflow: hidden;
  transition: width 0.3s ease;
}
.sac-sanctuary__sidebar.is-open .sac-sanctuary__sidebar-nav {
  width: 200px;
}
.sac-sanctuary__sidebar-toggle {
  display: none;
  position: absolute;
  right: -14px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(109,40,217,0.9);
  border: 1px solid rgba(255,255,255,0.2);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  padding: 0;
  transition: background 0.2s;
}
.sac-sanctuary__sidebar-toggle:hover {
  background: #7c3aed;
}
.sac-sidebar-arrow {
  transition: transform 0.3s ease;
  transform: rotate(180deg);
}
.sac-sanctuary__sidebar.is-open .sac-sidebar-arrow {
  transform: rotate(0deg);
}
.sac-sanctuary__sidebar-nav:hover .sac-sidebar-arrow {
  transform: rotate(0deg);
}
.sac-sanctuary__sidebar-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 6px;
  border-radius: 8px;
  text-decoration: none;
  color: rgba(255,255,255,0.8);
  white-space: nowrap;
  transition: background 0.2s, color 0.2s;
  
}
.sac-sanctuary__sidebar-item:hover {
  background: rgba(255,255,255,0.1);
  color: #fff;
  text-decoration: none;
}
.sac-sanctuary__sidebar-item--primary .sac-sidebar-icon {
  color: #a78bfa;
}
.sac-sidebar-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
}
.sac-sidebar-label {
  font-size: 13px;
  font-weight: 600;
  opacity: 0;
  transition: opacity 0.2s ease 0.05s;
  pointer-events: none;
}
.sac-sanctuary__sidebar.is-open .sac-sidebar-label {
  opacity: 1;
}
.sac-sanctuary__sidebar-nav:hover {
  width: 200px;
}
.sac-sanctuary__sidebar-nav:hover .sac-sidebar-label {
  opacity: 1;
}
@media (max-width: 640px) {
  .sac-sanctuary__sidebar {
    top: auto;
    bottom: 20px;
    transform: none;
  }
  .sac-sanctuary__sidebar-toggle {
    display: flex;
  }
}

/* ── Status / Warnings ── */
.sac-sanctuary__status {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 600px;
  padding: 0 24px 32px;
  text-align: center;
}
.sac-sanctuary__status-msg {
  font-size: 13px;
  padding: 10px 16px;
  border-radius: 8px;
  margin: 0;
}
.sac-sanctuary__status-msg--warn {
  background: rgba(255,200,80,0.08);
  border: 1px solid rgba(255,200,80,0.2);
  color: rgba(255,200,80,0.8);
}

/* ── Responsive ── */
@media (max-width: 640px) {
  .sac-sanctuary__service-times {
    flex-direction: column;
    gap: 16px;
  }
  .sac-sanctuary__service-divider {
    width: 40px;
    height: 1px;
  }
  .sac-sanctuary__stream {
    padding: 24px 16px 0;
  }
}

/* ── Sanctuary Modal Overlays ── */
.sac-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: rgba(0,0,0,0.75);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  box-sizing: border-box;
}
.sac-modal-overlay.is-open {
  display: flex;
}
.sac-modal-box {
  background: #1a1a2e;
  border: 1px solid rgba(139,92,246,0.3);
  border-radius: 16px;
  overflow: hidden;
  max-height: 90vh;
  overflow-y: auto;
  width: 100%;
}
@media (max-width: 640px) {
  #sac-arkpay-modal > div,
  #sac-connect-modal > div,
  #sac-prayer-modal > div,
  #sac-bible-modal > div {
    width: 98%;
    max-height: 92vh;
  }
  #sac-bible-modal > div {
    height: 85vh;
  }
}
