:root {
  color-scheme: light;
  font-family: Inter, "Noto Sans SC", "Microsoft YaHei", sans-serif;
  color: #211f23;
  background: #fff8fb;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background: #fff8fb;
  line-height: 1.55;
}

a { color: inherit; }

.pricing-topbar {
  position: sticky;
  top: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 68px;
  padding: 10px max(20px, calc((100vw - 1160px) / 2));
  border-bottom: 1px solid #eadde3;
  background: rgba(255, 255, 255, 0.96);
}

.pricing-brand,
.pricing-topbar nav,
.pricing-footer nav {
  display: flex;
  align-items: center;
}

.pricing-brand img {
  display: block;
  width: 44px;
  height: 44px;
  object-fit: contain;
  border-radius: 7px;
}

.pricing-brand span {
  margin-left: 10px;
  color: #3b0710;
  font-size: 23px;
  font-weight: 850;
}

.pricing-topbar nav { gap: 8px; }
.pricing-language select {
  min-height: 36px;
  padding: 0 28px 0 10px;
  border: 1px solid #e3d7dc;
  border-radius: 6px;
  background: #ffffff;
  color: #4d4549;
  font: inherit;
}
.pricing-topbar nav a {
  padding: 8px 10px;
  color: #665b61;
  font-size: 14px;
  text-decoration: none;
}
.pricing-topbar nav a.active { color: #9f2f54; font-weight: 800; }
.pricing-topbar nav a.primary-link {
  border: 1px solid #b63e62;
  border-radius: 6px;
  color: #9f2f54;
  font-weight: 700;
}

main { overflow: hidden; }

.pricing-intro,
.plans-section,
.packs-section,
.purchase-notes {
  width: min(1160px, calc(100% - 40px));
  margin-right: auto;
  margin-left: auto;
}

.pricing-intro { padding: 68px 0 46px; }
.eyebrow,
.section-kicker,
.plan-label {
  margin: 0;
  color: #b63e62;
  font-size: 12px;
  font-weight: 800;
}
.pricing-intro h1 {
  max-width: 980px;
  margin: 10px 0 14px;
  font-size: 58px;
  line-height: 1.12;
  letter-spacing: 0;
}
.pricing-intro > p:last-child {
  max-width: 720px;
  margin: 0;
  color: #6b6066;
  font-size: 17px;
}

.plans-section,
.packs-section,
.purchase-notes { padding: 32px 0 54px; }

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  padding-bottom: 18px;
  border-bottom: 1px solid #eadde3;
}
.section-heading h2 {
  margin: 2px 0 0;
  font-size: 27px;
  letter-spacing: 0;
}
.section-heading > p {
  max-width: 540px;
  margin: 0;
  color: #746970;
  font-size: 14px;
  text-align: right;
}

.plan-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}
.plan-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  padding: 26px;
  border: 1px solid #e7d9df;
  border-radius: 8px;
  background: #ffffff;
}
.plan-card.featured {
  border-color: #c84c6e;
  box-shadow: 0 15px 38px rgba(110, 28, 57, 0.1);
}
.plan-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 14px;
  min-height: 66px;
}
.plan-head h3 { margin: 3px 0 0; font-size: 23px; }
.price { margin: 0; text-align: right; white-space: nowrap; }
.price strong { display: block; color: #8f2448; font-size: 30px; line-height: 1; }
.price span { color: #7c7177; font-size: 12px; }
[data-price-key] {
  display: inline-block;
  min-width: 3.2ch;
  transition: opacity 160ms ease;
}
.pricing-localizing [data-price-key] { opacity: 0.52; }
.annual-price {
  min-height: 25px;
  margin: 9px 0 0;
  color: #8f2448;
  font-size: 14px;
  font-weight: 800;
}
.annual-price span { color: #80747a; font-size: 11px; font-weight: 500; }
.annual-price strong { color: inherit; font: inherit; }
.plan-summary { min-height: 72px; margin: 18px 0 0; color: #554d51; }
.plan-summary span { color: #82767c; font-size: 13px; }
.plan-card ul {
  display: grid;
  gap: 10px;
  margin: 18px 0 26px;
  padding: 18px 0 0 20px;
  border-top: 1px solid #efe4e8;
  color: #3e393c;
  font-size: 14px;
}
.plan-action,
.packs-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  margin-top: auto;
  border: 1px solid #a92f55;
  border-radius: 6px;
  background: #a92f55;
  color: #ffffff;
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
}
.plan-action.secondary { background: #ffffff; color: #9f2f54; }

.packs-section { border-top: 1px solid #eadde3; }
.pack-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 20px 0 16px;
}
.pack-grid article {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  padding: 20px;
  border: 1px solid #e7d9df;
  border-radius: 8px;
  background: #ffffff;
}
.pack-grid h3 {
  grid-column: 1;
  margin: 0 0 8px;
  font-size: 18px;
}
.pack-grid p { margin: 0; font-size: 16px; }
.pack-grid p strong { font-size: 30px; }
.pack-grid span { color: #81747a; font-size: 12px; }
.pack-price-row {
  grid-row: 1 / 4;
  grid-column: 2;
  display: flex;
  align-items: baseline;
  justify-content: flex-end;
  gap: 8px;
  white-space: nowrap;
}
.pack-price-row del { color: #8b8186; font-size: 15px; }
.pack-price-row b { color: #8f2448; font-size: 25px; }
.pack-price-row em {
  padding: 2px 5px;
  border: 1px solid #e5a1b7;
  border-radius: 5px;
  background: #fff1f6;
  color: #a42e54;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}
.pack-grid small {
  grid-column: 1 / -1;
  margin-top: 12px;
  color: #a42e54;
  font-size: 12px;
  font-weight: 700;
}
.pricing-non-cny [data-regular-price-key] { display: none; }
.packs-action { min-width: 280px; padding: 0 18px; }

.purchase-notes {
  width: 100%;
  padding-right: max(20px, calc((100vw - 1160px) / 2));
  padding-left: max(20px, calc((100vw - 1160px) / 2));
  border-top: 1px solid #eadde3;
  background: #ffffff;
}
.purchase-notes h2 { margin: 0 0 20px; font-size: 24px; }
.notes-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 48px; }
.notes-grid p { margin: 0; }
.notes-grid strong { display: block; margin-bottom: 4px; font-size: 14px; }
.notes-grid span { color: #746970; font-size: 13px; }

.pricing-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 70px;
  padding: 16px max(20px, calc((100vw - 1160px) / 2));
  border-top: 1px solid #eadde3;
  color: #766c73;
  font-size: 13px;
}
.pricing-footer nav { flex-wrap: wrap; justify-content: end; gap: 18px; }
.pricing-footer a { color: #8d3151; text-decoration: none; }

html[data-theme="dark"] {
  color-scheme: dark;
  color: #f7eef2;
  background: #171319;
}

html[data-theme="dark"] body { background: #171319; }

html[data-theme="dark"] .pricing-topbar {
  border-color: #493944;
  background: rgba(33, 26, 34, 0.96);
}

html[data-theme="dark"] .pricing-brand span { color: #ffd8e0; }

html[data-theme="dark"] .pricing-language select,
html[data-theme="dark"] .plan-card,
html[data-theme="dark"] .pack-grid article,
html[data-theme="dark"] .purchase-notes {
  border-color: #493944;
  background: #211a22;
  color: #f7eef2;
}

html[data-theme="dark"] .pricing-topbar nav a,
html[data-theme="dark"] .pricing-intro > p:last-child,
html[data-theme="dark"] .section-heading > p,
html[data-theme="dark"] .price span,
html[data-theme="dark"] .annual-price span,
html[data-theme="dark"] .plan-summary,
html[data-theme="dark"] .plan-summary span,
html[data-theme="dark"] .pack-grid span,
html[data-theme="dark"] .notes-grid span,
html[data-theme="dark"] .pricing-footer {
  color: #bcaeb8;
}

html[data-theme="dark"] .section-heading,
html[data-theme="dark"] .packs-section,
html[data-theme="dark"] .purchase-notes,
html[data-theme="dark"] .pricing-footer,
html[data-theme="dark"] .plan-card ul {
  border-color: #493944;
}

html[data-theme="dark"] .plan-card ul { color: #e9dde3; }

html[data-theme="dark"] .eyebrow,
html[data-theme="dark"] .section-kicker,
html[data-theme="dark"] .plan-label,
html[data-theme="dark"] .price strong,
html[data-theme="dark"] .annual-price,
html[data-theme="dark"] .pack-price-row b,
html[data-theme="dark"] .pack-grid small,
html[data-theme="dark"] .pricing-topbar nav a.active,
html[data-theme="dark"] .pricing-footer a {
  color: #ff9ab5;
}

html[data-theme="dark"] .plan-action.secondary {
  background: #2b232b;
  color: #ffadc1;
}

html[data-theme="dark"] .pack-price-row em {
  border-color: #8c5365;
  background: #3b232e;
  color: #ffadc1;
}

@media (max-width: 1000px) {
  .pricing-intro h1 { max-width: 760px; font-size: 50px; }
}

@media (max-width: 840px) {
  .plan-grid { grid-template-columns: 1fr; }
  .plan-card { min-height: 0; }
  .plan-summary { min-height: 0; }
  .pack-grid { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .pricing-topbar {
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 12px;
    padding: 9px 12px;
  }
  .pricing-brand img { width: 40px; height: 40px; }
  .pricing-brand span { margin-left: 8px; font-size: 21px; }
  .pricing-topbar nav {
    min-width: 0;
    flex: 1 0 100%;
    flex-wrap: wrap;
    justify-content: flex-start;
  }
  .pricing-language { min-width: 0; }
  .pricing-language select {
    max-width: 128px;
    min-height: 34px;
  }
  .pricing-topbar nav a { padding: 6px; font-size: 12px; }
  .pricing-topbar nav a.active { display: none; }
  .pricing-intro,
  .plans-section,
  .packs-section { width: min(100% - 24px, 580px); }
  .pricing-intro { padding: 42px 0 30px; }
  .pricing-intro h1 { font-size: 36px; }
  .section-heading { align-items: start; flex-direction: column; gap: 8px; }
  .section-heading > p { text-align: left; }
  .plan-card { padding: 22px 18px; }
  .pack-grid article {
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
  }
  .pack-price-row {
    grid-row: auto;
    grid-column: 1;
    flex-wrap: wrap;
    justify-content: flex-start;
    margin-top: 10px;
    white-space: normal;
  }
  .notes-grid { grid-template-columns: 1fr; }
  .packs-action { width: 100%; min-width: 0; }
  .pricing-footer { align-items: flex-start; flex-direction: column; }
  .pricing-footer nav { justify-content: flex-start; gap: 10px 16px; }
}
