/* evany SSO Theme */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }

body {
  min-height: 100vh;
  background: linear-gradient(145deg, #dbeafe 0%, #eff6ff 50%, #e0f2fe 100%);
  font-family: 'Segoe UI', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  color: #1e293b;
  display: flex;
  flex-direction: column;
}

/* Header */
.ev-header {
  background: linear-gradient(135deg, #0d6efd 0%, #0a58ca 100%);
  padding: 14px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 2px 12px rgba(13,110,253,0.2);
  flex-shrink: 0;
}
.ev-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}
.ev-brand-icon {
  width: 36px;
  height: 36px;
  background: rgba(255,255,255,0.2);
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.ev-brand-icon svg { width: 20px; height: 20px; fill: #fff; }
.ev-brand-name {
  font-size: 1.35rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.3px;
}
.ev-brand-name span {
  font-weight: 400;
  font-size: 0.88rem;
  color: rgba(255,255,255,0.75);
  margin-left: 2px;
}
.ev-header-right {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.75);
  display: flex;
  align-items: center;
  gap: 8px;
}
.ev-header-badge {
  background: rgba(255,255,255,0.2);
  border-radius: 6px;
  padding: 3px 10px;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.9);
  font-weight: 500;
}

/* Main */
main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px 16px;
}

/* Login Card */
.ev-login-card {
  width: 100%;
  max-width: 400px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 6px 28px rgba(124,58,237,0.12), 0 2px 8px rgba(0,0,0,0.07);
  overflow: hidden;
}
.ev-card-bar {
  height: 5px;
  background: linear-gradient(90deg, #7c3aed, #9333ea);
}
.ev-card-head {
  padding: 28px 32px 20px;
  text-align: center;
  border-bottom: 1px solid #f1f5f9;
}
.ev-card-icon-wrap {
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, #7c3aed, #9333ea);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 14px;
}
.ev-card-icon-wrap svg { width: 28px; height: 28px; fill: #fff; }
.ev-card-head h1 {
  font-size: 1.05rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 4px;
}
.ev-card-head p {
  font-size: 0.82rem;
  color: #64748b;
  line-height: 1.5;
}
.ev-card-body { padding: 24px 32px 28px; }

/* Form */
.ev-form-group { margin-bottom: 18px; }
.ev-form-group label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 6px;
}
.ev-form-group input[type="text"],
.ev-form-group input[type="password"],
.ev-form-group input[type="email"],
.ev-form-group textarea {
  display: block;
  width: 100%;
  padding: 10px 13px;
  font-size: 0.9rem;
  font-family: inherit;
  border: 1.5px solid #d1d5db;
  border-radius: 8px;
  outline: none;
  background: #f9fafb;
  color: #111827;
  transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
}
.ev-form-group input:focus,
.ev-form-group textarea:focus {
  border-color: #7c3aed;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(124,58,237,0.12);
}

/* Checkbox */
.ev-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: #6b7280;
  margin-top: -6px;
  margin-bottom: 16px;
}
.ev-checkbox input[type="checkbox"] {
  accent-color: #7c3aed;
  width: 15px;
  height: 15px;
  cursor: pointer;
  flex-shrink: 0;
}

/* Buttons */
.ev-btn-login {
  display: block;
  width: 100%;
  padding: 12px;
  font-size: 0.95rem;
  font-weight: 600;
  font-family: inherit;
  color: #fff;
  background: linear-gradient(135deg, #7c3aed, #9333ea);
  border: none;
  border-radius: 8px;
  cursor: pointer;
  letter-spacing: 0.3px;
  transition: opacity 0.15s, transform 0.1s;
  margin-top: 6px;
}
.ev-btn-login:hover { opacity: 0.9; }
.ev-btn-login:active { transform: scale(0.98); }
.ev-btn-login:disabled { opacity: 0.6; cursor: not-allowed; }

.ev-btn-secondary {
  display: block;
  width: 100%;
  padding: 10px;
  font-size: 0.88rem;
  font-weight: 600;
  font-family: inherit;
  color: #7c3aed;
  background: #f5f3ff;
  border: 1.5px solid #ddd6fe;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s;
  margin-top: 8px;
}
.ev-btn-secondary:hover { background: #ede9fe; }

/* Alert */
.ev-alert {
  border-radius: 8px;
  padding: 11px 14px;
  font-size: 0.83rem;
  margin-bottom: 18px;
  line-height: 1.55;
}
.ev-alert-error {
  background: #fef2f2;
  border: 1px solid #fca5a5;
  color: #b91c1c;
}
.ev-alert-warn {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
}
.ev-alert h4 {
  font-weight: 700;
  margin-bottom: 3px;
  font-size: 0.85rem;
}

/* Track ID */
.ev-trackid {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 12px 14px;
  margin-bottom: 18px;
}
.ev-trackid-label {
  font-size: 0.76rem;
  color: #64748b;
  margin-bottom: 5px;
}
.ev-trackid-value {
  font-family: 'Courier New', 'Menlo', monospace;
  font-size: 0.88rem;
  color: #1e293b;
  font-weight: 600;
}

/* Debug */
.ev-debug {
  background: #1e293b;
  color: #94a3b8;
  border-radius: 8px;
  padding: 10px 14px;
  margin-bottom: 14px;
  font-size: 0.76rem;
}
.ev-debug summary {
  color: #cbd5e1;
  cursor: pointer;
  font-weight: 600;
}
.ev-debug pre {
  white-space: pre-wrap;
  word-break: break-all;
  margin-top: 8px;
}

/* Divider */
.ev-divider {
  border: none;
  border-top: 1px solid #e5e7eb;
  margin: 20px 0;
}

/* Card Footer */
.ev-card-footer {
  padding: 0 32px 20px;
  text-align: center;
  font-size: 0.78rem;
  color: #9ca3af;
  line-height: 1.55;
}

/* Page Footer */
.ev-page-footer {
  text-align: center;
  padding: 16px;
  font-size: 0.74rem;
  color: #94a3b8;
  flex-shrink: 0;
}

@media (max-width: 480px) {
  .ev-header { padding: 12px 16px; }
  .ev-card-body { padding: 20px 20px 24px; }
  .ev-card-head { padding: 22px 20px 16px; }
  .ev-card-footer { padding: 0 20px 18px; }
}
