/* Layout and form styles adapted from BS_YF_M01's login page. */
:root {
  color-scheme: light;
  --login-ink: #0f172a;
  --login-text: #1f2937;
  --login-border: #dbe3ef;
  --login-accent: #2563eb;
}
*, *::before, *::after { box-sizing: border-box; }
body.login-page {
  display: flex;
  min-height: 100vh;
  min-height: 100svh;
  margin: 0;
  color: var(--login-text);
  background: #f8fafc;
  font: 14px -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", sans-serif;
  -webkit-font-smoothing: antialiased;
}
.login-brand {
  flex: 0 0 44%;
  min-width: 0;
  padding: 64px 48px;
  color: #f8fafc;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: #0a0a0a;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.login-brand-mark {
  display: block;
  width: 78px;
  height: 78px;
  margin-bottom: 28px;
  object-fit: contain;
}
.login-brand h1 {
  margin: 0;
  font-size: 30px;
  font-weight: 850;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.login-brand > p { max-width: 380px; margin: 14px 0 0; color: #cbd5e1; font-size: 14px; line-height: 1.8; }
.login-brand-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 42px; width: min(400px, 100%); }
.login-brand-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 13px 14px;
  border: 1px solid rgba(203,213,225,.16);
  border-radius: 8px;
  color: #cbd5e1;
  background: rgba(255,255,255,.06);
  font-size: 13px;
  font-weight: 650;
  text-align: left;
}
.login-brand-item .icon { width: 18px; height: 18px; flex: none; color: #93c5fd; }
.login-panel {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px;
}
.login-card { width: min(410px, 100%); }
.login-card h2 {
  margin: 0;
  color: var(--login-ink);
  font-size: 25px;
  font-weight: 850;
  line-height: 1.4;
}
.login-subtitle { margin: 8px 0 28px; color: #64748b; font-size: 14px; line-height: 1.8; }
.login-footer { margin-top: 28px; color: #64748b; font-size: 12px; text-align: center; line-height: 1.8; }
.login-field { margin-bottom: 22px; }
.login-field label {
  display: block;
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 600;
}
.login-input { position: relative; }
.login-card .icon { width: 18px; height: 18px; flex: none; }
.login-input > .icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #64748b;
  pointer-events: none;
}
.login-input input {
  width: 100%;
  min-width: 0;
  height: 44px;
  padding: 10px 12px 10px 42px;
  border: 1px solid var(--login-border);
  border-radius: 6px;
  background: #fff;
  color: var(--login-text);
  font: inherit;
  transition: border-color .15s, box-shadow .15s;
}
.login-input input::placeholder { color: #75849a; }
.login-input input:focus {
  outline: none;
  border-color: #6099ee;
  box-shadow: 0 0 0 3px rgba(37,99,235,.18);
}
.login-input input:-webkit-autofill {
  -webkit-text-fill-color: var(--login-ink);
  -webkit-box-shadow: 0 0 0 1000px #fff inset;
}
.login-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 44px;
  margin-top: 2px;
  border: 1px solid var(--login-accent);
  border-radius: 6px;
  color: #fff;
  background: var(--login-accent);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
.login-submit:hover { background: #1d4ed8; border-color: #1d4ed8; }
.login-submit:focus-visible { outline: 2px solid var(--login-accent); outline-offset: 3px; }
.login-alert {
  display: flex;
  gap: 9px;
  align-items: flex-start;
  margin: 0 0 20px;
  padding: 11px 14px;
  border: 1px solid #fecaca;
  border-radius: 8px;
  color: #991b1b;
  background: #fef2f2;
  font-size: 13px;
  line-height: 1.6;
}
.login-alert .icon { margin-top: 1px; }
@media (max-width: 1100px) {
  .login-brand { padding: 48px 28px; }
  .login-brand h1 { font-size: 25px; }
}
@media (max-width: 900px) {
  body.login-page { flex-direction: column; }
  .login-brand { flex: none; padding: 28px; }
  .login-brand-mark { width: 48px; height: 48px; margin-bottom: 14px; }
  .login-brand h1 { font-size: 21px; }
  .login-brand > p { margin-top: 8px; font-size: 12px; }
  .login-brand-grid { display: none; }
  .login-panel { align-items: flex-start; padding: 36px 24px; }
}
@media (prefers-reduced-motion: reduce) {
  .login-input input { transition: none; }
}
