/* ===============================
   templates/login.css
   Login Template
   ✅ Updated with Standardized Colors & Fonts
================================ */

/* Import core and utils */
@import url('../core/base.css');

/* Import components */
@import url('../components/button.css');
@import url('../components/input.css');
@import url('../components/input-group.css');

/* Page-specific styles */
body[data-page="login"] {
  min-height: 100vh;
  overflow-y: auto;
  background: var(--action-bg);
  color: var(--header-bg);
  font-family: var(--font-main);
}

body[data-page="login"] .login-center {
  margin-top: 0;
  text-align: center;
}

/* Center login section */
.login-center-wrapper {
  width: 100%;
  max-width: 100vw;
  box-sizing: border-box;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  overflow-x: hidden;
  opacity: 0;
  animation: loginFadeUp 0.6s ease forwards;
}

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

/* Login content */
.login-title {
  font-size: 24px;
  font-weight: var(--font-bold);
  color: var(--header-bg);
  margin-bottom: 6px;
}

.login-subtitle {
  color: var(--header-bg);
  font-size: var(--font-input);
  margin-bottom: var(--space-lg);
}

.login-footer {
  margin-top: var(--space-lg);
  color: var(--header-bg);
  font-size: var(--font-footer);
}

/* Logo */
.login-logo-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 26px;
}

.login-logo {
  width: 180px;
  height: 40px;
  object-fit: contain;
  animation: logoFade 0.6s ease-out forwards;
}

@keyframes logoFade {
  from {
    opacity: 0;
    transform: scale(0.96);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Messages */
#message {
  margin-top: var(--gap-md);
  min-height: 20px;
  color: var(--status-error);
  font-size: var(--font-input);
  font-weight: var(--font-regular);
}

#message.success {
  color: var(--status-success);
}

#message.error {
  color: var(--status-error);
}

#message.info {
  color: var(--status-info);
}

#message.warning {
  color: var(--status-warning);
}

/* Footer links */
.login-footer a {
  color: var(--header-bg);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.login-footer a:hover {
  color: var(--button-bg);
  text-decoration: underline;
}

.footer-sep {
  margin: 0 6px;
  color: var(--border-color);
}

@media (max-width: 600px) {
  .login-center-wrapper {
    justify-content: center;
    padding: 48px 20px 32px;
    box-sizing: border-box;
  }

  .login-title {
    font-size: 20px;
  }

  .login-logo {
    width: 140px;
    height: auto;
  }

  .submit-btn {
    width: 36px;
    height: 36px;
  }

  .eye-btn svg,
  .submit-btn svg {
    width: 18px;
    height: 18px;
  }
}

@media (max-height: 500px) {
  .login-center-wrapper {
    justify-content: flex-start;
    padding-top: 24px;
  }
}
