:root {
  --blue: #007aff;
  --ink: #3a3a3c;
  --gray: #9b9ba1;
  --line: #ececef;
  --gold: #f5b400;
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  background: #fff;
}

body {
  min-height: 100vh;
  color: var(--ink);
  font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
  -webkit-font-smoothing: antialiased;
}

body.lock {
  overflow: hidden;
}

button {
  font: inherit;
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}

.wxbar {
  position: sticky;
  top: 0;
  z-index: 6;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  background: #1c1c1e;
  color: #fff;
  font-size: 13px;
}

.wxbar[hidden],
.qr-block[hidden],
.get-menu[hidden],
.invite[hidden],
.android-note[hidden] {
  display: none !important;
}

.wxbar button {
  flex: none;
  border: 0;
  border-radius: 999px;
  padding: 6px 12px;
  background: var(--blue);
  color: #fff;
}

.wxbar.wxbar-hold {
  visibility: hidden;
}

.statusbar {
  height: calc(44px + env(safe-area-inset-top));
}

.page {
  width: min(430px, 100%);
  margin: 0 auto;
  padding: 4px 18px calc(24px + env(safe-area-inset-bottom));
}

.hero {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.icon {
  width: 86px;
  height: 86px;
  border-radius: 20px;
  overflow: hidden;
}

.icon svg {
  display: block;
  width: 100%;
  height: 100%;
}

h1 {
  margin: 0;
  font-size: 22px;
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: 0;
}

.subtitle {
  margin: 4px 0 0;
  color: var(--gray);
  font-size: 12px;
  line-height: 1.35;
}

.subtitle:empty {
  display: none;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
}

.install,
.trust {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 28px;
  padding: 0 10px 0 7px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
}

.install {
  border: 0;
  background: var(--blue);
  color: #fff;
}

.trust {
  border: 1px solid var(--blue);
  background: #fff;
  color: var(--blue);
}

.install:active,
.trust:active,
.copy-link:active {
  opacity: 0.6;
}

.get-wrap {
  position: relative;
}

.get-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 8;
  min-width: 148px;
  padding: 6px;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.16);
}

.get-menu button {
  display: block;
  width: 100%;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--blue);
  text-align: left;
  padding: 10px 12px;
  font-size: 15px;
  cursor: pointer;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin: 14px -18px 0;
  padding: 12px 0 10px;
  border-top: 1px solid #ededed;
  border-bottom: 1px solid #ededed;
}

.stat {
  position: relative;
  min-height: 72px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  text-align: center;
  padding: 0 6px;
}

.stat + .stat::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 1px;
  background: var(--line);
}

.stat-label,
.stat-foot {
  color: var(--gray);
  font-size: 11px;
  line-height: 1.2;
}

.stat-value {
  color: var(--gray);
  font-size: 20px;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.2;
}

.stars,
.gold-stars {
  display: flex;
  gap: 1px;
  line-height: 0;
}

.stars svg,
.gold-stars svg {
  display: block;
}

.block {
  margin-top: 22px;
}

.block h2 {
  margin: 0 0 8px;
  color: #4a4a4e;
  font-size: 18px;
  line-height: 1.3;
  font-weight: 600;
  letter-spacing: 0;
}

.intro {
  margin: 0;
  color: #4a4a4e;
  font-size: 14px;
  line-height: 1.65;
}

.invite {
  margin: 8px 0 0;
  color: var(--gray);
  font-size: 13px;
}

.rating-top {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 18px;
  align-items: center;
}

.rating-num {
  font-size: 58px;
  font-weight: 600;
  letter-spacing: -1px;
  line-height: 0.9;
  color: #4a4a4e;
}

.bars {
  display: grid;
  gap: 4px;
  padding-top: 4px;
}

.bar {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 6px;
  align-items: center;
}

.bar .stars {
  justify-content: flex-end;
  flex-wrap: nowrap;
}

.bar i {
  display: block;
  height: 2px;
  width: var(--w);
  background: #7a7a80;
}

.rating-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 8px;
  color: var(--gray);
  font-size: 12px;
}

.review {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #f2f2f2;
}

.review:first-child {
  margin-top: 16px;
  padding-top: 0;
  border-top: 0;
}

.review-head,
.review-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.review-title {
  margin: 0;
  color: #4a4a4e;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
}

.review-date,
.review-author {
  flex: none;
  color: var(--gray);
  font-size: 12px;
}

.review-author {
  max-width: 42%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.review-meta {
  margin-top: 4px;
}

.review-body {
  margin: 6px 0 0;
  color: #5c5c61;
  font-size: 14px;
  line-height: 1.55;
}

.steps {
  margin: 0;
  padding-left: 18px;
  color: #636366;
  font-size: 14px;
  line-height: 1.55;
}

.steps li + li {
  margin-top: 6px;
}

.android-note {
  margin: 10px 0 0;
  color: var(--gray);
  font-size: 14px;
  line-height: 1.5;
}

.copy-link {
  margin-top: 12px;
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--blue);
  font-size: 15px;
  cursor: pointer;
}

.sheet {
  position: fixed;
  inset: 0;
  z-index: 18;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 24px 16px calc(24px + env(safe-area-inset-bottom));
  background: rgba(0, 0, 0, 0.45);
}

.sheet[hidden] {
  display: none !important;
}

.sheet-card {
  width: min(420px, 100%);
  padding: 18px 16px 16px;
  border-radius: 14px;
  background: #fff;
}

.sheet-card h2 {
  margin: 0 0 12px;
  font-size: 18px;
}

.sheet-card .btn-fill {
  margin-top: 16px;
}

.qr-block {
  margin-top: 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.qr-frame {
  width: 136px;
  height: 136px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 12px;
}

.qr-frame img {
  width: 120px;
  height: 120px;
  image-rendering: pixelated;
}

.qr-caption,
.qr-fallback {
  margin: 0;
  color: var(--gray);
  font-size: 12px;
  text-align: center;
}

.mask {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 24px 16px calc(24px + env(safe-area-inset-bottom));
  background: rgba(0, 0, 0, 0.45);
}

.mask[hidden] {
  display: none !important;
}

.mask-arrow {
  position: absolute;
  top: 4px;
  right: 6px;
  width: 72px;
  height: 72px;
}

.mask-card {
  width: min(420px, 100%);
  padding: 20px 16px 16px;
  border-radius: 14px;
  background: #fff;
}

.mask-index {
  margin: 0;
  color: var(--blue);
  font-size: 13px;
  font-weight: 600;
}

.mask-card h2 {
  margin: 6px 0 0;
  font-size: 20px;
}

.mask-steps {
  margin: 14px 0 16px;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
}

.mask-steps li {
  display: flex;
  gap: 10px;
  font-size: 15px;
  line-height: 1.45;
}

.step-no {
  width: 22px;
  height: 22px;
  flex: none;
  border-radius: 50%;
  background: #eef5ff;
  color: var(--blue);
  font-size: 12px;
  font-weight: 700;
  display: grid;
  place-items: center;
}

.btn-fill {
  width: 100%;
  min-height: 46px;
  border: 0;
  border-radius: 12px;
  background: var(--blue);
  color: #fff;
  font-size: 17px;
  font-weight: 600;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(24px + env(safe-area-inset-bottom));
  z-index: 30;
  transform: translateX(-50%) translateY(8px);
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(28, 28, 30, 0.92);
  color: #fff;
  font-size: 13px;
  opacity: 0;
  pointer-events: none;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
