[v-cloak] {
  display: none;
}

:root {
  --bg: #fff5f5;
  --card: #ffffff;
  --ink: #182027;
  --muted: #6d747c;
  --line: #f1d2d2;
  --brand: #c81e1e;
  --brand-weak: #fff0f0;
  --accent: #e53935;
  --gold: #b45309;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

button {
  font: inherit;
  cursor: pointer;
  touch-action: manipulation;
}

.article-card,
.rank-card,
.podium-item,
.mine-menu button,
.bottom-nav button {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

#app {
  width: min(430px, 100%);
  min-height: 100vh;
  margin: 0 auto;
  padding: 12px 14px 86px;
  background:
    linear-gradient(180deg, rgba(200, 30, 30, .12), rgba(255, 245, 245, 0) 210px),
    var(--bg);
}

.theme-bar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  margin: -12px -14px 14px;
  padding: 10px 14px;
  background: rgba(255, 255, 255, .92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}

.theme-bar h1 {
  margin: 0;
  font-size: 17px;
  line-height: 1.2;
  letter-spacing: 0;
}

.theme-bar button {
  position: absolute;
  right: 14px;
  min-width: 50px;
  height: 32px;
  color: var(--brand);
  background: var(--brand-weak);
  border: 1px solid rgba(200, 30, 30, .14);
  border-radius: 8px;
  font-weight: 700;
  font-size: 13px;
}

.banner {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  background: var(--card);
  box-shadow: 0 12px 28px rgba(24, 32, 39, .12);
}

.banner-track {
  display: flex;
  transition: transform .35s ease;
}

.banner-item {
  position: relative;
  min-width: 100%;
  height: 176px;
  overflow: hidden;
}

.banner-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.banner-item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, .04), rgba(0, 0, 0, .18));
}

.banner-marquee {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
  height: 36px;
  overflow: hidden;
  background: rgba(0, 0, 0, .46);
  color: #fff;
  backdrop-filter: blur(4px);
}

.banner-marquee p {
  display: inline-flex;
  min-width: 200%;
  height: 36px;
  margin: 0;
  align-items: center;
  white-space: nowrap;
  animation: bannerMarquee 16s linear infinite;
}

.banner-marquee span {
  display: inline-block;
  min-width: 50%;
  padding: 0 56px 0 14px;
  font-size: 16px;
  font-weight: 800;
  line-height: 36px;
}

@keyframes bannerMarquee {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

.banner-dots {
  position: absolute;
  right: 14px;
  bottom: 48px;
  z-index: 2;
  display: flex;
  gap: 5px;
}

.banner-dots button {
  width: 6px;
  height: 6px;
  padding: 0;
  background: rgba(255, 255, 255, .55);
  border: 0;
  border-radius: 999px;
}

.banner-dots button.active {
  width: 16px;
  background: #fff;
}

.notice {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 42px;
  margin: 14px 0;
  padding: 0 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(24, 32, 39, .05);
}

.notice strong {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 8px;
  color: #fff;
  background: var(--accent);
  border-radius: 999px;
  font-size: 13px;
}

.notice-window {
  height: 28px;
  overflow: hidden;
  flex: 1;
}

.notice p {
  display: flex;
  flex-direction: column;
  margin: 0;
  transition: transform .28s ease;
}

.notice span {
  height: 28px;
  color: var(--ink);
  font-size: 13px;
  line-height: 28px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.article-section {
  padding-top: 2px;
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 16px 0 10px;
}

.section-title h2 {
  margin: 0;
  font-size: 19px;
  line-height: 1.2;
}

.section-title span {
  color: var(--muted);
  font-size: 13px;
}

.article-card {
  display: grid;
  grid-template-columns: 46px 1fr;
  gap: 12px;
  margin-bottom: 12px;
  padding: 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

.author-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), #ef4444);
  border-radius: 50%;
  font-size: 18px;
  font-weight: 800;
  box-shadow: inset 0 -10px 16px rgba(0, 0, 0, .1);
}

.article-info {
  position: relative;
  min-width: 0;
  padding-right: 66px;
}

.article-price {
  position: absolute;
  top: 0;
  right: 0;
  color: var(--accent);
  font-size: 16px;
  line-height: 1.2;
}

.card-seal {
  position: absolute;
  right: 2px;
  bottom: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border: 3px solid currentColor;
  border-radius: 50%;
  font-size: 14px;
  font-weight: 900;
  transform: rotate(-15deg);
  opacity: .86;
  pointer-events: none;
}

.card-seal.red {
  color: #d7261e;
}

.card-seal.black {
  color: #1f2933;
}

.article-meta,
.article-foot {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
}

.article-meta {
  color: var(--brand);
  font-size: 12px;
  font-weight: 700;
  min-height: 18px;
}

.article-meta em {
  color: var(--muted);
  font-style: normal;
  font-weight: 500;
}

.article-card h3 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 8px 0 8px;
  font-size: 16px;
  line-height: 1.42;
}

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

.article-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-bottom: 14px;
  padding: 5px;
  background: #f7dddd;
  border-radius: 8px;
}

.article-tabs.single {
  grid-template-columns: 1fr;
  width: 100%;
}

.article-tabs button {
  height: 38px;
  color: var(--muted);
  background: transparent;
  border: 0;
  border-radius: 6px;
  font-weight: 700;
}

.article-tabs button.active {
  color: var(--brand);
  background: var(--card);
  box-shadow: 0 5px 14px rgba(24, 32, 39, .08);
}

.rank-section {
  padding-top: 4px;
}

.podium {
  display: grid;
  grid-template-columns: 1fr 1.08fr 1fr;
  align-items: end;
  gap: 8px;
  margin: 12px 0 16px;
}

.podium-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  min-height: 142px;
  padding: 14px 8px 12px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

.podium-item.place-1 {
  min-height: 176px;
  border-color: rgba(217, 144, 0, .28);
  background: linear-gradient(180deg, #fff7d6, #fff);
}

.podium-item.place-2 {
  min-height: 152px;
  background: linear-gradient(180deg, #eef2f6, #fff);
}

.podium-item.place-3 {
  min-height: 136px;
  background: linear-gradient(180deg, #ffe8d8, #fff);
}

.podium-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  margin-bottom: 8px;
  color: #fff;
  background: var(--brand);
  border-radius: 50%;
  font-weight: 800;
}

.place-1 .podium-avatar {
  background: linear-gradient(135deg, #f7c948, #d99000);
}

.place-2 .podium-avatar {
  background: linear-gradient(135deg, #d7dee8, #8895a7);
}

.place-3 .podium-avatar {
  background: linear-gradient(135deg, #e6a06d, #b85c28);
}

.podium-item strong {
  font-size: 15px;
}

.podium-item p {
  margin: 5px 0 8px;
  color: var(--muted);
  font-size: 12px;
}

.podium-item b {
  color: var(--accent);
  font-size: 13px;
}

.rank-follow {
  height: 28px;
  margin-top: 8px;
  padding: 0 10px;
  color: var(--brand);
  background: var(--brand-weak);
  border: 1px solid rgba(200, 30, 30, .16);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.rank-card {
  display: grid;
  grid-template-columns: 38px 1fr auto auto;
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
  padding: 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

.rank-no {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  color: #fff;
  background: var(--brand);
  border-radius: 50%;
  font-weight: 800;
}

.rank-no.top-1 {
  background: linear-gradient(135deg, #f7c948, #d99000);
  box-shadow: 0 6px 14px rgba(217, 144, 0, .25);
}

.rank-no.top-2 {
  background: linear-gradient(135deg, #d7dee8, #8895a7);
  box-shadow: 0 6px 14px rgba(136, 149, 167, .24);
}

.rank-no.top-3 {
  background: linear-gradient(135deg, #e6a06d, #b85c28);
  box-shadow: 0 6px 14px rgba(184, 92, 40, .24);
}

.rank-main strong {
  display: block;
  margin-bottom: 4px;
  font-size: 16px;
}

.rank-main p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.rank-card b {
  color: var(--accent);
  font-size: 18px;
}

.article-detail {
  padding-top: 4px;
}

.back-button {
  height: 34px;
  margin-bottom: 12px;
  padding: 0 12px;
  color: var(--brand);
  background: var(--brand-weak);
  border: 1px solid rgba(200, 30, 30, .16);
  border-radius: 8px;
  font-weight: 700;
}

.detail-author {
  display: grid;
  grid-template-columns: 46px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

.detail-author strong {
  display: block;
  margin-bottom: 4px;
  font-size: 15px;
}

.detail-author p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.follow-button {
  min-width: 64px;
  height: 32px;
  color: #fff;
  background: var(--brand);
  border: 0;
  border-radius: 999px;
  font-weight: 800;
  font-size: 13px;
}

.article-head {
  position: relative;
  padding: 16px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

.article-author-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.article-author-line span {
  color: var(--brand);
  font-size: 14px;
  font-weight: 800;
}

.article-head p {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 13px;
}

.article-head h2 {
  margin: 0;
  font-size: 24px;
  line-height: 1.35;
}

.seal {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border: 3px solid currentColor;
  border-radius: 50%;
  font-size: 18px;
  font-weight: 900;
  transform: rotate(-16deg);
  opacity: .9;
}

.seal.red {
  color: #d7261e;
}

.seal.black {
  color: #1f2933;
}

.statement-box {
  margin-top: 14px;
  padding: 14px;
  background: #fff7ed;
  border: 1px solid #f1d4b8;
  border-radius: 8px;
}

.statement-box strong {
  display: block;
  margin-bottom: 6px;
  color: var(--gold);
  font-size: 15px;
}

.statement-box p {
  margin: 0;
  color: #7c5a34;
  font-size: 13px;
  line-height: 1.6;
}

.locked-content {
  margin-top: 18px;
  padding: 12px 14px 16px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

.locked-content > span {
  display: block;
  margin-bottom: 14px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.lock-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 118px;
  margin-bottom: 14px;
  background: #fffafa;
  border: 1px dashed var(--line);
  border-radius: 8px;
  cursor: pointer;
}

.lock-body strong {
  display: block;
  margin-bottom: 8px;
  font-size: 28px;
}

.lock-body p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.paid-content {
  margin-top: 18px;
  padding: 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

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

.paid-content-head span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.paid-content-head button {
  height: 30px;
  padding: 0 10px;
  color: #fff;
  background: var(--brand);
  border: 0;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 800;
}

.paid-content p {
  margin: 0;
  color: #000;
  font-size: 15px;
  line-height: 1.8;
  white-space: pre-wrap;
}

.content-lines {
  display: grid;
  gap: 10px;
}

.content-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.content-line b {
  min-width: 42px;
  height: 34px;
  padding: 0 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #000;
  background: #f7f8f8;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 15px;
}

.content-line b.zodiac {
  color: #000;
  background: #f7f8f8;
  border-color: var(--line);
}

.content-line b.hit {
  color: #d7261e;
  background: #fff1f0;
  border-color: rgba(215, 38, 30, .28);
}

.history-section {
  margin-top: 18px;
}

.history-row {
  position: relative;
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 10px;
  align-items: start;
  margin-bottom: 10px;
  padding: 12px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.history-row span {
  color: var(--muted);
  font-size: 13px;
}

.history-row strong {
  display: block;
  margin-bottom: 5px;
  color: var(--ink);
  font-size: 15px;
}

.history-row p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.history-main {
  min-width: 0;
  padding-right: 46px;
}

.history-lines {
  gap: 6px;
}

.history-lines .content-line {
  gap: 6px;
}

.history-lines .content-line b {
  min-width: 36px;
  height: 30px;
  font-size: 13px;
}

.history-seal {
  position: absolute;
  right: 10px;
  top: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border: 2px solid currentColor;
  border-radius: 50%;
  font-size: 12px;
  font-weight: 900;
  transform: rotate(-14deg);
}

.history-seal.red {
  color: #d7261e;
}

.history-seal.black {
  color: #1f2933;
}

.mine-section {
  padding-top: 8px;
}

.profile-card {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 14px;
  align-items: center;
  padding: 18px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

.profile-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), #ef4444);
  border-radius: 50%;
  font-size: 22px;
  font-weight: 800;
}

.profile-card strong {
  display: block;
  margin-bottom: 8px;
  font-size: 18px;
}

.profile-card p {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 13px;
}

.profile-card b {
  display: block;
  color: var(--accent);
  font-size: 24px;
}

.asset-breakdown {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.asset-breakdown span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  color: var(--muted);
  background: #fff7f7;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
}

.profile-card button {
  grid-column: 1 / -1;
  height: 42px;
  margin-top: 4px;
  color: #fff;
  background: var(--brand);
  border: 0;
  border-radius: 8px;
  font-weight: 800;
}

.mine-menu {
  margin-top: 14px;
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

.mine-menu button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: 48px;
  padding: 0 14px;
  color: var(--ink);
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  font-weight: 700;
}

.mine-menu button:last-child {
  border-bottom: 0;
}

.mine-menu button > span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.unread-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 7px;
  color: #fff;
  background: #ef3b2d;
  border-radius: 999px;
  font-size: 11px;
  font-style: normal;
  line-height: 1.35;
}

.unread-badge::before {
  width: 5px;
  height: 5px;
  background: #fff;
  border-radius: 50%;
  content: "";
}

.mine-menu b {
  color: var(--muted);
  font-size: 20px;
  font-weight: 400;
}

.bill-section {
  padding-top: 4px;
}

.bill-row,
.team-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
  margin-bottom: 10px;
  padding: 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

.bill-row strong,
.team-row strong {
  display: block;
  margin-bottom: 5px;
  font-size: 15px;
}

.bill-row p,
.team-row p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.bill-row b {
  color: var(--accent);
  font-size: 16px;
}

.bill-row b.income {
  color: var(--brand);
}

.bill-amount {
  display: grid;
  gap: 4px;
  justify-items: end;
}

.bill-amount span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.team-row {
  grid-template-columns: 42px 1fr;
}

.profile-avatar.small {
  width: 42px;
  height: 42px;
  font-size: 17px;
}

.follow-section {
  padding-top: 4px;
}

.follow-row {
  display: grid;
  grid-template-columns: 46px 1fr auto;
  gap: 12px;
  align-items: center;
  margin-bottom: 10px;
  padding: 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

.follow-row strong {
  display: block;
  margin-bottom: 4px;
  font-size: 15px;
}

.follow-row p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.follow-row button {
  height: 32px;
  padding: 0 10px;
  color: var(--brand);
  background: var(--brand-weak);
  border: 1px solid rgba(200, 30, 30, .16);
  border-radius: 999px;
  font-weight: 800;
  font-size: 12px;
}

.empty-box {
  padding: 28px 12px;
  color: var(--muted);
  text-align: center;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.share-section {
  padding-top: 4px;
}

.share-card {
  padding: 22px 16px;
  text-align: center;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

.share-card h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.share-card p {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.share-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 0 0 16px;
}

.share-stats div {
  padding: 10px;
  background: #fffafa;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.share-stats span {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 12px;
}

.share-stats b {
  color: var(--brand);
  font-size: 16px;
}

.qr-box {
  display: grid;
  place-items: center;
  width: 238px;
  height: 238px;
  margin: 0 auto 14px;
  background: #fffafa;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.qr-box img {
  width: 220px;
  height: 220px;
}

.share-card strong {
  display: block;
  margin-bottom: 8px;
  color: var(--brand);
  font-size: 15px;
}

.share-link {
  display: grid;
  gap: 10px;
  padding: 12px;
  background: #fffafa;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.share-link span {
  color: var(--muted);
  font-size: 12px;
  word-break: break-all;
}

.share-link button {
  height: 36px;
  color: #fff;
  background: var(--brand);
  border: 0;
  border-radius: 8px;
  font-weight: 800;
}

.lottery-wheel-wrap {
  position: relative;
  display: grid;
  place-items: center;
  width: min(300px, 82vw);
  aspect-ratio: 1;
  margin: 12px auto 18px;
}

.lottery-wheel {
  position: absolute;
  inset: 0;
  border: 10px solid #fff;
  border-radius: 50%;
  background:
    conic-gradient(#f7d06a 0 45deg, #f28f5b 45deg 90deg, #ef4444 90deg 135deg, #f7d06a 135deg 180deg, #f28f5b 180deg 225deg, #ef4444 225deg 270deg, #f7d06a 270deg 315deg, #f28f5b 315deg 360deg);
  box-shadow: 0 18px 36px rgba(24, 32, 39, .18);
  transition: transform 2.6s cubic-bezier(.12, .82, .18, 1);
}

.lottery-wheel::before {
  content: "";
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 0%, #fff 0 4px, transparent 5px),
    radial-gradient(circle at 85% 15%, #ffeaa0 0 4px, transparent 5px),
    radial-gradient(circle at 100% 50%, #fff 0 4px, transparent 5px),
    radial-gradient(circle at 85% 85%, #ffeaa0 0 4px, transparent 5px),
    radial-gradient(circle at 50% 100%, #fff 0 4px, transparent 5px),
    radial-gradient(circle at 15% 85%, #ffeaa0 0 4px, transparent 5px),
    radial-gradient(circle at 0% 50%, #fff 0 4px, transparent 5px),
    radial-gradient(circle at 15% 15%, #ffeaa0 0 4px, transparent 5px);
  opacity: .45;
  pointer-events: none;
}

.lottery-wheel.spinning::before {
  animation: lotteryBlink .42s steps(2, end) infinite;
}

.lottery-wheel.spinning {
  box-shadow: 0 18px 36px rgba(24, 32, 39, .18), 0 0 24px rgba(247, 208, 106, .7);
}

@keyframes lotteryBlink {
  0% {
    opacity: .35;
    filter: brightness(1);
  }
  50% {
    opacity: 1;
    filter: brightness(1.35);
  }
  100% {
    opacity: .55;
    filter: brightness(1.1);
  }
}

.lottery-prize {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 50%;
  height: 1px;
  transform-origin: 0 0;
  pointer-events: none;
}

.lottery-prize span {
  position: absolute;
  left: 58%;
  top: 50%;
  display: block;
  width: 74px;
  transform: translate(-50%, -50%);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  text-align: center;
  line-height: 1.15;
  text-shadow: 0 1px 2px rgba(0, 0, 0, .2);
  word-break: keep-all;
}

.lottery-pointer {
  position: absolute;
  top: -5px;
  z-index: 2;
  width: 0;
  height: 0;
  border-left: 13px solid transparent;
  border-right: 13px solid transparent;
  border-top: 24px solid var(--accent);
}

.lottery-draw-button {
  position: relative;
  z-index: 3;
  width: 96px;
  height: 96px;
  color: #fff;
  background: var(--brand);
  border: 8px solid #fff;
  border-radius: 50%;
  box-shadow: 0 10px 24px rgba(200, 30, 30, .24);
  font-weight: 900;
}

.lottery-draw-button:disabled {
  opacity: .65;
}

.lottery-result {
  margin: 10px 0;
  padding: 12px;
  color: var(--brand);
  background: var(--brand-weak);
  border-radius: 8px;
  font-weight: 800;
  text-align: center;
}

.form-section {
  padding-top: 4px;
}

.simple-form {
  display: grid;
  gap: 10px;
  padding: 16px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

.simple-form label {
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
}

.simple-form textarea,
.simple-form input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffafa;
  font: inherit;
}

.simple-form textarea {
  min-height: 128px;
  padding: 12px;
  resize: vertical;
}

.simple-form input {
  height: 42px;
  padding: 0 12px;
}

.simple-form button {
  height: 42px;
  margin-top: 4px;
  color: #fff;
  background: var(--brand);
  border: 0;
  border-radius: 8px;
  font-weight: 800;
}

.service-section {
  height: calc(100vh - 98px);
  min-height: 0;
  padding-top: 4px;
  padding-bottom: 126px;
  overflow: hidden;
}

.chat-box {
  display: flex;
  flex-direction: column;
  gap: 12px;
  height: 100%;
  overflow-y: auto;
  padding-bottom: 12px;
  -webkit-overflow-scrolling: touch;
}

.chat-end-anchor {
  height: 1px;
}

.chat-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.chat-row.me {
  flex-direction: row-reverse;
}

.chat-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  color: #fff;
  background: var(--brand);
  border-radius: 50%;
  font-size: 13px;
  font-weight: 800;
}

.chat-row.service .chat-avatar {
  background: var(--accent);
}

.chat-avatar img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.chat-row > div:last-child {
  max-width: 76%;
}

.chat-time {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 11px;
}

.chat-row.me .chat-time {
  text-align: right;
}

.chat-bubble {
  padding: 10px 12px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 14px;
  line-height: 1.45;
}

.chat-row.me .chat-bubble {
  color: #fff;
  background: var(--brand);
  border-color: var(--brand);
}

.chat-image {
  display: block;
  max-width: 180px;
  max-height: 220px;
  margin-top: 6px;
  border: 1px solid var(--line);
  border-radius: 8px;
  object-fit: cover;
}

.chat-row.me .chat-image {
  margin-left: auto;
}

.chat-input {
  position: fixed;
  left: 50%;
  bottom: 62px;
  z-index: 7;
  display: grid;
  grid-template-columns: 54px 54px 1fr 68px;
  gap: 8px;
  width: min(430px, 100%);
  padding: 10px 14px;
  transform: translateX(-50%);
  background: rgba(255, 255, 255, .96);
  border-top: 1px solid var(--line);
  backdrop-filter: blur(16px);
}

.chat-image-button {
  display: grid;
  place-items: center;
  height: 38px;
  color: var(--brand);
  background: var(--brand-weak);
  border: 1px solid rgba(200, 30, 30, .18);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
}

.chat-image-button input {
  display: none;
}

.chat-emoji-button {
  height: 38px;
  color: var(--brand);
  background: var(--brand-weak);
  border: 1px solid rgba(200, 30, 30, .18);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
}

.emoji-panel {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(10, 1fr);
  gap: 6px;
  padding: 8px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(24, 32, 39, .08);
}

.emoji-panel button {
  width: 100%;
  aspect-ratio: 1;
  height: auto;
  padding: 0;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 18px;
  line-height: 1;
}

.chat-image-preview {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 10px;
}

.chat-image-preview img {
  width: 58px;
  height: 58px;
  border: 1px solid var(--line);
  border-radius: 8px;
  object-fit: cover;
}

.chat-image-preview button {
  width: 58px;
  color: var(--danger);
  background: #fff;
  border: 1px solid var(--line);
}

.chat-input input {
  min-width: 0;
  height: 38px;
  padding: 0 12px;
  background: #fffafa;
  border: 1px solid var(--line);
  border-radius: 999px;
  font: inherit;
}

.chat-input button {
  height: 38px;
  color: #fff;
  background: var(--brand);
  border: 0;
  border-radius: 999px;
  font-weight: 800;
}

.chat-input .chat-emoji-button {
  color: var(--brand);
  background: var(--brand-weak);
  border: 1px solid rgba(200, 30, 30, .18);
}

.chat-input .emoji-panel button {
  height: auto;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 8px;
  font-weight: 400;
}

.bottom-nav {
  position: fixed;
  left: 50%;
  bottom: 0;
  z-index: 8;
  display: flex;
  width: min(430px, 100%);
  height: 62px;
  transform: translateX(-50%);
  background: rgba(255, 255, 255, .96);
  border-top: 1px solid var(--line);
  box-shadow: 0 -8px 24px rgba(24, 32, 39, .08);
  backdrop-filter: blur(16px);
}

.bottom-nav button {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  background: transparent;
  border: 0;
  font-weight: 700;
}

.bottom-nav button.active {
  color: var(--brand);
}

.bottom-nav button > span {
  position: relative;
}

.bottom-nav .nav-unread-dot {
  position: absolute;
  left: 100%;
  top: -6px;
  width: 8px;
  height: 8px;
  margin-left: 2px;
  background: #ef3b2d;
  border: 1px solid #fff;
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(239, 59, 45, .18);
}

.modal-mask {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(24, 32, 39, .42);
}

.rules-modal {
  width: min(430px, 100%);
  max-height: 72vh;
  padding: 16px;
  overflow-y: auto;
  background: var(--card);
  border-radius: 8px;
  box-shadow: 0 18px 46px rgba(24, 32, 39, .24);
}

.login-modal {
  display: grid;
  gap: 12px;
  width: min(360px, 100%);
  padding: 18px;
  background: var(--card);
  border-radius: 8px;
  box-shadow: 0 18px 46px rgba(24, 32, 39, .24);
}

.login-modal h2 {
  margin: 0 0 4px;
  text-align: center;
  font-size: 20px;
}

.pin-hint {
  margin: -2px 0 10px;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

.pin-dots {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin: 8px 0 18px;
}

.pin-dots i {
  width: 12px;
  height: 12px;
  border: 1px solid var(--muted);
  border-radius: 50%;
}

.pin-dots i.active {
  background: var(--ink);
  border-color: var(--ink);
}

.pin-keypad {
  display: grid;
  grid-template-columns: repeat(3, 64px);
  justify-content: center;
  gap: 12px 18px;
}

.pin-keypad button {
  width: 64px;
  height: 64px;
  color: var(--ink);
  background: #fffafa;
  border: 1px solid var(--line);
  border-radius: 50%;
  font-size: 22px;
  font-weight: 800;
}

.pin-keypad button:last-child {
  font-size: 13px;
}

.rule-item {
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.rule-tip {
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

.checkin-box {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
  margin: 10px 0 6px;
  padding: 12px;
  background: var(--brand-weak);
  border: 1px solid rgba(200, 30, 30, .16);
  border-radius: 8px;
}

.checkin-box strong {
  display: block;
  margin-bottom: 4px;
  color: var(--brand);
  font-size: 15px;
}

.checkin-box p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.checkin-box button {
  min-width: 64px;
  height: 34px;
  color: #fff;
  background: var(--brand);
  border: 0;
  border-radius: 999px;
  font-weight: 800;
}

.checkin-box button.checked {
  color: var(--muted);
  background: #fff;
  border: 1px solid var(--line);
}

.mine-checkin {
  margin-top: 14px;
  margin-bottom: 0;
  background: var(--card);
  box-shadow: 0 8px 22px rgba(24, 32, 39, .06);
}

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

.rule-item button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 0;
  color: var(--ink);
  background: transparent;
  border: 0;
  font-weight: 800;
  text-align: left;
}

.rule-item button span {
  font-size: 16px;
}

.rule-item button b {
  color: var(--brand);
  font-size: 20px;
  line-height: 1;
}

.rule-item p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.modal-close {
  width: 100%;
  height: 40px;
  margin-top: 14px;
  color: #fff;
  background: var(--brand);
  border: 0;
  border-radius: 8px;
  font-weight: 800;
}

.pretty-mask {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px;
  background: rgba(15, 25, 32, .42);
  backdrop-filter: blur(8px);
}

.pretty-dialog {
  width: min(330px, 100%);
  padding: 22px 18px 18px;
  text-align: center;
  background: #fff;
  border: 1px solid rgba(226, 235, 231, .95);
  border-radius: 14px;
  box-shadow: 0 24px 58px rgba(22, 34, 42, .24);
  animation: prettyPop .18s ease-out;
}

.pretty-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  margin-bottom: 10px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-strong));
  border-radius: 50%;
  font-size: 18px;
  font-weight: 900;
}

.pretty-dialog.success .pretty-icon {
  background: linear-gradient(135deg, #e53935, #b91c1c);
}

.pretty-dialog.warning .pretty-icon,
.pretty-dialog.confirm .pretty-icon {
  background: linear-gradient(135deg, #f1a832, #d07118);
}

.pretty-dialog.error .pretty-icon {
  background: linear-gradient(135deg, #ef4b39, #bd2419);
}

.pretty-dialog h3 {
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 18px;
  font-weight: 900;
}

.pretty-dialog p {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
  white-space: pre-wrap;
}

.pretty-dialog button {
  width: 100%;
  height: 40px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-strong));
  border: 0;
  border-radius: 10px;
  font-weight: 900;
}

.pretty-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.pretty-actions .ghost {
  color: var(--muted);
  background: #fff5f5;
  border: 1px solid var(--line);
  box-shadow: none;
}

@keyframes prettyPop {
  from {
    transform: translateY(8px) scale(.96);
    opacity: 0;
  }
  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

/* User UI polish */
:root {
  --bg: #fff5f5;
  --card: #ffffff;
  --ink: #17212b;
  --muted: #7d6f72;
  --line: #f1d2d2;
  --brand: #c81e1e;
  --brand-strong: #991b1b;
  --brand-weak: #fff0f0;
  --accent: #e53935;
  --gold: #b9801c;
  --shadow: 0 10px 28px rgba(31, 47, 55, .08);
  --soft-shadow: 0 4px 14px rgba(31, 47, 55, .06);
}

body {
  background:
    radial-gradient(circle at 18% -6%, rgba(200, 30, 30, .14), transparent 34%),
    linear-gradient(180deg, #fffafa 0%, #fff5f5 100%);
}

#app {
  padding: 12px 14px 92px;
  background:
    linear-gradient(180deg, rgba(200, 30, 30, .1), rgba(255, 245, 245, 0) 220px),
    var(--bg);
}

.theme-bar {
  min-height: 56px;
  margin-bottom: 16px;
  border-bottom-color: rgba(241, 210, 210, .8);
  box-shadow: 0 4px 18px rgba(31, 47, 55, .05);
}

.theme-bar h1 {
  font-size: 19px;
  font-weight: 900;
}

.theme-bar button,
.back-button {
  border-radius: 999px;
  box-shadow: inset 0 0 0 1px rgba(200, 30, 30, .06);
}

.banner {
  border: 1px solid rgba(255, 255, 255, .72);
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.banner-item {
  height: 190px;
}

.banner-item::after {
  background: linear-gradient(180deg, rgba(0, 0, 0, 0), rgba(0, 0, 0, .24));
}

.banner-marquee {
  height: 38px;
  background: linear-gradient(90deg, rgba(153, 27, 27, .88), rgba(41, 20, 20, .62));
}

.banner-marquee p {
  height: 38px;
}

.banner-marquee span {
  font-size: 15px;
  line-height: 38px;
}

.banner-dots {
  bottom: 52px;
}

.article-section {
  padding-top: 14px;
}

.article-tabs {
  position: sticky;
  top: 58px;
  z-index: 4;
  gap: 4px;
  margin-bottom: 12px;
  padding: 4px;
  background: rgba(255, 235, 235, .9);
  border: 1px solid rgba(255, 255, 255, .72);
  border-radius: 12px;
  backdrop-filter: blur(12px);
}

.article-tabs button {
  height: 40px;
  border-radius: 9px;
  font-size: 15px;
}

.article-tabs button.active {
  color: var(--brand-strong);
  box-shadow: var(--soft-shadow);
}

.article-card,
.rank-card,
.follow-row,
.bill-row,
.team-row,
.profile-card,
.mine-menu,
.share-card,
.simple-form,
.paid-content,
.locked-content,
.article-head,
.history-row,
.empty-box {
  border-color: rgba(241, 210, 210, .92);
  border-radius: 12px;
  box-shadow: var(--soft-shadow);
}

.article-card {
  grid-template-columns: 50px 1fr;
  gap: 13px;
  margin-bottom: 10px;
  padding: 14px 14px 13px;
  transition: transform .16s ease, box-shadow .16s ease;
}

.article-card:active,
.rank-card:active,
.mine-menu button:active {
  transform: scale(.99);
}

.author-avatar,
.profile-avatar,
.podium-avatar,
.rank-no,
.chat-avatar {
  background: linear-gradient(135deg, #c81e1e, #ef4444);
  box-shadow: inset 0 -10px 16px rgba(0, 0, 0, .12), 0 5px 12px rgba(200, 30, 30, .18);
}

.article-info {
  padding-right: 74px;
}

.article-price {
  top: 1px;
  padding: 3px 8px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), #f06f4c);
  border-radius: 999px;
  font-size: 13px;
  line-height: 1.25;
}

.article-meta {
  gap: 6px;
}

.article-meta span,
.article-meta em {
  max-width: 46%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.article-card h3 {
  margin: 7px 0 7px;
  color: #07131d;
  font-size: 17px;
  font-weight: 900;
}

.article-foot span {
  padding: 3px 8px;
  background: #fff5f5;
  border-radius: 999px;
}

.card-seal,
.seal,
.history-seal {
  background: rgba(255, 255, 255, .86);
  backdrop-filter: blur(2px);
}

.section-title h2 {
  font-size: 20px;
  font-weight: 900;
}

.podium {
  gap: 9px;
}

.podium-item {
  border-radius: 12px;
}

.podium-item strong,
.rank-main strong {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-card {
  grid-template-columns: 40px minmax(0, 1fr) auto auto;
}

.article-head {
  padding: 18px;
}

.article-head h2 {
  max-width: calc(100% - 72px);
  color: #07131d;
  font-size: 24px;
  font-weight: 950;
}

.statement-box {
  border-radius: 12px;
  background: linear-gradient(180deg, #fff8ed, #fffdf8);
}

.lock-body {
  border-radius: 12px;
  background: linear-gradient(180deg, #f8fbfa, #eef6f2);
}

.content-line b {
  border-radius: 10px;
  font-weight: 900;
}

.profile-card {
  grid-template-columns: 62px 1fr;
  padding: 18px;
  background:
    linear-gradient(135deg, rgba(200, 30, 30, .12), rgba(255, 255, 255, .96) 42%),
    #fff;
}

.profile-card button,
.simple-form button,
.share-link button,
.paid-content-head button,
.chat-input button,
.modal-close {
  background: linear-gradient(135deg, var(--brand), var(--brand-strong));
  box-shadow: 0 7px 16px rgba(200, 30, 30, .2);
}

.checkin-box {
  border-radius: 12px;
}

.mine-menu {
  overflow: hidden;
}

.mine-menu button {
  height: 52px;
  font-size: 15px;
}

.service-section {
  padding-top: 0;
}

.chat-box {
  padding: 6px 2px 14px;
}

.chat-bubble {
  border-radius: 14px 14px 14px 4px;
  box-shadow: var(--soft-shadow);
}

.chat-row.me .chat-bubble {
  border-radius: 14px 14px 4px 14px;
}

.chat-input {
  grid-template-columns: 52px 52px 1fr 64px;
  gap: 7px;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  border-top-color: rgba(226, 235, 231, .82);
  box-shadow: 0 -8px 24px rgba(31, 47, 55, .08);
}

.chat-image-button,
.chat-emoji-button,
.chat-input input {
  height: 40px;
}

.emoji-panel {
  border-radius: 12px;
}

.bottom-nav {
  height: calc(64px + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  border-top-color: rgba(226, 235, 231, .84);
}

.bottom-nav button {
  position: relative;
  font-size: 14px;
}

.bottom-nav button.active span {
  padding: 7px 13px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-strong));
  border-radius: 999px;
  box-shadow: 0 7px 16px rgba(200, 30, 30, .2);
}

.modal-mask {
  background: rgba(12, 21, 27, .46);
  backdrop-filter: blur(6px);
}

.rules-modal,
.login-modal {
  border-radius: 14px;
}

.pin-keypad button {
  background: #fff;
  box-shadow: var(--soft-shadow);
}

@media (max-width: 360px) {
  #app {
    padding-left: 10px;
    padding-right: 10px;
  }

  .theme-bar {
    margin-left: -10px;
    margin-right: -10px;
  }

  .article-card {
    grid-template-columns: 44px 1fr;
    padding: 12px;
  }

  .article-info {
    padding-right: 62px;
  }

  .chat-input {
    grid-template-columns: 46px 46px 1fr 58px;
  }
}

/* 2026 mobile refresh */
:root {
  --bg: #fff5f5;
  --surface: rgba(255, 255, 255, .88);
  --surface-strong: #ffffff;
  --ink: #101923;
  --muted: #7d6f72;
  --line: rgba(241, 210, 210, .9);
  --brand: #c81e1e;
  --brand-strong: #991b1b;
  --brand-weak: #fff0f0;
  --accent: #e53935;
  --blue: #b91c1c;
  --gold: #b45309;
  --shadow: 0 14px 34px rgba(22, 38, 45, .09);
  --soft-shadow: 0 7px 18px rgba(22, 38, 45, .07);
}

html {
  background: #fff5f5;
}

body {
  min-height: 100vh;
  background:
    radial-gradient(circle at 8% 0%, rgba(200, 30, 30, .16), transparent 30%),
    radial-gradient(circle at 98% 12%, rgba(229, 57, 53, .1), transparent 28%),
    linear-gradient(180deg, #fffafa 0%, #fff5f5 100%);
}

#app {
  position: relative;
  overflow-x: hidden;
  padding-bottom: calc(90px + env(safe-area-inset-bottom));
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .62), rgba(255, 245, 245, 0) 190px),
    var(--bg);
}

#app::before {
  position: fixed;
  top: 0;
  left: 50%;
  z-index: 0;
  width: min(430px, 100%);
  height: 210px;
  transform: translateX(-50%);
  background:
    linear-gradient(135deg, rgba(200, 30, 30, .16), rgba(229, 57, 53, .08)),
    linear-gradient(180deg, rgba(255, 255, 255, .42), rgba(255, 255, 255, 0));
  pointer-events: none;
  content: "";
}

#app > * {
  position: relative;
  z-index: 1;
}

.theme-bar {
  min-height: 60px;
  background: rgba(255, 255, 255, .78);
  border-bottom: 1px solid rgba(241, 210, 210, .76);
  box-shadow: 0 8px 26px rgba(19, 35, 42, .06);
}

.theme-bar h1 {
  color: #07141d;
  font-size: 20px;
  letter-spacing: 0;
}

.theme-bar button,
.back-button,
.rank-follow,
.follow-row button {
  background: rgba(255, 240, 240, .94);
  border-color: rgba(200, 30, 30, .18);
}

.banner {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .86);
  border-radius: 16px;
  box-shadow: 0 18px 40px rgba(12, 29, 38, .13);
}

.banner-item {
  height: 204px;
}

.banner-marquee {
  height: 42px;
  background: linear-gradient(90deg, rgba(153, 27, 27, .92), rgba(41, 20, 20, .66));
}

.banner-marquee p,
.banner-marquee span {
  height: 42px;
  line-height: 42px;
}

.article-tabs {
  top: 62px;
  padding: 5px;
  background: rgba(255, 235, 235, .78);
  border-radius: 14px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .72), 0 8px 22px rgba(22, 38, 45, .05);
}

.article-tabs button {
  height: 42px;
  border-radius: 11px;
}

.article-card,
.rank-card,
.follow-row,
.bill-row,
.team-row,
.profile-card,
.mine-menu,
.share-card,
.simple-form,
.paid-content,
.locked-content,
.article-head,
.history-row,
.empty-box,
.checkin-box,
.podium-item,
.rules-modal,
.login-modal {
  background: var(--surface-strong);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--soft-shadow);
}

.article-card {
  position: relative;
  grid-template-columns: 52px 1fr;
  padding: 15px;
  overflow: hidden;
}

.article-card::after {
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: linear-gradient(90deg, var(--brand), rgba(229, 57, 53, .78), rgba(255, 255, 255, .9));
  opacity: .72;
  content: "";
}

.article-card:active,
.rank-card:active,
.follow-row:active,
.bill-row:active,
.team-row:active,
.mine-menu button:active,
.checkin-box button:active,
.profile-card button:active {
  transform: translateY(1px) scale(.992);
}

.author-avatar,
.profile-avatar,
.podium-avatar,
.rank-no,
.chat-avatar {
  background:
    radial-gradient(circle at 28% 22%, rgba(255, 255, 255, .35), transparent 28%),
    linear-gradient(135deg, #c81e1e, #ef4444);
}

.article-price {
  min-width: 54px;
  text-align: center;
  background: linear-gradient(135deg, #e53935, #f87171);
  box-shadow: 0 8px 15px rgba(229, 57, 53, .18);
}

.article-meta span {
  color: var(--brand-strong);
}

.article-meta em {
  padding: 2px 7px;
  color: #526271;
  background: #fff5f5;
  border-radius: 999px;
}

.article-card h3 {
  color: #07141d;
  letter-spacing: 0;
}

.article-foot span,
.section-title span {
  color: #6b7b88;
}

.section-title {
  margin-top: 18px;
}

.section-title h2 {
  color: #07141d;
  letter-spacing: 0;
}

.rank-card {
  grid-template-columns: 42px minmax(0, 1fr) auto auto;
}

.rank-card b,
.profile-card b,
.bill-row b {
  color: var(--accent);
}

.rank-no.top-1,
.place-1 .podium-avatar {
  background: linear-gradient(135deg, #ffd66b, #c18424);
}

.rank-no.top-2,
.place-2 .podium-avatar {
  background: linear-gradient(135deg, #cbd5e1, #718096);
}

.rank-no.top-3,
.place-3 .podium-avatar {
  background: linear-gradient(135deg, #ef9a6a, #bf5b35);
}

.article-head {
  background:
    linear-gradient(135deg, rgba(200, 30, 30, .1), rgba(255, 255, 255, .94) 42%),
    #fff;
}

.statement-box {
  border-color: rgba(193, 132, 36, .2);
  box-shadow: 0 8px 20px rgba(193, 132, 36, .08);
}

.profile-card {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(200, 30, 30, .14), rgba(255, 255, 255, .96) 46%),
    linear-gradient(315deg, rgba(229, 57, 53, .08), rgba(255, 255, 255, 0) 48%),
    #fff;
}

.profile-card::after {
  position: absolute;
  right: -44px;
  top: -54px;
  width: 132px;
  height: 132px;
  border: 28px solid rgba(200, 30, 30, .08);
  border-radius: 50%;
  content: "";
}

.profile-card > * {
  position: relative;
  z-index: 1;
}

.profile-card button,
.simple-form button,
.share-link button,
.paid-content-head button,
.chat-input button,
.modal-close,
.checkin-box button,
.follow-button,
.lottery-draw-button {
  background: linear-gradient(135deg, var(--brand), var(--brand-strong));
  box-shadow: 0 9px 18px rgba(200, 30, 30, .2);
}

.checkin-box {
  padding: 14px;
  background:
    linear-gradient(135deg, rgba(255, 240, 240, .96), rgba(255, 255, 255, .95)),
    #fff;
}

.checkin-box strong {
  color: var(--brand-strong);
}

.mine-menu button {
  height: 54px;
  padding-left: 16px;
  padding-right: 16px;
}

.mine-menu button > span::before {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  margin-right: 2px;
  color: var(--brand);
  background: var(--brand-weak);
  border-radius: 10px;
  font-size: 14px;
  content: "•";
}

.mine-menu button:nth-child(1) > span::before { content: "¥"; color: var(--accent); background: #fff0ed; }
.mine-menu button:nth-child(2) > span::before { content: "✓"; color: var(--blue); background: #fff0f0; }
.mine-menu button:nth-child(3) > span::before { content: "+"; color: var(--brand); background: var(--brand-weak); }
.mine-menu button:nth-child(4) > span::before { content: "%"; color: var(--gold); background: #fff6df; }
.mine-menu button:nth-child(5) > span::before { content: "A"; color: var(--blue); background: #fff0f0; }
.mine-menu button:nth-child(6) > span::before { content: "!"; color: var(--accent); background: #fff0ed; }
.mine-menu button:nth-child(7) > span::before { content: "*"; color: var(--brand); background: var(--brand-weak); }
.mine-menu button:nth-child(8) > span::before { content: "↩"; color: #7d6f72; background: #fff5f5; }

.share-stats div,
.content-line b,
.lock-body,
.chat-input input,
.simple-form input,
.simple-form textarea {
  background: #fffafa;
  border-color: var(--line);
  border-radius: 12px;
}

.content-line b {
  min-width: 44px;
}

.lottery-wheel-wrap {
  margin-top: 10px;
}

.lottery-result {
  border: 1px solid rgba(200, 30, 30, .16);
  border-radius: 14px;
  box-shadow: var(--soft-shadow);
}

.service-section {
  height: calc(100vh - 102px);
}

.chat-input {
  bottom: calc(64px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, .9);
}

.bottom-nav {
  height: calc(68px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, .86);
  border-top: 1px solid rgba(241, 210, 210, .86);
  box-shadow: 0 -14px 30px rgba(20, 35, 44, .09);
}

.bottom-nav button {
  flex-direction: column;
  gap: 4px;
  font-size: 12px;
}

.bottom-nav button::before {
  display: block;
  width: 25px;
  height: 25px;
  color: currentColor;
  background: currentColor;
  border-radius: 0;
  content: "";
  -webkit-mask: var(--nav-icon) center / 23px 23px no-repeat;
  mask: var(--nav-icon) center / 23px 23px no-repeat;
}

.bottom-nav .nav-home {
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M4 11.2 12 4l8 7.2v7.9a1.9 1.9 0 0 1-1.9 1.9h-3.6v-6.2h-5V21H5.9A1.9 1.9 0 0 1 4 19.1v-7.9Z'/%3E%3C/svg%3E");
}

.bottom-nav .nav-rank {
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M6 19h12a1.5 1.5 0 0 1 0 3H6a1.5 1.5 0 0 1 0-3Zm1.5-7h9a1.5 1.5 0 0 1 1.5 1.5V18H6v-4.5A1.5 1.5 0 0 1 7.5 12Zm3-6h3A1.5 1.5 0 0 1 15 7.5V11H9V7.5A1.5 1.5 0 0 1 10.5 6Zm-6 7H6v5H3v-3.5A1.5 1.5 0 0 1 4.5 13Zm13.5 0h1.5a1.5 1.5 0 0 1 1.5 1.5V18h-3v-5Z'/%3E%3C/svg%3E");
}

.bottom-nav .nav-service {
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 3.5c-5 0-9 3.4-9 7.7 0 2.4 1.3 4.7 3.5 6.1l-.7 2.7a.8.8 0 0 0 1.2.9l3.1-1.8c.6.1 1.2.2 1.9.2 5 0 9-3.4 9-8.1 0-4.3-4-7.7-9-7.7Zm-4 8.7a1.3 1.3 0 1 1 0-2.6 1.3 1.3 0 0 1 0 2.6Zm4 0a1.3 1.3 0 1 1 0-2.6 1.3 1.3 0 0 1 0 2.6Zm4 0a1.3 1.3 0 1 1 0-2.6 1.3 1.3 0 0 1 0 2.6Z'/%3E%3C/svg%3E");
}

.bottom-nav .nav-mine {
  --nav-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 12.2a4.6 4.6 0 1 0 0-9.2 4.6 4.6 0 0 0 0 9.2Zm0 2.1c-4.6 0-8 2.4-8 5.1 0 1 .8 1.6 1.8 1.6h12.4c1 0 1.8-.6 1.8-1.6 0-2.7-3.4-5.1-8-5.1Z'/%3E%3C/svg%3E");
}

.bottom-nav button.active span {
  padding: 0;
  color: var(--brand-strong);
  background: transparent;
  box-shadow: none;
}

.bottom-nav button.active::before {
  color: var(--brand-strong);
  background: linear-gradient(135deg, var(--brand), var(--brand-strong));
  filter: drop-shadow(0 7px 12px rgba(200, 30, 30, .18));
}

.modal-mask,
.pretty-mask {
  background: rgba(10, 18, 25, .48);
}

@media (min-width: 431px) {
  #app {
    min-height: calc(100vh - 24px);
    margin-top: 12px;
    margin-bottom: 12px;
    border: 1px solid rgba(241, 210, 210, .86);
    border-radius: 22px;
    box-shadow: 0 22px 70px rgba(17, 31, 40, .13);
  }

  .theme-bar {
    border-radius: 22px 22px 0 0;
  }
}

/* Final override: compact rules dialog spacing */
.rules-modal {
  width: min(350px, calc(100vw - 28px)) !important;
  max-height: min(56dvh, 460px) !important;
}

.rules-modal-head {
  min-height: 40px !important;
  padding: 5px 10px !important;
}

.rules-modal-head strong {
  font-size: 16px !important;
}

.rules-close {
  width: 28px !important;
  height: 28px !important;
  font-size: 18px !important;
}

.rules-modal .rule-tip,
.rule-tip {
  margin: 7px 14px 5px !important;
  padding: 0 !important;
  font-size: 12px !important;
  line-height: 1.25 !important;
}

.rules-modal .rule-item,
.rule-item {
  margin: 0 14px 6px !important;
  padding: 0 !important;
  border-radius: 10px !important;
}

.rules-modal .rule-item button,
.rule-item button {
  min-height: 36px !important;
  height: 36px !important;
  padding: 0 12px !important;
  font-size: 15px !important;
  line-height: 1.1 !important;
}

.rules-modal .rule-item p,
.rule-item p {
  margin: 0 !important;
  padding: 0 12px 8px !important;
  font-size: 13px !important;
  line-height: 1.42 !important;
}

/* Final page background cleanup */
html,
body {
  background: #fff7f7 !important;
}

body {
  background-image: linear-gradient(180deg, #ffffff 0, #fff7f7 140px, #fff7f7 100%) !important;
}

#app {
  background: #fff7f7 !important;
}

#app::before {
  display: none !important;
}

.service-section,
.chat-box {
  background: #fff7f7 !important;
}

/* Final background cleanup */
html,
body {
  background: #fff7f7 !important;
}

body {
  background-image: linear-gradient(180deg, #ffffff 0, #fff7f7 140px, #fff7f7 100%) !important;
}

#app {
  background: #fff7f7 !important;
}

#app::before {
  display: none !important;
}

.service-section,
.chat-box {
  background: #fff7f7 !important;
}

/* Secondary pages need breathing room above the back button */
.article-detail,
.bill-section,
.follow-section,
.share-section,
.lottery-section,
.form-section {
  padding-top: 10px !important;
}

.back-button {
  margin-top: 4px !important;
  margin-bottom: 12px !important;
}

/* Slightly more comfortable top bar spacing */
.theme-bar {
  min-height: 58px !important;
  height: 58px !important;
  padding-top: 10px !important;
  padding-bottom: 8px !important;
}

.theme-bar h1 {
  line-height: 1.25 !important;
}

.banner {
  margin-top: 2px !important;
}

/* Fix banner marquee text overlap */
.banner-marquee {
  display: flex !important;
  align-items: center !important;
  height: 30px !important;
  overflow: hidden !important;
}

.banner-marquee p {
  display: flex !important;
  width: max-content !important;
  min-width: 200% !important;
  height: 30px !important;
  align-items: center !important;
  gap: 48px !important;
  margin: 0 !important;
  white-space: nowrap !important;
  animation: bannerMarquee 18s linear infinite !important;
}

.banner-marquee span {
  display: inline-flex !important;
  align-items: center !important;
  min-width: auto !important;
  max-width: none !important;
  height: 30px !important;
  padding: 0 !important;
  overflow: visible !important;
  font-size: 14px !important;
  line-height: 1.15 !important;
  transform: translateY(1px) !important;
  white-space: nowrap !important;
  flex: 0 0 auto !important;
}

/* Clean bottom navigation, remove desktop scrollbar arrows */
.bottom-nav {
  height: calc(66px + env(safe-area-inset-bottom)) !important;
  padding: 6px 10px calc(6px + env(safe-area-inset-bottom)) !important;
  gap: 6px !important;
  background: rgba(255, 255, 255, .98) !important;
  border-top: 1px solid rgba(241, 210, 210, .9) !important;
  box-shadow: 0 -8px 22px rgba(20, 35, 44, .06) !important;
}

.bottom-nav button {
  height: 54px !important;
  min-height: 54px !important;
  padding: 5px 0 4px !important;
  gap: 3px !important;
  color: #7b8993 !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 14px !important;
  box-shadow: none !important;
  appearance: none !important;
  -webkit-appearance: none !important;
}

.bottom-nav button::before {
  width: 22px !important;
  height: 22px !important;
  opacity: .9 !important;
}

.bottom-nav button span {
  display: block !important;
  height: auto !important;
  max-height: none !important;
  padding: 0 !important;
  overflow: hidden !important;
  color: inherit !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  font-size: 12px !important;
  font-weight: 800 !important;
  line-height: 1.2 !important;
  white-space: nowrap !important;
  scrollbar-width: none !important;
}

.bottom-nav button span::-webkit-scrollbar {
  display: none !important;
}

.bottom-nav button.active {
  color: var(--brand-strong) !important;
  background: linear-gradient(180deg, #effaf6, #ffffff) !important;
  border: 1px solid rgba(200, 30, 30, .12) !important;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .7) !important;
}

.bottom-nav button.active::after {
  top: 5px !important;
  width: 20px !important;
  height: 3px !important;
  background: var(--brand-strong) !important;
  border-radius: 999px !important;
}

.bottom-nav button.active::before {
  filter: none !important;
}

/* Final compact rules dialog spacing */
.rules-modal {
  max-height: min(58dvh, 480px) !important;
}

.rules-modal-head {
  min-height: 40px !important;
  padding: 5px 10px !important;
}

.rules-modal-head strong {
  font-size: 16px !important;
}

.rules-close {
  width: 28px !important;
  height: 28px !important;
}

.rules-modal .rule-tip,
.rule-tip {
  margin: 8px 14px 4px !important;
  padding: 0 !important;
  font-size: 12px !important;
  line-height: 1.25 !important;
  text-align: center !important;
}

.rules-modal .rule-item,
.rule-item {
  margin: 0 14px 6px !important;
  padding: 0 !important;
  border-radius: 10px !important;
}

.rules-modal .rule-item button,
.rule-item button {
  min-height: 36px !important;
  height: 36px !important;
  padding: 0 12px !important;
  font-size: 15px !important;
  line-height: 1.1 !important;
}

.rules-modal .rule-item p,
.rule-item p {
  margin: 0 !important;
  padding: 0 12px 9px !important;
  font-size: 13px !important;
  line-height: 1.45 !important;
}

/* Compact rules modal */
.rules-modal {
  width: min(360px, calc(100vw - 28px)) !important;
  max-height: min(64dvh, 520px) !important;
}

.rules-modal-head {
  min-height: 44px !important;
  padding: 6px 10px !important;
}

.rules-modal-head strong {
  font-size: 16px !important;
}

.rules-close {
  width: 28px !important;
  height: 28px !important;
  font-size: 19px !important;
}

.rule-tip {
  margin: 8px 14px 6px !important;
  font-size: 12px !important;
  line-height: 1.35 !important;
}

.rule-item {
  margin: 0 14px 8px !important;
  border-radius: 10px !important;
}

.rules-modal .rule-item button {
  min-height: 38px !important;
  padding: 0 11px !important;
  font-size: 14px !important;
}

.rules-modal .rule-item p {
  margin: 0 !important;
  padding: 0 11px 10px !important;
  font-size: 13px !important;
  line-height: 1.55 !important;
}

@media (max-width: 360px) {
  .banner-item {
    height: 176px;
  }

  .article-card {
    grid-template-columns: 46px 1fr;
  }

  .article-price {
    min-width: 48px;
    padding-left: 6px;
    padding-right: 6px;
  }

  .rank-card {
    grid-template-columns: 38px minmax(0, 1fr) auto;
  }

  .rank-card .rank-follow {
    grid-column: 2 / -1;
    justify-self: start;
  }
}

/* Mobile overflow guard */
html,
body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

#app {
  width: 100%;
  max-width: 430px;
  overflow-x: hidden;
}

#app *,
#app *::before,
#app *::after {
  max-width: 100%;
}

img,
video,
canvas {
  max-width: 100%;
}

.bottom-nav,
.chat-input {
  left: 50%;
  right: auto;
  width: min(430px, 100vw);
  max-width: 100vw !important;
  margin-right: 0;
  margin-left: 0;
  transform: translateX(-50%);
}

.article-info,
.rank-main,
.history-main,
.profile-card > div,
.bill-row > div,
.team-row > div,
.follow-row > div,
.share-link span,
.chat-row > div:last-child {
  min-width: 0;
}

.rank-card {
  grid-template-columns: 42px minmax(0, 1fr) auto;
}

.rank-card .rank-follow {
  grid-column: 2 / -1;
  justify-self: start;
}

.follow-row {
  grid-template-columns: 46px minmax(0, 1fr) auto;
}

.bill-row {
  grid-template-columns: minmax(0, 1fr) auto;
}

.share-link {
  grid-template-columns: minmax(0, 1fr) auto;
}

.share-link span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.article-card h3,
.rank-main strong,
.follow-row strong,
.bill-row strong,
.team-row strong {
  overflow-wrap: anywhere;
}

@media (max-width: 390px) {
  .podium {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .podium-item {
    padding-right: 6px;
    padding-left: 6px;
  }

  .rank-card {
    gap: 9px;
  }

  .chat-input {
    grid-template-columns: 46px 46px minmax(0, 1fr) 58px;
  }
}

/* Modal overflow guard */
.modal-mask,
.pretty-mask {
  left: 0;
  right: 0;
  width: 100%;
  max-width: none !important;
  overflow-x: hidden;
  padding: 14px;
}

.login-modal,
.rules-modal,
.pretty-dialog {
  width: calc(100vw - 28px);
  max-width: 360px;
  max-height: calc(100dvh - 28px);
  overflow-x: hidden;
  overflow-y: auto;
}

.rules-modal {
  max-width: 430px;
}

.pretty-dialog {
  max-width: 330px;
}

.login-modal *,
.rules-modal *,
.pretty-dialog * {
  min-width: 0;
}

.pin-keypad {
  grid-template-columns: repeat(3, minmax(0, 62px));
  gap: 11px clamp(10px, 4vw, 18px);
}

.pin-keypad button {
  width: clamp(54px, 16vw, 62px);
  height: clamp(54px, 16vw, 62px);
}

.pin-hint,
.rule-item button span,
.rule-item p,
.pretty-dialog h3,
.pretty-dialog p {
  overflow-wrap: anywhere;
}

.pretty-actions {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 340px) {
  .modal-mask,
  .pretty-mask {
    padding: 10px;
  }

  .login-modal,
  .rules-modal,
  .pretty-dialog {
    width: calc(100vw - 20px);
    max-height: calc(100dvh - 20px);
  }

  .pin-keypad {
    grid-template-columns: repeat(3, minmax(0, 56px));
    gap: 10px;
  }

  .pin-keypad button {
    width: 56px;
    height: 56px;
  }
}

/* Fixed layer final override: keep nav and modals in viewport */
.bottom-nav {
  position: fixed !important;
  left: 50% !important;
  right: auto !important;
  bottom: 0 !important;
  z-index: 80 !important;
  width: min(430px, 100vw) !important;
  max-width: 100vw !important;
  margin: 0 !important;
  transform: translateX(-50%) !important;
}

.chat-input {
  position: fixed !important;
  left: 50% !important;
  right: auto !important;
  bottom: calc(68px + env(safe-area-inset-bottom)) !important;
  z-index: 79 !important;
  width: min(430px, 100vw) !important;
  max-width: 100vw !important;
  margin: 0 !important;
  transform: translateX(-50%) !important;
}

.modal-mask,
.pretty-mask {
  position: fixed !important;
  inset: 0 !important;
  z-index: 120 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 100vw !important;
  height: 100dvh !important;
  max-width: 100vw !important;
  max-height: 100dvh !important;
  margin: 0 !important;
  padding: 14px !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  transform: none !important;
  box-sizing: border-box !important;
}

.login-modal,
.rules-modal,
.pretty-dialog {
  flex: 0 1 auto !important;
  width: min(360px, calc(100vw - 28px)) !important;
  max-width: calc(100vw - 28px) !important;
  max-height: calc(100dvh - 28px) !important;
  margin: auto !important;
  box-sizing: border-box !important;
}

.rules-modal {
  width: min(430px, calc(100vw - 28px)) !important;
}

.pretty-dialog {
  width: min(330px, calc(100vw - 28px)) !important;
}

/* Final visual normalization */
.bottom-nav {
  display: grid !important;
  grid-auto-flow: column !important;
  grid-auto-columns: minmax(0, 1fr) !important;
  align-items: stretch !important;
  height: calc(72px + env(safe-area-inset-bottom)) !important;
  padding: 7px 8px calc(7px + env(safe-area-inset-bottom)) !important;
  background: rgba(255, 255, 255, .96) !important;
  border-top: 1px solid rgba(241, 210, 210, .95) !important;
  box-shadow: 0 -12px 28px rgba(19, 35, 42, .1) !important;
  backdrop-filter: blur(18px) !important;
}

.bottom-nav button {
  position: relative !important;
  display: flex !important;
  min-width: 0 !important;
  height: 100% !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 4px !important;
  padding: 0 !important;
  color: #778692 !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 12px !important;
  box-shadow: none !important;
  font-size: 12px !important;
  font-weight: 800 !important;
  line-height: 1.1 !important;
}

.bottom-nav button::before {
  width: 23px !important;
  height: 23px !important;
  background: currentColor !important;
  filter: none !important;
  opacity: .95 !important;
}

.bottom-nav button span {
  display: block !important;
  max-width: 100% !important;
  padding: 0 !important;
  overflow: visible !important;
  color: inherit !important;
  background: transparent !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.bottom-nav button.active {
  color: var(--brand-strong) !important;
  background: linear-gradient(180deg, rgba(255, 240, 240, .94), rgba(255, 255, 255, .76)) !important;
}

.bottom-nav button.active::after {
  position: absolute;
  top: 5px;
  left: 50%;
  width: 18px;
  height: 3px;
  transform: translateX(-50%);
  background: var(--brand);
  border-radius: 999px;
  content: "";
}

.bottom-nav .nav-unread-dot {
  position: absolute !important;
  top: -3px !important;
  right: -10px !important;
  left: auto !important;
  z-index: 2 !important;
  display: block !important;
  width: 9px !important;
  height: 9px !important;
  margin: 0 !important;
  background: #ef3b2d !important;
  border: 1px solid #fff !important;
  border-radius: 50% !important;
  box-shadow: 0 0 0 2px rgba(239, 59, 45, .18) !important;
  pointer-events: none !important;
}

.modal-mask,
.pretty-mask {
  align-items: center !important;
  justify-content: center !important;
  padding: max(14px, env(safe-area-inset-top)) 14px max(14px, env(safe-area-inset-bottom)) !important;
  background: rgba(9, 18, 24, .5) !important;
  backdrop-filter: blur(8px) !important;
}

.login-modal,
.rules-modal,
.pretty-dialog {
  border: 1px solid rgba(241, 210, 210, .95) !important;
  border-radius: 18px !important;
  background: #fff !important;
  box-shadow: 0 22px 58px rgba(10, 24, 32, .24) !important;
}

.login-modal {
  gap: 14px !important;
  padding: 22px 18px 18px !important;
}

.login-modal h2,
.pretty-dialog h3 {
  color: #07141d !important;
  font-weight: 950 !important;
  letter-spacing: 0 !important;
}

.pin-dots {
  gap: 12px !important;
  margin: 6px 0 14px !important;
}

.pin-dots i {
  width: 10px !important;
  height: 10px !important;
  border-color: #a9b7c0 !important;
}

.pin-dots i.active {
  background: var(--brand) !important;
  border-color: var(--brand) !important;
}

.pin-keypad {
  grid-template-columns: repeat(3, minmax(0, 60px)) !important;
  justify-content: center !important;
  gap: 12px 18px !important;
}

.pin-keypad button {
  width: 60px !important;
  height: 60px !important;
  color: #101923 !important;
  background: #f8fbf9 !important;
  border: 1px solid rgba(241, 210, 210, .95) !important;
  border-radius: 50% !important;
  box-shadow: 0 7px 16px rgba(17, 31, 40, .07) !important;
}

.pin-keypad button:active,
.bottom-nav button:active {
  transform: scale(.97) !important;
}

.rules-modal {
  padding: 18px !important;
}

.rule-item button {
  gap: 12px !important;
}

.pretty-dialog {
  padding: 24px 18px 18px !important;
}

.pretty-icon {
  box-shadow: 0 8px 18px rgba(200, 30, 30, .2) !important;
}

@media (max-width: 340px) {
  .bottom-nav {
    padding-right: 6px !important;
    padding-left: 6px !important;
  }

  .bottom-nav button {
    font-size: 11px !important;
  }

  .bottom-nav button::before {
    width: 21px !important;
    height: 21px !important;
  }

  .pin-keypad {
    grid-template-columns: repeat(3, minmax(0, 56px)) !important;
    gap: 10px 14px !important;
  }

  .pin-keypad button {
    width: 56px !important;
    height: 56px !important;
  }
}

/* Header and follow button final polish */
.theme-bar {
  position: sticky !important;
  top: 0 !important;
  z-index: 70 !important;
  display: grid !important;
  grid-template-columns: 72px minmax(0, 1fr) 72px !important;
  align-items: center !important;
  min-height: 58px !important;
  margin: -12px -14px 14px !important;
  padding: 8px 14px !important;
  background: rgba(255, 255, 255, .94) !important;
  border-bottom: 1px solid rgba(241, 210, 210, .9) !important;
  border-radius: 0 !important;
  box-shadow: 0 8px 22px rgba(17, 31, 40, .06) !important;
  backdrop-filter: blur(18px) !important;
}

.theme-bar::before {
  width: 34px;
  height: 34px;
  background:
    radial-gradient(circle at 32% 28%, rgba(255, 255, 255, .42), transparent 32%),
    linear-gradient(135deg, var(--brand), var(--brand-strong));
  border-radius: 12px;
  box-shadow: 0 7px 14px rgba(200, 30, 30, .18);
  content: "";
}

.theme-bar h1 {
  min-width: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  color: #07141d !important;
  font-size: 18px !important;
  font-weight: 950 !important;
  line-height: 1.2 !important;
  text-align: center !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.theme-bar button {
  position: static !important;
  justify-self: end !important;
  min-width: 0 !important;
  width: auto !important;
  height: 34px !important;
  padding: 0 12px !important;
  color: var(--brand-strong) !important;
  background: #fff0f0 !important;
  border: 1px solid rgba(200, 30, 30, .16) !important;
  border-radius: 999px !important;
  box-shadow: none !important;
  font-size: 13px !important;
  font-weight: 900 !important;
  line-height: 34px !important;
}

.theme-bar button:active {
  transform: scale(.97) !important;
}

.article-author-line {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto !important;
  align-items: center !important;
  gap: 10px !important;
  margin-bottom: 10px !important;
}

.article-author-line span {
  min-width: 0 !important;
  overflow: hidden !important;
  color: #526271 !important;
  font-size: 13px !important;
  font-weight: 800 !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.follow-button,
.rank-follow,
.follow-row button {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-width: 58px !important;
  height: 30px !important;
  margin: 0 !important;
  padding: 0 11px !important;
  color: var(--brand-strong) !important;
  background: #edf7f2 !important;
  border: 1px solid rgba(200, 30, 30, .18) !important;
  border-radius: 999px !important;
  box-shadow: none !important;
  font-size: 12px !important;
  font-weight: 900 !important;
  line-height: 1 !important;
  white-space: nowrap !important;
}

.follow-button::before,
.rank-follow::before,
.follow-row button::before {
  width: 6px;
  height: 6px;
  margin-right: 5px;
  background: currentColor;
  border-radius: 50%;
  content: "";
}

.follow-button:active,
.rank-follow:active,
.follow-row button:active {
  transform: scale(.96) !important;
}

.rank-card .rank-follow {
  grid-column: auto !important;
  justify-self: end !important;
}

.podium-item .rank-follow {
  margin-top: 8px !important;
}

@media (max-width: 360px) {
  .theme-bar {
    grid-template-columns: 54px minmax(0, 1fr) 58px !important;
    margin-right: -10px !important;
    margin-left: -10px !important;
    padding-right: 10px !important;
    padding-left: 10px !important;
  }

  .theme-bar::before {
    width: 30px;
    height: 30px;
    border-radius: 10px;
  }

  .theme-bar h1 {
    font-size: 17px !important;
  }

  .theme-bar button {
    height: 32px !important;
    padding: 0 10px !important;
    font-size: 12px !important;
    line-height: 32px !important;
  }

  .rank-card {
    grid-template-columns: 38px minmax(0, 1fr) auto !important;
  }

  .rank-card .rank-follow {
    grid-column: 3 !important;
  }
}

/* Header and rank follow layout correction */
.theme-bar {
  grid-template-columns: 64px minmax(0, 1fr) 64px !important;
  min-height: 58px !important;
  margin: -12px -14px 18px !important;
  padding: 9px 14px !important;
  background: rgba(255, 255, 255, .9) !important;
  border-bottom: 1px solid rgba(241, 210, 210, .88) !important;
  box-shadow: 0 8px 22px rgba(17, 31, 40, .05) !important;
}

.theme-bar::before {
  display: none !important;
  content: none !important;
}

.theme-bar h1 {
  grid-column: 2 !important;
  justify-self: center !important;
  font-size: 18px !important;
}

.theme-bar button {
  grid-column: 3 !important;
  height: 34px !important;
  padding: 0 12px !important;
}

.rank-card {
  grid-template-columns: 50px minmax(0, 1fr) auto !important;
  grid-template-areas:
    "no main score"
    "no follow score" !important;
  align-items: center !important;
  row-gap: 8px !important;
}

.rank-card .rank-no {
  grid-area: no !important;
}

.rank-card .rank-main {
  grid-area: main !important;
}

.rank-card > b {
  grid-area: score !important;
  align-self: center !important;
  justify-self: end !important;
  white-space: nowrap !important;
}

.rank-card .rank-follow {
  grid-area: follow !important;
  justify-self: start !important;
  min-width: 62px !important;
}

.bottom-nav button {
  outline: none !important;
  -webkit-tap-highlight-color: transparent !important;
}

.bottom-nav button.active {
  border: 0 !important;
  outline: none !important;
  box-shadow: inset 0 0 0 1px rgba(200, 30, 30, .1) !important;
}

@media (max-width: 360px) {
  .theme-bar {
    grid-template-columns: 58px minmax(0, 1fr) 58px !important;
    margin-right: -10px !important;
    margin-left: -10px !important;
  }

  .rank-card {
    grid-template-columns: 44px minmax(0, 1fr) auto !important;
  }
}

/* Header and rank row alignment correction */
.theme-bar {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 60px !important;
  margin: -12px -14px 20px !important;
  padding: 10px 14px !important;
  background: rgba(255, 255, 255, .92) !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(241, 210, 210, .88) !important;
  border-radius: 0 !important;
  box-shadow: 0 8px 22px rgba(17, 31, 40, .05) !important;
}

.theme-bar h1 {
  position: static !important;
  flex: 1 1 auto !important;
  min-width: 0 !important;
  padding-left: 58px !important;
  overflow: hidden !important;
  text-align: center !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.theme-bar button {
  position: static !important;
  flex: 0 0 auto !important;
  margin-left: 12px !important;
}

.rank-card {
  grid-template-columns: 50px minmax(0, 1fr) auto auto !important;
  grid-template-areas: "no main score follow" !important;
  min-height: 116px !important;
  align-items: center !important;
  column-gap: 14px !important;
  row-gap: 0 !important;
}

.rank-card .rank-no {
  grid-area: no !important;
}

.rank-card .rank-main {
  grid-area: main !important;
}

.rank-card > b {
  grid-area: score !important;
}

.rank-card .rank-follow {
  grid-area: follow !important;
}

.rank-card > b,
.rank-card .rank-follow {
  align-self: center !important;
}

.rank-card > b {
  justify-self: end !important;
  white-space: nowrap !important;
}

.rank-card .rank-follow {
  justify-self: end !important;
  min-width: 62px !important;
  margin-left: 8px !important;
}

@media (max-width: 390px) {
  .rank-card {
    grid-template-columns: 44px minmax(0, 1fr) auto auto !important;
    column-gap: 8px !important;
  }

  .rank-card > b {
    font-size: 16px !important;
  }

  .rank-card .rank-follow {
    min-width: 56px !important;
    height: 28px !important;
    padding: 0 9px !important;
    margin-left: 0 !important;
  }
}

@media (max-width: 340px) {
  .theme-bar h1 {
    padding-left: 50px !important;
    font-size: 17px !important;
  }

  .theme-bar button {
    padding: 0 10px !important;
  }

  .rank-card {
    grid-template-columns: 40px minmax(0, 1fr) auto auto !important;
    grid-template-areas: "no main score follow" !important;
  }
}

/* Header full-width and compact lower rank cards */
.theme-bar {
  width: calc(100% + 28px) !important;
  max-width: none !important;
  margin: -12px -14px 20px !important;
}

.rank-card {
  min-height: 84px !important;
  margin-bottom: 12px !important;
  padding: 14px 16px !important;
  grid-template-columns: 48px minmax(0, 1fr) auto auto !important;
  column-gap: 10px !important;
}

.rank-card .rank-no {
  width: 46px !important;
  height: 46px !important;
}

.rank-card .rank-main strong {
  margin-bottom: 0 !important;
  font-size: 17px !important;
  line-height: 1.25 !important;
}

.rank-card > b {
  font-size: 18px !important;
  line-height: 1 !important;
}

.rank-card .rank-follow {
  height: 30px !important;
  min-width: 64px !important;
  padding: 0 10px !important;
  margin-left: 8px !important;
}

@media (max-width: 360px) {
  .theme-bar {
    width: calc(100% + 20px) !important;
    max-width: none !important;
    margin-right: -10px !important;
    margin-left: -10px !important;
  }

  .rank-card {
    min-height: 78px !important;
    padding: 12px 14px !important;
    grid-template-columns: 42px minmax(0, 1fr) auto auto !important;
    column-gap: 7px !important;
  }

  .rank-card .rank-no {
    width: 40px !important;
    height: 40px !important;
  }

  .rank-card > b {
    font-size: 15px !important;
  }

  .rank-card .rank-follow {
    min-width: 56px !important;
    height: 28px !important;
    padding: 0 8px !important;
    margin-left: 0 !important;
  }
}

/* Clean app header */
.theme-bar {
  width: calc(100% + 28px) !important;
  max-width: none !important;
  min-height: 64px !important;
  margin: -12px -14px 18px !important;
  padding: 10px 16px !important;
  background:
    linear-gradient(135deg, #c81e1e 0%, #e53935 54%, #991b1b 100%) !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: 0 10px 24px rgba(200, 30, 30, .18) !important;
}

.theme-bar h1 {
  color: #fff !important;
  padding-left: 62px !important;
  font-size: 19px !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, .12) !important;
}

.theme-bar button {
  height: 34px !important;
  padding: 0 13px !important;
  color: #991b1b !important;
  background: rgba(255, 255, 255, .92) !important;
  border: 1px solid rgba(255, 255, 255, .78) !important;
  border-radius: 999px !important;
  box-shadow: 0 6px 14px rgba(0, 0, 0, .08) !important;
}

@media (max-width: 360px) {
  .theme-bar {
    width: calc(100% + 20px) !important;
    margin-right: -10px !important;
    margin-left: -10px !important;
    padding-right: 12px !important;
    padding-left: 12px !important;
  }

  .theme-bar h1 {
    padding-left: 54px !important;
    font-size: 18px !important;
  }
}

/* Clean simple header, no heavy background */
.theme-bar {
  width: calc(100% + 28px) !important;
  max-width: none !important;
  min-height: 56px !important;
  margin: -12px -14px 12px !important;
  padding: 8px 14px !important;
  background: rgba(255, 255, 255, .92) !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(241, 210, 210, .9) !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  backdrop-filter: blur(14px) !important;
}

.theme-bar h1 {
  color: #07141d !important;
  padding-left: 56px !important;
  font-size: 18px !important;
  font-weight: 950 !important;
  text-shadow: none !important;
}

.theme-bar button {
  height: 32px !important;
  padding: 0 12px !important;
  color: var(--brand-strong) !important;
  background: #edf7f2 !important;
  border: 1px solid rgba(200, 30, 30, .16) !important;
  border-radius: 999px !important;
  box-shadow: none !important;
}

.banner {
  margin-top: 12px !important;
}

@media (max-width: 360px) {
  .theme-bar {
    width: calc(100% + 20px) !important;
    margin-right: -10px !important;
    margin-left: -10px !important;
    padding-right: 10px !important;
    padding-left: 10px !important;
  }

  .theme-bar h1 {
    padding-left: 50px !important;
    font-size: 17px !important;
  }
}

/* Full-bleed top header */
.theme-bar {
  left: 50% !important;
  width: min(430px, 100vw) !important;
  max-width: 100vw !important;
  margin: -12px 0 12px !important;
  transform: translateX(-50%) !important;
  border-radius: 0 !important;
}

@media (min-width: 431px) {
  #app {
    border-top-left-radius: 0 !important;
    border-top-right-radius: 0 !important;
  }

  .theme-bar {
    width: min(430px, 100vw) !important;
    margin-top: -12px !important;
  }
}

@media (max-width: 430px) {
  .theme-bar {
    width: 100vw !important;
  }
}

/* Fix sticky header offset: fill app width without horizontal transform */
.theme-bar {
  left: auto !important;
  right: auto !important;
  width: calc(100% + 28px) !important;
  max-width: none !important;
  margin: -12px -14px 12px !important;
  transform: none !important;
}

@media (max-width: 360px) {
  .theme-bar {
    width: calc(100% + 20px) !important;
    margin-right: -10px !important;
    margin-left: -10px !important;
  }
}

/* Remove stray strip above header */
#app {
  padding-top: 0 !important;
}

.theme-bar {
  margin-top: 0 !important;
}

/* True mobile full-width shell */
html,
body {
  margin: 0 !important;
  padding: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
  overflow-x: hidden !important;
  overscroll-behavior-x: none !important;
}

#app {
  width: 100vw !important;
  max-width: none !important;
  min-height: 100vh !important;
  margin: 0 !important;
  padding-top: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}

.theme-bar {
  position: sticky !important;
  top: 0 !important;
  left: auto !important;
  right: auto !important;
  width: 100vw !important;
  max-width: 100vw !important;
  margin: 0 0 12px calc(50% - 50vw) !important;
  padding: 8px max(14px, env(safe-area-inset-right)) 8px max(14px, env(safe-area-inset-left)) !important;
  transform: none !important;
  box-sizing: border-box !important;
}

.bottom-nav,
.chat-input {
  width: 100vw !important;
  max-width: 100vw !important;
}

/* Floating rules launcher */
.theme-bar h1 {
  padding-left: 0 !important;
}

.rules-float {
  position: fixed;
  right: 14px;
  top: calc(70px + env(safe-area-inset-top));
  z-index: 75;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px;
  background: rgba(255, 255, 255, .94);
  border: 1px solid rgba(241, 210, 210, .92);
  border-radius: 999px;
  box-shadow: 0 12px 26px rgba(17, 31, 40, .13);
  backdrop-filter: blur(14px);
}

.rules-float-main,
.rules-float-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  font-weight: 900;
}

.rules-float-main {
  height: 32px;
  padding: 0 12px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-strong));
  border-radius: 999px;
  font-size: 13px;
}

.rules-float-close {
  width: 28px;
  height: 28px;
  padding: 0;
  color: #657583;
  background: #fff5f5;
  border-radius: 50%;
  font-size: 18px;
  line-height: 1;
}

.rules-float button:active {
  transform: scale(.96);
}

.rules-float::after {
  position: absolute;
  right: 18px;
  bottom: -6px;
  width: 12px;
  height: 12px;
  transform: rotate(45deg);
  background: rgba(255, 255, 255, .94);
  border-right: 1px solid rgba(241, 210, 210, .92);
  border-bottom: 1px solid rgba(241, 210, 210, .92);
  content: "";
}

.rules-float {
  cursor: grab;
  user-select: none;
}

.rules-float:active {
  cursor: grabbing;
}

.rules-float-main {
  position: relative;
  z-index: 1;
}

.rules-float-close {
  position: relative;
  z-index: 1;
}

@media (max-width: 360px) {
  .rules-float {
    right: 10px;
    top: calc(66px + env(safe-area-inset-top));
  }
}

/* Rules floating panel and swipe-friendly secondary pages */
.rules-modal {
  position: relative !important;
  width: min(388px, calc(100vw - 28px)) !important;
  max-height: min(72dvh, 620px) !important;
  padding: 0 !important;
  overflow: hidden !important;
  background: rgba(255, 255, 255, .98) !important;
  border: 1px solid rgba(241, 210, 210, .95) !important;
  border-radius: 18px !important;
  box-shadow: 0 24px 64px rgba(10, 24, 32, .24) !important;
}

.rules-modal-head {
  position: sticky;
  top: 0;
  z-index: 1;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) 36px;
  align-items: center;
  min-height: 52px;
  padding: 8px 12px;
  background: #fff;
  border-bottom: 1px solid rgba(241, 210, 210, .9);
}

.rules-modal-head strong {
  grid-column: 2;
  justify-self: center;
  color: #07141d;
  font-size: 17px;
  font-weight: 950;
}

.rules-close {
  grid-column: 3;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 32px !important;
  height: 32px !important;
  padding: 0 !important;
  color: #657583 !important;
  background: #fff5f5 !important;
  border: 1px solid rgba(241, 210, 210, .95) !important;
  border-radius: 50% !important;
  box-shadow: none !important;
  font-size: 22px !important;
  font-weight: 500 !important;
  line-height: 1 !important;
}

.rule-tip,
.rule-item {
  margin-right: 16px !important;
  margin-left: 16px !important;
}

.rule-tip {
  margin-top: 14px !important;
}

.rule-item:last-child {
  margin-bottom: 14px !important;
}

.rules-modal .rule-item button {
  min-height: 44px !important;
}

.rules-modal .rule-item p {
  padding-bottom: 4px !important;
}

@media (max-width: 340px) {
  .rules-modal {
    width: calc(100vw - 20px) !important;
  }

  .rule-tip,
  .rule-item {
    margin-right: 12px !important;
    margin-left: 12px !important;
  }
}

/* Colorful translucent rules bubble and tighter top spacing */
.theme-bar {
  margin-bottom: 4px !important;
}

.rank-section,
.article-section {
  padding-top: 6px !important;
}

.rank-section .section-title,
.article-section .section-title {
  margin-top: 10px !important;
}

.rules-float {
  position: fixed !important;
  z-index: 9999 !important;
  width: 62px !important;
  height: 62px !important;
  display: grid !important;
  place-items: center !important;
  padding: 0 !important;
  touch-action: none !important;
  overflow: visible !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
}

.rules-float::after {
  display: none !important;
}

.rules-float-main {
  position: relative !important;
  z-index: 10000 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 58px !important;
  height: 58px !important;
  padding: 0 !important;
  color: #fff !important;
  background:
    radial-gradient(circle at 28% 24%, rgba(255, 255, 255, .92) 0 6px, rgba(255, 255, 255, .36) 7px 14px, transparent 15px),
    radial-gradient(circle at 78% 78%, rgba(255, 222, 118, .58), transparent 32%),
    linear-gradient(135deg, rgba(200, 30, 30, .88), rgba(229, 57, 53, .82) 48%, rgba(255, 255, 255, .78)) !important;
  border: 1px solid rgba(255, 255, 255, .72) !important;
  border-radius: 50% !important;
  box-shadow:
    inset 0 1px 10px rgba(255, 255, 255, .38),
    inset 0 -10px 18px rgba(120, 38, 38, .16),
    0 12px 26px rgba(200, 30, 30, .22) !important;
  backdrop-filter: blur(8px) saturate(1.25) !important;
  font-size: 13px !important;
  font-weight: 950 !important;
  line-height: 1 !important;
  text-shadow: 0 1px 2px rgba(36, 48, 70, .2) !important;
}

.rules-float-main::before {
  position: absolute;
  inset: 6px 8px auto;
  height: 15px;
  transform: rotate(-18deg);
  background: linear-gradient(180deg, rgba(255, 255, 255, .6), rgba(255, 255, 255, 0));
  border-radius: 50%;
  content: "";
}

.rules-float-main::after {
  display: none !important;
}

.rules-float-close {
  position: absolute !important;
  top: -9px !important;
  right: -7px !important;
  z-index: 10001 !important;
  width: 22px !important;
  height: 22px !important;
  color: #fff !important;
  background: rgba(112, 122, 132, .72) !important;
  border: 1px solid rgba(255, 255, 255, .72) !important;
  border-radius: 50% !important;
  box-shadow: 0 4px 10px rgba(20, 32, 40, .18) !important;
  font-size: 16px !important;
  font-weight: 700 !important;
}

@media (max-width: 360px) {
  .theme-bar {
    margin-bottom: 2px !important;
  }

  .rank-section,
  .article-section {
    padding-top: 4px !important;
  }

  .rank-section .section-title,
  .article-section .section-title {
    margin-top: 8px !important;
  }
}

/* Final compact top spacing */
.theme-bar {
  min-height: 52px !important;
  height: 52px !important;
  margin-bottom: 0 !important;
  padding-top: 6px !important;
  padding-bottom: 6px !important;
}

.banner {
  margin-top: 12px !important;
}

.rank-section,
.article-section {
  padding-top: 0 !important;
}

.rank-section .section-title {
  margin-top: 8px !important;
  margin-bottom: 10px !important;
}

.article-section .section-title {
  margin-top: 8px !important;
}

.article-tabs {
  margin-top: 8px !important;
}

@media (max-width: 360px) {
  .theme-bar {
    min-height: 50px !important;
    height: 50px !important;
  }

  .rank-section .section-title,
  .article-section .section-title {
    margin-top: 6px !important;
  }

  .article-tabs {
    margin-top: 6px !important;
  }
}

/* Desktop uses the same phone-sized layout as mobile */
@media (min-width: 431px) {
  html,
  body {
    background: #fff5f5 !important;
  }

  #app {
    width: 430px !important;
    max-width: 430px !important;
    margin: 0 auto !important;
    overflow-x: hidden !important;
    box-shadow: 0 0 0 1px rgba(241, 210, 210, .86) !important;
  }

  .theme-bar {
    width: 430px !important;
    max-width: 430px !important;
    margin-left: calc(50% - 215px) !important;
    margin-right: 0 !important;
  }

  .bottom-nav,
  .chat-input {
    left: 50% !important;
    width: 430px !important;
    max-width: 430px !important;
    transform: translateX(-50%) !important;
  }

  .modal-mask,
  .pretty-mask {
    left: 50% !important;
    width: 430px !important;
    max-width: 430px !important;
    transform: translateX(-50%) !important;
  }
}

/* Final override: compact rules dialog spacing */
.rules-modal {
  width: min(350px, calc(100vw - 28px)) !important;
  max-height: min(56dvh, 460px) !important;
}

.rules-modal-head {
  min-height: 40px !important;
  padding: 5px 10px !important;
}

.rules-modal-head strong {
  font-size: 16px !important;
}

.rules-close {
  width: 28px !important;
  height: 28px !important;
  font-size: 18px !important;
}

.rules-modal .rule-tip,
.rule-tip {
  margin: 7px 14px 5px !important;
  padding: 0 !important;
  font-size: 12px !important;
  line-height: 1.25 !important;
}

.rules-modal .rule-item,
.rule-item {
  margin: 0 14px 6px !important;
  padding: 0 !important;
  border-radius: 10px !important;
}

.rules-modal .rule-item button,
.rule-item button {
  min-height: 36px !important;
  height: 36px !important;
  padding: 0 12px !important;
  font-size: 15px !important;
  line-height: 1.1 !important;
}

.rules-modal .rule-item p,
.rule-item p {
  margin: 0 !important;
  padding: 0 12px 8px !important;
  font-size: 13px !important;
  line-height: 1.42 !important;
}

/* Final page background cleanup */
html,
body {
  background: #fff7f7 !important;
}

body {
  background-image: linear-gradient(180deg, #ffffff 0, #fff7f7 140px, #fff7f7 100%) !important;
}

#app {
  background: #fff7f7 !important;
}

#app::before {
  display: none !important;
}

.service-section,
.chat-box {
  background: #fff7f7 !important;
}
