/* ==========================================
   SACRED LOGIN PAGE STYLES - EK SANATAN
========================================== */

#loginContent {
  opacity: 0;
  visibility: hidden;
  transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

#loginContent.show {
  opacity: 1;
  visibility: visible;
}

.main-wrapper {
  transform: translateY(30px);
  opacity: 0;
  transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px 16px;
  position: relative;
  z-index: 10;
}

#loginContent.show .main-wrapper {
  transform: translateY(0);
  opacity: 1;
}

/* Splash Screen */
#splashScreen {
  position: fixed;
  inset: 0;
  z-index: 100000;
  background: radial-gradient(circle at center, #FFFDF9 0%, #F8EFE3 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 16px;
}

.splash-logo {
  width: 140px;
  animation: pulse 1.8s infinite ease-in-out;
  filter: drop-shadow(0 6px 20px rgba(139, 19, 36, 0.15));
}

@keyframes pulse {
  0% {
    transform: scale(0.98);
    opacity: 0.9;
  }
  50% {
    transform: scale(1.04);
    opacity: 1;
  }
  100% {
    transform: scale(0.98);
    opacity: 0.9;
  }
}

/* Intro Video */
#introVideoContainer {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  z-index: 99999;
  background: url("assets/login-bg.svg") center center / cover no-repeat;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

#introVideo {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  object-fit: cover;
  object-position: center;
  display: none;
}

.skip-animation-btn {
  position: fixed;
  top: 25px;
  right: 25px;
  z-index: 100005;
  background: rgba(32, 26, 24, 0.75);
  color: #FFFFFF;
  border: 1.5px solid rgba(212, 175, 55, 0.5);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 8px 20px;
  border-radius: 30px;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.25s ease;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.skip-animation-btn:hover {
  background: linear-gradient(135deg, #8B1324 0%, #6E0B1B 100%);
  border-color: #E5C365;
  color: #FFFFFF;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(139, 19, 36, 0.35);
}

/* Enter Temple Overlay */
#enterTempleOverlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background: linear-gradient(180deg, rgba(253, 251, 247, 0.4) 0%, rgba(253, 251, 247, 0.94) 100%);
  backdrop-filter: blur(4px);
  text-align: center;
  z-index: 5;
  padding: 20px;
}

.enter-logo {
  width: 160px;
  margin-bottom: 24px;
  filter: drop-shadow(0 6px 16px rgba(139, 19, 36, 0.18));
}

#enterTempleOverlay h2 {
  color: #8B1324;
  font-family: var(--font-header, 'Playfair Display', serif);
  font-size: 38px;
  font-weight: 800;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

#enterTempleOverlay p {
  color: #524442;
  font-size: 18px;
  margin-bottom: 30px;
  font-weight: 500;
}

#enterTempleBtn {
  border: none;
  background: linear-gradient(135deg, #8B1324 0%, #6E0B1B 100%);
  color: #FFFFFF;
  padding: 14px 38px;
  border-radius: 50px;
  font-size: 17px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 6px 22px rgba(139, 19, 36, 0.35);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  animation: pulseButton 2.2s infinite;
}

@keyframes pulseButton {
  0% {
    box-shadow: 0 0 0 0 rgba(139, 19, 36, 0.5);
  }
  70% {
    box-shadow: 0 0 0 16px rgba(139, 19, 36, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(139, 19, 36, 0);
  }
}

#enterTempleBtn:hover {
  background: linear-gradient(135deg, #9E1022 0%, #750817 100%);
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 8px 26px rgba(139, 19, 36, 0.45);
}

/* ==========================================
   TEMPLE BELLS ANIMATION
========================================== */
.bells-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  max-width: 780px;
  margin: 0 auto;
  transform: none !important;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  pointer-events: none;
  z-index: 12;
  padding: 0 15px;
  box-sizing: border-box;
}

.bell-item {
  position: relative !important;
  top: 0 !important;
  left: auto !important;
  right: auto !important;
  width: 105px;
  max-width: 16vw;
  height: auto;
  transform-origin: top center;
  pointer-events: auto;
  filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.18));
}

.bell-left {
  position: relative !important;
  left: 0 !important;
  right: auto !important;
  animation: templeBellSwingLeft 3.8s ease-in-out infinite alternate !important;
}

.bell-right {
  position: relative !important;
  right: 0 !important;
  left: auto !important;
  animation: templeBellSwingRight 4.2s ease-in-out infinite alternate !important;
}

.bell-item:hover {
  animation: bellJiggle 0.6s ease-in-out infinite !important;
  cursor: pointer;
}

/* ==========================================
   SACRED LOGIN CARD
========================================== */
.logo-wrapper .logo-img {
  width: 130px;
  height: auto;
  filter: drop-shadow(0 6px 16px rgba(139, 19, 36, 0.12));
}

.login-card {
  width: 100%;
  max-width: 440px;
  background: #FFFFFF;
  border-radius: 24px;
  padding: 28px 28px 24px 28px;
  box-shadow: 0 12px 38px rgba(139, 19, 36, 0.08), 0 2px 6px rgba(0, 0, 0, 0.03);
  border: 1.5px solid #EFE8DE;
  position: relative;
  overflow: hidden;
}

.login-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #8B1324 0%, #DF9B1A 50%, #8B1324 100%);
}

.login-title {
  text-align: center;
  color: #201A18;
  font-family: var(--font-header, 'Playfair Display', serif);
  font-weight: 800;
  font-size: 24px;
  margin-bottom: 6px;
  letter-spacing: -0.01em;
}

.divider {
  display: flex;
  align-items: center;
  margin: 12px auto 16px auto;
  max-width: 160px;
  gap: 8px;
}

.divider::before,
.divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(212, 175, 55, 0.6), transparent);
}

.divider span img {
  height: 16px;
  filter: drop-shadow(0 1px 3px rgba(212, 175, 55, 0.3));
}

/* Switch links */
.login-switch-link {
  color: #8B1324;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.login-switch-link:hover {
  color: #6E0B1B;
  text-decoration: underline;
}

/* MPIN Boxes */
.mpin-box {
  width: 58px;
  height: 58px;
  text-align: center;
  font-size: 26px;
  font-weight: 700;
  border-radius: 14px;
  border: 1.5px solid #E5D9C8;
  background: #FDFBF7;
  color: #201A18;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.02);
}

.mpin-box:focus {
  background: #FFFFFF;
  border-color: #8B1324 !important;
  box-shadow: 0 0 0 3.5px rgba(139, 19, 36, 0.12), inset 0 1px 2px rgba(0,0,0,0.02) !important;
  outline: none;
  transform: translateY(-1px);
}

/* Inputs */
.custom-input {
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.2s ease;
}

.custom-input input {
  height: 48px;
  font-size: 15px;
  border: 1.5px solid #EFE4D6;
  background: #FDFBF7;
  color: #201A18;
  padding: 0 14px;
}

.custom-input input:focus {
  background: #FFFFFF;
  border-color: #8B1324 !important;
  box-shadow: 0 0 0 3px rgba(139, 19, 36, 0.12) !important;
}

.input-group-text.country-code {
  border: 1.5px solid #EFE4D6;
  border-right: none;
  background: #FAF6EF;
  font-weight: 700;
  color: #8B1324;
  padding: 0 14px;
}

.password-box .input-group-text {
  border: 1.5px solid #EFE4D6;
  border-left: none;
  background: #FAF6EF;
}

/* Button */
.login-btn {
  background: linear-gradient(135deg, #8B1324 0%, #6E0B1B 100%) !important;
  border: none !important;
  border-radius: 14px !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  box-shadow: 0 6px 18px rgba(139, 19, 36, 0.28) !important;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.login-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, #9E1022 0%, #750817 100%) !important;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(139, 19, 36, 0.38) !important;
  color: #FFFFFF !important;
}

.login-btn:active:not(:disabled) {
  transform: translateY(0);
}

.login-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

/* Error states */
.input-error,
input.input-error {
  border-color: #DC2626 !important;
  background-color: #FEF2F2 !important;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.12) !important;
}

.field-error {
  min-height: 16px;
  font-weight: 500;
}

/* Responsive Styles */
@media (max-width: 991px) {
  #enterTempleOverlay h2 {
    font-size: 32px;
  }
  #enterTempleOverlay p {
    font-size: 17px;
  }
  .enter-logo {
    width: 140px;
    margin-bottom: 20px;
  }
  .bell-item {
    width: 80px;
  }
}

@media (max-width: 576px) {
  .login-card {
    padding: 22px 18px 20px 18px;
    border-radius: 20px;
  }
  .login-title {
    font-size: 21px;
  }
  .mpin-box {
    width: 48px;
    height: 48px;
    font-size: 22px;
    border-radius: 10px;
  }
  .bell-item {
    width: 60px;
  }
  #enterTempleOverlay h2 {
    font-size: 26px;
  }
  #enterTempleOverlay p {
    font-size: 15px;
    margin-bottom: 22px;
  }
  .enter-logo {
    width: 110px;
    margin-bottom: 15px;
  }
  #enterTempleBtn {
    padding: 12px 28px;
    font-size: 15px;
  }
}

@media (max-width: 380px) {
  .mpin-box {
    width: 42px;
    height: 44px;
    font-size: 20px;
  }
}
