/* ============ 俊云智造 - 全局样式（明亮清爽主题 v2） ============ */
:root {
  --bg: #f4f7fc;
  --bg-2: #ffffff;
  --panel: #ffffff;
  --panel-2: #ffffff;
  --border: #e6ebf2;
  --border-hi: #b7c9e0;
  --text: #1f2a3d;
  --text-dim: #7b8799;
  --accent: #2563eb;
  --accent-2: #7c3aed;
  --grad: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
  --grad-warm: linear-gradient(135deg, #f472b6 0%, #7c3aed 100%);
  --success: #16a34a;
  --danger: #e11d48;
  --warn: #f59e0b;
  --radius: 16px;
  --shadow: 0 12px 32px rgba(37, 99, 235, 0.12);
  --shadow-sm: 0 2px 10px rgba(31, 42, 61, 0.06);
  --glow: 0 6px 18px rgba(37, 99, 235, 0.28);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
button { cursor: pointer; font-family: inherit; border: none; outline: none; }
input, select, textarea { font-family: inherit; outline: none; }

/* 科技感背景：渐变网格 + 浮动光斑 + 顶部光带
   注意：z-index 必须为 -1，若为 0 会形成合成层盖住全部静态内容（登录页空白 bug 根因），
   且层数过多会拖慢重绘（卡顿），此处精简为 3 层。 */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(circle at 12% 8%, rgba(37, 99, 235, 0.10), transparent 42%),
    radial-gradient(circle at 88% 16%, rgba(124, 58, 237, 0.10), transparent 45%),
    linear-gradient(180deg, #f4f7fc 0%, #eef2fb 100%);
}
body::after {
  content: '';
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 4px; z-index: 999; pointer-events: none;
  background: var(--grad);
}

.container { max-width: 1240px; margin: 0 auto; padding: 0 24px; }

/* 顶部导航 */
.topbar {
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(16px);
  background: rgba(255, 255, 255, 0.86);
  border-bottom: 1px solid var(--border);
}
.topbar-inner { display: flex; align-items: center; gap: 28px; height: 68px; }
.logo {
  display: flex; align-items: center; gap: 10px;
  font-size: 22px; font-weight: 800; letter-spacing: 0.5px;
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.logo .chip {
  width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center;
  background: var(--grad); font-size: 18px;
  -webkit-text-fill-color: #fff; color: #fff;
  box-shadow: var(--glow);
}
.nav { display: flex; gap: 4px; flex: 1; }
.nav a {
  padding: 8px 16px; border-radius: 8px; font-size: 15px; color: var(--text-dim);
  transition: all .2s; white-space: nowrap;
}
.nav a:hover { color: var(--accent); background: rgba(37, 99, 235, 0.06); }
.nav a.active { color: var(--accent); background: rgba(37, 99, 235, 0.10); font-weight: 600; }
.top-actions { display: flex; align-items: center; gap: 14px; }
.icon-btn {
  position: relative; width: 42px; height: 42px; border-radius: 12px;
  background: var(--panel); border: 1px solid var(--border);
  display: grid; place-items: center; font-size: 19px; transition: all .2s;
  box-shadow: var(--shadow-sm);
}
.icon-btn:hover { border-color: var(--accent); box-shadow: var(--glow); transform: translateY(-1px); }
.icon-btn .badge {
  position: absolute; top: -6px; right: -6px; min-width: 18px; height: 18px;
  background: var(--danger); color: #fff; font-size: 11px; border-radius: 9px;
  display: grid; place-items: center; padding: 0 4px; font-weight: 700;
}
.admin-link {
  padding: 9px 18px; border-radius: 10px; font-size: 14px; font-weight: 600;
  background: var(--panel); border: 1px solid var(--border); color: var(--text);
  transition: all .2s; box-shadow: var(--shadow-sm);
}
.admin-link:hover { border-color: var(--accent-2); color: var(--accent-2); }

/* 按钮 */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 10px 20px; border-radius: 10px; font-size: 14px; font-weight: 600;
  transition: all .22s cubic-bezier(.4,0,.2,1); white-space: nowrap; position: relative; overflow: hidden;
}
.btn-primary { background: var(--grad); color: #fff; box-shadow: var(--glow); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(37, 99, 235, 0.42); }
.btn-primary:active { transform: translateY(0) scale(.98); }
.btn-ghost { background: transparent; border: 1px solid var(--border); color: var(--text); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-1px); }
.btn-danger { background: rgba(225, 29, 72, 0.08); color: var(--danger); border: 1px solid rgba(225, 29, 72, 0.25); }
.btn-danger:hover { background: rgba(225, 29, 72, 0.15); }
.btn-sm { padding: 6px 12px; font-size: 13px; border-radius: 8px; }
.btn-block { width: 100%; }

/* 顶部搜索框（导航右侧、用户登录区左侧） */
.top-search {
  display: flex; align-items: center;
  background: #fff; border-radius: 22px;
  border: 2px solid var(--border);
  overflow: hidden;
  transition: border-color .2s, box-shadow .2s;
  width: 380px;
}
.top-search:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.10);
}
.top-search .ts-input {
  flex: 1; min-width: 0;
  border: none; outline: none;
  padding: 8px 14px; font-size: 14px; color: var(--text);
  background: transparent;
}
.top-search .ts-input::placeholder { color: var(--text-dim); }
.top-search .ts-btn {
  border: none; cursor: pointer;
  padding: 7px 12px; font-size: 14px;
  background: var(--grad); color: #fff;
  border-radius: 18px; margin: 2px;
  line-height: 1;
  transition: filter .2s;
}
.top-search .ts-btn:hover { filter: brightness(1.08); }
@media (max-width: 1200px) { .top-search { width: 260px; } }
@media (max-width: 900px) { .top-search { width: 150px; } }

/* Hero */
.hero {
  position: relative; overflow: hidden;
  border-radius: 24px; margin: 24px 0;
  padding: 56px 52px;
  background:
    radial-gradient(circle at 80% 20%, rgba(124, 58, 237, 0.12), transparent 50%),
    radial-gradient(circle at 20% 80%, rgba(37, 99, 235, 0.10), transparent 50%),
    linear-gradient(135deg, #eef4ff 0%, #f3ecff 55%, #e8f4ff 100%);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}
.hero::after {
  content: ''; position: absolute; right: -60px; top: -60px;
  width: 380px; height: 380px; border-radius: 50%;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.16), transparent 70%);
  animation: floatGlow 6s ease-in-out infinite;
}
.hero::before {
  content: ''; position: absolute; right: 80px; bottom: -100px;
  width: 300px; height: 300px; border-radius: 50%;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.14), transparent 70%);
  animation: floatGlow 8s ease-in-out infinite reverse;
}
@keyframes floatGlow {
  0%, 100% { transform: translate(0, 0) scale(1); opacity: .8; }
  50% { transform: translate(-16px, 12px) scale(1.08); opacity: 1; }
}
.hero h1.hero-title { font-size: 19px; font-weight: 800; line-height: 1.3; margin-bottom: 8px; color: var(--text); }
.hero h1.hero-title span { background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hero h1.hero-title span + span { margin-left: 6px; }
.hero p { color: var(--text-dim); font-size: 14px; max-width: 560px; margin-bottom: 18px; }
.hero .hero-btns { display: flex; gap: 14px; }

/* 搜索框 */
.hero-search {
  display: flex; align-items: center; gap: 0;
  max-width: 560px; margin-bottom: 24px;
  background: #fff; border-radius: 14px;
  border: 2px solid var(--border);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: border-color .2s, box-shadow .2s;
}
.hero-search:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}
.hero-search-input {
  flex: 1; min-width: 0;
  border: none; outline: none;
  padding: 14px 18px; font-size: 15px; color: var(--text);
  background: transparent;
}
.hero-search-input::placeholder { color: var(--text-dim); }
.hero-search-btn {
  border: none; cursor: pointer;
  padding: 14px 24px; font-size: 15px; font-weight: 600; color: #fff;
  background: var(--grad);
  transition: filter .2s;
  white-space: nowrap;
}
.hero-search-btn:hover { filter: brightness(1.08); }
.list-search {
  display: flex; align-items: center; gap: 0;
  margin: 16px 0 4px;
  background: var(--panel); border-radius: 12px;
  border: 2px solid var(--border); overflow: hidden;
  transition: border-color .2s;
}
.list-search:focus-within { border-color: var(--accent); }
.list-search .hero-search-input { padding: 11px 16px; }
.list-search .hero-search-btn { padding: 11px 20px; font-size: 14px; }

.hero-stats { display: flex; gap: 44px; margin-top: 40px; }
.hero-stats .stat b { font-size: 28px; display: block; color: var(--accent); }
.hero-stats .stat span { color: var(--text-dim); font-size: 13px; }

/* Hero 轮播图（侧滑切换，图片保持原始比例不裁剪） */
.hero-inner { position: relative; z-index: 2; max-width: 55%; }
.hero-carousel {
  position: absolute; right: 36px; top: 36px; bottom: 36px;
  width: 40%; min-width: 320px; z-index: 1;
  border-radius: 16px; overflow: hidden;
  box-shadow: 0 12px 32px rgba(30, 41, 99, 0.16);
  background: #dde5f5;
}
.hc-track {
  display: flex; width: 100%; height: 100%;
  transition: transform 0.55s cubic-bezier(0.25, 0.8, 0.25, 1);
  will-change: transform;
}
.hc-slide {
  flex: 0 0 100%; width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
}
.hc-slide img {
  width: 100%; height: 100%;
  object-fit: contain;         /* 保持原始比例，不裁剪、不拉伸 */
  object-position: center;
  display: block;
  -webkit-user-drag: none; user-select: none;
}
.hc-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 34px; height: 34px; border: none; border-radius: 50%;
  background: rgba(255, 255, 255, 0.85); color: #334155;
  font-size: 20px; line-height: 1; cursor: pointer; z-index: 3;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
  display: flex; align-items: center; justify-content: center;
  transition: background .2s, transform .2s;
}
.hc-arrow:hover { background: #fff; transform: translateY(-50%) scale(1.1); }
.hc-prev { left: 10px; }
.hc-next { right: 10px; }
.hc-dots {
  position: absolute; bottom: 12px; left: 0; right: 0;
  display: flex; justify-content: center; gap: 8px; z-index: 3;
}
.hc-dots span {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.55); cursor: pointer;
  box-shadow: 0 1px 3px rgba(0,0,0,0.3); transition: all 0.3s;
}
.hc-dots span.on { background: #fff; width: 20px; border-radius: 4px; }
@media (max-width: 900px) {
  .hero-inner { max-width: 100%; }
  .hero-carousel { position: relative; right: auto; top: auto; bottom: auto; width: 100%; height: 220px; margin-top: 24px; }
}

/* ===================== 淘宝式首屏：左分类 + 中轮播 + 右促销 ===================== */
.home-top {
  display: grid;
  grid-template-columns: 208px minmax(0, 1fr) 224px;
  gap: 14px;
  margin: 20px 0 8px;
  align-items: stretch;
}

/* ---- 左侧分类导航 ---- */
.cat-side {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 6px 0;
  position: relative;
  z-index: 30;
  height: 300px;              /* 与轮播图 / 促销卡同高，三栏顶部底部齐平 */
  display: flex; flex-direction: column; justify-content: space-between;
  overflow: visible;
}
.cs-item { position: relative; flex: 1 1 0; display: flex; align-items: center; }
.cs-head {
  display: flex; align-items: center; gap: 8px;
  padding: 0 14px;
  width: 100%; height: 100%;
  font-size: 13px; font-weight: 600; color: var(--text);
  transition: background .16s, color .16s;
  border-left: 3px solid transparent;
}
.cs-ico { font-size: 15px; width: 20px; text-align: center; flex: 0 0 20px; }
.cs-name { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-cnt {
  font-size: 11px; font-weight: 500; color: var(--text-dim);
  background: var(--bg); border-radius: 9px; padding: 1px 7px;
  transition: all .16s;
}
.cs-arrow { color: var(--text-dim); font-size: 15px; line-height: 1; opacity: .5; }
.cs-item:hover > .cs-head {
  background: linear-gradient(90deg, rgba(37,99,235,.10), rgba(124,58,237,.06));
  color: var(--accent);
  border-left-color: var(--accent);
}
.cs-item:hover > .cs-head .cs-cnt { background: var(--accent); color: #fff; }

/* 子分类飞行面板 */
.cs-sub {
  position: absolute; left: 100%; top: 0;
  min-width: 300px;
  padding-left: 6px;
  opacity: 0; visibility: hidden;
  transform: translateX(-8px);
  transition: opacity .18s ease, transform .18s ease, visibility .18s;
  z-index: 40;
}
.cs-item:hover > .cs-sub { opacity: 1; visibility: visible; transform: translateX(0); }
.cs-sub-inner {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 16px 40px rgba(30, 41, 99, .16);
  padding: 14px 16px;
  display: flex; flex-wrap: wrap; gap: 8px;
}
.cs-sub-link {
  font-size: 13px; color: var(--text-dim);
  padding: 6px 12px; border-radius: 8px;
  background: var(--bg); border: 1px solid transparent;
  transition: all .16s; white-space: nowrap;
}
.cs-sub-link:hover {
  color: #fff; background: var(--grad); border-color: transparent;
  transform: translateY(-1px); box-shadow: var(--glow);
}
.cs-sub-link.cs-sub-all {
  color: var(--accent); font-weight: 600;
  background: rgba(37,99,235,.08);
}

/* ---- 中间轮播（双格：每格 2 秒淡入换图） ---- */
.home-carousel {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  height: 300px;
  background: linear-gradient(135deg, #eef4ff, #f3ecff);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}
/* 双格等比 + 左右渐变透明融合：
   中间一条很窄的交叠带里，左格向右侧渐隐、右格向左侧渐隐（互补遮罩），
   两图在中间逐渐透明交叠；底下垫一层跟随图片的模糊底衬，
   透出的是柔和画面色而不是空白/黑缝 */
.hc-pair {
  position: relative; width: 100%; height: 100%;
  --blend: 6px;
  background-color: #0b1020;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.hc-pair::before {
  content: ''; position: absolute; inset: 0;
  -webkit-backdrop-filter: blur(34px) saturate(1.15) brightness(.72);
          backdrop-filter: blur(34px) saturate(1.15) brightness(.72);
}
.hc-slot {
  position: absolute; top: 0; bottom: 0;
  width: calc(50% + var(--blend) / 2);
  overflow: hidden;
  background: transparent;
}
/* 左格：右缘渐隐为透明 */
.hc-slot:first-child {
  left: calc(-0.5 * var(--blend)); z-index: 1;
  -webkit-mask-image: linear-gradient(to right,
    #000 0,
    #000 calc(100% - var(--blend)),
    rgba(0,0,0,.88) calc(100% - var(--blend) * .8),
    rgba(0,0,0,.66) calc(100% - var(--blend) * .6),
    rgba(0,0,0,.40) calc(100% - var(--blend) * .4),
    rgba(0,0,0,.16) calc(100% - var(--blend) * .2),
    rgba(0,0,0,0) 100%);
          mask-image: linear-gradient(to right,
    #000 0,
    #000 calc(100% - var(--blend)),
    rgba(0,0,0,.88) calc(100% - var(--blend) * .8),
    rgba(0,0,0,.66) calc(100% - var(--blend) * .6),
    rgba(0,0,0,.40) calc(100% - var(--blend) * .4),
    rgba(0,0,0,.16) calc(100% - var(--blend) * .2),
    rgba(0,0,0,0) 100%);
}
/* 右格：左缘渐隐为透明（与左格严格互补） */
.hc-slot:last-child {
  right: calc(-0.5 * var(--blend)); z-index: 2;
  -webkit-mask-image: linear-gradient(to left,
    #000 0,
    #000 calc(100% - var(--blend)),
    rgba(0,0,0,.88) calc(100% - var(--blend) * .8),
    rgba(0,0,0,.66) calc(100% - var(--blend) * .6),
    rgba(0,0,0,.40) calc(100% - var(--blend) * .4),
    rgba(0,0,0,.16) calc(100% - var(--blend) * .2),
    rgba(0,0,0,0) 100%);
          mask-image: linear-gradient(to left,
    #000 0,
    #000 calc(100% - var(--blend)),
    rgba(0,0,0,.88) calc(100% - var(--blend) * .8),
    rgba(0,0,0,.66) calc(100% - var(--blend) * .6),
    rgba(0,0,0,.40) calc(100% - var(--blend) * .4),
    rgba(0,0,0,.16) calc(100% - var(--blend) * .2),
    rgba(0,0,0,0) 100%);
}
.hc-slot img {
  width: 100%; height: 100%;
  object-fit: cover;           /* 铺满整格，不留空白 */
  object-position: center;
  display: block;
}
/* 淡入的新图（叠在旧图上面渐显，完成后移除旧图） */
.hc-slot img.hc-fade-in {
  position: absolute; inset: 0;
  opacity: 0; transition: opacity .8s ease-in-out; z-index: 2;
}
.home-carousel:empty::after {
  content: '暂无轮播图 · 请在后台「首页与轮播」上传';
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-dim); font-size: 14px;
}

/* ---- 右侧促销卡 ---- */
.promo-side {
  display: grid; grid-template-rows: 1fr 1fr; gap: 10px;
  height: 300px;
}
.promo-card {
  position: relative; overflow: hidden;
  border-radius: 14px;
  padding: 12px 14px;
  display: flex; flex-direction: column; justify-content: space-between;
  border: 1px solid var(--border);
  transition: transform .2s, box-shadow .2s;
  box-shadow: var(--shadow-sm);
}
.promo-card:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(30,41,99,.16); }
.pc-title { font-size: 14px; font-weight: 700; line-height: 1.3; }
.pc-title span {
  display: block; font-size: 11px; font-weight: 500; opacity: .72; margin-top: 3px;
}
.pc-emoji {
  font-size: 40px; line-height: 1; align-self: flex-end;
  filter: drop-shadow(0 4px 10px rgba(0,0,0,.14));
  transition: transform .25s;
}
.promo-card:hover .pc-emoji { transform: scale(1.14) rotate(-6deg); }
.pc-1 { background: linear-gradient(135deg, #e0ecff, #cfe0ff); color: #1e40af; }
.pc-2 { background: linear-gradient(135deg, #ffe6f0, #ffd3e4); color: #9d174d; }
.pc-3 { background: linear-gradient(135deg, #e3fbf1, #cdf5e3); color: #065f46; }
.pc-4 { background: linear-gradient(135deg, #fff2dd, #ffe4bd); color: #92400e; }

/* ---- 品牌横幅（整行，位于首屏上方） ---- */
.hero-strip { margin: 20px 0 0; padding: 26px 40px; }
.hero-strip .hero-inner-full { max-width: 100%; }
.hero-strip .hero-stats { margin-top: 0; }

@media (max-width: 1100px) {
  .home-top { grid-template-columns: 190px minmax(0, 1fr); }
  .promo-side { display: none; }
}
@media (max-width: 820px) {
  .home-top { grid-template-columns: 1fr; }
  .cat-side { display: none; }
  .home-carousel { height: 220px; }
  .hc-pair { --blend: 6px; }
  .promo-side { height: auto; grid-template-rows: 1fr 1fr; }
  .hero-strip { padding: 20px 22px; }
}

/* 分类栏 */
.cat-bar { display: flex; gap: 12px; margin: 28px 0 20px; flex-wrap: wrap; }
.cat-chip {
  padding: 9px 20px; border-radius: 22px; font-size: 14px;
  background: var(--panel); border: 1px solid var(--border); color: var(--text-dim);
  transition: all .2s; box-shadow: var(--shadow-sm);
}
.cat-chip:hover { color: var(--accent); border-color: var(--accent); }
.cat-chip.active { background: var(--grad); color: #fff; border-color: transparent; box-shadow: var(--glow); }
/* 选中父分类后展开的子分类 chip 行 */
.cat-subrow {
  flex-basis: 100%;
  display: flex; gap: 10px; flex-wrap: wrap;
  margin-top: 2px; padding: 12px 14px;
  background: var(--panel); border: 1px dashed var(--border-hi);
  border-radius: 12px;
  animation: subRowIn .28s ease;
}
@keyframes subRowIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
.cat-subchip {
  font-size: 13px; padding: 6px 14px; border-radius: 8px;
  color: var(--accent); background: rgba(37,99,235,.08);
  border: 1px solid rgba(37,99,235,.16);
  transition: all .16s;
}
.cat-subchip:hover { color: #fff; background: var(--grad); border-color: transparent; box-shadow: var(--glow); }

/* 商品网格 */
.section-title { display: flex; align-items: center; justify-content: space-between; margin: 32px 0 18px; }
.section-title h2 { font-size: 24px; font-weight: 700; }
.section-title h2::before { content: ''; display: inline-block; width: 5px; height: 22px; background: var(--grad); border-radius: 3px; margin-right: 12px; vertical-align: -3px; }
.section-title .more { color: var(--text-dim); font-size: 14px; transition: all .2s; }
.section-title .more:hover { color: var(--accent); }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }
.product-card {
  background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; transition: all .3s cubic-bezier(.4,0,.2,1); cursor: pointer; position: relative;
  box-shadow: var(--shadow-sm);
}
.product-card:hover {
  transform: translateY(-8px);
  border-color: var(--accent);
  box-shadow: 0 18px 44px rgba(37, 99, 235, 0.16);
}
.product-card::before {
  content: ''; position: absolute; inset: 0; border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(37,99,235,.06), rgba(124,58,237,.06));
  opacity: 0; transition: opacity .3s; pointer-events: none; z-index: 3;
}
.product-card:hover::before { opacity: 1; }
.p-cover {
  height: 200px; position: relative; display: grid; place-items: center;
  background: linear-gradient(135deg, #eef4ff 0%, #f3ecff 100%);
  font-size: 64px; overflow: hidden;
}
.p-cover img { transition: transform .45s cubic-bezier(.4,0,.2,1); }
.product-card:hover .p-cover img { transform: scale(1.10); }
/* 扫光特效 */
.p-shine {
  position: absolute; top: 0; left: -75%; width: 50%; height: 100%; z-index: 2;
  background: linear-gradient(115deg, transparent 0%, rgba(255,255,255,.55) 50%, transparent 100%);
  transform: skewX(-20deg); pointer-events: none;
}
.product-card:hover .p-shine { animation: shine .9s ease; }
@keyframes shine { 0% { left: -75%; } 100% { left: 125%; } }
.p-cover .p-tag {
  position: absolute; top: 12px; left: 12px; z-index: 2;
  padding: 4px 10px; border-radius: 6px; font-size: 11px; font-weight: 700;
  background: var(--grad); color: #fff;
  box-shadow: 0 2px 8px rgba(37,99,235,.3);
}
/* 封面右上角分类徽标（毛玻璃质感） */
.p-cover .p-cat {
  position: absolute; top: 12px; right: 12px; z-index: 2;
  padding: 3px 9px; border-radius: 6px; font-size: 11px; font-weight: 600;
  color: #334155; background: rgba(255,255,255,.78);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,.75);
  box-shadow: 0 2px 8px rgba(31,42,61,.10);
}
.p-body { padding: 16px 18px 18px; }
.p-name { font-size: 16px; font-weight: 700; margin-bottom: 6px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 44px; transition: color .2s; }
.product-card:hover .p-name { color: var(--accent); }
.p-desc { color: var(--text-dim); font-size: 13px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 40px; }
.p-meta { display: flex; align-items: center; gap: 8px; margin: 10px 0; }
.p-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.p-tags span { font-size: 11px; color: var(--accent); background: rgba(37, 99, 235, 0.08); padding: 2px 8px; border-radius: 5px; }
.p-rating { color: var(--warn); font-size: 13px; margin-left: auto; }
.p-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; gap: 8px; flex-wrap: wrap; }
.p-price { font-size: 22px; font-weight: 800; color: #e11d48; }
.p-price small { font-size: 13px; font-weight: 400; color: var(--text-dim); text-decoration: line-through; margin-left: 8px; }
.p-actions { display: flex; gap: 6px; }
/* 加入购物车按钮（渐变 + 光晕 + 涟漪） */
.p-buy {
  position: relative; overflow: hidden;
  padding: 8px 12px; border-radius: 8px; font-size: 13px; font-weight: 700;
  background: var(--grad); color: #fff; box-shadow: 0 2px 8px rgba(37,99,235,.25);
  transition: all .22s cubic-bezier(.4,0,.2,1); border: none; cursor: pointer;
}
.p-buy:hover { transform: translateY(-2px) scale(1.04); box-shadow: 0 6px 18px rgba(37,99,235,.42); }
.p-buy:active { transform: scale(.96); }
/* 立即下单按钮（红色描边，hover 填充） */
.p-order {
  position: relative; overflow: hidden;
  padding: 8px 12px; border-radius: 8px; font-size: 13px; font-weight: 700;
  background: #fff; color: #e11d48; border: 1px solid #e11d48; transition: all .22s cubic-bezier(.4,0,.2,1); cursor: pointer;
}
.p-order:hover { background: linear-gradient(135deg, #e11d48, #f472b6); color: #fff; border-color: transparent; transform: translateY(-2px); box-shadow: 0 6px 18px rgba(225,29,72,.32); }
.p-order:active { transform: scale(.96); }
/* 按钮涟漪 */
.btn-ripple {
  position: absolute; border-radius: 50%; background: rgba(255,255,255,.5);
  transform: scale(0); animation: ripple .6s linear; pointer-events: none;
}
@keyframes ripple { to { transform: scale(4); opacity: 0; } }
.p-sold { font-size: 12px; color: var(--text-dim); margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); }

/* 底部 */
.footer {
  margin-top: 60px; padding: 48px 0; border-top: 1px solid var(--border);
  color: var(--text-dim); font-size: 14px;
  background: linear-gradient(180deg, var(--panel) 0%, #f0f4fb 100%);
  position: relative; z-index: 1;
}
.footer-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px; }
.footer-links { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.footer-links a { color: var(--text-dim); transition: color .2s; }
.footer-links a:hover { color: var(--accent); }

/* 弹窗 */
.modal-mask {
  position: fixed; inset: 0; background: rgba(31, 42, 61, 0.45); backdrop-filter: blur(6px);
  display: none; place-items: center; z-index: 200;
  animation: fadeIn .2s ease;
}
.modal-mask.show { display: grid; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal {
  background: var(--panel-2); border: 1px solid var(--border); border-radius: var(--radius);
  width: 90%; max-width: 760px; max-height: 88vh; overflow-y: auto; padding: 28px;
  box-shadow: 0 24px 64px rgba(31, 42, 61, 0.24);
  animation: modalIn .28s cubic-bezier(.4,0,.2,1);
}
@keyframes modalIn { from { opacity: 0; transform: translateY(20px) scale(.97); } to { opacity: 1; transform: translateY(0) scale(1); } }
.modal h3 { font-size: 20px; margin-bottom: 20px; }
.modal-close { float: right; font-size: 24px; color: var(--text-dim); background: none; line-height: 1; transition: color .2s, transform .2s; }
.modal-close:hover { color: var(--danger); transform: rotate(90deg); }

/* 会员欢迎弹窗 */
.welcome-modal { max-width: 380px; text-align: center; padding: 36px 32px; }
.welcome-body { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.welcome-badge {
  width: 88px; height: 88px; border-radius: 50%; display: grid; place-items: center;
  color: #fff; font-size: 22px; font-weight: 800; letter-spacing: 1px;
  box-shadow: 0 8px 24px rgba(0,0,0,.18); margin-bottom: 4px;
}
.welcome-body h3 { font-size: 20px; margin: 0; }
.welcome-body p { color: var(--text-dim); font-size: 14px; line-height: 1.7; margin: 0; }

/* 表单 */
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 13px; color: var(--text-dim); margin-bottom: 6px; }
.form-control {
  width: 100%; padding: 10px 14px; border-radius: 9px;
  background: var(--bg-2); border: 1px solid var(--border); color: var(--text);
  font-size: 14px; transition: all .2s;
}
.form-control:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12); }
textarea.form-control { min-height: 80px; resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
select.form-control option { background: #fff; color: var(--text); }

/* Toast */
.toast {
  position: fixed; top: 24px; left: 50%; transform: translateX(-50%);
  padding: 12px 24px; border-radius: 10px; font-size: 14px; font-weight: 600;
  z-index: 300; animation: toastIn .3s ease;
  background: #fff; border: 1px solid var(--border); color: var(--text); box-shadow: var(--shadow);
}
.toast.success { border-color: var(--success); color: var(--success); }
.toast.error { border-color: var(--danger); color: var(--danger); }
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, -20px); } to { opacity: 1; transform: translate(-50%, 0); } }

/* 空状态 */
.empty { text-align: center; padding: 80px 20px; color: var(--text-dim); }
.empty .e-icon { font-size: 64px; margin-bottom: 16px; }
.empty p { font-size: 16px; }

/* ============ 用户/会员 ============ */
.user-chip { display: flex; align-items: center; gap: 10px; padding: 4px 10px 4px 4px; border-radius: 24px; background: var(--panel); border: 1px solid var(--border); box-shadow: var(--shadow-sm); position: relative; transition: all .2s; }
.user-chip:hover { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(37,99,235,.1); }
.chip-arrow { font-size: 11px; color: var(--text-dim); transition: transform .2s; }
.user-chip:hover .chip-arrow { transform: rotate(180deg); }

/* 用户下拉菜单（固定在头像正下方弹出，left/top 由 JS 动态计算） */
.user-dropdown {
  position: fixed; z-index: 999; top: 70px; left: 200px; right: auto;
  width: 220px; background: var(--panel); border: 1px solid var(--border);
  border-radius: 14px; box-shadow: 0 12px 32px rgba(15,23,42,.14);
  padding: 8px; opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity .18s, transform .18s, visibility .18s;
}
.user-dropdown.open { opacity: 1; visibility: visible; transform: translateY(0); }
.ud-head { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--border); margin-bottom: 6px; }
.ud-head .avatar, .ud-head .avatar-img { width: 38px; height: 38px; font-size: 17px; }
.ud-name { font-size: 14px; font-weight: 700; }
.ud-level { font-size: 12px; }
.ud-item {
  display: flex; align-items: center; gap: 8px; width: 100%;
  padding: 9px 12px; border-radius: 9px; font-size: 13.5px; color: var(--text);
  transition: all .15s; text-align: left;
}
.ud-item:hover { background: rgba(37,99,235,.08); color: var(--accent); }
.ud-danger { color: #e11d48; border: none; background: none; cursor: pointer; }
.ud-danger:hover { background: rgba(225,29,72,.08); color: #e11d48; }
.ud-divider { height: 1px; background: var(--border); margin: 6px 4px; }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--grad); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 15px; flex-shrink: 0; overflow: hidden; }
.avatar-img { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; flex-shrink: 0; border: 1px solid var(--border); }
.user-info { display: flex; flex-direction: column; line-height: 1.2; }
.user-info b { font-size: 13px; }
.user-info i { font-size: 11px; font-style: normal; }

/* 游客价格遮挡提示 */
.p-price { position: relative; }
.price-hint {
  position: absolute; bottom: calc(100% + 8px); left: 0; white-space: nowrap;
  background: #fff; border: 1px solid var(--accent); color: var(--accent);
  padding: 6px 12px; border-radius: 8px; font-size: 12px; font-weight: 600;
  opacity: 0; visibility: hidden; transition: all .2s; z-index: 20;
  box-shadow: var(--shadow);
}
.price-hint::after {
  content: ''; position: absolute; top: 100%; left: 16px;
  border: 6px solid transparent; border-top-color: var(--accent);
}
.p-price:hover .price-hint { opacity: 1; visibility: visible; }
.price-lock { color: var(--text-dim); }

/* 滑动图片验证码 */
.scaptcha { user-select: none; margin: 4px 0 14px; }
.scaptcha-canvas { width: 100%; max-width: 300px; display: block; border-radius: 10px; border: 1px solid var(--border); }
.scaptcha-piece { position: absolute; pointer-events: none; filter: drop-shadow(0 2px 4px rgba(0,0,0,0.35)); }
.scaptcha { position: relative; }
.scaptcha-piece { left: 0; }
.scaptcha-track {
  position: relative; margin-top: 10px; height: 40px; border-radius: 10px;
  background: var(--bg); border: 1px solid var(--border); overflow: hidden;
}
.scaptcha-track.ok { border-color: var(--success); background: rgba(22,163,74,.08); }
.scaptcha-track.err { animation: scaptchaShake .35s; }
@keyframes scaptchaShake { 0%,100%{transform:translateX(0)} 25%{transform:translateX(-6px)} 75%{transform:translateX(6px)} }
.scaptcha-hint {
  position: absolute; inset: 0; display: grid; place-items: center;
  font-size: 12px; color: var(--text-dim); pointer-events: none;
}
.scaptcha-thumb {
  position: absolute; top: 0; left: 0; width: 46px; height: 100%;
  display: grid; place-items: center; font-size: 18px; font-weight: 700; color: #fff;
  background: var(--grad); cursor: grab; z-index: 2; touch-action: none;
}
.scaptcha-thumb:active { cursor: grabbing; }
.scaptcha-track.ok .scaptcha-thumb { background: var(--success); }

.auth-tabs { display: flex; gap: 6px; margin-bottom: 20px; }.auth-tabs button { flex: 1; padding: 9px; border-radius: 8px; background: var(--bg); border: 1px solid var(--border); color: var(--text-dim); font-size: 13px; transition: all .2s; }
.auth-tabs button.active { background: var(--grad); color: #fff; border-color: transparent; }
.auth-tip { margin-top: 14px; text-align: center; font-size: 13px; color: var(--text-dim); }
.auth-tip a { color: var(--accent); }

/* 登录/注册弹窗：左侧"加入我们" + 右侧表单 */
.auth-modal { max-width: 760px; padding: 0; overflow: hidden; position: relative; }
.auth-modal .modal-close { position: absolute; top: 14px; right: 18px; z-index: 3; }
.auth-panel { display: grid; grid-template-columns: 320px 1fr; }
.auth-left {
  padding: 40px 32px; color: #fff; position: relative; overflow: hidden;
  background: linear-gradient(160deg, #2563eb 0%, #7c3aed 100%);
}
.auth-left::before {
  content: ''; position: absolute; right: -50px; top: -50px; width: 220px; height: 220px;
  border-radius: 50%; background: radial-gradient(circle, rgba(255,255,255,0.25), transparent 70%);
}
.auth-left::after {
  content: ''; position: absolute; left: -40px; bottom: -60px; width: 180px; height: 180px;
  border-radius: 50%; background: radial-gradient(circle, rgba(255,255,255,0.15), transparent 70%);
}
.auth-left-logo { font-size: 18px; font-weight: 800; margin-bottom: 28px; display: flex; align-items: center; gap: 6px; position: relative; z-index: 1; }
.auth-left-logo .chip { background: rgba(255,255,255,0.2); }
.auth-left h2 { font-size: 30px; font-weight: 800; line-height: 1.2; position: relative; z-index: 1; }
.auth-left-sub { font-size: 14px; opacity: 0.9; margin: 6px 0 24px; position: relative; z-index: 1; }
.auth-left-feats { list-style: none; display: flex; flex-direction: column; gap: 14px; margin-bottom: 30px; position: relative; z-index: 1; }
.auth-left-feats li { font-size: 13px; display: flex; align-items: center; gap: 6px; }
.auth-left-feats b { font-weight: 700; }
.auth-join-btn {
  width: 100%; background: #fff; color: #2563eb; font-weight: 700;
  box-shadow: 0 6px 18px rgba(0,0,0,0.15); position: relative; z-index: 1;
}
.auth-join-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0,0,0,0.22); }
.auth-right { padding: 36px 34px; position: relative; }
.auth-right h3 { font-size: 22px; margin-bottom: 18px; }
@media (max-width: 640px) {
  .auth-panel { grid-template-columns: 1fr; }
  .auth-left { display: none; }
}

/* 支付方式选择 */
.pay-options { display: flex; gap: 12px; margin: 6px 0 16px; }
.pay-option { flex: 1; display: flex; align-items: center; gap: 10px; padding: 14px; border-radius: 12px; border: 2px solid var(--border); background: var(--bg); cursor: pointer; transition: all .2s; }
.pay-option .pay-icon { font-size: 28px; }
.pay-option .pay-name { font-size: 14px; font-weight: 600; }
.pay-option .pay-desc { font-size: 12px; color: var(--text-dim); }
.pay-option.active { border-color: var(--accent); background: rgba(37, 99, 235, 0.04); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.10); }
.pay-option.wechat.active { border-color: #16a34a; background: rgba(22, 163, 74, 0.04); box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.10); }
.pay-option.alipay.active { border-color: #0284c7; background: rgba(2, 132, 199, 0.04); box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.10); }

/* 个人中心 */
.profile-grid { display: grid; grid-template-columns: 300px 1fr; gap: 24px; margin: 32px 0; align-items: start; }
.profile-card { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; text-align: center; box-shadow: var(--shadow-sm); }
.profile-card .big-avatar { width: 80px; height: 80px; border-radius: 50%; background: var(--grad); color: #fff; display: grid; place-items: center; font-size: 34px; font-weight: 800; margin: 0 auto 16px; box-shadow: var(--glow); }
.profile-card h3 { font-size: 20px; margin-bottom: 4px; }
.level-badge { display: inline-block; padding: 4px 14px; border-radius: 20px; font-size: 13px; font-weight: 700; margin: 8px 0 16px; }
.level-progress { text-align: left; margin-top: 16px; }
.level-progress .lp-head { display: flex; justify-content: space-between; font-size: 12px; color: var(--text-dim); margin-bottom: 6px; }
.profile-main .panel { padding: 24px; }

/* 账户设置项 */
.set-item { display: flex; align-items: center; justify-content: space-between; padding: 14px 4px; border-bottom: 1px solid var(--border); cursor: pointer; transition: all .2s; }
.set-item:last-child { border-bottom: none; }
.set-item:hover { padding-left: 8px; }
.set-item .si-title { font-size: 15px; font-weight: 600; }
.set-item .si-sub { font-size: 13px; color: var(--text-dim); margin-top: 2px; }
.set-item .si-arrow { font-size: 22px; color: var(--text-dim); }

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

/* 响应式 */
@media (max-width: 768px) {
  .hero { padding: 32px 24px; }
  .hero h1 { font-size: 30px; }
  .nav { display: none; }
  .form-row { grid-template-columns: 1fr; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
}
