/* ==========================================================================
   木不易折 · DIGITAL ARCHIVE — Dark Tech Studio Design System (v5.0)
   Obsidian Glass · Aurora Nebula · Luminous Hairlines · Zero External CDN
   ========================================================================== */

:root {
  --bg: #070a12;
  --bg-deep: #04060c;
  --bg-surface: rgba(15, 21, 36, 0.76);
  --bg-surface-strong: rgba(20, 28, 48, 0.92);
  --bg-solid: #111827;
  --bg-subtle: rgba(148, 163, 184, 0.12);
  --ink: #f1f5f9;
  --ink-soft: #94a3b8;
  --ink-muted: #64748b;
  --cyan: #38bdf8;
  --indigo: #818cf8;
  --accent: #ff5b45;
  --accent-soft: rgba(56, 189, 248, 0.14);
  --emerald: #34d399;
  --line: rgba(148, 163, 184, 0.15);
  --line-strong: rgba(148, 163, 184, 0.28);
  --line-glow: rgba(56, 189, 248, 0.45);
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 999px;
  --shadow-xs: 0 2px 10px rgba(0, 0, 0, 0.3);
  --shadow-sm: 0 12px 30px -8px rgba(0, 0, 0, 0.48), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  --shadow-md: 0 24px 56px -14px rgba(0, 0, 0, 0.65), 0 0 28px -10px rgba(56, 189, 248, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  --shadow-lg: 0 32px 72px -16px rgba(0, 0, 0, 0.78), 0 0 40px -12px rgba(99, 102, 241, 0.3);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --font-sans: "PingFang SC", "HarmonyOS Sans SC", "Hiragino Sans GB", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-serif: "Songti SC", "Noto Serif SC", Georgia, "Times New Roman", serif;
  --font-mono: "SFMono-Regular", ui-monospace, "JetBrains Mono", Menlo, Consolas, monospace;
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: dark;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: var(--bg);
  background-image:
    radial-gradient(ellipse 68% 46% at 14% 0%, rgba(56, 189, 248, 0.16), transparent 62%),
    radial-gradient(ellipse 58% 42% at 86% 6%, rgba(129, 140, 248, 0.16), transparent 58%),
    radial-gradient(ellipse 50% 40% at 52% 58%, rgba(255, 91, 69, 0.07), transparent 65%),
    linear-gradient(rgba(148, 163, 184, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.045) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 100% 100%, 44px 44px, 44px 44px;
  background-attachment: scroll, scroll, scroll, fixed, fixed;
  color: var(--ink);
  font: 16px/1.68 var(--font-sans);
  overflow-x: clip;
  position: relative;
}

/* Interactive neural constellation canvas injected by JS */
.bg-tech-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  opacity: 0.78;
}

#main,
.mast-wrap,
footer,
.preview-banner {
  position: relative;
  z-index: 2;
}

#main {
  flex: 1;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.22s var(--ease-out);
}

a:hover {
  text-decoration: none;
}

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

/* ---------- Scroll Progress Neon Bar ---------- */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--cyan) 0%, var(--indigo) 52%, var(--accent) 100%);
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.75);
  transform: scaleX(0);
  transform-origin: left center;
  z-index: 60;
  pointer-events: none;
  will-change: transform;
}

/* ---------- Buttons & Interactive Controls ---------- */
button,
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(30, 41, 59, 0.7);
  color: var(--ink);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-pill);
  padding: 11px 22px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 650;
  letter-spacing: 0.01em;
  overflow: hidden;
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-xs);
  transition:
    transform 0.28s var(--ease-out),
    background-color 0.25s var(--ease-out),
    border-color 0.25s var(--ease-out),
    box-shadow 0.28s var(--ease-out),
    color 0.25s var(--ease-out);
}

.btn:hover,
button:hover {
  background: rgba(51, 65, 85, 0.85);
  border-color: var(--cyan);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 10px 26px -8px rgba(56, 189, 248, 0.35);
}

button:active,
.btn:active {
  transform: translateY(1px) scale(0.98);
}

.primary,
.gold {
  color: #06101d;
  background: linear-gradient(135deg, #38bdf8 0%, #818cf8 100%);
  border-color: transparent;
  font-weight: 750;
  box-shadow: 0 10px 28px -8px rgba(56, 189, 248, 0.55);
}

.primary::before,
.gold::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 20%, rgba(255, 255, 255, 0.42) 50%, transparent 80%);
  transform: translateX(-130%);
  transition: transform 0.65s var(--ease-out);
  pointer-events: none;
}

.primary:hover,
.gold:hover {
  background: linear-gradient(135deg, #60d5ff 0%, #9b9eff 100%);
  border-color: transparent;
  color: #040812;
  box-shadow: 0 14px 34px -6px rgba(56, 189, 248, 0.7);
}

.primary:hover::before,
.gold:hover::before {
  transform: translateX(130%);
}

.btn-ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  transform: scale(0);
  pointer-events: none;
  animation: ripple-expand 0.55s var(--ease-out) forwards;
}

@keyframes ripple-expand {
  to {
    transform: scale(3.2);
    opacity: 0;
  }
}

/* ---------- Layout Shell & Shared Flex ---------- */
.shell {
  width: min(1320px, 90%);
  margin-inline: auto;
}

.mast,
.footrow,
.brand,
.mast nav,
.bag,
.sectionhead,
.cardtitle,
.cardmeta,
.actions,
.buyline,
.turn,
.pills,
.aboutstrip,
.search,
.line,
.gallerynav {
  display: flex;
  align-items: center;
}

/* ---------- Sticky Obsidian-Glass Header ---------- */
.mast-wrap {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(7, 10, 18, 0.68);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  transition:
    background-color 0.3s var(--ease-out),
    box-shadow 0.3s var(--ease-out),
    border-color 0.3s var(--ease-out);
}

.mast-wrap.is-scrolled {
  background: rgba(7, 10, 18, 0.88);
  border-bottom-color: rgba(56, 189, 248, 0.22);
  box-shadow: 0 12px 36px -10px rgba(0, 0, 0, 0.65);
}

.mast {
  min-height: 76px;
  gap: 28px;
  position: relative;
  z-index: 5;
  transition: min-height 0.3s var(--ease-out);
}

.mast-wrap.is-scrolled .mast {
  min-height: 64px;
}

.brand {
  gap: 10px;
  font-size: 22px;
  font-weight: 850;
  letter-spacing: -0.04em;
  color: #ffffff;
  transition: transform 0.25s var(--ease-out);
}

.brand:hover {
  transform: translateY(-1px);
}

.brand small {
  font: 700 10px/1.15 var(--font-mono);
  letter-spacing: 0.14em;
  color: var(--cyan);
  margin-left: 2px;
  padding-left: 10px;
  border-left: 1px solid var(--line-strong);
}

.mark {
  width: 34px;
  height: 34px;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 0 14px rgba(255, 91, 69, 0.35);
  transition: transform 0.45s var(--ease-spring);
}

.brand:hover .mark {
  transform: rotate(-8deg) scale(1.08);
}

.mast nav {
  margin-left: auto;
  gap: 6px;
  font-size: 14px;
  font-weight: 600;
}

.mast nav a {
  position: relative;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  color: var(--ink-soft);
  transition:
    color 0.22s var(--ease-out),
    background-color 0.22s var(--ease-out);
}

.mast nav a:hover {
  color: #ffffff;
  background: rgba(148, 163, 184, 0.1);
}

.mast nav a[aria-current] {
  color: #ffffff;
  background: rgba(56, 189, 248, 0.14);
  box-shadow: inset 0 0 0 1px rgba(56, 189, 248, 0.28);
}

.mast nav a[aria-current]::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 4px;
  width: 16px;
  height: 2.5px;
  border-radius: 99px;
  background: var(--cyan);
  box-shadow: 0 0 8px var(--cyan);
  transform: translateX(-50%);
}

.bag {
  gap: 10px;
  font-size: 14px;
  font-weight: 700;
  padding: 8px 14px 8px 16px;
  border-radius: var(--radius-pill);
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-xs);
  transition:
    transform 0.25s var(--ease-out),
    border-color 0.25s var(--ease-out),
    box-shadow 0.25s var(--ease-out);
}

.bag:hover {
  transform: translateY(-2px);
  border-color: var(--cyan);
  box-shadow: 0 8px 22px -6px rgba(56, 189, 248, 0.35);
}

.bag b {
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--cyan), var(--indigo));
  color: #050b16;
  min-width: 24px;
  height: 24px;
  padding: 0 6px;
  font: 800 12px/1 var(--font-mono);
  font-variant-numeric: tabular-nums;
  transition: transform 0.3s var(--ease-spring);
}

.bag.pulse b {
  background: linear-gradient(135deg, var(--accent), #fb923c);
  color: #ffffff;
  animation: bag-pop 0.5s var(--ease-spring);
}

@keyframes bag-pop {
  0% { transform: scale(1); }
  40% { transform: scale(1.42) rotate(-8deg); }
  70% { transform: scale(0.92) rotate(4deg); }
  100% { transform: scale(1) rotate(0); }
}

.skip {
  position: fixed;
  top: -80px;
  left: 16px;
  z-index: 80;
  background: var(--cyan);
  color: #050b16;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  font-weight: 700;
}

.skip:focus {
  top: 12px;
}

a:focus-visible,
button:focus-visible,
summary:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

/* ---------- Masthead Hero Header ---------- */
.masthead {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding: 44px 0 30px;
  gap: 24px;
  animation: hero-fade-up 0.7s var(--ease-out) both;
}

.masthead h1 {
  font-size: clamp(44px, 6vw, 84px);
  line-height: 1.06;
  letter-spacing: -0.055em;
  font-weight: 900;
  margin: 0;
  color: #ffffff;
  text-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
}

.masthead h1 > span {
  background: linear-gradient(110deg, #38bdf8 0%, #818cf8 55%, #ff6b57 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.masthead .dot {
  color: var(--cyan);
  -webkit-text-fill-color: var(--cyan);
  display: inline-block;
  text-shadow: 0 0 18px rgba(56, 189, 248, 0.8);
  animation: dot-pulse 2.6s ease-in-out infinite;
}

@keyframes dot-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.22); opacity: 0.5; }
}

.masthead p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 15px;
  max-width: 380px;
  line-height: 1.75;
  text-align: right;
}

.masthead p a.back {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 6px;
  color: var(--cyan);
  font-weight: 700;
}

.masthead p a.back:hover {
  transform: translateX(3px);
  color: #7dd3fc;
}

.kicker,
.folio {
  font: 700 11px/1.5 var(--font-mono);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--cyan);
}

.kicker i,
.folio i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cyan);
  display: inline-block;
  box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.2), 0 0 12px var(--cyan);
  animation: kicker-pulse 2.4s ease-in-out infinite;
}

@keyframes kicker-pulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.25), 0 0 10px var(--cyan); }
  50% { box-shadow: 0 0 0 8px rgba(56, 189, 248, 0.04), 0 0 16px var(--cyan); }
}

/* ---------- Hero 3D Holographic Shelf (Fixed Height · Zero Overlap) ---------- */
.shelf {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  min-height: 495px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: var(--radius-lg);
  background: var(--bg-surface);
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  isolation: isolate;
  animation: hero-fade-up 0.8s var(--ease-out) 0.08s both;
}

.display {
  --stage-glow: rgba(255, 110, 72, 0.26);
  --stage-glow-2: rgba(99, 102, 241, 0.22);
  --spot-x: 50%;
  --spot-y: 50%;
  background:
    radial-gradient(380px circle at var(--spot-x) var(--spot-y), rgba(56, 189, 248, 0.22), transparent 60%),
    radial-gradient(circle at 25% 25%, var(--stage-glow), transparent 58%),
    radial-gradient(circle at 80% 75%, var(--stage-glow-2), transparent 60%),
    linear-gradient(145deg, #0b1120 0%, #11192e 100%);
  position: relative;
  overflow: hidden;
  min-height: 495px;
  display: grid;
  place-items: center;
  cursor: grab;
  transition: background 0.55s var(--ease-out);
  user-select: none;
  border-right: 1px solid rgba(148, 163, 184, 0.12);
}

.display:active {
  cursor: grabbing;
}

.shelf[data-active="0"] .display {
  --stage-glow: rgba(251, 146, 60, 0.28);
  --stage-glow-2: rgba(99, 102, 241, 0.24);
}

.shelf[data-active="1"] .display {
  --stage-glow: rgba(244, 63, 94, 0.26);
  --stage-glow-2: rgba(56, 189, 248, 0.24);
}

.shelf[data-active="2"] .display {
  --stage-glow: rgba(56, 189, 248, 0.3);
  --stage-glow-2: rgba(129, 140, 248, 0.26);
}

.stagegrid {
  position: absolute;
  inset: 60% -25% -45%;
  background-image:
    repeating-linear-gradient(0deg, transparent 0 28px, rgba(56, 189, 248, 0.22) 28px 29px),
    repeating-linear-gradient(90deg, transparent 0 42px, rgba(129, 140, 248, 0.14) 42px 43px);
  transform: perspective(500px) rotateX(62deg) rotate(-6deg);
  pointer-events: none;
  mask-image: linear-gradient(to bottom, transparent 0%, black 40%, black 100%);
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 40%, black 100%);
}

.books {
  position: relative;
  width: 44%;
  max-width: 232px;
  aspect-ratio: 880 / 1136;
  margin: 44px 0;
  transform-style: flat;
}

.book {
  display: block;
  position: absolute;
  inset: 0;
  border-radius: 8px 12px 12px 8px;
  overflow: hidden;
  cursor: pointer;
  will-change: transform, filter;
  transition:
    transform 0.58s var(--ease-out),
    filter 0.4s var(--ease-out),
    box-shadow 0.4s var(--ease-out);
  box-shadow:
    -2px 0 0 rgba(255, 255, 255, 0.5),
    4px 5px 0 #d6d3c9,
    0 24px 50px -10px rgba(0, 0, 0, 0.72),
    0 0 28px -6px rgba(56, 189, 248, 0.28);
}

.book::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    125deg,
    rgba(255, 255, 255, 0.28) 0%,
    rgba(255, 255, 255, 0.04) 38%,
    transparent 60%,
    rgba(0, 0, 0, 0.16) 100%
  );
  pointer-events: none;
}

.book img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background: #1e293b;
}

.pos0 {
  transform: translate(-4%, 0) rotate(-4deg) scale(1);
  z-index: 4;
  filter: saturate(1.06);
}

.pos1 {
  transform: translate(52%, 4%) rotate(10deg) scale(0.84);
  z-index: 2;
  filter: brightness(0.82) saturate(0.88);
}

.pos2 {
  transform: translate(-54%, 6%) rotate(-14deg) scale(0.8);
  z-index: 1;
  filter: brightness(0.76) saturate(0.84);
}

.pos0:hover {
  transform: translate(-4%, -8px) rotate(-1.5deg) scale(1.03);
  box-shadow:
    -2px 0 0 rgba(255, 255, 255, 0.6),
    5px 6px 0 #d6d3c9,
    0 30px 60px -10px rgba(0, 0, 0, 0.82),
    0 0 38px -4px rgba(56, 189, 248, 0.45);
}

.pos1:hover {
  transform: translate(58%, -2%) rotate(12deg) scale(0.88);
  filter: brightness(0.95);
}

.pos2:hover {
  transform: translate(-59%, 0%) rotate(-16deg) scale(0.84);
  filter: brightness(0.95);
}

.stage-hint {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  background: rgba(15, 23, 42, 0.78);
  backdrop-filter: blur(10px);
  font: 600 11px/1.4 var(--font-mono);
  letter-spacing: 0.05em;
  color: #cbd5e1;
  border: 1px solid rgba(56, 189, 248, 0.25);
  pointer-events: none;
  white-space: nowrap;
}

.shelf-info {
  padding: clamp(28px, 3.4vw, 48px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 495px;
  position: relative;
}

.shelf-info [data-edition] {
  min-height: 320px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.shelf-info h2,
.productinfo h1 {
  font-size: clamp(28px, 2.8vw, 42px);
  line-height: 1.18;
  letter-spacing: -0.035em;
  font-weight: 850;
  color: #ffffff;
  margin: 8px 0 6px;
}

.shelf-info em,
.productinfo em {
  display: inline-block;
  font: italic 17px/1.45 var(--font-serif);
  color: #cbd5e1;
  margin-bottom: 6px;
}

.shelf-info [data-edition] > p:not(.meta) {
  margin: 8px 0 0;
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.72;
  min-height: 76px;
}

.meta,
.cardmeta,
small,
.back {
  color: var(--ink-soft);
}

.shelf-info .meta {
  margin: 10px 0 0;
  font-size: 13px;
  font-weight: 650;
  color: var(--cyan);
  letter-spacing: 0.03em;
}

.buyline {
  gap: 14px;
  margin: 18px 0;
  align-items: baseline;
}

.buyline strong,
.price {
  font-family: var(--font-mono);
  font-size: 34px;
  font-weight: 850;
  line-height: 1;
  letter-spacing: -0.03em;
  color: #ffffff;
  font-variant-numeric: tabular-nums;
}

.buyline del {
  font-family: var(--font-mono);
  color: var(--ink-muted);
  font-size: 16px;
}

.buyline small {
  padding: 4px 11px;
  border-radius: var(--radius-pill);
  background: rgba(56, 189, 248, 0.14);
  color: #7dd3fc;
  border: 1px solid rgba(56, 189, 248, 0.25);
  font-size: 12px;
  font-weight: 650;
}

.feature-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.turn {
  gap: 10px;
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font: 700 12px var(--font-mono);
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}

.turn-progress {
  flex: 1;
  height: 3.5px;
  border-radius: 99px;
  background: rgba(148, 163, 184, 0.16);
  overflow: hidden;
  margin-inline: 8px;
  min-width: 48px;
}

.turn-progress-bar {
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, var(--cyan), var(--indigo), var(--accent));
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.65);
  transform-origin: left center;
  transform: scaleX(0);
}

.turn button {
  border-radius: 50%;
  padding: 0;
  width: 38px;
  height: 38px;
  font-size: 15px;
  background: rgba(30, 41, 59, 0.8);
  border: 1px solid var(--line-strong);
  color: #f8fafc;
}

.turn button:hover {
  background: var(--cyan);
  color: #050b16;
  border-color: var(--cyan);
}

/* ---------- Section Headers & Category Pill Rail ---------- */
.sectionhead,
.aboutstrip,
.footrow,
.cardtitle,
.cardmeta {
  justify-content: space-between;
  gap: 14px;
}

.collection,
.inner {
  padding-block: 56px;
}

.sectionhead h2,
.inner > h1,
.inner > header h1,
.detailsbody h2,
.aboutstrip h2 {
  font-size: clamp(28px, 3.2vw, 46px);
  line-height: 1.16;
  letter-spacing: -0.04em;
  font-weight: 850;
  color: #ffffff;
  margin: 8px 0 12px;
}

.sectionhead a,
.aboutstrip a,
.back,
.quick,
.panel a {
  font-size: 14px;
  font-weight: 650;
}

.sectionhead a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid var(--line-strong);
  color: #e2e8f0;
  transition: transform 0.25s var(--ease-out), border-color 0.25s, color 0.25s;
}

.sectionhead a:hover {
  transform: translateY(-2px);
  border-color: var(--cyan);
  color: var(--cyan);
}

.pills {
  position: relative;
  gap: 6px;
  flex-wrap: wrap;
  background: rgba(15, 21, 36, 0.78);
  backdrop-filter: blur(12px);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  margin: 18px 0 28px;
  padding: 7px;
  box-shadow: var(--shadow-xs);
}

.pills a {
  position: relative;
  z-index: 2;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-soft);
  transition: color 0.25s var(--ease-out), background-color 0.25s var(--ease-out);
}

.pills a:hover {
  color: #ffffff;
}

.pills a.selected,
.pills a[aria-current] {
  color: #050b16;
  background: linear-gradient(135deg, var(--cyan), #7dd3fc);
  font-weight: 750;
}

.pills.has-slider a.selected,
.pills.has-slider a[aria-current] {
  background: transparent;
}

.pill-slider {
  position: absolute;
  z-index: 1;
  top: 0;
  left: 0;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--cyan) 0%, #818cf8 100%);
  box-shadow: 0 6px 20px -4px rgba(56, 189, 248, 0.55);
  pointer-events: none;
  transition:
    transform 0.36s var(--ease-out),
    width 0.36s var(--ease-out),
    height 0.36s var(--ease-out),
    opacity 0.2s;
}

/* ---------- Holographic Glass Product Card Grid ---------- */
.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 26px;
}

.card {
  position: relative;
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: var(--bg-surface);
  backdrop-filter: blur(14px);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 14px 14px 20px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition:
    transform 0.38s var(--ease-out),
    box-shadow 0.38s var(--ease-out),
    border-color 0.35s var(--ease-out),
    background-color 0.35s var(--ease-out);
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    420px circle at var(--mx, 50%) var(--my, 0%),
    rgba(56, 189, 248, 0.14),
    transparent 55%
  );
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s var(--ease-out);
}

.card:hover {
  transform: translateY(-7px);
  background: var(--bg-surface-strong);
  border-color: rgba(56, 189, 248, 0.42);
  box-shadow: var(--shadow-md);
}

.card:hover::before {
  opacity: 1;
}

.cover,
.jacket {
  position: relative;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 24% 20%, rgba(255, 255, 255, 0.16), transparent 55%),
    var(--wash, linear-gradient(135deg, #162038 0%, #0f172a 100%));
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
  perspective: 900px;
}

.cover::after,
.jacket::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    320px circle at var(--gx, 50%) var(--gy, 50%),
    rgba(56, 189, 248, 0.32),
    transparent 60%
  );
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.32s var(--ease-out);
}

.cover:hover::after,
.jacket:hover::after {
  opacity: 1;
}

/* Deep luminous holographic tones tuned for dark studio */
.tone1 { --wash: linear-gradient(140deg, #321922 0%, #16182c 100%); }
.tone2 { --wash: linear-gradient(140deg, #152642 0%, #10182b 100%); }
.tone3 { --wash: linear-gradient(140deg, #332714 0%, #151a2b 100%); }
.tone4 { --wash: linear-gradient(140deg, #271b3f 0%, #13182b 100%); }
.tone5 { --wash: linear-gradient(140deg, #132d3b 0%, #101829 100%); }
.tone6 { --wash: linear-gradient(140deg, #12312e 0%, #0f1928 100%); }

.cover {
  height: clamp(210px, 19vw, 275px);
  padding: 22px;
}

.cover img,
.jacket > img {
  height: 100%;
  max-width: 82%;
  min-height: 0;
  object-fit: contain;
  border-radius: 6px;
  filter: drop-shadow(0 18px 24px rgba(0, 0, 0, 0.58));
  transform: rotate(-3deg);
  transition:
    transform 0.45s var(--ease-out),
    filter 0.45s var(--ease-out);
  will-change: transform;
}

.collection .card:nth-child(3n + 2) .cover img {
  transform: rotate(3deg);
}

.card:hover .cover img {
  transform: rotate(0deg) translateY(-6px) scale(1.05);
  filter: drop-shadow(0 24px 32px rgba(0, 0, 0, 0.72));
}

.cardmeta {
  font-size: 12px;
  font-weight: 600;
  margin: 16px 6px 4px;
  color: var(--cyan);
}

.cardmeta span {
  padding: 2px 9px;
  border-radius: var(--radius-pill);
  background: rgba(148, 163, 184, 0.14);
  color: #cbd5e1;
  font-size: 11px;
}

.cardtitle {
  margin: 0 6px;
  align-items: baseline;
}

.cardtitle h3 {
  font-size: 19px;
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: -0.02em;
  color: #ffffff;
  margin: 4px 0;
}

.cardtitle h3 a:hover {
  color: var(--cyan);
}

.cardtitle strong {
  font-family: var(--font-mono);
  font-size: 18px;
  font-weight: 800;
  white-space: nowrap;
  color: #7dd3fc;
  font-variant-numeric: tabular-nums;
}

.card p {
  margin: 6px 6px 16px;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.65;
  flex: 1;
}

.card form {
  margin: 0 6px;
}

.quick {
  padding: 9px 16px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(56, 189, 248, 0.35);
  background: rgba(56, 189, 248, 0.08);
  font-size: 13px;
  font-weight: 700;
  color: #e0f2fe;
  box-shadow: none;
  transition:
    background-color 0.25s var(--ease-out),
    color 0.25s var(--ease-out),
    border-color 0.25s var(--ease-out),
    transform 0.25s var(--ease-out),
    box-shadow 0.25s var(--ease-out);
}

.quick:hover {
  background: linear-gradient(135deg, var(--cyan), var(--indigo));
  border-color: transparent;
  color: #050b16;
  transform: translateY(-1px);
  box-shadow: 0 10px 24px -6px rgba(56, 189, 248, 0.55);
}

.quick.is-added {
  background: var(--emerald);
  border-color: var(--emerald);
  color: #04150e;
}

/* ---------- Bundle Discount Section (整套组合特惠) ---------- */
.bundle-section {
  padding-block: 14px 56px;
}

.bundle-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  margin-top: 20px;
}

.bundle-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 26px 24px 24px;
  border-radius: var(--radius-lg);
  background: var(--bg-surface);
  backdrop-filter: blur(16px);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out), border-color 0.3s;
}

.bundle-card.is-featured {
  background:
    radial-gradient(circle at 80% 0%, rgba(56, 189, 248, 0.2), transparent 55%),
    linear-gradient(155deg, rgba(22, 32, 58, 0.94) 0%, rgba(13, 19, 36, 0.96) 100%);
  border-color: rgba(56, 189, 248, 0.48);
  box-shadow: var(--shadow-md);
}

.bundle-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: var(--cyan);
}

.bundle-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: fit-content;
  padding: 4px 11px;
  border-radius: var(--radius-pill);
  background: rgba(56, 189, 248, 0.14);
  color: #7dd3fc;
  border: 1px solid rgba(56, 189, 248, 0.26);
  font-size: 12px;
  font-weight: 700;
}

.bundle-card.is-featured .bundle-badge {
  background: rgba(255, 91, 69, 0.18);
  color: #ff9c8a;
  border-color: rgba(255, 91, 69, 0.35);
}

.bundle-card h3 {
  font-size: 21px;
  font-weight: 850;
  color: #ffffff;
  margin: 14px 0 6px;
  line-height: 1.3;
}

.bundle-card > p {
  margin: 0 0 14px;
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.65;
}

.bundle-list {
  list-style: none;
  padding: 0;
  margin: 0 0 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.bundle-list li {
  font-size: 13.5px;
  padding-left: 20px;
  position: relative;
  color: #e2e8f0;
}

.bundle-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--cyan);
  font-weight: 800;
}

.bundle-price {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 16px;
}

.bundle-price strong {
  font-family: var(--font-mono);
  font-size: 30px;
  font-weight: 850;
  color: #ffffff;
}

.bundle-price del {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--ink-muted);
}

.bundle-save {
  margin-left: auto;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  background: rgba(52, 211, 153, 0.15);
  color: var(--emerald);
  border: 1px solid rgba(52, 211, 153, 0.3);
  font-size: 12px;
  font-weight: 700;
}

/* ---------- Roadmap / Directory Guide Cards ---------- */
.guide-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  margin-top: 22px;
}

.guide-card {
  background: var(--bg-surface);
  backdrop-filter: blur(14px);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-sm);
}

.guide-card h2,
.guide-card h3 {
  font-size: 24px;
  font-weight: 850;
  color: #ffffff;
  margin: 10px 0 8px;
}

.guide-card > p {
  margin: 0 0 18px;
  font-size: 14.5px;
  color: var(--ink-soft);
}

.step-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.step-item {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 14px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid var(--line);
  transition: transform 0.25s var(--ease-out), border-color 0.25s, box-shadow 0.25s;
}

.step-item:hover {
  transform: translateX(4px);
  border-color: var(--cyan);
  box-shadow: 0 8px 24px -10px rgba(56, 189, 248, 0.35);
}

.step-num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--cyan), var(--indigo));
  color: #050b16;
  display: grid;
  place-items: center;
  font: 800 13px/1 var(--font-mono);
}

.step-body strong {
  display: block;
  font-size: 15.5px;
  color: #ffffff;
  margin-bottom: 3px;
}

.step-body p {
  margin: 0 0 6px;
  font-size: 13.5px;
  color: var(--ink-soft);
  line-height: 1.6;
}

.step-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 700;
  color: var(--cyan);
}

.step-link:hover {
  color: #7dd3fc;
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* ---------- Scroll Reveal Choreography ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px) scale(0.985);
  transition:
    opacity 0.65s var(--ease-out),
    transform 0.65s var(--ease-out);
  transition-delay: var(--reveal-delay, 0ms);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* ---------- About / Guide CTA Strip ---------- */
.aboutstrip {
  margin-top: 12px;
  margin-bottom: 48px;
  padding: clamp(28px, 4vw, 44px);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 85% 20%, rgba(56, 189, 248, 0.16), transparent 50%),
    linear-gradient(135deg, rgba(17, 24, 39, 0.92) 0%, rgba(15, 23, 42, 0.78) 100%);
  border: 1px solid rgba(56, 189, 248, 0.24);
  box-shadow: var(--shadow-sm);
}

.aboutstrip h2 {
  margin: 0;
}

.aboutstrip p {
  max-width: 520px;
  margin: 6px 0 0;
  color: var(--ink-soft);
}

.aboutstrip a:not(.btn) {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  color: var(--cyan);
  font-weight: 700;
}

/* ---------- Detail, Split & Inner Pages ---------- */
.inner {
  min-height: 55vh;
  animation: hero-fade-up 0.55s var(--ease-out) both;
}

.detail,
.split,
.detailsbody {
  display: grid;
  grid-template-columns: 1.12fr 1fr;
  gap: clamp(28px, 5vw, 72px);
  align-items: start;
  margin: 28px 0;
}

.detail {
  align-items: center;
}

.jacket {
  height: clamp(360px, 34vw, 500px);
  padding: 40px;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(148, 163, 184, 0.2);
  box-shadow: var(--shadow-lg);
}

.jacket > img {
  transition: transform 0.35s var(--ease-out), opacity 0.25s ease;
}

.jacket > img.is-swapping {
  opacity: 0.25;
  transform: scale(0.95);
}

.gallerynav {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  gap: 6px;
  padding: 5px;
  border-radius: var(--radius-pill);
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(10px);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-sm);
}

.gallerynav button {
  background: transparent;
  border: 0;
  padding: 6px 14px;
  font-size: 12px;
  box-shadow: none;
}

.gallerynav button:hover,
.gallerynav button.is-active {
  background: var(--cyan);
  color: #050b16;
  transform: none;
}

.productinfo h1 {
  margin: 14px 0 4px;
}

.actions {
  gap: 12px;
  flex-wrap: wrap;
  margin: 22px 0;
}

.detailsbody {
  border-top: 1px solid var(--line);
  padding-top: 34px;
  margin-top: 40px;
}

.panel,
.line,
.reading,
details,
.aboutstrip,
.search {
  overflow-wrap: anywhere;
}

.panel {
  background: var(--bg-surface);
  backdrop-filter: blur(16px);
  border: 1px solid var(--line);
  border-top: 3px solid var(--cyan);
  border-radius: var(--radius-lg);
  padding: clamp(22px, 3vw, 38px);
  box-shadow: var(--shadow-sm);
}

.panel small {
  display: block;
}

.panel h2,
.panel h3 {
  color: #ffffff;
}

.panel h2 {
  font-size: 30px;
  font-weight: 850;
  margin: 8px 0 12px;
}

.panel hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 18px 0;
}

.inner a:not(.btn):hover {
  color: var(--cyan);
}

/* ---------- Cart & Order Line Items ---------- */
.line {
  padding: 18px 20px;
  margin-bottom: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  gap: 18px;
  flex-wrap: wrap;
  transition: transform 0.25s var(--ease-out), box-shadow 0.25s var(--ease-out), border-color 0.25s;
}

.line:hover {
  transform: translateY(-2px);
  border-color: var(--cyan);
  box-shadow: var(--shadow-xs);
}

.line img {
  width: 56px;
  height: 74px;
  object-fit: contain;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  padding: 4px;
}

.line strong {
  color: #ffffff;
}

.line p {
  margin: 2px 0 0;
  font-size: 13px;
  color: var(--ink-soft);
}

.line > b,
.line > form:last-child {
  margin-left: auto;
  color: #7dd3fc;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

.line input {
  width: 68px;
  text-align: center;
}

.line button {
  padding: 7px 14px;
  font-size: 13px;
}

/* ---------- Forms & Search Bar ---------- */
label {
  display: block;
  font-weight: 650;
  font-size: 14px;
  color: #e2e8f0;
}

input,
textarea,
select {
  padding: 11px 16px;
  border: 1px solid var(--line-strong);
  background: rgba(15, 23, 42, 0.86);
  color: #f8fafc;
  max-width: 100%;
  border-radius: var(--radius-sm);
  transition: border-color 0.22s, box-shadow 0.22s;
}

input::placeholder,
textarea::placeholder {
  color: var(--ink-muted);
}

input:focus,
textarea:focus,
select:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.18);
  outline: none;
}

input[type="email"],
input[type="text"],
textarea {
  width: 100%;
  margin: 6px 0 14px;
}

.search {
  gap: 10px;
  margin: 22px 0;
  padding: 8px;
  background: var(--bg-surface);
  backdrop-filter: blur(12px);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-xs);
}

.search input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  padding: 10px 14px;
}

.search input:focus {
  box-shadow: none;
}

.search select {
  border-radius: var(--radius-sm);
  background: rgba(7, 10, 18, 0.85);
  border: 1px solid var(--line);
}

.search button {
  background: linear-gradient(135deg, var(--cyan), var(--indigo));
  color: #050b16;
  border-color: transparent;
  font-weight: 750;
  padding: 10px 22px;
}

.category-intro {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.category-intro img {
  height: 96px;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}

.reading {
  max-width: 980px;
}

.reading p {
  font-size: 16px;
  line-height: 1.8;
  color: var(--ink-soft);
}

.detailsbody pre {
  white-space: pre-wrap;
  background: #04070f;
  color: #cbd5e1;
  border: 1px solid rgba(56, 189, 248, 0.22);
  padding: 20px;
  border-radius: var(--radius-md);
  font: 13.5px/1.75 var(--font-mono);
  overflow-x: auto;
}

summary {
  cursor: pointer;
  font-weight: 700;
  color: #ffffff;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 4px 0;
}

summary::-webkit-details-marker {
  display: none;
}

summary::after {
  content: "+";
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(56, 189, 248, 0.14);
  color: var(--cyan);
  font: 700 16px/1 var(--font-mono);
  transition: transform 0.3s var(--ease-out), background-color 0.25s, color 0.25s;
}

details[open] > summary::after {
  transform: rotate(45deg);
  background: var(--cyan);
  color: #050b16;
}

details {
  padding: 16px 20px;
  margin: 14px 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  transition: border-color 0.25s, box-shadow 0.25s;
}

details[open] {
  border-color: rgba(56, 189, 248, 0.35);
  box-shadow: var(--shadow-xs);
}

.build-guide {
  padding: 18px 22px;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  scroll-margin-top: 84px;
}

.build-guide summary {
  font-size: 1.15rem;
  font-weight: 750;
}

.build-guide a {
  text-decoration: underline;
  text-underline-offset: 0.22em;
  color: var(--cyan);
}

/* ---------- Receipt Banner ---------- */
.receipt-heading {
  padding: clamp(24px, 3.4vw, 44px);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--bg-surface);
  box-shadow: var(--shadow-sm);
}

.receipt-heading.is-paid {
  background: linear-gradient(135deg, rgba(16, 46, 38, 0.9) 0%, rgba(15, 23, 42, 0.92) 100%);
  border-color: rgba(52, 211, 153, 0.42);
}

.receipt-heading h1 {
  font-size: clamp(32px, 4vw, 54px);
  line-height: 1.14;
  color: #ffffff;
  margin: 12px 0;
}

.receipt-heading p {
  margin: 0;
  color: var(--ink-soft);
}

.receipt-heading.is-paid .folio i {
  background: var(--emerald);
  box-shadow: 0 0 0 4px rgba(52, 211, 153, 0.22), 0 0 12px var(--emerald);
}

/* ---------- Footer ---------- */
footer {
  background: rgba(4, 6, 12, 0.92);
  color: rgba(241, 245, 249, 0.88);
  padding: 36px 0;
  border-top: 1px solid rgba(148, 163, 184, 0.14);
}

.footrow > div {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  font-size: 13.5px;
  color: var(--ink-soft);
}

.footrow > div a:hover {
  color: var(--cyan);
}

/* ---------- Glassmorphic Toast & Fly-to-Cart Particle ---------- */
.toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 70;
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(15, 23, 42, 0.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  color: #ffffff;
  padding: 14px 20px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(56, 189, 248, 0.38);
  box-shadow: var(--shadow-lg);
  font-size: 14px;
  font-weight: 600;
}

.toast a {
  color: var(--cyan);
  text-decoration: none;
  font-weight: 700;
}

.toast a:hover {
  color: #ffffff;
}

.fly-orb {
  position: fixed;
  top: 0;
  left: 0;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #ffffff, var(--cyan));
  box-shadow: 0 0 18px var(--cyan), 0 0 32px rgba(129, 140, 248, 0.8);
  pointer-events: none;
  z-index: 90;
}

.fx {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 80;
}

.notice {
  border-left: 3.5px solid var(--cyan);
  background: rgba(56, 189, 248, 0.1);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 12px 18px;
  margin-block: 16px;
}

/* ---------- Keyframe Animations ---------- */
.shelf-info [data-edition]:not([hidden]) {
  animation: edition-in 0.42s var(--ease-out) both;
}

.toast:not([hidden]) {
  animation: toast-in 0.38s var(--ease-spring) both;
}

@keyframes hero-fade-up {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes edition-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.94);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

[hidden] {
  display: none !important;
}

@view-transition {
  navigation: auto;
}

/* ---------- Responsive Breakpoints ---------- */
@media (max-width: 960px) {
  .grid,
  .bundle-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
  }
  .guide-grid {
    grid-template-columns: 1fr;
  }
  .shell {
    width: 92%;
  }
  .mast {
    gap: 14px;
  }
  .shelf {
    grid-template-columns: 1fr 1fr;
  }
  .shelf-info {
    padding: 26px;
  }
  .masthead p {
    font-size: 14px;
  }
}

@media (max-width: 680px) {
  .mast {
    min-height: 64px;
    gap: 10px;
    flex-wrap: wrap;
  }
  .brand {
    font-size: 20px;
  }
  .brand small {
    display: none;
  }
  .mast nav {
    order: 5;
    width: 100%;
    gap: 8px;
    padding-bottom: 12px;
  }
  .mast.js-menu nav {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    background: rgba(15, 23, 42, 0.96);
    backdrop-filter: blur(18px);
    padding: 12px;
    border-radius: var(--radius-md);
    border: 1px solid var(--line-strong);
    box-shadow: var(--shadow-lg);
  }
  .mast.js-menu nav.open {
    display: flex;
    animation: edition-in 0.25s var(--ease-out);
  }
  .menu-toggle:not([hidden]) {
    display: inline-flex;
    margin-left: auto;
    padding: 7px 14px;
    font-size: 13px;
  }
  .bag {
    padding: 6px 12px;
  }
  .masthead {
    display: block;
    padding: 28px 0 18px;
  }
  .masthead h1 {
    font-size: clamp(38px, 11vw, 60px);
  }
  .masthead p {
    text-align: left;
    margin-top: 10px;
    font-size: 13.5px;
  }
  .masthead p br {
    display: none;
  }
  .shelf,
  .detail,
  .split,
  .detailsbody,
  .bundle-grid {
    grid-template-columns: 1fr;
  }
  .shelf,
  .shelf-info,
  .display {
    min-height: auto;
  }
  .display {
    min-height: 270px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .books {
    max-width: 156px;
    margin: 28px auto;
  }
  .shelf-info {
    padding: 22px;
  }
  .shelf-info [data-edition] {
    min-height: 260px;
  }
  .shelf-info h2 {
    font-size: 26px;
  }
  .collection,
  .inner {
    padding-block: 34px;
  }
  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }
  .card {
    padding: 10px 10px 14px;
    border-radius: var(--radius-md);
  }
  .cover {
    height: 165px;
    padding: 14px 8px;
  }
  .cardtitle {
    display: block;
  }
  .cardtitle h3 {
    font-size: 16px;
  }
  .cardmeta {
    font-size: 11px;
    margin: 12px 4px 2px;
  }
  .card p {
    font-size: 12.5px;
    margin: 4px 4px 12px;
  }
  .card form {
    margin: 0 4px;
  }
  .quick {
    width: 100%;
    padding: 8px 10px;
    font-size: 12px;
  }
  .aboutstrip,
  .footrow {
    align-items: flex-start;
    flex-direction: column;
  }
  .jacket {
    height: 300px;
    padding: 24px;
  }
  .productinfo .purchase {
    position: fixed;
    z-index: 35;
    bottom: 0;
    left: 0;
    width: 100%;
    margin: 0;
    background: rgba(10, 14, 24, 0.94);
    backdrop-filter: blur(16px);
    border-top: 1px solid var(--line-strong);
    padding: 10px 4% max(10px, env(safe-area-inset-bottom));
  }
  .purchase button {
    flex: 1;
  }
  .toast {
    bottom: 76px;
    right: 16px;
    left: 16px;
  }
  body:has(.purchase) {
    padding-bottom: 76px;
  }
  .search {
    flex-wrap: wrap;
  }
  .search input {
    flex-basis: 100%;
  }
}

@media (max-width: 420px) {
  .grid {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 681px) {
  .menu-toggle {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
  .bg-tech-canvas {
    display: none !important;
  }
  ::view-transition-group(*) {
    animation: none !important;
  }
}

/* ---------- Order Progress Stepper & One-Time Delivery UX ---------- */
.order-steps {
  list-style: none;
  padding: 0;
  margin: 0 0 22px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.order-steps li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  border: 1px solid var(--line);
  font-size: 13.5px;
  font-weight: 650;
  color: var(--ink-muted);
}

.order-steps li span {
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(148, 163, 184, 0.16);
  font: 700 12px/1 var(--font-mono);
}

.order-steps li.is-done {
  color: var(--emerald);
  border-color: rgba(52, 211, 153, 0.35);
}

.order-steps li.is-done span {
  background: rgba(52, 211, 153, 0.2);
  color: var(--emerald);
}

.order-steps li.is-current {
  color: #ffffff;
  border-color: rgba(56, 189, 248, 0.45);
  box-shadow: 0 8px 24px -12px rgba(56, 189, 248, 0.45);
}

.order-steps li.is-current span {
  background: linear-gradient(135deg, var(--cyan), var(--indigo));
  color: #050b16;
}

.quota-note {
  margin-top: 4px !important;
  font-size: 12px !important;
  color: var(--cyan) !important;
}

.quota-exhausted {
  margin-left: auto;
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  background: rgba(255, 91, 69, 0.14);
  color: #ff9c8a;
  font-size: 12.5px;
  font-weight: 650;
}

.security-note {
  margin-top: 18px;
  padding: 18px 20px;
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  border: 1px solid rgba(56, 189, 248, 0.25);
}

.security-note p {
  margin: 6px 0 0;
  font-size: 13px;
  color: var(--ink-soft);
}

.copy-row {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 8px;
}

.copy-row input {
  flex: 1;
  margin: 0;
  font: 12.5px var(--font-mono);
}

.token-log {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  background: rgba(4, 7, 15, 0.85);
  border: 1px solid var(--line);
  font: 12.5px/1.65 var(--font-mono);
  color: #cbd5e1;
}

@media (max-width: 680px) {
  .order-steps {
    grid-template-columns: 1fr;
  }
  .copy-row {
    flex-direction: column;
    align-items: stretch;
  }
}

/* ---------- Embedded Cyber Runner Mini-Game (摸鱼跑酷) ---------- */
.arcade-nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  background: rgba(56, 189, 248, 0.12);
  color: #e0f2fe;
  border: 1px solid rgba(56, 189, 248, 0.35);
  font-size: 13.5px;
  font-weight: 700;
  box-shadow: none;
}

.arcade-nav-btn:hover {
  background: linear-gradient(135deg, var(--cyan), var(--indigo));
  color: #050b16;
  border-color: transparent;
  transform: translateY(-1px);
  box-shadow: 0 8px 20px -6px rgba(56, 189, 248, 0.5);
}

.arcade-fab-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--emerald);
  box-shadow: 0 0 10px var(--emerald);
}

.arcade-modal {
  position: fixed;
  inset: 0;
  z-index: 95;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(4, 6, 12, 0.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.arcade-dialog {
  width: min(820px, 100%);
  border-radius: var(--radius-lg);
  background: linear-gradient(160deg, rgba(16, 23, 42, 0.96) 0%, rgba(9, 13, 24, 0.98) 100%);
  border: 1px solid rgba(56, 189, 248, 0.34);
  box-shadow: var(--shadow-lg);
  padding: 20px 22px 22px;
  animation: toast-in 0.32s var(--ease-out) both;
}

.arcade-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.arcade-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.arcade-title h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 850;
  color: #ffffff;
}

.arcade-hud {
  display: flex;
  align-items: center;
  gap: 14px;
  font: 700 13px/1 var(--font-mono);
  color: #cbd5e1;
  font-variant-numeric: tabular-nums;
}

.arcade-hud strong {
  color: var(--cyan);
}

.arcade-hud .hud-speed {
  color: #fbbf24;
}

.arcade-stage {
  position: relative;
  width: 100%;
  height: clamp(230px, 34vw, 310px);
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.22);
  background: #060913;
  touch-action: none;
  user-select: none;
}

.arcade-stage canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.arcade-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 18px;
  background: rgba(6, 9, 19, 0.68);
  backdrop-filter: blur(4px);
}

.arcade-overlay h4 {
  margin: 0 0 6px;
  font-size: 22px;
  font-weight: 850;
  color: #ffffff;
}

.arcade-overlay p {
  margin: 0 0 16px;
  font-size: 13.5px;
  color: var(--ink-soft);
  max-width: 420px;
}

.arcade-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 14px;
  flex-wrap: wrap;
}

.arcade-pad {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.arcade-controls button {
  padding: 9px 16px;
  font-size: 13px;
}

.arcade-keys {
  font: 600 12px/1.4 var(--font-mono);
  color: var(--ink-muted);
}

@media (max-width: 680px) {
  .arcade-nav-btn {
    justify-content: flex-start;
    padding: 9px 14px;
  }
  .arcade-dialog {
    padding: 14px;
  }
  .arcade-keys {
    display: none;
  }
  .arcade-pad {
    width: 100%;
  }
  .arcade-pad button {
    flex: 1;
  }
}

.arcade-subbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid var(--line);
  font-size: 12.5px;
}

.arcade-owner {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #fbbf24;
  font-weight: 700;
  font-family: var(--font-mono);
}

.arcade-player {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #cbd5e1;
}

.arcade-player input {
  width: 112px;
  padding: 4px 8px;
  font-size: 12px;
  margin: 0;
  border-radius: 6px;
}

.arcade-themes {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.arcade-themes button {
  padding: 4px 10px;
  font-size: 11.5px;
  border-radius: var(--radius-pill);
}

.arcade-themes button.is-active {
  background: linear-gradient(135deg, var(--cyan), var(--indigo));
  color: #050b16;
  border-color: transparent;
}

.arcade-history {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: rgba(6, 10, 20, 0.85);
  border: 1px solid var(--line);
  font-size: 12.5px;
  color: #cbd5e1;
}

.arcade-history ul {
  list-style: none;
  padding: 0;
  margin: 8px 0 0;
  display: grid;
  gap: 6px;
}

.arcade-history li {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 10px;
  border-radius: 6px;
  background: rgba(30, 41, 59, 0.5);
  font-family: var(--font-mono);
  font-size: 12px;
}

.arcade-touch-only {
  display: none;
}

@media (max-width: 680px), (pointer: coarse) {
  .arcade-touch-only {
    display: inline-flex;
  }
}

/* ---------- Aligned Cart Line Layout ---------- */
.line.is-cart-item {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 14px;
}

.line-head {
  display: flex;
  align-items: center;
  gap: 16px;
}

.line-info {
  flex: 1;
  min-width: 0;
}

.line-sub {
  font-family: var(--font-mono);
  font-size: 18px;
  font-weight: 800;
  color: #7dd3fc;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.line-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 12px;
  border-top: 1px dashed rgba(148, 163, 184, 0.16);
}

.qty-stepper {
  display: inline-flex;
  align-items: center;
  background: rgba(7, 10, 18, 0.72);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-pill);
  padding: 3px;
  gap: 4px;
}

.qty-stepper button {
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 50%;
  border: 0;
  background: rgba(148, 163, 184, 0.14);
  font-size: 15px;
  line-height: 1;
  box-shadow: none;
}

.qty-stepper button:hover {
  background: var(--cyan);
  color: #050b16;
  transform: none;
}

.qty-stepper span {
  min-width: 28px;
  text-align: center;
  font: 700 13.5px/1 var(--font-mono);
  color: #ffffff;
}

.btn-remove {
  padding: 7px 14px;
  font-size: 12.5px;
  color: #fca5a5;
  border-color: rgba(248, 113, 113, 0.35);
  background: rgba(248, 113, 113, 0.08);
}

.btn-remove:hover {
  background: rgba(239, 68, 68, 0.22);
  border-color: #f87171;
  color: #ffffff;
}

/* ---------- High-Visibility Add-to-Cart VFX ---------- */
.fly-capsule {
  position: fixed;
  top: 0;
  left: 0;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #38bdf8 0%, #818cf8 100%);
  color: #040812;
  font: 800 12px/1 var(--font-mono);
  box-shadow: 0 0 22px rgba(56, 189, 248, 0.95), 0 0 42px rgba(129, 140, 248, 0.75);
  pointer-events: none;
  z-index: 98;
}

.fly-trail {
  position: fixed;
  top: 0;
  left: 0;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #7dd3fc;
  box-shadow: 0 0 14px #38bdf8;
  pointer-events: none;
  z-index: 97;
}

.float-plus {
  position: fixed;
  top: 0;
  left: 0;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: rgba(52, 211, 153, 0.95);
  color: #04150e;
  font: 800 12px/1.2 var(--font-mono);
  box-shadow: 0 6px 20px rgba(52, 211, 153, 0.5);
  pointer-events: none;
  z-index: 99;
}

.bag-ring {
  position: fixed;
  top: 0;
  left: 0;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 2.5px solid #38bdf8;
  box-shadow: 0 0 20px rgba(56, 189, 248, 0.85);
  pointer-events: none;
  z-index: 96;
}

.bag.impact {
  border-color: var(--cyan);
  box-shadow: 0 0 28px rgba(56, 189, 248, 0.65);
}

/* ---------- Contact Email Chip ---------- */
.contact-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 6px 3px 11px;
  border-radius: var(--radius-pill);
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.28);
  color: #e0f2fe;
  font: 600 12.5px/1.3 var(--font-mono);
  vertical-align: middle;
}

.contact-chip a {
  color: #7dd3fc;
}

.contact-chip a:hover {
  color: #ffffff;
  text-decoration: underline;
}

.chip-copy {
  padding: 2px 8px;
  font-size: 11px;
  border-radius: var(--radius-pill);
  border: 0;
  background: rgba(56, 189, 248, 0.2);
  color: #e0f2fe;
  box-shadow: none;
}

.chip-copy:hover {
  background: var(--cyan);
  color: #050b16;
  transform: none;
}

.foot-contact {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ink-soft);
}

.receipt-contact {
  margin-top: 10px;
}

.chip-copy.is-copied {
  background: var(--emerald);
  color: #04150e;
  font-weight: 800;
}

.qty-stepper input {
  border: 0;
  background: transparent;
  padding: 4px 6px;
  width: 52px;
  text-align: center;
  margin: 0;
  font: 700 13.5px/1 var(--font-mono);
}

.qty-stepper input:focus {
  box-shadow: none;
}

.qty-stepper > span:first-child {
  padding-left: 8px;
  color: var(--ink-soft);
  font-size: 12px;
}

.pager {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 32px;
}

.icp-bar {
  margin-top: 22px;
  padding-top: 16px;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  text-align: center;
  font: 500 12.5px/1.5 var(--font-mono);
  color: var(--ink-muted);
}

.icp-bar a:hover {
  color: var(--cyan);
  text-decoration: underline;
  text-underline-offset: 4px;
}
