/* Clean 1:1 Video-Styled Second Frontend Stylesheet (Zero Ads / Dynamic Domain / 3 Lotteries) */
:root {
  --bg-body: #e6eaf2;
  --bg-page: #f3f5f9;
  --bg-card: #ffffff;
  --red-ball: #e52232;
  --blue-ball: #1a76d2;
  --green-ball: #169c4b;
  --green-brand: #10a852;
  --blue-sec-top: #6d8dc9;
  --blue-sec-bot: #4f70b2;
  --text-primary: #141b29;
  --text-secondary: #526075;
  --border-light: #dce3ee;
  --border-mid: #c5d0e0;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  background: var(--bg-body);
  color: var(--text-primary);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 14px;
  line-height: 1.4;
  overflow-x: hidden;
}

.app-shell {
  max-width: 560px;
  margin: 0 auto;
  background: var(--bg-page);
  min-height: 100vh;
  padding-bottom: 68px;
  box-shadow: 0 0 28px rgba(15, 23, 42, 0.12);
  position: relative;
}

/* ================= STICKY TOP HEADER ================= */
.sticky-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: #ffffff;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.1);
}

.brand-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 12px;
  background: linear-gradient(180deg, #ffffff 0%, #e1eafb 58%, #98b3e6 100%);
  border-bottom: 1px solid #9ab2df;
  min-height: 52px;
  gap: 8px;
}

.dynamic-logo {
  display: flex;
  align-items: flex-end;
  cursor: pointer;
  user-select: none;
  min-width: 0;
  flex: 1;
}

.logo-main-blue {
  font-family: "Arial Black", "Helvetica Neue", Impact, sans-serif;
  font-size: clamp(24px, 6.5vw, 35px);
  font-weight: 900;
  line-height: 0.94;
  color: #0924f0;
  text-shadow: 1.5px 1.5px 0 #fff, -1.5px -1.5px 0 #fff, 1.5px -1.5px 0 #fff, -1.5px 1.5px 0 #fff, 0 2px 4px rgba(0, 0, 0, 0.3);
  letter-spacing: -0.8px;
}

.logo-main-red {
  font-family: "Arial Black", "Helvetica Neue", Impact, sans-serif;
  font-size: clamp(24px, 6.5vw, 35px);
  font-weight: 900;
  line-height: 0.94;
  color: #f0111d;
  text-shadow: 1.5px 1.5px 0 #fff, -1.5px -1.5px 0 #fff, 1.5px -1.5px 0 #fff, -1.5px 1.5px 0 #fff, 0 2px 4px rgba(0, 0, 0, 0.3);
  letter-spacing: -0.8px;
}

.logo-suffix-stack {
  display: flex;
  flex-direction: column;
  margin-left: 4px;
  line-height: 1.05;
}

.logo-badge-top {
  background: #ffee00;
  color: #d90814;
  font-size: 10.5px;
  font-weight: 900;
  padding: 1px 4px;
  border-radius: 3px;
  border: 1px solid #f59e0b;
  white-space: nowrap;
  text-align: center;
}

.logo-tld {
  font-family: "Arial Black", sans-serif;
  font-size: clamp(16px, 4.2vw, 20px);
  font-weight: 900;
  color: #f0111d;
  text-shadow: 1px 1px 0 #fff, -1px -1px 0 #fff, 1px -1px 0 #fff, -1px 1px 0 #fff;
  margin-top: -1px;
}

.logo-fallback-title {
  display: flex;
  align-items: center;
  gap: 8px;
}
.logo-fallback-mark {
  background: linear-gradient(135deg, #1d4ed8, #0f172a);
  color: #ffffff;
  font-weight: 900;
  font-size: 16px;
  padding: 4px 8px;
  border-radius: 7px;
  border: 1px solid #60a5fa;
}
.logo-fallback-text {
  font-size: 21px;
  font-weight: 900;
  color: #0f256e;
  text-shadow: 1px 1px 0 #fff;
}

.active-game-capsule {
  border: 2px solid #169c4b;
  background: #ffffff;
  border-radius: 9px;
  padding: 3px 12px;
  font-size: 18px;
  font-weight: 900;
  color: #169c4b;
  box-shadow: inset 0 0 4px rgba(0,0,0,0.06), 0 1px 3px rgba(0,0,0,0.12);
  white-space: nowrap;
  cursor: pointer;
  flex-shrink: 0;
}
.active-game-capsule[data-game="90004"] {
  border-color: #1a76d2;
  color: #1a76d2;
}
.active-game-capsule[data-game="90001"] {
  border-color: #e52232;
  color: #e52232;
}

/* 3-Lottery Switcher Bar (ONLY 澳门新彩, 澳彩, 港彩) */
.lottery-tabs-bar {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  padding: 5px 8px;
  background: linear-gradient(180deg, #f8fafd, #e6ecf5);
  border-bottom: 1px solid var(--border-mid);
}

.lottery-tab {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 36px;
  border-radius: 18px;
  border: 1px solid #cdd6e5;
  background: #f2f5fa;
  font-size: 16px;
  font-weight: 900;
  color: #1e293b;
  cursor: pointer;
  transition: all 0.16s ease;
  user-select: none;
}

.lottery-tab svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.lottery-tab.active[data-game="90002"] {
  background: linear-gradient(90deg, #12a14c, #1ebc60);
  color: #ffffff;
  border-color: #0e873e;
  box-shadow: 0 2px 6px rgba(18, 161, 76, 0.32);
}
.lottery-tab.active[data-game="90004"] {
  background: linear-gradient(90deg, #2563eb, #3b82f6);
  color: #ffffff;
  border-color: #1d4ed8;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.32);
}
.lottery-tab.active[data-game="90001"] {
  background: linear-gradient(90deg, #dc2626, #f43f5e);
  color: #ffffff;
  border-color: #b91c1c;
  box-shadow: 0 2px 6px rgba(220, 38, 38, 0.32);
}

/* Sticky 7-Ball Mini Draw Strip */
.mini-draw-strip {
  display: grid;
  grid-template-columns: 76px repeat(6, 1fr) 22px 1fr;
  align-items: stretch;
  background: #ffffff;
  border-bottom: 1px solid var(--border-mid);
}

.mds-left {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2px;
  border-right: 1px solid var(--border-light);
}
.mds-issue {
  font-size: 13px;
  font-weight: 900;
  color: #111827;
}
.mds-hist-btn {
  background: #ffee00;
  color: #d90814;
  border: 1px solid #facc15;
  border-radius: 3px;
  padding: 0 5px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  line-height: 1.3;
  margin-top: 1px;
}

.mds-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  border-right: 1px solid #f1f5f9;
}
.mds-num {
  width: 100%;
  text-align: center;
  color: #ffffff;
  font-size: 16px;
  font-weight: 900;
  line-height: 21px;
  font-family: Arial, Helvetica, sans-serif;
}
.mds-num.red { background: var(--red-ball); }
.mds-num.blue { background: var(--blue-ball); }
.mds-num.green { background: var(--green-ball); }

.mds-sx {
  width: 100%;
  text-align: center;
  font-size: 14px;
  font-weight: 800;
  color: #1f2937;
  background: #f8fafc;
  line-height: 20px;
}

.mds-refresh {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #ffee00;
  color: #d90814;
  font-size: 11px;
  font-weight: 900;
  line-height: 1.15;
  cursor: pointer;
  user-select: none;
}

/* ================= CLEAN DYNAMIC HERO BANNER & NOTICE ================= */
.hero-banner-card {
  position: relative;
  width: 100%;
  aspect-ratio: 960 / 380;
  background: #0a2e27;
  --hero-loop: url("../assets/hero-right-90002-v4.webp");
  --hero-poster: url("../assets/hero-right-90002-poster-v4.webp");
  overflow: hidden;
  display: flex;
  align-items: center;
  padding: 12px 16px;
}

/* Right-aligned portraits; text is independent of the four-second image loop. */
.hero-banner-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--hero-loop) center / cover no-repeat;
}
.hero-banner-card[data-game="90004"] {
  --hero-loop: url("../assets/hero-right-90004-v4.webp");
  --hero-poster: url("../assets/hero-right-90004-poster-v4.webp");
}
.hero-banner-card[data-game="90001"] {
  --hero-loop: url("../assets/hero-right-90001-v4.webp");
  --hero-poster: url("../assets/hero-right-90001-poster-v4.webp");
}
.hero-banner-card.is-motion-paused::before { background-image: var(--hero-poster); }
@media (prefers-reduced-motion: reduce) {
  .hero-banner-card::before { background-image: var(--hero-poster); }
}

.hero-text-overlay {
  position: relative;
  z-index: 2;
  max-width: 48%;
  margin-left: 18%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

.hero-kicker {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.hero-tag {
  font-size: 11px;
  font-weight: 900;
  color: #ffffff;
  padding: 2px 7px;
  border-radius: 10px;
}
.hero-tag.g1 { background: #16a34a; }
.hero-tag.g2 { background: #2563eb; }
.hero-tag.g3 { background: #e11d48; }

.hero-headline {
  font-size: clamp(19px, 5vw, 25px);
  font-weight: 900;
  color: #ffffff;
  line-height: 1.2;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
}
.hero-headline span {
  display: block;
  color: #fde047;
}

.hero-domain-pill:empty {
  display: none;
}

.hero-domain-pill {
  background: linear-gradient(90deg, #facc15, #fde047);
  color: #991b1b;
  font-size: clamp(13px, 3.6vw, 16px);
  font-weight: 900;
  padding: 4px 12px;
  border-radius: 20px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero-subtext {
  font-size: 12px;
  font-weight: 800;
  color: #dbeafe;
  letter-spacing: 0.5px;
}

@media (max-width: 420px) {
  .hero-banner-card { padding: 8px 10px; }
  .hero-text-overlay { gap: 4px; }
  .hero-tag { font-size: 10px; padding: 2px 5px; }
  .hero-headline { font-size: clamp(16px, 4.4vw, 22px); }
  .hero-subtext { font-size: 10px; line-height: 1.3; letter-spacing: 0; white-space: nowrap; }
}
@media (max-width: 360px) {
  .hero-text-overlay { gap: 3px; }
  .hero-tag { font-size: 9px; }
  .hero-headline { font-size: 16px; }
  .hero-subtext { font-size: 9px; }
}

/* Scrolling Notice Bar */
.notice-strip {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  padding: 7px 12px;
  border-bottom: 1px solid var(--border-light);
}
.notice-icon {
  color: #f97316;
  flex-shrink: 0;
  display: flex;
  align-items: center;
}
.notice-marquee {
  flex: 1;
  overflow: hidden;
  white-space: nowrap;
}
.notice-marquee-inner {
  display: inline-block;
  font-size: 14px;
  font-weight: 700;
  color: #1e293b;
  animation: marquee-scroll 18s linear infinite;
}
@keyframes marquee-scroll {
  0% { transform: translateX(15%); }
  100% { transform: translateX(-100%); }
}

/* ================= 4 CORE FEATURE SHORTCUTS (Same as Figure 3) ================= */
.shortcut-4grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  padding: 10px;
  background: #ffffff;
  border-bottom: 1px solid var(--border-light);
}

.sc-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 8px 4px;
  border-radius: 10px;
  background: #f8fafd;
  border: 1px solid #e5ecf6;
  cursor: pointer;
  transition: transform 0.12s, background 0.12s;
}
.sc-card:active {
  transform: scale(0.97);
  background: #eef3fb;
}
.sc-icon-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  margin-bottom: 5px;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);
}
.sc-icon-circle.c-live { background: linear-gradient(135deg, #10b981, #059669); }
.sc-icon-circle.c-data { background: linear-gradient(135deg, #3b82f6, #1d4ed8); }
.sc-icon-circle.c-tuku { background: linear-gradient(135deg, #ef4444, #dc2626); }
.sc-icon-circle.c-trend { background: linear-gradient(135deg, #06b6d4, #0284c7); }
.sc-label {
  font-size: 14px;
  font-weight: 900;
  color: #1e293b;
}

/* ================= 3 LOTTERY DRAW CARDS (1:1 Video Style) ================= */
.draw-cards-stack {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 8px 0;
}

.draw-card {
  background: #ffffff;
  border-top: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
  padding: 10px 10px 8px;
  transition: border-color 0.2s;
}
.draw-card.is-selected {
  border-left: 4px solid var(--green-brand);
}

.dc-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
  font-size: 15px;
  font-weight: 900;
}
.dc-game-title {
  color: #1e293b;
}
.dc-game-title .issue-hl {
  color: #16a34a;
  margin: 0 2px;
}
.dc-timer {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 16px;
  font-weight: 900;
  color: #d90814;
  background: #fff1f2;
  padding: 1px 8px;
  border-radius: 12px;
}
.dc-hist-link {
  color: #16a34a;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  text-decoration: none;
}

.dc-balls-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr) 20px 1fr;
  align-items: center;
  gap: 5px;
  margin-bottom: 8px;
}

.rect-ball {
  border-radius: 7px;
  overflow: hidden;
  border: 2px solid var(--green-ball);
  background: #ffffff;
  text-align: center;
}
.rect-ball.red { border-color: var(--red-ball); }
.rect-ball.blue { border-color: var(--blue-ball); }
.rect-ball.green { border-color: var(--green-ball); }

.rect-ball .rb-num {
  color: #ffffff;
  font-size: 21px;
  font-weight: 900;
  line-height: 28px;
  font-family: Arial, Helvetica, sans-serif;
}
.rect-ball.red .rb-num { background: var(--red-ball); }
.rect-ball.blue .rb-num { background: var(--blue-ball); }
.rect-ball.green .rb-num { background: var(--green-ball); }

.rect-ball .rb-attr {
  background: #ffffff;
  font-size: 13px;
  font-weight: 900;
  line-height: 23px;
  white-space: nowrap;
}
.rect-ball.red .rb-attr { color: var(--red-ball); }
.rect-ball.blue .rb-attr { color: var(--blue-ball); }
.rect-ball.green .rb-attr { color: var(--green-ball); }

.dc-plus-sign {
  text-align: center;
  font-size: 22px;
  font-weight: 900;
  color: #475569;
}

.dc-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 700;
  color: #475569;
  padding-top: 4px;
  border-top: 1px dashed #e2e8f0;
}
.dc-foot .next-hl {
  color: #e52232;
  font-weight: 900;
}
.dc-btn-refresh {
  background: #16a34a;
  color: #ffffff;
  border: none;
  border-radius: 5px;
  padding: 3px 10px;
  font-size: 12.5px;
  font-weight: 800;
  cursor: pointer;
}

/* ================= VIDEO-STYLED BLUE SECTION BARS ================= */
.section-card {
  background: #ffffff;
  margin-bottom: 8px;
  border-top: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
}

.sec-blue-header {
  background: linear-gradient(180deg, var(--blue-sec-top) 0%, var(--blue-sec-bot) 100%);
  color: #ffffff;
  padding: 7px 10px;
  font-size: 17px;
  font-weight: 900;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-bottom: 1px solid #3b5998;
}
.sec-blue-header .emblem-dot {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #16a34a;
  border: 1.5px solid #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  flex-shrink: 0;
}

/* ================= HOMEPAGE GALLERY PREVIEW (2026正版彩图) ================= */
.issue-pill-bar {
  display: flex;
  gap: 6px;
  padding: 8px 10px 4px;
  overflow-x: auto;
}
.issue-pill {
  background: #1e293b;
  color: #ffffff;
  border: none;
  border-radius: 6px;
  padding: 6px 10px;
  font-size: 13.5px;
  font-weight: 900;
  white-space: nowrap;
  cursor: pointer;
  flex: 1;
  text-align: center;
}
.issue-pill.active {
  background: #e52232;
}

.tone-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 10px;
}
.tone-summary {
  font-size: 13px;
  font-weight: 800;
  color: var(--text-secondary);
}
.tone-btns {
  display: flex;
  gap: 6px;
}
.tone-btn {
  border: 1px solid var(--border-mid);
  background: #f8fafc;
  color: #334155;
  border-radius: 14px;
  padding: 3px 12px;
  font-size: 12.5px;
  font-weight: 800;
  cursor: pointer;
}
.tone-btn.active {
  background: #16a34a;
  color: #ffffff;
  border-color: #15803d;
}

.photo-2col-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  padding: 6px 10px 10px;
}
.photo-card {
  border: 1px solid var(--border-light);
  border-radius: 8px;
  overflow: hidden;
  background: #f8fafc;
  cursor: pointer;
  display: flex;
  flex-direction: column;
}
.photo-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
  background: #eef2f7;
}
.photo-card-title {
  padding: 7px 6px;
  font-size: 13.5px;
  font-weight: 800;
  color: #1e293b;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  background: #ffffff;
  border-top: 1px solid #f1f5f9;
}

.full-action-btn {
  display: block;
  width: calc(100% - 20px);
  margin: 2px 10px 12px;
  padding: 9px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  color: #1d4ed8;
  font-size: 14.5px;
  font-weight: 900;
  text-align: center;
  cursor: pointer;
}

/* ================= 3x3 TRENDS CANVAS GRID ================= */
.trends-3x3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  padding: 10px;
}
.trend-mini-card {
  border: 1px solid var(--border-light);
  border-radius: 8px;
  overflow: hidden;
  background: #ffffff;
  cursor: pointer;
  text-align: center;
  padding-bottom: 5px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}
.trend-mini-card canvas {
  width: 100%;
  height: 116px;
  display: block;
}
.tmc-meta {
  padding: 4px 4px 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.tmc-name {
  font-size: 13.5px;
  font-weight: 900;
  color: #1e293b;
}
.tmc-sub {
  font-size: 11px;
  font-weight: 700;
  color: #16a34a;
}

/* ================= 3-COLUMN SERIES PILL BUTTONS (正版图库 & 资料大全) ================= */
.sub-game-switch {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  padding: 8px 10px 4px;
}
.sgs-btn {
  padding: 7px 4px;
  border-radius: 18px;
  border: 1px solid #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 14px;
  font-weight: 800;
  text-align: center;
  cursor: pointer;
}
.sgs-btn.active {
  background: #2563eb;
  color: #ffffff;
  border-color: #1d4ed8;
}

.series-search-bar {
  display: flex;
  gap: 6px;
  padding: 6px 10px;
}
.series-search-bar input {
  flex: 1;
  border: 1px solid var(--border-mid);
  border-radius: 18px;
  padding: 6px 12px;
  font-size: 13.5px;
  outline: none;
}
.series-search-bar input:focus {
  border-color: #2563eb;
}

.pill-3col-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  padding: 6px 10px 10px;
}
.series-pill {
  background: #f8fafd;
  border: 1px solid #d5dfed;
  border-radius: 18px;
  padding: 8px 6px;
  font-size: 13.5px;
  font-weight: 800;
  color: #1e293b;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  cursor: pointer;
}
.series-pill:active {
  background: #e2e8f0;
}

/* ================= 挑码助手 (Interactive Picker) ================= */
.picker-wrap {
  padding: 10px;
}
.picker-result-box {
  min-height: 54px;
  border: 1px dashed var(--border-mid);
  border-radius: 8px;
  padding: 8px;
  margin-bottom: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  align-items: center;
  justify-content: center;
  color: #64748b;
  font-size: 13px;
  background: #f8fafc;
}
.round-ball {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 900;
  background: #ffffff;
  border: 2.5px solid var(--red-ball);
  color: #111827;
  font-family: Arial, sans-serif;
}
.round-ball.red { border-color: var(--red-ball); }
.round-ball.blue { border-color: var(--blue-ball); }
.round-ball.green { border-color: var(--green-ball); }

.picker-toolbar {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 10px;
}
.pt-btn {
  border-radius: 16px;
  padding: 5px 14px;
  font-size: 13px;
  font-weight: 800;
  border: 1px solid var(--border-mid);
  background: #ffffff;
  color: #334155;
  cursor: pointer;
}
.pt-btn.primary {
  background: #2563eb;
  color: #ffffff;
  border-color: #1d4ed8;
}
.cond-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 5px;
  margin-bottom: 5px;
}
.cond-grid.c5 { grid-template-columns: repeat(5, 1fr); }
.cond-grid.c3 { grid-template-columns: repeat(3, 1fr); }
.cond-chip {
  border: 1px solid #d5dfed;
  background: #ffffff;
  border-radius: 14px;
  padding: 5px 2px;
  font-size: 13px;
  font-weight: 800;
  color: #334155;
  text-align: center;
  cursor: pointer;
  user-select: none;
}
.cond-chip.active {
  background: #16a34a;
  color: #ffffff;
  border-color: #15803d;
}

/* ================= 2026 十二生肖号码对照 & 属性速查 ================= */
.zodiac-12-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--border-light);
}
.z12-cell {
  border-right: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
  padding: 8px 4px;
  text-align: center;
}
.z12-title {
  font-size: 15px;
  font-weight: 900;
  margin-bottom: 5px;
}
.z12-title span {
  font-size: 12px;
  color: #16a34a;
  font-weight: 800;
}
.z12-nums {
  display: flex;
  justify-content: center;
  gap: 3px;
  flex-wrap: wrap;
}
.z12-badge {
  display: inline-block;
  width: 23px;
  height: 20px;
  line-height: 20px;
  border-radius: 3px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 900;
  font-family: Arial, sans-serif;
}
.z12-badge.red { background: var(--red-ball); }
.z12-badge.blue { background: var(--blue-ball); }
.z12-badge.green { background: var(--green-ball); }

.clean-attr-table {
  border-top: 1px solid var(--border-light);
}
.cat-row {
  padding: 6px 12px;
  border-bottom: 1px solid #eef2f7;
  font-size: 14px;
  font-weight: 700;
  color: #334155;
  display: flex;
  justify-content: center;
  gap: 6px;
}
.cat-row b {
  color: #1d4ed8;
}

/* ================= FIXED 5-TAB BOTTOM BAR ================= */
.bottom-tabbar {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 560px;
  height: 58px;
  background: #ffffff;
  border-top: 1px solid var(--border-mid);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  align-items: center;
  z-index: 120;
  box-shadow: 0 -2px 10px rgba(15, 23, 42, 0.06);
}
.btab-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  user-select: none;
}
.btab-item.active {
  color: #1d4ed8;
}
.btab-item svg {
  width: 21px;
  height: 21px;
}
.btab-49-orb {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: #ffffff;
  font-size: 20px;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: -18px;
  border: 3px solid #ffffff;
  box-shadow: 0 3px 10px rgba(29, 78, 216, 0.35);
  font-family: "Arial Black", sans-serif;
}

/* Floating Right Action Buttons */
.floating-tools {
  position: fixed;
  right: max(10px, calc(50% - 270px));
  bottom: 74px;
  display: flex;
  flex-direction: column;
  gap: 9px;
  z-index: 110;
}
.ft-circle-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid var(--border-mid);
  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.15);
  color: #16a34a;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.ft-circle-btn svg {
  width: 20px;
  height: 20px;
}

/* Center Toast */
.app-toast {
  position: fixed;
  top: 46%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(15, 23, 42, 0.88);
  color: #ffffff;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 800;
  z-index: 350;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
  white-space: nowrap;
}
.app-toast.visible {
  opacity: 1;
}

/* Fullscreen Subview Drawer */
.drawer-overlay {
  position: fixed;
  inset: 0;
  z-index: 220;
  background: rgba(15, 23, 42, 0.55);
  display: none;
  justify-content: center;
}
.drawer-overlay.open {
  display: flex;
}
.drawer-sheet {
  width: 100%;
  max-width: 560px;
  height: 100%;
  background: var(--bg-page);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.drawer-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 14px;
  background: linear-gradient(90deg, #1e40af, #2563eb);
  color: #ffffff;
  font-size: 16px;
  font-weight: 900;
  gap: 8px;
}
.drawer-close-btn {
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
  border: none;
  border-radius: 6px;
  padding: 5px 12px;
  font-size: 13.5px;
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
}
.drawer-content {
  flex: 1;
  overflow-y: auto;
  padding: 10px;
}

/* A display-only site mark: original shared image files remain unchanged. */
.site-branded-image { display: block; position: relative; isolation: isolate; width: 100%; line-height: 0; }
.site-image-watermark { position: absolute; top: .55rem; right: .55rem; z-index: 1; display: inline-block; max-width: calc(100% - 1.1rem); padding: .26rem .48rem; border: 1px solid rgba(255,255,255,.74); border-radius: .35rem; background: rgba(13,35,81,.76); color: #fff; font-family: Arial, "Microsoft YaHei", sans-serif; font-size: clamp(12px, 2.8vw, 17px); font-weight: 800; line-height: 1.2; letter-spacing: .025em; text-shadow: 0 1px 2px rgba(0,0,0,.35); pointer-events: none; user-select: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.photo-card .site-image-watermark { top: .45rem; right: .45rem; font-size: clamp(11px, 2.7vw, 14px); padding: .2rem .38rem; }

/* Cinematic motion with a clearly visible sway, matching the first frontend. */
.hero-banner-card::before {
  transform-origin: 78% 18%;
}
.hero-gold-motion {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
}
.hero-gold-glint {
  position: absolute;
  display: block;
  width: clamp(7px, 1.4vw, var(--glint-size));
  aspect-ratio: 1;
  opacity: 0;
  transform: translate(-50%, -50%);
}
.hero-gold-glint svg { display: block; width: 100%; height: 100%; }
@media (prefers-reduced-motion: no-preference) {
  .hero-banner-card::before {
    animation: hero-cinematic-sway 4.2s ease-in-out infinite;
  }
  .hero-gold-glint {
    animation: hero-gold-flow 2.8s ease-in-out var(--glint-delay) infinite;
  }
  .hero-banner-card.is-motion-paused::before,
  .hero-banner-card.is-motion-paused .hero-gold-glint {
    animation-play-state: paused;
  }
}
@keyframes hero-cinematic-sway {
  0%, 100% { transform: translate3d(-.9%, .25%, 0) scale(1.035); }
  50% { transform: translate3d(.9%, -.25%, 0) scale(1.065); }
}
@keyframes hero-gold-flow {
  0%, 100% { opacity: .06; transform: translate(-50%, -30%) scale(.5) rotate(-15deg); }
  45% { opacity: .95; transform: translate(5%, -100%) scale(1.15) rotate(20deg); }
  75% { opacity: .25; transform: translate(35%, -170%) scale(.65) rotate(35deg); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-gold-motion { display: none; }
}

/* Six complete banners slide horizontally; artwork motion stays within each slide. */
.hero-banner-card { display: block; padding: 0; }
.hero-banner-card::before { content: none; }
.hero-carousel-viewport {
  display: flex;
  width: 100%;
  height: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  cursor: grab;
}
.hero-carousel-viewport::-webkit-scrollbar { display: none; }
.hero-carousel-viewport.is-dragging { scroll-snap-type: none; cursor: grabbing; user-select: none; }
.hero-carousel-viewport:focus-visible { outline: 2px solid #fff; outline-offset: -3px; }
.hero-slide {
  position: relative;
  display: flex;
  align-items: center;
  flex: 0 0 100%;
  min-width: 0;
  height: 100%;
  padding: 12px 16px 24px;
  overflow: hidden;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}
.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--slide-poster) center / cover no-repeat;
  transform-origin: 78% 18%;
}
.hero-slide .hero-text-overlay { flex: 0 1 48%; }
.hero-slide .hero-gold-glint { animation: none; }
.hero-carousel-dots {
  position: absolute;
  z-index: 4;
  display: flex;
  justify-content: center;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  height: 26px;
}
.hero-carousel-dot {
  position: relative;
  display: grid;
  place-items: center;
  flex: 0 0 26px;
  width: 26px;
  height: 26px;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  touch-action: manipulation;
}
.hero-carousel-dot::after {
  content: "";
  width: 7px;
  height: 7px;
  border: 1px solid #ffffffa6;
  border-radius: 50%;
  background: #ffffff55;
  box-shadow: 0 1px 3px #0006;
  transition: background-color 150ms, transform 150ms;
}
.hero-carousel-dot[aria-current="true"]::after { background: #fff; transform: scale(1.2); }
.hero-carousel-dot:hover::after { background: #fff; }
.hero-carousel-dot:focus-visible { outline: 2px solid #fff; outline-offset: -2px; border-radius: 50%; }
.hero-banner-card[data-active-slide="5"] .hero-carousel-dot::after { background: #22588b66; border-color: #22588bb3; box-shadow: none; }
.hero-banner-card[data-active-slide="5"] .hero-carousel-dot[aria-current="true"]::after { background: #12488f; }
.hero-banner-card[data-active-slide="5"] .hero-carousel-dot:focus-visible { outline-color: #12488f; }
.hero-slide--brand .hero-text-overlay { margin-left: 7%; max-width: 48%; gap: 7px; }
.hero-49-brand { display: inline-flex; align-items: baseline; gap: 3px; color: #f7fdff; line-height: 1; font-weight: 900; white-space: nowrap; }
.hero-49-brand__digits { font-family: Arial, sans-serif; font-size: clamp(25px, 5.5vw, 40px); font-style: italic; }
.hero-49-brand__name { font-size: clamp(19px, 4.2vw, 29px); }
.hero-slide--brand .hero-headline { font-size: clamp(17px, 4.1vw, 25px); }
.hero-slide--light .hero-49-brand { color: #12488f; }
.hero-slide--light .hero-headline { color: #113968; text-shadow: none; }
.hero-slide--light .hero-headline span { color: #075bb3; }
.hero-slide--light .hero-subtext { color: #234e79; }
.hero-slide--light .hero-domain-pill { background: #1456a0; color: #fff; box-shadow: none; }
.hero-slide--light .hero-gold-motion { display: none; }
@media (prefers-reduced-motion: no-preference) {
  .hero-slide.is-active::before {
    background-image: var(--slide-loop);
    animation: hero-cinematic-sway 4.2s ease-in-out infinite;
  }
  .hero-slide.is-active .hero-gold-glint { animation: hero-gold-flow 2.8s ease-in-out var(--glint-delay) infinite; }
  .hero-banner-card.is-motion-paused .hero-slide::before,
  .hero-banner-card.is-motion-paused .hero-gold-glint { animation-play-state: paused; }
}
@media (max-width: 420px) {
  .hero-banner-card { padding: 0; }
  .hero-slide { padding: 8px 10px 23px; }
  .hero-slide .hero-text-overlay { gap: 3px; }
  .hero-slide .hero-subtext { font-size: 9px; }
  .hero-slide--brand .hero-text-overlay { gap: 4px; }
  .hero-slide--brand .hero-domain-pill { padding: 3px 9px; }
  .hero-carousel-dots { height: 23px; }
  .hero-carousel-dot { width: 24px; height: 23px; flex-basis: 24px; }
}
