* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  max-width: 100%;
  min-height: 100%;
  margin: 0;
  padding: 0;
}

body {
  min-height: 100vh;
  font-family: "Microsoft YaHei", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
  color: #202733;
  background: linear-gradient(180deg, #f7f8fb 0%, #edf1f6 100%);
}

a {
  color: inherit;
  text-decoration: none;
}

.appHeader {
  width: 100%;
  min-height: 0;
  padding: 34px 12px 30px;
  color: #fff;
  background: linear-gradient(135deg, #008000 0%, #0d47a1 48%, #e60012 100%);
  border-bottom: 3px solid rgba(255, 215, 0, 0.58);
  box-shadow: 0 4px 24px rgba(13, 71, 161, 0.35);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 18px;
}

.site-logo {
  width: 48px;
  height: 48px;
  display: block;
  object-fit: cover;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.site-name {
  color: #fff;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 6px;
  line-height: 1.1;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.timer {
  min-width: 0;
  height: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.16);
  font-size: 18px;
  line-height: 1.2;
  font-weight: 500;
  white-space: nowrap;
}

.desktop-nav,
.mobile-nav-bottom ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.desktop-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 14px;
}

.desktop-nav a {
  min-width: 64px;
  height: 34px;
  padding: 0 18px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active {
  background: rgba(255, 255, 255, 0.22);
}

.desktop-nav a:hover {
  transform: translateY(-1px);
}

.page-shell {
  width: min(640px, 100%);
  margin: 0 auto;
  padding: 0 0 34px;
}

.hero-banner {
  width: 100%;
  height: 306px;
  object-fit: cover;
  display: block;
  background: #9c0000;
}

.lottery-panel {
  width: calc(100% - 4px);
  margin: 26px auto 0;
  border: 1px solid #ff6b2d;
  border-radius: 8px 8px 2px 2px;
  background: #fff;
  box-shadow: 0 18px 32px rgba(71, 97, 124, 0.14);
  overflow: hidden;
}

.lottery-panel.compact {
  margin-top: 30px;
  border: none;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.lottery-title {
  min-height: 35px;
  padding: 0 14px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
  background: #ffd5d2;
  border-bottom: 1px solid #f26437;
  color: #0013ff;
  font-size: 13px;
}

.lottery-title .center-title {
  color: #1c1f28;
  white-space: nowrap;
}

.lottery-title .issue {
  color: #0013ff;
  font-weight: 700;
}

.lottery-title .next-label {
  color: #0013ff;
}

.countdown-row {
  min-height: 121px;
  padding: 15px 18px 16px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  border-bottom: 1px solid #d7d7d7;
  gap: 16px;
}

.countdown-wrap {
  min-width: 0;
}

.countdown-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 11px;
  font-size: 14px;
  color: #222;
}

.countdown-meta strong {
  color: #e60012;
}

.countdown {
  display: flex;
  align-items: center;
  gap: 6px;
}

.time-part {
  display: flex;
  align-items: center;
  gap: 4px;
}

.digit {
  width: 36px;
  height: 54px;
  border-radius: 4px;
  background: #050505;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 34px;
  font-weight: 800;
  line-height: 1;
  font-family: Arial, Helvetica, sans-serif;
  box-shadow: inset 0 -4px 0 rgba(255, 255, 255, 0.08);
}

.history-page .digit {
  background: #fff;
  color: #000;
  border: 1px solid #d7d7d7;
  box-shadow: none;
}

.separator {
  width: 12px;
  color: #000;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  font-weight: 800;
  line-height: 1;
}

.live-badge {
  width: 66px;
  min-height: 39px;
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #fff;
  background: #d80011;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.08;
}

.live-release {
  position: absolute;
  left: 76px;
  bottom: 0;
  min-width: 0;
  min-height: 39px;
  padding: 4px 9px 5px;
  display: none;
  align-items: center;
  gap: 7px;
  color: #fff;
  background: #d80011;
  box-shadow: 0 3px 10px rgba(216, 0, 17, 0.2);
  animation: live-release-in 0.24s ease-out;
}

.live-release.is-visible {
  display: flex;
}

.countdown-wrap {
  position: relative;
}

.live-release-label,
.live-release-issue {
  font-size: 11px;
  line-height: 1.15;
  white-space: nowrap;
}

.live-release-label {
  font-weight: 800;
}

.live-release-issue {
  opacity: 0.9;
}

.live-release-balls {
  display: flex;
  align-items: center;
  gap: 3px;
}

.live-release-ball {
  width: 25px;
  height: 25px;
  font-size: 14px;
}

.sequence-ball {
  opacity: 0;
  transform: scale(0.55);
  animation: sequence-ball-in 0.34s ease-out forwards;
  animation-delay: var(--sequence-delay, 0ms);
}

@keyframes live-release-in {
  from {
    opacity: 0;
    transform: translateX(8px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes sequence-ball-in {
  0% {
    opacity: 0;
    transform: scale(0.55);
  }
  70% {
    opacity: 1;
    transform: scale(1.12);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

.history-link {
  min-width: 116px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: #000;
  font-size: 14px;
  white-space: nowrap;
}

.history-link::after {
  content: "";
  width: 9px;
  height: 9px;
  border-top: 3px solid #e60012;
  border-right: 3px solid #e60012;
  transform: rotate(45deg);
}

.current-result {
  min-height: 96px;
  padding: 15px 18px 18px;
  background: #fff;
}

.issue-line {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 11px;
  font-size: 15px;
  color: #111;
}

.issue-line .issue {
  color: #e60012;
}

.balls {
  display: flex;
  align-items: center;
  gap: 9px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.ball {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  color: #000;
  font-size: 18px;
  font-weight: 800;
  line-height: 1;
  font-family: Arial, Helvetica, sans-serif;
  background-position: center;
  background-repeat: no-repeat;
  background-size: 100% 100%;
}

.ball.red {
  background-image: url("/assets/balls/red.png");
}

.ball.yellow {
  background-image: url("/assets/balls/yellow.png");
}

.ball.blue {
  background-image: url("/assets/balls/blue.png");
}

.ball span {
  position: relative;
  z-index: 1;
  color: #000;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
}

.last-toggle {
  width: 100%;
  height: 45px;
  border: 0;
  border-top: 1px solid #e5e5e5;
  background: #fff;
  color: #333;
  font: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.last-toggle .chevron {
  width: 10px;
  height: 10px;
  border-right: 2px solid #666;
  border-bottom: 2px solid #666;
  transform: rotate(45deg);
  transition: transform 0.2s ease;
}

.last-toggle.open .chevron {
  transform: rotate(225deg);
}

.last-issues {
  display: none;
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid #ececec;
}

.last-issues.open {
  display: block;
}

.last-issues li {
  min-height: 56px;
  padding: 10px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid #f0f0f0;
}

.history-page {
  padding-top: 18px;
}

.history-summary {
  padding: 10px 16px 38px;
  border-bottom: 1px solid #cfcfcf;
}

.summary-title {
  min-height: 27px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #9aa0a8;
  font-size: 18px;
}

.summary-title .issue {
  color: #e60012;
}

.history-countdown {
  padding: 16px 16px 18px;
  border-bottom: 1px solid #cfcfcf;
}

.history-label {
  margin: 0 0 10px;
  color: #000;
  font-size: 14px;
}

.history-label span {
  color: #e60012;
  margin-left: 8px;
}

.tab-row {
  height: 48px;
  display: flex;
  align-items: center;
  padding-left: 17px;
}

.tab-pill {
  min-width: 40px;
  height: 28px;
  padding: 0 9px;
  border-radius: 5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: #e60012;
  font-size: 14px;
  font-weight: 800;
}

.history-list-wrap {
  padding-bottom: 12px;
}

.history-card {
  min-height: 102px;
  padding: 14px 16px 12px;
  border-bottom: 1px solid #cfcfcf;
  display: grid;
  grid-template-columns: 122px minmax(0, 1fr);
  row-gap: 8px;
  color: #303845;
}

.history-card dt,
.history-card dd {
  margin: 0;
  min-height: 22px;
  display: flex;
  align-items: center;
}

.history-card dt {
  justify-content: flex-end;
  padding-right: 16px;
  color: #e60012;
  font-weight: 800;
}

.history-card dd {
  min-width: 0;
}

.history-card .balls {
  gap: 8px;
}

.trend-page,
.about-page {
  margin-top: 26px;
  padding: 22px 18px 28px;
  background: #fff;
  border: 1px solid #e3e6eb;
  box-shadow: 0 18px 32px rgba(71, 97, 124, 0.14);
}

.section-heading {
  margin: 0 0 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid #e4e4e4;
  color: #e60012;
  font-size: 20px;
}

.trend-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 14px;
}

.trend-table th,
.trend-table td {
  height: 42px;
  border: 1px solid #d7dce4;
  text-align: center;
  vertical-align: middle;
}

.trend-table th {
  color: #fff;
  background: #0d47a1;
}

.trend-table td.active-cell {
  color: #fff;
  background: #e60012;
  font-weight: 800;
}

.about-page p {
  margin: 0 0 12px;
  color: #303845;
  line-height: 1.8;
}

.info-page {
  min-height: 320px;
}

.info-copy {
  color: #303845;
  font-size: 18px;
  line-height: 1.9;
}

.info-copy p {
  margin: 0 0 16px;
}

.about-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 20px;
}

.stat {
  min-height: 72px;
  padding: 12px 8px;
  border: 1px solid #ffd0a3;
  background: #fff7ee;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.stat strong {
  color: #e60012;
  font-size: 22px;
}

.stat span {
  color: #5e6878;
  font-size: 13px;
}

.mobile-nav-bottom {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  height: 72px;
  padding: 8px 0;
  background: linear-gradient(135deg, #008000 0%, #e60012 100%);
  border-top: 2px solid rgba(255, 215, 0, 0.3);
  box-shadow: 0 -4px 20px rgba(13, 71, 161, 0.3);
}

.mobile-nav-bottom ul {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-around;
}

.mobile-nav-bottom li {
  flex: 1;
  min-width: 0;
  height: 100%;
}

.mobile-nav-bottom a {
  height: 100%;
  min-height: 50px;
  padding: 6px 3px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 12px;
  line-height: 1.2;
}

.mobile-nav-bottom a.active,
.mobile-nav-bottom a:hover {
  background: rgba(255, 255, 255, 0.2);
}

.mobile-nav-icon {
  width: 26px;
  height: 26px;
  margin-bottom: 4px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.25);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
}

.hidden {
  display: none !important;
}

@media (max-width: 768px) {
  body {
    padding-bottom: 72px;
  }

  .appHeader {
    min-height: 0;
    padding: 34px 8px 30px;
    justify-content: center;
  }

  .desktop-nav {
    display: none;
  }

  .header-brand {
    gap: 16px;
    margin-bottom: 18px;
  }

  .site-logo {
    width: 48px;
    height: 48px;
  }

  .site-name {
    font-size: 24px;
    letter-spacing: 4px;
  }

  .timer {
    height: auto;
    min-width: 0;
    padding: 8px 18px;
    font-size: 18px;
  }

  .mobile-nav-bottom {
    display: block;
  }

  .page-shell {
    width: 100%;
  }

  .hero-banner {
    height: auto;
    aspect-ratio: 640 / 306;
  }

  .lottery-panel {
    width: calc(100% - 12px);
    margin-top: 14px;
  }

  .lottery-title {
    padding: 0 9px;
    grid-template-columns: 1fr;
    text-align: left;
    gap: 3px;
  }

  .lottery-title .center-title {
    justify-self: start;
  }

  .countdown-row {
    grid-template-columns: 1fr;
    min-height: 132px;
    padding: 14px 14px 16px;
    gap: 8px;
  }

  .history-link {
    justify-self: end;
  }

  .live-release {
    left: 76px;
    max-width: calc(100% - 76px);
    flex-wrap: wrap;
  }

  .digit {
    width: 34px;
    height: 52px;
    font-size: 32px;
  }

  .current-result,
  .last-issues li {
    padding-left: 14px;
    padding-right: 14px;
  }

  .history-card {
    grid-template-columns: 86px minmax(0, 1fr);
  }

  .history-card dt {
    padding-right: 12px;
  }
}

@media (max-width: 420px) {
  .countdown {
    gap: 4px;
  }

  .time-part {
    gap: 3px;
  }

  .digit {
    width: 28px;
    height: 44px;
    font-size: 27px;
  }

  .separator {
    width: 8px;
    font-size: 27px;
  }

  .ball {
    width: 28px;
    height: 28px;
    font-size: 17px;
  }

  .history-card {
    padding-left: 10px;
    padding-right: 10px;
    grid-template-columns: 72px minmax(0, 1fr);
    font-size: 13px;
  }

  .about-stats {
    grid-template-columns: 1fr;
  }
}

.mobile-page-title {
  display: none;
}

.mobile-sub-nav {
  display: none;
}

.trend-toolbar {
  min-height: 48px;
  padding: 10px 6px;
  display: flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  border-bottom: 1px solid #ededed;
  font-size: 15px;
}

.trend-toolbar select {
  height: 30px;
  min-width: 112px;
  border: 1px solid #d6d6d6;
  border-radius: 4px;
  padding: 0 8px;
  color: #444;
  background: linear-gradient(#fff, #e8e8e8);
  font: inherit;
}

.swipe-hint {
  margin: 0;
  padding: 9px 0;
  color: #777;
  text-align: center;
  background: #fff;
  border-bottom: 1px solid #eee;
  font-size: 14px;
}

.trend-scroll {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  background: #fff;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
}

.trend-table.old-style {
  min-width: 980px;
  table-layout: auto;
  background: #fff;
  font-size: 14px;
}

.trend-table.old-style th,
.trend-table.old-style td {
  height: 54px;
  padding: 0;
}

.trend-table.old-style th {
  background: #fff;
  color: #222;
}

.trend-table.old-style th:nth-child(n+5) {
  background: #f6ecc9;
}

.trend-table.old-style .issue-cell {
  font-weight: 700;
}

.trend-table.old-style th:nth-child(1),
.trend-table.old-style td:nth-child(1) {
  min-width: 126px;
}

.trend-table.old-style th:nth-child(2),
.trend-table.old-style td:nth-child(2) {
  min-width: 82px;
}

.trend-table.old-style th:nth-child(3),
.trend-table.old-style td:nth-child(3) {
  min-width: 158px;
}

.trend-table.old-style th:nth-child(4),
.trend-table.old-style td:nth-child(4) {
  min-width: 70px;
}

.trend-table.old-style th:nth-child(n+5),
.trend-table.old-style td:nth-child(n+5) {
  min-width: 52px;
}

.trend-table.old-style .week-cell {
  color: #333;
}

.trend-table.old-style .open-cell .balls {
  justify-content: center;
  gap: 5px;
}

.trend-table.old-style .open-cell .ball {
  width: 25px;
  height: 25px;
  color: #fff;
  background-image: none;
  font-size: 13px;
}

.trend-table.old-style .open-cell .ball.red {
  background: #ef3b3b;
}

.trend-table.old-style .open-cell .ball.yellow {
  background: #2ecc71;
}

.trend-table.old-style .open-cell .ball.blue {
  background: #3498db;
}

.trend-table.old-style .open-cell .ball span {
  color: #fff;
  text-shadow: none;
}

.trend-table.old-style .trend-number {
  color: #d05c68;
}

.trend-table.old-style td.active-cell {
  background: #fff;
}

.trend-table.old-style td.active-cell span {
  width: 34px;
  height: 34px;
  margin: 0 auto;
  border-radius: 50%;
  color: #fff;
  background: #e60012;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

.trend-board {
  --trend-issue-w: 112px;
  --trend-week-w: 78px;
  --trend-open-w: 154px;
  --trend-sum-w: 72px;
  --trend-digit-w: 42px;
  --trend-stat-w: 82px;
  position: relative;
  width: max-content;
  min-width: 100%;
  background: #fff;
}

.trend-table.old-style.classic-trend {
  width: max-content;
  min-width: 0;
  table-layout: fixed;
  border-collapse: collapse;
  background: #fff;
  font-size: 15px;
}

.classic-trend th,
.classic-trend td {
  box-sizing: border-box;
  border: 1px solid #d4d7dc;
  text-align: center;
  vertical-align: middle;
  white-space: nowrap;
}

.classic-trend .meta-issue {
  width: var(--trend-issue-w);
  min-width: var(--trend-issue-w);
}

.classic-trend .meta-week {
  width: var(--trend-week-w);
  min-width: var(--trend-week-w);
}

.classic-trend .meta-open {
  width: var(--trend-open-w);
  min-width: var(--trend-open-w);
}

.classic-trend .meta-sum {
  width: var(--trend-sum-w);
  min-width: var(--trend-sum-w);
}

.classic-trend .digit-header,
.classic-trend .position-cell,
.classic-trend .selection-cell {
  width: var(--trend-digit-w);
  min-width: var(--trend-digit-w);
}

.classic-trend .stat-header,
.classic-trend .stat-cell {
  width: var(--trend-stat-w);
  min-width: var(--trend-stat-w);
}

.classic-trend .trend-group-row th {
  height: 44px;
  padding: 0 8px;
  color: #2a2a2a;
  background: #f3e9bf;
  font-size: 16px;
  font-weight: 700;
}

.classic-trend .trend-group-row .meta-issue,
.classic-trend .trend-group-row .meta-week,
.classic-trend .trend-group-row .meta-open,
.classic-trend .trend-group-row .meta-sum {
  background: #fff;
}

.classic-trend .trend-group-header {
  border-right: 3px solid #c8cbd0;
}

.classic-trend .stats-group {
  background: #eaf4fb !important;
}

.classic-trend .trend-digit-row th {
  height: 40px;
  color: #2e2e2e;
  background: #f8f8f8;
  font-size: 15px;
  font-weight: 700;
}

.classic-trend .trend-digit-row .digit-header,
.classic-trend .trend-digit-row .selection-digit {
  background: #f3e9bf;
}

.classic-trend .trend-digit-row .stat-header {
  background: #eaf4fb;
}

.classic-trend tbody td {
  height: 56px;
  padding: 0;
  background: #fff;
}

.classic-trend tbody tr:nth-child(even) td {
  background: #fcfcfc;
}

.classic-trend .issue-cell {
  color: #232323;
  font-weight: 700;
}

.classic-trend .week-cell {
  color: #333;
}

.classic-trend .week-short {
  display: none;
}

.classic-trend .sum-cell {
  color: #202020;
  font-size: 17px;
  font-weight: 700;
}

.classic-trend .open-cell .balls {
  justify-content: center;
  gap: 5px;
}

.classic-trend .open-cell .ball {
  width: 25px;
  height: 25px;
  color: #fff;
  background-image: none;
  font-size: 13px;
}

.classic-trend .open-cell .ball.red {
  background: #ef3b3b;
}

.classic-trend .open-cell .ball.yellow {
  background: #2ecc71;
}

.classic-trend .open-cell .ball.blue {
  background: #3498db;
}

.classic-trend .open-cell .ball span {
  color: #fff;
  text-shadow: none;
}

.classic-trend .trend-number {
  color: #c97c82;
  font-size: 16px;
}

.classic-trend .position-cell {
  position: relative;
}

.classic-trend td.active-cell {
  background: #fff !important;
}

.classic-trend td.active-cell .trend-hit {
  position: relative;
  z-index: 4;
  width: 34px;
  height: 34px;
  margin: 0 auto;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.04);
}

.classic-trend td.active-cell .trend-hit-hundreds {
  background: #e64b4b !important;
}

.classic-trend td.active-cell .trend-hit-tens {
  background: #2ebf76 !important;
}

.classic-trend td.active-cell .trend-hit-units {
  background: #3199d4 !important;
}

.classic-trend td.active-cell .trend-hit-red,
.classic-trend .open-cell .ball.trend-ball-red {
  background: #e74c3c !important;
}

.classic-trend td.active-cell .trend-hit-blue,
.classic-trend .open-cell .ball.trend-ball-blue {
  background: #3498db !important;
}

.classic-trend td.active-cell .trend-hit-green,
.classic-trend .open-cell .ball.trend-ball-green {
  background: #2ecc71 !important;
}

.classic-trend .selection-cell {
  color: #c97c82;
}

.classic-trend .selection-cell.active-cell {
  background: #fff !important;
}

.classic-trend .selection-hit {
  position: relative;
  z-index: 4;
  width: 28px;
  height: 28px;
  margin: 0 auto;
  border: 1px solid #222;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #222;
  background: #fff;
  font-size: 15px;
}

.trend-table.old-style.classic-trend td.selection-cell.active-cell .selection-hit {
  width: 24px;
  height: 24px;
  border: 1px solid #666;
  color: #222;
  background: #fff;
  box-shadow: none;
  font-weight: 400;
}

.trend-table.old-style.classic-trend td.selection-cell.active-cell .selection-ball {
  width: 28px;
  height: 28px;
  border: 0;
  color: #fff;
  font-weight: 700;
}

.trend-table.old-style.classic-trend td.selection-cell.active-cell .selection-hit-red {
  background: #e74c3c;
}

.trend-table.old-style.classic-trend td.selection-cell.active-cell .selection-hit-blue {
  background: #3498db;
}

.trend-table.old-style.classic-trend td.selection-cell.active-cell .selection-hit-green {
  background: #2ecc71;
}

.classic-trend .stat-cell {
  color: #111;
  background: #eaf4fb !important;
  font-size: 15px;
  font-weight: 600;
}

.classic-trend .group-stat {
  padding: 0 4px;
}

.classic-trend .group-badge {
  min-width: 42px;
  padding: 4px 3px;
  display: inline-block;
  color: #fff;
  font-size: 15px;
  line-height: 1.15;
}

.classic-trend .group-six {
  background: #3295cf;
}

.classic-trend .group-three {
  background: #ef4c3e;
}

.classic-trend .group-baozi {
  background: #8d6ac7;
}

.trend-lines {
  position: absolute;
  z-index: 3;
  top: 0;
  left: 0;
  overflow: visible;
  pointer-events: none;
}

.expert-page {
  padding: 18px 0 80px;
}

.expert-frame {
  margin: 0 auto;
  padding: 10px 20px 28px;
  background: #fff;
  border: 2px dashed #f5b266;
}

.expert-tab {
  height: 54px;
  margin: 16px 0 24px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: linear-gradient(#ff9e39, #ff781f);
  box-shadow: 0 4px 0 rgba(221, 117, 24, 0.2);
  font-size: 22px;
  font-weight: 700;
}

.expert-card {
  overflow: hidden;
  padding: 0;
  border: 1px solid #f4ca9a;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 5px 16px rgba(204, 128, 38, 0.12);
}

.expert-card h1 {
  width: 100%;
  min-height: 56px;
  margin: 0;
  padding: 13px 20px;
  border-left: 5px solid #e66b0a;
  border-bottom: 1px solid #f4dcc0;
  color: #b55418;
  background: #fff7ed;
  line-height: 1.35;
  font-size: 20px;
  font-weight: 600;
}

.expert-card h1 span {
  width: 13px;
  height: 13px;
  margin-right: 9px;
  border-radius: 3px;
  background: #e66b0a;
  display: inline-block;
  vertical-align: 1px;
}

.expert-content {
  padding: 20px 26px 24px;
  color: #252525;
  font-size: 18px;
  line-height: 1.5;
}

.expert-content p {
  margin: 0 0 6px;
}

.prediction-balls {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 6px;
  vertical-align: middle;
}

.prediction-ball-group {
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.prediction-balls .ball {
  width: 24px;
  height: 24px;
  font-size: 14px;
  vertical-align: middle;
}

.prediction-symbol,
.prediction-group-separator {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  color: #111;
  font-weight: 700;
}

.prediction-group-separator {
  margin: 0 1px 0 -2px;
}

.expert-zimi,
.expert-shiju {
  font-weight: 700;
  white-space: pre-line;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.expert-zimi {
  color: #d71920;
}

.expert-shiju {
  color: #1264c8;
}

.expert-history-heading {
  min-height: 48px;
  margin: 36px 0 16px;
  padding: 0 4px 10px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 2px solid #f0a05a;
}

.expert-history-heading h2 {
  margin: 0;
  color: #b55418;
  font-size: 22px;
  font-weight: 600;
}

.expert-history-heading span {
  color: #8b8b8b;
  font-size: 14px;
}

.expert-history-list {
  display: grid;
  gap: 18px;
}

.expert-card-history .expert-content {
  font-size: 17px;
}

.expert-empty {
  margin: 28px 0 8px;
  color: #777;
  text-align: center;
  font-size: 16px;
}

@media (max-width: 768px) {
  .mobile-sub-nav:not([hidden]) {
    height: 44px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    border-top: 2px solid #d7bb2c;
    border-bottom: 1px solid #f26d16;
    background: #ff8b2c;
  }

  .mobile-sub-nav a {
    min-width: 0;
    height: 100%;
    border-radius: 12px 12px 0 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: linear-gradient(#ffad44, #ff7e21);
    border-right: 1px solid rgba(255, 255, 255, 0.35);
    font-size: 16px;
    line-height: 1;
    white-space: nowrap;
  }

  .lottery-title {
    min-height: 54px;
    grid-template-columns: minmax(0, 1.1fr) auto minmax(0, 1fr);
    gap: 6px;
    font-size: 17px;
    white-space: nowrap;
  }

  .lottery-title .center-title {
    justify-self: center;
  }

  .lottery-title .next-label {
    padding-left: 8px;
    border-left: 1px solid #fb6948;
  }

  .countdown-row {
    grid-template-columns: minmax(0, 1fr) auto;
    min-height: 150px;
    padding: 18px 24px 18px;
    gap: 8px;
  }

  .history-link {
    font-size: 20px;
  }

  .trend-page {
    width: 100%;
    margin-top: 0;
    padding: 0 0 72px;
    border: 0;
    box-shadow: none;
  }

  .trend-toolbar {
    min-height: 52px;
    padding: 10px 8px;
    border-top: 1px solid #eeeeee;
    font-size: 17px;
  }

  .trend-toolbar select {
    min-width: 132px;
    height: 34px;
    font-size: 16px;
  }

  .swipe-hint {
    min-height: 48px;
    box-sizing: border-box;
    padding: 14px 0;
    font-size: 16px;
  }

  .trend-table.old-style.classic-trend {
    font-size: 16px;
  }

  .trend-table.old-style.classic-trend .meta-open {
    width: 120px;
    min-width: 120px;
  }

  .trend-table.old-style.classic-trend .meta-sum {
    width: 58px;
    min-width: 58px;
  }

  .trend-table.old-style.classic-trend .meta-issue {
    width: 96px;
    min-width: 96px;
  }

  .trend-table.old-style.classic-trend .meta-week {
    width: 64px;
    min-width: 64px;
  }

  .classic-trend .trend-group-row th {
    height: 60px;
    font-size: 16px;
  }

  .classic-trend .trend-digit-row th {
    height: 60px;
    font-size: 16px;
  }

  .classic-trend tbody td {
    height: 58px;
  }

  .classic-trend .trend-number {
    font-size: 16px;
  }

  .mobile-nav-bottom {
    height: calc(72px + env(safe-area-inset-bottom));
    padding-bottom: env(safe-area-inset-bottom);
  }

  body {
    padding-bottom: calc(72px + env(safe-area-inset-bottom));
  }

  .expert-page {
    width: 100%;
    margin-top: 0;
    padding-top: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
  }

  .info-page {
    min-height: 320px;
    margin-top: 0;
    padding-top: 26px;
    border: 0;
    box-shadow: none;
  }

  .info-copy {
    font-size: 17px;
  }
}

@media (max-width: 420px) {
  .mobile-sub-nav a {
    font-size: 16px;
  }

  .lottery-title {
    font-size: 16px;
  }

  .countdown-row {
    padding-left: 20px;
    padding-right: 20px;
  }

  .history-link {
    min-width: 96px;
    font-size: 18px;
  }

  .live-release-label,
  .live-release-issue {
    font-size: 10px;
  }

  .live-release-ball {
    width: 22px;
    height: 22px;
    font-size: 13px;
  }

  .expert-frame {
    padding-left: 16px;
    padding-right: 16px;
  }

  .expert-card {
    padding: 0;
  }

  .expert-card h1 {
    left: auto;
    width: 100%;
    font-size: 16px;
  }

  .expert-content {
    font-size: 15px;
  }

  .expert-history-heading {
    margin-top: 28px;
    margin-bottom: 14px;
  }

  .expert-history-heading h2 {
    font-size: 19px;
  }

  .expert-card h1 {
    min-height: 52px;
    padding: 12px 14px;
    font-size: 17px;
  }

  .expert-card h1 span {
    width: 11px;
    height: 11px;
    margin-right: 7px;
  }

  .expert-content,
  .expert-card-history .expert-content {
    padding: 16px 14px 18px;
    font-size: 16px;
  }

  .trend-table.old-style.classic-trend .meta-issue {
    width: 92px;
    min-width: 92px;
  }

  .trend-table.old-style.classic-trend .meta-week {
    width: 60px;
    min-width: 60px;
  }

  .trend-table.old-style.classic-trend .meta-open {
    width: 114px;
    min-width: 114px;
  }

  .trend-table.old-style.classic-trend .meta-sum {
    width: 56px;
    min-width: 56px;
  }
}

@media (max-width: 360px) {
  .mobile-sub-nav a {
    font-size: 15px;
  }

  .appHeader {
    padding-left: 6px;
    padding-right: 6px;
  }

  .header-brand {
    gap: 10px;
  }

  .site-logo {
    width: 44px;
    height: 44px;
  }

  .site-name {
    font-size: 21px;
    letter-spacing: 2px;
  }

  .timer {
    font-size: 16px;
  }

  .trend-toolbar {
    gap: 6px;
    padding-left: 6px;
    padding-right: 6px;
  }

  .trend-toolbar select {
    min-width: 122px;
  }

  .trend-table.old-style.classic-trend .meta-issue {
    width: 86px;
    min-width: 86px;
  }

  .trend-table.old-style.classic-trend .meta-week {
    width: 56px;
    min-width: 56px;
  }

  .trend-table.old-style.classic-trend .meta-open {
    width: 106px;
    min-width: 106px;
  }

  .trend-table.old-style.classic-trend .meta-sum {
    width: 50px;
    min-width: 50px;
  }
}

@media (max-width: 768px) {
  .trend-scroll {
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    padding-bottom: 10px;
    overflow-x: auto;
    overflow-y: hidden;
    touch-action: pan-x pan-y;
    overscroll-behavior-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #aab4c3 #eef1f6;
  }

  .trend-scroll::-webkit-scrollbar {
    height: 8px;
  }

  .trend-scroll::-webkit-scrollbar-track {
    background: #eef1f6;
  }

  .trend-scroll::-webkit-scrollbar-thumb {
    background: #aab4c3;
    border-radius: 999px;
  }

  .trend-board {
    --trend-issue-w: 80px;
    --trend-week-w: 50px;
    --trend-open-w: 100px;
    --trend-sum-w: 50px;
    --trend-digit-w: 20px;
    --trend-stat-w: 20px;
  }

  .trend-table.old-style.classic-trend {
    border-collapse: separate;
    border-spacing: 0;
    font-size: 11px;
  }

  .trend-table.old-style.classic-trend .meta-issue {
    width: var(--trend-issue-w);
    min-width: var(--trend-issue-w);
    max-width: var(--trend-issue-w);
  }

  .trend-table.old-style.classic-trend .meta-week {
    width: var(--trend-week-w);
    min-width: var(--trend-week-w);
    max-width: var(--trend-week-w);
  }

  .trend-table.old-style.classic-trend .meta-open {
    width: var(--trend-open-w);
    min-width: var(--trend-open-w);
    max-width: var(--trend-open-w);
  }

  .trend-table.old-style.classic-trend .meta-sum {
    width: var(--trend-sum-w);
    min-width: var(--trend-sum-w);
    max-width: var(--trend-sum-w);
  }

  .trend-table.old-style.classic-trend .digit-header,
  .trend-table.old-style.classic-trend .position-cell,
  .trend-table.old-style.classic-trend .selection-cell {
    width: var(--trend-digit-w);
    min-width: var(--trend-digit-w);
    max-width: var(--trend-digit-w);
  }

  .trend-table.old-style.classic-trend .stat-header,
  .trend-table.old-style.classic-trend .stat-cell {
    width: var(--trend-stat-w);
    min-width: var(--trend-stat-w);
    max-width: var(--trend-stat-w);
  }

  .trend-table.old-style.classic-trend .meta-issue,
  .trend-table.old-style.classic-trend .meta-week,
  .trend-table.old-style.classic-trend .meta-open,
  .trend-table.old-style.classic-trend .meta-sum {
    position: static;
    z-index: auto;
    background: #fff;
    box-shadow: none;
  }

  .trend-table.old-style.classic-trend .meta-issue {
    left: auto;
  }

  .trend-table.old-style.classic-trend .meta-week {
    left: auto;
  }

  .trend-table.old-style.classic-trend .meta-open {
    left: auto;
  }

  .trend-table.old-style.classic-trend .meta-sum {
    left: auto;
  }

  .trend-table.old-style.classic-trend thead .meta-issue,
  .trend-table.old-style.classic-trend thead .meta-week,
  .trend-table.old-style.classic-trend thead .meta-open,
  .trend-table.old-style.classic-trend thead .meta-sum {
    z-index: auto;
  }

  .trend-table.old-style.classic-trend tbody tr:nth-child(even) .meta-issue,
  .trend-table.old-style.classic-trend tbody tr:nth-child(even) .meta-week,
  .trend-table.old-style.classic-trend tbody tr:nth-child(even) .meta-open,
  .trend-table.old-style.classic-trend tbody tr:nth-child(even) .meta-sum {
    background: #fcfcfc;
  }

  .classic-trend .trend-group-row th {
    height: 40px;
    padding: 0 2px;
    font-size: 11px;
    line-height: 1.2;
  }

  .classic-trend .trend-digit-row th {
    height: 40px;
    font-size: 11px;
  }

  .trend-table.old-style.classic-trend tbody td {
    height: 43px;
  }

  .classic-trend .issue-cell {
    font-size: 11px;
  }

  .classic-trend .week-cell {
    font-size: 11px;
  }

  .classic-trend .week-full {
    display: none;
  }

  .classic-trend .week-short {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #f3f4f6;
    font-size: 11px;
  }

  .classic-trend .sum-cell {
    font-size: 11px;
  }

  .classic-trend .open-cell .balls {
    gap: 3px;
  }

  .classic-trend .open-cell .ball {
    width: 20px;
    height: 20px;
    font-size: 11px;
  }

  .classic-trend .trend-number {
    font-size: 11px;
  }

  .classic-trend td.active-cell .trend-hit {
    width: 26px;
    height: 26px;
    font-size: 11px;
  }

  .classic-trend .selection-hit {
    width: 24px;
    height: 24px;
    font-size: 11px;
  }

  .classic-trend .stat-cell,
  .classic-trend .group-badge {
    font-size: 11px;
  }

  .trend-lines polyline {
    stroke-width: 2.25px;
  }
}

@media (max-width: 390px) {
  .trend-board {
    --trend-issue-w: 80px;
    --trend-week-w: 50px;
    --trend-open-w: 100px;
    --trend-sum-w: 50px;
    --trend-digit-w: 20px;
    --trend-stat-w: 20px;
  }

  .classic-trend .issue-cell {
    font-size: 11px;
  }

  .classic-trend .open-cell .ball {
    width: 20px;
    height: 20px;
    font-size: 11px;
  }
}

@media (max-width: 340px) {
  .trend-board {
    --trend-issue-w: 80px;
    --trend-week-w: 50px;
    --trend-open-w: 100px;
    --trend-sum-w: 50px;
    --trend-digit-w: 20px;
    --trend-stat-w: 20px;
  }

  .classic-trend .trend-group-row th {
    font-size: 11px;
  }

  .classic-trend .trend-digit-row th,
  .classic-trend .trend-number,
  .classic-trend .stat-cell,
  .classic-trend .group-badge {
    font-size: 11px;
  }
}

@media (max-width: 768px) {
  body.trend-route {
    background: #f1f1f1;
  }

  body.trend-route .appHeader {
    min-height: 0;
    padding: 0;
    color: #222;
    background: #fff;
    border-bottom: 0;
    box-shadow: none;
  }

  body.trend-route .header-brand {
    width: 100%;
    height: 82px;
    margin: 0;
    justify-content: center;
    gap: 0;
  }

  body.trend-route .site-logo {
    display: none;
  }

  body.trend-route .site-name {
    color: #e0332d;
    font-size: 18px;
    font-weight: 400;
    letter-spacing: 0;
    line-height: 1;
    text-shadow: none;
  }

  body.trend-route .site-name::after {
    content: "走势图";
  }

  body.trend-route .timer {
    width: 100%;
    height: 86px;
    padding: 0;
    border-radius: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #078333 0%, #174e9d 50%, #df0016 100%);
    box-shadow: inset 0 -3px 0 #1ca437;
  }

  body.trend-route .timer-value {
    min-width: 244px;
    height: 34px;
    padding: 0 16px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: rgba(255, 255, 255, 0.18);
    font-size: 18px;
    font-weight: 400;
    line-height: 1;
    white-space: nowrap;
  }

  body.trend-route .timer-value::after {
    content: "";
    margin-left: 0;
  }

  body.trend-route .mobile-sub-nav:not([hidden]) {
    height: 44px;
    margin-top: 8px;
    border-top: 0;
    border-bottom: 0;
    background: #f1f1f1;
    gap: 1px;
  }

  body.trend-route .mobile-sub-nav a {
    border-radius: 8px 8px 0 0;
    border-right: 0;
    background: linear-gradient(#ffa73c, #ff7825);
    font-size: 16px;
    font-weight: 400;
  }

  body.trend-route .trend-page {
    width: 100%;
    margin-top: 0;
    padding: 20px 0 calc(72px + env(safe-area-inset-bottom));
    background: #f1f1f1;
    border: 0;
    box-shadow: none;
  }

  body.trend-route .trend-intro {
    display: none;
  }

  body.trend-route .trend-toolbar {
    min-height: 38px;
    height: 38px;
    margin: 0;
    padding: 0 6px;
    border: 0;
    border-radius: 3px;
    background: #fff;
    font-size: 14px;
    line-height: 1;
  }

  body.trend-route .trend-toolbar select {
    min-width: 96px;
    height: 28px;
    padding: 0 8px;
    border-radius: 3px;
    font-size: 14px;
  }

  body.trend-route .swipe-hint {
    min-height: 30px;
    padding: 7px 0;
    border: 0;
    background: #fff;
    color: #555;
    font-size: 12px;
    line-height: 16px;
  }

  body.trend-route .trend-scroll {
    width: 100%;
    max-width: 100%;
    margin-left: 0;
    padding-bottom: 0;
    overflow-x: auto;
    overflow-y: hidden;
    background: #fff;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x pan-y;
    overscroll-behavior-y: auto;
  }

  body.trend-route .trend-board {
    --trend-issue-w: 80px;
    --trend-week-w: 50px;
    --trend-open-w: 100px;
    --trend-sum-w: 50px;
    --trend-digit-w: 20px;
    --trend-stat-w: 24px;
    width: max-content;
    min-width: 0;
  }

  body.trend-route .trend-table.old-style.classic-trend {
    width: 1224px;
    min-width: 1224px;
    max-width: 1224px;
    border-collapse: separate;
    border-spacing: 0;
    table-layout: fixed;
    font-size: 11px;
  }

  body.trend-route .trend-table.old-style.classic-trend .meta-issue,
  body.trend-route .trend-table.old-style.classic-trend .meta-week,
  body.trend-route .trend-table.old-style.classic-trend .meta-open,
  body.trend-route .trend-table.old-style.classic-trend .meta-sum {
    position: static !important;
    z-index: auto !important;
    box-shadow: none !important;
  }

  body.trend-route .classic-trend .trend-group-row th,
  body.trend-route .classic-trend .trend-digit-row th {
    height: 40px;
    padding: 0 2px;
    font-size: 11px;
    line-height: 1.2;
  }

  body.trend-route .trend-table.old-style.classic-trend tbody td {
    height: 43px;
    font-size: 11px;
  }

  body.trend-route .classic-trend .open-cell .ball {
    width: 20px;
    height: 20px;
    font-size: 11px;
  }

  body.trend-route .classic-trend td.active-cell .trend-hit {
    width: 26px;
    height: 26px;
    font-size: 11px;
  }

  body.trend-route .classic-trend .selection-hit {
    width: 20px;
    height: 20px;
    font-size: 11px;
  }

  body.trend-route .classic-trend .stat-cell,
  body.trend-route .classic-trend .group-badge {
    font-size: 10px;
  }

  body.trend-route .trend-table.old-style.classic-trend td.selection-cell.active-cell .selection-hit {
    width: 20px;
    height: 20px;
    font-size: 11px;
    line-height: 20px;
  }

  body.trend-route .trend-table.old-style.classic-trend td.selection-cell.active-cell .selection-ball {
    width: 24px;
    height: 24px;
  }

  body.trend-route .classic-trend .group-badge {
    min-width: 0;
    padding: 2px 3px;
    line-height: 1;
  }
}

@media (max-width: 480px) {
  body.trend-route .trend-table.old-style.classic-trend td.selection-cell.active-cell .selection-hit {
    width: 24px;
    height: 24px;
    font-size: 12px;
    line-height: 24px;
  }

  body.trend-route .trend-table.old-style.classic-trend td.selection-cell.active-cell .selection-ball {
    width: 26px;
    height: 26px;
    font-size: 12px;
    line-height: 26px;
  }
}

@media (max-width: 768px) {
  body.trend-route .trend-board {
    --trend-issue-w: 86px;
    --trend-week-w: 54px;
    --trend-open-w: 112px;
    --trend-sum-w: 56px;
    --trend-digit-w: 28px;
    --trend-stat-w: 52px;
  }

  body.trend-route .trend-table.old-style.classic-trend {
    width: 1730px;
    min-width: 1730px;
    max-width: 1730px;
    font-size: 12px;
  }

  body.trend-route .classic-trend .trend-group-row th,
  body.trend-route .classic-trend .trend-digit-row th {
    height: 46px;
    padding: 0 4px;
    font-size: 12px;
    line-height: 1.2;
    white-space: normal;
  }

  body.trend-route .trend-table.old-style.classic-trend tbody td {
    height: 48px;
    font-size: 12px;
  }

  body.trend-route .classic-trend .open-cell .balls {
    gap: 4px;
  }

  body.trend-route .classic-trend .open-cell .ball {
    width: 22px;
    height: 22px;
    font-size: 12px;
  }

  body.trend-route .classic-trend .trend-number,
  body.trend-route .classic-trend .issue-cell,
  body.trend-route .classic-trend .week-cell,
  body.trend-route .classic-trend .sum-cell {
    font-size: 12px;
  }

  body.trend-route .classic-trend td.active-cell .trend-hit,
  body.trend-route .classic-trend .selection-hit {
    width: 24px;
    height: 24px;
    font-size: 12px;
    line-height: 24px;
  }

  body.trend-route .trend-table.old-style.classic-trend td.selection-cell.active-cell .selection-hit {
    width: 24px;
    height: 24px;
    font-size: 12px;
    line-height: 24px;
  }

  body.trend-route .trend-table.old-style.classic-trend td.selection-cell.active-cell .selection-ball {
    width: 26px;
    height: 26px;
    font-size: 12px;
    line-height: 26px;
  }

  body.trend-route .classic-trend .stat-cell,
  body.trend-route .classic-trend .group-badge {
    font-size: 12px;
    line-height: 1.15;
  }

  body.trend-route .classic-trend .group-badge {
    min-width: 30px;
    padding: 3px 4px;
  }
}

.site-popup {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 18px;
}

.site-popup-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.52);
}

.site-popup-card {
  position: relative;
  width: min(440px, 100%);
  max-height: min(640px, calc(100vh - 36px));
  overflow: auto;
  padding: 22px;
  border: 1px solid #e0e5ed;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 20px 60px rgba(18, 28, 45, 0.28);
}

.site-popup-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.site-popup-head h2 {
  margin: 0;
  color: #1f2937;
  font-size: 20px;
  line-height: 1.35;
}

.site-popup-close {
  width: 34px;
  height: 34px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: #5d6878;
  background: #eef2f7;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.site-popup-close:hover {
  color: #202733;
  background: #e2e8f0;
}

.site-popup-content {
  color: #3d4654;
  font-size: 15px;
  line-height: 1.75;
}

.site-popup-content p {
  margin: 0 0 12px;
}

.site-popup-content p:last-child {
  margin-bottom: 0;
}

.site-popup-confirm {
  width: 100%;
  min-height: 42px;
  margin-top: 20px;
  border: 0;
  border-radius: 6px;
  color: #fff;
  background: #1463d8;
  font-size: 15px;
  cursor: pointer;
}

.site-popup-confirm:hover {
  background: #0c4cac;
}

@media (max-width: 480px) {
  .site-popup {
    padding: 12px;
  }

  .site-popup-card {
    max-height: calc(100vh - 24px);
    padding: 18px;
  }
}
