/* VALBLOX server-mode parts that sit on every page (loaded by assets/server/session.js, only when the API answers):
   the header's balance and Deposit button, and the site-wide toast queue. Same plates and tokens as styles.css. */

/* ---------------------------------------------------------------- header: balance + Deposit */
.bar__bal { gap: 8px; padding: 0 16px 4px 12px; --face: linear-gradient(180deg, #19202B 0%, #1D2531 100%); --bt: rgba(5, 8, 12, .5); --bb: rgba(var(--hi), .34); }
.bar__bal img { width: 20px; height: 21px; flex: none; }
.bar__bal-n { font-family: "Skranji", sans-serif; font-weight: 700; font-size: 16px; letter-spacing: .5px; color: var(--white); text-transform: none; font-variant-numeric: tabular-nums; }
.bar__bal[aria-current] { --rim: rgba(var(--lilac-rgb), .55); }
.bar__dep { padding: 0 18px 4px 14px; }
.bar__bal[hidden], .bar__dep[hidden] { display: none; }
.bar__user-lvl { width: 24px; height: 24px; font-size: 12px; margin-left: -2px; }
@media (max-width: 900px) {
  .bar__dep span { display: none; }
  .bar__dep { width: 44px; padding: 0 0 4px; }
  .bar__bal { padding: 0 12px 4px 9px; }
  .bar__bal-n { font-size: 14px; }
}
@media (max-width: 520px) {
  .is-signed-in .bar__rewards { display: none; }   /* the balance takes its place on a phone */
  .bar__user-lvl { display: none; }
}

/* ---------------------------------------------------------------- toasts (one queue, bottom right; bottom centre on phones) */
.vtoasts {
  position: fixed; right: 20px; bottom: 20px; z-index: 70; display: flex; flex-direction: column; gap: 10px;
  width: min(400px, calc(100vw - 24px)); pointer-events: none;
}
.vtoast {
  position: relative; isolation: isolate; display: flex; align-items: flex-start; gap: 12px; padding: 13px 12px 15px 16px;
  font-family: "Skranji", sans-serif; font-size: 14px; line-height: 20px; letter-spacing: .3px; color: var(--muted);
  pointer-events: auto; opacity: 0; transform: translateY(10px);
  filter: drop-shadow(0 10px 18px rgba(4, 7, 12, .5));
}
@media (prefers-reduced-motion: no-preference) { .vtoast { transition: opacity .2s ease, transform .2s ease; } }
.vtoast.is-on { opacity: 1; transform: none; }
.vtoast > .plate { --c: 10px; --n: 4px; --rim: rgba(var(--lilac-rgb), .45); --face: linear-gradient(180deg, #273042 0%, var(--dropdown) 100%); }
.vtoast--ok > .plate, .vtoast--coin > .plate { --rim: rgba(var(--green-rgb), .5); }
.vtoast--err > .plate { --rim: rgba(var(--salmon-rgb), .6); }
.vtoast > .ic { width: 20px; height: 20px; flex: none; color: var(--lilac); }
.vtoast--ok > .ic { color: var(--green); }
.vtoast--err > .ic { color: var(--salmon); }
.vtoast__coin { width: 20px; height: 21px; flex: none; }
.vtoast__b { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.vtoast__t { color: var(--white); overflow-wrap: anywhere; }
.vtoast__s { font-size: 13px; line-height: 18px; }
.vtoast__bar { display: block; height: 6px; margin-top: 5px; background: var(--track); box-shadow: inset 0 1px 0 rgba(0, 0, 0, .35);
  clip-path: polygon(3px 0, calc(100% - 3px) 0, 100% 3px, calc(100% - 3px) 100%, 3px 100%, 0 3px); }
.vtoast__bar i { display: block; height: 100%; background: linear-gradient(180deg, #B9E8FE 0 30%, #8FD4F3 30% 70%, #36708F 70% 100%); }
@media (prefers-reduced-motion: no-preference) { .vtoast__bar i { transition: width .4s ease; } }
.vtoast__a { flex: none; align-self: center; padding: 4px 8px; font-family: "GoldenSmile", sans-serif; font-size: 12px; letter-spacing: 1px; text-transform: uppercase; color: var(--lilac-light); }
.vtoast__a:hover, .vtoast__a:focus-visible { outline: none; text-decoration: underline; }
.vtoast__x { flex: none; width: 28px; height: 28px; margin: -4px -2px 0 0; display: grid; place-items: center; border: 0; background: none; color: var(--muted); }
.vtoast__x:hover, .vtoast__x:focus-visible { outline: none; color: var(--white); }
.vtoast__x .ic { width: 14px; height: 14px; }
@media (max-width: 600px) { .vtoasts { right: 12px; bottom: 12px; } }

/* the sign-in's server states (assets/server/login-server.js) */
.lg-check.is-fail .lg-check__ring { animation: none; opacity: 0; }
.lg-check.is-fail > .plate { --rim: rgba(var(--salmon-rgb), .55); }
.lg-fail { margin-top: 16px; flex-wrap: wrap; }
.lg-fail[hidden], .lg-factor[hidden] { display: none !important; }
.lg-factor { margin-top: 16px; }
.lg-passkey { margin-top: 12px; }

/* ---------------------------------------------------------------- the sign-in's ways in (login-server.js renders into
   [data-lg-routes]: the route buttons, or one field + one button + one message line; login.css keeps the slot's room) */
.lg-routes.is-wait { display: flex; min-height: 116px; }   /* GET /session on its way: the room of the two route buttons */
.lg-routes > .fld__msg:empty { display: none; }             /* the choice has no message line until there is a message */
.lg-rt { position: relative; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.lg-rt > .fld { position: relative; }
.lg-rt .fld__l > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lg-rt .fld__l b { font-weight: 400; color: var(--white); }
.lg-rt--alt .fld__l { padding-right: 56px; }      /* room for "Back" / "Later" at the right of the label line */
.lg-rt--code .fld__l { padding-right: 136px; }    /* ... for "Use another email" */
.lg-rt--code .fld__msg { padding-right: 140px; }  /* ... and for "Send again in 0:42" at the right of the message line */
.lg-rt--code .minput input { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 20px; letter-spacing: 4px; }
.lg-rt--code .minput input::placeholder { font-family: "Skranji", sans-serif; font-size: 17px; letter-spacing: .3px; }
.lg-rt__link {
  position: relative; display: inline-flex; align-items: center; gap: 7px; margin: 0; padding: 0 2px; border: 0; background: none; cursor: pointer;
  font-family: "Skranji", sans-serif; font-size: 13px; line-height: 18px; letter-spacing: .3px; color: var(--lilac);
  text-decoration: underline; text-underline-offset: 2px; white-space: nowrap;
}
.lg-rt__link::after { content: ""; position: absolute; inset: -9px -6px; }   /* a finger-sized target around the small text */
.lg-rt__link:hover { color: var(--lilac-lighter); }
.lg-rt__link:focus-visible { outline: 2px solid var(--lilac); outline-offset: 2px; color: var(--lilac-lighter); }
.lg-rt__link[aria-disabled="true"] { color: var(--muted); text-decoration: none; cursor: default; font-variant-numeric: tabular-nums; }
.lg-rt__link .ic { width: 15px; height: 15px; }
.lg-rt__alt { position: absolute; top: 1px; right: 0; }
.lg-rt__again { position: absolute; right: 0; bottom: 0; }
.lg-rt__solo { align-self: flex-start; text-decoration: none; font-size: 14px; line-height: 20px; color: var(--muted); }
.lg-rt__solo:hover span { text-decoration: underline; text-underline-offset: 2px; }

/* ---------------------------------------------------------------- security.html: sign-in methods (security.js) */
.sec-idn { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.sec-idn__i { display: flex; align-items: center; gap: 12px; min-width: 0; }
.sec-idn__i > .ic { width: 20px; height: 20px; flex: none; color: var(--lilac); }
.sec-idn__b { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; font-family: "Skranji", sans-serif; }
.sec-idn__b b { font-size: 15px; line-height: 21px; letter-spacing: .4px; color: var(--white); }
.sec-idn__i .btn { flex: none; }
.sec-idn-out:empty, [data-idn-msg]:empty { display: none; }
.sec-idn-form .minput { max-width: 380px; }
