/* Dimmed background */
.loginpagesection {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  z-index: 1000;
  
}

.loginpagesection.active {
  opacity: 1;
  pointer-events: auto;
}

/* Login container starts from top-right (off-screen) */
.leafy-auth-container {
  background-color: #fff;
  color: #0e0e1cfa;
  font-family: 'Segoe UI', sans-serif;
  width: 420px;
  max-width: 90%;
  padding: 2rem;
  border-radius: 16px;
  box-shadow: 0 40px 80px rgba(0, 0, 0, 0.3);
  opacity: 0;
  transform: translate(200%, -100%) scale(0.4);
  transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.6s ease;
  position: relative;
  text-align: center;
  
}

.loginpagesection.active .leafy-auth-container {
  opacity: 1;
  transform: translate(0, 0) scale(1);
}
/* Default: light theme */
.login-leafy-dark {
  display: none;
}

/* Dark mode */
body.dark-mode .login-leafy-light {
  display: none;
}

body.dark-mode .login-leafy-dark {
  display: inline-block;
}

/* Close Button */
.close-btn {
  position: absolute;
  top: 12px;
  right: 16px;
  background: none;
  border: none;
  font-size: 2rem;
  color: #373333;
  cursor: pointer;
  transition: color 0.3s ease;
}

.close-btn:hover {
  color: #e74c3c;
}



 .leafy-auth-logo {
   width: 100%;
   max-width: 280px;
   border-radius: 10px;
   margin-bottom: 1.5rem;
 }

 .leafy-auth-container h1 {
   font-size: 1.8rem;
   margin-bottom: 0.5rem;
 }

 .leafy-sub-text {
   margin-bottom: 1.5rem;
   font-size: 0.75rem;
 }

 .leafy-or {
   font-size: 0.9rem;
   margin-bottom: 1rem;
   color: #544949;
 }

 body.dark-mode .github img {
   filter: invert();
 }

 body.dark-mode .apple img {
   filter: invert();
 }

 body.dark-mode .leafy-auth-container {
    background-color: #181818;
    box-shadow: 2px 2px 7px rgb(10 10 10);
   color: #ffffff;
 }


 .leafy-auth-button {
   display: flex;
   align-items: center;
   justify-content: center;
   padding: 12px;
   width: 100%;
   margin: 0.5rem 0;
   border-radius: 6px;
   font-weight: bold;
   border: none;
   cursor: pointer;
   transition: 0.2s ease-in-out;
   font-size: 0.95rem;
 }

 .leafy-auth-button img {
   height: 20px;
   margin-right: 10px;
 }

 .leafy-auth-button.google {
   background-color: #149546;
   color: white;
 }

 .leafy-auth-button.github,
 .leafy-auth-button.apple {
   background-color: transparent;
   color: #0e0e1cfa;
   border: 1px solid #444;
 }
  .leafy-auth-button.apple{
    color: #0e0e1cfa;
  }

 body.dark-mode .leafy-auth-button.github{
   color: #ffffff;
 }
 body.dark-mode .leafy-auth-button.apple{
   color: #ffffff;
 }

 .leafy-terms {
   font-size: 0.75rem;
   color: #716161;
   margin-top: 1.5rem;
   line-height: 1.4;
 }

 .leafy-terms a {
   color: #4e8ef7;
   text-decoration: none;
 }

 .leafy-terms a:hover {
   text-decoration: underline;
 }

 .leafy-explore {
   margin-top: 1.2rem;
   font-size: 0.85rem;
 }

 .leafy-explore a {
   color: #4e8ef7;
   text-decoration: none;
 }

 .leafy-explore a:hover {
   text-decoration: underline;
 }