:root {
  color-scheme: light;
  --brand: #087a67;
  --brand-dark: #075c4e;
  --text: #172c29;
  --muted: #52645f;
  --line: #dce7e2;
  font-family: "Inter", "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-width: 320px; background: #f3f6f5; color: var(--text); }
button, input { font: inherit; }

.login-page {
  display: grid;
  min-height: 100vh;
  padding: 24px;
  place-items: center;
}

.login-card {
  width: min(380px, 100%);
  padding: 38px;
  border: 1px solid #e2ebe7;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 18px 50px rgba(33, 66, 57, .09);
}

.login-card header {
  display: grid;
  justify-items: center;
  gap: 15px;
  margin-bottom: 30px;
}

.brand-mark {
  display: grid;
  width: 54px;
  height: 54px;
  overflow: hidden;
  place-items: center;
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(3, 38, 32, .12);
}

.brand-mark img { width: 100%; height: 100%; object-fit: cover; }
.login-card h1 { margin: 0; font-size: 27px; letter-spacing: -.03em; }

.field { display: grid; gap: 8px; margin-top: 18px; }
.field > span:first-child { color: var(--muted); font-size: 13px; font-weight: 650; }
.field input {
  width: 100%;
  height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 11px;
  outline: 0;
  background: #fff;
  color: var(--text);
}
.field input::placeholder { color: #a1aea9; }
.field input:focus { border-color: #78bca9; box-shadow: 0 0 0 4px rgba(8, 122, 103, .1); }

.password-field { position: relative; display: block; }
.password-field input { padding-right: 64px; }
.password-field button {
  position: absolute;
  top: 50%;
  right: 7px;
  min-width: 48px;
  height: 34px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--brand);
  font-size: 12px;
  cursor: pointer;
}
.password-field button:hover { background: #e8f5f0; }

.form-error {
  margin: 15px 0 0;
  padding: 10px 12px;
  border: 1px solid #efcecb;
  border-radius: 9px;
  background: #fff3f2;
  color: #b3413b;
  font-size: 12px;
}

.submit-button {
  width: 100%;
  height: 48px;
  margin-top: 22px;
  border: 0;
  border-radius: 11px;
  background: var(--brand);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(8, 122, 103, .17);
  transition: transform .15s, background .15s;
}
.submit-button:hover { transform: translateY(-1px); background: var(--brand-dark); }
.submit-button:disabled { cursor: wait; opacity: .7; transform: none; }

@media (max-width: 480px) {
  .login-page { padding: 18px; }
  .login-card { padding: 32px 24px; border-radius: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition-duration: .01ms !important; }
}
