/* ============ 商城专属样式（分类/搜索/详情/对比/购物车） ============ */
/* 复用 subpage.css 变量：--ink --white --cream --celadon --muted --line --soft --shadow --display --body --deep */

/* ---------- 商城 hero 品牌 logo ---------- */
.store-hero-logo{display:block;height:84px;width:auto;margin:0 auto 18px}
[data-theme=dark] .store-hero-logo{filter:brightness(0) invert(1);opacity:.94}
@media(max-width:560px){.store-hero-logo{height:60px;margin-bottom:14px}}

/* ---------- 分类 tab ---------- */
.store-tabs{display:flex;flex-wrap:wrap;gap:10px;margin:0 0 22px}
.store-tab{border:1px solid var(--line);background:var(--white);color:var(--muted);border-radius:999px;padding:8px 20px;font-size:13px;cursor:pointer;font-family:inherit;transition:.2s}
.store-tab:hover{color:var(--ink);border-color:var(--soft)}
.store-tab.is-active{background:var(--ink);color:var(--white);border-color:var(--ink)}

/* ---------- 型号筛选（watch 分类下的二级筛选：WV 方屏 / MV 圆屏） ---------- */
.store-series-filter{display:flex;flex-wrap:wrap;gap:8px;margin:-8px 0 22px}
.store-series-filter[hidden]{display:none}
.store-series-tab{background:var(--cream);border-color:var(--line);padding:6px 16px}
.store-series-tab.is-active{background:var(--accent);color:var(--white);border-color:var(--accent)}
.store-compare-link{align-self:center;margin-left:6px;font-size:12.5px;color:var(--ink);text-decoration:underline;text-underline-offset:3px}
.store-compare-link:hover{color:var(--accent)}

/* ---------- 分类引导语 ---------- */
.store-cat-intro{font-size:14px;color:var(--muted);margin:-8px 0 22px;max-width:720px}
.store-cat-intro[hidden]{display:none}

/* ---------- 信任背书 ---------- */
.store-trust{display:flex;flex-wrap:wrap;gap:12px 30px;justify-content:center;margin-top:26px}
.store-trust span{font-size:12.5px;letter-spacing:1px;color:var(--muted);position:relative;padding-left:16px}
.store-trust span::before{content:'';position:absolute;left:0;top:50%;transform:translateY(-50%);width:6px;height:6px;border-radius:50%;background:var(--ink)}

/* ---------- 搜索框 ---------- */
.store-search{display:flex;align-items:center;gap:10px;background:var(--white);border:1px solid var(--line);border-radius:999px;padding:9px 18px;margin-bottom:20px;max-width:440px}
.store-search svg{width:18px;height:18px;stroke:var(--muted);fill:none;stroke-width:2;stroke-linecap:round;flex:none}
.store-search input{flex:1;border:0;background:none;font-family:inherit;font-size:14px;color:var(--ink);outline:none;min-width:0}
.store-search input::placeholder{color:var(--muted)}
.store-search-clear{border:0;background:none;color:var(--muted);font-size:12px;cursor:pointer;padding:0;flex:none}
.store-empty{margin-top:20px}

/* ---------- 商品卡增强 ---------- */
.sub-store-grid .store-media{position:relative;aspect-ratio:1/1}
.store-featured{position:absolute;top:12px;left:12px;background:var(--ink);color:var(--white);font-size:11px;letter-spacing:1px;padding:4px 12px;border-radius:999px}
.store-tags{display:flex;flex-wrap:wrap;gap:6px;margin-top:8px}
.store-tags span{font-size:10.5px;border:1px solid var(--line);border-radius:999px;padding:2px 10px;color:var(--muted)}

/* ---------- 库存展示 ---------- */
.sub-store-grid .store-foot{gap:10px}
.store-stock{font-size:11.5px;color:var(--muted);white-space:nowrap}
.sub-store-grid .store-stock{margin-right:auto}
.store-stock.is-low{color:#c77f0a}
.store-stock.is-out{color:#db302c}

/* ---------- 详情弹层（左图右文分栏） ---------- */
.store-dialog{border:0;background:transparent;padding:0;max-width:960px;width:94vw}
.store-dialog::backdrop,.store-cart-dialog::backdrop{background:#031412cc;backdrop-filter:blur(3px)}
.store-dialog-box{background:var(--white);border-radius:22px;overflow:hidden;box-shadow:0 32px 80px #00000055;max-height:90vh;overflow-y:auto}
.store-dialog-media{background:var(--celadon);padding:20px;display:flex;flex-direction:column;gap:14px;min-width:0}
.store-dialog-mainimg{display:block;width:100%;height:auto;aspect-ratio:1/1;object-fit:contain;border-radius:14px;background:var(--white)}
.store-dialog-media svg{width:64px;height:64px;stroke:var(--soft);fill:none;stroke-width:2}
/* 配色选择器（腕表配色 / 戒指四色） */
.store-swatches{display:flex;flex-direction:column;gap:8px}
.store-swatches-label{font-size:12px;letter-spacing:1.5px;color:var(--muted)}
.store-swatches-row{display:flex;flex-wrap:wrap;gap:10px}
.store-swatch{display:inline-flex;align-items:center;gap:8px;border:1px solid var(--line);background:var(--white);border-radius:999px;padding:6px 14px 6px 8px;cursor:pointer;font-family:inherit;font-size:13px;color:var(--ink);transition:.18s}
.store-swatch:hover{border-color:var(--ink)}
.store-swatch.is-active{border-color:var(--ink);background:var(--cream);box-shadow:inset 0 0 0 1px var(--ink)}
.store-swatch-dot{width:20px;height:20px;border-radius:50%;flex:none;border:1px solid #00000018;box-shadow:inset 0 0 0 1px #ffffff55}
.store-swatch-name{line-height:1}

.store-dialog-info{padding:26px 28px;display:flex;flex-direction:column;gap:16px;min-width:0}
.store-dialog-head{display:flex;justify-content:space-between;align-items:flex-start;gap:14px}
.store-dialog-titles{min-width:0}
.store-dialog-title{font-family:var(--display);font-size:23px;font-weight:500;line-height:1.3;margin-top:4px}
.store-dialog-close{border:0;background:var(--cream);color:var(--ink);width:34px;height:34px;border-radius:50%;font-size:15px;cursor:pointer;flex:none;display:flex;align-items:center;justify-content:center;transition:.2s;line-height:1}
.store-dialog-close:hover{background:var(--ink);color:var(--white)}

.store-dialog-pricerow{display:flex;align-items:baseline;gap:12px;flex-wrap:wrap}
.store-dialog-price{font-family:var(--display);font-size:30px;font-weight:600;color:var(--ink)}

.store-dialog-specs{display:flex;flex-wrap:wrap;gap:8px}
.store-dialog-specs span{font-size:12.5px;color:var(--ink);background:var(--cream);border:1px solid var(--line);border-radius:8px;padding:6px 12px}
.store-dialog-desc{font-size:13px;color:var(--muted)}
.store-dialog-section h4{font-size:12px;letter-spacing:1.5px;color:var(--muted);margin-bottom:8px}
.store-dialog-text{font-size:13px;color:var(--ink);line-height:1.7}
.store-feat-list{list-style:none;display:flex;flex-wrap:wrap;gap:8px}
.store-feat-list li{font-size:12.5px;padding:6px 14px;border-radius:999px;border:1px solid var(--line)}
.store-feat-list.is-open li{background:var(--celadon);color:var(--ink)}
.store-feat-list.is-open li::before{content:'● '}
.store-feat-list.is-hidden li{color:var(--muted);opacity:.75}
.store-feat-list.is-hidden li::before{content:'○ '}
.store-dialog-stock{font-size:12.5px}
.store-dialog-actions{display:flex;gap:10px;flex-wrap:wrap;padding-top:4px}
.store-dialog-actions .store-buy{flex:1;min-width:0}
.store-shape-switch{width:100%;justify-content:center;font-size:12.5px;padding:8px 16px}

/* 两栏（桌面 / 平板横屏） */
@media(min-width:760px){
  .store-dialog-box{display:grid;grid-template-columns:1fr 1.05fr;align-items:stretch}
  .store-dialog-media{padding:24px}
  .store-dialog-info{padding:30px 32px}
}

/* 购买按钮（基础 + 变体） */
.store-buy{display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:11px 20px;border-radius:999px;font-size:13.5px;font-family:inherit;font-weight:500;line-height:1;border:1px solid transparent;cursor:pointer;transition:.2s}
.store-buy:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.store-buy-primary{background:var(--ink);color:var(--white);border-color:var(--ink)}
.store-buy-primary:hover{background:var(--deep);border-color:var(--deep);color:var(--white)}
.store-buy-ghost{border-color:var(--line);color:var(--ink);background:var(--white)}
.store-buy-ghost:hover{background:var(--celadon);color:var(--ink);border-color:var(--line)}
.store-buy-link{background:transparent;border-color:transparent;color:var(--ink);text-decoration:underline;text-underline-offset:3px}
.store-buy-link:hover{background:transparent;color:var(--accent)}
.store-buy:disabled{opacity:.45;cursor:not-allowed}

/* ---------- 版本对比矩阵 ---------- */
#store-compare{overflow-x:auto}
.store-compare-tabs{display:flex;gap:10px;margin-bottom:16px}
.store-compare-note{font-size:12px;color:var(--muted);margin-bottom:14px}
.store-compare-table{width:100%;border-collapse:collapse;background:var(--white);border:1px solid var(--line);border-radius:12px;overflow:hidden;font-size:13px;min-width:560px}
.store-compare-table th,.store-compare-table td{padding:12px 14px;border-bottom:1px solid var(--line);text-align:center}
.store-compare-table thead th{background:var(--celadon);border-bottom:1px solid var(--line)}
.store-compare-table tbody th{text-align:left;color:var(--muted);font-weight:500;white-space:nowrap}
.store-compare-table tbody tr:last-child td,.store-compare-table tbody tr:last-child th{border-bottom:0}
.store-compare-tier{display:block;font-family:var(--display);font-weight:500;color:var(--ink)}
.store-compare-price{display:block;font-size:11px;color:var(--muted);margin-top:2px}
.store-compare-table td.is-open{color:var(--ink);font-weight:700}
.store-compare-table td.is-hidden{color:var(--muted)}
.store-compare-table td.is-none{color:var(--soft)}

/* ---------- 购物车 ---------- */
.store-cart-fab{position:fixed;right:24px;bottom:24px;z-index:60;width:54px;height:54px;border-radius:50%;border:0;background:var(--ink);color:var(--white);cursor:pointer;box-shadow:0 12px 30px #00000033;display:flex;align-items:center;justify-content:center;transition:transform .2s}
.store-cart-fab:hover{transform:translateY(-2px)}
.store-cart-fab svg{width:24px;height:24px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.store-cart-badge{position:absolute;top:-4px;right:-4px;background:#db302c;color:#fff;font-size:11px;min-width:20px;height:20px;border-radius:999px;display:flex;align-items:center;justify-content:center;padding:0 5px}
.store-cart-dialog{border:0;background:transparent;padding:0;max-width:460px;width:94vw}
.store-cart-box{background:var(--white);border-radius:18px;overflow:hidden;box-shadow:0 24px 60px #00000040;max-height:86vh;display:flex;flex-direction:column}
.store-cart-head{display:flex;justify-content:space-between;align-items:center;padding:20px 24px;border-bottom:1px solid var(--line)}
.store-cart-head h3{font-family:var(--display);font-size:20px;font-weight:500}
.store-cart-body{padding:20px 24px;overflow-y:auto}
.store-cart-empty{color:var(--muted);font-size:14px;text-align:center;padding:24px 0}
.store-cart-list{list-style:none;display:flex;flex-direction:column;gap:12px}
.store-cart-item{display:flex;justify-content:space-between;align-items:center;gap:12px}
.store-cart-info{display:flex;flex-direction:column;gap:2px;min-width:0}
.store-cart-name{font-size:14px;color:var(--ink)}
.store-cart-price{font-size:12px;color:var(--muted)}
.store-cart-remove{border:0;background:none;color:var(--muted);font-size:12px;cursor:pointer;text-decoration:underline;flex:none}
.store-cart-total{display:flex;justify-content:space-between;align-items:center;margin-top:16px;padding-top:14px;border-top:1px solid var(--line);font-size:14px}
.store-cart-total strong{font-family:var(--display);font-size:20px}
.store-cart-listtext{width:100%;margin-top:14px;border:1px solid var(--line);border-radius:8px;padding:10px;font-family:inherit;font-size:12px;color:var(--muted);resize:vertical;background:var(--cream)}
.store-cart-foot{display:flex;gap:10px;padding:16px 24px 20px;border-top:1px solid var(--line)}
.store-cart-foot .store-buy{flex:1}

/* ---------- toast ---------- */
.store-toast{position:fixed;left:50%;bottom:96px;transform:translateX(-50%) translateY(12px);background:var(--deep);color:#fff;font-size:13px;padding:10px 20px;border-radius:999px;opacity:0;pointer-events:none;transition:.25s;z-index:80}
.store-toast.is-show{opacity:1;transform:translateX(-50%) translateY(0)}

/* ---------- 品牌故事 ---------- */
.store-story{max-width:760px;font-family:var(--display);font-size:18px;line-height:1.9;color:var(--ink)}

/* ---------- 移动端 ---------- */
@media (max-width:720px){
  .store-search{max-width:100%}
  .store-dialog-box{display:block}
  .store-dialog-actions{justify-content:stretch}
  .store-dialog-actions .store-buy{flex:1}
  .store-cart-fab{right:16px;bottom:16px}
}

