/* Login — 1:1 match to reference split layout */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body.login-page {
  font-family: Inter, "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
  color: #0b1220;
  background: #fff;
  -webkit-font-smoothing: antialiased;
}

.login-page-shell {
  display: grid;
  grid-template-columns: 59% 41%;
  min-height: 100vh;
  width: 100%;
  overflow: hidden;
}

/* —— Left artwork —— */
.leftPanel {
  height: 100vh;
  overflow: hidden;
  background: #041b38;
  margin: 0;
  padding: 0;
}

.leftPanel img {
  width: 100%;
  height: 100%;
  /* Fill panel edge-to-edge; pin top so brand stays on-screen */
  object-fit: cover;
  object-position: center top;
  display: block;
}

/* —— Right form —— */
.rightPanel {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
}

.loginContainer {
  width: 100%;
  max-width: 520px;
  padding: 48px;
}

@media (min-width: 1400px) {
  .loginContainer {
    max-width: 520px;
  }
}

.loginTitle {
  margin: 0 0 12px;
  font-size: 48px;
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #0b1220;
}

.loginSubtitle {
  margin: 0 0 30px;
  font-size: 17px;
  line-height: 1.5;
  color: #667085;
  font-weight: 400;
}

.loginNotice {
  height: 48px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 16px;
  border-radius: 10px;
  background: #f5f7fa;
  color: #475467;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 30px;
}

.loginNotice svg {
  flex: 0 0 auto;
  color: #667085;
}

.loginFlash {
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 20px;
  font-size: 14px;
  font-weight: 600;
}

.loginFlash.error {
  background: #fee2e2;
  color: #dc2626;
}

.loginFlash.ok {
  background: #eff6ff;
  color: #1d4ed8;
}

.loginField {
  margin-bottom: 22px;
}

.loginField label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: #111827;
  margin-bottom: 8px;
}

.loginInputWrap {
  position: relative;
  display: flex;
  align-items: center;
}

.loginInputWrap .loginIconLeft {
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: #98a2b3;
  pointer-events: none;
  display: grid;
  place-items: center;
}

.loginInputWrap .loginIconRight {
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  border: 0;
  background: transparent;
  color: #98a2b3;
  cursor: pointer;
  padding: 4px;
  display: grid;
  place-items: center;
  border-radius: 6px;
}

.loginInputWrap .loginIconRight:hover {
  color: #475467;
}

.loginInputWrap .loginIconRight:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 2px;
}

.loginInput {
  width: 100%;
  height: 58px;
  border: 1px solid #d8e0ea;
  border-radius: 11px;
  background: #fff;
  font-family: inherit;
  font-size: 16px;
  font-weight: 400;
  padding: 0 16px 0 52px;
  color: #111827;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.loginInput.hasToggle {
  padding-right: 52px;
}

.loginInput::placeholder {
  color: #98a2b3;
  font-weight: 400;
}

.loginInput:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.loginRow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 18px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.loginCheck {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  font-weight: 500;
  color: #111827;
  cursor: pointer;
  user-select: none;
}

.loginCheck input {
  width: 20px;
  height: 20px;
  border-radius: 4px;
  accent-color: #2563eb;
  cursor: pointer;
}

.loginForgot {
  color: #155eef;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
}

.loginForgot:hover {
  text-decoration: underline;
}

.loginForgot:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 3px;
  border-radius: 4px;
}

.btnSignIn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  height: 62px;
  border: 0;
  border-radius: 11px;
  background: #2563eb;
  color: #fff;
  font-family: inherit;
  font-size: 17px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.12);
  transition: background 0.15s ease;
}

.btnSignIn:hover {
  background: #1d4ed8;
}

.btnSignIn:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 3px;
}

.loginDivider {
  display: flex;
  align-items: center;
  margin: 36px 0;
  color: #667085;
  font-size: 14px;
  font-weight: 500;
}

.loginDivider::before,
.loginDivider::after {
  content: "";
  flex: 1;
  border-top: 1px solid #e4e7ec;
}

.loginDivider span {
  padding: 0 16px;
}

.btnRequest {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  height: 58px;
  background: #fff;
  border: 1px solid #d0d5dd;
  border-radius: 11px;
  color: #155eef;
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.btnRequest:hover {
  background: #f8fafc;
  border-color: #b9c1cc;
}

.btnRequest:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 3px;
}

.loginFoot {
  margin: 24px 0 0;
  text-align: center;
  font-size: 14px;
  color: #667085;
  font-weight: 400;
}

.loginFoot a {
  color: #155eef;
  font-weight: 600;
  text-decoration: none;
}

.loginFoot a:hover {
  text-decoration: underline;
}

/* Subtle signed-out toast */
.loginToast {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 1000;
  background: rgba(15, 23, 42, 0.88);
  color: #e2e8f0;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.01em;
  padding: 8px 12px;
  border-radius: 8px;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.12);
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.loginToast.show {
  opacity: 1;
  transform: none;
}

@media (max-width: 1099px) and (min-width: 768px) {
  .login-page-shell {
    grid-template-columns: 50% 50%;
  }

  .loginContainer {
    padding: 36px 32px;
  }

  .loginTitle {
    font-size: 40px;
  }
}

@media (max-width: 767px) {
  .login-page-shell {
    grid-template-columns: 1fr;
    overflow: auto;
  }

  .leftPanel {
    display: none;
  }

  .rightPanel {
    width: 100%;
    min-height: 100vh;
    padding: 24px;
    padding-bottom: 24px;
    align-items: flex-start;
    padding-top: 48px;
  }

  .loginContainer {
    max-width: 460px;
    padding: 0;
    margin: 0 auto;
  }

  .loginTitle {
    font-size: 36px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .loginToast,
  .loginInput,
  .btnSignIn,
  .btnRequest {
    transition: none;
  }
}
