/* ==========================================================================
   动漫周边 · components.css — 三页共用组件
   ========================================================================== */

.wrap {
  width: min(100% - 48px, var(--wrap));
  margin-inline: auto;
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 16px; top: -60px;
  z-index: 100;
  padding: 10px 18px;
  background: var(--brand);
  color: var(--cream);
  border-radius: 0 0 8px 8px;
  font-size: 15px;
  transition: top .18s ease;
}
.skip-link:focus { top: 0; }

/* ---------------------------------------------------------------- header */
.site-header {
  position: relative;
  z-index: 40;
  background: var(--brand);
  color: var(--cream);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 36px;
  height: var(--header-h);
}
.brand {
  display: inline-flex;
  align-items: center;
  color: #fff;
  flex: none;
}
.brand-mark { display: block; width: 26px; height: 26px; }
.brand:hover .brand-mark { transform: rotate(-8deg); }
.brand-mark { transition: transform .2s ease; }

.main-nav {
  display: flex;
  align-items: center;
  gap: 34px;
  margin-inline: auto;
  font-size: 16.5px;
  letter-spacing: .01em;
}
.main-nav a {
  position: relative;
  padding: 6px 0;
  color: var(--cream);
  white-space: nowrap;
  transition: color .16s ease;
}
.main-nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  background: var(--cream);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform .2s ease;
}
.main-nav a:hover { color: #fff; }
.main-nav a:hover::after,
.main-nav a.is-active::after { transform: scaleX(1); }
.main-nav .nav-home { color: #fff; }

.menu-btn {
  display: none;
  width: 42px; height: 42px;
  margin-left: auto;
  padding: 10px;
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 8px;
  background: transparent;
  color: var(--cream);
  cursor: pointer;
}
.menu-btn span {
  display: block;
  height: 2px;
  margin: 4px 0;
  background: currentColor;
  border-radius: 2px;
}
.mobile-menu {
  position: absolute;
  left: 0; right: 0; top: 100%;
  background: var(--brand);
  border-top: 1px solid rgba(255,255,255,.12);
  box-shadow: 0 18px 30px rgba(10,20,40,.25);
}
.mobile-menu nav { display: grid; padding: 10px 24px 18px; }
.mobile-menu a {
  padding: 13px 4px;
  color: var(--cream);
  font-size: 16px;
  border-bottom: 1px solid rgba(255,255,255,.10);
}
.mobile-menu a:last-child { border-bottom: 0; }

/* ------------------------------------------------------------ section head */
.sec-head {
  display: flex;
  align-items: center;
  gap: 10px;
}
.sec-head h2 {
  font-size: 27px;
  font-weight: 800;
  letter-spacing: .01em;
  color: var(--ink);
}
.sec-star {
  flex: none;
  width: 22px; height: 22px;
  color: var(--brand);
}
.sec-sub {
  margin-left: 10px;
  font-size: 15px;
  color: var(--muted);
  font-weight: 400;
}

/* ----------------------------------------------------------------- buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 50px;
  padding: 0 26px;
  border-radius: 6px;
  font-size: 17.5px;
  font-weight: 600;
  line-height: 1;
  border: 1px solid transparent;
  transition: background .16s ease, color .16s ease, border-color .16s ease, transform .16s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-2); }
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); }

.btn-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 36px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: transparent;
  color: var(--brand);
  font-size: 15px;
  font-weight: 600;
  transition: background .16s ease, color .16s ease, border-color .16s ease;
}
.btn-pill:hover { background: var(--brand); color: #fff; border-color: var(--brand); }

/* ------------------------------------------------------------------ cards */
.category-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  height: 245px;
  padding: 17px 12px 16px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--ink);
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.category-card:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}
.category-icon {
  width: 62px; height: 62px;
  margin: 2px auto 10px;
  color: var(--brand);
}
.category-name { font-size: 19px; font-weight: 700; }
.category-desc {
  margin-top: 8px;
  font-size: 14px;
  line-height: 1.7;
  color: var(--muted);
}

.product-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 11px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--ink);
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.product-card:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}
.product-media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 194 / 116;
  border: 1px solid var(--line-soft);
  border-radius: 8px;
  background: #f8f3ea;
}
.product-media img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center;
  mix-blend-mode: multiply;
}
.product-media.is-square { aspect-ratio: 1 / 1; }
.product-type {
  position: absolute;
  top: 8px; left: 8px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(255,255,255,.9);
  color: var(--brand);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: .02em;
}
.product-title {
  margin-top: 10px;
  font-size: 19.5px;
  font-weight: 700;
  line-height: 1.4;
}
.product-title span { display: block; }
.product-spec {
  margin-top: 7px;
  font-size: 14.5px;
  line-height: 1.55;
  color: var(--muted);
}
.product-summary {
  margin-top: 7px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
}
.product-foot {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 9px;
  margin-top: auto;
  padding-top: 12px;
}
.product-price {
  font-size: 21px;
  font-weight: 800;
  letter-spacing: .01em;
  color: var(--brand);
  white-space: nowrap;
}
.product-price small {
  display: block;
  margin-top: 2px;
  font-size: 11.5px;
  font-weight: 500;
  color: var(--dim);
  letter-spacing: 0;
}
/* 目录站无价格：日期 + 分类的等宽槽位 */
.product-price.is-cat {
  font-size: 15.5px;
  font-weight: 700;
  letter-spacing: .01em;
  color: var(--ink);
}
.product-price.is-cat small {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
}
.product-foot .btn-pill {
  align-self: center;
  min-width: 148px;
  height: 34px;
}

.faq-card {
  padding: 14px 15px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 10px;
}
.faq-q {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.45;
  color: var(--ink);
}
.faq-mark {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px; height: 20px;
  margin-top: 1px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
  color: var(--brand);
}
.faq-a {
  margin-top: 8px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
}

/* ------------------------------------------------------------- breadcrumb */
.crumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 14px;
  color: var(--muted);
}
.crumb a { color: var(--muted); }
.crumb a:hover { color: var(--brand); }
.crumb-sep::before { content: "/"; color: var(--line-strong); }
.crumb span[aria-current] { color: var(--ink-soft); }

/* ----------------------------------------------------------------- footer */
.footer-gap { height: 28px; background: var(--bg); }
.site-footer {
  background: var(--brand);
  color: var(--cream);
}
.footer-inner {
  display: grid;
  grid-template-columns: 1.25fr 1.25fr .85fr 1.3fr;
  gap: 44px;
  padding-top: 26px;
  padding-bottom: 42px;
  height: 174px;
  position: relative;
}
.footer-brand .footer-name {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 33px;
  font-weight: 800;
  color: #fff;
  letter-spacing: .02em;
}
.footer-brand .footer-name svg { width: 20px; height: 20px; color: var(--gold); }
.footer-tag {
  margin-top: 9px;
  font-size: 15.5px;
  line-height: 1.5;
  color: var(--cream-soft);
}
.footer-col h3 {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 9px;
}
.footer-links {
  display: grid;
  grid-template-columns: repeat(3, auto);
  gap: 7px 22px;
  justify-content: start;
  font-size: 14.5px;
}
.footer-links.one-col { grid-template-columns: 1fr; }
.footer-links a { color: var(--cream-soft); }
.footer-links a:hover { color: #fff; }
.footer-note {
  font-size: 14.5px;
  line-height: 1.7;
  color: var(--cream-soft);
}
.footer-copy {
  position: absolute;
  right: 24px; bottom: 16px;
  font-size: 14px;
  color: var(--cream-soft);
}
.footer-copy::before { content: "© "; }

/* ------------------------------------------------------------ inner pages */
.page-hero {
  border-bottom: 1px solid var(--line);
  background: var(--bg);
}
.page-hero .wrap { padding-top: 26px; padding-bottom: 30px; }
.page-hero h1 {
  margin-top: 14px;
  font-size: 46px;
  font-weight: 800;
  letter-spacing: .01em;
  color: var(--ink);
}
.page-hero .lede {
  margin-top: 12px;
  max-width: 780px;
  font-size: 18px;
  line-height: 1.75;
  color: var(--ink-soft);
}
.page-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  margin-top: 20px;
  font-size: 15px;
  color: var(--muted);
}
.page-stats b {
  font-size: 21px;
  color: var(--brand);
  margin-right: 5px;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  padding: 18px 0 10px;
}
.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.chip {
  height: 38px;
  padding: 0 17px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-panel);
  color: var(--ink-soft);
  font-size: 14.5px;
  font-weight: 500;
  cursor: pointer;
  transition: background .16s ease, color .16s ease, border-color .16s ease;
}
.chip:hover { border-color: var(--line-strong); color: var(--brand); }
.chip[aria-pressed="true"] {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}
.sort-wrap {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-left: auto;
  font-size: 14px;
  color: var(--muted);
}
.sort-wrap select {
  height: 38px;
  padding: 0 34px 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-panel);
  color: var(--ink-soft);
  font-size: 14.5px;
  font-family: inherit;
  cursor: pointer;
}
.result-count {
  width: 100%;
  font-size: 14px;
  color: var(--dim);
}

.empty-state {
  display: none;
  padding: 54px 20px;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--line-strong);
  border-radius: 12px;
}
.empty-state.is-on { display: block; }
.empty-state p { font-size: 16px; }
.empty-state button {
  margin-top: 14px;
  height: 40px;
  padding: 0 20px;
  border: 1px solid var(--brand);
  border-radius: 999px;
  background: transparent;
  color: var(--brand);
  font-size: 15px;
  font-family: inherit;
  cursor: pointer;
}

.tag {
  display: inline-flex;
  align-items: center;
  height: 28px;
  padding: 0 11px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: .02em;
}

.article {
  max-width: 820px;
  color: var(--ink-soft);
}
.article h2 {
  margin: 34px 0 12px;
  font-size: 25px;
  font-weight: 800;
  color: var(--ink);
  scroll-margin-top: 96px;
}
.article h2:first-child { margin-top: 0; }
.article p {
  font-size: 16.5px;
  line-height: 1.9;
  color: var(--ink-soft);
}
.article p + p { margin-top: 12px; }

.spec-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}
.spec-table th,
.spec-table td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--line-soft);
  text-align: left;
  vertical-align: top;
}
.spec-table th {
  width: 30%;
  color: var(--dim);
  font-weight: 500;
  background: var(--bg-card);
}
.spec-table td { color: var(--ink-soft); }
.spec-table tr:last-child th,
.spec-table tr:last-child td { border-bottom: 0; }

/* --------------------------------------------------------------- helpers */
.is-hidden { display: none !important; }
.focus-ring:focus-visible,
a:focus-visible,
button:focus-visible,
select:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 4px;
}

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

/* 分类页：竖版商品图与品类快捷跳转 */
.product-media.is-portrait { aspect-ratio: 4 / 5; }
.product-media.is-portrait img {
  object-fit: contain;
  object-position: center;
  background: #f8f3ea;
}
.cat-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}
.cat-quick a {
  display: inline-flex;
  align-items: center;
  height: 34px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-card);
  color: var(--ink-soft);
  font-size: 13.5px;
  transition: border-color .16s ease, color .16s ease;
}
.cat-quick a:hover { border-color: var(--line-strong); color: var(--brand); }

/* 详情页：头部补充信息 */
.detail-tag { margin-top: 12px; }
.detail-spec {
  margin-top: 10px;
  font-size: 15.5px;
  color: var(--muted);
}

/* 详情页：细节图集与规格表 */
.detail-gallery { padding: 26px 0 6px; border-bottom: 1px solid var(--line); }
.detail-subtitle {
  font-size: 25px;
  font-weight: 800;
  color: var(--ink);
}
.detail-specs { padding: 26px 0 4px; }
.specs-card {
  max-width: 860px;
  padding: 20px 24px 8px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg-card);
}
.specs-card h2 {
  margin-bottom: 10px;
  font-size: 25px;
  font-weight: 800;
  color: var(--ink);
}
.detail-body-wrap { padding: 10px 0 8px; }
