/* Страница входа: всё помещается в 100dvh, без прокрутки страницы. */
body.login-page .lg-stage {
  position: relative; z-index: 1;
  flex: 1 1 auto; min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(360px, 440px);
  gap: clamp(20px, 4vw, 64px);
  align-items: center;
  max-width: 1240px; width: 100%; margin: 0 auto;
  padding: clamp(14px, 3vh, 36px) clamp(16px, 4vw, 48px);
  box-sizing: border-box;
  overflow: hidden;
}
.lg-header .lg-nav { justify-content: flex-end; }

/* Hero */
.lg-hero { min-width: 0; display: flex; flex-direction: column; gap: clamp(10px, 2vh, 18px); }
.lg-title { margin: 0; line-height: .95; font-size: clamp(42px, 7.2vw, 92px); }
.lg-title .xa-h { letter-spacing: .06em; filter: drop-shadow(0 0 24px rgba(0, 240, 255, .25)); }
.lg-lead { margin: 0; max-width: 560px; color: var(--xa-muted); font-size: clamp(14px, 1.25vw, 16.5px); line-height: 1.55; }
.lg-feats { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; max-width: 640px; }
.lg-feats li {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px;
  background: var(--xa-glass); border: 1px solid var(--xa-border-soft); border-radius: var(--xa-r);
}
.lg-feats b { display: block; font-size: 13.5px; color: #fff; }
.lg-feats small { display: block; font-size: 11.5px; color: var(--xa-muted-2); }
.lg-feat-ic {
  flex: 0 0 34px; height: 34px; border-radius: 10px; display: grid; place-items: center;
  font: 800 12px var(--xa-font-display); color: #05070f;
}
.lg-feat-ic--c { background: var(--xa-cyan); box-shadow: 0 0 14px rgba(0, 240, 255, .5); }
.lg-feat-ic--v { background: var(--xa-violet); color: #fff; box-shadow: 0 0 14px rgba(123, 97, 255, .55); font-size: 15px; }
.lg-feat-ic--p { background: var(--xa-pink); color: #fff; box-shadow: 0 0 14px rgba(255, 45, 149, .5); font-size: 15px; }

.lg-board {
  display: block; max-width: 640px; text-decoration: none; color: inherit;
  padding: 12px 16px 0; border-radius: var(--xa-r-lg);
  background: linear-gradient(160deg, rgba(15, 21, 40, .82), rgba(10, 14, 26, .7));
  border: 1px solid var(--xa-border);
  box-shadow: var(--xa-shadow);
  transition: box-shadow .2s, border-color .2s;
}
.lg-board:hover { box-shadow: var(--xa-shadow), var(--xa-glow); }
.lg-board__head { display: flex; justify-content: space-between; align-items: center; }
.lg-board__more { font-size: 12.5px; color: var(--xa-cyan); font-weight: 600; }
.lg-podium { display: grid; grid-template-columns: 1fr 1.15fr 1fr; align-items: end; gap: 10px; margin-top: 6px; }
.lg-pod { display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center; min-width: 0; }
.lg-pod b { font-size: 13px; color: #fff; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lg-pod small { font-size: 11.5px; color: var(--xa-muted); }
.lg-pod__av {
  position: relative; width: 52px; height: 52px; border-radius: 50%; padding: 2px; margin-bottom: 4px;
  background: conic-gradient(var(--c1), var(--c2), var(--c1)); display: grid; place-items: center;
  font: 800 18px var(--xa-font-display); color: #fff;
}
.lg-pod__av { flex: none; }
.lg-pod__av img { position: absolute; inset: 2px; display: block; width: calc(100% - 4px); height: calc(100% - 4px); max-width: none; border-radius: 50%; object-fit: cover; background: var(--xa-bg-2); }
.lg-pod__av i {
  position: absolute; right: -4px; bottom: -4px; width: 20px; height: 20px; border-radius: 50%;
  display: grid; place-items: center; font: 800 10px var(--xa-font-display); font-style: normal; color: #05070f; background: var(--c1);
}
.lg-pod--1 { --c1: #ffd700; --c2: #ffb300; }
.lg-pod--2 { --c1: #cfd8ea; --c2: #8ea0bd; }
.lg-pod--3 { --c1: #e09a5a; --c2: #a8622b; }
.lg-pod--1 .lg-pod__av { width: 66px; height: 66px; box-shadow: 0 0 24px rgba(255, 215, 0, .45); }
.lg-pod__base {
  display: block; width: 100%; margin-top: 8px; border-radius: 10px 10px 0 0;
  background: linear-gradient(180deg, color-mix(in srgb, var(--c1) 35%, transparent), rgba(13, 19, 40, .2));
  border: 1px solid color-mix(in srgb, var(--c1) 45%, transparent); border-bottom: 0;
}
.lg-pod--1 .lg-pod__base { height: 46px; }
.lg-pod--2 .lg-pod__base { height: 30px; }
.lg-pod--3 .lg-pod__base { height: 20px; }

/* Card */
.lg-card-wrap { min-width: 0; padding: 0 !important; margin: 0 !important; max-width: none !important; }
.lg-card {
  position: relative;
  padding: clamp(18px, 3.2vh, 30px) clamp(18px, 2.2vw, 30px);
  border-radius: 22px;
  background: linear-gradient(165deg, rgba(15, 21, 40, .9), rgba(10, 14, 26, .86));
  border: 1px solid var(--xa-border);
  box-shadow: var(--xa-shadow), var(--xa-glow);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
}
.lg-card::before {
  content: ""; position: absolute; inset: -1px; border-radius: 22px; padding: 1px; pointer-events: none;
  background: linear-gradient(135deg, rgba(0, 240, 255, .8), transparent 35%, transparent 65%, rgba(123, 97, 255, .8));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude;
}
.lg-h { margin: 4px 0 2px; font-family: var(--xa-font-display); font-size: clamp(20px, 2.2vw, 26px); font-weight: 800; letter-spacing: .03em; color: #fff; }
.lg-sub { margin: 0 0 clamp(12px, 2.2vh, 20px); color: var(--xa-muted); font-size: 13.5px; }
.lg-error { margin: 0 0 12px; padding: 10px 12px; border-radius: 12px; font-size: 13.5px; color: #ffb3c8; background: rgba(255, 45, 149, .1); border: 1px solid rgba(255, 45, 149, .4); }
.lg-tabs { display: grid !important; grid-template-columns: 1fr 1fr; width: 100%; box-sizing: border-box; margin-bottom: clamp(12px, 2vh, 18px); }
.lg-tabs > button { justify-content: center; height: 36px; }
.lg-panel { display: none; }
.lg-panel.is-active { display: block; }
.lg-field { display: block; margin-bottom: clamp(10px, 1.8vh, 14px); }
.lg-field__label { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; font: 600 11px var(--xa-font-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--xa-muted-2); }
.lg-forgot { font: 600 12px var(--xa-font); letter-spacing: 0; text-transform: none; color: var(--xa-cyan); text-decoration: none; }
.lg-forgot:hover { text-decoration: underline; }
.lg-field__box {
  display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 6px 0 14px; border-radius: 14px;
  background: rgba(5, 7, 15, .7); border: 1px solid rgba(157, 139, 255, .3);
  transition: border-color .2s, box-shadow .2s;
}
.lg-field__box:focus-within { border-color: var(--xa-cyan); box-shadow: 0 0 0 3px rgba(0, 240, 255, .15), var(--xa-glow-sm); }
.lg-field__box > .xa-ic { color: var(--xa-muted-2); width: 18px; height: 18px; }
.lg-field__box:focus-within > .xa-ic { color: var(--xa-cyan); }
.lg-field__box input { flex: 1 1 auto; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent; color: #fff; font: 500 15px var(--xa-font); }
.lg-field__box input::placeholder { color: rgba(179, 192, 216, .5); }
.lg-eye { width: 36px; height: 36px; border: 0; border-radius: 10px; background: transparent; color: var(--xa-muted-2); cursor: pointer; display: grid; place-items: center; }
.lg-eye:hover { color: #fff; background: rgba(255, 255, 255, .05); }
.lg-eye svg { width: 18px; height: 18px; }
.lg-eye .lg-eye-on { display: none; }
.lg-eye.is-open .lg-eye-on { display: block; }
.lg-eye.is-open .lg-eye-off { display: none; }
.lg-btn { width: 100%; min-height: 50px; margin-top: 4px; position: relative; font-size: 14.5px; }
.lg-btn.is-loading .lg-btn-t { opacity: 0; }
.lg-spin { display: none; position: absolute; width: 20px; height: 20px; border-radius: 50%; border: 2px solid rgba(5, 7, 15, .35); border-top-color: #05070f; animation: lg-spin .8s linear infinite; }
.lg-btn.is-loading .lg-spin { display: block; }
@keyframes lg-spin { to { transform: rotate(360deg); } }
.lg-alt { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: clamp(12px, 2vh, 18px); padding-top: clamp(10px, 1.8vh, 16px); border-top: 1px solid var(--xa-line); font-size: 13px; color: var(--xa-muted); }
.lg-tg { display: inline-flex; align-items: center; gap: 7px; padding: 7px 12px; border-radius: 999px; border: 1px solid rgba(0, 240, 255, .45); color: var(--xa-cyan); text-decoration: none; font-weight: 700; font-size: 13px; white-space: nowrap; }
.lg-tg svg { width: 16px; height: 16px; }
.lg-tg:hover { background: rgba(0, 240, 255, .08); }

/* Невысокие экраны ноутбуков */
@media (max-height: 820px) and (min-width: 861px) {
  .lg-feats li { padding: 8px 10px; }
  .lg-pod--1 .lg-pod__av { width: 56px; height: 56px; }
  .lg-pod__av { width: 44px; height: 44px; }
  .lg-pod--1 .lg-pod__base { height: 34px; }
  .lg-pod--2 .lg-pod__base { height: 22px; }
  .lg-pod--3 .lg-pod__base { height: 14px; }
}
@media (max-height: 700px) and (min-width: 861px) {
  .lg-board { display: none; }
}

/* Планшет / телефон */
@media (max-width: 860px) {
  body.login-page .lg-stage {
    grid-template-columns: 1fr; align-content: center; gap: 14px;
    padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
    max-width: 480px;
  }
  .lg-header .lg-nav { display: none; }
  .lg-hero { gap: 6px; text-align: center; align-items: center; }
  .lg-hero > .xa-label { display: none; }
  .lg-title { font-size: clamp(34px, 11vw, 46px); }
  .lg-lead { font-size: 13px; max-width: 360px; }
  .lg-feats { display: none; }
  .lg-board { display: none; }
  .lg-card { padding: 18px 16px; border-radius: 20px; }
  .lg-card::before { border-radius: 20px; }
  .lg-card > .xa-label { display: none; }
  .lg-alt { flex-direction: column; align-items: stretch; text-align: center; gap: 8px; }
  .lg-tg { justify-content: center; }
}
@media (max-width: 860px) and (min-height: 760px) {
  .lg-board { display: block; width: 100%; padding: 10px 12px 0; }
  .lg-board__head { display: none; }
  .lg-pod__av { width: 40px; height: 40px; font-size: 14px; }
  .lg-pod--1 .lg-pod__av { width: 48px; height: 48px; }
  .lg-pod b { font-size: 12px; }
  .lg-pod small { font-size: 10.5px; }
  .lg-pod--1 .lg-pod__base { height: 22px; }
  .lg-pod--2 .lg-pod__base { height: 14px; }
  .lg-pod--3 .lg-pod__base { height: 8px; }
}
.lg-feats li { justify-content: flex-start; }
.lg-feats li b { font-size: 13.5px; }
.lg-btn-t small { display: block; font-size: 10px; letter-spacing: .14em; opacity: .7; font-weight: 700; margin-top: 1px; }
.lg-btn .lg-btn-t { line-height: 1.15; }
.lg-forgot-row { margin: -4px 0 12px; text-align: right; }
.lg-reg { margin: 10px 0 0; font-size: 13px; color: var(--xa-muted); text-align: center; }
.lg-reg a { color: var(--xa-cyan); font-weight: 700; text-decoration: none; }
@media (max-width: 860px) { .lg-feats { display: none; } }
