@import url("https://fonts.googleapis.com/css2?family=Fredoka:wght@500;600;700&family=Noto+Sans+SC:wght@400;500;700;900&display=swap");

body.yunshi-page {
  --ink: #1a1530;
  --ink2: #3d3560;
  --muted: #7a7396;
  --paper: #fff7fb;
  --card: #ffffff;
  --line: #ffe0f0;
  --coral: #ff4d7a;
  --sun: #ffd24a;
  --sky: #5b8cff;
  --mint: #2ed9a0;
  --grape: #8b6cff;
  --peach: #ff8a65;
  --cream: #fff4c7;
  --r: 22px;
  --shadow: 0 10px 28px rgba(139, 108, 255, .12);
  --sans: "Noto Sans SC", "PingFang SC", "Hiragino Sans GB", system-ui, sans-serif;
  --display: "Fredoka", "Noto Sans SC", system-ui, sans-serif;
}
html { -webkit-text-size-adjust: 100%; }
body.yunshi-page, body.yunshi-page * { box-sizing: border-box; }
body.yunshi-page {
  font-family: var(--sans);
  color: var(--ink);
  background:
    radial-gradient(900px 420px at -10% -10%, #ffd6e8 0%, transparent 55%),
    radial-gradient(700px 380px at 110% 0%, #d6e4ff 0%, transparent 50%),
    radial-gradient(600px 300px at 50% 120%, #d9ffe8 0%, transparent 45%),
    var(--paper);
  line-height: 1.55;
  min-height: 100vh;
}
.yunshi-page .app a, .yunshi-page .tabs a { color: inherit; text-decoration: none; }
.yunshi-page .app img { max-width: 100%; display: block; }
.yunshi-page .app button,
.yunshi-page .tabs button,
.yunshi-page .tabbar button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }

.sample-banner {
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
  padding: 10px 16px; background: #1a1530; color: #fff; font-size: 13px;
}
.sample-banner b { font-family: var(--display); font-weight: 650; }
.pill {
  background: var(--sun); color: #1a1530; border-radius: 999px;
  padding: 2px 9px; font-size: 11px; font-weight: 800;
}
.sample-banner .meta { opacity: .72; margin-left: auto; }

.app {
  max-width: 430px; margin: 0 auto; padding: 14px 14px 112px;
}

.hero {
  position: relative;
  background: linear-gradient(145deg, #ff6b93 0%, #ff8a5b 48%, #ffd24a 100%);
  color: #fff; border-radius: 28px; padding: 22px 20px 20px;
  box-shadow: 0 16px 36px rgba(255, 77, 122, .28);
  overflow: hidden;
}
.hero:after {
  content: ""; position: absolute; right: -30px; top: -30px;
  width: 140px; height: 140px; border-radius: 50%;
  background: rgba(255,255,255,.18);
}
.hero .kicker {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(255,255,255,.22); border-radius: 999px;
  padding: 4px 10px; font-size: 12px; font-weight: 700;
}
.hero h1 {
  font-family: var(--display); font-size: 30px; line-height: 1.15;
  margin: 12px 0 6px; letter-spacing: .02em;
}
.hero p { opacity: .94; font-size: 14px; max-width: 22em; }
.sticker {
  position: absolute; right: 16px; bottom: 16px; z-index: 1;
  background: #fff; color: var(--coral); border-radius: 16px;
  padding: 8px 10px; transform: rotate(8deg);
  font-family: var(--display); font-weight: 700; font-size: 13px;
  box-shadow: 0 8px 16px rgba(26,21,48,.12);
}

.tabs {
  display: flex; gap: 8px; overflow-x: auto; padding: 14px 2px 6px;
  scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tab {
  flex: none; padding: 8px 14px; border-radius: 999px;
  background: #fff; border: 1.5px solid #ffd0e4;
  font-weight: 700; font-size: 13px; color: var(--ink2);
}
.tab.on {
  background: var(--ink); color: #fff; border-color: var(--ink);
}

.toolbar {
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
  margin: 8px 0 12px;
}
.seg {
  display: flex; background: #fff; border-radius: 999px; padding: 3px;
  border: 1.5px solid #ffd0e4;
}
.seg button {
  padding: 6px 12px; border-radius: 999px; font-size: 12px; font-weight: 800;
}
.seg button.on { background: var(--grape); color: #fff; }
.hint { font-size: 12px; color: var(--muted); }

.sx-row {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px;
  margin-bottom: 14px;
}
.sx-pk {
  background: #fff; border-radius: 16px; padding: 6px 2px 8px;
  text-align: center; border: 2px solid transparent;
  box-shadow: var(--shadow);
}
.sx-pk img { width: 40px; height: 40px; margin: 0 auto 2px; }
.sx-pk b { display: block; font-size: 11px; font-weight: 800; }
.sx-pk.on { border-color: var(--coral); background: #fff0f5; transform: translateY(-2px); }

.card {
  background: var(--card); border-radius: var(--r);
  padding: 16px; box-shadow: var(--shadow); margin-bottom: 12px;
}
.card-h {
  display: flex; align-items: center; gap: 12px; margin-bottom: 12px;
}
.card-h img { width: 64px; height: 64px; }
.card-h .who { font-size: 13px; color: var(--muted); font-weight: 700; }
.card-h h2 { font-family: var(--display); font-size: 22px; line-height: 1.2; }
.score-bubble {
  margin-left: auto; width: 64px; height: 64px; border-radius: 50%;
  display: grid; place-items: center;
  background: conic-gradient(var(--coral) calc(var(--p) * 1%), #ffe3ee 0);
  position: relative;
}
.score-bubble span {
  width: 50px; height: 50px; border-radius: 50%; background: #fff;
  display: grid; place-items: center;
  font-family: var(--display); font-size: 22px; font-weight: 700; color: var(--coral);
}

.block-title {
  display: flex; align-items: center; gap: 8px;
  font-family: var(--display); font-size: 18px; margin: 4px 0 10px;
}
.dot { width: 10px; height: 10px; border-radius: 50%; }
.yi .dot { background: var(--mint); }
.ji .dot { background: var(--coral); }

.row {
  display: grid; grid-template-columns: 72px 1fr; gap: 10px;
  padding: 10px 0; border-top: 1px dashed #ffe0ef;
}
.row:first-of-type { border-top: 0; }
.term {
  font-weight: 900; font-size: 14px; line-height: 1.3;
}
.yi .term { color: #12986c; }
.ji .term { color: var(--coral); }
.talk { font-size: 14px; color: var(--ink2); }
.act {
  margin-top: 6px; display: inline-flex; align-items: flex-start; gap: 6px;
  background: #f3fff8; color: #0d7a56; border-radius: 12px;
  padding: 7px 10px; font-size: 13px; font-weight: 600;
}
.ji .act { background: #fff3f6; color: #c22755; }
.badge-mini {
  flex: none; font-size: 10px; font-weight: 900; letter-spacing: .04em;
  background: var(--mint); color: #063; border-radius: 6px; padding: 2px 5px;
}
.ji .badge-mini { background: #ffd2de; color: #a0143c; }
.locked .act { filter: blur(5px); user-select: none; pointer-events: none; }
.lock-cta {
  margin-top: 12px; background: linear-gradient(90deg, #8b6cff, #ff4d7a);
  color: #fff; border-radius: 16px; padding: 12px 14px; text-align: center;
  font-weight: 800; font-size: 14px;
}
.lock-cta small { display: block; font-weight: 500; opacity: .85; margin-top: 2px; }

.idx-chips { display: flex; gap: 8px; overflow-x: auto; padding: 4px 0 10px; scrollbar-width: none; }
.idx-chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; background: #fff; border: 1.5px solid #eadbff; border-radius: 999px;
  padding: 7px 12px; font-weight: 800; font-size: 13px;
}
.chip.on { background: var(--grape); color: #fff; border-color: var(--grape); }

.rank { display: flex; flex-direction: column; gap: 8px; }
.rank-item {
  display: grid; grid-template-columns: 36px 44px 1fr auto; gap: 8px;
  align-items: center; background: #fff; border-radius: 18px; padding: 8px 12px;
  box-shadow: var(--shadow);
}
.rank-item img { width: 44px; height: 44px; }
.rank-item .n {
  font-family: var(--display); font-size: 18px; color: var(--muted); text-align: center;
}
.rank-item.top .n { color: var(--coral); }
.rank-item .name { font-weight: 900; }
.rank-item .tag { font-size: 12px; color: var(--muted); }
.big-sc {
  font-family: var(--display); font-size: 28px; font-weight: 700; line-height: 1;
  min-width: 52px; text-align: right;
}
.hot { color: var(--coral); }
.mid { color: var(--grape); }
.cold { color: #8aa; }
.bar { height: 8px; background: #f1e9ff; border-radius: 99px; margin-top: 6px; overflow: hidden; }
.bar i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, #8b6cff, #ff4d7a); }
.note { font-size: 12px; color: var(--muted); margin: 8px 2px 0; }

.podium { display: grid; grid-template-columns: 1fr 1.15fr 1fr; gap: 8px; align-items: end; margin: 8px 0 14px; }
.pod {
  background: #fff; border-radius: 20px; text-align: center; padding: 12px 8px 14px;
  box-shadow: var(--shadow);
}
.pod img { width: 68px; height: 68px; margin: 0 auto 6px; }
.pod.p1 { padding-top: 18px; background: linear-gradient(180deg, #fff4c7, #fff); border: 2px solid var(--sun); }
.pod.p2 { border: 2px solid #d8deff; }
.pod.p3 { border: 2px solid #ffd8c4; }
.pod .place { font-family: var(--display); font-size: 13px; font-weight: 700; }
.pod b { display: block; font-size: 16px; }
.pod em { font-style: normal; font-family: var(--display); font-size: 26px; color: var(--coral); }

.rest { display: flex; flex-direction: column; gap: 8px; }
.rest-item {
  display: grid; grid-template-columns: 28px 40px 1fr; gap: 8px; align-items: center;
  background: #fff; border-radius: 16px; padding: 8px 12px;
}
.rest-item img { width: 40px; height: 40px; }
.rest-item .pl { font-weight: 900; color: var(--muted); }
.rest-item p { font-size: 13px; color: var(--ink2); }

.zhan {
  background: #fff; border-radius: 22px; padding: 16px 16px 14px;
  box-shadow: var(--shadow); margin-bottom: 12px; position: relative;
}
.zhan .when { font-size: 11px; font-weight: 800; color: var(--grape); letter-spacing: .06em; }
.zhan h3 { font-family: var(--display); font-size: 20px; margin: 6px 0 8px; }
.tags { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.tagx {
  background: #fff0f5; color: var(--coral); border-radius: 999px;
  padding: 3px 10px; font-weight: 800; font-size: 13px;
}
.zhan p { font-size: 14.5px; color: var(--ink2); }
.cta-line {
  margin-top: 10px; font-family: var(--display); font-size: 18px; color: var(--coral);
}
.zhan .stamp {
  position: absolute; right: 12px; top: 12px;
  border: 2px solid var(--coral); color: var(--coral); border-radius: 10px;
  padding: 2px 6px; font-weight: 900; font-size: 11px; transform: rotate(12deg);
  opacity: .85;
}

.quiz-cover {
  background: linear-gradient(160deg, #8b6cff, #5b8cff 50%, #2ed9a0);
  color: #fff; border-radius: 28px; padding: 28px 22px; text-align: center;
  box-shadow: 0 16px 36px rgba(91,140,255,.28);
}
.quiz-cover h2 { font-family: var(--display); font-size: 28px; line-height: 1.2; margin: 8px 0 10px; }
.quiz-cover p { opacity: .92; }
.start {
  margin-top: 18px; background: #fff; color: var(--grape); border-radius: 999px;
  padding: 12px 22px; font-weight: 900; font-size: 16px;
}
.q-progress { height: 8px; background: #ffe3f0; border-radius: 99px; margin: 8px 0 14px; overflow: hidden; }
.q-progress i { display: block; height: 100%; background: linear-gradient(90deg,#ff4d7a,#ffd24a); }
.q-card h3 { font-size: 20px; font-weight: 900; margin-bottom: 12px; }
.opt {
  display: block; width: 100%; text-align: left; background: #fff;
  border: 2px solid #ffe0f0; border-radius: 16px; padding: 12px 14px;
  margin-bottom: 8px; font-weight: 700;
}
.opt:active, .opt.on { border-color: var(--grape); background: #f3eeff; }

.result {
  background: #fff; border-radius: 28px; padding: 20px 18px; text-align: center;
  box-shadow: var(--shadow);
}
.result img { width: 96px; height: 96px; margin: 0 auto 8px; }
.result .type {
  display: inline-block; background: var(--sun); color: #1a1530;
  border-radius: 999px; padding: 4px 12px; font-weight: 900; font-size: 13px;
}
.result h2 { font-family: var(--display); font-size: 28px; margin: 8px 0 4px; }
.result .sc {
  font-family: var(--display); font-size: 56px; color: var(--coral); line-height: 1;
}
.result .sc small { font-size: 18px; color: var(--muted); }
.result p { text-align: left; margin-top: 10px; color: var(--ink2); }
.share-row { display: flex; gap: 8px; margin-top: 14px; }
.share-row button, .share-row a {
  flex: 1; background: var(--ink); color: #fff; border-radius: 999px;
  padding: 11px 8px; font-weight: 800; font-size: 13px; text-align: center;
}
.deep {
  margin-top: 12px; border: 2px dashed #d4c4ff; border-radius: 18px;
  padding: 14px; background: #faf6ff; text-align: left;
}
.deep b { display: block; margin-bottom: 4px; }
.deep .price { color: var(--grape); font-weight: 900; }

.foot {
  text-align: center; font-size: 12px; color: var(--muted); padding: 18px 8px 0;
}
.tabbar {
  position: fixed; left: 50%; bottom: 12px; transform: translateX(-50%);
  width: min(402px, calc(100% - 20px));
  background: rgba(26,21,48,.94); color: #fff; border-radius: 22px;
  display: grid; grid-template-columns: repeat(5, 1fr);
  padding: 8px 6px; backdrop-filter: blur(12px); z-index: 20;
}
.tabbar button { color: rgba(255,255,255,.55); font-size: 11px; font-weight: 800; padding: 6px 0; }
.tabbar button span { display: block; font-size: 16px; line-height: 1.2; }
.tabbar button.on { color: #ffd24a; }

@media (min-width: 800px) {
  body.yunshi-page { padding-bottom: 20px; }
  .yunshi-page .app { max-width: 430px; }
}

/* yule-v4 additions */
.date-row, .idx-chips { display: flex; gap: 8px; overflow-x: auto; padding: 4px 0 10px; scrollbar-width: none; }
.date-row::-webkit-scrollbar { display: none; }
.dchip {
  flex: none; background: #fff; border: 1.5px solid #ffd0e4; border-radius: 16px;
  padding: 7px 10px; text-align: center; min-width: 64px;
}
.dchip b { display: block; font-size: 13px; font-weight: 900; }
.dchip span { display: block; font-size: 10px; color: var(--muted); font-weight: 700; }
.dchip.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.dchip.on span { color: #ffd24a; }
.bday {
  display: flex; gap: 8px; align-items: center; flex-wrap: wrap;
  background: #fff; border: 1.5px solid #ffd0e4; border-radius: 16px;
  padding: 8px 10px; margin-bottom: 12px;
}
.bday label { font-size: 12px; font-weight: 800; color: var(--muted); }
.bday input {
  border: 0; font: inherit; font-weight: 700; color: var(--ink); background: transparent;
}
.sub-card {
  background: linear-gradient(135deg, #1a1530, #3d2a7a);
  color: #fff; border-radius: 22px; padding: 16px; margin: 12px 0;
  box-shadow: var(--shadow);
}
.sub-card h3 { font-family: var(--display); font-size: 20px; margin: 4px 0 8px; }
.sub-card p { font-size: 13.5px; opacity: .92; }
.sub-card .price-row { display: flex; gap: 8px; margin: 12px 0; }
.price-pill {
  flex: 1; background: rgba(255,255,255,.12); border-radius: 14px; padding: 10px 8px; text-align: center;
}
.price-pill b { display: block; font-family: var(--display); font-size: 18px; color: #ffd24a; }
.price-pill span { font-size: 11px; opacity: .8; }
.sub-actions { display: flex; gap: 8px; }
.sub-actions a, .sub-actions button {
  flex: 1; background: #ffd24a; color: #1a1530; border-radius: 999px;
  padding: 11px 8px; font-weight: 900; font-size: 13px; text-align: center;
}
.sub-actions a.ghost, .sub-actions button.ghost {
  background: rgba(255,255,255,.12); color: #fff;
}
.push-card {
  background: #fff; border-radius: 22px; padding: 16px; box-shadow: var(--shadow); margin-bottom: 12px;
}
.push-card .who { font-size: 11px; font-weight: 800; color: var(--grape); letter-spacing: .06em; }
.checkin {
  margin-top: 10px; width: 100%; background: #f3fff8; color: #0d7a56;
  border: 1.5px dashed #9be7c4; border-radius: 14px; padding: 10px; font-weight: 800;
}
.checkin.done { background: var(--mint); color: #063; border-style: solid; }
.modal {
  position: fixed; inset: 0; background: rgba(26,21,48,.55); z-index: 40;
  display: grid; place-items: end center; padding: 16px;
}
.sheet {
  background: #fff; width: min(430px, 100%); border-radius: 24px 24px 18px 18px;
  padding: 18px 16px 22px; max-height: 86vh; overflow: auto;
}
.sheet h3 { font-family: var(--display); font-size: 22px; margin-bottom: 8px; }
.toast {
  position: fixed; left: 50%; bottom: 86px; transform: translateX(-50%);
  background: #1a1530; color: #fff; border-radius: 999px; padding: 8px 14px;
  font-size: 13px; font-weight: 700; z-index: 30; white-space: nowrap;
}
.share-preview img { width: 100%; border-radius: 18px; margin: 8px 0 12px; }
.bday input[type="text"] { min-width: 140px; letter-spacing: .04em; }
.bday input::placeholder { color: #b5aec8; font-weight: 600; }

.lock-cta{display:block}
.yunshi-page .sample-banner{display:none}
