:root {
  --panel: rgba(14, 24, 23, .94);
  --line: rgba(255, 255, 255, .16);
  --text: #f5f7f5;
  --muted: #b7c1bc;
  --green: #38b691;
  --green-strong: #15906e;
  --danger: #ffb9b2;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; margin: 0; }
body {
  background: #111c1b url("/auth-assets/login-background.png") center / cover fixed no-repeat;
  color: var(--text);
  font-family: Inter, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 14px;
  letter-spacing: 0;
}
button, input { font: inherit; letter-spacing: 0; }

.login-shell { min-height: 100vh; }
.login-panel {
  display: flex;
  width: min(520px, 46vw);
  min-height: 100vh;
  padding: 42px clamp(34px, 5vw, 76px);
  background: var(--panel);
  flex-direction: column;
}
.language-switch {
  display: inline-flex;
  align-self: flex-end;
  border: 1px solid var(--line);
}
.language-switch button {
  min-width: 48px;
  height: 32px;
  padding: 0 10px;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}
.language-switch button.active { background: #fff; color: #16221f; font-weight: 700; }
.brand-lockup { display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: 16px; align-items: start; margin-top: clamp(64px, 11vh, 118px); }
.brand-mark {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, .34);
  border-radius: 6px;
  color: #fff;
  font-size: 20px;
  font-weight: 800;
}
.role-label { margin: 1px 0 9px; color: #82d9bd; font-size: 11px; font-weight: 750; }
h1 { max-width: 340px; margin: 0; font-size: clamp(27px, 3vw, 38px); line-height: 1.18; }
.brand-lockup p { max-width: 340px; margin: 13px 0 0; color: var(--muted); line-height: 1.65; }
form { width: min(100%, 360px); margin-top: clamp(46px, 8vh, 78px); }
.form-heading h2 { margin: 0; font-size: 18px; }
.form-heading p { margin: 8px 0 0; color: var(--muted); font-size: 12px; }
.field { display: block; margin-top: 22px; }
.field > span { display: block; margin-bottom: 8px; color: #dce2df; font-size: 12px; font-weight: 650; }
.field input {
  width: 100%;
  height: 46px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 5px;
  outline: none;
  background: rgba(255, 255, 255, .07);
  color: #fff;
}
.field input:focus { border-color: var(--green); box-shadow: 0 0 0 2px rgba(56, 182, 145, .16); }
.password-input { position: relative; }
.password-input input { padding-right: 62px; }
.password-input button {
  position: absolute;
  top: 1px;
  right: 1px;
  height: 44px;
  padding: 0 12px;
  border: 0;
  background: transparent;
  color: #9fd6c4;
  cursor: pointer;
  font-size: 11px;
}
.error-message { margin-top: 15px; padding: 10px 11px; border-left: 3px solid #d65a50; background: rgba(185, 59, 50, .18); color: var(--danger); font-size: 12px; line-height: 1.45; }
.submit-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: 46px;
  margin-top: 20px;
  padding: 0 15px;
  border: 1px solid var(--green);
  border-radius: 5px;
  background: var(--green-strong);
  color: #fff;
  cursor: pointer;
  font-weight: 720;
}
.submit-button:hover { background: #117c60; }
.submit-button:disabled { cursor: wait; opacity: .65; }
footer { display: flex; align-items: center; gap: 8px; margin-top: auto; padding-top: 40px; color: #91a09a; font-size: 11px; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px rgba(56, 182, 145, .12); }

@media (max-width: 820px) {
  body { background-position: 68% center; }
  .login-panel { width: min(100%, 480px); padding: 28px 28px 24px; }
  .brand-lockup { margin-top: 60px; }
}

@media (max-width: 520px) {
  body { background-image: none; }
  .login-panel { width: 100%; padding: 22px 20px; }
  .brand-lockup { grid-template-columns: 42px minmax(0, 1fr); gap: 12px; margin-top: 48px; }
  .brand-mark { width: 42px; height: 42px; }
  h1 { font-size: 26px; }
  form { width: 100%; margin-top: 44px; }
}
