:root {
  --ink: #0b1a24;
  --foam: #f4fbff;
  --cyan: #2ec6ff;
  --coral: #ff6b7a;
  --gold: #ffd166;
  --panel: rgba(8, 24, 36, 0.78);
  --line: rgba(255, 255, 255, 0.14);
  --bg: #041018;
  --font: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--foam);
  font-family: var(--font);
  background:
    radial-gradient(circle at 12% 0%, rgba(46, 198, 255, 0.18), transparent 42%),
    radial-gradient(circle at 88% 12%, rgba(255, 107, 122, 0.14), transparent 40%),
    var(--bg);
}
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button { cursor: pointer; }
img { max-width: 100%; display: block; }
.muted { color: rgba(255, 255, 255, 0.62); }
.tiny { font-size: 0.78rem; margin: 0.45rem 0 0; }
.eyebrow {
  margin: 0 0 0.35rem;
  letter-spacing: 0.14em;
  font-size: 0.75rem;
  color: var(--cyan);
  font-weight: 700;
}

.shop-top {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1.25rem;
  background: rgba(4, 16, 24, 0.88);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(8px);
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-weight: 700;
}
.brand img { width: 34px; height: 34px; border-radius: 10px; }
.shop-nav {
  display: none;
  gap: 1rem;
  margin-left: 0.5rem;
  color: rgba(255, 255, 255, 0.72);
}
.shop-nav a.is-on,
.shop-nav a:hover { color: #fff; }
.top-right {
  margin-left: auto;
  display: flex;
  gap: 0.5rem;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.ghost-btn,
.primary-btn {
  border-radius: 999px;
  padding: 0.5rem 0.95rem;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.08);
  color: var(--foam);
}
.ghost-btn.is-disabled,
.ghost-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.primary-btn {
  border: 0;
  background: linear-gradient(135deg, var(--cyan), #1a8fc4);
  color: #04202c;
  font-weight: 700;
  width: 100%;
  padding: 0.7rem 1rem;
}
.cart-fab {
  position: fixed;
  right: max(1rem, env(safe-area-inset-right));
  bottom: max(1.25rem, env(safe-area-inset-bottom));
  z-index: 55;
  width: 3.4rem;
  height: 3.4rem;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(145deg, var(--cyan), #1a8fc4);
  color: #04202c;
  box-shadow: 0 10px 28px rgba(46, 198, 255, 0.35);
  display: grid;
  place-items: center;
  padding: 0;
}
.cart-fab:hover { filter: brightness(1.05); }
.cart-fab.is-bounce {
  animation: cart-bounce 0.45s ease;
}
.cart-fab-plus {
  font-size: 2rem;
  font-weight: 600;
  line-height: 1;
  margin-top: -0.1rem;
}
@keyframes cart-bounce {
  0% { transform: scale(1); }
  35% { transform: scale(1.18); }
  70% { transform: scale(0.92); }
  100% { transform: scale(1); }
}

.fly-chip {
  position: fixed;
  z-index: 100;
  width: 44px;
  height: 44px;
  margin: 0;
  border-radius: 12px;
  overflow: hidden;
  pointer-events: none;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
  border: 2px solid rgba(46, 198, 255, 0.65);
  background: #0a1822;
  will-change: transform, opacity;
  transition: transform 0.65s cubic-bezier(0.22, 0.82, 0.28, 1), opacity 0.65s ease;
}
.fly-chip img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.fly-chip.is-fly {
  opacity: 0.35;
  transform: scale(0.28);
}
.cart-badge {
  position: absolute;
  top: -0.15rem;
  right: -0.15rem;
  display: inline-grid;
  place-items: center;
  min-width: 1.25rem;
  height: 1.25rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  background: var(--coral);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  box-shadow: 0 0 0 2px #041018;
}
.cart-badge[hidden] { display: none !important; }

.shop-hero {
  position: relative;
  padding: 2.5rem 1.25rem 1.75rem;
  overflow: hidden;
}
.shop-hero-bg {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(120deg, rgba(4, 16, 24, 0.55), rgba(4, 16, 24, 0.82)),
    url("https://cms-static.100bt.com/upload/common_cms/20260521/1779346070869.png") center/cover no-repeat;
  transform: scale(1.02);
}
.shop-hero-inner {
  position: relative;
  max-width: 72rem;
  margin: 0 auto;
}
.shop-hero h1 {
  margin: 0;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  letter-spacing: 0.02em;
}
.shop-hero .sub {
  margin: 0.65rem 0 0;
  max-width: 36rem;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.55;
}

.shop-body {
  max-width: 72rem;
  margin: 0 auto;
  padding: 0 1.25rem 3rem;
  display: grid;
  gap: 1rem;
}
.cats {
  display: flex;
  gap: 0.45rem;
  overflow-x: auto;
  padding-bottom: 0.25rem;
  -webkit-overflow-scrolling: touch;
}
.cat-btn {
  flex: 0 0 auto;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.78);
  border-radius: 999px;
  padding: 0.45rem 0.9rem;
  white-space: nowrap;
}
.cat-btn.is-on {
  background: rgba(46, 198, 255, 0.18);
  border-color: rgba(46, 198, 255, 0.55);
  color: #fff;
  font-weight: 600;
}
.goods-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.85rem;
}
.search {
  width: min(100%, 18rem);
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.28);
  color: var(--foam);
  border-radius: 12px;
  padding: 0.65rem 0.85rem;
  outline: none;
}
.search:focus { border-color: rgba(46, 198, 255, 0.55); }
.goods-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}
.goods-card {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-width: 0;
  transition: transform 0.2s ease, border-color 0.2s ease;
}
.goods-card:hover {
  transform: translateY(-2px);
  border-color: rgba(46, 198, 255, 0.4);
}
.goods-card .thumb {
  aspect-ratio: 1.15 / 1;
  background: rgba(0, 0, 0, 0.25);
  display: grid;
  place-items: center;
  padding: 0.75rem;
}
.goods-card .thumb img {
  width: min(72%, 120px);
  height: auto;
  object-fit: contain;
  border-radius: 12px;
}
.goods-card .body { padding: 0.75rem 0.85rem 0.95rem; }
.goods-card .name {
  margin: 0;
  font-size: 0.98rem;
  font-weight: 700;
  line-height: 1.35;
}
.goods-card .meta {
  margin: 0.35rem 0 0;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.55);
}
.goods-card .pack {
  margin: 0.3rem 0 0.55rem;
  font-size: 0.72rem;
  line-height: 1.35;
  color: rgba(46, 198, 255, 0.9);
}
.goods-card .row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: 0.55rem;
}
.price {
  color: var(--gold);
  font-weight: 800;
  font-size: 1.05rem;
}
.tag {
  display: inline-block;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  background: rgba(255, 209, 102, 0.16);
  color: var(--gold);
  font-size: 0.72rem;
  font-weight: 700;
}
.tag:empty { display: none; }
.mini-btn {
  border: 0;
  border-radius: 999px;
  padding: 0.4rem 0.7rem;
  background: rgba(46, 198, 255, 0.9);
  color: #04202c;
  font-weight: 700;
  font-size: 0.82rem;
}
.empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 2.5rem 1rem;
  color: rgba(255, 255, 255, 0.55);
}

.cart-mask,
.modal-mask {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(2, 8, 12, 0.62);
}
.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 70;
  width: min(22rem, 92vw);
  height: 100%;
  background: #0a1822;
  border-left: 1px solid var(--line);
  transform: translateX(105%);
  transition: transform 0.25s ease;
  display: flex;
  flex-direction: column;
}
.cart-drawer.open { transform: translateX(0); }
.cart-head,
.cart-foot { padding: 1rem 1.1rem; border-bottom: 1px solid var(--line); }
.cart-foot { border-bottom: 0; border-top: 1px solid var(--line); margin-top: auto; }
.cart-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.cart-head h2 { margin: 0; font-size: 1.1rem; }
.cart-list {
  flex: 1;
  overflow: auto;
  padding: 0.75rem 1.1rem;
}
.cart-empty { color: rgba(255,255,255,0.5); text-align: center; padding: 2rem 0.5rem; }
.cart-item {
  display: grid;
  grid-template-columns: 52px 1fr auto;
  gap: 0.65rem;
  align-items: center;
  padding: 0.65rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.cart-item img {
  width: 52px;
  height: 52px;
  object-fit: cover;
  border-radius: 10px;
  background: rgba(255,255,255,0.06);
}
.cart-item .nm { font-weight: 650; font-size: 0.9rem; }
.cart-item .qty-ctrl {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.3rem;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.55);
  flex-wrap: wrap;
}
.cart-item .qty-ctrl button {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 6px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.06);
  color: #fff;
  line-height: 1;
  padding: 0;
}
.cart-item .qty-ctrl .sum {
  margin-left: 0.25rem;
  color: var(--gold);
  font-weight: 700;
}
.cart-item .rm {
  border: 0;
  background: transparent;
  color: rgba(255,255,255,0.45);
  font-size: 1.1rem;
}
.cart-total { margin-bottom: 0.75rem; }
.icon-x {
  border: 0;
  background: transparent;
  color: rgba(255,255,255,0.7);
  font-size: 1.5rem;
  line-height: 1;
}

.modal-mask {
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 1rem;
}
.modal {
  position: relative;
  width: min(560px, 100%);
  max-height: min(88vh, 720px);
  overflow: auto;
  background: #0d1c28;
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.4);
}
.modal-x { position: absolute; top: 0.55rem; right: 0.7rem; z-index: 2; }
.modal-media {
  background:
    radial-gradient(circle at 50% 30%, rgba(46, 198, 255, 0.2), transparent 55%),
    rgba(0, 0, 0, 0.25);
  padding: 1.5rem;
  display: grid;
  place-items: center;
}
.modal-media img {
  width: min(180px, 55%);
  border-radius: 16px;
}
.modal-body { padding: 0 1.2rem 1.35rem; }
.modal-body h2 { margin: 0.15rem 0 0.55rem; font-size: 1.35rem; }
.detail-desc {
  margin: 0;
  color: rgba(255,255,255,0.7);
  line-height: 1.55;
  font-size: 0.92rem;
}
.detail-price {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin: 1rem 0;
}
.qty-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
}
.qty-row button {
  width: 2rem;
  height: 2rem;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.06);
  color: #fff;
}
.qty-row input {
  width: 3.5rem;
  text-align: center;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: rgba(0,0,0,0.28);
  color: #fff;
  padding: 0.4rem;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 1.5rem;
  z-index: 90;
  transform: translateX(-50%);
  background: rgba(10, 28, 40, 0.95);
  border: 1px solid var(--line);
  color: #fff;
  padding: 0.7rem 1.1rem;
  border-radius: 999px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.35);
}

.shop-foot {
  text-align: center;
  padding: 1.5rem 1rem 2.5rem;
  color: rgba(255,255,255,0.45);
  font-size: 0.85rem;
}
.shop-foot img {
  width: 36px;
  height: 36px;
  margin: 0 auto 0.5rem;
  border-radius: 10px;
  opacity: 0.85;
}

@media (min-width: 720px) {
  .shop-nav { display: flex; }
  .goods-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
}
@media (min-width: 980px) {
  .shop-body {
    grid-template-columns: 11rem minmax(0, 1fr);
    align-items: start;
    gap: 1.25rem;
  }
  .cats {
    flex-direction: column;
    overflow: visible;
    position: sticky;
    top: 5rem;
  }
  .cat-btn {
    width: 100%;
    border-radius: 12px;
    text-align: left;
  }
  .goods-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
