/* ==========================================================================
   Select Mobility India Pvt. Ltd. - Sign-in screen
   Loaded only by login.html, after app.css so it can build on the brand tokens.
   ========================================================================== */

.login-body { background: var(--canvas); }

.login-shell {
  display: grid;
  grid-template-columns: 0.94fr 1.06fr;
  min-height: 100vh;
}

/* ---------- Brand side ---------------------------------------------------- */

.login-brand {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 48px 56px;
  color: var(--brand-900);
  background: radial-gradient(circle at 8% 90%, rgba(243, 107, 33, 0.12), transparent 25%), linear-gradient(145deg, #f4f7f9 0%, #ffffff 46%, #e3f1f8 74%, #c5dce8 100%);
  border-right: 0;
}

/* Soft drifting light blobs: depth without an image asset or a network request. */
.aurora { position: absolute; inset: 0; pointer-events: none; }
.aurora { display: none; }
.aurora .blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(46px);
  opacity: 0.5;
  will-change: transform;
}
.aurora .b1 {
  width: 380px; height: 380px; right: -90px; top: -110px;
  background: rgba(26, 128, 196, 0.85);
  animation: drift 19s ease-in-out infinite;
}
.aurora .b2 {
  width: 300px; height: 300px; left: -80px; bottom: -70px;
  background: rgba(245, 158, 11, 0.36);
  animation: drift 24s ease-in-out infinite reverse;
}
.aurora .b3 {
  width: 240px; height: 240px; right: 16%; bottom: 16%;
  background: rgba(255, 255, 255, 0.16);
  animation: drift 28s ease-in-out infinite;
}
@keyframes drift {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50%      { transform: translate3d(-22px, 20px, 0) scale(1.09); }
}

.login-logo {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 0;
}
.brand-lockup {
  display: flex;
  align-items: center;
  gap: 14px;
}
.smipl-logo {
  display: block;
  width: 322px;
  height: 122px;
  object-fit: contain;
  object-position: center;
  background: transparent;
  border-radius: 0;
  padding: 0;
  filter: drop-shadow(0 3px 7px rgba(15, 23, 42, 0.16));
}
.peoplepilot-login .smipl-logo {
  background: linear-gradient(135deg, #071c31 0%, #0d527c 72%, #123e58 100%);
  border-radius: 12px;
  padding: 8px 14px;
  filter: drop-shadow(0 5px 12px rgba(15, 23, 42, 0.2));
}
.brand-divider {
  width: 1px;
  height: 68px;
  background: #cbd5e1;
}
.login-logo .name { font-size: 14px; font-weight: 700; letter-spacing: 0.7px; text-transform: uppercase; }
.login-logo .tagline {
  font-size: 10.5px;
  color: var(--ink-500);
  opacity: 1;
  letter-spacing: 0.8px;
  text-transform: uppercase;
}

.login-copy { position: relative; z-index: 1; max-width: 480px; }
.login-copy h2 {
  font-size: 34px;
  line-height: 1.2;
  letter-spacing: 0;
  margin: 0 0 14px;
}
.login-copy > p {
  font-size: 14.5px;
  line-height: 1.68;
  color: var(--ink-600);
  opacity: 1;
  margin: 0;
}

.login-features {
  list-style: none;
  margin: 28px 0 0;
  padding: 0;
  display: grid;
  gap: 12px;
}
.login-features li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--ink-700);
  opacity: 1;
}
.login-features li > span:first-child {
  flex-shrink: 0;
  width: 26px; height: 26px;
  display: grid;
  place-items: center;
  font-size: 13px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid #dbe3ea;
  box-shadow: 0 2px 5px rgba(15, 23, 42, 0.08);
}
.login-features li > span:last-child { padding-top: 3px; }

.login-legal {
  position: relative;
  z-index: 1;
  font-size: 11.5px;
  color: var(--ink-500);
  opacity: 1;
}

/* ---------- Form side ----------------------------------------------------- */

.login-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 72px;
  background: radial-gradient(circle at 78% 18%, rgba(243, 107, 33, 0.1), transparent 28%), linear-gradient(180deg, #f4f7f9 0%, #ffffff 100%);
}

.login-card {
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: 430px;
  padding: 36px 38px 32px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.1), 0 2px 0 rgba(243, 107, 33, 0.18) inset;
  animation: rise 0.42s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.card-accent {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  height: 4px;
}
.card-accent span:nth-child(1) { flex: 1.2; background: #0b2d46; }
.card-accent span:nth-child(2) { flex: 0.65; background: #f36b21; }
.card-accent span:nth-child(3) { flex: 0.35; background: #f6a21a; }
@keyframes rise {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: none; }
}

.login-head h1 {
  font-size: 28px;
  letter-spacing: -0.3px;
  margin: 0 0 6px;
}
.panel-kicker {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 12px;
  color: #c45119;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.status-dot {
  width: 7px;
  height: 7px;
  background: #16a05d;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(22, 160, 93, 0.12);
}
.login-head .sub {
  color: var(--ink-500);
  font-size: 13.5px;
  margin: 0 0 30px;
}

/* Field with an icon, inline validation and a floating label position that
   stays put so the layout never shifts while the user types. */
.lf { margin-bottom: 15px; }
.lf > label,
.lf-row label {
  display: block;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--ink-700);
  margin-bottom: 6px;
}
.lf-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.lf-wrap { position: relative; display: flex; align-items: center; }
.lf-ico {
  position: absolute;
  left: 12px;
  width: 17px; height: 17px;
  color: var(--ink-400);
  pointer-events: none;
  transition: color 0.15s;
}
.lf-ico svg { width: 100%; height: 100%; display: block; }

.lf input {
  width: 100%;
  padding: 11px 12px 11px 39px;
  font-size: 14px;
  font-family: inherit;
  color: var(--ink-900);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 9px;
  transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
}
.lf input::placeholder { color: var(--ink-400); }
.lf input:hover:not(:focus) { border-color: #cbd5e1; }
.lf input:focus {
  outline: none;
  border-color: var(--brand-500);
  box-shadow: 0 0 0 3.5px rgba(26, 128, 196, 0.14);
}
.lf-wrap:focus-within .lf-ico { color: var(--brand-500); }
.lf input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 30px #fff inset;
  -webkit-text-fill-color: var(--ink-900);
}

/* Show/hide password */
.lf-toggle {
  border: 0;
  background: none;
  padding: 0;
  font: inherit;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--brand-600);
  cursor: pointer;
  border-radius: 4px;
}
.lf-toggle:hover { color: var(--brand-800); text-decoration: underline; }
.lf-toggle:focus-visible { outline: 2px solid var(--brand-500); outline-offset: 2px; }

/* Validation messages: reserved height so nothing jumps when they appear */
.lf-msg {
  font-size: 11.5px;
  color: var(--danger-600);
  min-height: 15px;
  margin-top: 4px;
}
.lf.invalid input {
  border-color: var(--danger-600);
  background: #fffafa;
}
.lf.invalid input:focus { box-shadow: 0 0 0 3.5px rgba(185, 28, 28, 0.12); }
.lf.invalid .lf-ico { color: var(--danger-600); }

.lf-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 4px 0 18px;
  min-height: 20px;
}
.lf-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.8px;
  color: var(--ink-700);
  cursor: pointer;
  user-select: none;
}
.lf-check input {
  width: 15px; height: 15px;
  accent-color: var(--brand-600);
  cursor: pointer;
  margin: 0;
}
.lf-caps {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--warn-600);
  background: var(--warn-100);
  border-radius: 5px;
  padding: 2px 7px;
}

/* Error banner */
.login-error {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin-bottom: 15px;
  padding: 10px 12px;
  font-size: 12.8px;
  line-height: 1.5;
  color: #7f1d1d;
  background: var(--danger-100);
  border: 1px solid #fecaca;
  border-radius: 9px;
  animation: shake 0.32s ease;
}
.login-error[hidden],
.dc-body[hidden] { display: none; }
.login-error svg { width: 16px; height: 16px; flex-shrink: 0; margin-top: 1px; }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25%      { transform: translateX(-4px); }
  75%      { transform: translateX(4px); }
}

/* Submit button with an inline spinner */
.login-submit {
  position: relative;
  width: 100%;
  padding: 13px 16px;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(110deg, #09243b 0%, #12547f 72%, #f59e0b 100%);
  border: 1px solid #12547f;
  border-radius: 10px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  box-shadow: 0 4px 14px rgba(17, 24, 39, 0.2);
  transition: transform 0.12s, box-shadow 0.15s, filter 0.15s;
}
.login-submit:hover:not(:disabled) {
  filter: brightness(1.06);
  box-shadow: 0 5px 16px rgba(13, 79, 124, 0.28);
}
.login-submit:active:not(:disabled) { transform: translateY(1px); }
.login-submit:focus-visible { outline: 2px solid var(--brand-500); outline-offset: 2px; }
.login-submit:disabled { cursor: progress; opacity: 0.82; }
.login-submit .spin { display: none; }
.login-submit.loading .lbl { opacity: 0.9; }
.login-submit.loading .spin {
  display: block;
  width: 15px; height: 15px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-top-color: #fff;
  animation: spin 0.65s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.login-assurance {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-top: 22px;
  padding: 12px 13px;
  color: var(--ink-700);
  background: linear-gradient(90deg, #fff7f1, #f8fbfd);
  border: 1px solid #f6d2bd;
  border-radius: 9px;
}
.assurance-mark {
  display: grid;
  place-items: center;
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  color: #fff;
  background: linear-gradient(135deg, #f36b21, #c94212);
  border-radius: 8px;
}
.assurance-mark svg { width: 17px; height: 17px; }
.login-assurance strong {
  display: block;
  color: var(--brand-900);
  font-size: 11.5px;
}
.login-assurance small {
  display: block;
  margin-top: 2px;
  color: var(--ink-500);
  font-size: 10.5px;
}
.dc-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.dc-head strong { color: var(--brand-800); font-size: 12px; }
.dc-toggle {
  border: 0;
  background: none;
  padding: 0;
  font: inherit;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--brand-600);
  cursor: pointer;
}
.dc-toggle:hover { color: var(--brand-800); text-decoration: underline; }

.dc-body { display: grid; gap: 7px; margin-top: 10px; }
.dc-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 9px;
  width: 100%;
  padding: 8px 10px;
  font: inherit;
  font-size: 12.3px;
  text-align: left;
  color: var(--ink-700);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 7px;
  cursor: pointer;
  transition: border-color 0.14s, box-shadow 0.14s;
}
.dc-item:hover {
  border-color: var(--brand-500);
  box-shadow: 0 0 0 3px rgba(26, 128, 196, 0.1);
}
.dc-role { font-weight: 700; color: var(--brand-800); }
.dc-mail { font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; font-size: 11.6px; }
.dc-use { font-size: 11.5px; font-weight: 600; color: var(--brand-600); }

/* ---------- Responsive ---------------------------------------------------- */

@media (max-width: 940px) {
  .login-shell { grid-template-columns: 1fr; }
  .login-brand {
    padding: 34px 30px 38px;
    min-height: auto;
  }
  .login-copy h2 { font-size: 25px; }
  .login-features { display: none; }
  .login-legal { margin-top: 22px; }
  .login-panel { padding: 34px 20px 48px; align-items: flex-start; }
  .login-card { max-width: 420px; }
}

@media (max-width: 420px) {
  .login-brand { padding: 28px 22px 30px; }
  .login-panel  { padding: 28px 18px 40px; }
  .brand-lockup { gap: 11px; }
  .smipl-logo { width: 214px; height: 80px; }
  .brand-divider { height: 42px; }
  .login-logo .name { font-size: 11px; letter-spacing: 0.45px; }
  .login-logo .tagline { font-size: 9px; letter-spacing: 0.45px; }
}

/* Respect reduced-motion: keep the polish, drop the movement. */
@media (prefers-reduced-motion: reduce) {
  .aurora .blob,
  .login-card,
  .login-error,
  .login-submit .spin { animation: none !important; }
  .login-card { opacity: 1; transform: none; }
}
