:root {
  color-scheme: light;
  font-family: "SF Pro Display", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  background: #eef2ee;
  color: #13201d;
  --ink: #13201d;
  --muted: #68746f;
  --line: rgba(19, 32, 29, 0.14);
  --accent: #174c42;
  --accent-hover: #286257;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  min-height: 100dvh;
  background: #eef2ee;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

button, input { font: inherit; }

.login-shell {
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  grid-template-columns: minmax(340px, 0.9fr) minmax(480px, 1.1fr);
}

.login-context {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(32px, 5vw, 72px);
  color: #f3f7f5;
  background:
    radial-gradient(circle at 86% 18%, rgba(121, 173, 159, 0.23), transparent 28rem),
    linear-gradient(145deg, #0e342d, #142d28 62%, #101f1c);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  width: fit-content;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.09);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: -0.04em;
}

.brand-copy strong, .brand-copy small { display: block; white-space: nowrap; }
.brand-copy strong { font-size: 1rem; }
.brand-copy small { margin-top: 3px; color: rgba(243, 247, 245, 0.68); font-size: 0.72rem; }

.context-copy { max-width: 570px; padding-block: 80px; }
.eyebrow { margin: 0 0 18px; color: #8cc1b3; font-size: 0.72rem; font-weight: 800; letter-spacing: 0.16em; }
.context-copy h1 { max-width: 8em; margin: 0; font-size: clamp(2.5rem, 5vw, 5.4rem); line-height: 0.98; letter-spacing: -0.07em; }
.context-copy p:last-child { max-width: 32rem; margin: 28px 0 0; color: rgba(243, 247, 245, 0.72); font-size: 1rem; line-height: 1.8; }
.context-note { margin: 0; color: rgba(243, 247, 245, 0.55); font-size: 0.78rem; }

.login-panel {
  display: grid;
  place-items: center;
  padding: clamp(28px, 6vw, 92px);
  background:
    linear-gradient(rgba(23, 76, 66, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23, 76, 66, 0.055) 1px, transparent 1px),
    #f4f6f2;
  background-size: 72px 72px;
}

.login-card { width: min(100%, 440px); }
.card-heading { margin-bottom: 34px; }
.card-heading p { margin: 0 0 10px; color: var(--accent); font-size: 0.74rem; font-weight: 800; letter-spacing: 0.12em; }
.card-heading h2 { margin: 0; font-size: clamp(2rem, 4vw, 2.7rem); letter-spacing: -0.055em; }
.card-heading span { display: block; margin-top: 12px; color: var(--muted); font-size: 0.92rem; }

label { display: block; margin: 22px 0 9px; color: var(--ink); font-size: 0.88rem; font-weight: 720; }
input {
  width: 100%;
  min-height: 52px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 10px;
  outline: none;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.83);
  transition: border-color 150ms ease, box-shadow 150ms ease;
}
input:focus { border-color: #4b8175; box-shadow: 0 0 0 4px rgba(40, 98, 87, 0.12); }
#account-hint { display: block; margin-top: 7px; color: var(--muted); font-size: 0.76rem; }

.password-field { position: relative; }
.password-field input { padding-right: 70px; }
.password-field button {
  position: absolute;
  top: 7px;
  right: 7px;
  min-height: 38px;
  padding: 0 11px;
  border: 0;
  border-radius: 7px;
  color: var(--accent);
  background: transparent;
  cursor: pointer;
}
.password-field button:hover { background: #e9efeb; }

.form-error { min-height: 22px; margin: 12px 0 4px; color: #a33f32; font-size: 0.82rem; }
.submit-button {
  width: 100%;
  min-height: 52px;
  border: 0;
  border-radius: 10px;
  color: #f4f8f6;
  background: var(--accent);
  font-weight: 760;
  cursor: pointer;
  transition: transform 150ms ease, background 150ms ease;
}
.submit-button:hover { background: var(--accent-hover); transform: translateY(-1px); }
.submit-button:active { transform: translateY(1px); }
.back-link { display: block; margin-top: 18px; color: var(--muted); text-align: center; font-size: 0.84rem; text-decoration: none; }
.back-link:hover { color: var(--accent); }
.security-note { margin: 34px 0 0; padding-top: 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.75rem; line-height: 1.65; }

@media (max-width: 820px) {
  .login-shell { grid-template-columns: 1fr; }
  .login-context { min-height: auto; padding: 26px 24px 34px; }
  .context-copy { padding: 56px 0; }
  .context-copy h1 { max-width: none; font-size: clamp(2.2rem, 10vw, 3.2rem); line-height: 1.04; }
  .context-note { display: none; }
  .login-panel { min-height: 580px; padding: 48px 24px 64px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
