.auth-page {
  min-height: 100vh;
  background: linear-gradient(135deg, var(--primary-500) 0%, var(--primary-700) 50%, var(--primary-900) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-6);
  position: relative;
  overflow: hidden;
}

.auth-page::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.auth-container {
  width: 100%;
  max-width: 440px;
  position: relative;
  z-index: 1;
}

.auth-card {
  background: rgba(255, 255, 255, 0.95);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-2xl);
  overflow: hidden;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: var(--transition-slow);
}

.auth-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-2xl), 0 20px 40px rgba(0,0,0,0.1);
}

.auth-header {
  background: linear-gradient(135deg, var(--primary-600), var(--primary-700));
  color: white;
  padding: var(--space-8);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.auth-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.1'%3E%3Cpath d='M0 0h40v40H0V0zm1 1h38v38H1V1z'/%3E%3C/g%3E%3C/svg%3E");
}

.auth-header-content {
  position: relative;
  z-index: 1;
}

.auth-header h1 {
  margin: 0 0 var(--space-2) 0;
  font-size: var(--text-3xl);
  font-weight: 800;
  background: linear-gradient(135deg, white, var(--primary-100));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.auth-header p {
  margin: 0;
  opacity: 0.9;
  font-size: var(--text-lg);
  font-weight: 500;
}

.auth-form {
  padding: var(--space-8);
}

.form-group {
  margin-bottom: var(--space-6);
}

.form-group label {
  display: block;
  margin-bottom: var(--space-2);
  font-weight: 600;
  color: var(--gray-700);
  font-size: var(--text-sm);
}

.form-group input {
  width: 100%;
  padding: var(--space-4);
  border: 2px solid var(--gray-300);
  border-radius: var(--radius-xl);
  font-size: var(--text-base);
  transition: var(--transition);
  background: white;
  font-family: inherit;
}

.form-group input:focus {
  outline: none;
  border-color: var(--primary-500);
  box-shadow: 0 0 0 4px rgb(59 130 246 / 0.1);
  transform: translateY(-1px);
}

.btn-full {
  width: 100%;
  padding: var(--space-4);
  font-size: var(--text-base);
  font-weight: 700;
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, var(--primary-500), var(--primary-600));
  color: white;
  border: none;
  cursor: pointer;
  transition: var(--transition-slow);
  position: relative;
  overflow: hidden;
}

.btn-full::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left 0.5s;
}

.btn-full:hover {
  background: linear-gradient(135deg, var(--primary-600), var(--primary-700));
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-full:hover::before {
  left: 100%;
}

.auth-footer {
  padding: var(--space-6) var(--space-8);
  background: var(--gray-50);
  border-top: 1px solid var(--gray-200);
  text-align: center;
}

.auth-footer p {
  margin-bottom: var(--space-3);
  font-size: var(--text-sm);
  color: var(--gray-600);
}

.auth-link {
  color: var(--primary-600);
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition);
}

.auth-link:hover {
  color: var(--primary-700);
  text-decoration: underline;
}

.demo-accounts {
  font-size: var(--text-xs);
  text-align: left;
  background: var(--gray-100);
  padding: var(--space-4);
  border-radius: var(--radius-lg);
  margin-top: var(--space-4);
  border-left: 4px solid var(--primary-500);
}

.demo-accounts h4 {
  margin-bottom: var(--space-2);
  color: var(--gray-700);
  font-size: var(--text-sm);
}

.demo-account {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-2) 0;
  border-bottom: 1px solid var(--gray-200);
}

.demo-account:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.demo-role {
  font-weight: 600;
  color: var(--primary-600);
}

.demo-email {
  color: var(--gray-600);
  font-family: 'Monaco', 'Consolas', monospace;
  font-size: 0.7rem;
}

.demo-password {
  color: var(--gray-500);
  font-size: 0.7rem;
}

/* Responsive Auth */
@media (max-width: 640px) {
  .auth-page {
    padding: var(--space-4);
  }
  
  .auth-card {
    border-radius: var(--radius-xl);
  }
  
  .auth-header {
    padding: var(--space-6);
  }
  
  .auth-header h1 {
    font-size: var(--text-2xl);
  }
  
  .auth-form {
    padding: var(--space-6);
  }
  
  .demo-account {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-1);
  }
}

/* Loading State */
.btn-loading {
  pointer-events: none;
  opacity: 0.8;
}

.btn-loading::after {
  content: '';
  width: 16px;
  height: 16px;
  border: 2px solid transparent;
  border-top: 2px solid white;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-left: var(--space-2);
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Error States */
.form-group.error input {
  border-color: var(--error-500);
  box-shadow: 0 0 0 4px rgb(239 68 68 / 0.1);
}

.error-message {
  color: var(--error-600);
  font-size: var(--text-sm);
  margin-top: var(--space-1);
  font-weight: 500;
}

/* Success States */
.form-group.success input {
  border-color: var(--success-500);
  box-shadow: 0 0 0 4px rgb(34 197 94 / 0.1);
}