/* Local preview only. Additive auth skin; original forms and behavior are retained. */
@font-face {
  font-family: "Manrope UI";
  src: url("assets/Manrope-variable.ttf") format("truetype");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

html:has(body > .auth-wrap) {
  background: #f5f4ee;
  color-scheme: light;
}

body:has(> .auth-wrap) {
  --ink: #16232c;
  --ink-2: #4c5962;
  --ink-3: #667078;
  --bg: #f5f4ee;
  --card: #fff;
  --line: #d9dcd6;
  --line-2: #bfc6c8;
  --brand: #4b46c8;
  --brand-dark: #3c37ad;
  --brand-tint: #eeedf7;
  --brand-track: #dcd9f4;
  --auth-focus: #315fbd;
  background: var(--bg);
  color: var(--ink);
  font-family: "Manrope UI", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.6;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.auth-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 22px;
  min-height: 100vh;
  min-height: 100svh;
  padding: max(24px, env(safe-area-inset-top, 0px)) 32px max(24px, env(safe-area-inset-bottom, 0px));
  background: #f5f4ee;
}
.auth-wrap::before { content: none; }

.auth-wrap .auth-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 1fr);
  grid-template-rows: auto auto;
  align-items: stretch;
  justify-items: stretch;
  gap: 0;
  width: min(1080px, 100%);
  min-width: 0;
  background: #fff;
  border: 1px solid #d9dcd6;
  border-radius: 16px;
}
.auth-wrap .auth-main::before {
  content: "";
  grid-column: 1;
  grid-row: 1 / span 2;
  min-width: 0;
  min-height: 500px;
  border-radius: 15px 0 0 15px;
  background: linear-gradient(180deg, #f5f4ee24, #f5f4ee00 50%),
    url("assets/auth-showroom.webp") 100% 50% / cover no-repeat;
}

.auth-wrap .auth-card,
.auth-wrap .auth-card.wide {
  grid-column: 2;
  grid-row: 1;
  width: auto;
  max-width: none;
  min-width: 0;
  padding: 36px 44px 16px;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

/* The original role=img and accessible name remain on .pmark. */
.auth-wrap .pmark {
  display: block;
  position: relative;
  width: 112px;
  height: 36px;
  background: url("assets/drive-product-dark.svg") 0 50% / 112px auto no-repeat;
}
.auth-wrap .pmark .mono,
.auth-wrap .pmark .word { display: none; }
.auth-wrap .auth-card.center .pmark { margin-inline: auto; }

.auth-wrap .auth-title {
  margin: 24px 0 10px;
  color: var(--ink);
  font-family: "Manrope UI", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size: clamp(32px, 3.1vw, 40px);
  font-weight: 500;
  letter-spacing: -.055em;
  line-height: 1.12;
  overflow-wrap: break-word;
}
.auth-wrap .auth-sub {
  margin: 0 0 24px;
  color: var(--ink-3);
  font-size: 14px;
  line-height: 1.65;
  letter-spacing: -.015em;
  overflow-wrap: break-word;
}
.auth-wrap .auth-sub b { color: var(--ink-2); font-weight: 650; }
.auth-wrap .auth-foot {
  margin-top: 20px;
  padding-top: 16px;
  border-top-color: var(--line);
  color: var(--ink-3);
  font-size: 12.5px;
  line-height: 1.7;
  overflow-wrap: break-word;
}
.auth-wrap .auth-foot a { color: var(--brand); }
.auth-wrap .auth-card .hint,
.auth-wrap .fld-help { color: var(--ink-3); font-size: 12.5px; line-height: 1.6; }

.auth-wrap .auth-card .fld { margin-bottom: 16px; }
.auth-wrap .auth-card .lbl { margin-bottom: 8px; color: var(--ink-2); font-size: 13px; font-weight: 650; line-height: 1.5; }
.auth-wrap .auth-card.center .fld .lbl { text-align: left; }
.auth-wrap .auth-card input:not([type=hidden]):not([type=checkbox]):not([type=radio]),
.auth-wrap .auth-card select {
  width: 100%;
  min-width: 0;
  min-height: 50px;
  padding: 11px 13px;
  color: var(--ink);
  background-color: #fff;
  border: 1px solid var(--line-2);
  border-radius: 6px;
  box-shadow: none;
  font: inherit;
  font-size: 16px;
  line-height: 1.5;
  transition: border-color .15s, box-shadow .15s;
}
.auth-wrap .auth-card input:not([type=hidden]):hover,
.auth-wrap .auth-card select:hover { border-color: #8b959c; }
.auth-wrap .auth-card input:not([type=hidden]):focus,
.auth-wrap .auth-card select:focus {
  border-color: var(--auth-focus);
  outline: none;
  box-shadow: 0 0 0 3px #315fbd26;
}
.auth-wrap .auth-card input::placeholder { color: var(--ink-3); }
.auth-wrap .auth-card input.pin { text-align: center; font-size: 22px; letter-spacing: 8px; font-variant-numeric: tabular-nums; }
.auth-wrap .auth-card .pw-wrap input { padding-right: 54px; }
.auth-wrap .auth-card .pw-eye {
  width: 44px;
  height: 44px;
  border-radius: 5px;
  color: var(--ink-3);
  background: transparent;
}
.auth-wrap .auth-card .pw-eye:hover { color: var(--ink); background: #eeedf7; }
.auth-wrap .auth-card .pw-eye:focus-visible { outline: 2px solid var(--auth-focus); outline-offset: 1px; box-shadow: none; }

/* Error meaning stays red; the focused control also keeps a distinct blue ring. */
.auth-wrap .auth-card .fld.is-invalid :is(input, select, textarea),
.auth-wrap .auth-card [aria-invalid="true"] {
  border-color: var(--bad, #b91c1c);
  box-shadow: 0 0 0 3px #b91c1c1f;
}
.auth-wrap .auth-card .fld.is-invalid :is(input, select, textarea):focus,
.auth-wrap .auth-card [aria-invalid="true"]:focus {
  outline: 2px solid var(--auth-focus);
  outline-offset: 3px;
}
.auth-wrap .fld-err { font-size: 12.5px; line-height: 1.5; }
.auth-wrap .auth-card .flash { padding: 12px 13px; border-radius: 7px; font-size: 13px; line-height: 1.6; }
.auth-wrap .auth-card .flash.info { background: #edf2fc; border-color: #c9d8f5; color: #315fbd; }

.auth-wrap .auth-card .btn {
  min-height: 48px;
  padding: 12px 17px;
  border-color: var(--line-2);
  border-radius: 5px;
  box-shadow: none;
  font-family: inherit;
  font-size: 14px;
  font-weight: 650;
  line-height: 1.45;
  letter-spacing: -.012em;
  white-space: normal;
}
.auth-wrap .auth-card .btn:hover { background: #f5f4ee; }
.auth-wrap .auth-card .btn.primary {
  min-height: 50px;
  margin-top: 6px;
  color: #fff;
  background: #4b46c8;
  border-color: #4b46c8;
  box-shadow: none;
}
.auth-wrap .auth-card .btn.primary:hover { background: #3c37ad; border-color: #3c37ad; }
.auth-wrap .auth-card .btn.ghost { color: var(--ink-2); background: transparent; border-color: transparent; }
.auth-wrap .auth-card .btn.ghost:hover { color: var(--ink); background: #eeedf7; }
.auth-wrap .auth-card .btn:focus-visible,
.auth-wrap .auth-card .btn.ghost:focus-visible,
.auth-wrap .auth-card .btn.primary:focus-visible {
  outline: 2px solid var(--auth-focus);
  outline-offset: 3px;
  box-shadow: none;
}
.auth-wrap .or-row { margin-top: 22px; color: var(--ink-3); font-size: 11.5px; font-weight: 600; }

.auth-wrap .user-tiles { gap: 10px; margin: 22px 0; }
.auth-wrap .user-tile,
.auth-wrap .acct { border-color: var(--line-2); border-radius: 9px; box-shadow: none; }
.auth-wrap .user-tile:hover,
.auth-wrap .acct:hover { background: #f5f4ee; border-color: #8b959c; }
.auth-wrap .user-tile.selected { background: #eeedf7; border-color: #4b46c8; box-shadow: 0 0 0 2px #4b46c81f; }
.auth-wrap .user-tile:focus-visible,
.auth-wrap .acct:focus-visible { outline: 2px solid var(--auth-focus); outline-offset: 3px; box-shadow: none; }
.auth-wrap .user-tile .rl,
.auth-wrap .acct .em,
.auth-wrap .who .un { color: var(--ink-3); }
.auth-wrap .user-tile.selected .rl { color: var(--ink-2); }
.auth-wrap .acct > span:last-child { min-width: 0; }
.auth-wrap :is(.user-tile, .acct) :is(.nm, .em) { overflow-wrap: anywhere; }
.auth-wrap .who .avatar { box-shadow: 0 0 0 5px #eeedf7; }

.auth-wrap .vtog.auth-lang {
  grid-column: 2;
  grid-row: 2;
  justify-self: start;
  display: inline-flex;
  max-width: calc(100% - 88px);
  gap: 3px;
  margin: 0 44px 24px;
  padding: 4px;
  background: #f5f4ee;
  border: 1px solid #d9dcd6;
  border-radius: 8px;
  overflow: visible;
}
.auth-wrap .vtog.auth-lang button {
  min-width: 48px;
  min-height: 44px;
  padding: 9px 12px;
  color: var(--ink-2);
  background: transparent;
  border-radius: 5px;
  font: inherit;
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.4;
}
.auth-wrap .vtog.auth-lang button:hover { color: var(--ink); background: #e9e9e2; }
.auth-wrap .vtog.auth-lang button.on { color: #4b46c8; background: #e7e5f7; }
.auth-wrap .vtog.auth-lang button:focus-visible { outline: 2px solid var(--auth-focus); outline-offset: 1px; box-shadow: none; }
.auth-wrap .auth-legal {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0 7px;
  align-self: auto;
  margin: 0;
  padding-top: 0;
  color: var(--ink-3);
  font-size: 11.5px;
  line-height: 1.7;
  letter-spacing: 0;
}
.auth-wrap .auth-legal b {
  display: inline-block;
  flex: 0 0 auto;
  width: 47px;
  height: 17px;
  margin-right: 0;
  background: url("assets/drive-product-dark.svg") center / contain no-repeat;
  font-size: 0;
  vertical-align: middle;
}
.auth-wrap .auth-legal b::after { content: none; }

@media (min-width: 1100px) and (min-height: 850px) {
  .auth-wrap { padding-block: 48px; }
  .auth-wrap .auth-card { padding-top: 54px; padding-bottom: 26px; }
  .auth-wrap .vtog.auth-lang { margin-bottom: 40px; }
  .auth-wrap .auth-main::before { min-height: 570px; }
}
@media (max-width: 900px) {
  .auth-wrap { padding: max(24px, env(safe-area-inset-top, 0px)) 20px max(24px, env(safe-area-inset-bottom, 0px)); }
  .auth-wrap .auth-main { grid-template-columns: minmax(0, 1fr); width: min(480px, 100%); border-radius: 12px; }
  .auth-wrap .auth-main::before { content: none; }
  .auth-wrap .auth-card, .auth-wrap .auth-card.wide { grid-column: 1; padding: 34px 30px 20px; }
  .auth-wrap .vtog.auth-lang { grid-column: 1; justify-self: center; max-width: calc(100% - 60px); margin: 0 30px 26px; }
  .auth-wrap .auth-title { font-size: 36px; }
}
@media (max-width: 480px) {
  .auth-wrap { gap: 20px; padding-inline: 16px; }
  .auth-wrap .auth-card, .auth-wrap .auth-card.wide { padding: 30px 24px 18px; }
  .auth-wrap .auth-title { font-size: 32px; }
  .auth-wrap .vtog.auth-lang { max-width: calc(100% - 48px); margin: 0 24px 24px; }
  .auth-wrap .vtog.auth-lang button { min-width: 44px; padding-inline: 10px; }
  .auth-wrap .auth-legal { max-width: 100%; font-size: 11.5px; }
}
@media (max-width: 360px) {
  .auth-wrap { padding-inline: 12px; }
  .auth-wrap .auth-card, .auth-wrap .auth-card.wide { padding-inline: 20px; }
  .auth-wrap .vtog.auth-lang { max-width: calc(100% - 40px); margin-inline: 20px; }
  .auth-wrap .vtog.auth-lang button { padding-inline: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  .auth-wrap *, .auth-wrap *::before, .auth-wrap *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
@media (forced-colors: active) {
  .auth-wrap .auth-main { grid-template-columns: minmax(0, 1fr); width: min(480px, 100%); border-color: CanvasText; }
  .auth-wrap .auth-main::before { content: none; }
  .auth-wrap .auth-card, .auth-wrap .auth-card.wide, .auth-wrap .vtog.auth-lang { grid-column: 1; }
  .auth-wrap .pmark { width: auto; height: auto; background: none; }
  .auth-wrap .pmark .word { display: block; color: CanvasText; }
  .auth-wrap .pmark .word::after { color: CanvasText; }
  .auth-wrap .auth-legal b { width: auto; height: auto; background: none; color: CanvasText; font-size: inherit; vertical-align: baseline; }
  .auth-wrap :is(.btn, .pw-eye, .user-tile, .acct, .auth-lang button):focus-visible { outline: 2px solid Highlight; outline-offset: 3px; }
}
@media print {
  html:has(body > .auth-wrap), body:has(> .auth-wrap), .auth-wrap { background: #fff; }
  .auth-wrap { display: block; min-height: 0; padding: 0; }
  .auth-wrap .auth-main { display: block; width: 100%; border-radius: 0; }
  .auth-wrap .auth-main::before { content: none; }
  .auth-wrap .auth-card { padding: 24px; }
  .auth-wrap .vtog.auth-lang { margin: 0 24px 24px; }
  .auth-wrap .auth-legal { margin-top: 18px; }
}

/* Preview readability refinement: type and contrast, with the existing layout. */
@media screen {
  body:has(> .auth-wrap) { font-size: 15px; font-weight: 500; }
  .auth-wrap .auth-title { font-weight: 600; }
  .auth-wrap .auth-sub { font-size: 15px; font-weight: 500; color: var(--ink-2); }
  .auth-wrap .auth-card .lbl { font-size: 14px; font-weight: 650; }
  .auth-wrap .auth-card :is(input,select) { font-weight: 500; }
  .auth-wrap .auth-foot,
  .auth-wrap .fld-help { font-size: 13.5px; font-weight: 500; color: var(--ink-2); }
  .auth-wrap .fld-err { font-size: 14px; font-weight: 550; }
  .auth-wrap .auth-card .flash { font-size: 14px; font-weight: 500; }
  .auth-wrap .auth-card .btn { font-size: 15px; font-weight: 650; }
  .auth-wrap .vtog.auth-lang button { font-size: 14px; font-weight: 650; }
  .auth-wrap .or-row { font-size: 12.5px; font-weight: 650; color: var(--ink-2); }
  .auth-wrap :is(.user-tile,.acct) .nm { font-size: 15px; font-weight: 650; }
  .auth-wrap :is(.user-tile,.acct,.who) :is(.rl,.em,.un) { font-size: 13.5px; color: var(--ink-2); }
  .auth-wrap .auth-legal { font-size: 12.5px; font-weight: 500; color: var(--ink-2); }
}
