/* ==========================================================
   Проходка — стили по макетам (Prohodka-design/screens)
   ========================================================== */
:root {
  --bg: #F2F5FC;
  --card: #FFFFFF;
  --ink: #0F1A2E;
  --muted: #6B7489;
  --line: #E3E8F3;
  --primary: #2856E8;
  --primary-press: #1E46CF;
  --primary-soft: #DCE4FC;
  --navy: #17263F;
  --ok: #16815A;
  --bad: #C93A3F;
  --warn: #B7791F;
  --radius: 16px;
  --radius-sm: 12px;
  --shadow: 0 1px 2px rgba(15, 26, 46, .04), 0 6px 20px rgba(15, 26, 46, .05);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: #DDE3F0;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }

/* ---------- «Телефон» ---------- */
#app {
  position: relative;
  max-width: 430px;
  height: 100vh;
  height: 100dvh;
  margin: 0 auto;
  overflow: hidden;
  background: var(--bg);
  display: flex;
  flex-direction: column;
}
@media (min-width: 600px) {
  body { padding: 24px 0; }
  #app {
    min-height: min(900px, calc(100dvh - 48px));
    height: min(900px, calc(100dvh - 48px));
    border-radius: 36px;
    box-shadow: 0 30px 80px rgba(15, 26, 46, .18);
    overflow: hidden;
  }
}

.screen { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.scroll { flex: 1; overflow-y: auto; padding: 8px 20px 24px; display: flex; flex-direction: column; }
.scroll > * { flex-shrink: 0; }

/* ---------- Шапка ---------- */
.topbar {
  display: flex; align-items: center; gap: 12px;
  padding: 18px 20px 10px;
}
.topbar .back {
  width: 32px; height: 32px; margin-left: -8px;
  border: 0; background: none; border-radius: 10px;
  display: grid; place-items: center;
}
.topbar .back:hover { background: rgba(15,26,46,.06); }
.topbar .back svg { width: 18px; height: 18px; }
.topbar .brand { font-weight: 800; font-size: 20px; letter-spacing: -.01em; flex: 1; }
.topbar .logo { width: 44px; height: 26px; color: var(--primary); }
.topbar .net-pill { margin-left: auto; }

/* ---------- Типографика ---------- */
.eyebrow { font-size: 13px; color: var(--muted); margin: 6px 0 4px; }
.eyebrow a { color: inherit; text-decoration: none; }
h1.title { font-size: 30px; line-height: 1.12; font-weight: 800; letter-spacing: -.02em; margin: 6px 0 8px; }
h1.hero { font-size: 38px; line-height: 1.15; font-weight: 800; letter-spacing: -.02em; margin: 28px 0 14px; }
.subtitle { font-size: 14px; color: var(--muted); margin: 0 0 20px; line-height: 1.45; }
h3.section { font-size: 15px; font-weight: 700; margin: 22px 0 10px; }
.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.meta { font-size: 13px; color: var(--primary); }
.dot { margin: 0 6px; }
.mono { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; }

/* ---------- Кнопки ---------- */
.btn {
  display: flex; align-items: center; justify-content: flex-start; gap: 8px;
  width: 100%; min-height: 50px; padding: 0 18px;
  border-radius: 14px; border: 1px solid transparent;
  font-weight: 700; font-size: 15.5px; text-align: left;
  transition: background .15s, transform .05s, box-shadow .15s;
}
.btn:active { transform: scale(.99); }
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 6px 16px rgba(40, 86, 232, .25); }
.btn-primary:hover { background: var(--primary-press); }
.btn-secondary { background: var(--card); color: var(--ink); border-color: var(--line); }
.btn-secondary:hover { background: #F8FAFE; }
.btn-ghost { background: transparent; color: var(--primary); min-height: 40px; padding: 0 4px; font-weight: 600; font-size: 14px; }
.btn-danger { background: var(--card); color: var(--bad); border-color: #F2D4D6; }
.btn[disabled] { opacity: .5; pointer-events: none; }
.btn + .btn { margin-top: 12px; }
.btn-row { display: flex; gap: 10px; }
.btn-row .btn { margin-top: 0; justify-content: center; text-align: center; }
.btn-sm { min-height: 38px; font-size: 13.5px; border-radius: 11px; padding: 0 12px; justify-content: center; }
.push { margin-top: auto; padding-top: 20px; }

/* ---------- Формы ---------- */
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; }
.input, select.input {
  width: 100%; height: 48px; padding: 0 14px;
  background: var(--card); border: 1px solid var(--line); border-radius: 12px;
  outline: none; font-size: 16px; /* меньше 16px — iPhone приближает страницу при вводе */
  transition: border-color .15s, box-shadow .15s;
}
.input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(40, 86, 232, .15); }
.input.code { text-align: center; letter-spacing: .5em; font-size: 22px; font-weight: 700; height: 56px; }
.field .err { color: var(--bad); font-size: 12.5px; margin-top: 5px; min-height: 0; }
.field .hint { color: var(--muted); font-size: 12px; margin-top: 5px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.check { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--muted); margin: -4px 0 14px; justify-content: flex-end; cursor: pointer; user-select: none; }
.field .file-drop, .file-drop {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  height: 92px; border: 1.5px dashed #C4CEE6; border-radius: 12px; background: #FAFBFF;
  color: var(--muted); font-size: 14px; cursor: pointer; overflow: hidden; position: relative;
}
.file-drop img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.file-drop input { display: none; }

/* ---------- Карточки ---------- */
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; }
.card + .card { margin-top: 12px; }
.card.tap { cursor: pointer; transition: transform .1s, box-shadow .15s; }
.card.tap:hover { box-shadow: 0 2px 4px rgba(15,26,46,.05), 0 10px 26px rgba(15,26,46,.08); }
.card.tap:active { transform: scale(.995); }
.card .ttl { font-weight: 700; font-size: 16px; line-height: 1.25; margin-bottom: 6px; }
.card .addr { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.card-row { display: flex; align-items: center; gap: 12px; }
.card-row .grow { flex: 1; min-width: 0; }
.chev { color: var(--primary); font-size: 20px; }

.invite { background: var(--primary-soft); border-radius: var(--radius); padding: 16px; }
.invite .ttl { font-weight: 700; margin-bottom: 10px; }
.invite-row { display: flex; gap: 8px; }
.invite-row .input { height: 46px; border-color: transparent; }
.invite-row .go { width: 52px; flex: none; border: 0; border-radius: 12px; background: var(--primary); color: #fff; font-size: 18px; }

/* Обложка события (полоски как в макете) */
.cover {
  position: relative; border-radius: 12px; background: var(--primary-soft);
  height: 96px; overflow: hidden; margin-bottom: 12px; display: flex; align-items: center; padding: 0 16px;
}
.cover.big { height: 170px; border-radius: 0; margin: 0 -20px 20px; padding: 0 20px; }
.cover .cover-text { font-weight: 800; color: var(--primary); font-size: 19px; line-height: 1.2; max-width: 55%; position: relative; z-index: 1; }
.cover.big .cover-text { font-size: 26px; }
.cover .bars { position: absolute; right: 16px; top: 14px; bottom: 14px; display: flex; gap: 6px; }
.cover .bars i { width: 7px; background: var(--primary); border-radius: 3px; }
.cover.big .bars { right: 24px; top: 20px; bottom: 20px; gap: 9px; }
.cover.big .bars i { width: 10px; }
.cover .pat { position: absolute; right: 10px; top: 10px; bottom: 10px; height: calc(100% - 20px); width: 50%; opacity: .95; }
.cover.big .pat { right: 20px; top: 22px; bottom: 22px; height: calc(100% - 44px); }
.fill { display: flex; align-items: center; gap: 10px; margin-top: 10px; font-size: 12.5px; color: var(--muted); }
.fill-bar { width: 72px; height: 5px; border-radius: 3px; background: var(--primary-soft); overflow: hidden; flex: none; }
.fill-bar i { display: block; height: 100%; border-radius: 3px; }
.chips { display: flex; gap: 8px; overflow-x: auto; margin: -2px -20px 12px; padding: 2px 20px 4px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; height: 34px; padding: 0 14px; border-radius: 17px; border: 1px solid var(--line); background: var(--card); font-size: 13px; font-weight: 600; color: var(--ink); }
.chip.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* ---------- Роль ---------- */
.role-card { padding: 20px; }
.role-card .head { display: flex; align-items: center; gap: 12px; font-weight: 700; font-size: 17px; }
.role-card .ico { width: 38px; height: 38px; border-radius: 10px; background: var(--primary-soft); color: var(--primary); display: grid; place-items: center; }
.role-card p { margin: 14px 0 0; font-size: 13.5px; color: var(--muted); line-height: 1.45; }
.role-card .chev { margin-left: auto; }

/* ---------- Стартовый билет ---------- */
.ticket-hero {
  position: relative; margin: 26px auto 0; width: 80%; background: var(--primary); color: #fff;
  border-radius: 18px; padding: 22px 22px 24px; box-shadow: 0 16px 34px rgba(40, 86, 232, .28);
}
.ticket-hero::before, .ticket-hero::after {
  content: ""; position: absolute; top: 47%; width: 14px; height: 14px; border-radius: 50%; background: var(--bg);
}
.ticket-hero::before { left: -7px; } .ticket-hero::after { right: -7px; }
.ticket-hero .t1 { font-size: 22px; font-weight: 800; }
.ticket-hero .t2 { font-size: 13.5px; opacity: .85; margin-top: 4px; }
.ticket-hero hr { border: 0; border-top: 1px solid rgba(255,255,255,.35); margin: 18px 0; }
.ticket-hero .t3 { font-weight: 700; font-size: 14px; }

/* ---------- Билет участника ---------- */
.ticket { background: var(--card); border-radius: 20px; box-shadow: var(--shadow); overflow: hidden; }
.ticket .head { background: var(--primary); color: #fff; padding: 18px 20px; border-radius: 20px; }
.ticket .head .ttl { font-weight: 800; font-size: 18px; }
.ticket .head .when { font-size: 13.5px; opacity: .9; margin-top: 8px; }
.ticket .qr-wrap { padding: 22px 0 10px; display: flex; flex-direction: column; align-items: center; }
.ticket canvas.qr { width: 210px; height: 210px; image-rendering: pixelated; }
.ticket.used canvas.qr { opacity: .18; }
.live-strip { width: 210px; height: 4px; border-radius: 2px; margin-top: 12px; background: var(--primary-soft); overflow: hidden; position: relative; }
.live-strip::after { content: ""; position: absolute; top: 0; bottom: 0; width: 40%; background: var(--primary); border-radius: 2px; animation: live 1.6s ease-in-out infinite alternate; }
@keyframes live { from { left: 0; } to { left: 60%; } }
.live-time { font-size: 11.5px; color: var(--muted); margin-top: 6px; font-variant-numeric: tabular-nums; }
.ticket .code { font-size: 13px; color: var(--muted); margin-top: 4px; letter-spacing: .08em; }
.ticket .foot { border-top: 1px solid var(--line); margin: 6px 20px 0; padding: 14px 0 18px; display: flex; align-items: flex-start; gap: 10px; }
.ticket .foot .name { font-weight: 800; font-size: 16px; }
.badge { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: 8px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.badge.ok { background: #E3F4EC; color: var(--ok); }
.badge.bad { background: #FBE7E8; color: var(--bad); }
.badge.warn { background: #FBF0DD; color: var(--warn); }
.badge.info { background: var(--primary-soft); color: var(--primary); }
.badge.muted { background: #EEF1F7; color: var(--muted); }

/* ---------- Таббар ---------- */
.tabbar { display: flex; border-top: 1px solid var(--line); background: var(--bg); padding: 8px 0 calc(10px + env(safe-area-inset-bottom)); }
.tabbar button { flex: 1; border: 0; background: none; display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 11px; color: var(--muted); padding: 4px 0; }
.tabbar button svg { width: 20px; height: 20px; }
.tabbar button.active { color: var(--primary); font-weight: 600; }

/* ---------- Дашборд ---------- */
.stat-hero { background: var(--primary); color: #fff; border-radius: 18px; padding: 18px 20px 20px; box-shadow: 0 12px 28px rgba(40, 86, 232, .25); }
.stat-hero .lbl { font-size: 13.5px; opacity: .9; display: flex; align-items: center; gap: 8px; }
.stat-hero .num { font-size: 46px; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.stat-hero .of { font-size: 14px; opacity: .85; margin-left: 10px; }
.stat-hero .bar { margin-top: 12px; height: 5px; border-radius: 3px; background: rgba(255,255,255,.3); overflow: hidden; }
.stat-hero .bar i { display: block; height: 100%; background: #fff; border-radius: 3px; transition: width .4s; }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: #7CF0B5; box-shadow: 0 0 0 0 rgba(124,240,181,.7); animation: pulse 1.8s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(124,240,181,.7); } 70% { box-shadow: 0 0 0 8px rgba(124,240,181,0); } 100% { box-shadow: 0 0 0 0 rgba(124,240,181,0); } }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 12px; }
.stats .card { padding: 12px; }
.stats .card + .card { margin-top: 0; }
.stats .v { font-size: 22px; font-weight: 800; font-variant-numeric: tabular-nums; }
.stats .k { font-size: 11.5px; color: var(--muted); margin-top: 2px; line-height: 1.25; }
.chart { display: flex; align-items: flex-end; gap: 4px; height: 90px; margin-top: 10px; }
.chart .col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; height: 100%; justify-content: flex-end; }
.chart .col i { width: 100%; background: var(--primary); border-radius: 4px 4px 2px 2px; min-height: 2px; transition: height .3s; }
.chart .col span { font-size: 9.5px; color: var(--muted); }
.feed { list-style: none; margin: 0; padding: 0; }
.feed li { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.feed li:last-child { border-bottom: 0; }
.feed .ic { width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; font-size: 13px; color: #fff; flex: none; }
.feed .ic.ok { background: var(--ok); } .feed .ic.bad { background: var(--bad); } .feed .ic.warn { background: var(--warn); }
.feed .grow { flex: 1; min-width: 0; }
.feed .sub { font-size: 11.5px; color: var(--muted); }
.feed .t { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.linkbox { display: flex; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: 12px; height: 48px; padding: 0 6px 0 14px; gap: 6px; }
.linkbox span { flex: 1; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.linkbox button { border: 0; background: none; color: var(--primary); width: 36px; height: 36px; border-radius: 9px; display: grid; place-items: center; }
.linkbox button:hover { background: var(--primary-soft); }
.alert { border-radius: 12px; padding: 12px 14px; font-size: 13px; line-height: 1.4; display: flex; gap: 10px; align-items: flex-start; }
.alert.warn { background: #FBF0DD; color: #7A5212; }
.alert.bad { background: #FBE7E8; color: #8A2328; }
.alert.info { background: var(--primary-soft); color: #1C3BA6; }
.alert.ok { background: #E3F4EC; color: #0F5C40; }

/* ---------- Сканер ---------- */
.scanner-box {
  position: relative; width: 100%; aspect-ratio: 1 / 1; border-radius: 22px; background: var(--navy);
  overflow: hidden; display: grid; place-items: center;
}
.scanner-box > video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

.scanner-box .corners { position: absolute; inset: 6%; pointer-events: none; z-index: 2; }
.scanner-box .corners i { position: absolute; width: 14%; height: 14%; border: 3px solid #A9BCF5; border-radius: 4px; }
.scanner-box .corners i:nth-child(1) { left: 0; top: 0; border-right: 0; border-bottom: 0; }
.scanner-box .corners i:nth-child(2) { right: 0; top: 0; border-left: 0; border-bottom: 0; }
.scanner-box .corners i:nth-child(3) { left: 0; bottom: 0; border-right: 0; border-top: 0; }
.scanner-box .corners i:nth-child(4) { right: 0; bottom: 0; border-left: 0; border-top: 0; }
.scanner-box .laser { position: absolute; left: 9%; right: 9%; height: 2px; background: #6E8CF0; top: 50%; z-index: 2; box-shadow: 0 0 12px #6E8CF0; animation: laser 2.2s ease-in-out infinite alternate; }
@keyframes laser { from { top: 10%; } to { top: 90%; } }
.scanner-box .hint { position: absolute; left: 0; right: 0; bottom: 8%; z-index: 2; color: #fff; font-size: 14px; text-align: center; padding: 0 30px; text-shadow: 0 1px 3px rgba(0,0,0,.5); }
.scanner-box .verdict {
  position: absolute; z-index: 3; width: 34%; aspect-ratio: 1/1; border-radius: 22%;
  display: grid; place-items: center; animation: pop .22s ease-out;
}
.scanner-box .verdict svg { width: 46%; height: 46%; }
.scanner-box .verdict.ok { background: #1E8A5F; }
.scanner-box .verdict.bad { background: #C9383E; }
.scanner-box .verdict.warn { background: #B97A1C; }
.scanner-box.has-verdict video { filter: brightness(.35) blur(2px); }
@keyframes pop { from { transform: scale(.6); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.scan-status { margin: 22px 0 4px; font-size: 22px; font-weight: 800; color: var(--primary); }
.scan-status.ok { color: var(--ok); } .scan-status.bad { color: var(--bad); } .scan-status.warn { color: var(--warn); }
.scan-sub { font-size: 13.5px; color: var(--muted); min-height: 20px; }
.scan-meta { display: flex; justify-content: space-between; align-items: center; margin-top: 14px; font-size: 12.5px; color: var(--muted); }
.net-pill { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 10px; border-radius: 14px; font-size: 12px; font-weight: 600; border: 0; }
.net-pill.on { background: #E3F4EC; color: var(--ok); }
.net-pill.off { background: #FBE7E8; color: var(--bad); }
.net-pill i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }

/* ---------- Нижний лист и тосты ---------- */
.sheet-backdrop { position: absolute; inset: 0; background: rgba(15, 26, 46, .35); z-index: 50; display: flex; align-items: flex-end; animation: fade .15s; }
.sheet { width: 100%; background: var(--bg); border-radius: 22px 22px 0 0; padding: 10px 20px 24px; max-height: 85%; overflow-y: auto; animation: up .2s ease-out; }
.sheet .grab { width: 40px; height: 4px; border-radius: 2px; background: #C9D0DE; margin: 0 auto 14px; }
.sheet h3 { margin: 0 0 12px; font-size: 18px; }
@keyframes up { from { transform: translateY(30px); opacity: .5; } to { transform: none; opacity: 1; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
#toast { position: fixed; left: 50%; bottom: 40px; transform: translateX(-50%); z-index: 100; background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 12px; font-size: 14px; box-shadow: 0 10px 30px rgba(0,0,0,.2); max-width: 380px; text-align: center; transition: opacity .2s; }

.empty { text-align: center; color: var(--muted); font-size: 14px; padding: 30px 10px; }
.kv { display: flex; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.kv:last-child { border-bottom: 0; }
.kv span:first-child { color: var(--muted); }
.spacer { height: 12px; }

/* ---------- Нижнее меню: иконки с «пилюлей» у активной вкладки ---------- */
.tabbar button .ti { width: 56px; height: 30px; border-radius: 15px; display: grid; place-items: center; transition: background .2s, transform .2s; }
.tabbar button svg { width: 22px; height: 22px; overflow: visible; }
.tabbar button svg .fi { fill: currentColor; stroke: none; opacity: 0; transition: opacity .2s; }
.tabbar button.active .ti { background: rgba(40, 86, 232, .12); }
.tabbar button.active svg .fi { opacity: .16; }
.tabbar button:active .ti { transform: scale(.92); }
.tabbar button svg .laser { opacity: 0; }
.tabbar button.active svg .laser { opacity: .9; animation: tab-laser 2.2s ease-in-out infinite; }
@keyframes tab-laser { 0%, 100% { transform: translateY(-5px); } 50% { transform: translateY(5px); } }
@media (prefers-reduced-motion: reduce) { .tabbar button.active svg .laser { animation: none; } }

/* ---------- Устройства и входы ---------- */
.sess { display: flex; align-items: flex-start; gap: 12px; padding: 14px; margin-bottom: 10px; }
.sess.cur { border: 1.5px solid rgba(40, 86, 232, .35); }
.sess .grow { flex: 1; min-width: 0; }
.sess-ic { width: 40px; height: 40px; border-radius: 12px; background: #EAF0FD; color: var(--primary); display: grid; place-items: center; flex-shrink: 0; }
.sess-ic svg { width: 22px; height: 22px; }
.sess-t { font-weight: 600; font-size: 15px; }
.sess .sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; line-height: 1.4; word-break: break-all; }
.sess .badge { height: 20px; }
.sess-label { font-size: 12.5px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; margin: 10px 2px 8px; }
.sess + .sess { margin-top: 0; }

/* ---------- Выбор режима: при регистрации и в профиле ---------- */
.role-pick { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.role-opt { border: 1.5px solid var(--line); background: var(--card); border-radius: 14px; padding: 14px 12px; text-align: left; display: flex; flex-direction: column; gap: 4px; color: var(--ink); font: inherit; cursor: pointer; transition: border-color .15s, background .15s; }
.role-opt svg { width: 24px; height: 24px; color: var(--primary); margin-bottom: 4px; }
.role-opt svg .fi, .seg svg .fi { fill: currentColor; stroke: none; opacity: .14; }
.role-opt svg .laser, .seg svg .laser { display: none; }
.role-opt b { font-size: 15px; }
.role-opt span { font-size: 12.5px; color: var(--muted); line-height: 1.35; }
.role-opt.on { border-color: var(--primary); background: #EEF2FE; box-shadow: 0 0 0 3px rgba(40, 86, 232, .12); }
.seg { display: flex; background: #E6EBF6; border-radius: 12px; padding: 4px; gap: 4px; }
.seg button { flex: 1; border: 0; background: none; border-radius: 9px; height: 40px; display: flex; align-items: center; justify-content: center; gap: 7px; font: inherit; font-size: 14.5px; font-weight: 600; color: var(--muted); cursor: pointer; }
.seg button svg { width: 19px; height: 19px; }
.seg button.on { background: var(--card); color: var(--primary); box-shadow: 0 1px 3px rgba(16, 24, 40, .12); }
.seg button .cnt { margin-left: 6px; font-size: 12px; font-weight: 700; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: rgba(16, 24, 40, .07); display: inline-grid; place-items: center; }
.seg button.on .cnt { background: rgba(40, 86, 232, .12); }

/* ---------- Ник ---------- */
.nick-wrap { position: relative; }
.nick-wrap > span { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); font-weight: 700; color: var(--primary); pointer-events: none; font-size: 16px; }
.nick-wrap .input { padding-left: 32px; }
.field .hint.ok { color: var(--ok); font-weight: 600; }
.nick-tag { display: inline-block; align-self: flex-start; margin: -2px 0 8px; padding: 3px 10px; border-radius: 10px; background: #EEF2FE; color: var(--primary); font-weight: 700; font-size: 14px; }
.nick-id { color: var(--primary); }
