/* ==========================================================================
   星卡铺 · 前台样式
   ========================================================================== */

:root {
  --bg: #f6f7fb;
  --surface: #ffffff;
  --ink: #111827;
  --muted: #667085;
  --line: #e9ebf3;
  --brand: #5b5bd6;
  --brand-2: #8b5cf6;
  --brand-soft: #eef0ff;
  --success: #0f9f6e;
  --success-soft: #e8f8f1;
  --danger: #e5484d;
  --danger-soft: #fdeeee;
  --warn: #b7791f;
  --warn-soft: #fdf6e7;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow-sm: 0 2px 8px rgba(16, 24, 40, 0.05);
  --shadow: 0 18px 40px -24px rgba(16, 24, 40, 0.28);
  --shadow-lg: 0 30px 70px -32px rgba(45, 42, 120, 0.35);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Noto Sans SC", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

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

ul,
ol {
  padding: 0;
  list-style: none;
}

a {
  color: inherit;
  text-decoration: none;
}

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

img {
  display: block;
  max-width: 100%;
}

code {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

.container {
  width: min(1160px, 100% - 40px);
  margin-inline: auto;
}

.muted {
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   顶部导航
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid rgba(233, 235, 243, 0.9);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 32px;
  height: 72px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  flex-shrink: 0;
}

.brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 13px;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 1px;
  box-shadow: 0 10px 22px -10px rgba(91, 91, 214, 0.85);
}

.brand-text strong {
  display: block;
  font-size: 17px;
  line-height: 1.2;
  letter-spacing: 0.5px;
}

.brand-text small {
  display: block;
  color: var(--muted);
  font-size: 11.5px;
  letter-spacing: 0.3px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  margin-left: auto;
  font-size: 14px;
  color: var(--muted);
}

.site-nav a,
.site-nav button {
  position: relative;
  background: none;
  border: 0;
  padding: 6px 0;
  cursor: pointer;
  font-size: 14px;
  color: var(--muted);
  transition: color 0.18s ease;
}

.site-nav a:hover,
.site-nav button:hover,
.site-nav a.active {
  color: var(--ink);
}

.site-nav a.active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--brand), var(--brand-2));
}

.header-cta {
  margin-left: 4px;
}

/* 公告 */
.announcement {
  background: linear-gradient(90deg, #eef0ff, #f7f0ff 55%, #eef6ff);
  border-bottom: 1px solid #e6e8f7;
  color: #4b4a7a;
  font-size: 13px;
}

.announcement .container {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-block: 9px;
}

.announcement .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--brand);
  box-shadow: 0 0 0 4px rgba(91, 91, 214, 0.14);
  flex-shrink: 0;
}

/* --------------------------------------------------------------------------
   按钮 / 标签 / 表单控件
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  padding: 10px 18px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease,
    background 0.16s ease, opacity 0.16s ease;
}

.btn:focus-visible,
.chip:focus-visible,
.pay-tile:focus-within {
  outline: 3px solid rgba(91, 91, 214, 0.24);
  outline-offset: 2px;
}

.btn:disabled,
.btn[aria-disabled="true"] {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

.btn-primary {
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff;
  box-shadow: 0 12px 24px -14px rgba(91, 91, 214, 0.95);
}

.btn-primary:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 16px 30px -14px rgba(91, 91, 214, 0.95);
}

.btn-ghost {
  background: #fff;
  border-color: var(--line);
  color: var(--ink);
}

.btn-ghost:hover:not(:disabled) {
  border-color: #cfd3e4;
  box-shadow: var(--shadow-sm);
}

.btn-soft {
  background: var(--brand-soft);
  color: var(--brand);
  border-color: transparent;
}

.btn-soft:hover:not(:disabled) {
  background: #e4e7ff;
}

.btn-danger-ghost {
  background: #fff;
  border-color: #f7d4d6;
  color: var(--danger);
}

.btn-danger-ghost:hover:not(:disabled) {
  background: var(--danger-soft);
}

.btn-sm {
  padding: 8px 14px;
  font-size: 13px;
  border-radius: 9px;
}

.btn-lg {
  padding: 13px 26px;
  font-size: 15px;
  border-radius: 12px;
}

.btn-block {
  width: 100%;
}

.btn-link {
  border: 0;
  background: none;
  padding: 0;
  color: var(--brand);
  font-weight: 600;
  cursor: pointer;
  font-size: 14px;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 22px 0 26px;
}

.chip {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 8px 18px;
  font-size: 13.5px;
  color: var(--muted);
  cursor: pointer;
  transition: all 0.16s ease;
}

.chip:hover {
  border-color: #cdd1e6;
  color: var(--ink);
}

.chip.active {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
  box-shadow: 0 10px 20px -14px rgba(17, 24, 39, 0.8);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 600;
  line-height: 1.6;
  background: var(--brand-soft);
  color: var(--brand);
}

.pill-success {
  background: var(--success-soft);
  color: var(--success);
}

.pill-warn {
  background: var(--warn-soft);
  color: var(--warn);
}

.pill-danger {
  background: var(--danger-soft);
  color: var(--danger);
}

.pill-gray {
  background: #f0f2f7;
  color: #667085;
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(900px 420px at 82% -10%, rgba(139, 92, 246, 0.16), transparent 62%),
    radial-gradient(720px 380px at 4% 0%, rgba(91, 91, 214, 0.12), transparent 58%),
    linear-gradient(180deg, #fbfbff 0%, var(--bg) 88%);
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.02fr 0.98fr;
  gap: 56px;
  align-items: center;
  padding: 66px 0 72px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 12.5px;
  font-weight: 600;
  color: #5b5bd6;
  box-shadow: var(--shadow-sm);
}

.hero h1 {
  margin: 20px 0 16px;
  font-size: clamp(32px, 4.4vw, 52px);
  line-height: 1.16;
  letter-spacing: -0.5px;
  font-weight: 800;
}

.hero h1 em {
  font-style: normal;
  background: linear-gradient(120deg, var(--brand), #b06ef0 70%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-copy > p {
  max-width: 480px;
  color: var(--muted);
  font-size: 15.5px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.hero-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
  margin-top: 34px;
  color: var(--muted);
  font-size: 13px;
}

.hero-facts li {
  display: flex;
  align-items: center;
  gap: 7px;
}

.hero-facts b {
  color: var(--ink);
  font-size: 16px;
  font-weight: 700;
}

.hero-art {
  position: relative;
  min-height: 360px;
  display: grid;
  place-items: center;
}

.ticket {
  position: relative;
  z-index: 2;
  width: min(370px, 100%);
  border-radius: 22px;
  padding: 26px 26px 20px;
  color: #fff;
  background:
    radial-gradient(120% 120% at 85% 0%, rgba(255, 255, 255, 0.28), transparent 42%),
    linear-gradient(145deg, #4f46e5 0%, #7c3aed 52%, #a855f7 100%);
  box-shadow: 0 40px 80px -36px rgba(79, 70, 229, 0.75);
  transform: rotate(-3deg);
}

.ticket::before,
.ticket::after {
  content: "";
  position: absolute;
  top: 148px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--bg);
}

.ticket::before {
  left: -11px;
}

.ticket::after {
  right: -11px;
}

.ticket-top {
  display: flex;
  align-items: center;
  gap: 12px;
}

.ticket-emoji {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  font-size: 24px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.ticket-top b {
  display: block;
  font-size: 15px;
  letter-spacing: 0.3px;
}

.ticket-top small {
  display: block;
  font-size: 11px;
  letter-spacing: 1.6px;
  color: rgba(255, 255, 255, 0.66);
}

.ticket-status {
  margin-left: auto;
  font-size: 11.5px;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.24);
}

.ticket-code {
  margin: 26px 0 14px;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 20px;
  letter-spacing: 2.4px;
  font-weight: 700;
  text-align: center;
  padding: 14px 6px;
  border-radius: 12px;
  background: rgba(15, 12, 45, 0.22);
  border: 1px dashed rgba(255, 255, 255, 0.32);
}

.ticket-meta {
  display: flex;
  justify-content: space-between;
  font-size: 11.5px;
  color: rgba(255, 255, 255, 0.7);
}

.ticket-dash {
  margin: 18px 0 14px;
  border-top: 1px dashed rgba(255, 255, 255, 0.3);
}

.ticket-bottom {
  text-align: center;
  font-size: 12px;
  letter-spacing: 3px;
  color: rgba(255, 255, 255, 0.78);
}

.float-chip {
  position: absolute;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 7px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 9px 14px;
  font-size: 12.5px;
  font-weight: 600;
  color: #3c3c5e;
  box-shadow: 0 18px 36px -22px rgba(16, 24, 40, 0.5);
  animation: floaty 6s ease-in-out infinite;
}

.chip-a {
  top: 26px;
  left: 4px;
}

.chip-b {
  bottom: 26px;
  right: 0;
  animation-delay: -2.6s;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(2px);
  opacity: 0.55;
}

.orb-a {
  width: 230px;
  height: 230px;
  top: 6%;
  right: 4%;
  background: radial-gradient(circle at 35% 30%, #c4b5fd, #ede9fe 70%);
}

.orb-b {
  width: 150px;
  height: 150px;
  bottom: 2%;
  left: 8%;
  background: radial-gradient(circle at 35% 30%, #bae6fd, #e0f2fe 70%);
}

@keyframes floaty {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-9px);
  }
}

/* --------------------------------------------------------------------------
   区块 / 商品
   -------------------------------------------------------------------------- */

.section {
  padding: 64px 0;
}

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

.section-head h2 {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.3px;
}

.section-head p {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13.5px;
}

.search-box {
  position: relative;
  width: 260px;
}

.search-box input {
  width: 100%;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 11px;
  padding: 10px 14px 10px 38px;
  font-size: 13.5px;
  outline: none;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.search-box input:focus {
  border-color: #b9bcf5;
  box-shadow: 0 0 0 4px rgba(91, 91, 214, 0.1);
}

.search-box svg {
  position: absolute;
  left: 13px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: #98a2b3;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(258px, 1fr));
  gap: 22px;
}

.product-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: #dfe2f2;
}

.product-cover {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 152px;
  overflow: hidden;
  isolation: isolate;
}

.product-cover::before,
.product-cover::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
}

.product-cover::before {
  width: 150px;
  height: 150px;
  top: -64px;
  right: -40px;
}

.product-cover::after {
  width: 90px;
  height: 90px;
  bottom: -46px;
  left: -18px;
}

.product-emoji {
  font-size: 54px;
  filter: drop-shadow(0 12px 18px rgba(0, 0, 0, 0.18));
  transition: transform 0.24s ease;
}

.product-card:hover .product-emoji {
  transform: scale(1.07) rotate(-3deg);
}

.theme-violet {
  background: linear-gradient(135deg, #6d28d9, #a78bfa);
}

.theme-ocean {
  background: linear-gradient(135deg, #0369a1, #22d3ee);
}

.theme-sunset {
  background: linear-gradient(135deg, #ea580c, #fb7185);
}

.theme-forest {
  background: linear-gradient(135deg, #047857, #6ee7b7);
}

.theme-midnight {
  background: linear-gradient(135deg, #0f172a, #475569);
}

.theme-candy {
  background: linear-gradient(135deg, #be185d, #f9a8d4);
}

.cover-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 1;
  background: rgba(17, 24, 39, 0.42);
  border: 1px solid rgba(255, 255, 255, 0.32);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  backdrop-filter: blur(4px);
}

.cover-stock {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 1;
  background: rgba(255, 255, 255, 0.92);
  color: #374151;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 999px;
}

.cover-stock.low {
  background: rgba(255, 247, 237, 0.96);
  color: #b45309;
}

.product-body {
  padding: 16px 18px 18px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-cat {
  font-size: 11.5px;
  color: var(--muted);
  letter-spacing: 0.4px;
}

.product-body h3 {
  margin: 5px 0 3px;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.4;
}

.product-body h3 a:hover {
  color: var(--brand);
}

.product-body .sub {
  color: var(--muted);
  font-size: 12.5px;
  min-height: 21px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-foot {
  margin-top: auto;
  padding-top: 14px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}

.price {
  display: flex;
  align-items: baseline;
  gap: 7px;
  color: #d92d20;
  font-weight: 800;
  font-size: 21px;
  line-height: 1.2;
  letter-spacing: -0.3px;
}

.price .cur {
  font-size: 13px;
  font-weight: 700;
}

.price s {
  color: #98a2b3;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0;
}

.empty-state {
  padding: 64px 20px;
  text-align: center;
  color: var(--muted);
  background: #fff;
  border: 1px dashed #d9dced;
  border-radius: var(--radius);
}

.empty-state .big {
  font-size: 40px;
  margin-bottom: 10px;
}

.skeleton-card {
  height: 300px;
  border-radius: var(--radius);
  background: linear-gradient(100deg, #eef0f6 30%, #f8f9fc 48%, #eef0f6 66%);
  background-size: 240% 100%;
  animation: shimmer 1.3s infinite linear;
}

@keyframes shimmer {
  0% {
    background-position: 120% 0;
  }
  100% {
    background-position: -120% 0;
  }
}

/* 特性 */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.feature-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
}

.feature-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  font-size: 21px;
  border-radius: 13px;
  background: var(--brand-soft);
  margin-bottom: 16px;
}

.feature-card h3 {
  font-size: 16px;
  margin-bottom: 7px;
}

.feature-card p {
  color: var(--muted);
  font-size: 13.5px;
}

/* 步骤 */
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  counter-reset: step;
}

.step {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px 22px;
}

.step::before {
  counter-increment: step;
  content: "0" counter(step);
  display: block;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 1px;
  color: #b3b8d9;
  margin-bottom: 12px;
}

.step h3 {
  font-size: 15px;
  margin-bottom: 6px;
}

.step p {
  color: var(--muted);
  font-size: 13px;
}

/* FAQ */
.faq-list {
  display: grid;
  gap: 12px;
  max-width: 840px;
}

.faq-item {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 4px 20px;
}

.faq-item summary {
  cursor: pointer;
  list-style: none;
  padding: 15px 0;
  font-weight: 600;
  font-size: 14.5px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-size: 20px;
  font-weight: 400;
  color: #98a2b3;
  transition: transform 0.2s ease;
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
}

.faq-item p {
  padding: 0 0 16px;
  color: var(--muted);
  font-size: 13.5px;
}

/* --------------------------------------------------------------------------
   页脚
   -------------------------------------------------------------------------- */

.site-footer {
  margin-top: 24px;
  background: #0f1222;
  color: #a5aac2;
  padding: 52px 0 30px;
  font-size: 13px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 32px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.site-footer .brand-text strong {
  color: #fff;
}

.site-footer .brand-text small {
  color: #7f849e;
}

.footer-about {
  margin-top: 16px;
  max-width: 340px;
  line-height: 1.8;
  color: #8b90a8;
}

.site-footer h4 {
  color: #e7e9f3;
  font-size: 13.5px;
  margin-bottom: 12px;
}

.site-footer li {
  margin-bottom: 8px;
}

.site-footer a:hover {
  color: #fff;
}

.footer-bottom {
  padding-top: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  justify-content: space-between;
  color: #6f748c;
  font-size: 12.5px;
}

/* --------------------------------------------------------------------------
   通用组件：输入 / 表单 / 弹窗 / 提示
   -------------------------------------------------------------------------- */

.field {
  display: block;
  margin-bottom: 16px;
}

.field > span {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 7px;
  color: #344054;
}

.input,
.textarea,
.select {
  width: 100%;
  border: 1px solid #dfe2ee;
  background: #fff;
  border-radius: 10px;
  padding: 10px 13px;
  font-size: 14px;
  outline: none;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.input:focus,
.textarea:focus,
.select:focus {
  border-color: #b3b6f2;
  box-shadow: 0 0 0 4px rgba(91, 91, 214, 0.1);
}

.textarea {
  resize: vertical;
  min-height: 92px;
  line-height: 1.7;
}

.form-hint {
  font-size: 12px;
  color: var(--muted);
  margin-top: 7px;
}

.input-suffix {
  position: relative;
}

.input-suffix .input {
  padding-right: 46px;
}

.input-suffix span {
  position: absolute;
  right: 13px;
  top: 50%;
  transform: translateY(-50%);
  color: #98a2b3;
  font-size: 13px;
}

.modal-mask {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(15, 18, 34, 0.5);
  backdrop-filter: blur(3px);
  animation: fadeIn 0.16s ease;
}

.modal-card {
  width: min(520px, 100%);
  max-height: min(86vh, 720px);
  overflow: auto;
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 40px 90px -30px rgba(9, 11, 25, 0.6);
  animation: popIn 0.18s ease;
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px 0;
}

.modal-head h3 {
  font-size: 17px;
}

.modal-body {
  padding: 18px 24px 24px;
}

.modal-close {
  border: 0;
  background: #f2f4f7;
  width: 30px;
  height: 30px;
  border-radius: 9px;
  cursor: pointer;
  color: #667085;
  font-size: 16px;
  line-height: 1;
}

.modal-close:hover {
  background: #e8ebf1;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
}

@keyframes popIn {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.985);
  }
}

.toast-stack {
  position: fixed;
  z-index: 200;
  top: 86px;
  right: 22px;
  display: grid;
  gap: 10px;
  width: min(340px, calc(100vw - 32px));
}

.toast {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: #101828;
  color: #fff;
  border-radius: 12px;
  padding: 12px 15px;
  font-size: 13.5px;
  line-height: 1.55;
  box-shadow: 0 20px 40px -20px rgba(0, 0, 0, 0.55);
  animation: toastIn 0.22s ease;
}

.toast.success {
  background: #067a55;
}

.toast.error {
  background: #b42318;
}

.toast .ico {
  flex-shrink: 0;
}

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
}

/* 面包屑 */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 22px 0 0;
  font-size: 12.5px;
  color: var(--muted);
}

.breadcrumb a:hover {
  color: var(--ink);
}

.breadcrumb span.sep {
  color: #c3c7d6;
}

/* --------------------------------------------------------------------------
   商品详情
   -------------------------------------------------------------------------- */

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 30px;
  padding: 22px 0 64px;
  align-items: start;
}

.detail-cover {
  position: relative;
  display: grid;
  place-items: center;
  height: 340px;
  border-radius: 20px;
  overflow: hidden;
  isolation: isolate;
  box-shadow: var(--shadow);
}

.detail-cover::before {
  content: "";
  position: absolute;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.13);
  top: -120px;
  right: -80px;
}

.detail-cover::after {
  content: "";
  position: absolute;
  width: 190px;
  height: 190px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  bottom: -90px;
  left: -40px;
}

.detail-cover .product-emoji {
  font-size: 108px;
}

.detail-card {
  margin-top: 22px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 28px;
}

.detail-card h2 {
  font-size: 17px;
  margin-bottom: 14px;
}

.detail-desc {
  white-space: pre-line;
  color: #475467;
  font-size: 14px;
  line-height: 1.9;
}

.detail-card + .detail-card {
  margin-top: 18px;
}

.buy-panel {
  position: sticky;
  top: 96px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 26px;
  box-shadow: var(--shadow);
}

.buy-panel .cat {
  font-size: 12px;
  color: var(--muted);
}

.buy-panel h1 {
  font-size: 23px;
  line-height: 1.35;
  margin: 6px 0 4px;
  letter-spacing: -0.2px;
}

.buy-panel .sub {
  color: var(--muted);
  font-size: 13.5px;
}

.buy-price {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 18px 0 6px;
  padding: 16px 18px;
  border-radius: 13px;
  background: linear-gradient(120deg, #fff5f4, #fff 70%);
  border: 1px solid #ffe1dd;
  color: #d92d20;
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.buy-price .cur {
  font-size: 16px;
}

.buy-price s {
  color: #98a2b3;
  font-size: 13px;
  font-weight: 500;
}

.buy-price .save {
  margin-left: auto;
  font-size: 11.5px;
  font-weight: 700;
  color: #b42318;
  background: #fee4e2;
  border-radius: 999px;
  padding: 3px 9px;
}

.stock-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12.5px;
  color: var(--muted);
  margin-bottom: 18px;
}

.qty {
  display: inline-flex;
  align-items: center;
  border: 1px solid #dfe2ee;
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}

.qty button {
  width: 36px;
  height: 38px;
  border: 0;
  background: #f8f9fc;
  font-size: 17px;
  color: #475467;
  cursor: pointer;
}

.qty button:hover:not(:disabled) {
  background: #eef0f7;
}

.qty button:disabled {
  color: #c3c7d6;
  cursor: not-allowed;
}

.qty input {
  width: 48px;
  height: 38px;
  border: 0;
  border-inline: 1px solid #dfe2ee;
  text-align: center;
  font-size: 14px;
  font-weight: 600;
  outline: none;
}

.pay-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(104px, 1fr));
  gap: 10px;
}

.pay-tile {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #dfe2ee;
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  background: #fff;
  transition: all 0.16s ease;
}

.pay-tile input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.pay-tile .mark {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  font-size: 12px;
  color: #fff;
  background: #1677ff;
  font-weight: 700;
}

.pay-tile[data-method="wxpay"] .mark {
  background: #07c160;
}

.pay-tile[data-method="qqpay"] .mark {
  background: #12b7f5;
}

.pay-tile:hover {
  border-color: #c9cce0;
}

.pay-tile:has(input:checked) {
  border-color: var(--brand);
  background: #f6f6ff;
  box-shadow: 0 0 0 3px rgba(91, 91, 214, 0.1);
}

.buy-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin: 20px 0 14px;
  font-size: 13px;
  color: var(--muted);
}

.buy-total b {
  font-size: 24px;
  color: #d92d20;
  letter-spacing: -0.4px;
}

.buy-total b .cur {
  font-size: 13px;
}

.safe-note {
  margin-top: 14px;
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  color: var(--muted);
  justify-content: center;
}

/* --------------------------------------------------------------------------
   订单页
   -------------------------------------------------------------------------- */

.order-page {
  padding: 30px 0 70px;
}

.order-shell {
  width: min(760px, 100%);
  margin-inline: auto;
}

.order-head {
  text-align: center;
  padding: 18px 0 26px;
}

.order-head .icon {
  width: 62px;
  height: 62px;
  margin: 0 auto 14px;
  display: grid;
  place-items: center;
  font-size: 30px;
  border-radius: 20px;
  background: var(--brand-soft);
}

.order-head.paid .icon {
  background: var(--success-soft);
}

.order-head.cancelled .icon {
  background: #f2f4f7;
}

.order-head h1 {
  font-size: 24px;
  letter-spacing: -0.3px;
}

.order-head p {
  color: var(--muted);
  font-size: 13.5px;
  margin-top: 6px;
}

.order-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.order-card + .order-card {
  margin-top: 18px;
}

.order-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 17px 24px;
  border-bottom: 1px solid #f0f1f7;
  font-size: 14px;
  font-weight: 700;
}

.order-card-body {
  padding: 20px 24px 24px;
}

.order-meta {
  display: grid;
  gap: 0;
}

.order-meta > div {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 10px 0;
  font-size: 13.5px;
  border-bottom: 1px dashed #f0f1f7;
}

.order-meta > div:last-child {
  border-bottom: 0;
}

.order-meta dt {
  color: var(--muted);
  flex-shrink: 0;
}

.order-meta dd {
  margin: 0;
  text-align: right;
  word-break: break-all;
}

.order-meta .amount {
  color: #d92d20;
  font-weight: 800;
  font-size: 18px;
}

.copy-text {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.copy-btn {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 6px;
  padding: 1px 7px;
  font-size: 11.5px;
  color: var(--muted);
  cursor: pointer;
}

.copy-btn:hover {
  border-color: #c9cce0;
  color: var(--ink);
}

.pay-panel {
  background:
    radial-gradient(600px 200px at 100% 0%, rgba(91, 91, 214, 0.08), transparent 70%),
    #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  margin-top: 18px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.pay-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  border-bottom: 1px dashed #e4e6f0;
  font-size: 13px;
  color: var(--muted);
}

.demo-badge {
  font-size: 11px;
  font-weight: 700;
  color: var(--warn);
  background: var(--warn-soft);
  border: 1px solid #f6e3b8;
  border-radius: 999px;
  padding: 2px 9px;
}

.pay-amount {
  text-align: center;
  padding: 28px 20px 8px;
}

.pay-amount small {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.pay-amount strong {
  display: block;
  font-size: 44px;
  font-weight: 800;
  letter-spacing: -1.5px;
  color: #d92d20;
  margin-top: 4px;
}

.pay-amount strong .cur {
  font-size: 20px;
  margin-right: 2px;
}

.pay-tip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  color: #667085;
  font-size: 13px;
  padding: 6px 20px 22px;
  text-align: center;
}

.pay-actions {
  padding: 0 24px 26px;
  display: grid;
  gap: 10px;
}

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

.cards-list {
  display: grid;
  gap: 10px;
}

.card-key {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #f8f9fc;
  border: 1px solid #e9ebf3;
  border-radius: 10px;
  padding: 12px 14px;
}

.card-key .idx {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 7px;
  background: #fff;
  border: 1px solid #e4e6f0;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--muted);
}

.card-key code {
  flex: 1;
  font-size: 14.5px;
  font-weight: 700;
  letter-spacing: 1px;
  word-break: break-all;
  color: #1d2939;
}

.delivery-note {
  display: flex;
  gap: 10px;
  background: #f8f9fc;
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.7;
  margin-top: 16px;
}

.order-foot-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-top: 24px;
  font-size: 13px;
  color: var(--muted);
}

.order-foot-links a:hover {
  color: var(--brand);
}

.lookup-card {
  width: min(480px, 100%);
  margin: 0 auto;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 30px;
  box-shadow: var(--shadow);
}

.lookup-card h1 {
  font-size: 21px;
  margin-bottom: 6px;
}

.lookup-card > p {
  color: var(--muted);
  font-size: 13.5px;
  margin-bottom: 22px;
}

/* --------------------------------------------------------------------------
   响应式
   -------------------------------------------------------------------------- */

@media (max-width: 1024px) {
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 40px;
    padding: 50px 0 56px;
  }

  .hero-art {
    min-height: 320px;
  }

  .detail-grid {
    grid-template-columns: 1fr;
  }

  /* 移动端把购买面板放到封面之后、详情之前，避免用户先滑过整篇详情 */
  .detail-left {
    display: contents;
  }

  .detail-cover {
    order: 1;
  }

  .buy-panel {
    order: 2;
    position: static;
  }

  .detail-card {
    order: 3;
    margin-top: 0;
  }

  .detail-card + .detail-card {
    margin-top: 0;
  }

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

  .feature-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 860px) {
  .site-nav {
    display: none;
  }

  .section {
    padding: 48px 0;
  }

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

  .search-box {
    width: 100%;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .site-footer {
    padding-top: 40px;
  }
}

@media (max-width: 640px) {
  .container {
    width: min(1160px, 100% - 28px);
  }

  .header-inner {
    height: 64px;
    gap: 14px;
  }

  .brand-text small {
    display: none;
  }

  .header-cta {
    margin-left: auto;
  }

  .hero-inner {
    padding: 36px 0 44px;
  }

  .hero-art {
    min-height: 260px;
  }

  .ticket {
    padding: 20px 18px 16px;
    transform: rotate(-2deg);
  }

  .ticket-code {
    font-size: 15px;
    letter-spacing: 1.4px;
  }

  .ticket::before,
  .ticket::after {
    top: 128px;
  }

  .float-chip {
    display: none;
  }

  .chip-a {
    left: -4px;
    top: 4px;
  }

  .chip-b {
    right: -4px;
    bottom: 4px;
  }

  .hero-art {
    min-height: 250px;
  }

  .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 14px;
  }

  .product-cover {
    height: 112px;
  }

  .product-emoji {
    font-size: 40px;
  }

  .product-body {
    padding: 13px 14px 15px;
  }

  .product-body h3 {
    font-size: 14.5px;
  }

  .product-body .sub {
    display: none;
  }

  .price {
    font-size: 18px;
  }

  .steps {
    grid-template-columns: 1fr;
  }

  .detail-cover {
    height: 240px;
  }

  .detail-cover .product-emoji {
    font-size: 84px;
  }

  .detail-card {
    padding: 20px;
  }

  .buy-panel {
    padding: 20px;
  }

  .order-card-head,
  .order-card-body {
    padding-inline: 18px;
  }

  .pay-actions .row {
    grid-template-columns: 1fr;
  }

  .toast-stack {
    top: auto;
    bottom: 18px;
    right: 16px;
  }

  .footer-bottom {
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  html {
    scroll-behavior: auto;
  }
}
