:root {
  --bg: #eef4ff;
  --surface: rgba(255, 255, 255, 0.84);
  --surface-strong: #ffffff;
  --line: rgba(30, 74, 170, 0.12);
  --text: #162443;
  --muted: #627392;
  --accent: #1f68ff;
  --accent-deep: #0f49c6;
  --accent-soft: #dce8ff;
  --shadow: 0 24px 80px rgba(27, 72, 156, 0.14);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --max-width: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(53, 125, 255, 0.32), transparent 28%),
    radial-gradient(circle at top right, rgba(19, 76, 201, 0.18), transparent 24%),
    linear-gradient(180deg, #edf4ff 0%, #f8fbff 34%, #eef3ff 100%);
  min-height: 100vh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    linear-gradient(rgba(255, 255, 255, 0.26), rgba(255, 255, 255, 0.26)),
    repeating-linear-gradient(90deg, transparent 0, transparent 48px, rgba(42, 97, 211, 0.03) 48px, rgba(42, 97, 211, 0.03) 49px);
  pointer-events: none;
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  position: relative;
  z-index: 1;
  width: min(var(--max-width), calc(100% - 32px));
  margin: 0 auto;
  padding-bottom: 120px;
}

.topbar,
.topbar-actions,
.brand-lockup,
.hero-actions,
.pay-actions,
.pay-options,
.field-row,
.summary-line,
.order-head,
.order-foot,
.cart-line,
.panel-head,
.info-line,
.topbar-actions {
  display: flex;
  gap: 12px;
}

.topbar {
  align-items: center;
  justify-content: space-between;
  padding: 20px 0 10px;
}

.topbar-actions {
  align-items: center;
}

.brand-lockup {
  align-items: center;
  gap: 14px;
}

.brand-logo {
  width: 58px;
  height: 58px;
  object-fit: cover;
  border-radius: 20px;
  box-shadow: 0 12px 28px rgba(18, 83, 203, 0.18);
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--accent);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-family: "Avenir Next", "Helvetica Neue", sans-serif;
}

h1,
h2,
h3,
h4,
p,
ul {
  margin: 0;
}

h1 {
  font-size: 22px;
}

.hero {
  display: grid;
  grid-template-columns: 1.18fr 0.82fr;
  gap: 24px;
  min-height: calc(100vh - 120px);
  align-items: center;
  padding: 26px 0 30px;
}

.hero-copy h2,
.section-head h3 {
  letter-spacing: -0.03em;
  line-height: 1.04;
}

.hero-copy h2 {
  max-width: 9.5em;
  font-size: clamp(38px, 6vw, 72px);
}

.hero-text,
.section-tip,
.workflow article p,
.company-grid article p,
.policy-card li,
.policy-note p,
.orders-list p,
.footer p,
.member-card p,
.product-body p,
.address-card p {
  color: var(--muted);
  line-height: 1.8;
}

.hero-text {
  max-width: 560px;
  margin-top: 18px;
  font-size: 18px;
}

.hero-actions,
.pay-actions {
  margin-top: 28px;
}

.hero-panel,
.member-card,
.checkout-card,
.policy-card,
.company-grid article,
.product-card,
.workflow article,
.orders-list article,
.account-panel,
.modal-card {
  background: var(--surface);
  backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.72);
  box-shadow: var(--shadow);
}

.hero-panel {
  padding: 26px;
  border-radius: var(--radius-xl);
  display: grid;
  gap: 16px;
  align-self: stretch;
}

.hero-stat,
.member-card {
  padding: 18px 18px 20px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(226, 237, 255, 0.64));
  border: 1px solid rgba(31, 104, 255, 0.08);
}

.hero-stat span,
.strip-label,
.product-meta,
.order-tag {
  display: inline-block;
  font-size: 12px;
  color: var(--muted);
}

.hero-stat strong,
.member-card strong {
  display: block;
  margin-top: 10px;
  font-size: 20px;
  line-height: 1.5;
}

.member-strip,
.catalog-grid,
.company-grid,
.workflow-track,
.checkout-zone,
.account-grid,
.footer {
  display: grid;
  gap: 18px;
}

.member-strip {
  grid-template-columns: repeat(3, 1fr);
}

.section {
  margin-top: 28px;
}

.section-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: end;
  margin-bottom: 18px;
}

.section-head h3 {
  font-size: clamp(28px, 3vw, 42px);
}

.section-head.compact h3 {
  font-size: 28px;
}

.section-tip {
  max-width: 380px;
}

.catalog-grid,
.company-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.product-card,
.workflow article,
.checkout-card,
.policy-card,
.orders-list article,
.account-panel,
.company-grid article,
.modal-card {
  border-radius: var(--radius-lg);
}

.product-card {
  overflow: hidden;
}

.product-banner {
  height: 180px;
  padding: 18px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  background: linear-gradient(135deg, #1a5aff 0%, #7ab7ff 100%);
  color: #fff;
}

.product-icon {
  width: 56px;
  height: 56px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  font-size: 28px;
  background: rgba(255, 255, 255, 0.18);
}

.product-body,
.workflow article,
.checkout-card,
.policy-card,
.orders-list article,
.account-panel,
.modal-card,
.company-grid article,
.cart-card {
  padding: 22px;
}

.product-meta {
  margin-top: 14px;
}

.product-bottom,
.cart-footer.stacked,
.stack-form,
.pay-verify,
.info-stack,
.address-list,
.orders-list,
.cart-items,
.timeline {
  display: grid;
  gap: 14px;
}

.product-bottom {
  margin-top: 18px;
  grid-template-columns: 1fr auto;
  align-items: center;
}

.price {
  font-size: 28px;
  font-weight: 800;
}

.primary-btn,
.secondary-btn,
.ghost-btn,
.pay-option,
.tab-btn {
  border: 0;
  border-radius: 999px;
  padding: 13px 20px;
  transition: transform 180ms ease, background 180ms ease, box-shadow 180ms ease;
}

.primary-btn {
  color: #fff;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-deep) 100%);
  box-shadow: 0 12px 30px rgba(31, 104, 255, 0.28);
}

.secondary-btn,
.pay-option,
.tab-btn {
  background: rgba(255, 255, 255, 0.92);
  color: var(--text);
  border: 1px solid rgba(31, 104, 255, 0.12);
}

.ghost-btn {
  background: transparent;
  color: var(--accent);
  border: 1px solid rgba(31, 104, 255, 0.18);
}

.primary-btn:hover,
.secondary-btn:hover,
.ghost-btn:hover,
.pay-option:hover,
.tab-btn:hover {
  transform: translateY(-1px);
}

.workflow-track {
  grid-template-columns: repeat(4, 1fr);
}

.workflow article span {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 700;
}

.workflow article h4,
.company-grid article h4,
.policy-card h4,
.account-panel h4 {
  margin-top: 18px;
  font-size: 22px;
}

.checkout-zone {
  grid-template-columns: 1.18fr 0.82fr;
}

.field-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
}

label span {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid rgba(31, 104, 255, 0.12);
  background: rgba(255, 255, 255, 0.94);
  border-radius: 16px;
  padding: 14px 16px;
  color: var(--text);
}

textarea {
  resize: vertical;
}

.checkout-summary {
  display: grid;
  gap: 14px;
  padding: 18px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(220, 232, 255, 0.55), rgba(255, 255, 255, 0.82));
}

.summary-line,
.order-head,
.order-foot,
.cart-line,
.panel-head,
.info-line {
  justify-content: space-between;
  align-items: center;
}

.full-width {
  width: 100%;
}

.policy-card ul {
  padding-left: 18px;
  margin-top: 18px;
}

.policy-note {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.account-grid {
  grid-template-columns: 0.8fr 1.2fr;
}

.info-line span,
.timeline span {
  color: var(--muted);
}

.address-card,
.cart-card {
  border-radius: 20px;
  background: #fff;
  border: 1px solid rgba(31, 104, 255, 0.08);
}

.address-card .order-actions,
.order-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.order-tag {
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
}

.order-items,
.timeline {
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.order-items span,
.timeline span {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(31, 104, 255, 0.08);
  font-size: 14px;
}

.footer {
  margin: 34px 0 10px;
  padding: 22px 0 4px;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--line);
}

.footer-record {
  grid-column: 1 / -1;
  padding-top: 8px;
  border-top: 1px solid rgba(30, 74, 170, 0.08);
}

.footer-record a {
  color: var(--muted);
  text-decoration: none;
}

.footer-record a:hover {
  color: var(--accent);
}

.drawer,
.modal-shell {
  position: fixed;
  inset: 0;
  z-index: 20;
}

.drawer {
  inset: 0 0 0 auto;
  width: min(420px, 100%);
  background: rgba(247, 250, 255, 0.96);
  backdrop-filter: blur(20px);
  box-shadow: -24px 0 80px rgba(27, 72, 156, 0.16);
  padding: 22px;
  transform: translateX(110%);
  transition: transform 220ms ease;
}

.drawer.open {
  transform: translateX(0);
}

.floating-cart {
  position: fixed;
  right: 20px;
  bottom: 22px;
  z-index: 15;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  border-radius: 999px;
  border: 0;
  color: #fff;
  background: linear-gradient(135deg, #123d96, #1f68ff);
  box-shadow: 0 14px 36px rgba(18, 61, 150, 0.34);
}

.floating-cart strong {
  min-width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
}

.modal-shell {
  display: grid;
  place-items: center;
  background: rgba(10, 22, 52, 0.44);
}

.modal-card {
  width: min(560px, calc(100% - 24px));
}

.auth-card {
  width: min(460px, calc(100% - 24px));
}

.tab-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin: 18px 0;
}

.tab-btn.active,
.pay-option.active {
  border-color: rgba(31, 104, 255, 0.4);
  background: var(--accent-soft);
  color: var(--accent);
}

.pay-options {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin-top: 20px;
}

.pay-order-info,
.pay-verify {
  margin-top: 18px;
}

.pay-wechat {
  margin-top: 18px;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 18px;
  align-items: center;
}

.wechat-qr-wrap {
  padding: 14px;
  border-radius: 24px;
  background: #ffffff;
  border: 1px solid rgba(31, 104, 255, 0.1);
  box-shadow: inset 0 0 0 1px rgba(31, 104, 255, 0.03);
}

.wechat-qr-image {
  width: 220px;
  height: 220px;
  display: block;
  border-radius: 12px;
  object-fit: cover;
}

.wechat-pay-meta {
  display: grid;
  gap: 12px;
}

.pay-line,
.pay-status {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.pay-status {
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(31, 104, 255, 0.08);
}

.hidden {
  display: none !important;
}

.empty-state {
  padding: 28px;
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.68);
  color: var(--muted);
  text-align: center;
}

@media (max-width: 960px) {
  .hero,
  .member-strip,
  .catalog-grid,
  .company-grid,
  .workflow-track,
  .checkout-zone,
  .account-grid,
  .footer {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    padding-top: 16px;
  }

  .field-row,
  .pay-options,
  .pay-wechat {
    grid-template-columns: 1fr;
  }

  .section-head {
    align-items: start;
    flex-direction: column;
  }
}

@media (max-width: 640px) {
  .app-shell {
    width: min(var(--max-width), calc(100% - 20px));
  }

  .topbar {
    align-items: start;
    flex-direction: column;
  }

  .topbar-actions,
  .hero-actions,
  .pay-actions {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr;
  }

  .hero-copy h2 {
    font-size: 40px;
    max-width: none;
  }

  .hero-text {
    font-size: 16px;
  }

  .floating-cart {
    right: 14px;
    left: 14px;
    justify-content: space-between;
  }
}
