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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  min-height: 100vh;
  background: linear-gradient(135deg, #1a2a6c 0%, #2c3e8a 40%, #3a52a8 70%, #5b6fc4 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}

/* ===== Animated background shapes ===== */
.login-bg {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: 0;
  overflow: hidden;
}

.bg-shape {
  position: absolute;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
  animation: float 12s ease-in-out infinite;
}

.shape1 {
  width: 400px; height: 400px;
  top: -100px; left: -100px;
  animation-delay: 0s;
}

.shape2 {
  width: 300px; height: 300px;
  bottom: -80px; right: -60px;
  animation-delay: 3s;
}

.shape3 {
  width: 200px; height: 200px;
  top: 50%; right: 15%;
  animation-delay: 6s;
}

@keyframes float {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-30px) scale(1.05); }
}

/* ===== Language toggle ===== */
.lang-toggle {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 10;
  display: flex;
  gap: 4px;
  background: rgba(255,255,255,0.15);
  border-radius: 20px;
  padding: 4px;
  backdrop-filter: blur(10px);
}

.lang-btn {
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.6);
  padding: 6px 18px;
  border-radius: 16px;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.25s;
}

.lang-btn:hover {
  color: rgba(255,255,255,0.9);
}

.lang-btn.active {
  background: rgba(255,255,255,0.9);
  color: #2c3e8a;
  font-weight: 600;
}

/* ===== Login card ===== */
.login-container {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 420px;
  padding: 20px;
}

.login-card {
  background: rgba(255,255,255,0.95);
  border-radius: 20px;
  padding: 48px 40px 32px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
  backdrop-filter: blur(20px);
  animation: slideUp 0.5s ease-out;
}

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

/* ===== Header ===== */
.login-header {
  text-align: center;
  margin-bottom: 36px;
}

.login-logo {
  width: 72px;
  height: 72px;
  margin: 0 auto 16px;
  background: linear-gradient(135deg, #3a52a8, #5b6fc4);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  box-shadow: 0 8px 24px rgba(58,82,168,0.35);
}

.login-header h1 {
  font-size: 24px;
  color: #1a2a6c;
  font-weight: 700;
  margin-bottom: 6px;
}

.login-header p {
  font-size: 14px;
  color: #888;
}

/* ===== Form ===== */
.form-group {
  margin-bottom: 22px;
}

.form-group label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: #444;
  margin-bottom: 8px;
}

.input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 14px;
  font-size: 18px;
  opacity: 0.5;
  pointer-events: none;
}

.input-wrap input {
  width: 100%;
  padding: 14px 16px 14px 46px;
  border: 2px solid #e8e8e8;
  border-radius: 12px;
  font-size: 15px;
  font-family: inherit;
  transition: all 0.25s;
  background: #fafafa;
}

.input-wrap input:focus {
  outline: none;
  border-color: #3a52a8;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(58,82,168,0.1);
}

.error-msg {
  background: #fff2f0;
  border: 1px solid #ffccc7;
  border-radius: 8px;
  padding: 10px 16px;
  font-size: 13px;
  color: #ff4d4f;
  margin-bottom: 20px;
  text-align: center;
}

/* ===== Login button ===== */
.login-btn {
  width: 100%;
  padding: 15px;
  background: linear-gradient(135deg, #2c3e8a, #3a52a8);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s;
  letter-spacing: 2px;
}

.login-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(44,62,138,0.4);
}

.login-btn:active {
  transform: translateY(0);
}

.login-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

/* ===== Footer ===== */
.login-footer {
  margin-top: 28px;
  text-align: center;
}

.login-footer p {
  font-size: 12px;
  color: #bbb;
  margin-bottom: 4px;
}

/* ===== Responsive ===== */
@media (max-width: 480px) {
  .login-card {
    padding: 36px 24px 24px;
  }
  .login-header h1 {
    font-size: 20px;
  }
}
