:root {
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-light: #dbeafe;
  --text-main: #1f2937;
  --text-secondary: #6b7280;
  --border: #e5e7eb;
  --bg: #f8fafc;
  --white: #ffffff;
  --danger: #ef4444;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text-main);
  min-height: 100vh;
}

.login-wrapper {
  display: flex;
  min-height: 100vh;
}

.login-left {
  flex: 1;
  background: linear-gradient(135deg, #1e40af 0%, #2563eb 100%);
  color: var(--white);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 16px;
}

.logo {
  width: 64px;
  height: 64px;
  object-fit: contain;
  background: var(--white);
  border-radius: 12px;
  padding: 8px;
}

.brand-text h1 {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 1px;
}

.brand-text p {
  font-size: 16px;
  opacity: 0.9;
  margin-top: 4px;
}

.slogan h2 {
  font-size: 36px;
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 24px;
}

.slogan p {
  font-size: 18px;
  line-height: 1.8;
  opacity: 0.9;
  max-width: 520px;
}

.contact p {
  font-size: 14px;
  opacity: 0.85;
  margin-bottom: 6px;
}

.login-right {
  width: 520px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  background: var(--white);
}

.login-box {
  width: 100%;
  max-width: 400px;
}

.login-box h3 {
  font-size: 26px;
  font-weight: 600;
  margin-bottom: 24px;
  color: var(--text-main);
}

.login-box h4 {
  font-size: 22px;
  font-weight: 600;
  margin-bottom: 20px;
  color: var(--text-main);
}

.mode-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
  border-bottom: 2px solid var(--border);
}

.mode-tab {
  flex: 1;
  padding: 12px 0;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 15px;
  cursor: pointer;
  position: relative;
  transition: color 0.2s;
}

.mode-tab.active {
  color: var(--primary);
  font-weight: 600;
}

.mode-tab.active::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 100%;
  height: 2px;
  background: var(--primary);
}

.form-group {
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.form-group input[type="text"],
.form-group input[type="password"],
.form-group input[type="tel"] {
  width: 100%;
  height: 44px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 15px;
  color: var(--text-main);
  background: var(--white);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-light);
}

.captcha-input {
  display: flex;
  gap: 12px;
}

.captcha-input input {
  flex: 1;
}

.captcha-box {
  width: 120px;
  height: 44px;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  background: #f3f4f6;
  display: flex;
  align-items: center;
  justify-content: center;
}

.captcha-box svg {
  width: 100%;
  height: 100%;
}

.error-msg {
  color: var(--danger);
  font-size: 13px;
  min-height: 20px;
  margin-bottom: 10px;
}

.btn-login {
  width: 100%;
  height: 46px;
  background: var(--primary);
  color: var(--white);
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-login:hover {
  background: var(--primary-dark);
}

.btn-login:disabled {
  background: #93c5fd;
  cursor: not-allowed;
}

.form-actions {
  display: flex;
  justify-content: space-between;
  margin-top: 16px;
}

.form-actions.center {
  justify-content: center;
}

.form-actions a {
  color: var(--primary);
  font-size: 14px;
  text-decoration: none;
}

.form-actions a:hover {
  text-decoration: underline;
}

.login-footer {
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--text-secondary);
  text-align: center;
  line-height: 1.6;
}

.login-footer a {
  color: var(--primary);
  text-decoration: none;
}

.hidden {
  display: none !important;
}

@media (max-width: 900px) {
  .login-left {
    display: none;
  }
  .login-right {
    width: 100%;
  }
}
