/* ============================================================
   资料参考中心
   配色集中在 :root，想整体换色改这一段即可
   ============================================================ */

:root {
  --bg: #f5f1e8;
  --ink: #1b2230;
  --muted: #7a7468;
  --faint: #a5a094;
  --line: #e6dfd1;
  --card: #ffffff;

  --navy: #0f223f;
  --blue: #16305c;
  --royal: #2a4b8d;
  --gold: #b8892b;
  --gold-soft: #efe2c2;

  --sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  --mono: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  /* 数字专用：无斜杠 0，且等宽对齐 */
  --digit: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial,
    "PingFang SC", "Microsoft YaHei", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(180deg, #f8f4ec 0%, #f2ecdf 48%, #ede5d4 100%);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  position: relative;
}

/* 背景柔光 */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(680px 320px at 50% -80px, rgba(42, 75, 141, 0.14), transparent 70%),
    radial-gradient(520px 280px at 92% 6%, rgba(184, 137, 43, 0.1), transparent 72%),
    radial-gradient(520px 340px at 4% 34%, rgba(43, 127, 116, 0.07), transparent 72%);
}

::selection {
  background: rgba(184, 137, 43, 0.22);
}

a {
  color: var(--royal);
}

/* ============================================================
   首页
   ============================================================ */

.page {
  max-width: 820px;
  margin: 0 auto;
  padding: 44px 20px 56px;
}

.banner {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  padding: 38px 26px 34px;
  text-align: center;
  color: #fff;
  background: linear-gradient(118deg, var(--navy) 0%, var(--blue) 46%, var(--royal) 100%);
  box-shadow:
    0 30px 60px -34px rgba(15, 34, 63, 0.8),
    0 1px 0 rgba(214, 178, 104, 0.5) inset;
}

.banner::before {
  content: "";
  position: absolute;
  inset: -60% -28% auto auto;
  width: 78%;
  height: 200%;
  background: radial-gradient(closest-side, rgba(255, 236, 200, 0.24), transparent 70%);
  filter: blur(10px);
  pointer-events: none;
}

.banner::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.45;
  background-image: radial-gradient(rgba(255, 255, 255, 0.2) 1px, transparent 1px);
  background-size: 18px 18px;
  -webkit-mask-image: radial-gradient(120% 90% at 50% 0%, #000 8%, transparent 76%);
  mask-image: radial-gradient(120% 90% at 50% 0%, #000 8%, transparent 76%);
}

.banner h1 {
  position: relative;
  margin: 0 0 10px;
  font-size: 30px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-indent: 0.09em;
  text-shadow: 0 2px 18px rgba(6, 14, 32, 0.4);
}

.banner .sub {
  position: relative;
  margin: 0;
  font-size: 13px;
  letter-spacing: 0.14em;
  color: rgba(255, 255, 255, 0.72);
}

.banner-tag {
  position: absolute;
  top: 13px;
  right: 13px;
  z-index: 1;
  padding: 3px 10px;
  border-radius: 99px;
  border: 1px solid rgba(214, 178, 104, 0.45);
  background: rgba(214, 178, 104, 0.18);
  color: #f0dfb6;
  font-size: 11px;
  letter-spacing: 0.04em;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 16px;
}

.card {
  --c: #3c5c8f;
  --bgc: #eaeef6;
  --bord: #c6d2e6;
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 17px 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--card);
  text-decoration: none;
  color: inherit;
  box-shadow: 0 1px 2px rgba(27, 34, 48, 0.04);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
  animation: cardIn 0.4s ease both;
}

.card:nth-child(1) { animation-delay: 0.02s; }
.card:nth-child(2) { animation-delay: 0.06s; }
.card:nth-child(3) { animation-delay: 0.1s; }
.card:nth-child(4) { animation-delay: 0.14s; }
.card:nth-child(5) { animation-delay: 0.18s; }
.card:nth-child(6) { animation-delay: 0.22s; }

@keyframes cardIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.card:hover {
  transform: translateY(-2px);
  border-color: var(--bord);
  box-shadow: 0 18px 34px -22px rgba(27, 34, 48, 0.42);
}

.card:focus-visible {
  outline: 2px solid var(--c);
  outline-offset: 3px;
}

.ico {
  flex: none;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--bgc);
  color: var(--c);
}

.ico svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.txt {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.t {
  font-size: 15.5px;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: 0.01em;
}

.d {
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.5;
}

.chev {
  flex: none;
  margin-left: auto;
  color: #ccc5b6;
  font-size: 20px;
  line-height: 1;
  transition: transform 0.18s ease, color 0.18s ease;
}

.card:hover .chev {
  transform: translateX(2px);
  color: var(--c);
}

/* 六种配色 */
.c-slate  { --c: #3c5c8f; --bgc: #eaeef6; --bord: #c6d2e6; }
.c-gold   { --c: #b8892b; --bgc: #f7efdd; --bord: #e8d3a4; }
.c-plum   { --c: #7d4a8f; --bgc: #f3e9f5; --bord: #dcc4e3; }
.c-teal   { --c: #2b7f74; --bgc: #e5f1ee; --bord: #b3d9d2; }
.c-clay   { --c: #c05a3e; --bgc: #fbeae2; --bord: #efc3b3; }
.c-indigo { --c: #4a4fa8; --bgc: #eceaf9; --bord: #cbc7ee; }

.foot {
  margin-top: 30px;
  text-align: center;
  font-size: 12px;
  color: var(--muted);
}

.foot p {
  margin: 0 0 4px;
}

.foot .copy {
  font-size: 11px;
  color: var(--faint);
  letter-spacing: 0.02em;
}

/* ============================================================
   内页通用
   ============================================================ */

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px max(18px, calc(50% - 410px));
  border-bottom: 1px solid var(--line);
  background: rgba(245, 241, 232, 0.86);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.back {
  flex: none;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  font-size: 16px;
  line-height: 1;
  transition: 0.16s ease;
}

.back:hover {
  border-color: #d5cbb4;
  background: #fdfbf6;
}

.topbar h1 {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.pill {
  margin-left: auto;
  flex: none;
  padding: 3px 10px;
  border-radius: 99px;
  border: 1px solid var(--gold-soft);
  background: #fdf6e6;
  color: var(--gold);
  font-size: 11.5px;
  letter-spacing: 0.02em;
}

.wrap {
  max-width: 820px;
  margin: 0 auto;
  padding: 18px 20px 64px;
}

/* 期号切换 */
.period-card {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(120deg, #ffffff, #fdfaf3);
  box-shadow: 0 14px 30px -26px rgba(27, 34, 48, 0.5);
}

.pnav {
  flex: none;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  font-size: 19px;
  line-height: 1;
  cursor: pointer;
  transition: 0.16s ease;
}

.pnav:hover:not(:disabled) {
  border-color: var(--gold-soft);
  background: #fdf7e8;
  color: var(--gold);
}

.pnav:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.period-body {
  flex: 1;
  text-align: center;
  min-width: 0;
}

.issue {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.issue b {
  color: var(--gold);
  font-size: 22px;
  font-weight: 800;
  margin: 0 2px;
}

.pdate {
  margin-top: 2px;
  font-size: 12.5px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

/* 内容块 */
.block {
  margin-top: 16px;
  padding: 18px 18px 20px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--card);
}

.block-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 14px;
}

.block-head h2 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.block-head h2::before {
  content: "";
  display: inline-block;
  width: 3px;
  height: 13px;
  margin-right: 8px;
  border-radius: 2px;
  background: var(--gold);
  vertical-align: -1px;
}

.block-head .hint {
  font-size: 11.5px;
  color: var(--faint);
}

/* 生肖 */
.zodiac-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.z-card {
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fdfbf6;
}

.z-tag {
  display: inline-block;
  margin-bottom: 9px;
  padding: 1px 8px;
  border-radius: 6px;
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--gold);
  background: #fbf3e0;
  border: 1px solid var(--gold-soft);
}

.z-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.z-item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  padding: 3px 8px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: #fff;
  font-size: 13px;
  color: #4b4438;
}

.z-item.single {
  min-width: 54px;
  padding: 6px 14px;
  font-size: 17px;
  font-weight: 600;
  color: var(--ink);
  border-color: var(--gold-soft);
  background: #fdf7e8;
}

/* 号码 */
.number-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.n-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 10px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fdfbf6;
}

.n-label {
  font-size: 11.5px;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.n-value {
  font-family: var(--mono);
  font-size: 26px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.1;
}

.n-value.hot {
  color: var(--clay, #c05a3e);
}

.wave {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
}

.wave i {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.04);
}

.wave.red i { background: #d1493f; }
.wave.blue i { background: #3a6ea8; }
.wave.green i { background: #3f8a5f; }

.disclaimer {
  margin: 22px 0 0;
  text-align: center;
  font-size: 11.5px;
  color: var(--faint);
  letter-spacing: 0.03em;
}

/* ============================================================
   历史记录
   ============================================================ */

.toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.search-box {
  position: relative;
  flex: 1;
}

.search-box input {
  width: 100%;
  height: 42px;
  padding: 0 14px 0 36px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 13.5px;
  outline: none;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.search-box input::placeholder {
  color: var(--faint);
}

.search-box input:focus {
  border-color: var(--gold-soft);
  box-shadow: 0 0 0 3px rgba(184, 137, 43, 0.12);
}

.search-box::before {
  content: "⌕";
  position: absolute;
  left: 13px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--faint);
  font-size: 16px;
  pointer-events: none;
}

.table-wrap {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  overflow: hidden;
}

.table-scroll {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  white-space: nowrap;
}

thead th {
  padding: 11px 14px;
  text-align: left;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--muted);
  background: #f8f3e8;
  border-bottom: 1px solid var(--line);
}

tbody td {
  padding: 12px 14px;
  border-bottom: 1px solid #f3eee3;
  color: var(--ink);
}

tbody tr:last-child td {
  border-bottom: 0;
}

tbody tr:hover td {
  background: #fdfbf6;
}

tbody tr[data-issue] {
  cursor: pointer;
}

td.num {
  font-family: var(--mono);
  font-weight: 600;
}

td .mini {
  color: var(--muted);
  font-size: 12.5px;
}

.empty-row td {
  padding: 34px 14px;
  text-align: center;
  color: var(--faint);
}

.pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 16px;
}

.pager button {
  height: 36px;
  padding: 0 16px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  transition: 0.16s ease;
}

.pager button:hover:not(:disabled) {
  border-color: var(--gold-soft);
  background: #fdf7e8;
  color: var(--gold);
}

.pager button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.pager .page-info {
  font-size: 12.5px;
  color: var(--muted);
  min-width: 56px;
  text-align: center;
}

/* ============================================================
   Toast
   ============================================================ */

.toast {
  position: fixed;
  left: 50%;
  bottom: 32px;
  z-index: 60;
  transform: translate(-50%, 14px);
  max-width: min(88vw, 420px);
  padding: 10px 16px;
  border-radius: 12px;
  border: 1px solid rgba(184, 137, 43, 0.35);
  background: rgba(22, 30, 44, 0.94);
  color: #f6edda;
  font-size: 13px;
  text-align: center;
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, 0.6);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ============================================================
   精选生肖 / 号码参考 / 公告 / 会员中心
   ============================================================ */

/* 分段切换 */
.tabs {
  display: flex;
  gap: 4px;
  padding: 4px;
  margin: 14px 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #f7f2e7;
}

.tab {
  flex: 1;
  height: 34px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  transition: 0.16s ease;
}

.tab:hover {
  color: var(--ink);
}

.tab.on {
  background: #fff;
  color: var(--ink);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(27, 34, 48, 0.12);
}

.z-list.big {
  gap: 8px;
}

.z-list.big .z-item {
  min-width: 46px;
  padding: 9px 15px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 11px;
}

/* 统计条 */
.bars {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px 20px;
}

.bars.one {
  grid-template-columns: 1fr;
  gap: 12px;
}

.bar-row {
  display: grid;
  grid-template-columns: 26px 1fr 26px;
  align-items: center;
  gap: 9px;
}

.bar-name {
  font-size: 13px;
  text-align: center;
  color: var(--ink);
}

.bar-track {
  height: 8px;
  border-radius: 99px;
  background: #f1ebe0;
  overflow: hidden;
}

.bar-fill {
  display: block;
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, #d8b46a, var(--gold));
  transition: width 0.45s ease;
}

.bar-fill.red {
  background: linear-gradient(90deg, #e6a49d, #c94a40);
}

.bar-fill.blue {
  background: linear-gradient(90deg, #a9c4e0, #3a6ea8);
}

.bar-fill.green {
  background: linear-gradient(90deg, #a8d3ba, #3f8a5f);
}

.bar-count {
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--muted);
  text-align: right;
}

/* 号码小球 */
.ball-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 14px;
}

.ball-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
}

.ball {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 600;
}

.ball.red {
  background: linear-gradient(145deg, #d3574c, #b23c33);
  box-shadow: 0 8px 16px -10px rgba(178, 60, 51, 0.9);
}
.ball.blue {
  background: linear-gradient(145deg, #4a7fb8, #315b8a);
  box-shadow: 0 8px 16px -10px rgba(49, 91, 138, 0.9);
}
.ball.green {
  background: linear-gradient(145deg, #4d9a6e, #35714f);
  box-shadow: 0 8px 16px -10px rgba(53, 113, 79, 0.9);
}

.ball-label {
  font-size: 10.5px;
  color: var(--faint);
}

/* 尾数格子 */
.tail-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.tail-cell {
  padding: 11px 6px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fdfbf6;
  text-align: center;
}

.tail-num {
  font-family: var(--mono);
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
}

.tail-cnt {
  margin-top: 2px;
  font-size: 11px;
  color: var(--muted);
}

/* 公告 */
.notice {
  display: flex;
  gap: 14px;
  padding: 15px 0;
  border-bottom: 1px dashed #f0e9db;
}

.notice:first-child {
  padding-top: 2px;
}

.notice:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.notice-date {
  flex: none;
  width: 76px;
  padding-top: 2px;
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--faint);
  letter-spacing: 0.02em;
}

.notice h3 {
  margin: 0 0 4px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.notice p {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.75;
  color: var(--muted);
}

/* 会员中心 */
.profile {
  display: flex;
  align-items: center;
  gap: 14px;
}

.avatar {
  flex: none;
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--navy), var(--royal));
  color: #e8d9b5;
  font-size: 20px;
  font-weight: 700;
}

.profile-name {
  font-size: 17px;
  font-weight: 600;
  line-height: 1.4;
}

.profile-sub {
  font-size: 12px;
  color: var(--muted);
}

.member-actions {
  display: flex;
  gap: 8px;
  margin-left: auto;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.btn-sm {
  height: 32px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 12.5px;
  cursor: pointer;
  transition: 0.16s ease;
}

.btn-sm:hover {
  border-color: var(--gold-soft);
  background: #fdf7e8;
  color: var(--gold);
}

.name-form {
  display: flex;
  gap: 8px;
  margin-top: 14px;
}

.name-form input {
  flex: 1;
  height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 13px;
  outline: none;
}

.name-form input:focus {
  border-color: var(--gold-soft);
  box-shadow: 0 0 0 3px rgba(184, 137, 43, 0.12);
}

.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 11px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
  font-size: 12.5px;
  text-decoration: none;
  transition: 0.16s ease;
}

.chip-link:hover {
  border-color: var(--gold-soft);
  background: #fdf7e8;
  color: var(--gold);
}

.chip-link button {
  border: 0;
  background: transparent;
  padding: 0;
  color: var(--faint);
  font-size: 13px;
  line-height: 1;
  cursor: pointer;
}

.chip-link button:hover {
  color: #c05a3e;
}

.block-sub {
  margin: 10px 0 0;
  font-size: 12px;
  color: var(--faint);
  line-height: 1.7;
}

/* 每日资料里的收藏按钮 */
.fav-line {
  display: flex;
  justify-content: center;
  margin-top: 6px;
}

.fav-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 28px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 99px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
  transition: 0.16s ease;
}

.fav-btn:hover {
  border-color: var(--gold-soft);
  background: #fdf7e8;
  color: var(--gold);
}

.fav-btn.on {
  border-color: var(--gold-soft);
  background: #fbf3e0;
  color: var(--gold);
  font-weight: 600;
}

/* ============================================================
   首页 / 开奖展示
   ============================================================ */

.appbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px max(18px, calc(50% - 410px));
  border-bottom: 1px solid var(--line);
  background: rgba(245, 241, 232, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.brand-mark {
  flex: none;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--navy), var(--royal));
  color: #e8d9b5;
  font-size: 14px;
}

.brand-name {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.appbar .pill {
  margin-left: auto;
}

/* 最新开奖卡 */
.draw-card {
  position: relative;
  overflow: hidden;
  padding: 20px 18px 16px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 22px 44px -36px rgba(15, 34, 63, 0.7);
}

.draw-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: linear-gradient(90deg, var(--navy), var(--royal), var(--gold));
}

.draw-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.draw-top h1 {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.draw-issue {
  flex: none;
  padding: 2px 10px;
  border-radius: 99px;
  border: 1px solid var(--gold-soft);
  background: #fbf3e0;
  color: var(--gold);
  font-family: var(--mono);
  font-size: 12px;
}

.draw-time {
  margin-top: 6px;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.draw-balls {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: center;
  gap: 10px 12px;
  margin: 20px 0 4px;
}

/* 号码球：台球质感 */
.nb {
  --ball: 52px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.nb-num {
  position: relative;
  width: var(--ball);
  height: var(--ball);
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 26%, #b9b2a4 0%, #8b8477 45%, #5f594f 100%);
  box-shadow:
    inset -5px -6px 13px rgba(0, 0, 0, 0.3),
    inset 4px 6px 11px rgba(255, 255, 255, 0.24),
    0 9px 16px -10px rgba(24, 18, 10, 0.65);
}

/* 左上高光 */
.nb-num::after {
  content: "";
  position: absolute;
  left: 17%;
  top: 11%;
  width: 40%;
  height: 30%;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0));
  transform: rotate(-20deg);
  pointer-events: none;
}

/* 中间白色号码盘 */
.nb-ink {
  position: relative;
  z-index: 1;
  width: 63%;
  height: 63%;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: radial-gradient(circle at 34% 28%, #ffffff 0%, #fbf8f1 62%, #e9e2d2 100%);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.24), inset 0 -1px 2px rgba(0, 0, 0, 0.05);
  color: #1f1f1f;
  font-family: var(--mono);
  font-size: calc(var(--ball) * 0.36);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
}

.nb.red .nb-num {
  background: radial-gradient(circle at 32% 26%, #ff9c92 0%, #e0493f 38%, #b2312a 74%, #8a241f 100%);
}
.nb.blue .nb-num {
  background: radial-gradient(circle at 32% 26%, #9dc2ec 0%, #3f6fae 38%, #2b5086 74%, #1d3a66 100%);
}
.nb.green .nb-num {
  background: radial-gradient(circle at 32% 26%, #9adcb6 0%, #3f8a5f 38%, #2c6b47 74%, #1d5236 100%);
}

.nb.special .nb-num {
  box-shadow:
    0 0 0 3px rgba(214, 178, 104, 0.55),
    inset -6px -8px 16px rgba(0, 0, 0, 0.34),
    inset 5px 7px 12px rgba(255, 255, 255, 0.26),
    0 10px 18px -10px rgba(24, 18, 10, 0.7);
}

.nb-z {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.2;
}

.nb.sm .nb-num {
  --ball: 38px;
}
.nb.sm .nb-z {
  display: none;
}

.nb-plus {
  align-self: center;
  margin-top: 6px;
  color: var(--gold);
  font-family: var(--mono);
  font-size: 18px;
  font-weight: 700;
}

.draw-balls .nb-num {
  --ball: 56px;
}

/* 主按钮 */
.draw-actions {
  display: flex;
  gap: 8px;
  margin-top: 18px;
}

.btn {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 42px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 14px;
  text-decoration: none;
  cursor: pointer;
  transition: 0.16s ease;
}

.btn:hover {
  border-color: var(--gold-soft);
  background: #fdf7e8;
}

.btn.primary {
  border-color: transparent;
  background: linear-gradient(135deg, var(--navy), var(--royal));
  color: #fff;
  box-shadow: 0 14px 26px -18px rgba(15, 34, 63, 0.95);
}

.btn.primary:hover {
  filter: brightness(1.08);
  color: #fff;
}

.btn.more-btn {
  flex: 0 0 auto;
  padding: 0 14px;
  color: var(--muted);
}

/* 快捷入口 */
.quick {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.quick a {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  padding: 14px 6px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  color: var(--ink);
  font-size: 12.5px;
  text-decoration: none;
  transition: 0.16s ease;
}

.quick a:hover {
  transform: translateY(-2px);
  border-color: var(--gold-soft);
  box-shadow: 0 14px 26px -20px rgba(27, 34, 48, 0.5);
}

.qi {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: #f7f2e7;
  color: var(--gold);
  font-size: 15px;
  font-family: var(--mono);
}

/* 倒计时 */
.countdown-box {
  position: relative;
  overflow: hidden;
  padding: 18px 14px 16px;
  border-radius: 16px;
  text-align: center;
  color: #fff;
  background: linear-gradient(135deg, #0f223f, #22427f 70%, #2f5390);
}

.countdown-box::after {
  content: "";
  position: absolute;
  inset: -40% -20% auto auto;
  width: 260px;
  height: 260px;
  background: radial-gradient(closest-side, rgba(214, 178, 104, 0.28), transparent 70%);
  pointer-events: none;
}

.cd-label {
  position: relative;
  font-size: 11.5px;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.72);
}

.cd-time {
  position: relative;
  margin-top: 6px;
  font-family: var(--mono);
  font-size: 30px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #f2e4c4;
}

.cd-time.big {
  font-size: 40px;
  margin-top: 10px;
}

.cd-issue {
  position: relative;
  margin-top: 6px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.62);
}

.times {
  display: flex;
  gap: 8px;
  margin-top: 14px;
  flex-wrap: wrap;
  justify-content: center;
}

.time-item {
  flex: 0 1 180px;
  min-width: 92px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  padding: 8px 6px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fdfbf6;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 12.5px;
}

.time-item i {
  font-style: normal;
  font-size: 10px;
  color: var(--faint);
}

.time-item.done {
  background: #f2ede1;
  color: #a09988;
}

.time-item.next {
  border-color: var(--gold-soft);
  background: #fdf6e6;
  color: #96691c;
}

.time-item.next i {
  color: var(--gold);
}

/* 近期开奖 */
.recent {
  display: flex;
  flex-direction: column;
}

.recent-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 2px;
  border-bottom: 1px dashed #f0e9db;
  text-decoration: none;
  color: inherit;
}

.recent-row:last-child {
  border-bottom: 0;
  padding-bottom: 2px;
}

.recent-row:hover .rr-issue {
  color: var(--gold);
}

.rr-main {
  display: flex;
  flex-direction: column;
  min-width: 92px;
}

.rr-issue {
  font-size: 16px;
  font-weight: 600;
}

.rr-date {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--faint);
}

.rr-balls {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 5px;
  flex-wrap: wrap;
  margin-left: auto;
}

/* 直播页开奖记录 */
.feed-row {
  padding: 14px 2px;
  border-bottom: 1px dashed #f0e9db;
}

.feed-row:last-child {
  border-bottom: 0;
}

.feed-head {
  display: flex;
  align-items: center;
  gap: 8px;
}

.feed-issue {
  font-size: 16px;
  font-weight: 600;
}

.feed-date {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--faint);
}

.feed-balls {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.feed-balls .nb-num {
  --ball: 52px;
}

.feed-balls .nb-z {
  font-size: 12.5px;
}

.feed-balls .nb-plus {
  margin-top: 14px;
}

.feed-balls .nb.special {
  margin-left: 6px;
}

.tag-new {
  padding: 0 6px;
  border-radius: 5px;
  border: 1px solid var(--gold-soft);
  background: #fbf3e0;
  color: var(--gold);
  font-size: 10px;
  line-height: 1.6;
}

.live-card {
  padding-top: 24px;
  padding-bottom: 22px;
}

.more {
  font-size: 12px;
  color: var(--muted);
  text-decoration: none;
}

.more:hover {
  color: var(--gold);
}

/* 底部导航 */
.tabbar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  display: flex;
  padding: 7px 6px calc(7px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: rgba(245, 241, 232, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.tabbar a {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 3px 0;
  color: var(--muted);
  font-size: 11px;
  text-decoration: none;
}

.tabbar svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tabbar a.on {
  color: var(--gold);
}

.tabbar a.on svg {
  stroke-width: 2;
}

body.home {
  padding-bottom: 70px;
}

@media (min-width: 760px) {
  .tabbar {
    display: none;
  }
  body.home {
    padding-bottom: 0;
  }
}

/* ============================================================
   背景层 & 首页深色区
   ============================================================ */

.bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(84px);
  opacity: 0.5;
  animation: drift 26s ease-in-out infinite alternate;
}

.orb-1 {
  width: 480px;
  height: 480px;
  left: -150px;
  top: -190px;
  background: radial-gradient(circle, rgba(246, 213, 152, 0.9), transparent 66%);
}

.orb-2 {
  width: 560px;
  height: 560px;
  right: -210px;
  top: 40px;
  background: radial-gradient(circle, rgba(246, 199, 168, 0.72), transparent 66%);
  animation-delay: -6s;
}

.orb-3 {
  width: 520px;
  height: 520px;
  left: 26%;
  top: 540px;
  background: radial-gradient(circle, rgba(230, 203, 214, 0.55), transparent 66%);
  animation-delay: -12s;
}

@keyframes drift {
  from {
    transform: translate3d(0, 0, 0) scale(1);
  }
  to {
    transform: translate3d(30px, -40px, 0) scale(1.08);
  }
}

.grain {
  position: absolute;
  inset: 0;
  opacity: 0.55;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix type='saturate' values='0'/></filter><rect width='160' height='160' filter='url(%23n)' opacity='0.07'/></svg>");
}

/* 细点阵：只在内容区淡淡铺一层 */
body.home::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: radial-gradient(rgba(15, 34, 63, 0.14) 1px, transparent 1px);
  background-size: 26px 26px;
  opacity: 0.45;
  -webkit-mask-image: linear-gradient(180deg, transparent 360px, #000 460px 86%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 360px, #000 460px 86%, transparent 100%);
}

/* 顶部深色区 */
.hero {
  position: relative;
  z-index: 1;
  overflow: hidden;
  padding: 4px 0 36px;
  border-radius: 0 0 34px 34px;
  background:
    radial-gradient(760px 380px at 82% -14%, rgba(214, 178, 104, 0.22), transparent 62%),
    radial-gradient(680px 400px at -12% 6%, rgba(58, 110, 168, 0.4), transparent 62%),
    linear-gradient(158deg, #0a1730 0%, #122a4d 44%, #1c3c6e 100%);
  box-shadow: 0 34px 66px -46px rgba(10, 23, 48, 0.75);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.5;
  background-image: radial-gradient(rgba(255, 255, 255, 0.18) 1px, transparent 1px);
  background-size: 20px 20px;
  -webkit-mask-image: radial-gradient(120% 80% at 70% 0%, #000 6%, transparent 72%);
  mask-image: radial-gradient(120% 80% at 70% 0%, #000 6%, transparent 72%);
}

.hero::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -120px;
  width: 720px;
  height: 240px;
  transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(214, 178, 104, 0.18), transparent 70%);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  padding-bottom: 0;
}

.hero .appbar {
  position: static;
  padding: 14px 0 12px;
  border: 0;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.hero .brand-name {
  color: #f6f1e6;
  font-size: 15.5px;
  letter-spacing: 0.04em;
}

.hero .brand-mark {
  background: linear-gradient(135deg, #d6b268, #f3e2b6);
  color: #10233f;
  box-shadow: 0 10px 22px -12px rgba(214, 178, 104, 0.95);
}

.hero .pill {
  border-color: rgba(214, 178, 104, 0.42);
  background: rgba(214, 178, 104, 0.16);
  color: #f2e2ba;
}

.hero .draw-card {
  border-color: rgba(255, 255, 255, 0.16);
  box-shadow:
    0 34px 60px -30px rgba(4, 12, 26, 0.9),
    0 0 0 1px rgba(214, 178, 104, 0.16),
    0 0 70px -24px rgba(214, 178, 104, 0.35);
}

.main-body {
  position: relative;
  z-index: 1;
  padding-top: 22px;
}

.update-tip {
  position: fixed;
  left: 50%;
  bottom: 86px;
  z-index: 60;
  transform: translate(-50%, 20px);
  padding: 10px 18px;
  border: 1px solid rgba(214, 178, 104, 0.5);
  border-radius: 99px;
  background: linear-gradient(135deg, #0f223f, #22427f);
  color: #f2e4c4;
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  box-shadow: 0 18px 40px -18px rgba(10, 23, 48, 0.9);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.update-tip.show {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, 0);
}

@media (min-width: 760px) {
  .update-tip {
    bottom: 28px;
  }
}

.wrap {
  position: relative;
  z-index: 1;
}

/* 视频直播 */
.player-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 14px;
  overflow: hidden;
  background: #0b1220;
}

.player {
  width: 100%;
  height: 100%;
  display: block;
  background: #0b1220;
}

.player-mask {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 22px;
  text-align: center;
  color: #d6dee9;
  font-size: 13px;
  line-height: 1.95;
  background: radial-gradient(120% 100% at 50% 0%, rgba(20, 40, 72, 0.94), rgba(8, 14, 26, 0.97));
  transition: opacity 0.2s ease;
}

.player-mask.hide {
  opacity: 0;
  pointer-events: none;
}

.player-mask.loading .mask-text::after {
  content: "";
  display: block;
  width: 26px;
  height: 26px;
  margin: 12px auto 0;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.18);
  border-top-color: #d6b268;
  animation: spin 0.9s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.mask-dim {
  color: #8b99ad;
  font-size: 12px;
}

.player-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  flex-wrap: wrap;
}

/* 动画开奖 */
.anim {
  padding-top: 4px;
  text-align: center;
}

.anim-balls {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  padding: 20px 4px 12px;
}

.anim-ball {
  opacity: 0.12;
  transform: translateY(10px) scale(0.88);
  transition: opacity 0.3s ease, transform 0.36s cubic-bezier(0.2, 0.8, 0.3, 1.4);
}

.anim-ball.on {
  opacity: 1;
  transform: none;
}

.anim-meta {
  margin-bottom: 14px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
}

/* 历史记录列表 */
.hist-list {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  overflow: hidden;
}

.hist-item {
  display: block;
  padding: 18px 20px 20px;
  border-bottom: 1px solid #f1ebe0;
  color: inherit;
  text-decoration: none;
}

.hist-item:last-child {
  border-bottom: 0;
}



.hist-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 16px;
}

.hist-issue {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--ink);
}

.hist-time {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--muted);
}

.hist-balls {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 12px;
}

.hist-balls .nb-num {
  --ball: 56px;
}

.hist-balls .nb-z {
  margin-top: 2px;
  font-size: 13px;
  color: #8b8578;
}

.hist-balls .nb-plus {
  margin-top: 13px;
  color: #d1493f;
  font-size: 20px;
  font-weight: 700;
}

.hist-balls .nb.special {
  margin-left: 8px;
}

.hist-empty {
  padding: 46px 0;
  text-align: center;
  font-size: 13.5px;
  color: var(--faint);
}

/* 冷码统计 */
.cold-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  margin-bottom: 12px;
  font-size: 11.5px;
  color: var(--muted);
}

.cold-legend .legend-note {
  margin-left: auto;
  color: var(--faint);
}

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

.cold-dot {
  background: #4a78b5;
}

.hot-dot {
  background: #d1493f;
}

.cold-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 10px;
}

.cold-cell {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 12px 4px 10px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fdfbf6;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.cold-cell:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 26px -22px rgba(27, 34, 48, 0.6);
}

.cold-cell.is-cold {
  border-color: rgba(74, 120, 181, 0.45);
  background: linear-gradient(180deg, #f7faff, #eef4fc);
}

.cold-cell.is-hot {
  border-color: rgba(209, 73, 63, 0.35);
  background: linear-gradient(180deg, #fff8f6, #fdeeea);
}

.cold-ball .nb-num {
  --ball: 40px;
}

.cold-miss {
  font-size: 11.5px;
  color: var(--muted);
  white-space: nowrap;
}

.cold-miss b {
  margin: 0 1px;
  font-family: var(--mono);
  font-size: 15px;
  color: var(--ink);
}

.cold-sub {
  font-size: 10.5px;
  color: var(--faint);
  white-space: nowrap;
}

.cold-sub em {
  font-style: normal;
  font-family: var(--mono);
  color: var(--muted);
}

.cold-count {
  font-size: 10.5px;
  color: var(--faint);
  white-space: nowrap;
}

.cold-top {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.cold-top-item {
  position: relative;
  flex: 1;
  min-width: 112px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 16px 8px 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: linear-gradient(180deg, #f7faff, #eef4fc);
}

.cold-top-item .nb-num {
  --ball: 44px;
}

.cold-rank {
  position: absolute;
  top: 8px;
  left: 10px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--gold);
}

.cold-top-meta {
  font-size: 11.5px;
  color: var(--muted);
}

.cold-top-meta b {
  font-family: var(--mono);
  font-size: 14px;
  color: var(--ink);
}

/* ============================================================
   响应式
   ============================================================ */

@media (max-width: 620px) {
  .page {
    padding: 22px 14px 40px;
  }
  .banner {
    border-radius: 18px;
    padding: 30px 18px 26px;
  }
  .banner h1 {
    font-size: 24px;
    letter-spacing: 0.06em;
    text-indent: 0.06em;
  }
  .banner .sub {
    font-size: 12px;
    letter-spacing: 0.08em;
  }
  .grid {
    gap: 10px;
    margin-top: 12px;
  }
  .card {
    gap: 10px;
    padding: 13px 12px;
    border-radius: 14px;
  }
  .ico {
    width: 34px;
    height: 34px;
    border-radius: 10px;
  }
  .ico svg {
    width: 18px;
    height: 18px;
  }
  .t {
    font-size: 14.5px;
  }
  .d {
    font-size: 11.5px;
  }
  .chev {
    display: none;
  }

  .wrap {
    padding: 14px 14px 48px;
  }
  .block {
    padding: 15px 14px 16px;
    border-radius: 16px;
  }
  .zodiac-grid {
    gap: 8px;
  }
  .z-card {
    padding: 11px 12px;
  }
  .z-item {
    min-width: 28px;
    padding: 2px 6px;
    font-size: 12.5px;
  }
  .n-value {
    font-size: 22px;
  }
  .issue {
    font-size: 17px;
  }
  .issue b {
    font-size: 20px;
  }
  .topbar {
    padding: 10px 14px;
  }
  .bars {
    grid-template-columns: 1fr;
    gap: 9px;
  }
  .ball {
    width: 36px;
    height: 36px;
    font-size: 13.5px;
  }
  .tail-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
  }
  .tail-cell {
    padding: 9px 4px;
  }
  .notice {
    gap: 10px;
  }
  .notice-date {
    width: 64px;
    font-size: 11px;
  }
  .profile {
    flex-wrap: wrap;
  }
  .member-actions {
    margin-left: 0;
    width: 100%;
    justify-content: flex-start;
  }
  .z-list.big .z-item {
    min-width: 40px;
    padding: 8px 12px;
    font-size: 15px;
  }

  .appbar {
    padding: 10px 14px;
  }
  .draw-card {
    padding: 17px 14px 14px;
    border-radius: 18px;
  }
  .draw-balls {
    gap: 9px 10px;
    margin: 16px 0 2px;
  }
  .nb-num {
    --ball: 46px;
  }
  .nb.sm .nb-num {
    --ball: 32px;
  }
  .draw-actions {
    margin-top: 14px;
  }
  .btn {
    height: 40px;
    font-size: 13.5px;
    padding: 0 12px;
  }
  .quick {
    gap: 8px;
  }
  .quick a {
    padding: 12px 4px;
    font-size: 12px;
  }
  .qi {
    width: 30px;
    height: 30px;
    font-size: 13px;
  }
  .cd-time {
    font-size: 26px;
  }
  .cd-time.big {
    font-size: 32px;
  }
  .rr-main {
    min-width: 78px;
  }

  .hist-item {
    padding: 15px 14px 16px;
  }
  .hist-head {
    margin-bottom: 12px;
    gap: 8px;
  }
  .hist-issue {
    font-size: 16px;
  }
  .hist-time {
    font-size: 11.5px;
  }
  .hist-balls {
    gap: 7px;
  }
  .hist-balls .nb-num {
    --ball: 44px;
  }
  .feed-balls {
    gap: 8px;
  }
  .feed-balls .nb-num {
    --ball: 42px;
  }
  .feed-balls .nb-z {
    font-size: 11.5px;
  }
  .feed-balls .nb-plus {
    margin-top: 12px;
    font-size: 17px;
  }

  .cold-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
  }
  .cold-cell {
    padding: 10px 4px 9px;
    border-radius: 12px;
  }
  .cold-ball .nb-num {
    --ball: 36px;
  }
  .cold-miss {
    font-size: 11px;
  }
  .cold-miss b {
    font-size: 13px;
  }
  .cold-count {
    font-size: 10px;
  }
  .cold-top-item {
    min-width: calc(50% - 5px);
  }
  .cold-top-item .nb-num {
    --ball: 40px;
  }
  .hist-balls .nb-z {
    font-size: 12px;
  }
  .hist-balls .nb-plus {
    margin-top: 11px;
    font-size: 17px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-delay: 0ms !important;
    transition-duration: 0.001ms !important;
  }
}

/* ============================================================
   数字统一字体：去掉等宽字体里 0 的斜杠
   ============================================================ */

.nb-ink,
.cd-time,
.n-value,
.ball,
.draw-issue,
.issue b,
.hist-time,
.rr-date,
.feed-date,
.cold-miss b,
.cold-sub em,
.cold-top-meta b,
.cold-count,
.bar-count,
.tail-num,
.tabbar span,
.pager .page-info {
  font-family: var(--digit);
  font-variant-numeric: tabular-nums;
  font-feature-settings: "zero" 0;
}
/* ============================================================
   统计表格（冷肖 / 头数 / 波色）
   ============================================================ */

.cold-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.stat-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
  white-space: nowrap;
}

.stat-table th {
  padding: 9px 10px;
  text-align: center;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--muted);
  background: #f8f3e8;
  border-bottom: 1px solid var(--line);
}

.stat-table th:first-child {
  text-align: left;
}

.stat-table .sub-head th {
  background: #fbf7ee;
  font-size: 11px;
  color: var(--faint);
}

.stat-table td {
  padding: 10px;
  text-align: center;
  border-bottom: 1px solid #f3eee3;
  font-family: var(--digit);
  font-variant-numeric: tabular-nums;
  font-size: 14px;
  color: var(--ink);
}

.stat-table td.zi {
  text-align: left;
  font-family: var(--sans);
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink);
}

.stat-table tbody tr:last-child td {
  border-bottom: 0;
}

.stat-table tbody tr:hover td {
  background: #fdfbf6;
}

.stat-table .mini {
  margin-left: 4px;
  font-family: var(--digit);
  font-size: 11px;
  font-weight: 400;
  color: var(--faint);
}

.stat-table td.is-cold-cell {
  color: #2f5c8e;
  background: #f2f7fd;
  font-weight: 700;
}

.stat-table td.is-hot-cell {
  color: #b23c33;
  background: #fdf3f1;
  font-weight: 700;
}

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

.wave-dot.red {
  background: #d1493f;
}
.wave-dot.green {
  background: #3f8a5f;
}
.wave-dot.blue {
  background: #3a6ea8;
}

@media (max-width: 620px) {
  .cold-two {
    grid-template-columns: 1fr;
  }
  .stat-table {
    font-size: 12.5px;
  }
  .stat-table td {
    padding: 8px 6px;
    font-size: 13px;
  }
  .stat-table th {
    padding: 8px 6px;
    font-size: 10.5px;
  }
}
/* ============================================================
   冷码统计：顶部分页
   ============================================================ */

.page-tabs {
  position: sticky;
  top: 58px;
  z-index: 15;
  display: flex;
  gap: 6px;
  padding: 5px;
  margin: 4px 0 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(247, 242, 231, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.ptab {
  flex: 1;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0 6px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 13px;
  white-space: nowrap;
  cursor: pointer;
  transition: 0.16s ease;
}

.ptab b {
  font-family: var(--digit);
  font-size: 11px;
  font-weight: 700;
  color: var(--faint);
}

.ptab:hover {
  color: var(--ink);
}

.ptab.on {
  background: #fff;
  color: var(--ink);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(27, 34, 48, 0.12);
}

.ptab.on b {
  color: var(--gold);
}

.page-block {
  display: none;
}

.page-block.on {
  display: block;
}

@media (max-width: 620px) {
  .page-tabs {
    top: 52px;
  }
  .ptab {
    height: 38px;
    font-size: 12px;
    gap: 4px;
  }
  .ptab b {
    font-size: 10px;
  }
}
/* 冷肖表：特肖 / 平肖 分组区分 */
.stat-table .grp-te {
  background: #fbf5e6;
  color: #8a6a1f;
}

.stat-table .grp-ping {
  background: #eef4fc;
  color: #2f5c8e;
}

.zodiac-table .ping-first {
  border-left: 2px solid #e3e8f0;
}

.zodiac-table td:nth-child(4),
.zodiac-table td:nth-child(5) {
  background: #f8fbff;
}

.zodiac-table td:nth-child(4) {
  border-left: 2px solid #e3e8f0;
}

.zodiac-table tbody tr:hover td {
  background: #fdfbf6;
}
.stat-table .zi-idx {
  margin-right: 6px;
  font-family: var(--digit);
  font-size: 12px;
  font-weight: 500;
  color: var(--faint);
}

/* ============================================================
   大数据
   ============================================================ */

.ov-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.ov-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 14px 8px 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fdfbf6;
}

.ov-k {
  display: flex;
  align-items: center;
  font-size: 12px;
  color: var(--muted);
}

.ov-v {
  font-family: var(--digit);
  font-variant-numeric: tabular-nums;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--ink);
}

.ov-sub {
  font-size: 11px;
  color: var(--faint);
}

@media (max-width: 620px) {
  .ov-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .ov-v {
    font-size: 20px;
  }
}
/* ============================================================
   排行榜
   ============================================================ */

.rank-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.seg {
  display: flex;
  flex: 1;
  min-width: 220px;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #f7f2e7;
}

.seg-btn {
  flex: 1;
  height: 32px;
  padding: 0 8px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 12.5px;
  white-space: nowrap;
  cursor: pointer;
  transition: 0.15s ease;
}

.seg-btn:hover {
  color: var(--ink);
}

.seg-btn.on {
  background: #fff;
  color: var(--ink);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(27, 34, 48, 0.12);
}

.rank-list {
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
}

.rank-row {
  display: grid;
  grid-template-columns: 52px 1fr 130px;
  align-items: center;
  gap: 12px;
  padding: 11px 16px;
  border-bottom: 1px solid #f3eee3;
  background: #fff;
}

.rank-row:last-child {
  border-bottom: 0;
}

.rank-row.top1 {
  background: linear-gradient(90deg, #fdf4e2, #fffdf8);
}
.rank-row.top2 {
  background: linear-gradient(90deg, #f2f6fb, #fffdf8);
}
.rank-row.top3 {
  background: linear-gradient(90deg, #fdf0ea, #fffdf8);
}

.rank-no {
  text-align: center;
  font-family: var(--digit);
  font-size: 14px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.rank-no.medal {
  width: 28px;
  height: 28px;
  margin: 0 auto;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  box-shadow: 0 4px 10px -6px rgba(0, 0, 0, 0.5);
}

.medal.gold {
  background: linear-gradient(145deg, #f4c65a, #d99a1e);
}
.medal.silver {
  background: linear-gradient(145deg, #cfd6e0, #98a5b8);
}
.medal.bronze {
  background: linear-gradient(145deg, #e3a97e, #b97a49);
}

.rank-ball {
  display: flex;
  justify-content: center;
}

.rank-ball .nb-num {
  --ball: 38px;
}

.rank-val {
  text-align: right;
  font-family: var(--digit);
  font-variant-numeric: tabular-nums;
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
}

.rank-val em {
  margin-left: 4px;
  font-style: normal;
  font-size: 11.5px;
  font-weight: 400;
  color: var(--faint);
}

@media (max-width: 620px) {
  .rank-row {
    grid-template-columns: 42px 1fr 96px;
    padding: 10px 12px;
    gap: 8px;
  }
  .rank-ball .nb-num {
    --ball: 34px;
  }
  .rank-val {
    font-size: 14.5px;
  }
  .seg {
    min-width: 0;
  }
  .seg-btn {
    font-size: 11.5px;
  }
}
/* ============================================================
   热买榜
   ============================================================ */

.hb-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.hb-issue {
  font-size: 13px;
  color: var(--muted);
}

.hb-bar .btn-sm {
  margin-left: auto;
}

.hb-empty {
  padding: 40px 20px;
  text-align: center;
  font-size: 13px;
  color: var(--muted);
  line-height: 2;
}

.hb-empty span {
  font-size: 12px;
  color: var(--faint);
}

.hb-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}

.field > span {
  font-size: 11.5px;
  letter-spacing: 0.04em;
  color: var(--faint);
}

.field input,
.field textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 13px;
  line-height: 1.7;
  outline: none;
  resize: vertical;
}

.field textarea {
  font-family: var(--digit);
  font-size: 13px;
}

.field input:focus,
.field textarea:focus {
  border-color: var(--gold-soft);
  box-shadow: 0 0 0 3px rgba(184, 137, 43, 0.12);
}
/* ============================================================
   热买榜页
   ============================================================ */

.hb-tabs {
  display: flex;
  gap: 6px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f7f2e7;
}

.hb-tab {
  flex: 1;
  height: 42px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 14px;
  cursor: pointer;
  transition: 0.16s ease;
}

.hb-tab.on {
  background: linear-gradient(135deg, var(--navy), var(--royal));
  color: #fff;
  font-weight: 600;
  box-shadow: 0 8px 18px -12px rgba(15, 34, 63, 0.9);
}

.hb-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 14px 0 8px;
  flex-wrap: wrap;
}

.hb-select {
  height: 36px;
  padding: 0 30px 0 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background-color: #fff;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 16px) 16px, calc(100% - 11px) 16px;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  color: var(--ink);
  font: inherit;
  font-size: 13px;
  appearance: none;
  -webkit-appearance: none;
  outline: none;
  cursor: pointer;
}

.hb-issues {
  display: flex;
  gap: 6px;
  margin-left: auto;
  flex-wrap: wrap;
}

.hb-chip {
  height: 30px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 99px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-family: var(--digit);
  font-size: 12.5px;
  cursor: pointer;
  transition: 0.15s ease;
}

.hb-chip:hover {
  border-color: var(--gold-soft);
  color: var(--ink);
}

.hb-chip.on {
  background: linear-gradient(135deg, var(--navy), var(--royal));
  border-color: transparent;
  color: #fff;
  font-weight: 600;
}

.hb-chip.more {
  font-family: var(--sans);
}

.hb-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 10px 2px 8px;
  font-size: 12px;
  color: var(--faint);
}

.hb-table {
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
}

.hb-head {
  display: grid;
  grid-template-columns: 52px 1fr 130px;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  background: #f8f3e8;
  font-size: 11.5px;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.hb-head span:nth-child(2) {
  text-align: center;
}

.hb-head span:last-child {
  text-align: right;
}

.hb-table .hb-empty {
  padding: 46px 20px;
  text-align: center;
  font-size: 13px;
  color: var(--faint);
}

.hb-table .rank-row:last-child {
  border-bottom: 0;
}

@media (max-width: 620px) {
  .hb-tab {
    height: 38px;
    font-size: 13px;
  }
  .hb-head {
    grid-template-columns: 42px 1fr 96px;
    padding: 9px 12px;
  }
  .hb-issues {
    margin-left: 0;
    width: 100%;
  }
  .hb-meta {
    font-size: 11px;
  }
}
/* 玩法切换 */
.hb-plays {
  display: flex;
  gap: 8px;
  margin: 14px 0 12px;
  flex-wrap: wrap;
}

.hb-play {
  flex: 1;
  min-width: 96px;
  height: 38px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-size: 13px;
  white-space: nowrap;
  cursor: pointer;
  transition: 0.16s ease;
}

.hb-play:hover {
  border-color: var(--gold-soft);
  color: var(--ink);
}

.hb-play.on {
  background: linear-gradient(135deg, var(--navy), var(--royal));
  border-color: transparent;
  color: #fff;
  font-weight: 600;
  box-shadow: 0 8px 18px -12px rgba(15, 34, 63, 0.9);
}

/* 生肖圆牌 */
.zi-badge {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 26%, #f7e2b4 0%, #dfb763 42%, #b8892b 100%);
  color: #4a3105;
  font-size: 18px;
  font-weight: 700;
  box-shadow: inset -3px -4px 8px rgba(120, 80, 10, 0.35),
    inset 3px 4px 8px rgba(255, 255, 255, 0.5), 0 8px 16px -10px rgba(24, 18, 10, 0.6);
}

@media (max-width: 620px) {
  .hb-play {
    height: 34px;
    font-size: 12px;
    min-width: 0;
  }
  .zi-badge {
    width: 34px;
    height: 34px;
    font-size: 16px;
  }
}
/* ============================================================
   历史记录：日期查询
   ============================================================ */

.hist-filter {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 14px;
}

.date-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.date-input {
  flex: 1;
  min-width: 160px;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 13.5px;
  outline: none;
  color-scheme: light;
}

.date-input:focus {
  border-color: var(--gold-soft);
  box-shadow: 0 0 0 3px rgba(184, 137, 43, 0.12);
}

.date-row .btn-sm {
  height: 40px;
  padding: 0 16px;
}
.date-hint {
  margin: -2px 0 0;
  font-size: 11.5px;
  color: var(--faint);
}

/* ============================================================
   跳码助手
   ============================================================ */

.picker-groups {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.picker-group {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.picker-label {
  flex: none;
  width: 62px;
  padding-top: 6px;
  font-size: 12px;
  color: var(--faint);
  letter-spacing: 0.04em;
}

.picker-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.pick-chip {
  height: 30px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-size: 12.5px;
  white-space: nowrap;
  cursor: pointer;
  transition: 0.15s ease;
}

.pick-chip:hover {
  border-color: var(--gold-soft);
  color: var(--ink);
}

.pick-chip.on {
  background: linear-gradient(135deg, var(--navy), var(--royal));
  border-color: transparent;
  color: #fff;
  font-weight: 600;
}

.picker-actions {
  display: flex;
  gap: 8px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px dashed #f0e9db;
}

.pick-result {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 14px;
  min-height: 60px;
}

.pick-result .nb-num {
  --ball: 44px;
}

@media (max-width: 620px) {
  .picker-group {
    gap: 8px;
  }
  .picker-label {
    width: 48px;
    font-size: 11px;
    padding-top: 7px;
  }
  .pick-chip {
    height: 28px;
    padding: 0 9px;
    font-size: 12px;
  }
  .pick-result .nb-num {
    --ball: 38px;
  }
}
/* 波色 / 波色单双 配色 */
.pick-chip.c-red {
  color: #d93025;
  border-color: rgba(217, 48, 37, 0.4);
  background: #fdecea;
}
.pick-chip.c-blue {
  color: #1657c9;
  border-color: rgba(22, 87, 201, 0.4);
  background: #eaf1fe;
}
.pick-chip.c-green {
  color: #0f8a3d;
  border-color: rgba(15, 138, 61, 0.42);
  background: #e8faee;
}

.pick-chip.c-red:hover {
  border-color: #d93025;
}
.pick-chip.c-blue:hover {
  border-color: #1657c9;
}
.pick-chip.c-green:hover {
  border-color: #0f8a3d;
}

.pick-chip.c-red.on {
  background: linear-gradient(135deg, #ef4444, #b91c1c);
  border-color: transparent;
  color: #fff;
}
.pick-chip.c-blue.on {
  background: linear-gradient(135deg, #3b82f6, #1657c9);
  border-color: transparent;
  color: #fff;
}
.pick-chip.c-green.on {
  background: linear-gradient(135deg, #22c55e, #0f8a3d);
  border-color: transparent;
  color: #fff;
}
.pick-result {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 14px;
  min-height: 60px;
}

.pick-result .nb-num {
  --ball: 44px;
}

@media (max-width: 620px) {
  .picker-group {
    gap: 8px;
  }
  .picker-label {
    width: 48px;
    font-size: 11px;
    padding-top: 7px;
  }
  .pick-chip {
    height: 28px;
    padding: 0 9px;
    font-size: 12px;
  }
  .pick-result .nb-num {
    --ball: 38px;
  }
}
/* 波色 / 波色单双 配色 */
.pick-chip.c-red {
  color: #c04036;
  border-color: rgba(201, 74, 64, 0.35);
  background: #fdf3f1;
}
.pick-chip.c-blue {
  color: #2f5c8e;
  border-color: rgba(58, 110, 168, 0.35);
  background: #f2f7fd;
}
.pick-chip.c-green {
  color: #2f7a52;
  border-color: rgba(63, 138, 95, 0.35);
  background: #f1f9f4;
}

.pick-chip.c-red:hover {
  border-color: #c94a40;
}
.pick-chip.c-blue:hover {
  border-color: #3a6ea8;
}
.pick-chip.c-green:hover {
  border-color: #3f8a5f;
}

.pick-chip.c-red.on {
  background: linear-gradient(135deg, #e0493f, #b2312a);
  border-color: transparent;
  color: #fff;
}
.pick-chip.c-blue.on {
  background: linear-gradient(135deg, #3f6fae, #2b5086);
  border-color: transparent;
  color: #fff;
}
.pick-chip.c-green.on {
  background: linear-gradient(135deg, #3f8a5f, #2c6b47);
  border-color: transparent;
  color: #fff;
}
/* 挑码结果：置顶固定 */
.pick-panel {
  position: sticky;
  top: 58px;
  z-index: 12;
  margin-bottom: 14px;
  padding: 12px 14px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 14px 30px -26px rgba(27, 34, 48, 0.6);
}

.pick-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.pick-head h2 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.pick-head h2::before {
  content: "";
  display: inline-block;
  width: 3px;
  height: 13px;
  margin-right: 8px;
  border-radius: 2px;
  background: var(--gold);
  vertical-align: -1px;
}

.pick-panel .pick-result {
  max-height: 200px;
  overflow-y: auto;
  padding-right: 2px;
}

.pick-panel .pick-result .nb-num {
  --ball: 40px;
}

.pick-panel .pick-result .nb-z {
  font-size: 11px;
}

@media (max-width: 620px) {
  .pick-panel {
    top: 52px;
    padding: 10px 11px 12px;
  }
  .pick-panel .pick-result {
    max-height: 160px;
  }
  .pick-panel .pick-result .nb-num {
    --ball: 36px;
  }
}
.pick-actions {
  display: flex;
  gap: 6px;
  flex: none;
}

.pick-actions .btn-sm {
  height: 28px;
  padding: 0 11px;
  font-size: 12px;
}

.pick-head h2 .hint {
  margin-left: 8px;
  font-size: 11.5px;
  font-weight: 400;
  color: var(--faint);
}

@media (max-width: 620px) {
  .pick-actions .btn-sm {
    height: 26px;
    padding: 0 9px;
    font-size: 11.5px;
  }
  .pick-head h2 .hint {
    display: none;
  }
}
/* 跳码助手：整体放大 */
.pick-actions {
  gap: 8px;
}

.pick-actions .btn-sm {
  height: 38px;
  padding: 0 18px;
  font-size: 14px;
  border-radius: 11px;
}

.pick-actions #btnClear {
  color: var(--ink);
  border: 1px solid var(--line);
  background: #fff;
}

.pick-actions #btnClear:hover {
  border-color: var(--gold-soft);
  background: #fdf7e8;
  color: var(--gold);
}

.pick-actions #btnCopy {
  border-color: transparent;
  background: linear-gradient(135deg, var(--navy), var(--royal));
  color: #fff;
  font-weight: 600;
  box-shadow: 0 10px 20px -14px rgba(15, 34, 63, 0.95);
}

.pick-actions #btnCopy:hover {
  filter: brightness(1.08);
  color: #fff;
}

.pick-panel .pick-result {
  max-height: 250px;
  gap: 14px 16px;
}

.pick-panel .pick-result .nb-num {
  --ball: 48px;
}

.pick-panel .pick-result .nb-z {
  font-size: 12px;
}

.pick-chip {
  height: 36px;
  padding: 0 15px;
  font-size: 13.5px;
  border-radius: 9px;
}

.picker-label {
  width: 68px;
  padding-top: 8px;
  font-size: 12.5px;
}

.pick-head h2 {
  font-size: 16px;
}

@media (max-width: 620px) {
  .pick-actions .btn-sm {
    height: 34px;
    padding: 0 13px;
    font-size: 13px;
  }
  .pick-panel .pick-result {
    max-height: 210px;
    gap: 10px 12px;
  }
  .pick-panel .pick-result .nb-num {
    --ball: 42px;
  }
  .pick-chip {
    height: 33px;
    padding: 0 12px;
    font-size: 12.5px;
  }
  .picker-label {
    width: 52px;
  }
}
/* 跳码助手：分组标题加强 */
.picker-label {
  width: 76px;
  padding-top: 9px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: 0;
  display: flex;
  align-items: flex-start;
  gap: 7px;
  line-height: 1.35;
}

.picker-label::before {
  content: "";
  flex: none;
  width: 3px;
  height: 13px;
  margin-top: 2px;
  border-radius: 2px;
  background: var(--gold);
}

@media (max-width: 620px) {
  .picker-label {
    width: 62px;
    font-size: 12.5px;
    gap: 5px;
    padding-top: 8px;
  }
  .picker-label::before {
    height: 12px;
  }
}
.pick-empty {
  padding: 22px 4px;
  font-size: 13px;
  color: var(--faint);
  text-align: center;
}

/* ============================================================
   每日资料：资料图
   ============================================================ */

.gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.gallery-item {
  display: block;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fdfbf6;
  overflow: hidden;
  cursor: zoom-in;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}

.gallery-item:hover {
  transform: translateY(-2px);
  border-color: var(--gold-soft);
  box-shadow: 0 14px 26px -22px rgba(27, 34, 48, 0.6);
}

.gallery-item img {
  display: block;
  width: 100%;
  height: auto;
}

.gallery-empty {
  grid-column: 1 / -1;
  padding: 34px 12px;
  text-align: center;
  font-size: 13px;
  line-height: 2;
  color: var(--muted);
}

.gallery-empty span {
  font-size: 12px;
  color: var(--faint);
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(5, 8, 14, 0.92);
  cursor: zoom-out;
}

.lightbox img {
  max-width: 100%;
  max-height: 100%;
  border-radius: 10px;
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.9);
}

@media (min-width: 900px) {
  .gallery {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
/* 直播线路切换 */
.line-seg {
  display: flex;
  gap: 6px;
  margin: 12px 0 10px;
  flex-wrap: wrap;
}

.line-btn {
  height: 32px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-size: 12.5px;
  cursor: pointer;
  transition: 0.15s ease;
}

.line-btn.on {
  background: linear-gradient(135deg, var(--navy), var(--royal));
  border-color: transparent;
  color: #fff;
  font-weight: 600;
}
/* ============================================================
   每日资料：搜索版
   ============================================================ */

.search-row {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}

.search-row input {
  flex: 1;
  height: 44px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 13.5px;
  outline: none;
}

.search-row input:focus {
  border-color: var(--gold-soft);
  box-shadow: 0 0 0 3px rgba(184, 137, 43, 0.12);
}

.search-row .btn-sm.solid {
  height: 44px;
  padding: 0 20px;
  border-radius: 12px;
  font-size: 13.5px;
}

.toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 12.5px;
  color: var(--ink);
  cursor: pointer;
  user-select: none;
}

.toggle input {
  width: 16px;
  height: 16px;
  accent-color: var(--gold);
}

.toggle em {
  font-style: normal;
  font-size: 11.5px;
  color: var(--faint);
}

.chips {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: none;
}

.chips::-webkit-scrollbar {
  display: none;
}

.chip {
  flex: none;
  height: 34px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 99px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-family: var(--digit);
  font-size: 13px;
  cursor: pointer;
  transition: 0.15s ease;
}

.chip.on {
  background: linear-gradient(135deg, var(--navy), var(--royal));
  border-color: transparent;
  color: #fff;
  font-weight: 600;
}

.gallery-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 10px;
}

.gallery-head h2 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
}

.gallery-head h2::before {
  content: "";
  display: inline-block;
  width: 3px;
  height: 13px;
  margin-right: 8px;
  border-radius: 2px;
  background: var(--gold);
  vertical-align: -1px;
}

.day-head {
  grid-column: 1 / -1;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 6px 2px 2px;
  font-family: var(--digit);
  font-size: 12.5px;
  color: var(--faint);
}

.day-head span {
  color: var(--faint);
}

.g-card {
  position: relative;
  display: block;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fdfbf6;
  overflow: hidden;
  cursor: zoom-in;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}

.g-card:hover {
  transform: translateY(-2px);
  border-color: var(--gold-soft);
  box-shadow: 0 14px 26px -22px rgba(27, 34, 48, 0.6);
}

.g-card img {
  display: block;
  width: 100%;
  height: auto;
}



.g-text {
  display: block;
  padding: 7px 9px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  color: var(--ink);
  line-height: 1.55;
  text-align: left;
  word-break: break-all;
}
/* ============================================================
   站长心水（首页 · 清新版）
   ============================================================ */

.xs-block {
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

.xs-card {
  position: relative;
  overflow: hidden;
  padding: 18px 18px 14px;
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 20px;
  background:
    radial-gradient(720px 260px at 88% -20%, rgba(56, 189, 248, 0.32), transparent 62%),
    radial-gradient(520px 260px at 4% 108%, rgba(52, 211, 153, 0.22), transparent 65%),
    linear-gradient(180deg, #e9f7ff 0%, #f7fcff 42%, #ffffff 100%);
  box-shadow:
    0 26px 54px -32px rgba(2, 132, 199, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.xs-card::before {
  content: "";
  position: absolute;
  top: -90px;
  right: -70px;
  width: 260px;
  height: 260px;
  background: radial-gradient(circle, rgba(255, 235, 170, 0.55), rgba(255, 235, 170, 0) 68%);
  animation: xs-breathe 7s ease-in-out infinite;
  pointer-events: none;
}

@keyframes xs-breathe {
  0%, 100% { opacity: 0.55; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.16); }
}

.xs-card::after {
  content: "";
  position: absolute;
  top: -20%;
  left: -60%;
  width: 38%;
  height: 140%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.85), transparent);
  transform: skewX(-16deg);
  animation: xs-sheen 6.5s ease-in-out infinite;
  pointer-events: none;
}

@keyframes xs-sheen {
  0%, 55% { left: -60%; }
  100% { left: 130%; }
}

/* 右侧可选配图：把图命名为 assets/xinshui-photo.jpg 就会自动出现 */
.xs-photo {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 46%;
  height: 100%;
  background: url("xinshui-photo.jpg") right bottom / contain no-repeat;
  opacity: 0.92;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 34%);
  mask-image: linear-gradient(90deg, transparent, #000 34%);
}

/* 上升气泡 */
.xs-deco {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.xs-deco span {
  position: absolute;
  bottom: -14px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 30%, #ffffff, rgba(125, 211, 252, 0.65));
  box-shadow: 0 0 8px rgba(125, 211, 252, 0.9);
  animation: xs-bubble linear infinite;
}

.xs-deco span:nth-child(1) { left: 12%; animation-duration: 9s; animation-delay: 0s; }
.xs-deco span:nth-child(2) { left: 26%; width: 5px; height: 5px; animation-duration: 11s; animation-delay: 1.6s; }
.xs-deco span:nth-child(3) { left: 44%; width: 7px; height: 7px; animation-duration: 10s; animation-delay: 3.2s; }
.xs-deco span:nth-child(4) { left: 62%; width: 4px; height: 4px; animation-duration: 12s; animation-delay: 0.8s; }
.xs-deco span:nth-child(5) { left: 78%; width: 9px; height: 9px; animation-duration: 13s; animation-delay: 2.4s; }
.xs-deco span:nth-child(6) { left: 90%; width: 6px; height: 6px; animation-duration: 9.5s; animation-delay: 4s; }

@keyframes xs-bubble {
  0% { transform: translateY(0) scale(0.8); opacity: 0; }
  12% { opacity: 0.9; }
  85% { opacity: 0.55; }
  100% { transform: translateY(-320px) scale(1.15); opacity: 0; }
}

.xs-top {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.xs-title {
  margin: 0 0 4px;
  font-size: 19px;
  font-weight: 800;
  letter-spacing: 0.04em;
  background: linear-gradient(96deg, #0284c7, #38bdf8 40%, #0ea5e9 70%, #0369a1);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 3px 8px rgba(56, 189, 248, 0.35));
}

/* 标题前的月亮 */
.xs-title::before {
  content: "";
  display: inline-block;
  width: 19px;
  height: 19px;
  margin-right: 9px;
  vertical-align: -3px;
  background: linear-gradient(152deg, #fffef7 0%, #ffe08a 40%, #efa521 100%);
  border-radius: 50%;
  -webkit-mask: radial-gradient(circle at 132% 50%, transparent 60%, #000 61%);
  mask: radial-gradient(circle at 132% 50%, transparent 60%, #000 61%);
  filter: drop-shadow(0 0 7px rgba(250, 204, 90, 0.95));
  transform: rotate(-18deg);
  animation: moon-glow 3.6s ease-in-out infinite;
}

@keyframes moon-glow {
  0%, 100% { filter: drop-shadow(0 0 5px rgba(250, 204, 90, 0.8)); }
  50% { filter: drop-shadow(0 0 13px rgba(255, 228, 140, 1)); }
}

@media (prefers-reduced-motion: reduce) {
  .xs-title::before {
    animation: none !important;
  }
}

.xs-sub {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-left: 19px;
  font-size: 11.5px;
  color: #5b7c95;
}

.xs-sep {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #93c5fd;
}

.xs-refresh {
  position: relative;
  z-index: 2;
  flex: none;
  height: 32px;
  padding: 0 13px;
  border: 1px solid rgba(14, 165, 233, 0.4);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.85);
  color: #0284c7;
  font: inherit;
  font-size: 12.5px;
  cursor: pointer;
  transition: 0.18s ease;
  box-shadow: 0 6px 14px -10px rgba(2, 132, 199, 0.8);
}

.xs-refresh:hover {
  background: #ffffff;
  border-color: #0ea5e9;
  color: #0369a1;
  transform: translateY(-1px);
}

.xs-rows {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.xs-row {
  display: grid;
  grid-template-columns: 96px 1fr 84px;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(186, 230, 253, 0.9);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 8px 18px -16px rgba(2, 132, 199, 0.7);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.xs-row:hover {
  transform: translateY(-1px);
  border-color: rgba(56, 189, 248, 0.85);
  box-shadow: 0 14px 24px -18px rgba(2, 132, 199, 0.85);
}

.xs-rows.animate .xs-row {
  opacity: 0;
  transform: translateY(12px);
  animation: xs-in 0.55s cubic-bezier(0.2, 0.75, 0.3, 1) forwards;
  animation-delay: calc(var(--i, 0) * 90ms);
}

@keyframes xs-in {
  to {
    opacity: 1;
    transform: none;
  }
}

.xs-rows.animate .xs-row .xs-num,
.xs-rows.animate .xs-row .xs-zod {
  animation: xs-pop 0.5s cubic-bezier(0.2, 1.2, 0.35, 1) backwards;
  animation-delay: calc(var(--i, 0) * 90ms + 120ms);
}

@keyframes xs-pop {
  from {
    opacity: 0;
    transform: scale(0.55);
  }
}

.xs-label {
  font-size: 12.5px;
  font-weight: 500;
  color: #3f6683;
  letter-spacing: 0.02em;
}

.xs-pick {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: center;
}

.xs-zod {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(150deg, #fff1c9, #fcd34d 55%, #f59e0b);
  color: #7c4a03;
  font-size: 18px;
  font-weight: 700;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.9), 0 6px 14px -8px rgba(245, 158, 11, 0.95);
}

.xs-num .nb-num {
  --ball: 34px;
}

/* 只有生肖的行：居中放大 */
.xs-row.zods-only {
  grid-template-columns: 96px 1fr 84px;
}

.xs-row.zods-only .xs-zod {
  width: 48px;
  height: 48px;
  font-size: 24px;
  font-weight: 700;
}

.xs-row.zods-only .xs-pick {
  gap: 12px;
}

/* 号码多的行（特主 12 个）：缩小一点排两行 */
.xs-row.many .xs-num .nb-num {
  --ball: 32px;
}

/* 号码多的行：每排 6 个，自动分两排 */
.xs-row.many .xs-pick {
  display: grid;
  grid-template-columns: repeat(6, auto);
  justify-content: center;
  align-items: center;
  gap: 7px 10px;
}

.xs-num .nb-ink {
  font-size: 13px;
}

.xs-side {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding-left: 8px;
  border-left: 1px dashed rgba(148, 197, 224, 0.7);
}

.xs-side-label {
  font-size: 10.5px;
  color: #7a9ab2;
  white-space: nowrap;
}

.xs-side-value {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--digit);
  font-size: 15px;
  font-weight: 700;
  color: #0284c7;
}

.xs-side-value.on {
  color: #16a34a;
  text-shadow: 0 0 10px rgba(22, 163, 74, 0.35);
}

.xs-hit {
  display: inline-block;
  padding: 0 4px;
  border-radius: 4px;
  background: #16a34a;
  color: #fff;
  font-size: 9px;
  font-style: normal;
  line-height: 14px;
  animation: xs-pulse 1.8s ease-in-out infinite;
}

@keyframes xs-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.55); }
  50% { box-shadow: 0 0 0 5px rgba(22, 163, 74, 0); }
}

.xs-empty {
  padding: 26px 8px;
  text-align: center;
  font-size: 13px;
  color: #7a9ab2;
}

@media (max-width: 620px) {
  .xs-card {
    padding: 15px 13px 12px;
  }
  .xs-row {
    grid-template-columns: 76px 1fr 66px;
    gap: 8px;
    padding: 8px 9px;
  }
  .xs-label {
    font-size: 11.5px;
  }
  .xs-zod {
    width: 32px;
    height: 32px;
    font-size: 16px;
  }
  .xs-row.zods-only .xs-zod {
    width: 42px;
    height: 42px;
    font-size: 21px;
  }
  .xs-num .nb-num {
    --ball: 30px;
  }
  .xs-side-value {
    font-size: 13px;
  }
  .xs-photo {
    width: 40%;
    opacity: 0.5;
  }
}

@media (prefers-reduced-motion: reduce) {
  .xs-card::before,
  .xs-card::after,
  .xs-deco span,
  .xs-rows.animate .xs-row,
  .xs-rows.animate .xs-row .xs-num,
  .xs-rows.animate .xs-row .xs-zod,
  .xs-hit {
    animation: none !important;
  }
  .xs-rows.animate .xs-row {
    opacity: 1;
    transform: none;
  }
}
/* 命中：圈起来 + 打勾 */
.xs-zod,
.xs-num {
  position: relative;
}

.xs-zod.hit::after,
.xs-num.hit::after {
  content: "";
  position: absolute;
  inset: -5px;
  border-radius: 50%;
  border: 2px solid #22c55e;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.14), 0 0 16px rgba(34, 197, 94, 0.55);
  animation: xs-ring-in 0.5s cubic-bezier(0.2, 1.5, 0.4, 1) both,
             xs-ring-pulse 2.4s ease-in-out 0.5s infinite;
  pointer-events: none;
}

@keyframes xs-ring-in {
  from { transform: scale(0.35); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

@keyframes xs-ring-pulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.14), 0 0 16px rgba(34, 197, 94, 0.55); }
  50% { box-shadow: 0 0 0 6px rgba(34, 197, 94, 0.05), 0 0 22px rgba(34, 197, 94, 0.8); }
}

.xs-zod.hit::before,
.xs-num.hit::before {
  content: "✓";
  position: absolute;
  top: -7px;
  right: -7px;
  z-index: 3;
  width: 15px;
  height: 15px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(150deg, #4ade80, #16a34a);
  color: #fff;
  font-size: 9px;
  line-height: 1;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(22, 101, 52, 0.45);
  animation: xs-check-in 0.4s cubic-bezier(0.2, 1.6, 0.4, 1) 0.15s both;
}

@keyframes xs-check-in {
  from { transform: scale(0); }
  to { transform: scale(1); }
}

.xs-row.has-hit {
  border-color: rgba(34, 197, 94, 0.55);
  background: linear-gradient(96deg, rgba(240, 253, 244, 0.95), rgba(255, 255, 255, 0.9));
  box-shadow: 0 10px 22px -18px rgba(22, 163, 74, 0.75);
}

@media (prefers-reduced-motion: reduce) {
  .xs-zod.hit::after,
  .xs-num.hit::after,
  .xs-zod.hit::before,
  .xs-num.hit::before {
    animation: none !important;
  }
}

/* ============================================================
   资料图库：分类 / 卡片标题
   ============================================================ */

.cat-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.cat-tab {
  height: 34px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  transition: 0.15s ease;
}

.cat-tab.on {
  background: linear-gradient(135deg, var(--navy), var(--royal));
  border-color: transparent;
  color: #fff;
  font-weight: 600;
}

.g-card {
  display: flex;
  flex-direction: column;
}

.g-card img {
  flex: none;
}

.g-name {
  display: block;
  padding: 8px 9px 2px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.45;
  text-align: left;
  word-break: break-all;
}

.g-meta {
  display: block;
  padding: 0 9px 8px;
  font-family: var(--digit);
  font-size: 11px;
  color: var(--faint);
  text-align: left;
}

.more-wrap {
  display: flex;
  justify-content: center;
  margin: 18px 0 6px;
}

.more-wrap .btn-sm {
  height: 38px;
  padding: 0 26px;
}
/* 资料图库：瀑布流排列（图片高度不一也整齐） */
.gallery {
  display: block;
  column-count: 2;
  column-gap: 12px;
}

@media (min-width: 900px) {
  .gallery {
    column-count: 3;
  }
}

.gallery .g-card {
  display: inline-flex;
  width: 100%;
  margin: 0 0 12px;
  break-inside: avoid;
  -webkit-column-break-inside: avoid;
  page-break-inside: avoid;
}

.gallery-empty {
  column-span: all;
  display: block;
  width: 100%;
}
/* ============================================================
   资料命名
   ============================================================ */

.tg-tip {
  margin: 0 0 12px;
  font-size: 12.5px;
  color: var(--muted);
}

.tg-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

@media (min-width: 900px) {
  .tg-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.tg-item {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fdfbf6;
  overflow: hidden;
}

.tg-item img {
  width: 100%;
  height: auto;
  display: block;
}

.tg-input {
  width: 100%;
  border: 0;
  border-top: 1px solid var(--line);
  padding: 9px 10px;
  font: inherit;
  font-size: 12.5px;
  color: var(--ink);
  background: #fff;
  outline: none;
}

.tg-input:focus {
  background: #fffdf5;
  box-shadow: inset 0 0 0 2px rgba(184, 137, 43, 0.25);
}

.tg-input.saved {
  background: #ecfdf3;
  box-shadow: inset 0 0 0 2px rgba(34, 197, 94, 0.4);
}
/* 空状态：等待更新 */
.waiting {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.waiting i {
  display: inline-block;
  width: 18px;
  text-align: left;
}

.waiting i::after {
  content: "";
  animation: wait-dots 1.6s steps(4, end) infinite;
}

@keyframes wait-dots {
  0% { content: ""; }
  25% { content: "."; }
  50% { content: ".."; }
  75% { content: "..."; }
  100% { content: ""; }
}
/* ============================================================
   首页 Hero：清新渐变 + 光效
   ============================================================ */

.hero {
  position: relative;
  overflow: hidden;
  padding-bottom: 30px;
  background:
    radial-gradient(900px 420px at 15% -10%, rgba(56, 189, 248, 0.55), transparent 62%),
    radial-gradient(760px 380px at 88% 0%, rgba(45, 212, 191, 0.45), transparent 60%),
    radial-gradient(600px 300px at 50% 118%, rgba(129, 140, 248, 0.35), transparent 62%),
    linear-gradient(160deg, #061a3a 0%, #0a2f63 38%, #0b4f8e 68%, #072043 100%);
  background-size: 100% 100%;
  animation: hero-shift 22s ease-in-out infinite alternate;
}

@keyframes hero-shift {
  0% { background-position: 0 0; filter: hue-rotate(0deg); }
  100% { background-position: 0 0; filter: hue-rotate(-8deg); }
}

.hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(214, 178, 104, 0.75), transparent);
  pointer-events: none;
}

.beam {
  position: absolute;
  border-radius: 50%;
  filter: blur(46px);
  opacity: 0.55;
  pointer-events: none;
}

.beam-1 {
  width: 320px;
  height: 320px;
  left: -80px;
  top: -60px;
  background: radial-gradient(circle, rgba(125, 211, 252, 0.85), transparent 68%);
  animation: float-a 14s ease-in-out infinite;
}

.beam-2 {
  width: 380px;
  height: 380px;
  right: -110px;
  bottom: 40px;
  background: radial-gradient(circle, rgba(94, 234, 212, 0.65), transparent 68%);
  animation: float-b 18s ease-in-out infinite;
}

@keyframes float-a {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(40px, 30px) scale(1.12); }
}

@keyframes float-b {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-36px, -26px) scale(1.08); }
}

/* 卡片下方四个入口：玻璃质感，排在卡下面 */
.hero-quick {
  position: relative;
  z-index: 4;
  max-width: 820px;
  margin: 16px auto 0;
  padding: 0 20px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  animation: quick-in 0.7s cubic-bezier(0.2, 0.8, 0.3, 1) both;
}

@keyframes quick-in {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: none; }
}

.hero-quick a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 8px 14px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 16px;
  background: linear-gradient(160deg, rgba(12, 44, 92, 0.55), rgba(8, 30, 66, 0.38));
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 18px 34px -20px rgba(2, 16, 38, 0.95), inset 0 1px 0 rgba(255, 255, 255, 0.16);
  color: #eaf6ff;
  text-shadow: 0 1px 6px rgba(2, 20, 45, 0.6);
  font-size: 13px;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.hero-quick a:hover {
  transform: translateY(-4px) scale(1.02);
  border-color: rgba(214, 178, 104, 0.95);
  background: linear-gradient(160deg, rgba(20, 62, 118, 0.7), rgba(10, 38, 78, 0.5));
  box-shadow: 0 26px 44px -20px rgba(2, 16, 38, 1), 0 0 24px -8px rgba(214, 178, 104, 0.7);
}

.hero-quick .qi {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  font-size: 18px;
  color: #b8892b;
  background: linear-gradient(150deg, #fff6df, #f3dfae);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.main-body {
  padding-top: 26px;
}

@media (max-width: 620px) {
  .hero {
    padding-bottom: 24px;
  }
  .hero-quick {
    margin-top: 12px;
    gap: 8px;
    padding: 0 12px;
  }
  .hero-quick a {
    padding: 12px 4px 11px;
    font-size: 12px;
    border-radius: 13px;
  }
  .hero-quick .qi {
    width: 34px;
    height: 34px;
    font-size: 15px;
  }
}
/* ============================================================
   Hero 特效层
   ============================================================ */

.hero-fx {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  opacity: 0.9;
}

.hero-glow {
  position: absolute;
  left: 50%;
  top: -55%;
  width: 900px;
  height: 900px;
  margin-left: -450px;
  z-index: 0;
  pointer-events: none;
  background: conic-gradient(
    from 0deg,
    rgba(56, 189, 248, 0) 0deg,
    rgba(56, 189, 248, 0.55) 60deg,
    rgba(45, 212, 191, 0.45) 140deg,
    rgba(129, 140, 248, 0.35) 220deg,
    rgba(56, 189, 248, 0) 330deg
  );
  filter: blur(70px);
  opacity: 0.55;
  animation: glow-spin 26s linear infinite;
}

@keyframes glow-spin {
  to { transform: rotate(360deg); }
}

.hero-shine {
  position: absolute;
  top: -30%;
  left: -40%;
  width: 32%;
  height: 160%;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.16), transparent);
  transform: skewX(-14deg);
  animation: hero-shine 9s ease-in-out infinite;
}

@keyframes hero-shine {
  0%, 65% { left: -40%; }
  100% { left: 130%; }
}

.hero-inner {
  position: relative;
  z-index: 2;
}

.draw-card {
  position: relative;
  z-index: 3;
  will-change: transform;
  transition: transform 0.25s ease-out, box-shadow 0.3s ease;
  transform-style: preserve-3d;
  box-shadow:
    0 30px 60px -34px rgba(2, 20, 45, 0.9),
    0 0 0 1px rgba(255, 255, 255, 0.55),
    0 0 42px -18px rgba(125, 211, 252, 0.85);
}

.draw-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.5), transparent 32%);
  opacity: 0.5;
  mix-blend-mode: overlay;
}

.draw-balls .nb-num {
  animation: ball-float 5.5s ease-in-out infinite;
}

.draw-balls .nb-num:nth-child(2) { animation-delay: 0.4s; }
.draw-balls .nb-num:nth-child(3) { animation-delay: 0.8s; }
.draw-balls .nb-num:nth-child(4) { animation-delay: 1.2s; }
.draw-balls .nb-num:nth-child(5) { animation-delay: 1.6s; }
.draw-balls .nb-num:nth-child(6) { animation-delay: 2s; }
.draw-balls .nb-num:nth-child(7) { animation-delay: 2.4s; }

@keyframes ball-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

@media (prefers-reduced-motion: reduce) {
  .hero-glow,
  .hero-shine,
  .draw-balls .nb-num {
    animation: none !important;
  }
}
/* 卡片渐变描边 + 号码光辉 */
.draw-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 5;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    125deg,
    rgba(214, 178, 104, 0.95),
    rgba(125, 211, 252, 0.35) 38%,
    rgba(214, 178, 104, 0.15) 58%,
    rgba(214, 178, 104, 0.9)
  );
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  pointer-events: none;
}

.draw-balls .nb {
  box-shadow:
    0 12px 22px -12px rgba(2, 16, 38, 0.75),
    0 0 18px -6px rgba(125, 211, 252, 0.45);
}

.hero-quick .qi {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 0 18px -4px rgba(214, 178, 104, 0.75);
}

/* 顶部扫光 */
.hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: -30%;
  width: 26%;
  height: 2px;
  z-index: 2;
  background: linear-gradient(90deg, transparent, rgba(214, 178, 104, 0.95), transparent);
  animation: top-scan 7s linear infinite;
  pointer-events: none;
}

@keyframes top-scan {
  0% { left: -30%; }
  100% { left: 110%; }
}
/* 开奖号码下方的生肖：做成凸起的小标签 */
.draw-balls .nb-z {
  display: inline-block;
  margin-top: 6px;
  padding: 3px 11px 4px;
  border-radius: 9px;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1.2;
  color: #2f445e;
  background: linear-gradient(180deg, #ffffff 0%, #f2f6fc 55%, #dfe7f3 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    inset 0 -2px 3px rgba(160, 178, 200, 0.35),
    0 3px 6px rgba(16, 30, 54, 0.22);
  text-shadow: 0 1px 0 #fff;
}

.draw-balls .nb.special .nb-z {
  color: #8a5a08;
  background: linear-gradient(180deg, #fffdf5 0%, #fdf0cf 55%, #f6dfa6 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    inset 0 -2px 3px rgba(190, 150, 60, 0.35),
    0 3px 8px rgba(120, 78, 10, 0.28);
}

/* 开奖记录 / 历史里的生肖也顺手放大一点 */
.feed-balls .nb-z {
  font-size: 13px;
  font-weight: 600;
  color: #3d5069;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.9), 0 2px 3px rgba(18, 32, 56, 0.2);
}

.hist-balls .nb-z {
  font-size: 14px;
  font-weight: 600;
  color: #4a5a72;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.9), 0 2px 3px rgba(18, 32, 56, 0.18);
}

@media (max-width: 620px) {
  .draw-balls .nb-z {
    font-size: 13.5px;
    margin-top: 5px;
    padding: 2px 8px 3px;
  }
  .hist-balls .nb-z {
    font-size: 12.5px;
  }
}
/* ============================================================
   品牌：居中 + 星星特效
   ============================================================ */

.hero .appbar {
  position: relative;
  justify-content: center;
}

.hero .appbar .pill {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
}

.brand.brand-center {
  gap: 9px;
}

.brand.brand-center .brand-name {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #ffffff;
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.35),
    0 2px 10px rgba(2, 20, 45, 0.75),
    0 0 22px rgba(125, 211, 252, 0.55);
}

.star-wrap {
  position: relative;
  width: 26px;
  height: 26px;
  display: inline-grid;
  place-items: center;
  flex: none;
}

.star {
  width: 22px;
  height: 22px;
  display: block;
  background: radial-gradient(circle at 42% 38%, #fffbe6, #ffd873 45%, #f59e0b 100%);
  clip-path: polygon(
    50% 0%, 61% 34%, 98% 35%, 68% 57%,
    79% 91%, 50% 70%, 21% 91%, 32% 57%,
    2% 35%, 39% 34%
  );
  filter: drop-shadow(0 0 8px rgba(255, 208, 102, 0.95));
  animation: star-twinkle 2.4s ease-in-out infinite;
}

@keyframes star-twinkle {
  0%, 100% { transform: scale(1) rotate(0deg); filter: drop-shadow(0 0 6px rgba(255, 208, 102, 0.8)); }
  50% { transform: scale(1.18) rotate(9deg); filter: drop-shadow(0 0 16px rgba(255, 226, 140, 1)); }
}

.spark {
  position: absolute;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #fff6cf;
  box-shadow: 0 0 8px 2px rgba(255, 231, 160, 0.9);
  animation: spark-blink 2.4s ease-in-out infinite;
}

.spark-1 { top: -2px; right: 1px; animation-delay: 0.2s; }
.spark-2 { bottom: 0; left: -3px; animation-delay: 1.1s; }
.spark-3 { top: 6px; right: -4px; width: 2px; height: 2px; animation-delay: 1.8s; }

@keyframes spark-blink {
  0%, 100% { opacity: 0; transform: scale(0.6); }
  40% { opacity: 1; transform: scale(1.25); }
  70% { opacity: 0.25; transform: scale(0.9); }
}

@media (prefers-reduced-motion: reduce) {
  .star,
  .spark {
    animation: none !important;
  }
}
/* ============================================================
   快捷入口：宇宙主题图标
   ============================================================ */

.hero-quick .qi {
  position: relative;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 46%, rgba(26, 62, 118, 0.95), rgba(6, 18, 40, 0.98));
  border: 1px solid rgba(125, 211, 252, 0.32);
  box-shadow:
    inset 0 0 14px rgba(56, 189, 248, 0.28),
    0 0 16px -4px rgba(56, 189, 248, 0.55);
  overflow: hidden;
}

/* 1. 星星 */
.qi-star::before {
  content: "";
  width: 22px;
  height: 22px;
  background: radial-gradient(circle at 44% 38%, #fffdf0, #ffd45e 55%, #f59e0b 100%);
  clip-path: polygon(
    50% 0%, 61% 34%, 98% 35%, 68% 57%,
    79% 91%, 50% 70%, 21% 91%, 32% 57%,
    2% 35%, 39% 34%
  );
  filter: drop-shadow(0 0 8px rgba(255, 214, 110, 0.95));
  animation: qi-twinkle 2.6s ease-in-out infinite;
}

@keyframes qi-twinkle {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 6px rgba(255, 214, 110, 0.8)); }
  50% { transform: scale(1.16) rotate(8deg); filter: drop-shadow(0 0 14px rgba(255, 236, 170, 1)); }
}

/* 2. 黑洞 */
.qi-hole::before {
  content: "";
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    #000 40%,
    #170a33 52%,
    rgba(167, 139, 250, 0.9) 64%,
    rgba(236, 72, 153, 0.6) 72%,
    transparent 78%
  );
  box-shadow: 0 0 16px rgba(167, 139, 250, 0.85);
}

.qi-hole::after {
  content: "";
  position: absolute;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1.5px solid transparent;
  border-top-color: rgba(125, 211, 252, 0.9);
  border-right-color: rgba(236, 72, 153, 0.7);
  animation: qi-spin 3.4s linear infinite;
}

@keyframes qi-spin {
  to { transform: rotate(360deg); }
}

/* 3. 流星 */
.qi-comet::before {
  content: "";
  position: absolute;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  top: 12px;
  left: 22px;
  background: radial-gradient(circle, #ffffff, #bfe6ff 55%, #38bdf8);
  box-shadow: 0 0 12px rgba(147, 222, 255, 0.95);
}

.qi-comet::after {
  content: "";
  position: absolute;
  width: 24px;
  height: 2px;
  top: 16px;
  left: 4px;
  border-radius: 2px;
  background: linear-gradient(90deg, transparent, rgba(191, 230, 255, 0.35), rgba(255, 255, 255, 0.95));
  transform: rotate(-24deg);
  transform-origin: right center;
  animation: qi-comet-drift 2.8s ease-in-out infinite;
}

@keyframes qi-comet-drift {
  0%, 100% { opacity: 0.55; transform: rotate(-24deg) translateX(0); }
  50% { opacity: 1; transform: rotate(-24deg) translateX(3px); }
}

/* 4. 脉冲星 */
.qi-pulse::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: radial-gradient(circle, #ffffff, #a5f3fc 60%, #22d3ee);
  box-shadow: 0 0 12px rgba(34, 211, 238, 0.95);
  animation: qi-pulse-core 2.4s ease-in-out infinite;
}

.qi-pulse::after {
  content: "";
  position: absolute;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1.5px solid rgba(125, 211, 252, 0.85);
  animation: qi-pulse-ring 2.4s ease-out infinite;
}

@keyframes qi-core-pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.2); }
}

@keyframes qi-pulse-core {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.22); }
}

@keyframes qi-pulse-ring {
  0% { transform: scale(0.6); opacity: 0.95; }
  100% { transform: scale(2.3); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .qi-star::before,
  .qi-hole::after,
  .qi-comet::after,
  .qi-pulse::before,
  .qi-pulse::after {
    animation: none !important;
  }
}
/* 心水指标：波色按颜色显示 */
.xs-side-value.v-red {
  color: #e0403a;
  text-shadow: 0 0 10px rgba(224, 64, 58, 0.3);
}

.xs-side-value.v-blue {
  color: #1d6fd0;
  text-shadow: 0 0 10px rgba(29, 111, 208, 0.3);
}

.xs-side-value.v-green {
  color: #17913f;
  text-shadow: 0 0 10px rgba(23, 145, 63, 0.3);
}
/* 心水：标签加重，清晰不糊 */
.xs-label {
  font-size: 14px;
  font-weight: 700;
  color: #0e2a48;
  letter-spacing: 0.02em;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.85);
}

.xs-side-label {
  font-size: 12px;
  font-weight: 600;
  color: #33506e;
  letter-spacing: 0.02em;
  text-shadow: none;
}

@media (max-width: 620px) {
  .xs-label {
    font-size: 13px;
  }
  .xs-side-label {
    font-size: 10.5px;
  }
}
/* 心水右列：标签与数值一起加重 */
.xs-side-label {
  font-size: 12.5px;
  font-weight: 700;
  color: #16375a;
  letter-spacing: 0.02em;
}

.xs-side-value {
  font-size: 16.5px;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.xs-side-value:not(.on):not(.v-red):not(.v-blue):not(.v-green) {
  color: #0b64b0;
}

@media (max-width: 620px) {
  .xs-side-label {
    font-size: 10.5px;
  }
  .xs-side-value {
    font-size: 14px;
  }
}
/* 复式三连肖：换成冷色系，和上面六肖区分开 */
.xs-row.alt .xs-zod {
  background: linear-gradient(150deg, #f2f8ff 0%, #cfe2f7 55%, #93b9e2 100%);
  color: #10355c;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.9),
    0 6px 14px -8px rgba(30, 90, 160, 0.95),
    0 0 16px -6px rgba(125, 211, 252, 0.75);
}

.xs-row.alt {
  background: linear-gradient(96deg, rgba(238, 247, 255, 0.95), rgba(255, 255, 255, 0.9));
  border-color: rgba(147, 197, 253, 0.95);
}
/* ============================================================
   心水：中奖记录
   ============================================================ */

.xs-hist {
  background: linear-gradient(135deg, #0ea5e9, #0284c7) !important;
  border-color: transparent !important;
  color: #fff !important;
  font-weight: 600;
  box-shadow: 0 8px 16px -10px rgba(2, 132, 199, 0.95);
}

.xs-hist:hover {
  filter: brightness(1.08);
}

.xs-modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(6, 16, 32, 0.62);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}

.xs-modal-box {
  width: min(720px, 100%);
  max-height: 78vh;
  display: flex;
  flex-direction: column;
  border-radius: 18px;
  background: #fff;
  overflow: hidden;
  box-shadow: 0 40px 80px -40px rgba(2, 12, 28, 0.95);
}

.xs-modal-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, #f5fbff, #ffffff);
}

.xs-modal-head h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: #0e2a48;
}

.xs-modal-sum {
  margin-left: auto;
  font-size: 12.5px;
  color: #33506e;
}

.xs-modal-sum b {
  color: #0284c7;
  font-size: 14px;
}

.xs-modal-sum i {
  margin: 0 6px;
  font-style: normal;
  color: #a9bdd0;
}

.xs-modal-close {
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 8px;
  background: #eef4fa;
  color: #33506e;
  font-size: 17px;
  line-height: 1;
  cursor: pointer;
}

.xs-modal-close:hover {
  background: #dde9f5;
}

.xs-modal-body {
  padding: 8px 12px 14px;
  overflow-y: auto;
}

.xs-hist-row {
  display: grid;
  grid-template-columns: 96px 48px 74px 1fr 1fr 66px;
  align-items: center;
  gap: 8px;
  padding: 9px 8px;
  border-radius: 10px;
  border-bottom: 1px dashed #eef2f7;
  font-size: 12.5px;
  color: #3c5670;
}

.xs-hist-row.win {
  background: linear-gradient(90deg, rgba(236, 253, 245, 0.9), rgba(255, 255, 255, 0.6));
}

.h-issue {
  font-family: var(--digit);
  font-weight: 600;
  color: #0e2a48;
}

.h-date {
  font-family: var(--digit);
  color: #8aa0b6;
  font-size: 11.5px;
}

.h-main em {
  margin-left: 4px;
  padding: 0 4px;
  border-radius: 4px;
  background: #16a34a;
  color: #fff;
  font-size: 9.5px;
  font-style: normal;
}

.h-main em.no {
  background: #cbd5e1;
  color: #475569;
}

.h-six b,
.h-num b {
  color: #0284c7;
  font-size: 13.5px;
}

.h-special {
  font-family: var(--digit);
  color: #8aa0b6;
  text-align: right;
}

.h-special em {
  margin-left: 3px;
  color: #16a34a;
  font-style: normal;
  font-weight: 700;
}

@media (max-width: 620px) {
  .xs-hist-row {
    grid-template-columns: 84px 56px 1fr 62px;
    row-gap: 4px;
  }
  .h-date,
  .h-special {
    display: none;
  }
  .h-six,
  .h-num {
    font-size: 11.5px;
  }
}
/* 中奖记录：行内标签 + 详情 */
.xs-hist-row {
  width: 100%;
  text-align: left;
  border: 0;
  border-bottom: 1px dashed #eef2f7;
  background: transparent;
  cursor: pointer;
  grid-template-columns: 92px 46px 54px 1fr 52px;
  transition: background 0.15s ease;
}

.xs-hist-row:hover {
  background: #f4faff;
}

.xs-hist-row.win {
  background: linear-gradient(90deg, rgba(236, 253, 245, 0.9), rgba(255, 255, 255, 0.6));
}

.h-main {
  font-weight: 700;
  color: #0e2a48;
}

.h-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.bd {
  display: inline-block;
  padding: 1px 6px;
  border-radius: 5px;
  background: #eef2f7;
  color: #7b8ea3;
  font-size: 10.5px;
  font-weight: 600;
  line-height: 1.5;
}

.bd.win {
  background: linear-gradient(135deg, #34d399, #16a34a);
  color: #fff;
}

.bd.win.gold {
  background: linear-gradient(135deg, #fbbf24, #d97706);
}

.h-more {
  text-align: right;
  color: #8aa0b6;
  font-size: 11.5px;
}

/* 详情 */
.xs-modal.detail .xs-modal-sum {
  display: none;
}

.d-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 4px 12px;
}

.d-back {
  height: 28px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: #33506e;
  font: inherit;
  font-size: 12.5px;
  cursor: pointer;
}

.d-title {
  font-size: 13px;
  font-weight: 700;
  color: #0e2a48;
}

.d-sec {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 4px;
  border-top: 1px dashed #eef2f7;
}

.d-label {
  flex: none;
  width: 76px;
  font-size: 12px;
  font-weight: 600;
  color: #33506e;
}

.d-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.d-draw {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 10px;
}

.d-draw .nb-plus {
  align-self: center;
  margin: 0 2px;
  color: #b8892b;
}

.d-draw .nb-num {
  --ball: 42px;
}

.d-zod {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(150deg, #fff1c9, #fcd34d 55%, #f59e0b);
  color: #7c4a03;
  font-size: 16px;
  font-weight: 700;
  box-shadow: 0 4px 10px -6px rgba(120, 78, 10, 0.9);
}

.d-zod.hit {
  box-shadow: 0 0 0 2px #22c55e, 0 0 12px rgba(34, 197, 94, 0.6);
}

.d-nums .nb-num {
  --ball: 32px;
}

.d-num.hit .nb {
  box-shadow: 0 0 0 2px #22c55e, 0 0 12px rgba(34, 197, 94, 0.55);
}

.d-sum {
  justify-content: flex-end;
}

.d-dim {
  font-size: 12px;
  color: #8aa0b6;
}

@media (max-width: 620px) {
  .xs-hist-row {
    grid-template-columns: 78px 46px 1fr 44px;
  }
  .h-date {
    display: none;
  }
  .d-label {
    width: 62px;
    font-size: 11.5px;
  }
}
/* ============================================================
   右下角：免费开户悬浮按钮 + 开户页
   ============================================================ */

.ad-fab {
  position: fixed;
  right: 18px;
  bottom: 78px;
  z-index: 90;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 46px;
  padding: 0 18px 0 14px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, #f7d488, #d6a043 45%, #b8892b);
  color: #3d2a06;
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  letter-spacing: 0.02em;
  box-shadow:
    0 16px 30px -14px rgba(120, 78, 10, 0.9),
    0 0 0 1px rgba(255, 236, 190, 0.7) inset;
  animation: ad-fab-float 3.4s ease-in-out infinite;
}

.ad-fab::before {
  content: "";
  width: 18px;
  height: 18px;
  flex: none;
  background: radial-gradient(circle at 38% 32%, #fffbe0, #f0b32c 65%, #d97706);
  clip-path: polygon(50% 0%, 61% 34%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 34%);
  filter: drop-shadow(0 0 6px rgba(255, 214, 110, 0.95));
}

.ad-fab:hover {
  filter: brightness(1.06);
  transform: translateY(-2px);
}

@keyframes ad-fab-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

@media (max-width: 620px) {
  .ad-fab {
    right: 12px;
    bottom: 72px;
    height: 42px;
    padding: 0 15px 0 12px;
    font-size: 13px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ad-fab {
    animation: none;
  }
}

/* 开户页 */
.ad-hero {
  padding: 26px 20px 22px;
  border-radius: 18px;
  text-align: center;
  background:
    radial-gradient(420px 180px at 50% -30%, rgba(214, 178, 104, 0.35), transparent 70%),
    linear-gradient(160deg, #0d1c33, #14304f 60%, #0d1c33);
  box-shadow: 0 22px 44px -30px rgba(6, 16, 32, 0.95);
}

.ad-badge {
  display: inline-block;
  padding: 3px 12px;
  border-radius: 99px;
  background: rgba(214, 178, 104, 0.18);
  border: 1px solid rgba(214, 178, 104, 0.5);
  color: #f0cf8e;
  font-size: 11.5px;
  letter-spacing: 0.08em;
}

.ad-title {
  margin: 12px 0 6px;
  font-size: 26px;
  font-weight: 800;
  letter-spacing: 0.06em;
  background: linear-gradient(96deg, #fdf3d6, #f0c46e 45%, #d6a043);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 3px 10px rgba(214, 178, 104, 0.35));
}

.ad-sub {
  margin: 0;
  font-size: 13px;
  color: rgba(233, 240, 252, 0.75);
}

.ad-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0;
}

.ad-step {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 10px 22px -20px rgba(20, 40, 70, 0.7);
}

.ad-n {
  font-family: var(--digit);
  font-size: 12px;
  font-weight: 700;
  color: var(--gold);
}

.ad-step b {
  font-size: 13.5px;
  color: #12304f;
}

.ad-step em {
  font-style: normal;
  font-size: 11.5px;
  color: var(--muted);
  line-height: 1.5;
}

.ad-body {
  margin: 16px 0;
}

.ad-text {
  margin: 0 0 12px;
  font-size: 13.5px;
  line-height: 1.9;
  color: var(--ink);
}

.ad-fig {
  margin: 0 0 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
}

.ad-fig img {
  display: block;
  width: 100%;
  height: auto;
}

.ad-fig figcaption {
  padding: 8px 12px;
  font-size: 12px;
  color: var(--muted);
}

.ad-list {
  margin: 0 0 12px;
  padding-left: 20px;
  font-size: 13.5px;
  line-height: 2;
  color: var(--ink);
}

.ad-actions {
  display: flex;
  gap: 10px;
  margin: 18px 0 10px;
}

.ad-btn {
  flex: 1;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: 0.16s ease;
}

.ad-btn.primary {
  border-color: transparent;
  background: linear-gradient(135deg, #f7d488, #c48f2f);
  color: #3d2a06;
  box-shadow: 0 14px 26px -18px rgba(120, 78, 10, 0.95);
}

.ad-btn:hover {
  transform: translateY(-1px);
}

.ad-note {
  margin: 6px 0 0;
  font-size: 11.5px;
  color: var(--faint);
  text-align: center;
}

@media (max-width: 620px) {
  .ad-steps {
    grid-template-columns: 1fr;
  }
  .ad-title {
    font-size: 22px;
  }
}
/* 开户页：去掉内容块时不留空隙 */
.ad-sub:empty,
.ad-note:empty {
  display: none;
}

.ad-steps:empty,
.ad-body:empty,
.ad-actions:empty {
  display: none;
}

.ad-hero .ad-title {
  margin-top: 12px;
}
/* 资料页：期号 chip 上的「今日」标记 */
.chip.today em {
  display: inline-block;
  margin-left: 5px;
  padding: 0 4px;
  border-radius: 4px;
  background: rgba(214, 178, 104, 0.22);
  color: var(--gold);
  font-size: 9.5px;
  font-style: normal;
  line-height: 1.5;
  vertical-align: 1px;
}

.chip.today.on em {
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
}
/* 历史记录：日期查询提示（跟在日期框旁边） */
.date-tip {
  flex: 1;
  min-width: 0;
  margin: 0;
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.date-row .date-input {
  flex: 0 0 auto;
  width: 168px;
}

@media (max-width: 560px) {
  .date-tip {
    display: none;
  }
  .date-row .date-input {
    flex: 1;
    width: auto;
  }
}

.date-tip em {
  font-style: normal;
  color: var(--gold);
}
/* ============================================================
   星空心水：极简头部 + 底部记录条
   ============================================================ */

.xs-icon-btn {
  flex: none;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(14, 165, 233, 0.28);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.8);
  color: #5b8bab;
  font: inherit;
  font-size: 15px;
  line-height: 1;
  cursor: pointer;
  transition: 0.16s ease;
}

.xs-icon-btn:hover {
  border-color: rgba(14, 165, 233, 0.6);
  color: #0284c7;
  background: #fff;
  transform: rotate(-40deg);
}

.xs-icon-btn:active {
  transform: rotate(-160deg);
}

/* 底部：中奖记录入口 */
.xs-record-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  height: 46px;
  margin-top: 14px;
  padding: 0 14px;
  border: 0;
  border-radius: 13px;
  background: linear-gradient(120deg, #0e2a48 0%, #124a7c 45%, #0d3a63 100%);
  color: #eaf6ff;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  box-shadow:
    0 12px 24px -16px rgba(4, 24, 48, 0.95),
    inset 0 1px 0 rgba(255, 255, 255, 0.14);
  transition: 0.18s ease;
}

.xs-record-bar .rb-star {
  width: 16px;
  height: 16px;
  flex: none;
  background: radial-gradient(circle at 40% 35%, #fffbe6, #ffd873 60%, #f59e0b);
  clip-path: polygon(
    50% 0%, 61% 34%, 98% 35%, 68% 57%,
    79% 91%, 50% 70%, 21% 91%, 32% 57%,
    2% 35%, 39% 34%
  );
  filter: drop-shadow(0 0 6px rgba(255, 214, 110, 0.9));
}

.xs-record-bar em {
  margin-left: auto;
  font-style: normal;
  font-size: 12px;
  font-weight: 500;
  color: #f0cf8e;
}

.xs-record-bar i {
  font-style: normal;
  font-size: 17px;
  color: rgba(255, 255, 255, 0.65);
}

.xs-record-bar:hover {
  transform: translateY(-1px);
  box-shadow:
    0 16px 30px -16px rgba(4, 24, 48, 1),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
}

/* 免费开户：缩小一点，避免和内容挤在一起 */
.ad-fab {
  right: 16px;
  bottom: 86px;
  height: 42px;
  padding: 0 15px 0 12px;
  font-size: 13px;
  box-shadow: 0 12px 24px -16px rgba(120, 78, 10, 0.9);
}

.ad-fab::before {
  width: 15px;
  height: 15px;
}

@media (max-width: 620px) {
  .ad-fab {
    right: 12px;
    bottom: 80px;
  }
}
/* ============================================================
   星空卜卦
   ============================================================ */

.gua-stage {
  position: relative;
  padding: 26px 18px 22px;
  border-radius: 18px;
  text-align: center;
  background:
    radial-gradient(520px 240px at 50% -20%, rgba(214, 178, 104, 0.28), transparent 70%),
    linear-gradient(165deg, #0b1d36, #14304f 55%, #0b1d36);
  box-shadow: 0 24px 48px -32px rgba(6, 16, 32, 0.95);
}

.gua-coins {
  display: flex;
  justify-content: center;
  gap: 18px;
  perspective: 800px;
  margin-bottom: 18px;
}

.coin {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  transform-style: preserve-3d;
  background:
    radial-gradient(circle at 34% 30%, #fff3c8, #e3b455 48%, #a9781f 100%);
  box-shadow:
    inset 0 0 0 3px rgba(255, 240, 200, 0.55),
    inset 0 -6px 10px rgba(120, 78, 10, 0.55),
    0 10px 20px -12px rgba(0, 0, 0, 0.9);
  transition: transform 0.6s cubic-bezier(0.3, 1.4, 0.4, 1);
}

.coin::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  border-radius: 3px;
  border: 2px solid rgba(120, 78, 10, 0.55);
  background: rgba(15, 34, 63, 0.9);
}

.coin {
  position: relative;
}

.coin .coin-face {
  position: relative;
  z-index: 2;
  font-size: 20px;
  font-weight: 700;
  color: #5a3d05;
  text-shadow: 0 1px 0 rgba(255, 246, 210, 0.9);
}

.coin .coin-face.back {
  color: #7a4a05;
  opacity: 0.75;
}

.coin.flip {
  animation: coin-spin 0.62s ease-in-out;
}

@keyframes coin-spin {
  0% { transform: rotateY(0) translateY(0); }
  40% { transform: rotateY(540deg) translateY(-18px); }
  100% { transform: rotateY(1080deg) translateY(0); }
}

.gua-hint {
  min-height: 20px;
  margin-bottom: 14px;
  font-size: 13px;
  color: rgba(233, 240, 252, 0.78);
}

.gua-progress {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 16px;
  font-size: 12px;
  color: rgba(233, 240, 252, 0.6);
}

.gua-dots {
  display: flex;
  gap: 5px;
}

.gua-dots i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  transition: 0.2s ease;
}

.gua-dots i.on {
  background: linear-gradient(150deg, #ffe9a8, #d6a043);
  box-shadow: 0 0 8px rgba(214, 178, 104, 0.9);
}

.gua-btn {
  height: 46px;
  padding: 0 34px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, #f7d488, #d6a043 50%, #b8892b);
  color: #3d2a06;
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.12em;
  cursor: pointer;
  box-shadow: 0 16px 28px -18px rgba(120, 78, 10, 0.95);
  transition: 0.16s ease;
}

.gua-btn:hover {
  filter: brightness(1.06);
  transform: translateY(-1px);
}

.gua-btn:disabled {
  opacity: 0.55;
  cursor: default;
  transform: none;
}

.gua-btn.ghost {
  margin-left: 8px;
  height: 40px;
  padding: 0 20px;
  background: transparent;
  border: 1px solid rgba(214, 178, 104, 0.55);
  color: #e9c98a;
  font-size: 13px;
  letter-spacing: 0.06em;
  box-shadow: none;
}

.gua-panel {
  margin-top: 16px;
  padding: 20px 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 16px 34px -30px rgba(20, 40, 70, 0.8);
}

.gua-lines {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 9px;
  margin-bottom: 18px;
}

.gua-line {
  display: grid;
  grid-template-columns: 1fr 22px 1fr;
  align-items: center;
  width: 168px;
  height: 11px;
  animation: gua-line-in 0.4s ease both;
}

.gua-line .gua-seg:first-child {
  grid-column: 1;
}

.gua-line .gua-gap {
  grid-column: 2;
}

.gua-line .gua-seg:last-child {
  grid-column: 3;
}

.gua-line.yang .gua-seg:first-child {
  grid-column: 1 / -1;
}

@keyframes gua-line-in {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: none; }
}

.gua-line .gua-seg {
  display: block;
  width: 100%;
  height: 11px;
  border-radius: 3px;
  background: linear-gradient(180deg, #4a5a72, #22324a);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25);
}



.gua-line.moving .gua-seg {
  background: linear-gradient(180deg, #e8a33c, #b8892b);
  box-shadow: 0 0 10px rgba(214, 178, 104, 0.8);
}

.gua-result {
  text-align: center;
}

.gua-name {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 8px;
}

.gua-name span {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #0e2a48;
}

.gua-name em {
  padding: 2px 9px;
  border-radius: 6px;
  font-size: 11.5px;
  font-style: normal;
  font-weight: 600;
  color: #fff;
  background: #64748b;
}

.gua-name em.lv-1 { background: linear-gradient(135deg, #f0b429, #d97706); }
.gua-name em.lv-2 { background: linear-gradient(135deg, #34d399, #16a34a); }
.gua-name em.lv-3 { background: linear-gradient(135deg, #38bdf8, #0284c7); }
.gua-name em.lv-4 { background: linear-gradient(135deg, #94a3b8, #64748b); }
.gua-name em.lv-5 { background: linear-gradient(135deg, #fb923c, #ea580c); }
.gua-name em.lv-6 { background: linear-gradient(135deg, #f87171, #dc2626); }

.gua-text {
  margin: 0 0 10px;
  font-size: 14.5px;
  color: #23405f;
  line-height: 1.8;
}

.gua-sub {
  margin-bottom: 12px;
  font-size: 12px;
  color: var(--muted);
}

.gua-bian {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  padding-top: 12px;
  border-top: 1px dashed var(--line);
  font-size: 12.5px;
  color: var(--muted);
}

.bian-tag {
  padding: 2px 8px;
  border-radius: 5px;
  background: rgba(214, 178, 104, 0.16);
  color: var(--gold);
  font-size: 11.5px;
  font-weight: 600;
}

.bian-arrow {
  color: #b8892b;
}

.gua-bian b {
  color: #0e2a48;
}

@media (max-width: 620px) {
  .coin {
    width: 54px;
    height: 54px;
  }
  .coin .coin-face {
    font-size: 17px;
  }
  .gua-btn {
    padding: 0 26px;
    font-size: 14px;
  }
  .gua-line {
    width: 140px;
  }
}
/* ============================================================
   卜卦：时空隧道开场
   ============================================================ */

.gua-body {
  background: var(--bg);
}

.intro {
  position: fixed;
  inset: 0;
  z-index: 999;
  overflow: hidden;
  background:
    radial-gradient(680px 520px at 22% 18%, rgba(96, 74, 168, 0.32), transparent 62%),
    radial-gradient(760px 560px at 78% 82%, rgba(24, 92, 148, 0.34), transparent 64%),
    radial-gradient(520px 420px at 62% 26%, rgba(168, 122, 52, 0.18), transparent 66%),
    radial-gradient(circle at 50% 50%, #0b1730 0%, #050a16 55%, #02040a 100%);
}

.intro-canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.intro-title {
  position: absolute;
  left: 0;
  right: 0;
  top: 66%;
  transform: translateY(-50%);
  text-align: center;
  pointer-events: none;
  animation: intro-title-in 1.4s ease 0.3s both;
}

.intro-title::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 320px;
  height: 130px;
  transform: translate(-50%, -50%);
  background: radial-gradient(ellipse at center, rgba(36, 14, 0, 0.5), rgba(36, 14, 0, 0) 72%);
  z-index: -1;
  pointer-events: none;
}

.intro-title .it-line {
  display: block;
  font-size: 15px;
  font-weight: 400;
  letter-spacing: 0.58em;
  text-indent: 0.58em;
  color: #fffdf8;
  text-shadow: 0 1px 6px rgba(45, 16, 0, 0.85);
}

.intro-title .it-rule {
  display: block;
  width: 44px;
  height: 1px;
  margin: 13px auto 11px;
  background: linear-gradient(90deg, transparent, rgba(255, 228, 168, 0.95), transparent);
}

.intro-title em {
  display: block;
  margin: 0;
  font-size: 10.5px;
  font-style: normal;
  letter-spacing: 0.5em;
  text-indent: 0.5em;
  color: rgba(255, 242, 218, 0.62);
  text-shadow: 0 1px 4px rgba(45, 16, 0, 0.9);
}

@keyframes intro-title-in {
  from { opacity: 0; transform: translateY(-50%) scale(0.86); filter: blur(8px); }
  to { opacity: 1; transform: translateY(-50%) scale(1); filter: blur(0); }
}

.intro-skip {
  position: absolute;
  right: 18px;
  top: 18px;
  height: 32px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.8);
  font: inherit;
  font-size: 12.5px;
  cursor: pointer;
  backdrop-filter: blur(6px);
}

.intro-skip:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}

.intro.out {
  animation: intro-out 0.65s ease forwards;
}

@keyframes intro-out {
  to { opacity: 0; transform: scale(1.25); filter: blur(10px); }
}

/* 主页面：开场结束后淡入 */
.gua-page {
  opacity: 0;
  transform: scale(0.98);
  transition: opacity 0.6s ease, transform 0.6s ease;
  background: var(--bg);
  min-height: 100vh;
}

.gua-page.show {
  opacity: 1;
  transform: none;
}

/* 铜钱图标（底部导航） */
.coin-icon {
  animation: coin-breathe 2.8s ease-in-out infinite;
  transform-origin: center;
}

@keyframes coin-breathe {
  0%, 100% { transform: rotate(0deg) scale(1); }
  50% { transform: rotate(14deg) scale(1.08); }
}

@media (prefers-reduced-motion: reduce) {
  .coin-icon {
    animation: none;
  }
}

/* 卜卦页：收起旧内容后的样式微调 */
.gua-stage {
  margin-top: 6px;
}

.gua-again {
  display: block;
  width: 100%;
  height: 42px;
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}

.gua-again:hover {
  border-color: var(--gold-soft);
  color: var(--gold);
}
/* 开场暗角：聚焦画面中心 */
.intro::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(
    ellipse at 50% 50%,
    rgba(0, 0, 0, 0) 38%,
    rgba(0, 0, 0, 0.35) 72%,
    rgba(0, 0, 0, 0.72) 100%
  );
}

/* 压暗 + 中心留亮，让标题更清楚 */
.intro-veil {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 50% 50%, rgba(0, 0, 0, 0) 30%, rgba(0, 0, 0, 0.35) 72%, rgba(0, 0, 0, 0.7) 100%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.35) 0%, rgba(0, 0, 0, 0) 22%, rgba(0, 0, 0, 0) 74%, rgba(0, 0, 0, 0.45) 100%);
}
/* ============================================================
   卜卦：问答式
   ============================================================ */

.qa-wrap {
  padding-bottom: 40px;
}

.qa {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 60vh;
}

.qa-log {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.qa-msg {
  max-width: 88%;
  padding: 13px 16px;
  border-radius: 16px;
  font-size: 14.5px;
  line-height: 1.85;
  animation: qa-in 0.32s ease both;
}

@keyframes qa-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

.qa-msg.bot {
  align-self: flex-start;
  background: #fff;
  border: 1px solid var(--line);
  color: #22374f;
  border-bottom-left-radius: 6px;
  box-shadow: 0 8px 20px -18px rgba(20, 40, 70, 0.8);
}

.qa-msg.bot small {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  color: var(--muted);
}

.qa-msg.me {
  align-self: flex-end;
  background: linear-gradient(135deg, #14416d, #0f2c4c);
  color: #eaf4ff;
  border-bottom-right-radius: 6px;
  box-shadow: 0 10px 20px -18px rgba(4, 24, 48, 0.9);
}

/* 输入区 */
.qa-dock {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: flex-end;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 12px 26px -24px rgba(20, 40, 70, 0.9);
}

.qa-dock:empty {
  display: none;
}

.qa-field {
  flex: 1 1 200px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.qa-field span {
  font-size: 12px;
  color: var(--muted);
}

.qa-field input,
.qa-text {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fbf8f1;
  font: inherit;
  font-size: 14px;
  color: var(--ink);
  outline: none;
  transition: 0.16s ease;
}

.qa-field input:focus,
.qa-text:focus {
  border-color: var(--gold-soft);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(214, 178, 104, 0.16);
}

.qa-text {
  flex: 1 1 100%;
  resize: none;
  line-height: 1.6;
}

.qa-row {
  display: flex;
  gap: 10px;
  width: 100%;
  justify-content: flex-end;
}

.qa-next {
  height: 42px;
  padding: 0 22px;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, #f7d488, #d6a043 55%, #b8892b);
  color: #3d2a06;
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 12px 22px -16px rgba(120, 78, 10, 0.9);
  transition: 0.16s ease;
}

.qa-next:hover {
  filter: brightness(1.05);
  transform: translateY(-1px);
}

.qa-ghost {
  height: 42px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-size: 13.5px;
  cursor: pointer;
}

.qa-ghost:hover {
  border-color: var(--gold-soft);
  color: var(--gold);
}

.shake {
  animation: qa-shake 0.36s ease;
}

@keyframes qa-shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

/* 起卦过程 */
.qa-toss {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 18px 22px;
  background: linear-gradient(165deg, #0b1d36, #14304f 60%, #0b1d36);
  border: 0;
  color: #dce9f8;
}

.toss-hex {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  min-height: 108px;
  justify-content: flex-end;
}

.toss-tip {
  font-size: 12.5px;
  color: rgba(226, 238, 252, 0.75);
  letter-spacing: 0.05em;
}

/* 结果卡片 */
.qa-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 16px 8px 6px;
}

.card-hex {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.card-name {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 21px;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: #0e2a48;
}

.card-name em {
  padding: 2px 9px;
  border-radius: 6px;
  font-size: 11.5px;
  font-style: normal;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(135deg, #34d399, #16a34a);
}

.card-text {
  margin: 2px 0 0;
  font-size: 14.5px;
  color: #23405f;
  text-align: center;
}

.card-sub {
  font-size: 12px;
  color: var(--muted);
}

.card-bian {
  margin-top: 8px;
  padding-top: 10px;
  border-top: 1px dashed var(--line);
  width: 100%;
  text-align: center;
  font-size: 12.5px;
  color: var(--muted);
}

.card-bian span {
  display: inline-block;
  margin-right: 6px;
  padding: 1px 8px;
  border-radius: 5px;
  background: rgba(214, 178, 104, 0.16);
  color: var(--gold);
  font-size: 11.5px;
  font-weight: 600;
}

.qa-p {
  margin: 10px 0 0;
  font-size: 14.5px;
  line-height: 1.95;
  color: #22374f;
}

.qa-p.qa-end {
  margin-top: 14px;
  text-align: right;
  font-size: 13px;
  color: var(--muted);
}

.qa-again {
  display: block;
  width: 100%;
  height: 42px;
  margin-top: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fbf8f1;
  color: var(--gold);
  font: inherit;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
}

.qa-again:hover {
  background: #fff;
  border-color: var(--gold-soft);
}

@media (max-width: 620px) {
  .qa-msg {
    max-width: 94%;
    font-size: 14px;
  }
  .card-name {
    font-size: 19px;
  }
}
/* 卦象吉凶等级配色 */
.card-name em.lv1 { background: linear-gradient(135deg, #f0b429, #d97706); }
.card-name em.lv2 { background: linear-gradient(135deg, #34d399, #16a34a); }
.card-name em.lv3 { background: linear-gradient(135deg, #38bdf8, #0284c7); }
.card-name em.lv4 { background: linear-gradient(135deg, #9aa6b5, #64748b); }
.card-name em.lv5 { background: linear-gradient(135deg, #fb923c, #ea580c); }
.card-name em.lv6 { background: linear-gradient(135deg, #f87171, #dc2626); }
/* ============================================================
   卜卦：星空悬浮问答
   ============================================================ */

.gua-body {
  background: #05070d;
}

.gua-ui {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  opacity: 0;
  transition: opacity 0.7s ease;
}

.gua-ui.show {
  opacity: 1;
}

.gua-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  color: rgba(235, 243, 255, 0.92);
}

.gua-back {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.06);
  color: rgba(235, 243, 255, 0.9);
  text-decoration: none;
  font-size: 15px;
  backdrop-filter: blur(6px);
}

.gua-brand {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.06em;
}

.gua-tag {
  margin-left: auto;
  padding: 3px 10px;
  border-radius: 99px;
  border: 1px solid rgba(214, 178, 104, 0.45);
  background: rgba(214, 178, 104, 0.12);
  color: #efd39a;
  font-size: 11.5px;
  letter-spacing: 0.06em;
}

.gua-stage {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 10px 18px 26px;
}

.gua-note {
  margin: 0 0 22px;
  text-align: center;
  font-size: 11.5px;
  color: rgba(206, 220, 240, 0.42);
}

/* 问卦面板 */
.ask {
  width: 100%;
  max-width: 420px;
  padding: 26px 22px 22px;
  border-radius: 22px;
  border: 1px solid rgba(214, 178, 104, 0.22);
  background: linear-gradient(165deg, rgba(16, 28, 48, 0.82), rgba(9, 16, 30, 0.88));
  box-shadow:
    0 30px 60px -34px rgba(0, 0, 0, 0.95),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(14px);
  text-align: center;
  animation: ask-in 0.5s ease both;
}

@keyframes ask-in {
  from { opacity: 0; transform: translateY(14px) scale(0.98); }
  to { opacity: 1; transform: none; }
}

.ask.shake {
  animation: ask-shake 0.4s ease;
}

@keyframes ask-shake {
  0%, 100% { transform: translateX(0); }
  22% { transform: translateX(-6px); }
  65% { transform: translateX(6px); }
}

.ask-q {
  margin: 0 0 6px;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #f3f7ff;
}

.ask-sub {
  margin: 0 0 20px;
  font-size: 12.5px;
  color: rgba(200, 216, 238, 0.55);
}

/* 年月日输入 */
.dt {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-bottom: 22px;
}

.dt span {
  font-size: 13px;
  color: rgba(214, 226, 244, 0.55);
}

.dt-in {
  width: 62px;
  height: 50px;
  border: 1px solid rgba(214, 178, 104, 0.28);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  color: #fff8e6;
  font: inherit;
  font-size: 19px;
  font-weight: 600;
  text-align: center;
  letter-spacing: 0.04em;
  outline: none;
  transition: 0.16s ease;
}

.dt-in::placeholder {
  color: rgba(214, 226, 244, 0.28);
  font-weight: 400;
  font-size: 15px;
}

.dt-in:focus {
  border-color: rgba(214, 178, 104, 0.85);
  background: rgba(214, 178, 104, 0.1);
  box-shadow: 0 0 0 3px rgba(214, 178, 104, 0.14);
}

.dt-in.bad {
  border-color: rgba(248, 113, 113, 0.8);
  animation: ask-shake 0.34s ease;
}

.dt-in:nth-of-type(1) {
  width: 84px;
}

.line-in {
  width: 100%;
  height: 50px;
  padding: 0 16px;
  margin-bottom: 18px;
  border: 1px solid rgba(214, 178, 104, 0.28);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  color: #f4f8ff;
  font: inherit;
  font-size: 15px;
  outline: none;
  transition: 0.16s ease;
}

.line-in::placeholder {
  color: rgba(214, 226, 244, 0.3);
}

.line-in:focus {
  border-color: rgba(214, 178, 104, 0.85);
  background: rgba(214, 178, 104, 0.1);
}

.go {
  width: 100%;
  height: 50px;
  border: 0;
  border-radius: 13px;
  background: linear-gradient(135deg, #f7d488, #d6a043 52%, #b8892b);
  color: #3d2a06;
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.16em;
  cursor: pointer;
  box-shadow: 0 18px 30px -22px rgba(180, 120, 30, 0.95);
  transition: 0.16s ease;
}

.go:hover {
  filter: brightness(1.06);
  transform: translateY(-1px);
}

.ask-row {
  display: flex;
  gap: 10px;
}

.ask-row .go {
  flex: 1;
}

.skip {
  flex: 0 0 92px;
  height: 50px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.05);
  color: rgba(214, 226, 244, 0.7);
  font: inherit;
  font-size: 13.5px;
  cursor: pointer;
}

.skip:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.32);
}

/* 起卦 */
.toss-hex {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 9px;
  min-height: 128px;
  justify-content: flex-end;
  margin: 12px 0 10px;
}

.toss-hex .gua-line {
  width: 150px;
}

.toss-hex .gua-seg {
  background: linear-gradient(180deg, #eaf5ff, #9fc4ea);
  box-shadow: 0 0 10px rgba(160, 210, 255, 0.4);
}

.toss-hex .gua-line.moving .gua-seg {
  background: linear-gradient(180deg, #ffe2a0, #d6a043);
  box-shadow: 0 0 14px rgba(214, 178, 104, 0.8);
}

.toss-tip {
  margin: 0;
  font-size: 12.5px;
  color: rgba(214, 228, 246, 0.6);
  letter-spacing: 0.08em;
}

/* 结果 */
.res {
  width: 100%;
  max-width: 520px;
  padding: 24px 22px 20px;
  border-radius: 22px;
  border: 1px solid rgba(214, 178, 104, 0.22);
  background: linear-gradient(165deg, rgba(14, 26, 44, 0.86), rgba(8, 14, 26, 0.9));
  box-shadow: 0 30px 60px -34px rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(14px);
  text-align: center;
  animation: ask-in 0.55s ease both;
}

.res-hex {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 9px;
  margin-bottom: 14px;
}

.res-hex .gua-line {
  width: 160px;
}

.res-hex .gua-seg {
  background: linear-gradient(180deg, #eef7ff, #a8c8ea);
  box-shadow: 0 0 12px rgba(150, 200, 255, 0.35);
}

.res-hex .gua-line.moving .gua-seg {
  background: linear-gradient(180deg, #ffe6ae, #d6a043);
  box-shadow: 0 0 16px rgba(214, 178, 104, 0.85);
}

.res-name {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 23px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #fdf6e6;
}

.res-name em {
  padding: 3px 10px;
  border-radius: 7px;
  font-size: 11.5px;
  font-style: normal;
  font-weight: 600;
  color: #fff;
}

.res-name em.lv1 { background: linear-gradient(135deg, #f0b429, #d97706); }
.res-name em.lv2 { background: linear-gradient(135deg, #34d399, #16a34a); }
.res-name em.lv3 { background: linear-gradient(135deg, #38bdf8, #0284c7); }
.res-name em.lv4 { background: linear-gradient(135deg, #94a3b8, #64748b); }
.res-name em.lv5 { background: linear-gradient(135deg, #fb923c, #ea580c); }
.res-name em.lv6 { background: linear-gradient(135deg, #f87171, #dc2626); }

.res-text {
  margin: 8px 0 4px;
  font-size: 15px;
  color: #dbe9fb;
}

.res-sub,
.res-bian {
  margin: 4px 0;
  font-size: 12px;
  color: rgba(206, 222, 244, 0.5);
}

.res-bian {
  padding-bottom: 14px;
  border-bottom: 1px dashed rgba(214, 178, 104, 0.22);
}

.res-body {
  text-align: left;
}

.res-body p {
  margin: 14px 0 0;
  font-size: 14px;
  line-height: 2;
  color: rgba(224, 236, 251, 0.88);
}

.res-end {
  margin: 18px 0 0;
  text-align: right;
  font-size: 12.5px;
  color: rgba(206, 222, 244, 0.45);
}

.again {
  width: 100%;
  height: 46px;
  margin-top: 16px;
  border: 1px solid rgba(214, 178, 104, 0.35);
  border-radius: 13px;
  background: rgba(214, 178, 104, 0.08);
  color: #efd39a;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.08em;
  cursor: pointer;
}

.again:hover {
  background: rgba(214, 178, 104, 0.16);
}

/* 开场结束后，星空继续作为背景 */
.intro.done {
  opacity: 1;
  z-index: 0;
}

.intro.done .intro-canvas {
  opacity: 0.8;
  transition: opacity 1.2s ease;
}

.intro.done .intro-title,
.intro.done .intro-skip {
  display: none;
}

.intro.done .intro-veil {
  background: radial-gradient(ellipse at 50% 45%, rgba(4, 8, 18, 0.28) 0%, rgba(3, 6, 12, 0.66) 72%, rgba(2, 4, 8, 0.86) 100%);
}

@media (max-width: 620px) {
  .ask {
    padding: 22px 16px 18px;
  }
  .ask-q {
    font-size: 16px;
  }
  .dt-in {
    width: 54px;
    font-size: 17px;
  }
  .dt-in:nth-of-type(1) {
    width: 72px;
  }
  .res-name {
    font-size: 20px;
  }
}
/* ============================================================
   卜卦：三张牌 + 今日六肖号码
   ============================================================ */

.pick {
  width: 100%;
  max-width: 520px;
  margin: 22px auto 0;
  padding: 22px 20px;
  border-radius: 22px;
  border: 1px solid rgba(214, 178, 104, 0.22);
  background: linear-gradient(165deg, rgba(14, 26, 44, 0.86), rgba(8, 14, 26, 0.9));
  box-shadow: 0 30px 60px -34px rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(14px);
  text-align: center;
  animation: ask-in 0.5s ease both;
}

.pick-q {
  margin: 0 0 4px;
  font-size: 16px;
  font-weight: 600;
  color: #f3f7ff;
}

.pick-sub {
  margin: 0 0 18px;
  font-size: 12px;
  color: rgba(200, 216, 238, 0.5);
}

.pick-row {
  display: flex;
  justify-content: center;
  gap: 12px;
}

.pcard {
  position: relative;
  width: 82px;
  height: 118px;
  border: 1px solid rgba(214, 178, 104, 0.5);
  border-radius: 12px;
  background: linear-gradient(160deg, #16273f, #0b1524 60%, #16273f);
  color: #efd39a;
  font: inherit;
  cursor: pointer;
  transition: transform 0.4s cubic-bezier(0.3, 1.3, 0.4, 1), box-shadow 0.3s ease;
  box-shadow: 0 14px 26px -20px rgba(0, 0, 0, 0.9), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.pcard::before {
  content: "";
  position: absolute;
  inset: 6px;
  border: 1px solid rgba(214, 178, 104, 0.28);
  border-radius: 8px;
  pointer-events: none;
}

.pcard .pc-back {
  display: block;
  font-size: 26px;
  line-height: 118px;
  opacity: 0.75;
  transition: opacity 0.2s ease;
}

.pcard .pc-face {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.06em;
  opacity: 0;
  transition: opacity 0.3s ease 0.25s;
}

.pcard:hover:not(.flip) {
  transform: translateY(-4px);
  box-shadow: 0 20px 34px -22px rgba(0, 0, 0, 1), inset 0 1px 0 rgba(255, 255, 255, 0.14);
}

.pick.done .pcard:not(.flip) {
  opacity: 0.32;
  transform: scale(0.94);
}

.pcard.flip {
  transform: scale(1.06);
}

.pcard.flip .pc-back {
  opacity: 0;
}

.pcard.flip .pc-face {
  opacity: 1;
}

.pcard.flip.good {
  border-color: rgba(52, 211, 153, 0.8);
  box-shadow: 0 0 26px rgba(52, 211, 153, 0.45), inset 0 0 24px rgba(52, 211, 153, 0.16);
}

.pcard.flip.good .pc-face {
  color: #8ef0c2;
  text-shadow: 0 0 18px rgba(52, 211, 153, 0.9);
}

.pcard.flip.bad {
  border-color: rgba(248, 113, 113, 0.8);
  box-shadow: 0 0 26px rgba(248, 113, 113, 0.4), inset 0 0 24px rgba(248, 113, 113, 0.16);
}

.pcard.flip.bad .pc-face {
  color: #ff9d9d;
  text-shadow: 0 0 18px rgba(248, 113, 113, 0.9);
}

/* 结果 */
.pick-out {
  margin-top: 18px;
}

.fortune {
  padding: 16px 14px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  animation: ask-in 0.5s ease both;
}

.ft-luck {
  margin: 0 0 12px;
  font-size: 13px;
  color: rgba(214, 226, 244, 0.6);
}

.ft-luck b {
  font-size: 17px;
  color: #fff;
  letter-spacing: 0.08em;
}

.fortune.is-good .ft-luck b { color: #8ef0c2; }
.fortune.is-bad .ft-luck b { color: #ff9d9d; }

.ft-label {
  margin: 14px 0 8px;
  font-size: 11.5px;
  letter-spacing: 0.16em;
  color: rgba(214, 226, 244, 0.45);
}

.ft-zods {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.ft-zod {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid rgba(214, 178, 104, 0.55);
  background: radial-gradient(circle at 36% 30%, rgba(255, 236, 190, 0.28), rgba(214, 178, 104, 0.1));
  color: #ffe9bd;
  font-size: 16px;
  font-weight: 700;
}

.ft-nums {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 7px;
}

.ft-num {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(160deg, #1d3355, #10203a);
  border: 1px solid rgba(150, 200, 255, 0.28);
  color: #dcecff;
  font-size: 13.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.ft-num.sp {
  background: linear-gradient(160deg, #f7d488, #b8892b);
  border-color: rgba(255, 226, 160, 0.9);
  color: #3d2a06;
}

.ft-plus {
  color: rgba(214, 226, 244, 0.4);
  font-size: 13px;
}

.ft-advice {
  margin: 16px 0 0;
  font-size: 14.5px;
  font-weight: 600;
}

.ft-advice .ok {
  padding: 5px 14px;
  border-radius: 99px;
  background: rgba(52, 211, 153, 0.14);
  border: 1px solid rgba(52, 211, 153, 0.45);
  color: #8ef0c2;
}

.ft-advice .no {
  padding: 5px 14px;
  border-radius: 99px;
  background: rgba(248, 113, 113, 0.13);
  border: 1px solid rgba(248, 113, 113, 0.45);
  color: #ff9d9d;
}

.ft-note {
  margin: 10px 0 0;
  font-size: 12.5px;
  line-height: 1.8;
  color: rgba(214, 226, 244, 0.5);
}

@media (max-width: 620px) {
  .pcard {
    width: 72px;
    height: 104px;
  }
  .pcard .pc-back {
    line-height: 104px;
    font-size: 22px;
  }
  .ft-zod {
    width: 34px;
    height: 34px;
    font-size: 15px;
  }
  .ft-num {
    width: 30px;
    height: 30px;
    font-size: 12.5px;
  }
}
/* ============================================================
   卜卦：全屏翻牌
   ============================================================ */

.flip-mask {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  place-items: center;
  background: rgba(4, 8, 14, 0.97);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.flip-mask.in { opacity: 1; }
.flip-mask.out { opacity: 0; }

.flip-inner {
  text-align: center;
  padding: 20px;
}

.flip-q {
  margin: 0 0 6px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.3em;
  text-indent: 0.3em;
  color: #fff6df;
  text-shadow: 0 0 24px rgba(214, 178, 104, 0.8);
}

.flip-sub {
  margin: 0 0 34px;
  font-size: 13px;
  letter-spacing: 0.1em;
  color: rgba(210, 226, 246, 0.55);
}

.flip-row {
  display: flex;
  justify-content: center;
  gap: 22px;
  perspective: 1200px;
}

.fcard {
  position: relative;
  width: 150px;
  height: 216px;
  border-radius: 16px;
  border: 1px solid rgba(214, 178, 104, 0.55);
  background: linear-gradient(160deg, #1a2a44, #0a1220 55%, #1a2a44);
  cursor: pointer;
  transform-style: preserve-3d;
  transition: transform 0.6s cubic-bezier(0.3, 1.25, 0.4, 1), box-shadow 0.35s ease, opacity 0.4s ease;
  box-shadow:
    0 26px 44px -30px rgba(0, 0, 0, 1),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  animation: fcard-float 3.2s ease-in-out infinite;
}

.fcard:nth-child(2) { animation-delay: 0.4s; }
.fcard:nth-child(3) { animation-delay: 0.8s; }

@keyframes fcard-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.fcard::before {
  content: "";
  position: absolute;
  inset: 9px;
  border: 1px solid rgba(214, 178, 104, 0.3);
  border-radius: 10px;
  pointer-events: none;
}

.fc-back,
.fc-face {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border-radius: 16px;
  transition: opacity 0.35s ease, transform 0.45s cubic-bezier(0.3, 1.4, 0.4, 1);
}

.fc-back b {
  font-size: 46px;
  font-weight: 400;
  color: rgba(239, 211, 154, 0.85);
  text-shadow: 0 0 26px rgba(214, 178, 104, 0.9);
  animation: fc-glow 2.4s ease-in-out infinite;
}

@keyframes fc-glow {
  0%, 100% { opacity: 0.55; transform: scale(0.96); }
  50% { opacity: 1; transform: scale(1.06); }
}

.fc-face {
  font-size: 34px;
  font-weight: 800;
  letter-spacing: 0.08em;
  opacity: 0;
  transform: scale(0.72);
}

.fcard:hover:not(.flip) {
  transform: translateY(-12px) scale(1.04);
  box-shadow:
    0 34px 56px -30px rgba(0, 0, 0, 1),
    0 0 34px rgba(214, 178, 104, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.fcard.flip {
  transform: scale(0.99);
  animation: none;
}

.fcard.flip .fc-back { opacity: 0; transform: scale(1.1); }
.fcard.flip .fc-face { opacity: 1; transform: scale(1); }

.fcard.flip.good {
  border-color: rgba(52, 211, 153, 0.9);
  box-shadow: 0 0 60px rgba(52, 211, 153, 0.55), inset 0 0 46px rgba(52, 211, 153, 0.2);
}

.fcard.flip.good .fc-face {
  color: #8ef0c2;
  text-shadow: 0 0 30px rgba(52, 211, 153, 0.95);
}

.fcard.flip.bad {
  border-color: rgba(248, 113, 113, 0.9);
  box-shadow: 0 0 60px rgba(248, 113, 113, 0.5), inset 0 0 46px rgba(248, 113, 113, 0.2);
}

.fcard.flip.bad .fc-face {
  color: #ff9d9d;
  text-shadow: 0 0 30px rgba(248, 113, 113, 0.95);
}

.fcard.dim {
  opacity: 0.18;
  transform: scale(0.9);
}

/* 中牌后的光环 */
.flip-mask.picked::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 240px;
  height: 240px;
  margin: -120px 0 0 -120px;
  border-radius: 50%;
  pointer-events: none;
  animation: burst 1.2s ease-out forwards;
}

.flip-mask.picked.to-good::after {
  background: radial-gradient(circle, rgba(52, 211, 153, 0.55), rgba(52, 211, 153, 0) 70%);
}

.flip-mask.picked.to-bad::after {
  background: radial-gradient(circle, rgba(248, 113, 113, 0.5), rgba(248, 113, 113, 0) 70%);
}

@keyframes burst {
  from { transform: scale(0.2); opacity: 0.9; }
  to { transform: scale(3.2); opacity: 0; }
}

/* 今日已卜 */
.done-tip {
  margin: 0 0 14px;
  padding: 5px 14px;
  display: inline-block;
  border-radius: 99px;
  border: 1px solid rgba(214, 178, 104, 0.4);
  background: rgba(214, 178, 104, 0.1);
  font-size: 12px;
  color: #efd39a;
}

.res-bian b.good { color: #8ef0c2; }
.res-bian b.bad { color: #ff9d9d; }

@media (max-width: 620px) {
  .flip-row { gap: 12px; }
  .fcard {
    width: 104px;
    height: 150px;
  }
  .fc-back b { font-size: 32px; }
  .fc-face { font-size: 24px; }
  .flip-q { font-size: 18px; }
}
/* ============================================================
   翻牌层：加大 + 特效
   ============================================================ */

.flip-aura {
  display: none;
  position: absolute;
  left: 50%;
  top: 52%;
  width: min(760px, 92vw);
  height: min(760px, 92vw);
  transform: translate(-50%, -50%);
  border-radius: 50%;
  pointer-events: none;
  background:
    radial-gradient(circle, rgba(214, 178, 104, 0.10) 0%, rgba(214, 178, 104, 0.03) 40%, rgba(0, 0, 0, 0) 66%);
  animation: aura-pulse 5s ease-in-out infinite;
  opacity: 0.55;
}

@keyframes aura-pulse {
  0%, 100% { opacity: 0.55; transform: translate(-50%, -50%) scale(0.94); }
  50% { opacity: 1; transform: translate(-50%, -50%) scale(1.06); }
}

.flip-sparks {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.flip-sparks i {
  position: absolute;
  left: var(--x);
  bottom: -10px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: radial-gradient(circle, #fff6dc, rgba(214, 178, 104, 0));
  box-shadow: 0 0 8px rgba(255, 226, 150, 0.9);
  opacity: 0;
  animation: spark-rise var(--s) linear var(--d) infinite;
}

@keyframes spark-rise {
  0% { transform: translateY(0) scale(0.6); opacity: 0; }
  16% { opacity: calc(0.3 + var(--o) / 100); }
  100% { transform: translateY(-88vh) scale(1.1); opacity: 0; }
}

.flip-inner {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 20px;
}

.flip-row {
  display: flex;
  justify-content: center;
  gap: 26px;
  perspective: 1600px;
}

.fcard {
  width: clamp(150px, 22vw, 214px);
  height: clamp(216px, 31.6vw, 308px);
  border-radius: 20px;
  border: 1.5px solid rgba(232, 196, 126, 0.75);
  background:
    linear-gradient(160deg, #223553 0%, #0d1728 42%, #1d2f4a 68%, #0b1422 100%);
  box-shadow:
    0 38px 60px -34px rgba(0, 0, 0, 1),
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 0 46px rgba(214, 178, 104, 0.18);
  overflow: hidden;
}

.fcard::before {
  inset: 11px;
  border: 1px solid rgba(232, 196, 126, 0.34);
  border-radius: 13px;
}

/* 扫光 */
.fcard::after {
  content: "";
  position: absolute;
  top: -60%;
  left: -120%;
  width: 70%;
  height: 220%;
  background: linear-gradient(100deg, rgba(255, 240, 200, 0) 0%, rgba(255, 240, 200, 0.34) 50%, rgba(255, 240, 200, 0) 100%);
  transform: rotate(18deg);
  animation: card-sheen 3.6s ease-in-out infinite;
  pointer-events: none;
}

@keyframes card-sheen {
  0% { left: -120%; }
  55%, 100% { left: 160%; }
}

.fcard:nth-child(2)::after { animation-delay: 1.1s; }
.fcard:nth-child(3)::after { animation-delay: 2.2s; }

.fc-back b {
  font-size: clamp(44px, 6vw, 64px);
}

.fc-face {
  font-size: clamp(34px, 4.6vw, 46px);
}

/* 翻转时略微放大（不做 3D 旋转，避免文字镜像） */
.fcard.flip {
  transform: scale(1.04);
  animation: none;
}

/* 闪光 */
.flip-flash {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(circle at 50% 52%, rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0) 62%);
}

.flip-mask.flash.to-good .flip-flash {
  animation: flash-pop 0.75s ease-out;
}

.flip-mask.flash.to-bad .flip-flash {
  background: radial-gradient(circle at 50% 52%, rgba(255, 170, 170, 0.8), rgba(255, 120, 120, 0) 62%);
  animation: flash-pop 0.75s ease-out;
}

@keyframes flash-pop {
  0% { opacity: 0; transform: scale(0.4); }
  22% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.5); }
}

@media (max-width: 620px) {
  .flip-row {
    gap: 12px;
  }
  .fcard {
    width: 112px;
    height: 162px;
    border-radius: 14px;
  }
  .fcard::before {
    inset: 7px;
  }
}
/* 牌背星图纹样 */
.fc-back::before {
  content: "";
  position: absolute;
  inset: 18px;
  border-radius: 50%;
  border: 1px solid rgba(232, 196, 126, 0.18);
  background:
    radial-gradient(circle at 50% 50%, rgba(255, 226, 160, 0.10), rgba(0, 0, 0, 0) 62%),
    radial-gradient(circle at 22% 26%, rgba(255, 255, 255, 0.5) 0.6px, transparent 1.4px),
    radial-gradient(circle at 78% 30%, rgba(255, 255, 255, 0.42) 0.6px, transparent 1.4px),
    radial-gradient(circle at 34% 74%, rgba(255, 255, 255, 0.4) 0.6px, transparent 1.4px),
    radial-gradient(circle at 68% 78%, rgba(255, 255, 255, 0.5) 0.6px, transparent 1.4px),
    radial-gradient(circle at 50% 14%, rgba(255, 255, 255, 0.35) 0.6px, transparent 1.4px);
  opacity: 0.9;
}

.fc-back::after {
  content: "";
  position: absolute;
  inset: 30%;
  border-radius: 50%;
  border: 1px dashed rgba(232, 196, 126, 0.22);
  animation: slow-spin 24s linear infinite;
}

@keyframes slow-spin {
  to { transform: rotate(360deg); }
}

/* 背后旋转光束 */
.flip-aura::after {
  content: "";
  position: absolute;
  inset: -6%;
  border-radius: 50%;
  background: conic-gradient(
    from 0deg,
    rgba(255, 226, 160, 0) 0deg,
    rgba(255, 226, 160, 0.10) 18deg,
    rgba(255, 226, 160, 0) 40deg,
    rgba(255, 226, 160, 0) 180deg,
    rgba(200, 220, 255, 0.08) 200deg,
    rgba(255, 226, 160, 0) 226deg
  );
  filter: blur(14px);
  animation: slow-spin 34s linear infinite reverse;
  opacity: 0.18;
}

/* 牌面更大更亮 */
.fc-face {
  font-size: clamp(40px, 5.4vw, 60px);
  letter-spacing: 0.06em;
}

.fcard.flip.good {
  box-shadow: 0 0 90px rgba(52, 211, 153, 0.6), inset 0 0 60px rgba(52, 211, 153, 0.22);
}

.fcard.flip.bad {
  box-shadow: 0 0 90px rgba(248, 113, 113, 0.55), inset 0 0 60px rgba(248, 113, 113, 0.22);
}
/* 访客 ID 徽章 */
.gua-id {
  margin-left: auto;
  padding: 3px 10px;
  border-radius: 99px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.06);
  color: rgba(226, 238, 252, 0.7);
  font-size: 11px;
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}

.gua-id:empty {
  display: none;
}

.gua-tag {
  margin-left: 8px;
}
/* ============================================================
   手机端（≤480px，约 6.6 英寸手机）整体缩小
   ============================================================ */

@media (max-width: 480px) {

  body {
    font-size: 14px;
  }

  .wrap {
    padding-left: 12px;
    padding-right: 12px;
  }

  /* 顶部品牌 */
  .brand-name {
    font-size: 16px;
    letter-spacing: 0.01em;
  }

  .pill {
    font-size: 10.5px;
    padding: 3px 8px;
  }

  .appbar {
    padding: 10px 12px;
  }

  /* 最新开奖卡 */
  .draw-card {
    padding: 12px 12px 11px;
    border-radius: 16px;
  }

  .draw-card h1 {
    font-size: 16px;
  }

  .draw-issue {
    font-size: 11.5px;
    padding: 2px 8px;
  }

  .draw-time {
    margin-top: 3px;
    font-size: 11.5px;
  }

  .draw-balls {
    gap: 6px 4px;
    margin: 11px 0 2px;
  }

  .draw-balls {
    gap: 4px 2px;
  }

  .draw-balls .nb {
    --ball: 34px;
    width: 38px;
    gap: 3px;
  }

  .draw-balls .nb-num {
    width: 34px;
    height: 34px;
  }

  .draw-balls .nb-z {
    margin-top: 4px;
    padding: 2px 5px 3px;
    border-radius: 7px;
    letter-spacing: 0;
    min-width: 0;
  }

  .draw-balls .nb-plus {
    margin: 0 1px;
    font-size: 12px;
  }

  .draw-balls .nb-ink {
    font-size: 12px;
  }

  .draw-balls .nb-num {
    box-shadow:
      inset -3px -4px 8px rgba(0, 0, 0, 0.28),
      inset 3px 4px 7px rgba(255, 255, 255, 0.24),
      0 6px 10px -6px rgba(24, 18, 10, 0.6);
  }

  .draw-balls .nb-z {
    font-size: 10.5px;
  }

  .draw-balls .nb.nb.special .nb-z {
    font-size: 11px;
  }

  .draw-actions {
    gap: 7px;
    margin-top: 11px;
  }

  .draw-actions .btn {
    height: 40px;
    font-size: 12.5px;
    border-radius: 10px;
  }

  /* 快捷入口 */
  .hero-quick {
    gap: 7px;
    margin-top: 10px;
    padding: 0 12px;
  }

  .hero-quick a {
    gap: 6px;
    padding: 9px 2px 8px;
    border-radius: 12px;
    font-size: 10.5px;
  }

  .hero-quick .qi {
    width: 30px;
    height: 30px;
  }

  .hero-quick .qi::before,
  .hero-quick .qi::after {
    transform: scale(0.78);
  }

  /* 星空心水 */
  .xs-card {
    padding: 12px 11px;
    border-radius: 16px;
  }

  .xs-title {
    font-size: 16px;
  }

  .xs-sub {
    font-size: 11px;
  }

  .xs-icon-btn {
    width: 26px;
    height: 26px;
    font-size: 13px;
  }

  .xs-row {
    grid-template-columns: 56px 1fr 44px;
    gap: 4px;
    padding: 6px;
    border-radius: 11px;
  }

  .xs-label {
    font-size: 11.5px;
    letter-spacing: 0;
    white-space: nowrap;
  }

  .xs-num .nb-num {
    --ball: 28px;
    width: 28px;
    height: 28px;
  }

  .xs-num .nb-ink {
    font-size: 11px;
  }

  .xs-row.many .xs-num .nb-num {
    --ball: 26px;
    width: 26px;
    height: 26px;
  }

  .xs-row.many .xs-pick {
    gap: 5px 7px;
  }

  .xs-side {
    padding-left: 5px;
    gap: 1px;
  }

  .xs-side-label {
    font-size: 9.5px;
    letter-spacing: 0;
  }

  .xs-side-value {
    font-size: 12px;
  }

  .xs-row .zods,
  .xs-row [class*="zod"] {
    gap: 4px;
  }

  .xs-row .label,
  .xs-row > b {
    font-size: 11px;
  }

  .xs-zod {
    width: 26px;
    height: 26px;
    font-size: 13px;
  }

  .xs-row.zods-only {
    grid-template-columns: 56px 1fr 44px;
  }

  .xs-row.zods-only .xs-zod {
    width: 30px;
    height: 30px;
    font-size: 15px;
  }

  .xs-row.zods-only .xs-pick {
    gap: 6px;
  }

  .xs-side {
    font-size: 10.5px;
  }

  .xs-side b {
    font-size: 13px;
  }

  .xs-record-bar {
    height: 40px;
    margin-top: 11px;
    font-size: 12.5px;
    border-radius: 11px;
  }

  .xs-record-bar em {
    font-size: 11px;
  }

  /* 底部导航 */
  .tabbar {
    height: 54px;
  }

  .tabbar a {
    gap: 2px;
    font-size: 10px;
  }

  .tabbar svg {
    width: 20px;
    height: 20px;
  }

  /* 悬浮开户 */
  .ad-fab {
    height: 34px;
    padding: 0 11px 0 9px;
    font-size: 11.5px;
    right: 10px;
    bottom: 62px;
  }

  /* 免责声明 */
  .disclaimer {
    font-size: 10.5px;
    padding: 10px 14px 16px;
  }

  /* ---------- 卜卦页 ---------- */
  .ask {
    padding: 18px 14px 16px;
    border-radius: 18px;
  }

  .ask-q {
    font-size: 15.5px;
  }

  .ask-sub {
    font-size: 11.5px;
    margin-bottom: 16px;
  }

  .dt {
    gap: 4px;
    margin-bottom: 18px;
  }

  .dt span {
    font-size: 11.5px;
  }

  .dt-in {
    width: 46px;
    height: 46px;
    font-size: 16px;
    border-radius: 10px;
  }

  .dt-in:nth-of-type(1) {
    width: 62px;
  }

  .line-in {
    height: 44px;
    font-size: 13.5px;
  }

  .go {
    height: 44px;
    font-size: 14px;
    border-radius: 11px;
  }

  .skip {
    flex: 0 0 76px;
    height: 44px;
    font-size: 12.5px;
    border-radius: 11px;
  }

  .res {
    padding: 18px 14px 16px;
    border-radius: 18px;
  }

  .res-hex .gua-line {
    width: 128px;
  }

  .res-name {
    font-size: 18.5px;
  }

  .res-text {
    font-size: 13.5px;
  }

  .res-body p {
    font-size: 13px;
    line-height: 1.9;
  }

  .ft-zod {
    width: 31px;
    height: 31px;
    font-size: 14px;
  }

  .ft-num {
    width: 28px;
    height: 28px;
    font-size: 12px;
  }

  .ft-advice {
    font-size: 13.5px;
  }

  .ft-note {
    font-size: 11.5px;
  }

  .fortune {
    padding: 13px 11px;
    border-radius: 14px;
  }

  .pick-q {
    font-size: 15px;
  }

  .again {
    height: 42px;
    font-size: 13px;
  }

  /* 翻牌层 */
  .flip-q {
    font-size: 17px;
  }

  .flip-sub {
    font-size: 11.5px;
    margin-bottom: 24px;
  }

  .fcard {
    width: 96px;
    height: 140px;
    border-radius: 12px;
  }

  .flip-row {
    gap: 10px;
  }

  .fc-back b {
    font-size: 30px;
  }

  .fc-face {
    font-size: 26px;
  }

  .gua-bar {
    padding: 10px 12px;
  }

  .gua-brand {
    font-size: 14px;
  }

  .gua-id {
    font-size: 10px;
    padding: 2px 8px;
  }

  .gua-tag {
    font-size: 10.5px;
    padding: 2px 8px;
  }

  .gua-note {
    font-size: 10.5px;
  }
}

/* ============================================================
   手机端性能模式：去掉毛玻璃和大面积循环动画（治卡顿/闪烁）
   ============================================================ */

@media (max-width: 768px) {

  * {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }

  /* 大面积扫光、呼吸、闪烁一律停掉 */
  .hero,
  .hero::before,
  .hero-glow,
  .hero-shine,
  .beam,
  .orb,
  .star,
  .spark,
  .draw-balls .nb-num,
  .qi::before,
  .qi::after,
  .xs-card::before,
  .xs-card::after,
  .xs-title::before,
  .xs-deco span,
  .ad-fab,
  .coin-icon,
  .fcard::after,
  .fc-back::after,
  .flip-sparks i,
  .flip-aura,
  .moon,
  .tabbar a {
    animation: none !important;
  }

  /* 去掉模糊后，给需要的地方补实底 */
  .hero-quick a {
    background: linear-gradient(160deg, rgba(11, 38, 78, 0.78), rgba(7, 24, 52, 0.7));
  }

  .ask,
  .res,
  .pick {
    background: linear-gradient(165deg, rgba(13, 24, 40, 0.96), rgba(8, 14, 26, 0.97));
  }

  .gua-back {
    background: rgba(255, 255, 255, 0.1);
  }

  .page-tabs {
    background: #f7f2e7;
  }

  /* 减少大阴影的重绘开销 */
  .draw-card,
  .xs-card,
  .ask,
  .res,
  .pick,
  .block {
    box-shadow: 0 10px 22px -18px rgba(20, 40, 70, 0.6);
  }
}


/* 历史开奖：手机端收紧一档，7 个球排成一行 */
@media (max-width: 480px) {
  .hist-list {
    border-radius: 14px;
  }

  .hist-item {
    padding: 11px 10px 12px;
  }

  .hist-head {
    gap: 6px;
    margin-bottom: 9px;
  }

  .hist-issue {
    font-size: 14.5px;
  }

  .hist-time {
    font-size: 10.5px;
  }

  .hist-balls {
    gap: 3px 2px;
    align-items: flex-start;
  }

  .hist-balls .nb {
    width: 38px;
  }

  .hist-balls .nb-num {
    --ball: 30px;
    width: 30px;
    height: 30px;
  }

  .hist-balls .nb-ink {
    font-size: 12px;
  }

  .hist-balls .nb-z {
    margin-top: 3px;
    font-size: 10px;
    letter-spacing: 0;
  }

  .hist-balls .nb-plus {
    margin-top: 8px;
    font-size: 12px;
  }

  .hist-balls .nb.special {
    margin-left: 3px;
  }

  .hist-filter {
    gap: 8px;
    margin-bottom: 10px;
  }

  .hist-empty {
    padding: 34px 0;
    font-size: 12.5px;
  }
}


/* 跳码助手：挑码结果的号码球缩小一档 */
.pick-panel .pick-result {
  gap: 10px 12px;
  max-height: 220px;
}

.pick-panel .pick-result .nb-num {
  --ball: 36px;
  width: 36px;
  height: 36px;
}

.pick-panel .pick-result .nb-ink {
  font-size: 13px;
}

.pick-panel .pick-result .nb-z {
  font-size: 10.5px;
}

@media (max-width: 480px) {
  .pick-panel .pick-result {
    gap: 7px 9px;
    max-height: 180px;
  }

  .pick-panel .pick-result .nb-num {
    --ball: 30px;
    width: 30px;
    height: 30px;
  }

  .pick-panel .pick-result .nb-ink {
    font-size: 11.5px;
  }

  .pick-panel .pick-result .nb-z {
    font-size: 9.5px;
  }
}




/* ============================================================
   首页背景升级：深墨蓝 + 极光 + 金线（替代原来的亮蓝）
   ============================================================ */

.hero {
  background:
    radial-gradient(1100px 620px at 50% -18%, rgba(88, 132, 186, 0.30), transparent 68%),
    radial-gradient(760px 520px at 8% 12%, rgba(104, 82, 168, 0.20), transparent 70%),
    radial-gradient(820px 560px at 92% 8%, rgba(28, 104, 126, 0.22), transparent 72%),
    radial-gradient(900px 700px at 50% 120%, rgba(12, 28, 48, 0.9), transparent 70%),
    linear-gradient(178deg, #0a1524 0%, #0b1a2c 42%, #081120 100%);
}

/* 原来的高光/光束压下去，别抢戏 */
.hero-glow {
  opacity: 0.28;
}

.hero-shine {
  opacity: 0.14;
}

.hero::before {
  opacity: 0.3;
}

.beam {
  opacity: 0.16;
}

.orb {
  opacity: 0.35;
  filter: blur(24px);
}

/* 顶部一条极细金线 */
.hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(214, 178, 104, 0.55), transparent);
  opacity: 0.7;
}

/* 品牌更稳 */
.brand-name {
  color: #f3f7ff;
  text-shadow: 0 2px 14px rgba(2, 10, 24, 0.9);
}

.hero .pill {
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.07);
  color: rgba(232, 242, 255, 0.78);
}

/* 快捷入口：去掉厚重玻璃，改细边金线 */
.hero-quick a {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.015));
  border: 1px solid rgba(214, 178, 104, 0.16);
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  color: rgba(226, 238, 255, 0.92);
}

.hero-quick a:hover {
  border-color: rgba(214, 178, 104, 0.5);
  background: rgba(255, 255, 255, 0.07);
  box-shadow: 0 12px 28px -22px rgba(0, 0, 0, 0.9);
}

/* 图标：金调，冷光减弱 */
.hero-quick .qi {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 44%, rgba(255, 246, 220, 0.16), rgba(255, 246, 220, 0.04) 62%, transparent 72%);
  border: 1px solid rgba(214, 178, 104, 0.32);
  box-shadow: inset 0 0 12px rgba(214, 178, 104, 0.18);
}

/* 开奖卡片：更干净的投影 */
.draw-card {
  box-shadow:
    0 30px 60px -40px rgba(0, 8, 20, 0.95),
    0 1px 0 rgba(255, 255, 255, 0.7) inset;
}


/* ============================================================
   首页背景主题（?theme=emerald / ivory / charcoal 预览）
   ============================================================ */

/* A. 墨绿 + 香槟金 */
html.theme-emerald .hero {
  background:
    radial-gradient(1000px 560px at 50% -16%, rgba(76, 132, 108, 0.42), transparent 66%),
    radial-gradient(760px 520px at 6% 6%, rgba(28, 74, 60, 0.55), transparent 70%),
    radial-gradient(820px 560px at 96% 10%, rgba(18, 58, 48, 0.5), transparent 72%),
    linear-gradient(178deg, #0d2a22 0%, #0a211b 45%, #07160f 100%);
}

html.theme-emerald .hero::after {
  background: linear-gradient(90deg, transparent, rgba(226, 192, 122, 0.7), transparent);
}

html.theme-emerald .hero-quick a {
  border-color: rgba(226, 192, 122, 0.18);
}

html.theme-emerald .hero-quick a:hover {
  border-color: rgba(226, 192, 122, 0.6);
}

html.theme-emerald .hero-quick .qi {
  border-color: rgba(226, 192, 122, 0.32);
  background: radial-gradient(circle at 50% 44%, rgba(255, 240, 206, 0.14), transparent 70%);
}

/* B. 象牙白 + 烫金（浅色高级） */
html.theme-ivory .hero {
  background:
    radial-gradient(900px 520px at 50% -20%, #fffdf7, transparent 70%),
    radial-gradient(700px 480px at 8% 4%, rgba(232, 214, 168, 0.35), transparent 70%),
    radial-gradient(760px 520px at 94% 8%, rgba(214, 196, 150, 0.3), transparent 72%),
    linear-gradient(180deg, #f7f2e6 0%, #efe7d6 52%, #e8dfcb 100%);
}

html.theme-ivory .brand-name {
  color: #3d3323;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
}

html.theme-ivory .hero .pill {
  border-color: rgba(120, 96, 48, 0.22);
  background: rgba(255, 255, 255, 0.5);
  color: #7a6231;
}

html.theme-ivory .hero-quick a {
  border-color: rgba(160, 128, 64, 0.25);
  background: rgba(255, 255, 255, 0.55);
  color: #4a3f2a;
  text-shadow: none;
}

html.theme-ivory .hero-quick a:hover {
  border-color: rgba(160, 128, 64, 0.6);
  background: #fffdf7;
}

html.theme-ivory .hero-quick .qi {
  background: radial-gradient(circle at 50% 44%, rgba(255, 245, 220, 0.9), rgba(226, 206, 158, 0.5) 60%, transparent 72%);
  border-color: rgba(160, 128, 64, 0.35);
}

html.theme-ivory .hero::after {
  background: linear-gradient(90deg, transparent, rgba(176, 140, 62, 0.5), transparent);
}

html.theme-ivory .draw-card {
  box-shadow:
    0 26px 50px -34px rgba(90, 70, 30, 0.55),
    0 1px 0 rgba(255, 255, 255, 0.9) inset;
}

/* C. 炭黑 + 香槟金（低调） */
html.theme-charcoal .hero {
  background:
    radial-gradient(900px 520px at 50% -18%, rgba(122, 116, 100, 0.22), transparent 68%),
    radial-gradient(720px 460px at 8% 8%, rgba(86, 78, 62, 0.25), transparent 70%),
    radial-gradient(820px 520px at 94% 10%, rgba(70, 66, 56, 0.22), transparent 72%),
    linear-gradient(178deg, #1a1a1a 0%, #141414 48%, #0c0c0c 100%);
}

html.theme-charcoal .hero-quick a {
  border-color: rgba(226, 192, 122, 0.18);
}

html.theme-charcoal .hero-quick .qi {
  border-color: rgba(226, 192, 122, 0.3);
}


/* 象牙白主题：去掉白斑，快捷入口做成白卡 */
html.theme-ivory .hero-shine,
html.theme-ivory .hero-glow,
html.theme-ivory .beam,
html.theme-ivory .orb {
  opacity: 0;
}

html.theme-ivory .hero-quick a {
  background: #fffdf8;
  border: 1px solid rgba(170, 140, 80, 0.26);
  box-shadow: 0 16px 28px -24px rgba(120, 92, 40, 0.6);
}

html.theme-ivory .hero-quick a:hover {
  background: #fff;
  border-color: rgba(170, 140, 80, 0.55);
  box-shadow: 0 18px 32px -22px rgba(120, 92, 40, 0.5);
}

html.theme-ivory .hero-quick .qi {
  background: linear-gradient(160deg, #fff6e2, #f0e0bc);
  border: 1px solid rgba(170, 140, 80, 0.3);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

html.theme-ivory .hero .draw-card,
html.theme-ivory .hero .brand-name {
  text-shadow: none;
}

html.theme-ivory .hero .brand-name {
  color: #2b2417 !important;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.7) !important;
}

html.theme-ivory .hero .pill {
  color: #6b5527 !important;
}
/* 象牙白主题：收尾打磨 */
html.theme-ivory .hero {
  border-bottom: 1px solid rgba(170, 140, 80, 0.18);
  box-shadow: 0 18px 40px -32px rgba(120, 92, 40, 0.5);
}

html.theme-ivory .hero .draw-card {
  border: 1px solid rgba(170, 140, 80, 0.14);
}

html.theme-ivory .hero .btn.primary {
  box-shadow: 0 12px 22px -16px rgba(15, 34, 63, 0.8);
}

html.theme-ivory .hero-quick .qi {
  color: #9a7420;
}

/* 象牙白主题：四个快捷图标重绘，提高对比度 */
html.theme-ivory .hero-quick .qi {
  width: 46px;
  height: 46px;
  background:
    radial-gradient(circle at 50% 34%, #fffdf8, #f6e9c9 62%, #ecd9ab 100%);
  border: 1px solid rgba(150, 116, 50, 0.45);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    inset 0 -2px 6px rgba(168, 132, 60, 0.18),
    0 8px 16px -12px rgba(120, 92, 40, 0.75);
}

/* 星星 */
html.theme-ivory .qi-star::before {
  width: 24px;
  height: 24px;
  background: radial-gradient(circle at 42% 34%, #fff8dc, #e8b843 52%, #b8801a 100%);
  filter: drop-shadow(0 1px 3px rgba(120, 84, 10, 0.55));
}

/* 黑洞：金色吸积环 + 深墨核心 */
html.theme-ivory .qi-hole::before {
  width: 24px;
  height: 24px;
  background: radial-gradient(
    circle,
    #0a1220 34%,
    #101c2f 46%,
    #b8892b 60%,
    #e8c377 68%,
    rgba(232, 195, 119, 0) 76%
  );
  box-shadow: 0 0 10px rgba(184, 137, 43, 0.55);
}

html.theme-ivory .qi-hole::after {
  width: 36px;
  height: 36px;
  border: 1.5px solid transparent;
  border-top-color: rgba(150, 112, 40, 0.95);
  border-right-color: rgba(184, 137, 43, 0.55);
}

/* 流星：暖金拖尾 */
html.theme-ivory .qi-comet::before {
  width: 10px;
  height: 10px;
  top: 13px;
  left: 24px;
  background: radial-gradient(circle, #fffdf4, #ffd98a 55%, #c98f1e);
  box-shadow: 0 0 10px rgba(201, 143, 30, 0.8);
}

html.theme-ivory .qi-comet::after {
  width: 32px;
  height: 3px;
  top: 17px;
  left: 0;
  border-radius: 3px;
  background: linear-gradient(90deg, rgba(184, 137, 43, 0), rgba(201, 143, 30, 0.75), rgba(184, 137, 43, 1));
}

/* 脉冲：深金核心 + 金环 */
html.theme-ivory .qi-pulse::before {
  width: 11px;
  height: 11px;
  background: radial-gradient(circle, #fffdf4, #f0c979 55%, #b8801a);
  box-shadow: 0 0 10px rgba(184, 128, 26, 0.85);
}

html.theme-ivory .qi-pulse::after {
  width: 20px;
  height: 20px;
  border: 1.5px solid rgba(160, 120, 42, 0.85);
}

html.theme-ivory .qi-pulse::before {
  width: 12px;
  height: 12px;
}


/* 手机端：图标缩回小号，避免撑破卡片 */
@media (max-width: 480px) {
  html.theme-ivory .hero-quick .qi {
    width: 36px;
    height: 36px;
  }

  html.theme-ivory .qi-star::before {
    width: 19px;
    height: 19px;
  }

  html.theme-ivory .qi-hole::before {
    width: 19px;
    height: 19px;
  }

  html.theme-ivory .qi-hole::after {
    width: 28px;
    height: 28px;
  }

  html.theme-ivory .qi-comet::before {
    width: 8px;
    height: 8px;
    top: 10px;
    left: 19px;
  }

  html.theme-ivory .qi-comet::after {
    width: 24px;
    top: 14px;
  }

  html.theme-ivory .qi-pulse::before {
    width: 10px;
    height: 10px;
  }

  html.theme-ivory .qi-pulse::after {
    width: 16px;
    height: 16px;
  }
}


/* 象牙白主题：图标不再自己闪，交给流星雨做动效 */
html.theme-ivory .qi-star::before,
html.theme-ivory .qi-hole::after,
html.theme-ivory .qi-comet::after,
html.theme-ivory .qi-pulse::before,
html.theme-ivory .qi-pulse::after {
  animation: none !important;
}


/* 快捷入口：太阳 / 火箭 / 喇叭（SVG 图标） */
.qi-svg {
  width: 26px;
  height: 26px;
  display: block;
  color: inherit;
}

html.theme-ivory .hero-quick .qi {
  color: #a8791f;
}

html.theme-ivory .qi-svg {
  stroke: #a8791f;
}

html.theme-emerald .hero-quick .qi,
html.theme-charcoal .hero-quick .qi {
  color: #e2c07a;
}

html.theme-emerald .qi-svg,
html.theme-charcoal .qi-svg {
  stroke: #e2c07a;
}

@media (max-width: 480px) {
  .qi-svg {
    width: 20px;
    height: 20px;
  }
}


/* 手机端：快捷入口与开奖卡拉近一些 */
@media (max-width: 480px) {
  .hero .wrap.hero-inner {
    padding-bottom: 2px;
  }

  .hero-quick {
    margin-top: 28px;
  }

  .hero {
    padding-bottom: 24px;
  }
}


/* ============================================================
   悬浮：联系我们（客服）
   ============================================================ */

.contact-fab {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid rgba(184, 137, 43, 0.45);
  background: rgba(255, 253, 246, 0.96);
  color: #8a6a24;
  box-shadow: 0 14px 26px -20px rgba(90, 70, 30, 0.75);
}

.contact-fab::before {
  display: none;
}

.contact-fab svg {
  width: 16px;
  height: 16px;
  flex: none;
}

.contact-fab:hover {
  border-color: rgba(184, 137, 43, 0.85);
  background: #fffdf7;
  color: #6f5418;
}

/* 叠在免费开户上面 */
.ad-fab.contact-fab {
  bottom: 138px;
}

/* 弹层 */
.contact-mask {
  position: fixed;
  inset: 0;
  z-index: 1300;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(20, 16, 8, 0.42);
  opacity: 0;
  transition: opacity 0.22s ease;
}

.contact-mask.in {
  opacity: 1;
}

.contact-box {
  width: 100%;
  max-width: 320px;
  padding: 22px 20px 18px;
  border-radius: 18px;
  background: #fffdf7;
  border: 1px solid rgba(184, 137, 43, 0.28);
  box-shadow: 0 30px 60px -34px rgba(60, 44, 14, 0.7);
  text-align: center;
  transform: translateY(8px) scale(0.98);
  transition: transform 0.24s cubic-bezier(0.2, 1.2, 0.4, 1);
}

.contact-mask.in .contact-box {
  transform: none;
}

.contact-box h3 {
  margin: 0 0 14px;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #3d3323;
}

.contact-box h3::after {
  content: "";
  display: block;
  width: 36px;
  height: 1px;
  margin: 10px auto 0;
  background: linear-gradient(90deg, transparent, rgba(184, 137, 43, 0.8), transparent);
}

.contact-lead {
  margin: 0 0 14px;
  font-size: 12.5px;
  line-height: 1.6;
  color: #7a6f5c;
}

.contact-in {
  width: 100%;
  box-sizing: border-box;
  margin-bottom: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(184, 137, 43, 0.28);
  border-radius: 11px;
  background: #fffdf6;
  font: inherit;
  font-size: 14px;
  color: #3d3323;
  outline: none;
}

.contact-in:focus {
  border-color: rgba(184, 137, 43, 0.75);
  box-shadow: 0 0 0 3px rgba(214, 178, 104, 0.16);
}

textarea.contact-in {
  height: auto;
  min-height: 76px;
  line-height: 1.7;
  resize: vertical;
}

.contact-tip {
  min-height: 16px;
  margin: 2px 0 10px;
  font-size: 12px;
  color: #b8892b;
}

.contact-acts {
  display: flex;
  gap: 10px;
}

.contact-close,
.contact-send {
  flex: 1;
  height: 42px;
  border-radius: 12px;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.contact-close {
  border: 1px solid rgba(184, 137, 43, 0.3);
  background: #fffdf7;
  color: #7a6f5c;
}

.contact-send {
  border: 0;
  background: linear-gradient(135deg, #f7d488, #d6a043 52%, #b8892b);
  color: #3d2a06;
}

.contact-send:disabled {
  opacity: 0.6;
  cursor: default;
}

.contact-close:hover {
  border-color: rgba(184, 137, 43, 0.7);
  color: #3d3323;
}

@media (max-width: 480px) {
  .ad-fab.contact-fab {
    bottom: 104px;
    height: 34px;
    padding: 0 11px 0 9px;
    font-size: 11.5px;
    gap: 5px;
  }

  .contact-fab svg {
    width: 14px;
    height: 14px;
  }
}


/* ============================================================
   后台管理
   ============================================================ */

.admin-body {
  background: var(--bg);
}

.admin-login form {
  display: flex;
  gap: 10px;
}

.admin-login input {
  flex: 1;
  height: 44px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fff;
  font: inherit;
  font-size: 14px;
  outline: none;
}

.admin-login input:focus {
  border-color: var(--gold-soft);
  box-shadow: 0 0 0 3px rgba(214, 178, 104, 0.16);
}

.admin-tabs {
  display: flex;
  gap: 6px;
  padding: 5px;
  margin: 4px 0 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(247, 242, 231, 0.95);
  position: sticky;
  top: 58px;
  z-index: 12;
}

.atab {
  flex: 1;
  height: 36px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}

.atab.on {
  background: #fff;
  color: var(--ink);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(27, 34, 48, 0.1);
}

.atab b {
  display: inline-block;
  min-width: 16px;
  margin-left: 4px;
  padding: 0 4px;
  border-radius: 8px;
  background: #e0403a;
  color: #fff;
  font-size: 10.5px;
  line-height: 16px;
}

.atab b:empty {
  display: none;
}

.admin-pane {
  display: none;
}

.admin-pane.on {
  display: block;
}

.xs-edit {
  padding: 14px;
  margin-bottom: 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}

.xs-edit-head {
  margin-bottom: 10px;
  font-size: 14px;
  font-weight: 700;
  color: #0e2a48;
}

.xs-edit label,
.admin-row label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 12.5px;
  color: var(--muted);
}

.xs-edit input,
.admin-row input,
.admin-pane textarea {
  flex: 1;
  min-width: 0;
  height: 38px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fbf8f1;
  font: inherit;
  font-size: 13.5px;
  color: var(--ink);
  outline: none;
}

.admin-pane textarea {
  width: 100%;
  height: auto;
  padding: 11px;
  line-height: 1.7;
  resize: vertical;
}

.admin-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-row label {
  flex: 1 1 160px;
  margin: 0;
}

.admin-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}

.admin-tip {
  font-size: 12.5px;
  color: var(--muted);
}

.msg-item {
  padding: 13px 14px;
  margin-bottom: 10px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fff;
}

.msg-item.read {
  opacity: 0.62;
}

.msg-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 6px;
}

.msg-head b {
  font-size: 14px;
  color: var(--ink);
}

.msg-head span {
  font-size: 12.5px;
  color: var(--gold);
}

.msg-head em {
  margin-left: auto;
  font-style: normal;
  font-size: 11.5px;
  color: var(--faint);
}

.msg-item p {
  margin: 0 0 10px;
  font-size: 13.5px;
  line-height: 1.75;
  color: #3d5069;
  white-space: pre-wrap;
}

.msg-acts {
  display: flex;
  gap: 8px;
}

.admin-toast {
  position: fixed;
  left: 50%;
  bottom: 32px;
  transform: translate(-50%, 12px);
  padding: 10px 18px;
  border-radius: 99px;
  background: rgba(15, 34, 63, 0.94);
  color: #fff;
  font-size: 13px;
  opacity: 0;
  transition: 0.24s ease;
  z-index: 999;
}

.admin-toast.in {
  opacity: 1;
  transform: translate(-50%, 0);
}

@media (max-width: 620px) {
  .admin-tabs {
    top: 52px;
  }
  .atab {
    font-size: 12px;
    height: 34px;
  }
}


/* 后台：今日草稿提示条 */
.draft-box {
  border-color: rgba(184, 137, 43, 0.45);
  background: linear-gradient(180deg, #fffdf3, #fff8e6);
}

.draft-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 10px;
}

.draft-head b {
  padding: 2px 9px;
  border-radius: 99px;
  background: rgba(184, 137, 43, 0.16);
  color: #8a6a24;
  font-size: 12px;
}

.draft-head span {
  font-size: 12.5px;
  color: #7a6f5c;
}

.draft-acts {
  display: flex;
  gap: 10px;
}


/* ============================================================
   联系我们：会话式聊天
   ============================================================ */

.chat-mask {
  position: fixed;
  inset: 0;
  z-index: 1300;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 16px;
  background: rgba(20, 16, 8, 0.42);
  opacity: 0;
  transition: opacity 0.22s ease;
}

.chat-mask.in {
  opacity: 1;
}

.chat-box {
  width: 100%;
  max-width: 380px;
  height: min(560px, 78vh);
  display: flex;
  flex-direction: column;
  border-radius: 18px;
  border: 1px solid rgba(184, 137, 43, 0.3);
  background: #fffdf7;
  box-shadow: 0 30px 60px -30px rgba(60, 44, 14, 0.75);
  overflow: hidden;
  transform: translateY(14px);
  transition: transform 0.24s cubic-bezier(0.2, 1.2, 0.4, 1);
}

.chat-mask.in .chat-box {
  transform: none;
}

.chat-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 13px 14px;
  border-bottom: 1px solid rgba(184, 137, 43, 0.18);
  background: linear-gradient(180deg, #fffdf6, #fdf6e6);
}

.chat-head b {
  font-size: 15px;
  color: #3d3323;
}

.chat-head span {
  font-size: 11.5px;
  color: #9a8c72;
}

.chat-close {
  margin-left: auto;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #9a8c72;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}

.chat-close:hover {
  background: rgba(184, 137, 43, 0.12);
  color: #3d3323;
}

.chat-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 14px 12px;
  background: #fffdf9;
}

.chat-empty {
  margin: 40% 0 0;
  text-align: center;
  font-size: 12.5px;
  color: #b6a98f;
}

.chat-msg {
  display: flex;
  margin-bottom: 9px;
}

.chat-msg span {
  max-width: 78%;
  padding: 9px 12px;
  border-radius: 12px;
  font-size: 13.5px;
  line-height: 1.65;
  word-break: break-word;
  white-space: pre-wrap;
}

.chat-msg.me {
  justify-content: flex-end;
}

.chat-msg.me span {
  background: linear-gradient(135deg, #f7d488, #d6a043 60%, #b8892b);
  color: #3d2a06;
  border-bottom-right-radius: 4px;
}

.chat-msg.them {
  justify-content: flex-start;
}

.chat-msg.them span {
  background: #fff;
  border: 1px solid rgba(184, 137, 43, 0.28);
  color: #3d3323;
  border-bottom-left-radius: 4px;
}

.chat-foot {
  padding: 10px 12px 12px;
  border-top: 1px solid rgba(184, 137, 43, 0.18);
  background: #fffdf7;
}


.chat-send-row {
  display: flex;
  gap: 8px;
  align-items: stretch;
}

.chat-ta {
  flex: 1;
  min-height: 42px;
  max-height: 96px;
  padding: 9px 11px;
  border: 1px solid rgba(184, 137, 43, 0.25);
  border-radius: 10px;
  background: #fff;
  font: inherit;
  font-size: 13.5px;
  color: #3d3323;
  line-height: 1.6;
  resize: none;
  outline: none;
}

.chat-in:focus,
.chat-ta:focus {
  border-color: rgba(184, 137, 43, 0.7);
  box-shadow: 0 0 0 3px rgba(214, 178, 104, 0.14);
}

.chat-send {
  flex: 0 0 68px;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(135deg, #f7d488, #d6a043 52%, #b8892b);
  color: #3d2a06;
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

.chat-send:disabled {
  opacity: 0.6;
  cursor: default;
}

/* 后台会话样式 */
.chat-thread {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 340px;
  overflow-y: auto;
  padding: 12px;
  margin: 10px 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fbf8f1;
}

.thread-msg {
  display: flex;
}

.thread-msg span {
  max-width: 80%;
  padding: 8px 11px;
  border-radius: 11px;
  font-size: 13px;
  line-height: 1.6;
  white-space: pre-wrap;
}

.thread-msg.visitor span {
  background: #fff;
  border: 1px solid var(--line);
  color: #22374f;
}

.thread-msg.admin {
  justify-content: flex-end;
}

.thread-msg.admin span {
  background: linear-gradient(135deg, #14416d, #0f2c4c);
  color: #eaf4ff;
}

.thread-meta {
  font-size: 11px;
  color: var(--faint);
  margin-bottom: 2px;
}


/* 聊天图片 */
.chat-pic {
  flex: 0 0 40px;
  border: 1px solid rgba(184, 137, 43, 0.3);
  border-radius: 10px;
  background: #fffdf7;
  font-size: 17px;
  line-height: 1;
  cursor: pointer;
}

.chat-pic:hover {
  border-color: rgba(184, 137, 43, 0.7);
}

.chat-pic:disabled {
  opacity: 0.6;
  cursor: default;
}

.chat-msg .chat-img {
  padding: 0;
  overflow: hidden;
  background: transparent;
  border: 0;
  max-width: 74%;
}

.chat-img img {
  display: block;
  max-width: 100%;
  max-height: 220px;
  border-radius: 12px;
  box-shadow: 0 8px 18px -12px rgba(60, 44, 14, 0.6);
}

.thread-msg .chat-img {
  padding: 0;
  background: transparent;
  border: 0;
}

.thread-msg .chat-img img {
  max-width: 200px;
  max-height: 200px;
  border-radius: 10px;
}


/* 「联系我们」未读红点 */
.ad-fab.contact-fab {
  position: fixed;
}

.contact-fab.has-new::after {
  content: "";
  position: absolute;
  top: -3px;
  right: -3px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #e0403a;
  box-shadow: 0 0 0 2px #fffdf7, 0 0 10px rgba(224, 64, 58, 0.9);
  animation: dot-pulse 1.6s ease-in-out infinite;
}

@keyframes dot-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.25); opacity: 0.7; }
}


/* 图片放大查看 */
.chat-img img {
  cursor: zoom-in;
}

.thread-msg img {
  cursor: zoom-in;
}

.img-zoom {
  position: fixed;
  inset: 0;
  z-index: 1600;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(8, 6, 2, 0.86);
  opacity: 0;
  transition: opacity 0.2s ease;
  cursor: zoom-out;
}

.img-zoom.in {
  opacity: 1;
}

.img-zoom img {
  max-width: 96vw;
  max-height: 90vh;
  border-radius: 12px;
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.9);
  transform: scale(0.96);
  transition: transform 0.22s cubic-bezier(0.2, 1.2, 0.4, 1);
}

.img-zoom.in img {
  transform: none;
}


/* 后台会话筛选与工具条 */
.chat-filters {
  display: flex;
  gap: 6px;
  margin-bottom: 12px;
}

.cf {
  padding: 5px 12px;
  border: 1px solid var(--line);
  border-radius: 99px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-size: 12.5px;
  cursor: pointer;
}

.cf.on {
  border-color: rgba(184, 137, 43, 0.6);
  background: #fff8e6;
  color: #8a6a24;
  font-weight: 600;
}

.thread-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0;
}

.btn-sm.danger {
  border-color: rgba(224, 64, 58, 0.4);
  color: #c0342e;
}

.btn-sm.danger:hover {
  background: #fff1f0;
}

.msg-note {
  margin: 2px 0 6px;
  font-size: 12px;
  color: #8a6a24;
}

.tag {
  padding: 1px 7px;
  border-radius: 99px;
  background: #f0ece2;
  color: #7a6f5c;
  font-size: 11px;
  font-style: normal;
}

.tag.bad {
  background: #ffeceb;
  color: #c0342e;
}


/* 后台自检输出 */
.diag-out {
  margin-top: 12px;
  padding: 12px 14px;
  max-height: 280px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fbf8f1;
  font-family: ui-monospace, Consolas, monospace;
  font-size: 12px;
  line-height: 1.7;
  color: #3d5069;
  white-space: pre-wrap;
}


.diag-acts {
  display: flex;
  gap: 10px;
}


/* 自绘对话框（替代 prompt / confirm） */
.ui-mask {
  position: fixed;
  inset: 0;
  z-index: 1700;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(20, 16, 8, 0.42);
  opacity: 0;
  transition: opacity 0.18s ease;
}

.ui-mask.in {
  opacity: 1;
}

.ui-box {
  width: 100%;
  max-width: 340px;
  padding: 18px;
  border-radius: 16px;
  background: #fffdf7;
  border: 1px solid rgba(184, 137, 43, 0.35);
  box-shadow: 0 30px 60px -30px rgba(60, 44, 14, 0.8);
}

.ui-box h3 {
  margin: 0 0 8px;
  font-size: 15px;
  color: #3d3323;
}

.ui-text {
  margin: 0 0 10px;
  font-size: 13px;
  line-height: 1.7;
  color: #7a6f5c;
}

.ui-input {
  width: 100%;
  box-sizing: border-box;
  height: 38px;
  margin-bottom: 12px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fbf8f1;
  font: inherit;
  font-size: 13.5px;
  color: #3d3323;
  outline: none;
}

.ui-input:focus {
  border-color: rgba(184, 137, 43, 0.7);
}

.ui-acts {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

.chat-tip {
  margin: 0 0 6px;
  font-size: 12px;
  color: #b8892b;
  min-height: 0;
}


html.chat-open,
html.chat-open body {
  overflow: hidden;
  touch-action: none;
}

html.chat-open .chat-body {
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}


/* 会话工具折叠菜单 */
.more-wrap {
  position: relative;
  display: flex;
  justify-content: flex-end;
  margin: 8px 0;
}

.more-menu {
  position: absolute;
  top: 38px;
  right: 0;
  z-index: 30;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 132px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fffdf7;
  box-shadow: 0 18px 36px -18px rgba(60, 44, 14, 0.55);
}

.more-menu .btn-sm {
  width: 100%;
  text-align: left;
}


/* 顶部导航菜单 */
.nav-menu {
  position: absolute;
  top: 62px;
  right: 16px;
  z-index: 60;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 150px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fffdf7;
  box-shadow: 0 20px 40px -20px rgba(60, 44, 14, 0.6);
}

.nav-menu .nm {
  padding: 9px 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 13.5px;
  text-align: left;
  cursor: pointer;
}

.nav-menu .nm.on {
  background: #fff8e6;
  color: #8a6a24;
  font-weight: 600;
}

.news-wrap-dummy { display: none; }

/* 头部一行的「更多」 */
.block-head .more-wrap {
  margin: 0 0 0 auto;
  justify-content: flex-end;
}

.block-head .more-menu {
  top: 34px;
}


/* 进入聊天时：极简模式，隐藏标签栏，聊天框放大 */
body.chat-mode .admin-tabs {
  display: none;
}

body.chat-mode .admin-tabs {
  display: none;
}

body.chat-mode .wrap {
  height: auto;
  padding: 8px 12px 12px;
}

body.chat-mode .admin-pane[data-pane="msg"] > .block {
  margin: 0;
  padding: 12px;
}

body.chat-mode .block-head {
  margin-bottom: 8px;
}

/* 聊天区固定高度：一屏能看到回复框，历史消息在框内滚动 */
body.chat-mode .chat-thread {
  max-height: min(54vh, 520px);
  min-height: 180px;
  overflow-y: auto;
}

body.chat-mode .chat-send-row {
  margin-bottom: 0;
}

@media (max-width: 480px) {
  body.chat-mode .chat-thread {
    max-height: min(46vh, 420px);
  }
}



/* 会话分类切换 */
.chat-seg {
  display: flex;
  gap: 6px;
  margin: 4px 0 12px;
}

.chat-seg {
  flex-wrap: wrap;
}

.chat-seg .seg {
  flex: 0 0 auto;
  min-width: 0;
  padding: 6px 14px;
  border: 1px solid var(--line);
  border-radius: 99px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-size: 12.5px;
  cursor: pointer;
}

.chat-seg .seg.on {
  border-color: rgba(184, 137, 43, 0.6);
  background: #fff8e6;
  color: #8a6a24;
  font-weight: 600;
}

/* 列表项里的备注按钮 */
.msg-item {
  position: relative;
}

.note-btn {
  position: absolute;
  right: 12px;
  bottom: 12px;
  padding: 3px 10px;
  border: 1px solid rgba(184, 137, 43, 0.35);
  border-radius: 99px;
  background: #fffdf7;
  color: #8a6a24;
  font: inherit;
  font-size: 11.5px;
  cursor: pointer;
}

.note-btn:hover {
  border-color: rgba(184, 137, 43, 0.8);
}

/* 长按 / 右键菜单 */
.item-menu {
  position: fixed;
  z-index: 1500;
  display: flex;
  flex-direction: column;
  min-width: 132px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fffdf7;
  box-shadow: 0 20px 40px -18px rgba(60, 44, 14, 0.6);
}

.item-menu button {
  padding: 9px 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 13px;
  text-align: left;
  cursor: pointer;
}

.item-menu button:hover {
  background: #f6f1e5;
}

.item-menu button.danger {
  color: #c0342e;
}


/* 手机端：聊天头部收紧，返回按钮移到底部 */
.chat-bottom {
  display: none;
  margin-top: 10px;
  text-align: center;
}

.link-btn {
  border: 0;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}

.link-btn:hover {
  color: var(--ink);
}

@media (max-width: 560px) {
  .chat-bottom {
    display: block;
  }

  body.chat-mode .block-head #chatBack {
    display: none;
  }

  body.chat-mode .block-head {
    flex-wrap: wrap;
    gap: 6px;
  }

  body.chat-mode .block-head .btn-sm {
    padding: 5px 10px;
    font-size: 12px;
  }

  body.chat-mode .block-head h2 {
    font-size: 15px;
    max-width: 46vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}


/* 访问统计 */
.stat-cards {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}

.stat-card {
  padding: 12px 10px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fffdf7;
  text-align: center;
}

.stat-card b {
  display: block;
  font-size: 22px;
  line-height: 1.2;
  color: #0e2a48;
}

.stat-card span {
  font-size: 11.5px;
  color: var(--muted);
}

.chart {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 130px;
  padding: 10px 6px 0;
  margin-bottom: 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fbf8f1;
  overflow-x: auto;
}

.chart .bar {
  flex: 1 0 14px;
  min-width: 14px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  height: 100%;
}

.chart .bar i {
  width: 100%;
  max-width: 18px;
  border-radius: 4px 4px 0 0;
  background: linear-gradient(180deg, #f0cd83, #c99b3c);
}

.chart .bar em {
  margin-top: 4px;
  font-style: normal;
  font-size: 9px;
  color: #b6a98f;
  transform: scale(0.9);
}

.top-pages .row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 0;
  border-bottom: 1px dashed rgba(184, 137, 43, 0.18);
  font-size: 13px;
}

.top-pages .row:last-child {
  border-bottom: 0;
}

.top-pages .row span {
  flex: 1;
  color: #3d5069;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.top-pages .row b {
  color: #8a6a24;
}

.visit-list {
  max-height: 420px;
  overflow-y: auto;
}

.visit-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px dashed rgba(184, 137, 43, 0.16);
  font-size: 12.5px;
}

.visit-row em {
  flex: 0 0 auto;
  font-style: normal;
  color: var(--faint);
  font-size: 11.5px;
}

.visit-row .ip {
  flex: 0 0 auto;
  color: #0e2a48;
  font-weight: 600;
}

.visit-row .uri {
  flex: 1;
  color: #3d5069;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.visit-row .dev {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 11.5px;
}

@media (max-width: 560px) {
  .stat-cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .visit-row .dev {
    display: none;
  }
}


/* 访问统计：日期选择与每日汇总 */
.visit-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 14px;
}

.visit-date {
  height: 34px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fffdf7;
  font: inherit;
  font-size: 13px;
  color: var(--ink);
}

.day-list {
  max-height: 260px;
  overflow-y: auto;
}

.day-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 12.5px;
  cursor: pointer;
}

.day-row:hover {
  background: #f6f1e5;
}

.day-row.on {
  background: #fff8e6;
  font-weight: 600;
}

.day-row span {
  flex: 1;
  color: #3d5069;
}

.day-row i {
  font-style: normal;
  color: var(--muted);
}

.day-row b {
  min-width: 62px;
  text-align: right;
  color: #8a6a24;
}


.stat-card.live b {
  color: #c0342e;
}

.visit-row .where {
  flex: 0 1 auto;
  max-width: 130px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #8a6a24;
  font-size: 11.5px;
}

@media (max-width: 560px) {
  .stat-cards {
    grid-template-columns: repeat(2, 1fr);
  }
  .visit-row .where {
    display: none;
  }
}


/* 中奖记录：日期在上、主肖带特码 */
.xs-hist-row {
  grid-template-columns: 104px 62px 1fr 52px;
}

.h-left {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.h-left .h-date {
  font-size: 10.5px;
  color: #8aa0b6;
}

.h-left .h-issue {
  font-weight: 600;
  font-size: 12.5px;
}

.h-main .sp {
  margin-left: 5px;
  padding: 0 5px;
  border-radius: 999px;
  background: #eef2f7;
  color: #0e2a48;
  font-family: var(--digit);
  font-size: 11px;
  font-style: normal;
}

@media (max-width: 620px) {
  .xs-hist-row {
    grid-template-columns: 92px 58px 1fr 44px;
  }
}


/* 手机上也要显示日期 */
@media (max-width: 620px) {
  .h-left .h-date {
    display: block;
  }
}


/* 最新开奖：开奖号码依次掉落 */
@keyframes nb-drop {
  0%   { transform: translateY(-26px) scale(0.86); opacity: 0; }
  55%  { opacity: 1; }
  75%  { transform: translateY(3px) scale(1.03); }
  100% { transform: none; opacity: 1; }
}

#drawBalls .nb {
  animation: nb-drop 0.52s cubic-bezier(0.22, 1.15, 0.36, 1) both;
}

#drawBalls > *:nth-child(1) { animation-delay: 0.04s; }
#drawBalls > *:nth-child(2) { animation-delay: 0.14s; }
#drawBalls > *:nth-child(3) { animation-delay: 0.24s; }
#drawBalls > *:nth-child(4) { animation-delay: 0.34s; }
#drawBalls > *:nth-child(5) { animation-delay: 0.44s; }
#drawBalls > *:nth-child(6) { animation-delay: 0.54s; }
#drawBalls > *:nth-child(7) { animation-delay: 0.64s; }
#drawBalls > *:nth-child(8) { animation-delay: 0.80s; }

@media (prefers-reduced-motion: reduce) {
  #drawBalls .nb { animation: none; }
}


/* 当天访客列表 */
.visitor-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.visitor {
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fffdf7;
  cursor: pointer;
}

.visitor:hover {
  border-color: rgba(184, 137, 43, 0.5);
}

.v-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}

.v-ip {
  color: #0e2a48;
  font-size: 13.5px;
}

.v-geo {
  flex: 1;
  color: #8a6a24;
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.v-dev,
.v-n {
  color: var(--muted);
  font-size: 11.5px;
}

.v-n {
  color: #16a34a;
}

.v-sub {
  margin-top: 3px;
  font-size: 11.5px;
  color: var(--faint);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.v-items {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px dashed rgba(184, 137, 43, 0.2);
}

.v-item {
  display: flex;
  gap: 10px;
  padding: 3px 0;
  font-size: 12px;
  color: #3d5069;
}

.v-item em {
  font-style: normal;
  color: var(--faint);
}

.stat-card.link {
  cursor: pointer;
}

.stat-card.link:hover {
  border-color: rgba(184, 137, 43, 0.6);
}


/* 今日摘要行 */
.visit-today {
  margin: -6px 0 12px;
  font-size: 12px;
  color: var(--muted);
}

/* 访客详情弹层 */
.v-modal {
  position: fixed;
  inset: 0;
  z-index: 1500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(20, 16, 8, 0.45);
  opacity: 0;
  transition: opacity 0.18s ease;
}

.v-modal.in {
  opacity: 1;
}

.v-modal-box {
  width: 100%;
  max-width: 520px;
  max-height: 82vh;
  display: flex;
  flex-direction: column;
  border-radius: 16px;
  border: 1px solid rgba(184, 137, 43, 0.3);
  background: #fffdf7;
  overflow: hidden;
}

.v-modal-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(184, 137, 43, 0.18);
  background: #fffdf6;
}

.v-modal-head b {
  flex: 1;
  font-size: 14px;
  color: #0e2a48;
}

.v-modal-body {
  padding: 12px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.stat-cards {
  grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 560px) {
  .stat-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}


.tag.ok {
  background: #eafaf1;
  color: #12805a;
}

.white-btn {
  padding: 2px 8px;
  border: 1px solid rgba(184, 137, 43, 0.35);
  border-radius: 99px;
  background: #fffdf7;
  color: #8a6a24;
  font: inherit;
  font-size: 11px;
  cursor: pointer;
}

.white-btn.on {
  background: #fff8e6;
  border-color: rgba(184, 137, 43, 0.8);
  font-weight: 600;
}


/* 访客行：机型/地址在前，标签在后，按钮最右 */
.v-head {
  align-items: center;
}

.v-head .v-dev {
  flex: 0 0 auto;
  padding: 1px 8px;
  border-radius: 99px;
  background: #f3efe4;
  color: #6b5f4a;
  font-size: 11px;
}

.v-head .v-geo {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 12.5px;
  color: #3d5069;
}

.v-head .v-n {
  flex: 0 0 auto;
  color: #16a34a;
}

.v-head .white-btn {
  flex: 0 0 auto;
  margin-left: 4px;
}

.v-sub {
  margin-top: 5px;
}


/* 访客行不换行，长地址省略，按钮固定最右 */
.v-head {
  flex-wrap: nowrap;
  overflow: hidden;
}

.v-head .v-geo {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 560px) {
  .v-head {
    flex-wrap: wrap;
  }

  .v-head .v-geo {
    flex: 1 1 100%;
    order: 3;
    text-align: left;
  }

  .v-head .white-btn {
    order: 4;
  }
}


.tag {
  white-space: nowrap;
  flex: 0 0 auto;
}


/* 访客详情弹层：收小一点，别挡住上面 */
.v-modal-box {
  max-width: 460px;
  max-height: 68vh;
}

.v-modal-head {
  padding: 9px 12px;
}

.v-modal-head b {
  font-size: 13px;
}

.v-modal-body {
  padding: 10px;
  gap: 6px;
}

#vModal .visitor {
  padding: 8px 10px;
}

#vModal .v-head .v-dev {
  padding: 1px 6px;
  font-size: 10.5px;
}

#vModal .v-head .v-geo {
  font-size: 12px;
}

#vModal .v-n {
  font-size: 11px;
}

#vModal .tag {
  font-size: 10px;
  padding: 1px 6px;
}

#vModal .white-btn {
  font-size: 10.5px;
  padding: 2px 7px;
}

#vModal .v-sub {
  font-size: 11px;
  margin-top: 4px;
}

#vModal .v-item {
  font-size: 11.5px;
}


/* ============================================================
   网站「联系我们」聊天框：收小、靠右下，跟后台风格一致
   ============================================================ */

.chat-mask {
  align-items: flex-end;
  justify-content: flex-end;
  padding: 14px;
  background: rgba(20, 16, 8, 0.26);
}

.chat-box {
  width: 340px;
  max-width: calc(100vw - 28px);
  height: auto;
  max-height: min(58vh, 460px);
  border-radius: 16px;
  border: 1px solid rgba(184, 137, 43, 0.28);
  box-shadow: 0 22px 44px -22px rgba(60, 44, 14, 0.55);
}

.chat-head {
  padding: 9px 12px;
}

.chat-head b {
  font-size: 13.5px;
}

.chat-head span {
  font-size: 11px;
}

.chat-body {
  padding: 10px;
  min-height: 120px;
  max-height: 300px;
}

.chat-msg {
  margin-bottom: 7px;
}

.chat-msg span {
  padding: 7px 10px;
  font-size: 12.5px;
  border-radius: 10px;
}

.chat-foot {
  padding: 8px 10px 10px;
}

.chat-ta {
  min-height: 38px;
  padding: 7px 9px;
  font-size: 12.5px;
}

.chat-send {
  flex: 0 0 58px;
  font-size: 13px;
}

.chat-pic {
  flex: 0 0 34px;
  font-size: 15px;
}

.chat-tip {
  font-size: 11.5px;
}

@media (max-width: 560px) {
  .chat-mask {
    padding: 10px;
  }

  .chat-box {
    width: calc(100vw - 20px);
    max-height: 62vh;
  }
}


/* 访客第二行：IP + 单个时间 + 页面，颜色加深 */
.v-sub {
  display: flex;
  align-items: baseline;
  gap: 8px;
  color: #43566d;
  font-size: 11.5px;
}

.v-sub b {
  color: #0e2a48;
  font-weight: 600;
}

.v-sub em {
  flex: 0 0 auto;
  font-style: normal;
  font-weight: 600;
  color: #b8862b;
  background: #fdf6e3;
  padding: 0 5px;
  border-radius: 4px;
}

.v-sub span {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #5b6b7f;
}

@media (max-width: 560px) {
  .v-sub span {
    display: none;
  }
}


/* 聊天框：贴底、随可视区域变化，输入法弹出时整体不动 */
.chat-mask {
  position: fixed;
  inset: 0;
  align-items: flex-end;
  justify-content: flex-end;
  padding-bottom: max(14px, env(safe-area-inset-bottom));
}

.chat-box {
  transform-origin: bottom right;
}

/* 键盘弹出时页面高度变小，让聊天框自己缩，不要被顶飞 */
@media (max-width: 560px) {
  .chat-mask {
    padding: 8px 10px max(8px, env(safe-area-inset-bottom));
  }

  .chat-box {
    max-height: calc(100dvh - 24px);
  }

  .chat-body {
    max-height: none;
    flex: 1 1 auto;
  }
}


/* 用绝对定位钉住右下角，输入法弹出时不会跑偏 */
.chat-mask {
  display: block;
  padding: 0;
}

.chat-box {
  position: absolute;
  right: 14px;
  bottom: max(14px, env(safe-area-inset-bottom));
  margin: 0;
}

@media (max-width: 560px) {
  .chat-box {
    left: 10px;
    right: 10px;
    width: auto;
    max-width: none;
    bottom: max(10px, env(safe-area-inset-bottom));
  }
}


/* 入场动画结束后回到原位，别往下沉 */
.chat-mask.in .chat-box {
  transform: none;
}


/* 强制归位（防止其它规则把聊天框往下推 14px） */
.chat-mask.in .chat-box,
.chat-box {
  transform: none !important;
}


/* 聊天框：整体再收一档，关闭按钮加大 */
.chat-box {
  width: 300px;
  max-height: min(48vh, 380px);
}

.chat-body {
  min-height: 96px;
  max-height: 210px;
  padding: 9px 9px 4px;
}

.chat-head {
  padding: 8px 10px;
}

.chat-head b {
  font-size: 13px;
}

.chat-head span {
  font-size: 10.5px;
}

.chat-close {
  width: 34px;
  height: 34px;
  margin-left: auto;
  border-radius: 10px;
  background: rgba(184, 137, 43, 0.12);
  color: #6b5b3e;
  font-size: 22px;
  font-weight: 600;
  line-height: 1;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.chat-close:hover {
  background: rgba(184, 137, 43, 0.28);
  color: #3d3323;
}

.chat-foot {
  padding: 7px 9px 9px;
}

.chat-ta {
  min-height: 34px;
  font-size: 12.5px;
  padding: 6px 8px;
}

.chat-send {
  flex: 0 0 52px;
  font-size: 12.5px;
}

.chat-pic {
  flex: 0 0 32px;
  font-size: 14px;
}

.chat-msg span {
  padding: 6px 9px;
  font-size: 12px;
}

@media (max-width: 560px) {
  .chat-box {
    max-height: min(52vh, 400px);
  }

  .chat-body {
    max-height: 190px;
  }

  .chat-close {
    width: 36px;
    height: 36px;
    font-size: 23px;
  }
}


/* ============================================================
   聊天框：回到中间大小，底部居中
   ============================================================ */

.chat-mask {
  display: flex !important;
  align-items: flex-end;
  justify-content: center;
  padding: 12px;
}

.chat-mask .chat-box {
  position: relative !important;
  left: auto;
  right: auto;
  top: auto;
  bottom: auto;
  margin: 0 auto;
  width: 340px;
  max-width: calc(100vw - 24px);
  max-height: min(62vh, 520px);
  transform: none !important;
}

.chat-mask .chat-body {
  min-height: 140px;
  max-height: 300px;
  padding: 10px;
}

.chat-mask .chat-foot {
  padding: 8px 10px 10px;
}

.chat-mask .chat-ta {
  min-height: 40px;
  padding: 7px 9px;
  font-size: 13px;
}

.chat-mask .chat-send {
  flex: 0 0 62px;
  font-size: 13.5px;
}

.chat-mask .chat-msg span {
  padding: 8px 10px;
  font-size: 12.5px;
}

@media (max-width: 560px) {
  .chat-mask {
    padding: 10px;
  }

  .chat-mask .chat-box {
    width: calc(100vw - 20px);
    max-height: 64vh;
  }

  .chat-mask .chat-body {
    max-height: 240px;
  }
}


/* ============================================================
   流畅度优化：手机端少用重特效，聊天/弹层打开时暂停装饰动画
   ============================================================ */

@media (max-width: 768px) {
  /* 模糊很吃 GPU，手机上去掉 */
  .draw-card,
  .block,
  .chat-box,
  .ui-box,
  .v-modal-box {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }

  /* 阴影收敛 */
  .draw-card,
  .block,
  .quick-item {
    box-shadow: 0 6px 14px -10px rgba(20, 40, 70, 0.35) !important;
  }

  /* 装饰性无限动画在手机上停下 */
  .qi-star,
  .qi-sun,
  .qi-rocket,
  .qi-horn,
  .ad-fab,
  .meteor-canvas,
  #heroFx {
    animation: none !important;
  }
}

/* 聊天/弹层打开时，背景装饰动画全部暂停，把 CPU 让给输入法 */
html.chat-open .hero,
html.chat-open .draw-card,
html.chat-open .quick-item,
html.modal-open .hero,
html.modal-open .draw-card {
  animation-play-state: paused !important;
}

html.chat-open #heroFx,
html.modal-open #heroFx {
  opacity: 0.35;
  transition: opacity 0.2s ease;
}

/* 聊天框独立成层，输入时不带动整页重排 */
.chat-box {
  contain: layout paint style;
}


/* 手机上用固定像素高度，键盘弹出时不再重排 */
@media (max-width: 560px) {
  .chat-mask .chat-box {
    max-height: 430px;
  }

  .chat-mask .chat-body {
    max-height: 210px;
  }
}


/* 不再整页禁用触摸手势，避免输入法/滚动变慢 */
html.chat-open,
html.chat-open body {
  touch-action: auto;
  overscroll-behavior: none;
}

.chat-mask .chat-box {
  overscroll-behavior: contain;
}


/* 访客 ID 标签 */
.v-id {
  flex: 0 0 auto;
  padding: 1px 7px;
  border-radius: 6px;
  background: #eef4fb;
  color: #2f5d8a;
  font-family: var(--digit, monospace);
  font-size: 10.5px;
  letter-spacing: 0.4px;
}

.v-sub u {
  flex: 0 0 auto;
  text-decoration: none;
  color: #7d93a8;
  font-family: var(--digit, monospace);
  font-size: 10.5px;
}


.v-id.off {
  background: #f2f2f2;
  color: #9aa4ae;
}


/* 联系我们按钮上的未读数 */
.ad-fab.contact-fab[data-unread]::before {
  content: attr(data-unread);
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 99px;
  background: #e0403a;
  color: #fff;
  font-size: 10.5px;
  font-weight: 700;
  line-height: 17px;
  text-align: center;
  box-shadow: 0 0 0 2px #fffdf7;
  z-index: 2;
}


/* 有数字徽标时不再画小红点 */
.contact-fab.has-new[data-unread]::after {
  display: none;
}


/* 联系我们未读数：真实元素，避免和 ::before 图标冲突 */
.contact-fab {
  position: fixed;
}

.fab-badge {
  position: absolute;
  top: -7px;
  right: -7px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border-radius: 99px;
  background: #e0403a;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
  box-shadow: 0 0 0 2px #fffdf7, 0 2px 6px rgba(224, 64, 58, 0.5);
  z-index: 3;
  pointer-events: none;
}

.fab-badge[hidden] {
  display: none !important;
}

/* 有数字徽标时不再画小红点 */
.contact-fab.has-new::after {
  display: none;
}


/* 联系消息：多选 */
.msg-item {
  position: relative;
}

.msg-item.sel {
  border-color: #d6a043;
  background: #fff9ea;
  box-shadow: 0 0 0 2px rgba(214, 160, 67, 0.25);
}

.msel-box {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 18px;
  height: 18px;
  border: 2px solid #c9c0ae;
  border-radius: 50%;
  background: #fff;
}

.msg-item.sel .msel-box {
  border-color: #16a34a;
  background: #16a34a;
}

.msg-item.sel .msel-box::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 1px;
  width: 5px;
  height: 9px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.multi-bar {
  position: fixed;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  z-index: 900;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fffdf7;
  box-shadow: 0 18px 40px -20px rgba(60, 44, 14, 0.6);
}

.multi-bar span {
  font-size: 12.5px;
  color: var(--muted);
  margin-right: 4px;
}


/* 多选按钮：放在黑名单右侧 */
.chat-seg .multi-btn {
  margin-left: auto;
  border-style: dashed;
  color: #8a6a24;
}

.chat-seg .multi-btn.solid {
  border-style: solid;
  background: #fff8e6;
  font-weight: 600;
}


/* 底部导航：不透明 + 永远压在最上层 */
.tabbar {
  background: #f5f1e8 !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  z-index: 200 !important;
  box-shadow: 0 -6px 16px -12px rgba(40, 30, 10, 0.4);
}

/* 手机端给底部留够位置，内容不要钻到导航下面 */
@media (max-width: 768px) {
  .wrap {
    padding-bottom: calc(74px + env(safe-area-inset-bottom)) !important;
  }
}

.stat-card.live.link {
  cursor: pointer;
}

.stat-card.live.link:hover {
  border-color: rgba(224, 64, 58, 0.5);
}


/* 手机上不要横向溢出（否则底部导航会被撑宽、第四项跑出屏幕） */
@media (max-width: 768px) {
  html, body {
    overflow-x: hidden;
    max-width: 100vw;
  }

  .hb-tabs,
  .hb-plays {
    flex-wrap: wrap;
  }

  .hb-tab,
  .hb-play {
    flex: 1 1 auto;
    min-width: 0;
  }
}

/* 底部导航固定占满可视宽度 */
.tabbar {
  width: 100%;
  max-width: 100vw;
  box-sizing: border-box;
}


/* 全局防横向溢出：任何页面都不许把底部导航撑宽 */
html,
body {
  max-width: 100%;
  overflow-x: hidden;
}

.wrap,
main {
  max-width: 100%;
  box-sizing: border-box;
}

/* 大数据页的标签行：超出就横向滚动，不再顶出屏幕 */
.hb-tabs,
.hb-plays {
  display: flex;
  flex-wrap: nowrap;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.hb-tabs::-webkit-scrollbar,
.hb-plays::-webkit-scrollbar {
  display: none;
}

.hb-tab,
.hb-play {
  flex: 0 0 auto;
  white-space: nowrap;
}

/* 底部导航钉死 */
.tabbar {
  position: fixed !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 100% !important;
  max-width: 100vw !important;
  box-sizing: border-box;
}


/* 底部导航：强制按视口宽度排版，4 项等分 */
.tabbar {
  width: 100vw !important;
  max-width: 100vw !important;
  min-width: 0 !important;
  left: 0 !important;
  right: auto !important;
  display: flex !important;
}

.tabbar a {
  flex: 1 1 0 !important;
  min-width: 0 !important;
  max-width: none !important;
}


/* 底部四个导航：任何屏幕宽度都显示（原来宽屏会被隐藏） */
.tabbar {
  display: flex !important;
}


/* 底部导航：压过所有页面元素（占卜引导层、弹层等） */
.tabbar {
  z-index: 9999 !important;
  display: flex !important;
  visibility: visible !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

/* 占卜页的引导层结束后不要挡住导航 */
.intro.done {
  z-index: 0 !important;
  pointer-events: none !important;
}


/* 联系我们：聊天时盖住底部导航，恢复原来的浮层样式 */
.chat-mask {
  z-index: 10000 !important;
  align-items: flex-end !important;
  justify-content: center !important;
  padding: 12px !important;
}

html.chat-open .tabbar {
  display: none !important;
}

.chat-mask .chat-box {
  position: relative !important;
  left: auto !important;
  right: auto !important;
  top: auto !important;
  bottom: auto !important;
  margin: 0 auto !important;
  width: 340px !important;
  max-width: calc(100vw - 24px) !important;
  max-height: min(62vh, 520px) !important;
  border-radius: 16px !important;
}

@media (max-width: 560px) {
  .chat-mask .chat-box {
    width: calc(100vw - 20px) !important;
    max-height: 430px !important;
  }
}


/* 聊天框：位置略抬高，动画更快 */
.chat-mask {
  padding-bottom: 46px !important;
  transition: opacity 0.12s ease !important;
}

.chat-mask .chat-box {
  transition: none !important;
}

body.chat-open .tabbar,
html.chat-open .tabbar {
  display: none !important;
}

body.chat-open {
  overflow: hidden;
}

@media (max-width: 560px) {
  .chat-mask {
    padding-bottom: 52px !important;
  }
}


/* ============================================================
   后台 · 联系消息：对话区固定高度，输入框钉在底部
   ============================================================ */
#chatBox:not([hidden]) {
  display: flex;
  flex-direction: column;
  height: calc(100vh - 210px);
  height: calc(100dvh - 210px);
  max-height: calc(100vh - 210px);
  max-height: calc(100dvh - 210px);
  min-height: 320px;
}

#chatBox .chat-thread {
  flex: 1 1 auto;
  min-height: 0;
  max-height: none;
  margin: 6px 0 8px;
}

#chatBox .chat-send-row {
  flex: none;
  position: sticky;
  bottom: 0;
  background: var(--card-bg, #fffdf7);
  padding-top: 6px;
  z-index: 2;
}

#chatBox .chat-bottom {
  flex: none;
  margin-top: 4px;
}

/* 后台对话字体收小一点 */
#chatBox .chat-msg span {
  font-size: 12.5px;
  line-height: 1.6;
  padding: 7px 10px;
}

#chatBox .chat-msg {
  margin-bottom: 7px;
}

#chatBox .chat-msg .chat-time {
  font-size: 10.5px;
}

#chatBox .chat-ta {
  font-size: 13px;
  min-height: 38px;
}

@media (max-width: 560px) {
  #chatBox:not([hidden]) {
    height: calc(100dvh - 200px);
    max-height: calc(100dvh - 200px);
    min-height: 260px;
  }

  #chatBox .chat-msg span {
    font-size: 12px;
    max-width: 84%;
  }
}


/* 后台对话：占满可视区域，输入框永远在最下面 */
body.chat-fixed #chatBox:not([hidden]) {
  position: fixed;
  left: 8px;
  right: 8px;
  top: 62px;
  bottom: auto;
  z-index: 90;
  display: flex;
  flex-direction: column;
  height: auto;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fffdf7;
  box-shadow: 0 24px 60px -30px rgba(60, 44, 14, 0.55);
  box-sizing: border-box;
}

body.chat-fixed #chatBox .chat-thread {
  flex: 1 1 auto;
  min-height: 0;
  max-height: none;
  margin: 6px 0 8px;
}

body.chat-fixed #chatBox .chat-send-row,
body.chat-fixed #chatBox .chat-bottom {
  flex: none;
}

body.chat-fixed .msg-title-row,
body.chat-fixed #msgTitle {
  flex: none;
}


/* 聊天图片放大：必须盖在聊天框上面 */
.img-zoom {
  z-index: 10060 !important;
  padding: 18px !important;
  box-sizing: border-box;
}

.img-zoom img {
  max-width: min(92vw, 720px) !important;
  max-height: min(78vh, 720px) !important;
  width: auto !important;
  height: auto !important;
  object-fit: contain !important;
  border-radius: 14px !important;
}

.img-zoom-x {
  position: fixed;
  top: calc(14px + env(safe-area-inset-top));
  right: 14px;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  color: #3d3323;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  z-index: 10061;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 22px -8px rgba(0, 0, 0, 0.6);
}

.img-zoom-x:active {
  transform: scale(0.94);
}


/* 放大图再收敛一点，边距更明显 */
.img-zoom { padding: 26px !important; }

.img-zoom img {
  max-width: min(84vw, 560px) !important;
  max-height: min(70vh, 640px) !important;
  border-radius: 16px !important;
}

@media (max-width: 560px) {
  .img-zoom img {
    max-width: 86vw !important;
    max-height: 64vh !important;
  }
}


/* ============================================================
   联系我们：改成全屏聊天页（手机铺满，电脑居中）
   ============================================================ */
.chat-mask {
  align-items: stretch !important;
  justify-content: stretch !important;
  padding: 0 !important;
  background: rgba(12, 9, 3, 0.45) !important;
}

.chat-mask .chat-box {
  display: flex !important;
  flex-direction: column !important;
  width: 100% !important;
  max-width: 100% !important;
  height: 100vh;
  height: 100dvh;
  max-height: none !important;
  margin: 0 !important;
  border-radius: 0 !important;
  background: #fbf7ee !important;
  box-shadow: none !important;
  overflow: hidden;
}

.chat-mask .chat-head {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: calc(14px + env(safe-area-inset-top)) 16px 12px;
  border-bottom: 1px solid var(--line);
  background: #fffdf7;
}

.chat-mask .chat-head b {
  font-size: 16px;
}

.chat-mask .chat-head span {
  font-size: 11.5px;
  color: var(--muted);
}

.chat-mask .chat-close {
  margin-left: auto;
  width: 40px;
  height: 40px;
  font-size: 24px;
  border-radius: 50%;
  background: #f3ede0;
  border: 1px solid var(--line);
  color: #5a4a2a;
}

.chat-mask .chat-body {
  flex: 1 1 auto;
  min-height: 0;
  max-height: none !important;
  overflow-y: auto;
  padding: 14px 14px 8px;
  background: #f7f2e7;
  -webkit-overflow-scrolling: touch;
}

.chat-mask .chat-foot {
  flex: 0 0 auto;
  padding: 8px 12px calc(10px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: #fffdf7;
}

.chat-mask .chat-msg span {
  font-size: 14px;
  line-height: 1.65;
  max-width: 78%;
}

@media (min-width: 900px) {
  .chat-mask {
    align-items: center !important;
    justify-content: center !important;
    padding: 24px !important;
  }

  .chat-mask .chat-box {
    width: 720px !important;
    max-width: 94vw !important;
    height: min(100dvh - 64px, 860px) !important;
    border-radius: 18px !important;
    box-shadow: 0 40px 80px -40px rgba(40, 28, 6, 0.65) !important;
  }
}


/* 聊天顶部固定欢迎语 */
.chat-pinned span {
  background: #fff8e8 !important;
  border: 1px solid rgba(214, 160, 67, 0.35) !important;
  color: #4a3a1c !important;
}

.chat-pinned b {
  color: #b88a2b;
}


/* 固定欢迎语：长文换行、链接可点 */
.chat-pinned span {
  max-width: 92% !important;
  font-size: 13px !important;
  line-height: 1.7 !important;
  word-break: break-word;
}

.chat-pinned a {
  color: #b8860b;
  text-decoration: underline;
  word-break: break-all;
}


/* 聊天全屏页：用 fixed 铺满，输入栏必定在底部 */
.chat-mask .chat-box {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  height: auto !important;
  max-height: none !important;
  overflow: hidden !important;
}

@media (min-width: 900px) {
  .chat-mask .chat-box {
    top: 50% !important;
    left: 50% !important;
    right: auto !important;
    bottom: auto !important;
    transform: translate(-50%, -50%) !important;
    width: 720px !important;
    height: min(88vh, 860px) !important;
  }
}


/* 聊天：引用、撤回、长按操作条 */
.chat-quote {
  display: block;
  font-style: normal;
  font-size: 11.5px;
  color: #8a7340;
  background: rgba(214, 178, 104, 0.16);
  border-left: 2px solid rgba(184, 137, 43, 0.6);
  border-radius: 4px;
  padding: 3px 7px;
  margin-bottom: 4px;
  white-space: normal;
  word-break: break-word;
}

.chat-recalled {
  color: #9c917c !important;
  background: #f1ece1 !important;
  border: 1px dashed rgba(184, 137, 43, 0.3) !important;
  font-size: 12px !important;
  font-style: normal;
}

.chat-msg.recalled span {
  background: #f1ece1 !important;
}

.chat-quote-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 8px;
  padding: 7px 10px;
  border-radius: 10px;
  background: #fff4dd;
  border: 1px solid rgba(214, 160, 67, 0.35);
  font-size: 12px;
  color: #6b5628;
}

.chat-quote-bar span {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chat-quote-x {
  border: 0;
  background: transparent;
  color: #8a7340;
  font-size: 18px;
  line-height: 1;
  padding: 0 2px;
  cursor: pointer;
}

.chat-actions {
  position: fixed;
  left: 50%;
  bottom: 120px;
  transform: translateX(-50%);
  z-index: 10080;
  display: flex;
  gap: 6px;
  padding: 8px;
  border-radius: 14px;
  background: rgba(38, 30, 14, 0.94);
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, 0.7);
}

.chat-actions button {
  border: 0;
  border-radius: 9px;
  padding: 9px 16px;
  font-size: 13.5px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  cursor: pointer;
}

.chat-actions button.danger {
  color: #ff9d94;
}

.chat-actions button:active {
  background: rgba(255, 255, 255, 0.22);
}


/* 首页快捷入口：手机上收紧间距 */
@media (max-width: 560px) {
  .hero-quick {
    gap: 5px !important;
    padding: 0 10px !important;
    margin-top: 8px !important;
  }

  .hero-quick a {
    padding: 8px 2px 7px !important;
    gap: 4px !important;
    border-radius: 11px !important;
    font-size: 10.5px !important;
  }

  .hero-quick .qi {
    width: 30px !important;
    height: 30px !important;
    border-radius: 10px !important;
  }

  .hero-quick .qi-svg,
  .hero-quick .qi svg {
    width: 15px !important;
    height: 15px !important;
  }

  .quick {
    gap: 5px !important;
  }

  .quick a {
    padding: 9px 2px !important;
    font-size: 10.5px !important;
    border-radius: 11px !important;
  }
}


/* 首页：开奖卡片 → 四个入口 → 心水，上下间距收紧（覆盖各种宽度） */
@media (max-width: 900px) {
  .hero {
    padding-bottom: 8px !important;
  }

  .hero-quick {
    margin: 6px auto 0 !important;
    gap: 5px !important;
    padding: 0 10px !important;
  }

  .hero-quick a {
    padding: 8px 2px 7px !important;
    gap: 4px !important;
    border-radius: 11px !important;
    font-size: 10.5px !important;
  }

  .hero-quick .qi {
    width: 30px !important;
    height: 30px !important;
    border-radius: 10px !important;
  }

  .hero-quick .qi svg,
  .hero-quick .qi-svg {
    width: 15px !important;
    height: 15px !important;
  }

  .quick {
    gap: 5px !important;
  }

  .quick a {
    padding: 9px 2px !important;
    font-size: 10.5px !important;
    border-radius: 11px !important;
  }

  /* 心水卡片紧跟入口 */
  .xs-card,
  .xinshui,
  .wrap > .block:first-child {
    margin-top: 10px !important;
  }
}


/* 开奖卡片下方那块 74px 空白去掉 */
@media (max-width: 900px) {
  .hero .wrap.hero-inner,
  .hero-inner {
    padding-bottom: 10px !important;
  }
}


/* 🔔 提醒按钮与面板 */
.xk-bell {
  position: fixed;
  top: calc(10px + env(safe-area-inset-top));
  right: 12px;
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid rgba(184, 137, 43, 0.35);
  background: rgba(255, 253, 247, 0.94);
  color: #8a6a24;
  z-index: 240;
  cursor: pointer;
  box-shadow: 0 8px 18px -12px rgba(60, 44, 14, 0.5);
}

.xk-bell.on {
  color: #b8892b;
  border-color: rgba(214, 160, 67, 0.8);
}

.xk-bell-dot {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #e0403a;
  box-shadow: 0 0 0 2px #fffdf7;
  animation: bell-pulse 1.6s ease-in-out infinite;
}

@keyframes bell-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.25); opacity: 0.75; }
}

.xk-bell-panel {
  position: fixed;
  top: calc(54px + env(safe-area-inset-top));
  right: 12px;
  width: min(300px, calc(100vw - 24px));
  max-height: 60vh;
  overflow-y: auto;
  padding: 8px;
  border-radius: 14px;
  border: 1px solid rgba(184, 137, 43, 0.3);
  background: #fffdf7;
  z-index: 241;
  box-shadow: 0 24px 50px -24px rgba(60, 44, 14, 0.55);
}

.xk-bell-item {
  padding: 9px 10px;
  border-radius: 10px;
  border-bottom: 1px dashed rgba(184, 137, 43, 0.22);
}

.xk-bell-item:last-child {
  border-bottom: 0;
}

.xk-bell-item b {
  display: block;
  font-size: 13px;
  color: #3d3323;
}

.xk-bell-item p {
  margin: 3px 0 2px;
  font-size: 12px;
  line-height: 1.6;
  color: #6b5a35;
  white-space: pre-wrap;
}

.xk-bell-item em {
  font-style: normal;
  font-size: 10.5px;
  color: #a59574;
}

.xk-bell-item.xs b {
  color: #b8892b;
}

.xk-bell-empty {
  margin: 10px;
  font-size: 12.5px;
  color: var(--muted);
}


/* 铃铛挪到左下角，避免挡住顶部日期 */
.xk-bell {
  top: auto !important;
  right: auto !important;
  left: 12px !important;
  bottom: calc(78px + env(safe-area-inset-bottom)) !important;
  width: 36px !important;
  height: 36px !important;
}

.xk-bell-panel {
  top: auto !important;
  right: auto !important;
  left: 12px !important;
  bottom: calc(122px + env(safe-area-inset-bottom)) !important;
  width: min(290px, calc(100vw - 24px)) !important;
}


/* ============================================================
   后台对话：全屏覆盖，输入框钉底
   ============================================================ */
body.chat-fixed #chatBox:not([hidden]) {
  position: fixed !important;
  left: 0 !important;
  right: 0 !important;
  top: 54px !important;
  bottom: 0 !important;
  height: auto !important;
  max-height: none !important;
  margin: 0 !important;
  padding: 10px 14px calc(12px + env(safe-area-inset-bottom)) !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: #fbf7ee !important;
  box-shadow: none !important;
  z-index: 150 !important;
  display: flex !important;
  flex-direction: column !important;
  box-sizing: border-box !important;
}

body.chat-fixed #chatBox .chat-thread {
  flex: 1 1 auto !important;
  min-height: 0 !important;
  max-height: none !important;
  overflow-y: auto !important;
  margin: 0 0 10px !important;
  padding: 12px !important;
  border: 1px solid var(--line) !important;
  border-radius: 14px !important;
  background: #fffdf9 !important;
}

body.chat-fixed #chatBox .chat-send-row {
  flex: none !important;
  position: static !important;
  background: transparent !important;
}

body.chat-fixed #chatBox .chat-bottom {
  flex: none !important;
  margin-top: 6px !important;
}

body.chat-fixed #chatBox .chat-ta {
  font-size: 14px !important;
  min-height: 42px !important;
}

/* 对话打开时把页面本身锁住 */
body.chat-fixed {
  overflow: hidden !important;
}


/* 后台对话：隐藏顶部管理栏，改成对话自己的顶栏 */
body.chat-fixed .appbar,
body.chat-fixed .topbar,
body.chat-fixed .block-head {
  display: none !important;
}

body.chat-fixed #chatBox:not([hidden]) {
  top: 0 !important;
  padding-top: calc(8px + env(safe-area-inset-top)) !important;
}

.adm-chat-head {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 2px 10px;
  border-bottom: 1px solid rgba(184, 137, 43, 0.22);
  margin-bottom: 10px;
}

.adm-chat-left {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.adm-chat-left b {
  font-size: 16px;
  color: #2f2a1d;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.adm-chat-left span {
  font-size: 11.5px;
  color: #b8892b;
}

.adm-chat-close {
  flex: none;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: #f3ede0;
  color: #5a4a2a;
  font-size: 22px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.adm-chat-close:active {
  transform: scale(0.94);
}


/* 后台 / 访客 聊天字体统一（后台再小一点） */
.thread-msg span {
  font-size: 12px !important;
  padding: 7px 10px !important;
  line-height: 1.62 !important;
}

.thread-msg {
  margin-bottom: 7px !important;
}

.chat-mask .chat-msg span {
  font-size: 13px !important;
  line-height: 1.62 !important;
  padding: 8px 11px !important;
}

/* 后台对话标题略小 */
.adm-chat-left b {
  font-size: 15px !important;
}

.adm-chat-left span {
  font-size: 11px !important;
}

/* 后台输入框同步小一点 */
body.chat-fixed #chatBox .chat-ta {
  font-size: 13px !important;
  min-height: 40px !important;
}



/* 聊天输入栏贴近底部，减少和键盘之间的空隙 */
.chat-mask .chat-foot {
  padding-bottom: calc(6px + env(safe-area-inset-bottom)) !important;
}

body.chat-fixed #chatBox {
  padding-bottom: calc(6px + env(safe-area-inset-bottom)) !important;
}



/* ============================================================
   卜卦：蓝色铺满整屏（去掉四周黑边和圆角卡片）
   ============================================================ */
.gua-body {
  background: #0b1d36 !important;
}

.gua-ui {
  background:
    radial-gradient(520px 240px at 50% -20%, rgba(214, 178, 104, 0.18), transparent 70%),
    linear-gradient(165deg, rgba(11, 29, 54, 0.94), rgba(20, 48, 79, 0.94) 55%, rgba(11, 29, 54, 0.96)) !important;
}

.gua-stage {
  background: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}


/* 底部导航 5 项时字号略收 */
.tabbar a {
  font-size: 10.5px;
}


/* ============================================================
   后台 · 访客行为（板块停留 / 停留排行）
   ============================================================ */
.v-sec { display: flex; flex-direction: column; gap: 8px; }
.v-sec-row {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px; border-radius: 11px;
  background: #fbf8f0; border: 1px solid rgba(184, 137, 43, .22);
}
.v-sec-name { width: 46px; flex: none; font-size: 13px; font-weight: 600; color: #3d3323; }
.v-sec-bar { flex: 1; height: 8px; border-radius: 99px; background: rgba(184, 137, 43, .16); overflow: hidden; }
.v-sec-bar i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, #e6c98d, #c9a057); }
.v-sec-meta { flex: none; font-size: 11.5px; color: #8a7c60; font-variant-numeric: tabular-nums; }
.v-sec-meta b { color: #14304f; }

.v-stay { display: flex; flex-direction: column; gap: 6px; }
.v-stay-row {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 8px 11px; border-radius: 10px;
  background: #fffdf8; border: 1px solid rgba(184, 137, 43, .18);
  font-size: 12px; color: #6b5a35;
}
.v-stay-row b { color: #14304f; font-variant-numeric: tabular-nums; }
.v-stay-row .path { color: #8a6a24; }
.v-stay-row .sec {
  padding: 1px 7px; border-radius: 99px; font-size: 10.5px;
  background: rgba(20, 48, 79, .08); color: #2f4a6b;
}
.v-stay-row .stay-time { margin-left: auto; font-weight: 600; color: #b4552a; }


/* 访客卡片：看过什么 + 展开轨迹 */
.v-sub { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.v-toured { flex: 1; min-width: 0; color: #6b5a35; font-size: 12px; }
.v-caret {
  flex: none; font-style: normal; font-size: 11.5px;
  color: #8a6a24; background: #fff7e2; border: 1px solid rgba(214, 160, 67, .45);
  border-radius: 99px; padding: 1px 9px; cursor: pointer;
}
.v-items .v-item span { color: #14304f; }


/* 当天浏览：原始链接（默认折叠） */
.v-raw { margin-top: 14px; border-top: 1px dashed rgba(184, 137, 43, .3); padding-top: 10px; }
.v-raw summary {
  cursor: pointer; font-size: 12px; color: #8a6a24; list-style: none;
  padding: 5px 10px; border-radius: 9px; background: #fff8e8;
  border: 1px solid rgba(214, 160, 67, .4); display: inline-block;
}
.v-raw summary::-webkit-details-marker { display: none; }
.v-raw[open] summary { margin-bottom: 8px; }
.v-raw-row {
  display: flex; align-items: center; gap: 8px; font-size: 11.5px;
  padding: 3px 2px; color: #8a7c60;
}
.v-raw-row em { flex: 1; min-width: 0; font-style: normal; word-break: break-all; }
.v-raw-row span { flex: none; color: #b4552a; font-weight: 600; }


/* 访客弹窗筛选 + 按钮事件徽章 */
.vf-bar { display: flex; gap: 8px; margin: 0 0 12px; flex-wrap: wrap; }
.vf-btn {
  padding: 6px 14px; border-radius: 99px; cursor: pointer;
  border: 1px solid rgba(184, 137, 43, .38); background: #fffdf7;
  color: #6b5a35; font-size: 12.5px;
}
.vf-btn.on { background: #14304f; border-color: #14304f; color: #fff; font-weight: 600; }
.tag.act { background: #fff2cf; color: #8a5a08; border-color: rgba(214, 160, 67, .8); }
.tag.act2 { background: #e8f3ff; color: #1d4fb5; border-color: rgba(29, 79, 181, .45); }
.v-items .v-item.ev span { color: #b4552a; }


/* 「展开」固定在卡片右侧，看过内容超长自动省略 */
.v-sub {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  flex-wrap: nowrap !important;
}
.v-sub .v-toured {
  flex: 1 1 auto !important;
  min-width: 0 !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}
.v-sub .v-caret {
  flex: 0 0 auto !important;
  margin-left: auto !important;
}


/* 当天浏览：按钮点击汇总 */
.ev-box {
  display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 12px;
  padding: 10px 12px; border-radius: 11px;
  background: #fff8e8; border: 1px solid rgba(214, 160, 67, .4);
}
.ev-row { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: #6b5a35; }
.ev-row b { color: #b4552a; font-size: 14px; }
.ev-ppl { color: #8a7c60; font-size: 11.5px; }
.ev-name { font-weight: 600; color: #3d3323; }


/* 心水右列（平肖 / 波色）命中也圈起来打勾 */
.xs-side-value.hit {
  position: relative;
  padding: 1px 7px 2px;
  border-radius: 9px;
  box-shadow: 0 0 0 2px #22c55e, 0 0 14px rgba(34, 197, 94, 0.45);
  animation: xs-ring-pulse 2.4s ease-in-out infinite;
}
.xs-side-value.hit::before {
  content: "✓";
  position: absolute;
  top: -8px;
  right: -8px;
  z-index: 3;
  width: 15px;
  height: 15px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(150deg, #4ade80, #16a34a);
  color: #fff;
  font-size: 9px;
  line-height: 1;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(22, 101, 52, 0.45);
  animation: xs-check-in 0.4s cubic-bezier(0.2, 1.6, 0.4, 1) 0.15s both;
}
