/* GroupMNK-Inspired Login Page Design */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
  --primary-teal: #106073;
  --accent-teal: #49bfb5;
  --light-teal: #0a9ba5;
  --mint-bg: #F3FFFE;
  --text-dark: #4a4a4a;
  --text-light: #6b6b6b;
  --white: #ffffff;
  --shadow-natural: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-deep: 0 4px 16px rgba(0, 0, 0, 0.12);
}

* {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Hero Section */
.login-hero {
  background: linear-gradient(135deg, var(--primary-teal) 0%, var(--light-teal) 100%);
  padding: 3rem 0 2.5rem;
  margin-bottom: 3rem;
  position: relative;
  overflow: hidden;
}

.login-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="40" height="40" patternUnits="userSpaceOnUse"><path d="M 40 0 L 0 0 0 40" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
  opacity: 0.5;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}

.hero-title {
  color: var(--white);
  font-size: clamp(1.75rem, 4vw, 3rem);
  font-weight: 600;
  margin-bottom: 0.75rem;
  letter-spacing: -0.5px;
  line-height: 1.2;
}

.hero-subtitle {
  color: rgba(255, 255, 255, 0.95);
  font-size: clamp(0.95rem, 1.8vw, 1.15rem);
  font-weight: 300;
  line-height: 1.6;
  margin: 0;
}

/* Main Section */
.login-main-section {
  padding: 2rem 0 4rem;
  min-height: 50vh;
}

.container {
  max-width: 550px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Login Card */
.login-card {
  background: var(--white);
  border-radius: 12px;
  padding: 2.5rem;
  box-shadow: var(--shadow-deep);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.login-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.card-header-custom {
  margin-bottom: 2rem;
  text-align: center;
}

.card-title-custom {
  color: var(--primary-teal);
  font-size: 1.75rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  letter-spacing: -0.3px;
}

.card-subtitle-custom {
  color: var(--text-light);
  font-size: 0.95rem;
  font-weight: 400;
  margin: 0;
}

/* Form Styling */
.login-form {
  margin-bottom: 1.5rem;
}

.form-group-custom {
  margin-bottom: 1.5rem;
}

.form-label-custom {
  color: var(--text-dark);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  display: block;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.required-indicator {
  color: var(--accent-teal);
  margin-right: 0.25rem;
}

.form-input-custom {
  width: 100%;
  padding: 0.875rem 1rem;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 1rem;
  color: var(--text-dark);
  transition: all 0.3s ease;
  background: var(--white);
}

.form-input-custom:focus {
  outline: none;
  border-color: var(--accent-teal);
  box-shadow: 0 0 0 3px rgba(73, 191, 181, 0.1);
  background: var(--white);
}

.form-input-custom::placeholder {
  color: #a0a0a0;
  font-weight: 300;
}

/* Form Actions */
.form-actions {
  margin-top: 2rem;
}

.btn-login-custom {
  width: 100%;
  background: var(--primary-teal);
  color: var(--white);
  border: none;
  border-radius: 8px;
  padding: 0.875rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  box-shadow: var(--shadow-natural);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-login-custom:hover {
  background: var(--light-teal);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(16, 96, 115, 0.25);
}

.btn-login-custom:active {
  transform: translateY(0);
  box-shadow: var(--shadow-natural);
}

.btn-login-custom:disabled {
  background: var(--text-light);
  cursor: not-allowed;
  transform: none;
}

.btn-icon {
  transition: transform 0.3s ease;
}

.btn-login-custom:hover .btn-icon {
  transform: translateX(4px);
}

/* Form Footer */
.form-footer {
  text-align: center;
  margin-top: 1.5rem;
}

.link-custom {
  color: var(--primary-teal);
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.3s ease;
}

.link-custom:hover {
  color: var(--accent-teal);
  text-decoration: underline;
}

/* OTP Section */
.otp-form {
  text-align: center;
}

.qr-container {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 2rem 0;
  padding: 1.5rem;
  background: var(--mint-bg);
  border-radius: 12px;
  border: 2px dashed var(--accent-teal);
}

.qr-image {
  max-width: 200px;
  height: auto;
  border-radius: 8px;
}

.otp-input {
  text-align: center;
  font-size: 1.5rem;
  letter-spacing: 0.5rem;
  font-weight: 600;
}

/* Status Message */
.status-message {
  margin-top: 1rem;
}

.status-message .alert {
  border-radius: 8px;
  padding: 1rem;
  margin: 0;
  font-size: 0.9rem;
}

/* Responsive Design */
@media (max-width: 768px) {
  .login-hero {
    padding: 2.5rem 0 2rem;
  }

  .hero-title {
    font-size: 1.75rem;
  }

  .hero-subtitle {
    font-size: 0.95rem;
  }

  .login-card {
    padding: 2rem 1.5rem;
  }

  .card-title-custom {
    font-size: 1.5rem;
  }

  .container {
    max-width: 100%;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 1rem;
  }

  .login-card {
    padding: 1.5rem 1rem;
  }

  .form-input-custom {
    padding: 0.75rem 0.875rem;
  }

  .btn-login-custom {
    padding: 0.75rem 1.25rem;
  }

  .qr-container {
    padding: 1rem;
  }

  .qr-image {
    max-width: 180px;
  }
}

/* Loading State */
.btn-login-custom.loading {
  background: var(--text-light);
  cursor: not-allowed;
  pointer-events: none;
}

/* Alert Styling */
.alert {
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 1rem;
  border: none;
  box-shadow: var(--shadow-natural);
  font-size: 0.95rem;
}

.alert-danger {
  background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
  color: white;
}

.alert-warning {
  background: linear-gradient(135deg, #ffd93d 0%, #ffb700 100%);
  color: #333;
}

.alert-success {
  background: linear-gradient(135deg, #51cf66 0%, #37b24d 100%);
  color: white;
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.login-card {
  animation: fadeIn 0.5s ease;
}
