/* ============================================================
   雲live 邀请落地页 · 样式
   设计稿参照 App 注册页：浅蓝底 / 白色胶囊输入框 / 青色渐变主按钮
   ============================================================ */

:root {
  --bg: #e9f6fb;
  --card: #ffffff;
  --primary: #33c3e8;
  --primary-deep: #22a9d4;
  --grad-from: #8cebF9;
  --grad-to: #41c9ec;
  --text: #1c2b33;
  --text-sub: #7b8a94;
  --placeholder: #b9c6ce;
  --border: #e4eef3;
  --danger: #f2566b;
}

* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }

html, body { height: 100%; overflow-x: hidden; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue",
               "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

.app {
  min-height: 100%;
  max-width: 480px;
  margin: 0 auto;
  padding: 0 24px calc(24px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
}

.hidden { display: none !important; }

/* ---------- 导航栏 ---------- */
.navbar {
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 0 -24px;
  padding: 0 16px;
}
.nav-title { font-size: 17px; font-weight: 600; }
.nav-back {
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  background: none; border: 0; color: var(--text); cursor: pointer;
}
.nav-placeholder { width: 40px; }

/* ---------- 头部 ---------- */
.hero { text-align: center; padding-top: 18px; }
.logo {
  width: 96px; height: 96px;
  object-fit: contain;
  filter: drop-shadow(0 8px 16px rgba(60, 170, 210, .18));
}
.heading {
  font-size: 30px;
  font-weight: 700;
  letter-spacing: 1px;
  margin-top: 14px;
  text-align: left;
}
.heading.center { text-align: center; }
.hero-sub {
  margin-top: 8px;
  font-size: 14px;
  color: var(--text-sub);
  text-align: left;
}
.invite-badge {
  margin: 14px auto 0;
  display: inline-flex;
  align-items: center;
  padding: 7px 16px;
  font-size: 13px;
  color: var(--primary-deep);
  background: var(--card);
  border: 1px dashed var(--primary);
  border-radius: 999px;
}
.invite-badge b { font-weight: 700; letter-spacing: 1px; }

/* ---------- 表单 ---------- */
#auth-form { margin-top: 10px; }

.field-label {
  display: block;
  margin: 20px 0 10px;
  font-size: 15px;
  font-weight: 600;
}

.input-pill {
  position: relative;
  display: flex;
  align-items: center;
  height: 54px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 27px;
  transition: border-color .15s;
}
.input-pill:focus-within { border-color: var(--primary); }

.input-pill input {
  flex: 1;
  height: 100%;
  padding: 0 20px;
  border: 0;
  outline: none;
  background: transparent;
  font-size: 16px;
  color: var(--text);
}
.input-pill input::placeholder { color: var(--placeholder); }

.btn-send {
  flex-shrink: 0;
  padding: 0 18px 0 8px;
  border: 0;
  background: none;
  font-size: 15px;
  font-weight: 600;
  color: var(--primary);
  cursor: pointer;
}
.btn-send:disabled { color: var(--placeholder); cursor: default; }

/* ---------- 主按钮 ---------- */
.btn-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 56px;
  margin-top: 40px;
  border: 0;
  border-radius: 28px;
  background: linear-gradient(90deg, var(--grad-from), var(--grad-to));
  color: #0f3b4d;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 2px;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 10px 22px rgba(52, 189, 226, .32);
  transition: transform .12s, box-shadow .12s, opacity .12s;
}
.btn-primary:active { transform: scale(.97); }
.btn-primary:disabled { opacity: .55; cursor: default; box-shadow: none; }

.switch-mode {
  margin-top: 22px;
  text-align: center;
  font-size: 14px;
  color: var(--text-sub);
}
.switch-mode a { color: var(--primary); text-decoration: none; font-weight: 600; }

.agreement {
  margin-top: 14px;
  text-align: center;
  font-size: 12px;
  color: var(--placeholder);
}

/* ---------- 成功视图 ---------- */
.success-wrap { text-align: center; padding-top: 12vh; }
.success-icon {
  width: 84px; height: 84px;
  margin: 0 auto;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--grad-from), var(--grad-to));
  box-shadow: 0 12px 26px rgba(52, 189, 226, .35);
}
.success-wrap .heading { margin-top: 26px; font-size: 28px; }
.success-desc { margin-top: 10px; font-size: 15px; color: var(--text-sub); }
.success-wrap .btn-primary { margin-top: 48px; }
.success-tip {
  margin-top: 16px;
  font-size: 13px;
  color: var(--text-sub);
  line-height: 1.7;
}

.bind-retry {
  margin-top: 26px;
  padding: 16px;
  background: #fff7f8;
  border: 1px solid #ffdbe0;
  border-radius: 16px;
  font-size: 13px;
  color: var(--danger);
}
.bind-retry p { margin-bottom: 12px; }
.btn-plain {
  padding: 9px 22px;
  border: 1px solid var(--danger);
  border-radius: 999px;
  background: #fff;
  color: var(--danger);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

/* ---------- Toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 15%;
  transform: translateX(-50%);
  max-width: 78%;
  padding: 11px 20px;
  background: rgba(28, 43, 51, .88);
  color: #fff;
  font-size: 14px;
  line-height: 1.5;
  border-radius: 12px;
  text-align: center;
  z-index: 99;
  animation: toast-in .18s ease-out;
}
@keyframes toast-in {
  from { opacity: 0; transform: translate(-50%, 8px); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}
