:root {
  color-scheme: light;
  --page: #eeefe9;
  --paper: #fcfbf7;
  --forest: #203b33;
  --green: #345849;
  --muted: #657268;
  --border: #dcded3;
  --focus: #12815e;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--forest);
  background: var(--page);
  font-synthesis: none;
  -webkit-text-size-adjust: 100%;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 280px; }
button, input { font: inherit; }
button { cursor: pointer; }
button, input, label { -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }

body {
  display: grid;
  min-height: 100vh;
  min-height: 100svh;
  place-items: center;
  padding: 40px;
  background: radial-gradient(ellipse at 14% 5%, #f7f7ef 0, transparent 65%), var(--page);
}

.login-shell {
  display: grid;
  grid-template-columns: 1fr 1fr;
  width: min(100%, 1200px);
  min-height: 728px;
  overflow: hidden;
  border: 1px solid #e0e2d8;
  border-radius: 22px;
  background: var(--paper);
  box-shadow: 0 24px 80px -40px #203b3338, 0 2px 6px #203b3303;
}

.brand-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 44px 48px 38px;
  background: radial-gradient(ellipse at 95% 85%, #355142 0, transparent 65%), var(--forest);
  color: #f6f4e9;
}

.brand { display: flex; align-items: center; gap: 13px; position: relative; z-index: 1; }
.brand-mark { flex: 0 0 auto; width: 34px; height: 34px; color: #d4d8b6; }
.brand-name { font-size: 26px; font-weight: 600; letter-spacing: 4px; white-space: nowrap; }
.brand-divider { height: 17px; width: 1px; background: #f6f4e933; margin-left: 2px; }
.brand-caption { color: #c8d1c5; font-size: 13px; letter-spacing: 1.5px; white-space: nowrap; }
.brand-story { position: relative; z-index: 1; margin-top: 104px; }
.eyebrow { margin: 0; font-size: 10px; font-weight: 600; letter-spacing: 2px; line-height: 1.6; }
.brand-story .eyebrow { color: #bdc9b6; }
.brand-story h2 {
  margin: 25px 0 18px;
  font-family: "Songti SC", "STSong", "SimSun", serif;
  font-size: clamp(38px, 3.3vw, 46px);
  font-weight: 400;
  line-height: 1.6;
  letter-spacing: 4px;
}
.story-description { color: #c8d1c5; font-size: 16px; line-height: 1.75; letter-spacing: .25px; margin: 0; }
.story-description span { display: block; }
.journey-art { position: absolute; bottom: 49px; left: 0; width: 100%; pointer-events: none; }
.journey-art svg { display: block; width: 100%; height: auto; }
.orbit { stroke: #c4cda9; stroke-opacity: .1; stroke-width: 1; }
.trace { stroke: #c4cda9; stroke-opacity: .16; stroke-width: 1; stroke-dasharray: 3 7; }
.art-cross { stroke: #c4cda9; stroke-opacity: .4; stroke-width: 1; }
.brand-footer { position: relative; z-index: 1; display: flex; align-items: center; gap: 14px; margin-top: auto; padding-top: 220px; color: #bdc9b6; font-size: 11px; letter-spacing: 2px; }
.brand-footer-line { width: 25px; height: 1px; background: #bdc9b67a; }

.form-panel { display: flex; flex-direction: column; min-width: 0; padding: 42px 48px 30px; }
.panel-note { display: flex; justify-content: flex-end; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; letter-spacing: .5px; line-height: 1.8; }
.panel-note > span { width: 5px; height: 5px; border-radius: 50%; background: #a1ac87; }
.login-content { width: 100%; max-width: 352px; margin: auto; padding: 55px 0 50px; }
.form-heading .eyebrow { color: var(--muted); font-size: 9px; letter-spacing: 1.8px; }
h1 { margin: 17px 0 12px; font-size: 32px; font-weight: 550; letter-spacing: 1px; line-height: 1.4; }
h1 > span { color: #81916e; }
.form-heading > p:last-child { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.8; }
form { margin-top: 34px; }
.field { margin-bottom: 21px; }
.field > label { display: block; margin-bottom: 9px; font-size: 13px; font-weight: 550; line-height: 1.6; }
.field input {
  display: block;
  width: 100%;
  min-width: 0;
  min-height: 52px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 13px 15px;
  color: var(--forest);
  background: #fffefa;
  font-size: 16px;
  line-height: 1.5;
  transition: border-color .18s, box-shadow .18s;
}
.field input::placeholder { color: #7c8176; font-size: 14px; opacity: 1; }
.field input:hover { border-color: #a7b3a4; }
.field input:focus { border-color: var(--focus); outline: 2px solid #12815e24; outline-offset: 2px; }
.password-field { position: relative; }
.password-field:has(.password-toggle:not([hidden])) input { padding-right: 84px; }
.password-toggle {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  gap: 5px;
  align-items: center;
  justify-content: center;
  min-width: 72px;
  min-height: 44px;
  padding: 6px;
  border: 0;
  border-radius: 5px;
  color: var(--muted);
  background: transparent;
  font-size: 12px;
}
.password-toggle:hover { color: var(--forest); background: #edf1e8; }
.eye-icon { width: 18px; height: 18px; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.eye-slash { display: none; }
.password-toggle[aria-pressed="true"] .eye-slash { display: block; }
.remember-option { display: flex; align-items: center; gap: 9px; width: fit-content; max-width: 100%; min-height: 44px; margin: -5px 0 21px; color: var(--muted); font-size: 13px; line-height: 1.7; cursor: pointer; }
.remember-option input { width: 17px; height: 17px; margin: 0; flex: 0 0 auto; accent-color: var(--forest); cursor: pointer; }
.submit-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  width: 100%;
  min-height: 54px;
  padding: 14px 20px;
  border: 1px solid var(--forest);
  border-radius: 8px;
  background: var(--forest);
  color: #fcfbf7;
  font-size: 15px;
  font-weight: 550;
  letter-spacing: 1px;
  box-shadow: 0 4px 10px #203b3310;
  transition: background .18s, border-color .18s, transform .18s;
}
.submit-button:hover { background: var(--green); border-color: var(--green); }
.submit-button:active { transform: translateY(1px); }
.button-arrow { width: 19px; height: 19px; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.submit-button:disabled { cursor: wait; background: #496052; border-color: #496052; transform: none; }
.button-spinner { display: none; width: 17px; height: 17px; border: 2px solid #fcfbf74d; border-top-color: currentColor; border-radius: 50%; }
.is-submitting .button-spinner { display: block; animation: spin .8s linear infinite; }
.is-submitting .button-arrow { display: none; }
.login-error { margin: 0 0 23px; padding: 12px 14px; border: 1px solid #e7cdc2; border-radius: 8px; background: #fcf0e9; color: #91412e; font-size: 13px; line-height: 1.8; overflow-wrap: anywhere; }
.login-error:empty { display: none; }
.workspace-note { display: flex; align-items: center; justify-content: center; gap: 7px; margin-top: 24px; color: var(--muted); font-size: 11px; line-height: 1.8; }
.workspace-note svg { flex: 0 0 auto; width: 15px; height: 15px; stroke: currentColor; stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; }
.form-footer { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px 16px; color: var(--muted); font-size: 10px; line-height: 1.8; letter-spacing: .5px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
button:focus-visible, input[type="checkbox"]:focus-visible, .login-error:focus-visible { outline: 2px solid var(--focus); outline-offset: 4px; }
@keyframes spin { to { transform: rotate(360deg); } }

@media (min-width: 1600px) {
  .login-shell { min-height: 780px; }
  .brand-story { margin-top: 120px; }
}

@media (max-width: 1050px) {
  body { padding: 28px; }
  .brand-panel { padding: 36px 32px; }
  .form-panel { padding: 34px 32px 26px; }
  .brand { gap: 10px; }
  .brand-name { font-size: 24px; }
  .brand-caption { font-size: 12px; letter-spacing: 1px; }
  .brand-story h2 { font-size: 38px; letter-spacing: 2px; }
}

@media (max-width: 760px) {
  body { display: block; padding: 0; background: var(--paper); }
  .login-shell { grid-template-columns: minmax(0, 1fr); width: 100%; min-height: 100vh; min-height: 100svh; border: 0; border-radius: 0; box-shadow: none; }
  .brand-panel { min-height: 156px; padding: max(26px, env(safe-area-inset-top)) 28px 26px; justify-content: space-between; }
  .brand-mark { width: 30px; height: 30px; }
  .brand-story { margin-top: 21px; }
  .brand-story .eyebrow, .brand-footer { display: none; }
  .brand-story { margin-top: 24px; }
  .brand-story h2 { margin: 0 0 10px; font-size: 26px; line-height: 1.5; letter-spacing: 1px; }
  .motto-break { display: none; }
  .story-description { font-size: 12px; line-height: 1.65; letter-spacing: .2px; }
  .journey-art { width: 280px; left: auto; right: -46px; bottom: -95px; opacity: .7; }
  .form-panel { padding: 39px 28px max(24px, env(safe-area-inset-bottom)); }
  .panel-note { display: none; }
  .login-content { max-width: 400px; padding: 0 0 46px; }
  .form-heading .eyebrow { font-size: 9px; }
  h1 { margin-top: 14px; font-size: 30px; }
  form { margin-top: 30px; }
  .field { margin-bottom: 22px; }
  .field input { min-height: 54px; }
  .field > label { font-size: 14px; }
  .remember-option { font-size: 13px; margin-bottom: 22px; }
  .submit-button { min-height: 56px; }
  .workspace-note { margin-top: 23px; }
  .form-footer { width: 100%; max-width: 400px; margin: auto auto 0; font-size: 11px; }
}

@media (max-width: 360px) {
  .brand-panel { padding-left: 22px; padding-right: 22px; }
  .form-panel { padding-left: 22px; padding-right: 22px; }
  .brand-name { font-size: 23px; }
  .brand-caption { font-size: 11px; }
  .brand-story h2 { font-size: 22px; letter-spacing: .5px; }
}

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

@media (forced-colors: active) {
  .brand-panel { border-bottom: 1px solid CanvasText; }
  .brand, .brand-story .eyebrow, .story-description, .brand-footer { color: CanvasText; }
  .submit-button { border: 1px solid ButtonText; }
  .login-error { border: 1px solid CanvasText; }
}
