/* Sign in: one full-screen section.
   Phone (spec M1): navy hero over a white sheet, one column.
   Wide screen: headline and roles on the left, the sign-in card on the right, on one 12-column grid. */

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

.wrap { --gutter: 24px; width: calc(100% - 2 * var(--gutter)); max-width: 432px; margin-inline: auto; }

/* header: logo and skip link, laid over the top of the section */
.login__nav { position: absolute; inset: 0 0 auto 0; z-index: 2; color: #fff; padding-top: var(--safe-t); }
.login__navin { position: relative; display: flex; align-items: center; min-height: 64px; }
.login__navin .skip-link { position: absolute; left: 0; top: 10px; }

.login { min-height: 100vh; min-height: 100svh; display: flex; background: var(--navy); color: #fff; }
.login__wrap { flex: 0 1 auto; display: flex; flex-direction: column; padding-top: calc(64px + var(--safe-t)); }

.login__hero { display: grid; gap: 12px; padding: 8px 0 32px; }
.login__hero h1 { font-size: 28px; line-height: 1.25; font-weight: 700; letter-spacing: -.01em; }
.login__sub { font-size: 15px; color: var(--on-navy); }
.roles { display: none; }

.login__sheet {
  flex: 1; margin-top: -16px; margin-inline: -24px; padding: 24px 24px calc(24px + var(--safe-b));
  background: #fff; color: var(--text); border-radius: 24px 24px 0 0;
  display: grid; gap: 20px; align-content: start;
}
.login__form { display: grid; gap: 16px; }
.lang-group { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.lang-group .btn { min-height: 48px; font-size: 16px; border-radius: 12px; }
.login__form .field input { min-height: 52px; border-radius: 12px; }

.login__resume { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.login__demo { display: grid; gap: 10px; padding-top: 16px; border-top: 1px solid var(--line); }
.login__demo-title { font-size: 14px; font-weight: 700; color: var(--text-strong); }
.login__demo p { font-size: 13px; color: var(--text-strong); }
.login__demo .btn-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.login__demo .btn { flex-direction: column; justify-content: center; gap: 2px; min-height: 64px; padding: 6px 4px; text-align: center; font-size: 14px; line-height: 1.25; }
.login__demo .btn span { font-weight: 500; color: var(--text-2); font-size: 12.5px; }

@media (min-width: 900px) {
  .wrap { --gutter: 40px; max-width: 1280px; }
  .login__wrap {
    display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 24px; align-items: start;
    padding-block: 112px 48px;
  }
  .login__hero { grid-column: 1 / span 6; padding: 0; gap: 16px; }
  .login__hero h1 { font-size: 44px; line-height: 1.15; max-width: 14em; }
  .login__sub { font-size: 18px; }
  .login__sheet { grid-column: 7 / span 6; flex: none; margin: 0; padding: 32px; border-radius: 20px; box-shadow: 0 24px 60px rgba(0, 0, 0, .25); }
  .lang-group .btn { min-height: 48px; }

  .roles { display: grid; gap: 20px; list-style: none; margin: 24px 0 0; padding: 0; max-width: 32em; }
  .roles li { display: grid; grid-template-columns: 40px 1fr; gap: 16px; align-items: start; font-size: 15px; color: var(--on-navy); }
  .roles strong { color: #fff; }
  .roles__icon { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; background: rgba(255, 255, 255, .1); color: #fff; }
}
@media (min-width: 1200px) {
  .wrap { --gutter: 80px; }
  .login__sheet { grid-column: 8 / span 5; }
}

/* ---------- worker sign-in: employee number + PIN (merge) ---------- */
.modes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 4px; border-radius: 14px; background: var(--surface); }
.modes button { min-height: 48px; border: 0; border-radius: 10px; background: none; font: inherit; font-size: 14.5px; font-weight: 600;
  color: var(--text-2); cursor: pointer; padding: 6px 8px; line-height: 1.2; }
.modes button[aria-selected="true"] { background: #fff; color: var(--navy); box-shadow: 0 1px 3px rgba(16, 24, 40, .12); }
.modes button:focus-visible { outline: 3px solid var(--blue); outline-offset: 1px; }
.wpanel { display: grid; gap: 14px; }
.wpanel[hidden], .login__form[hidden] { display: none; }
.wl-label { font-size: 14px; font-weight: 600; color: var(--text-strong); }
.wl-hint { font-size: 13px; color: var(--text-2); margin-top: -8px; }
.wl-recent { display: grid; gap: 8px; }
.wl-person { display: grid; grid-template-columns: 1fr 48px; border: 1px solid var(--line-input); border-radius: 12px; overflow: hidden; background: #fff; }
.wl-person > button { border: 0; background: none; font: inherit; cursor: pointer; }
.wl-person__main { display: flex; align-items: center; gap: 12px; padding: 10px 12px; min-height: 60px; text-align: left; }
.wl-person__main:hover { background: var(--row); }
.wl-person__init { width: 40px; height: 40px; border-radius: 10px; background: var(--navy); color: #fff; display: grid; place-items: center; font-weight: 700; flex: none; }
.wl-person__name { display: block; font-weight: 600; color: var(--text); }
.wl-person__id { display: block; font-size: 13px; color: var(--text-2); font-variant-numeric: tabular-nums; }
.wl-person__forget { border-left: 1px solid var(--line) !important; color: var(--text-off); display: grid; place-items: center; }
.wl-person__forget:hover { background: var(--row); color: var(--text); }
.wl-or { text-align: center; font-size: 13px; color: var(--text-2); }
.wl-display { display: flex; justify-content: center; align-items: baseline; gap: 2px; padding: 12px; border: 1px solid var(--line-input);
  border-radius: 12px; font-size: 34px; font-weight: 700; letter-spacing: .04em; font-variant-numeric: tabular-nums; color: var(--navy); }
.wl-display__prefix { color: var(--text-off); }
.wl-display__ph { color: var(--line-input); }
.keypad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.keypad button { min-height: 58px; border-radius: 12px; border: 1px solid var(--line-input); background: #fff; color: var(--text);
  font: inherit; font-size: 24px; font-weight: 600; cursor: pointer; touch-action: manipulation; display: grid; place-items: center;
  transition: background 120ms var(--ease), transform 80ms var(--ease); }
.keypad button:hover { background: var(--row); }
.keypad button:active { transform: scale(.97); background: var(--blue-tint); }
.keypad button.fn { font-size: 15px; color: var(--text-2); border-color: transparent; background: none; }
.keypad button:disabled { opacity: .5; }
.wl-who { display: flex; align-items: center; gap: 10px; width: 100%; padding: 12px; border: 1px solid var(--line-input); border-radius: 12px;
  background: #fff; font: inherit; font-size: 15px; text-align: left; cursor: pointer; }
.wl-who__id { color: var(--text-2); font-variant-numeric: tabular-nums; }
.wl-who__change { margin-left: auto; font-size: 13.5px; color: var(--blue); font-weight: 600; }
.wl-dots { display: flex; justify-content: center; gap: 18px; padding: 6px 0; }
.wl-dots span { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--text-off); }
.wl-dots span.is-on { background: var(--navy); border-color: var(--navy); }
.wl-error { margin: 0; }
.wl-foot { font-size: 13px; color: var(--text-2); text-align: center; }
