/* Linear-style welcome flow: one question per screen on the black pre-auth shell,
   a stage on the right that reacts to what the person types. Scoped by the
   .welcome- prefix; shares the auth.css tokens on purpose so the hand-over from
   sign-up is invisible. */
.welcome-page {
  min-height: 100dvh;
  display: grid;
  grid-template-columns: minmax(0, 52%) minmax(0, 48%);
  background: #08090a;
  color: #f7f8f8;
  font-family: var(--font-inter, 'Inter', system-ui, sans-serif);
  -webkit-font-smoothing: antialiased;
}
.welcome-pane {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 72px clamp(24px, 9vw, 120px) 96px;
  position: relative;
}
.welcome-inner { width: 100%; max-width: 460px; }
.welcome-eyebrow { font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: #62666d; font-weight: 510; margin: 0 0 14px; }
.welcome-pane .auth-title { text-align: left; margin-bottom: 8px; }
.welcome-pane .auth-subtitle { text-align: left; margin: 0 0 28px; max-width: none; text-wrap: pretty; }
.welcome-form { display: flex; flex-direction: column; gap: 20px; }
.welcome-field { display: flex; flex-direction: column; gap: 8px; }
.welcome-label { font-size: 13px; color: #8a8f98; font-weight: 510; display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.welcome-label .hint { font-weight: 400; color: #62666d; font-size: 12px; }
.welcome-pane .auth-notice { text-align: left; display: flex; gap: 10px; align-items: flex-start; }
.welcome-pane .auth-notice .auth-textbtn { margin-left: auto; white-space: nowrap; }

.welcome-cards { display: grid; gap: 8px; }
.welcome-card {
  text-align: left; background: #141517; border: 1px solid rgba(255,255,255,0.08); border-radius: 10px;
  padding: 12px 14px; display: flex; gap: 12px; align-items: center; color: inherit; font: inherit; cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}
.welcome-card:hover { border-color: rgba(255,255,255,0.16); }
.welcome-card[aria-pressed="true"] { border-color: #00dd59; background: rgba(0,221,89,0.06); }
.welcome-card:focus-visible, .welcome-chip:focus-visible, .welcome-switch:focus-visible, .welcome-iconbtn:focus-visible { outline: 2px solid #00dd59; outline-offset: 2px; }
.welcome-card .t { font-weight: 510; font-size: 14px; }
.welcome-card .s { color: #8a8f98; font-size: 12.5px; }
.welcome-card .ico { width: 30px; height: 30px; border-radius: 8px; background: rgba(255,255,255,0.05); display: grid; place-items: center; font-size: 15px; flex: none; }
.welcome-card .tail { margin-left: auto; font-size: 11px; color: #62666d; border: 1px solid rgba(255,255,255,0.08); border-radius: 6px; padding: 2px 7px; white-space: nowrap; }
.welcome-card[aria-pressed="true"] .tail { color: #00dd59; border-color: rgba(0,221,89,0.4); }
.welcome-mono { width: 34px; height: 34px; border-radius: 8px; display: grid; place-items: center; font-weight: 590; font-size: 12px; letter-spacing: 0.02em; flex: none; }

.welcome-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.welcome-chip {
  border: 1px solid rgba(255,255,255,0.08); background: transparent; border-radius: 999px; padding: 6px 12px;
  color: #8a8f98; font: inherit; font-size: 13px; cursor: pointer; transition: all 0.15s ease;
}
.welcome-chip:hover { border-color: rgba(255,255,255,0.16); color: #f7f8f8; }
.welcome-chip[aria-pressed="true"] { background: rgba(0,221,89,0.14); border-color: rgba(0,221,89,0.5); color: #00dd59; }

.welcome-rows { border-top: 1px solid rgba(255,255,255,0.08); }
.welcome-row { padding: 15px 0; border-bottom: 1px solid rgba(255,255,255,0.08); display: flex; justify-content: space-between; gap: 16px; align-items: center; }
.welcome-row .t { font-weight: 510; font-size: 15px; }
.welcome-row .s { color: #8a8f98; font-size: 13px; margin-top: 2px; }
.welcome-row .s a { color: #f7f8f8; text-decoration: none; }
.welcome-row .s a:hover { text-decoration: underline; text-underline-offset: 3px; }
.welcome-switch { width: 36px; height: 20px; border-radius: 999px; background: rgba(255,255,255,0.16); position: relative; border: 0; padding: 0; cursor: pointer; flex: none; transition: background-color 0.15s ease; }
.welcome-switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform 0.15s ease; }
.welcome-switch[aria-checked="true"] { background: #00dd59; }
.welcome-switch[aria-checked="true"]::after { transform: translateX(16px); }
.welcome-iconrow { display: flex; gap: 8px; flex: none; }
.welcome-iconbtn { width: 32px; height: 32px; border-radius: 50%; border: 1px solid rgba(255,255,255,0.16); background: #141517; display: grid; place-items: center; color: #f7f8f8; flex: none; cursor: pointer; transition: border-color 0.15s ease, color 0.15s ease; }
.welcome-iconbtn:hover { border-color: #00dd59; }

.welcome-consent { font-size: 12.5px; color: #62666d; margin: 0; line-height: 1.5; text-wrap: pretty; }
.welcome-consent a { color: #8a8f98; text-decoration: none; }
.welcome-consent .welcome-link--strong { background: none; border: 0; padding: 0; font: inherit; font-weight: 510; color: #8a8f98; cursor: pointer; }
.welcome-consent .welcome-link--strong:hover { color: #f7f8f8; }
.welcome-consent a:hover { text-decoration: underline; text-underline-offset: 3px; }
.welcome-connected { font-size: 13px; color: #00dd59; margin: 0; }
.welcome-waiting { font-size: 13px; color: #8a8f98; margin: 0; }
.welcome-error { font-size: 13px; color: #ff7b7b; margin: 0; }

.welcome-inline-btn.auth-btn { width: auto; padding-inline: 16px; white-space: nowrap; flex: none; }
/* multi-line input: the single-line .auth-input padding pins text to the top edge */
.welcome-textarea.auth-input { height: auto; min-height: 96px; padding: 12px 16px; line-height: 1.5; resize: none; display: block; }
.welcome-linkbtn.auth-textbtn { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; }
/* The Mia contact row on the Telegram screen */
.welcome-contact { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; padding: 12px 14px; border: 1px solid rgba(255,255,255,0.08); border-radius: 12px; background: #141517; }
.welcome-contact__avatar { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; flex: none; }
.welcome-contact__text { flex: 1 1 180px; min-width: 0; }
.welcome-contact__name { font-weight: 510; font-size: 14px; }
.welcome-contact__sub { color: #8a8f98; font-size: 12.5px; line-height: 1.45; }
.welcome-contact .auth-btn.welcome-contact__btn { width: auto; height: 36px; padding-inline: 14px; font-size: 13px; white-space: nowrap; margin-left: auto; text-decoration: none; }
.welcome-actions { display: flex; justify-content: flex-end; align-items: center; gap: 10px; margin-top: 28px; }
.welcome-actions .auth-btn { width: auto; padding-inline: 20px; white-space: nowrap; }
.welcome-dots { position: absolute; left: clamp(24px, 9vw, 120px); bottom: 36px; display: flex; gap: 8px; align-items: center; }
.welcome-dot { width: 7px; height: 7px; border-radius: 4px; background: #62666d; transition: width 0.2s ease, background-color 0.2s ease; }
.welcome-dot--on { width: 24px; background: #f7f8f8; }
.welcome-dot--done { background: #8a8f98; }
/* A passed step's dot is a button: the way back. A larger hit area than the dot itself, the dot drawn inside. */
button.welcome-dot--done { position: relative; border: 0; padding: 0; cursor: pointer; font: inherit; }
button.welcome-dot--done::before { content: ""; position: absolute; inset: -8px; }
button.welcome-dot--done:hover { background: #f7f8f8; }
button.welcome-dot--done:focus-visible { outline: 2px solid #00dd59; outline-offset: 4px; }
button.welcome-dot--done:disabled { cursor: default; }

/* ---------- stage ---------- */
.welcome-stage {
  background: #0c0d0f; border-left: 1px solid rgba(255,255,255,0.08); position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: center; padding: 48px;
}
.welcome-stage::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(60% 50% at 70% 30%, rgba(0,221,89,0.07), transparent 70%),
    radial-gradient(40% 40% at 20% 85%, rgba(255,255,255,0.03), transparent 70%);
}
.welcome-stage-inner { position: relative; width: 100%; max-width: 520px; display: flex; flex-direction: column; gap: 12px; }
.welcome-panel { background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.08); border-radius: 14px; padding: 20px; animation: welcome-rise 0.35s ease both; }
@keyframes welcome-rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .welcome-panel { animation: none; } .welcome-dot { transition: none; } }
.welcome-panel h3 { margin: 0 0 12px; font-size: 12px; font-weight: 510; color: #62666d; text-transform: uppercase; letter-spacing: 0.08em; }
.welcome-big { font-size: 44px; font-weight: 590; letter-spacing: -0.03em; line-height: 1; font-variant-numeric: tabular-nums; display: flex; flex-direction: column; gap: 8px; }
.welcome-big small { font-size: 14px; line-height: 1.45; color: #8a8f98; font-weight: 400; letter-spacing: 0; }
.welcome-person { display: flex; gap: 14px; align-items: center; }
.welcome-avatar { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; font-weight: 590; font-size: 18px; background: rgba(0,221,89,0.14); color: #00dd59; border: 1px solid rgba(0,221,89,0.3); flex: none; }
.welcome-avatar--empty { background: #141517; color: #8a8f98; border-color: rgba(255,255,255,0.08); }
.welcome-avatar--small { width: 28px; height: 28px; font-size: 11px; }
/* Name & picture: the avatar is a button; hovering shows a "+", clicking opens the file picker. */
.welcome-avatar-btn { position: relative; width: 48px; height: 48px; border-radius: 50%; border: 0; padding: 0; background: none; cursor: pointer; flex: none; }
.welcome-avatar-btn .welcome-avatar { width: 48px; height: 48px; font-size: 15px; overflow: hidden; }
.welcome-avatar-btn img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; display: block; }
.welcome-avatar-plus { position: absolute; inset: 0; border-radius: 50%; display: grid; place-items: center; background: rgba(0,0,0,0.55); color: #fff; font-size: 22px; font-weight: 400; line-height: 1; opacity: 0; transition: opacity 0.15s ease; }
.welcome-avatar-btn:hover .welcome-avatar-plus, .welcome-avatar-btn:focus-visible .welcome-avatar-plus { opacity: 1; }
.welcome-avatar-btn.is-empty .welcome-avatar { border-color: rgba(255,255,255,0.16); color: #8a8f98; }
/* The ring lives on the overlay: the "+" layer covers the avatar, border included, so a ring under it never shows. */
.welcome-avatar-btn:hover .welcome-avatar-plus, .welcome-avatar-btn:focus-visible .welcome-avatar-plus { box-shadow: inset 0 0 0 1px #00dd59; }
.welcome-avatar-btn.is-empty .welcome-avatar-plus { background: #141517; color: #f7f8f8; }
.welcome-avatar-btn:focus-visible { outline: 2px solid #00dd59; outline-offset: 2px; }
.welcome-person .nm { font-size: 18px; font-weight: 590; letter-spacing: -0.01em; }
.welcome-person .tt { color: #8a8f98; }
.welcome-catalog { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-top: 16px; }
.welcome-catalog .c { border: 1px solid rgba(255,255,255,0.08); border-radius: 10px; padding: 10px 8px; text-align: center; }
.welcome-catalog .c .welcome-mono { margin: 0 auto 6px; }
.welcome-catalog .c .n { font-size: 11px; color: #8a8f98; }
.welcome-catalog .c--on { border-color: #00dd59; background: rgba(0,221,89,0.06); }
.welcome-catalog .c--on .n { color: #f7f8f8; }
.welcome-games { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 14px; }
.welcome-game { aspect-ratio: 4 / 3; border-radius: 10px; position: relative; overflow: hidden; border: 1px solid rgba(255,255,255,0.08); display: grid; place-items: center; }
.welcome-game span { width: 30px; height: 30px; border-radius: 50%; background: rgba(0,0,0,0.5); border: 1px solid rgba(255,255,255,0.3); display: grid; place-items: center; font-size: 11px; }
.welcome-game em { position: absolute; left: 8px; bottom: 6px; font-size: 11px; font-style: normal; color: rgba(255,255,255,0.9); text-shadow: 0 1px 2px rgba(0,0,0,0.6); }
.welcome-team { display: flex; flex-direction: column; gap: 8px; }
.welcome-team .m { display: flex; gap: 10px; align-items: center; font-size: 13px; }
.welcome-team .m .r { margin-left: auto; color: #62666d; font-size: 12px; }
.welcome-phone { width: 300px; max-width: 100%; margin: 0 auto; background: #0f1113; border: 1px solid rgba(255,255,255,0.16); border-radius: 28px; padding: 18px 14px 20px; box-shadow: 0 20px 60px rgba(0,0,0,0.5); }
.welcome-phone .hdr { display: flex; gap: 10px; align-items: center; padding: 0 4px 12px; border-bottom: 1px solid rgba(255,255,255,0.08); margin-bottom: 12px; }
.welcome-phone .hdr .av { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-weight: 590; font-size: 12px; background: rgba(84,161,255,0.16); color: #7db8ff; }
.welcome-phone .hdr .n { font-weight: 510; font-size: 13px; }
.welcome-phone .hdr .o { color: #62666d; font-size: 11px; }
.welcome-msgs { display: flex; flex-direction: column; gap: 8px; }
.welcome-msg { max-width: 88%; padding: 8px 11px; border-radius: 14px; font-size: 12.5px; line-height: 1.45; background: #1c1f22; border-bottom-left-radius: 4px; animation: welcome-rise 0.3s ease both; }
.welcome-msg--me { align-self: flex-end; background: rgba(0,221,89,0.18); border-bottom-right-radius: 4px; border-bottom-left-radius: 14px; }
.welcome-msg--ghost { color: #62666d; background: transparent; border: 1px dashed rgba(255,255,255,0.16); }
.welcome-msg .who { display: block; font-size: 11px; color: #62666d; margin-bottom: 2px; }
.welcome-check { display: flex; gap: 10px; align-items: center; font-size: 13px; padding: 6px 0; }
.welcome-check .ok { color: #00dd59; }
.welcome-check .off { color: #62666d; }
.welcome-check .r { margin-left: auto; color: #62666d; font-size: 12px; }

@media (max-width: 860px) {
  .welcome-page { grid-template-columns: 1fr; }
  .welcome-stage { display: none; }
  .welcome-pane { padding: 64px 24px 120px; }
  .welcome-dots { bottom: 84px; left: 24px; }
  .welcome-cards--two { grid-template-columns: 1fr; }
}
.welcome-consent strong, .welcome-waiting strong { color: #d0d6e0; font-weight: 510; }
/* The welcome pack on the last screen: the one number the person should leave with. */
.welcome-panel--accent { background: rgba(0,221,89,0.10); border-color: rgba(0,221,89,0.35); }
.welcome-panel--accent h3 { color: #5cff96; }
.welcome-panel--accent .welcome-big small { color: #c3cbc6; }

/* The "chosen once" confirmation on the company screen (founder, 2026-09-15): a dialog over the screen, so nothing below it moves. */
.welcome-modal-backdrop { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 24px; background: rgba(0,0,0,0.6); animation: welcome-fade 0.15s ease both; }
.welcome-modal { width: min(460px, 100%); padding: 20px 22px; border: 1px solid rgba(255,255,255,0.12); border-radius: 14px; background: #141517; box-shadow: 0 24px 60px rgba(0,0,0,0.5); animation: welcome-rise 0.2s ease both; }
.welcome-confirm__text { margin: 0; font-size: 14px; line-height: 1.55; color: #d0d6e0; text-wrap: pretty; }
.welcome-confirm__text strong { color: #f7f8f8; font-weight: 510; }
/* "contact support" inside a lock line or the confirmation: visibly a link, on the same palette. */
.welcome-support-link, .welcome-consent .welcome-support-link { color: #d0d6e0; text-decoration: underline; text-underline-offset: 3px; }
.welcome-support-link:hover, .welcome-consent .welcome-support-link:hover { color: #f7f8f8; }
.welcome-modal .welcome-actions { margin-top: 18px; }
@keyframes welcome-fade { from { opacity: 0; } to { opacity: 1; } }
/* An affiliate's solo/company choice is fixed with the organisation, like the role. */
.welcome-card:disabled { cursor: default; opacity: 0.6; }
.welcome-card:disabled:hover { border-color: rgba(255,255,255,0.08); }
