/* ============================================================
   签到助手 · 移动端 H5 样式
   ============================================================ */
:root {
  --blue: #2f6df6;
  --blue-700: #2559d8;
  --blue-50: #edf3fe;
  --blue-100: #dce8fd;
  --blue-200: #c9dcfb;
  --blue-lite: #5b8bf5;
  --blue-soft: rgba(47,109,246,.10);
  --blue-glow: rgba(47,109,246,.28);
  --hero-a: #ecf3ff;
  --hero-b: #dfe9fb;
  --green: #0fa97c;
  --green-50: #e2f6ef;
  --purple: #7b4df4;
  --purple-50: #f0e9ff;
  --orange: #f5a524;
  --orange-50: #fff3e0;
  --red: #f04a4a;
  --text: #18233f;
  --text-2: #6e7a90;
  --text-3: #9aa4b8;
  --line: #eef1f6;
  --line-2: #dfe4ec;
  --bg: #f3f5f9;
  --card: #ffffff;
  --shell: 480px;
  --radius: 20px;
}

/* ---------- 主题风格（默认风格切换） ---------- */
body[data-style="green"] {
  --blue: #0c8f68;
  --blue-700: #0a7a59;
  --blue-50: #e2f6ef;
  --blue-100: #c6ecdf;
  --blue-200: #a9e0cd;
  --blue-lite: #3cbb92;
  --blue-soft: rgba(12,143,104,.12);
  --blue-glow: rgba(12,143,104,.26);
  --hero-a: #e9f9f3;
  --hero-b: #d9f2e8;
}
body[data-style="purple"] {
  --blue: #7b4df4;
  --blue-700: #6438d6;
  --blue-50: #f0e9ff;
  --blue-100: #e2d6ff;
  --blue-200: #d2beff;
  --blue-lite: #a888ff;
  --blue-soft: rgba(123,77,244,.10);
  --blue-glow: rgba(123,77,244,.26);
  --hero-a: #f2ecff;
  --hero-b: #e7dcff;
}
body[data-style="orange"] {
  --blue: #d97706;
  --blue-700: #b45309;
  --blue-50: #fff3e0;
  --blue-100: #ffe6bd;
  --blue-200: #ffd894;
  --blue-lite: #f0a92e;
  --blue-soft: rgba(217,119,6,.12);
  --blue-glow: rgba(217,119,6,.26);
  --hero-a: #fff6e8;
  --hero-b: #ffeed2;
}

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

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Noto Sans SC", "Helvetica Neue", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; }

/* ---------- 布局壳 ---------- */
.shell {
  max-width: var(--shell);
  margin: 0 auto;
  min-height: 100vh;
  background: var(--bg);
  position: relative;
  overflow-x: hidden;
}

.page {
  padding: 14px 14px 96px;
  animation: fadeIn .22s ease both;
}
.page--flush { padding: 0 0 96px; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ---------- 首页顶部横幅 ---------- */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px 16px;
  border-radius: 24px;
  background: linear-gradient(135deg, var(--hero-a) 0%, var(--hero-b) 100%);
  border: 1.5px solid var(--blue-200);
  overflow: hidden;
  cursor: pointer;
}
.hero:active { transform: scale(.99); }
.hero::after {
  content: "";
  position: absolute;
  right: -40px; top: -60px;
  width: 180px; height: 180px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--blue-soft), transparent 70%);
}
.hero__icon {
  flex: none;
  width: 56px; height: 56px;
  border-radius: 16px;
  background: linear-gradient(140deg, var(--blue-lite), var(--blue));
  color: #fff;
  display: grid; place-items: center;
  box-shadow: 0 8px 18px var(--blue-glow);
}
.hero__body { flex: 1; min-width: 0; }
.hero__title { font-size: 22px; font-weight: 700; letter-spacing: .5px; }
.hero__sub { font-size: 13px; color: #6b7a92; margin-top: 6px; }
.hero__link {
  flex: none;
  display: flex; align-items: center; gap: 2px;
  color: var(--blue); font-weight: 600; font-size: 15px;
  background: none; border: 0; padding: 4px 0;
}

/* ---------- 卡片区块 ---------- */
.card {
  background: var(--card);
  border-radius: 22px;
  padding: 18px 16px;
  margin-top: 14px;
  box-shadow: 0 1px 2px rgba(16,24,40,.03), 0 10px 26px rgba(16,24,40,.045);
}
.card--dark {
  background: linear-gradient(140deg, #1d2c4d, #16233f);
  color: #fff;
  box-shadow: 0 12px 28px rgba(22,35,63,.22);
}
.sec-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px; gap: 12px;
}
.sec-title {
  display: flex; align-items: center; gap: 10px;
  font-size: 21px; font-weight: 700; letter-spacing: .3px;
}
.sec-title::before {
  content: ""; width: 4px; height: 22px; border-radius: 3px;
  background: var(--blue);
}
.sec-sub { font-size: 13px; color: var(--text-2); margin: -8px 0 16px; }
.sec-more {
  display: flex; align-items: center; gap: 2px;
  background: none; border: 0; padding: 0;
  color: var(--text-2); font-size: 14px;
}
.card--dark .sec-more { color: rgba(255,255,255,.72); }

/* ---------- 数据概览 ---------- */
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.stat {
  background: #fafbfd;
  border: 1px solid var(--line-2);
  border-radius: 16px;
  padding: 14px 10px;
  display: flex; align-items: center; gap: 10px;
}
.stat__body { flex: 1; min-width: 0; }
.stat__icon {
  flex: none;
  width: 46px; height: 46px; border-radius: 50%;
  display: grid; place-items: center;
}
.stat__icon--blue { background: var(--blue-50); color: var(--blue); }
.stat__icon--green { background: var(--green-50); color: var(--green); }
.stat__label { font-size: 13px; color: var(--text-2); white-space: nowrap; }
.stat__value { display: flex; align-items: baseline; gap: 5px; margin-top: 6px; }
.stat__num { font-size: 27px; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
/* 文字型数值（如「不限」）降一档字号，与单个数字视觉配平 */
.stat__num--word { font-size: 21px; }
.stat__num--blue { color: var(--blue); }
.stat__num--green { color: var(--green); }
.stat__unit { font-size: 14px; color: var(--text); font-weight: 600; }

/* ---------- 常用功能 ---------- */
.feat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.feat {
  background: #fafbfd;
  border: 1px solid var(--line-2);
  border-radius: 16px;
  padding: 18px 6px 16px;
  text-align: center;
  border-bottom: 0;
  transition: transform .15s ease, box-shadow .15s ease;
}
.feat:active { transform: scale(.97); }
.feat__icon {
  width: 48px; height: 48px; border-radius: 14px;
  display: grid; place-items: center;
  margin: 0 auto 12px;
  color: #fff;
}
.feat__icon--blue { background: linear-gradient(140deg, var(--blue-lite), var(--blue)); }
.feat__icon--green { background: linear-gradient(140deg, #63c6ac, var(--green)); }
.feat__icon--purple { background: linear-gradient(140deg, #9a6bff, var(--purple)); }
.feat__t { font-size: 15px; font-weight: 600; }
.feat__d { font-size: 12px; color: var(--text-3); margin-top: 6px; }

/* ---------- 四种签到模式 ---------- */
.modes { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.mode {
  border: 1.5px solid var(--line-2);
  border-radius: 16px;
  padding: 15px 13px 14px;
  position: relative;
  text-align: left;
  background: #fff;
  transition: transform .15s ease, box-shadow .15s ease;
}
.mode:active { transform: scale(.98); }
.mode__badge {
  display: inline-block;
  font-size: 12px; font-weight: 500;
  padding: 3px 10px; border-radius: 20px;
}
.mode__badge--blue { background: var(--blue-50); color: var(--blue); }
.mode__badge--green { background: var(--green-50); color: var(--green); }
.mode__badge--purple { background: var(--purple-50); color: var(--purple); }
.mode__badge--orange { background: var(--orange-50); color: #d98416; }
.mode__num {
  position: absolute; right: 13px; top: 13px;
  color: var(--text-3); font-weight: 700; font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.mode__t { font-size: 16.5px; font-weight: 700; margin: 12px 0 8px; line-height: 1.35; }
.mode__d { font-size: 12.5px; color: var(--text-2); line-height: 1.6; min-height: 40px; }
.mode__link {
  display: flex; align-items: center; gap: 4px;
  font-size: 13px; color: var(--text-2); margin-top: 12px;
}
.mode--blue { background: #f7faff; border-color: #d6e5fd; }
.mode--green { background: #f6fcf9; border-color: #cdeade; }
.mode--purple { background: #faf8ff; border-color: #e2d8fd; }
.mode--orange { background: #fffbf3; border-color: #f7e2c2; }

/* ---------- 最近签到（深色卡片） ---------- */
.recent { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid rgba(255,255,255,.10); }
.recent:last-child { border-bottom: 0; padding-bottom: 0; }
.recent__body { flex: 1; min-width: 0; }
.recent__t { font-size: 15.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.recent__d { font-size: 12px; color: rgba(255,255,255,.55); margin-top: 4px; }
.recent__n { font-size: 20px; font-weight: 700; color: #6ee7c0; font-variant-numeric: tabular-nums; }

/* ---------- 顶部导航 ---------- */
.navbar {
  position: sticky; top: 0; z-index: 30;
  height: 52px;
  background: rgba(255,255,255,.94);
  backdrop-filter: saturate(1.6) blur(8px);
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
}
.navbar__title { font-size: 17px; font-weight: 600; }
.navbar__back {
  position: absolute; left: 10px; top: 0;
  width: 40px; height: 52px;
  display: grid; place-items: center;
  background: none; border: 0; color: var(--text);
}
.capsule {
  position: absolute; right: 12px; top: 11px;
  display: flex; align-items: center;
  height: 30px; border-radius: 16px;
  border: 1px solid #e2e7ef;
  overflow: hidden;
  background: rgba(255,255,255,.9);
}
.capsule i {
  width: 38px; height: 100%;
  display: grid; place-items: center;
  color: #3b4252; font-style: normal;
}
.capsule i + i { border-left: 1px solid #e8ecf2; }
.capsule .dots { letter-spacing: 1px; font-weight: 700; font-size: 13px; }

/* ---------- 表单 ---------- */
.form-group { margin-top: 16px; }
.group-title {
  display: flex; align-items: center; gap: 10px;
  font-size: 18px; font-weight: 700;
  margin: 0 2px 10px;
}
.group-title::before {
  content: ""; width: 4px; height: 18px; border-radius: 3px; background: var(--blue);
}
.form-card {
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(16,24,40,.03), 0 8px 22px rgba(16,24,40,.04);
}
.field { padding: 15px 16px; border-bottom: 1px solid var(--line); }
.field:last-child { border-bottom: 0; }
.field__label {
  font-size: 15px; color: var(--text);
  margin-bottom: 12px;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
}
.field__label .req { color: var(--red); margin-right: 4px; }
.field__hint { font-size: 12.5px; color: var(--text-3); margin-top: 10px; }

.text-input {
  width: 100%;
  border: 0; outline: 0;
  font-size: 15px; color: var(--text);
  background: transparent;
  padding: 2px 0;
}
.text-input::placeholder { color: #b6bfcf; }
.text-input--right { text-align: right; }
.field--inline {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 15px 16px; border-bottom: 1px solid var(--line);
}
.field--inline:last-child { border-bottom: 0; }
.field--inline .text-input { text-align: right; flex: 1; }

.link-more {
  background: none; border: 0; padding: 0;
  color: var(--blue); font-size: 14px;
  display: inline-flex; align-items: center; gap: 2px;
  white-space: nowrap;
}

/* 选项卡片 */
.opt-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.opt {
  border: 1.5px solid var(--line-2);
  border-radius: 14px;
  padding: 14px 12px;
  position: relative;
  text-align: left;
  background: #fff;
  transition: border-color .15s ease, background .15s ease;
}
.opt.is-on { border-color: var(--blue); background: #f5f9ff; }
.opt__t { font-size: 15px; font-weight: 600; padding-right: 24px; line-height: 1.35; }
.opt__d { font-size: 12px; color: var(--text-2); margin-top: 8px; line-height: 1.55; }
.opt__radio {
  position: absolute; right: 10px; top: 12px;
  width: 18px; height: 18px; border-radius: 50%;
  border: 1.5px solid #c9d1de;
  background: #fff;
}
.opt.is-on .opt__radio { border-color: var(--blue); background: var(--blue); }
.opt.is-on .opt__radio::after {
  content: ""; position: absolute; left: 4.5px; top: 4.5px;
  width: 6px; height: 6px; border-radius: 50%; background: #fff;
}

/* 复选 */
.chk-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px 6px; }
.chk {
  display: flex; align-items: center; gap: 8px;
  font-size: 14.5px; background: none; border: 0; padding: 2px 0; text-align: left;
}
.chk__box {
  flex: none; width: 18px; height: 18px; border-radius: 5px;
  border: 1.5px solid #c9d1de; background: #fff;
  display: grid; place-items: center; color: #fff;
}
.chk.is-on .chk__box { background: var(--blue); border-color: var(--blue); }
.chk.is-on { color: var(--text); font-weight: 500; }

.btn-outline {
  margin-top: 14px;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 1px solid var(--blue);
  background: #fff; color: var(--blue);
  font-size: 14.5px; font-weight: 500;
  padding: 8px 14px; border-radius: 9px;
}
.btn-outline:active { background: var(--blue-50); }

/* 设置行 */
.row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 16px; border-bottom: 1px solid var(--line);
  background: none; border-left: 0; border-right: 0; border-top: 0;
  width: 100%;
}
.row:last-child { border-bottom: 0; }
.row__l { min-width: 0; }
.row__t { font-size: 15px; }
.row__d { font-size: 12px; color: var(--text-3); margin-top: 4px; line-height: 1.5; }
.row__v { display: flex; align-items: center; gap: 4px; color: var(--text-2); font-size: 14px; white-space: nowrap; }
.row--muted .row__t, .row--muted .row__v { color: #c2c9d6; }
.row--muted .row__d { color: #cbd2de; }

/* ---------- 卡片式设置项（常用设置 / 更多操作） ---------- */
.sec-head--out { margin: 22px 2px 0; }
.sec-head--out .sec-title { font-size: 18px; }
.sec-head--out .sec-title::before { height: 18px; }
.opt-card {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  width: 100%; text-align: left;
  background: #fff; border: 1px solid var(--line-2); border-radius: 16px;
  padding: 14px 15px; margin-top: 10px;
  box-shadow: 0 1px 2px rgba(16,24,40,.03), 0 8px 22px rgba(16,24,40,.04);
}
.opt-card:active { transform: translateY(1px); }
.opt-card__l { flex: 1; min-width: 0; }
.opt-card__t { display: block; font-size: 15.5px; font-weight: 600; color: var(--text); }
.opt-card__d { display: block; font-size: 12.5px; color: var(--text-3); margin-top: 4px; line-height: 1.55; }
.opt-card__v {
  display: flex; align-items: center; gap: 4px; flex: none;
  color: var(--text-2); font-size: 13.5px; white-space: nowrap;
}
.opt-card__v svg { width: 15px; height: 15px; color: #c2c9d6; }
.opt-card--danger { background: #fff7f7; border-color: rgba(240,74,74,.2); }
.opt-card--danger .opt-card__t, .opt-card--danger .opt-card__v { color: var(--red); }
.opt-card--danger .opt-card__v svg { color: var(--red); }

/* ---------- 卡片式操作按钮（导出等） ---------- */
.sec-more--card {
  background: var(--blue-50); color: var(--blue);
  border: 1px solid rgba(37,99,235,.18);
  border-radius: 10px; padding: 7px 13px;
  font-size: 13.5px; font-weight: 600;
  box-shadow: 0 2px 8px rgba(37,99,235,.08);
}
.sec-more--card:active { background: var(--blue-100, #d6e5fd); }
.sec-more--card svg { width: 15px; height: 15px; }

/* 开关 */
.switch {
  flex: none; width: 46px; height: 27px; border-radius: 14px;
  background: #dfe4ec; position: relative; transition: background .2s ease;
  border: 0; padding: 0;
}
.switch.is-on { background: var(--blue); }
.switch::after {
  content: ""; position: absolute; top: 2.5px; left: 2.5px;
  width: 22px; height: 22px; border-radius: 50%; background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,.22);
  transition: left .2s ease;
}
.switch.is-on::after { left: 21.5px; }

/* ---------- 底部操作条 ---------- */
.bottom-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  max-width: var(--shell); margin: 0 auto;
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(8px);
  border-top: 1px solid var(--line);
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
}
.btn-primary {
  width: 100%; height: 48px;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; border-radius: 12px;
  background: linear-gradient(120deg, var(--blue-lite), var(--blue));
  color: #fff; font-size: 17px; font-weight: 600;
  box-shadow: 0 8px 20px var(--blue-glow);
}
.btn-primary:active { transform: translateY(1px); }
.btn-primary[disabled] { opacity: .5; box-shadow: none; }
.btn-ghost {
  height: 44px; border-radius: 12px; border: 1px solid var(--line-2);
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  background: #fff; color: var(--text-2); font-size: 15px; padding: 0 18px;
}
.btn-block { width: 100%; }
.btn-sm {
  height: 34px; font-size: 13.5px; border-radius: 8px; padding: 0 14px;
  border: 1px solid var(--line-2); background: #fff; color: var(--text-2);
  display: inline-flex; align-items: center; justify-content: center; gap: 5px;
}

/* ---------- 列表 / 空态 ---------- */
.list-card { background: #fff; border-radius: 16px; overflow: hidden; box-shadow: 0 1px 2px rgba(16,24,40,.03), 0 8px 22px rgba(16,24,40,.04); }
.item {
  display: flex; align-items: center; gap: 12px;
  padding: 15px 16px; border-bottom: 1px solid var(--line);
  background: none; border-left: 0; border-right: 0; border-top: 0;
  width: 100%; text-align: left;
}
.item:last-child { border-bottom: 0; }
.item__badge {
  flex: none; width: 44px; height: 44px; border-radius: 12px;
  display: grid; place-items: center; font-size: 12px; font-weight: 700;
}
.item__body { flex: 1; min-width: 0; }
.item__t { font-size: 15.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item__d { font-size: 12px; color: var(--text-3); margin-top: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item__meta { font-size: 12.5px; color: var(--text-2); margin-top: 4px; line-height: 1.55; word-break: break-all; }
.empty { text-align: center; padding: 60px 20px; color: var(--text-3); }
.empty svg { margin-bottom: 12px; opacity: .55; display: block; margin-left: auto; margin-right: auto; }
.empty__t { font-size: 15px; }
.empty__d { font-size: 13px; margin-top: 6px; }

/* ---------- 签到执行页 ---------- */
.sign-head {
  background: linear-gradient(140deg, var(--blue), var(--blue-lite));
  color: #fff;
  padding: 26px 20px 30px;
  text-align: center;
}
.sign-head__t { font-size: 21px; font-weight: 700; }
.sign-head__d { font-size: 13px; opacity: .85; margin-top: 8px; }
.sign-form { margin-top: -14px; }
.sign-field { padding: 14px 16px; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 12px; }
.sign-field__l { width: 84px; flex: none; font-size: 14.5px; color: var(--text-2); }
.sign-field__l .req { color: var(--red); margin-right: 3px; }
.sign-field input, .sign-field select {
  flex: 1; min-width: 0;
  border: 0; outline: 0; background: transparent;
  font-size: 15px; color: var(--text);
}
.sign-field input::placeholder { color: #b6bfcf; }
.sign-pad {
  margin: 14px; background: #fff; border-radius: 16px; padding: 14px;
  box-shadow: 0 1px 2px rgba(16,24,40,.03), 0 8px 22px rgba(16,24,40,.04);
}
.sign-pad canvas { width: 100%; height: 170px; border: 1px dashed #d8dee8; border-radius: 10px; touch-action: none; background: #fcfdff; }
.sign-pad__ops { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; font-size: 13px; color: var(--text-2); }

/* ---------- 弹层 ---------- */
.mask {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(17,24,39,.42);
  display: flex; align-items: flex-end; justify-content: center;
  animation: fadeIn .18s ease both;
}
.sheet {
  width: 100%; max-width: var(--shell);
  background: #fff;
  border-radius: 20px 20px 0 0;
  padding: 8px 16px calc(18px + env(safe-area-inset-bottom));
  animation: slideUp .24s cubic-bezier(.22,.9,.3,1) both;
  max-height: 84vh; overflow: auto;
}
@keyframes slideUp { from { transform: translateY(100%); } to { transform: none; } }
.sheet__grip { width: 36px; height: 4px; border-radius: 2px; background: #dfe3ea; margin: 6px auto 12px; }
.sheet__t { font-size: 17px; font-weight: 700; margin-bottom: 4px; }
.sheet__d { font-size: 13px; color: var(--text-2); margin-bottom: 14px; }
.sheet__ops {
  display: flex; gap: 10px; margin-top: 18px;
  position: sticky; bottom: 0;
  background: #fff;
  padding: 12px 0 2px;
  box-shadow: 0 -8px 12px rgba(255,255,255,.9);
}
.sheet__ops > * { flex: 1; }

.fieldset { border: 1px solid var(--line-2); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; }
.fieldset__t { font-size: 14.5px; font-weight: 600; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.fieldset__d { font-size: 12.5px; color: var(--text-3); margin-top: 6px; }
.drag-handle { color: #c2c9d6; cursor: grab; }

/* ---------- Toast ---------- */
#toast {
  position: fixed; left: 50%; bottom: 110px; z-index: 90;
  transform: translate(-50%, 12px);
  background: rgba(24,35,63,.92);
  color: #fff; font-size: 14px;
  padding: 10px 18px; border-radius: 10px;
  opacity: 0; pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
  max-width: 80vw; text-align: center;
}
#toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- 结果页 ---------- */
.result { text-align: center; padding: 40px 20px 24px; }
.result__icon {
  width: 76px; height: 76px; border-radius: 50%;
  background: var(--green-50); color: var(--green);
  display: grid; place-items: center; margin: 0 auto 18px;
}
.result__t { font-size: 21px; font-weight: 700; }
.result__d { font-size: 14px; color: var(--text-2); margin-top: 10px; line-height: 1.7; }
.result__info { margin-top: 18px; background: #fff; border-radius: 14px; padding: 14px 16px; text-align: left; box-shadow: 0 1px 2px rgba(16,24,40,.03), 0 8px 22px rgba(16,24,40,.04); }
.result__row { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; font-size: 14px; }
.result__row span:first-child { color: var(--text-3); flex: none; }
.result__row span:last-child { text-align: right; word-break: break-all; }

/* ---------- 工具 ---------- */
.stack { display: flex; flex-direction: column; gap: 10px; }
.between { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.mt8 { margin-top: 8px; } .mt12 { margin-top: 12px; } .mt16 { margin-top: 16px; } .mt20 { margin-top: 20px; }
.muted { color: var(--text-2); } .muted-sm { color: var(--text-3); font-size: 13px; }
.center { text-align: center; }
.fab {
  position: fixed; right: max(16px, calc(50% - var(--shell) / 2 + 16px)); bottom: 26px; z-index: 25;
  height: 48px; padding: 0 20px; border: 0; border-radius: 24px;
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  background: linear-gradient(120deg, var(--blue-lite), var(--blue)); color: #fff;
  font-size: 15px; font-weight: 600; box-shadow: 0 10px 24px var(--blue-glow);
}
.help-h { font-size: 16px; font-weight: 700; margin: 22px 2px 10px; }
.help-p { font-size: 14px; color: var(--text-2); line-height: 1.85; margin: 0 2px; }
.help-li { font-size: 14px; color: var(--text-2); line-height: 1.9; margin: 0 2px; padding-left: 4px; }

/* ---------- 图标尺寸 ---------- */
.hero__link svg, .mode__link svg, .row__v svg, .sec-more svg, .link-more svg { width: 16px; height: 16px; }
.row__v svg { width: 14px; height: 14px; color: #c2c9d6; }
.sec-more svg { width: 14px; height: 14px; }
.stat__icon svg { width: 28px; height: 28px; }
.feat__icon svg { width: 24px; height: 24px; }
.chk__box svg { width: 12px; height: 12px; stroke-width: 3.2; }
.btn-outline svg { width: 16px; height: 16px; flex: none; }
.btn-primary svg { width: 19px; height: 19px; flex: none; }
.btn-ghost svg { width: 17px; height: 17px; flex: none; }
.fab svg { width: 18px; height: 18px; flex: none; }
.empty svg { width: 44px; height: 44px; }
.item > svg { width: 18px; height: 18px; color: #c2c9d6; flex: none; }
.result__icon svg { width: 40px; height: 40px; stroke-width: 2.4; }
.btn-sm svg { width: 15px; height: 15px; }
.recent > svg { width: 16px; height: 16px; color: rgba(255,255,255,.45); flex: none; }
.item__badge svg { width: 18px; height: 18px; }
.switch svg { display: none; }

/* ---------- 状态机 ---------- */
.status-badge {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 20px;
  white-space: nowrap;
}
.status-badge--muted { background: #eef1f6; color: #8b95a8; }
.status-badge--green { background: var(--green-50); color: var(--green); }
.status-badge--orange { background: var(--orange-50); color: #d98416; }
.status-badge--blue { background: var(--blue-50); color: var(--blue); }
.status-badge--red { background: #fdeaea; color: var(--red); }

.status-hero { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 12px; }
.sign-notice {
  margin: 14px 14px 0; padding: 13px 15px; border-radius: 14px;
  background: #fff8e8; border: 1px solid #f3e0b6; color: #8a6416;
  font-size: 14px; line-height: 1.7;
}
.sign-notice--red { background: #fdeeee; border-color: #f6cdcd; color: #b3413f; }
.sign-notice--grey { background: #f6f8fb; border-color: var(--line-2); color: var(--text-2); }

/* ---------- 签到时段 ---------- */
.session {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 12px; border: 1px solid var(--line-2); border-radius: 12px;
  margin-bottom: 8px; background: #fafbfd;
}
.session__main { flex: 1; min-width: 0; }
.session__t { font-size: 14.5px; font-weight: 600; }
.session__d { font-size: 12px; color: var(--text-3); margin-top: 3px; }

/* ---------- 记录筛选 ---------- */
.tabs { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 12px; }
.tabs::-webkit-scrollbar { display: none; }
.tabs__item {
  flex: none; height: 32px; padding: 0 12px; border-radius: 16px;
  border: 1px solid var(--line-2); background: #fff; color: var(--text-2);
  font-size: 13px; white-space: nowrap;
}
.tabs__item.is-on { border-color: var(--blue); background: var(--blue-50); color: var(--blue); font-weight: 600; }

.rec-tag {
  display: inline-block; font-size: 11px; font-weight: 600;
  padding: 2px 8px; border-radius: 20px; margin-right: 6px; vertical-align: 1px;
}
.rec-tag--normal { background: var(--green-50); color: var(--green); }
.rec-tag--late { background: var(--orange-50); color: #d98416; }
.rec-tag--void { background: #eef1f6; color: #98a1b2; text-decoration: line-through; }
.rec-tag--out { background: #fff3e0; color: #d98416; }
.rec-ops { display: flex; gap: 8px; flex: none; align-items: center; }

/* ---------- 成功页模块 ---------- */
.mod {
  background: #fff; border-radius: 16px; padding: 16px;
  margin-top: 12px; text-align: left;
  box-shadow: 0 1px 2px rgba(16,24,40,.03), 0 8px 22px rgba(16,24,40,.04);
}
.mod__t { font-size: 15.5px; font-weight: 700; margin-bottom: 8px; }
.mod__x { font-size: 14px; color: var(--text-2); line-height: 1.85; word-break: break-word; }
.mod__img { display: block; width: 100%; border-radius: 10px; margin-bottom: 6px; }
.timeline { border-left: 2px solid var(--blue-100); margin-left: 4px; padding-left: 14px; }
.timeline__item { display: flex; gap: 12px; padding: 6px 0; }
.timeline__time { flex: none; width: 46px; font-size: 13px; font-weight: 700; color: var(--blue); font-variant-numeric: tabular-nums; }
.timeline__label { flex: 1; font-size: 14px; color: var(--text-2); line-height: 1.6; }

.mod-item {
  display: flex; align-items: center; gap: 10px;
  border: 1px solid var(--line-2); border-radius: 12px; padding: 11px 12px; margin-bottom: 8px;
}
.mod-item__main { flex: 1; min-width: 0; }
.mod-item__t { font-size: 14.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mod-item__d { font-size: 12px; color: var(--text-3); margin-top: 3px; }
.mod-add { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 6px; }
.mod-add button {
  border: 1px dashed var(--line-2); border-radius: 12px; background: #fafbfd;
  padding: 12px 6px; color: var(--text-2); font-size: 13px;
}
.mod-add button:active { background: var(--blue-50); border-color: var(--blue); color: var(--blue); }
.tl-row { display: flex; gap: 8px; align-items: center; margin-bottom: 8px; }
.tl-row input { flex: 1; min-width: 0; }
.tl-row__time { flex: none !important; width: 92px; }

/* ---------- 入口条（位置签到设置等） ---------- */
.entry {
  display: flex; align-items: center; gap: 12px;
  width: 100%; text-align: left;
  background: #fff; border: 1px solid var(--line-2); border-radius: 14px;
  padding: 12px 14px; margin-top: 10px;
}
.entry__icon {
  flex: none; width: 38px; height: 38px; border-radius: 11px;
  display: grid; place-items: center; color: #fff;
}
.entry__icon--blue { background: linear-gradient(140deg, var(--blue-lite), var(--blue)); }
.entry__main { flex: 1; min-width: 0; }
.entry__t { display: block; font-size: 15px; font-weight: 600; }
.entry__d { display: block; font-size: 12px; color: var(--text-3); margin-top: 3px; }
.entry svg { width: 19px; height: 19px; }
.entry .row__v svg { width: 16px; height: 16px; }

.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; vertical-align: 1px; }

/* ---------- 选项胶囊 ---------- */
.chip-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--line-2); background: #fff; color: var(--text-2);
  border-radius: 18px; padding: 7px 14px; font-size: 13.5px;
}
.chip.is-on { border-color: var(--blue); background: var(--blue-50); color: var(--blue); font-weight: 600; }

/* ---------- 地图选点 ---------- */
.map-box {
  height: 260px; border-radius: 14px; overflow: hidden;
  border: 1px solid var(--line-2); background: #f6f8fb; margin-top: 4px;
}
.map-loading {
  display: grid; place-items: center; height: 100%;
  color: var(--text-3); font-size: 13.5px; padding: 20px; text-align: center;
}
.map-coord { margin-top: 10px; font-size: 13px; color: var(--text-2); }
.map-coord b { color: var(--text); font-variant-numeric: tabular-nums; }

/* ---------- 签到页封面 ---------- */
.sign-cover { width: 100%; height: 168px; overflow: hidden; background: #eef1f6; }
.sign-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------- 位置签到 ---------- */
.geo-box {
  padding: 13px 14px; margin: 0 0 12px;
  background: #fff; border-radius: 14px;
  border: 1px solid var(--line-2);
  box-shadow: 0 1px 2px rgba(16,24,40,.03), 0 8px 22px rgba(16,24,40,.04);
}
.geo-box__head { display: flex; align-items: center; gap: 10px; }
.geo-box__icon {
  flex: none; width: 32px; height: 32px; border-radius: 10px;
  display: grid; place-items: center; color: var(--blue); background: var(--blue-50);
}
.geo-box__icon svg { width: 18px; height: 18px; }
.geo-box__main { flex: 1; min-width: 0; }
.geo-box__t { display: block; font-size: 14.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.geo-box__d { display: block; font-size: 12px; color: var(--text-3); margin-top: 3px; }
.geo-box__status { margin-top: 10px; font-size: 12.5px; line-height: 1.6; color: var(--text-2); }
.geo-box__status.is-ok { color: var(--green); }
.geo-box__status.is-far { color: #d97706; }
.geo-box__ops { margin-top: 10px; display: flex; gap: 8px; }

/* ---------- 分享图预览 ---------- */
.share-preview { margin-top: 12px; }
.share-preview img { display: block; width: 100%; border-radius: 12px; }

/* ---------- 风格选择 ---------- */
.style-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.style-item {
  position: relative; text-align: left;
  border: 1.5px solid var(--line-2); border-radius: 14px; background: #fff;
  padding: 10px 12px 12px;
}
.style-item.is-on { border-color: var(--blue); background: var(--blue-50); }
.style-item__bar { display: block; height: 34px; border-radius: 9px; margin-bottom: 8px; }
.style-item__n { font-size: 14px; font-weight: 600; }
.style-item__ck { position: absolute; right: 10px; top: 10px; color: var(--blue); }
.style-item__ck svg { width: 18px; height: 18px; stroke-width: 2.4; }

/* ---------- 位置异常标签 ---------- */
.rec-tag--geo { background: #fdeaea; color: #c9413f; }

/* ---------- 底部导航（4 个模块） ---------- */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  max-width: var(--shell); margin: 0 auto;
  display: flex; align-items: stretch;
  height: calc(58px + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(8px);
  border-top: 1px solid var(--line);
}
.tabbar__item {
  flex: 1; min-width: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  background: none; border: 0; padding: 6px 0 4px;
  color: var(--text-3);
}
.tabbar__item.is-on { color: var(--blue); }
.tabbar__icon { display: grid; place-items: center; height: 24px; }
.tabbar__icon svg { width: 22px; height: 22px; }
.tabbar__item.is-on .tabbar__icon svg { stroke-width: 2.1; }
.tabbar__label { font-size: 11px; font-weight: 500; letter-spacing: .2px; }
.tabbar__item.is-on .tabbar__label { font-weight: 600; }
.fab--tab { bottom: calc(72px + env(safe-area-inset-bottom)); }

/* ---------- 我的 ---------- */
.profile { display: flex; align-items: center; gap: 13px; }
.profile__main { flex: 1; min-width: 0; }
.profile__name { font-size: 18px; font-weight: 700; }
.profile__sub { font-size: 13px; color: var(--text-2); margin-top: 5px; }
.profile__bio {
  margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line);
  font-size: 13.5px; color: var(--text-2); line-height: 1.7; white-space: pre-wrap;
}
.avatar {
  flex: none; width: 48px; height: 48px; border-radius: 15px;
  display: grid; place-items: center;
  font-size: 19px; font-weight: 700; color: #fff;
}
.avatar--blue { background: linear-gradient(140deg, var(--blue-lite), var(--blue)); }
.avatar--green { background: linear-gradient(140deg, #4fc9a5, #0c8f68); }
.avatar--purple { background: linear-gradient(140deg, #a888ff, #7b4df4); }
.avatar--orange { background: linear-gradient(140deg, #f0a92e, #d97706); }

.admin-list { display: flex; flex-direction: column; gap: 8px; }
.admin-row {
  display: flex; align-items: center; gap: 11px;
  border: 1px solid var(--line-2); border-radius: 13px; padding: 10px 12px;
  background: #fafbfd; text-align: left; width: 100%;
}
.admin-row .avatar { width: 36px; height: 36px; border-radius: 11px; font-size: 15px; }
.admin-row__main { flex: 1; min-width: 0; }
.admin-row__t { display: block; font-size: 14.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.admin-row__d { display: block; font-size: 12px; color: var(--text-3); margin-top: 3px; }
.admin-row .btn-sm { flex: none; }

.invite-link {
  background: #f6f8fb; border: 1px solid var(--line-2); border-radius: 10px;
  padding: 10px 12px; font-size: 12.5px; color: var(--text-2);
  word-break: break-all; line-height: 1.6;
}

/* 首页常用功能 2×2 */
.feat-grid--2 { grid-template-columns: repeat(2, 1fr); gap: 12px; }
.feat-grid--2 .feat { padding: 20px 8px 18px; }
.feat-grid--2 .feat__icon { width: 52px; height: 52px; border-radius: 15px; margin-bottom: 10px; }
.feat-grid--2 .feat__icon svg { width: 26px; height: 26px; }
.feat-grid--2 .feat__t { font-size: 15.5px; }
.feat__icon--orange { background: linear-gradient(140deg, #f0a92e, #d97706); }
