.catalog-page {
  --catalog-ink: #2c1b15;
  --catalog-muted: #674d40;
  --catalog-accent: #9c291f;
  --catalog-paper: #f5eadb;
  --catalog-line: #e4d4c5;
  --catalog-studio-base: #261610;
  scrollbar-gutter: stable;
}

html:has(body.catalog-page) { scrollbar-gutter: stable; }

.catalog {
  /* 顶部一段直接用纸色，让通栏底边的圆拱与下方背景严丝合缝 */
  background: linear-gradient(180deg, var(--catalog-paper), var(--catalog-paper) 520px, #f9efe2);
  color: var(--catalog-ink);
  line-break: strict;
}

.catalog-shell {
  width: min(calc(100% - clamp(32px, 5.5vw, 80px)), 1320px);
  margin-inline: auto;
}

@property --catalog-top-shade {
  syntax: '<number>';
  inherits: true;
  initial-value: .38;
}

.catalog-hero {
  --catalog-top-shade: .38;
  --catalog-title-shade: linear-gradient(90deg, #1e0e09f5, #21110be0 24%, #21110b80 45%, transparent 77%);
  --page-arc: clamp(18px, 2.4vw, 36px);
  --page-arc-paper: var(--catalog-paper);
  position: relative;
  aspect-ratio: 2048 / 768;
  min-height: calc(var(--site-header-height) + 190px);
  padding-top: 0;
  isolation: isolate;
  overflow: hidden;
  background: #2b160f;
  color: #fff0d8;
}

/* 通栏与栏目页同一套：图完整显示（aspect 与 2048×768 原图同比，不再上下裁），
   顶到页面最上沿让导航浮在图上，底边压一道纸色圆拱 */
.catalog-hero::before {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 2;
  height: var(--page-arc);
  background: var(--page-arc-paper);
  clip-path: inset(0 round 50% 50% 0 0 / var(--page-arc) var(--page-arc) 0 0);
  pointer-events: none;
  content: '';
}

.catalog-hero:is([data-scene="kaoyu"], [data-scene="maocai"], [data-scene="jianghucai"]) { --catalog-top-shade: .47; }
.catalog-hero:is([data-scene="huoguo"], [data-scene="meiwayu"], [data-scene="shaokao"]) { --catalog-top-shade: .55; }
.catalog-hero:is([data-scene="ganguo"], [data-scene="tangliao"], [data-scene="suanlafen"]) { --catalog-top-shade: .60; }

@media (prefers-reduced-motion: no-preference) {
  .catalog-hero[data-scene-fade] { transition: --catalog-top-shade 210ms ease-out; }
}

/* 切到具体品类时，头图换成甲方提供的品类 banner（图里已带标题文案）：
   站内大标题、代表产品按钮和左侧压暗都收起，避免和 banner 上的字叠在一起。 */
.catalog-hero:not([data-scene="all"]) {
  --catalog-title-shade: linear-gradient(90deg, #1e0e0914, #21110b08 36%, transparent 66%);
  min-height: clamp(280px, 30vw, 430px);
}
.catalog-hero:not([data-scene="all"]) .catalog-hero-inner { padding-block: 0; }
.catalog-hero:not([data-scene="all"]) .catalog-hero-copy h1 {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.catalog-hero:not([data-scene="all"]) .catalog-hero-caption { display: none; }
/* 品类页的 banner 自带标题文案，这行副标题也一起收起 */
.catalog-hero:not([data-scene="all"]) .catalog-hero-lead { display: none; }

/* 窄屏用的是 2:1 的手机版 banner，头图高度按 50vw 算，避免把两侧文案裁掉 */
@media (max-width: 640px) {
  .catalog-hero:not([data-scene="all"]) { min-height: calc(var(--site-header-height) + 50vw); }
}

.catalog-hero > img {
  position: absolute;
  z-index: -2;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

.catalog-collection-image { object-position: right 52%; }

.catalog-hero::after {
  position: absolute;
  z-index: -1;
  inset: 0;
  background:
    linear-gradient(180deg, rgb(18 10 7 / var(--catalog-top-shade)) 0 calc(var(--site-header-height) * .64),
      transparent calc(var(--site-header-height) + 68px)),
    var(--catalog-title-shade);
  content: '';
}

/* 标题从左中挪到左下：和四张栏目页通栏同一套定位（贴内容栏左边线、落在圆拱上方） */
.catalog-hero-inner {
  position: absolute;
  right: max(clamp(24px, 6vw, 82px), calc((100% - 1220px) / 2));
  bottom: calc(var(--page-arc) + clamp(12px, 1.8vw, 24px));
  left: max(clamp(24px, 6vw, 82px), calc((100% - 1220px) / 2));
  z-index: 3;
  display: flex;
  align-items: flex-end;
  box-sizing: border-box;
  width: auto;
  min-height: 0;
  margin: 0;
  padding: 0;
}

.catalog-hero-copy { min-width: 0; }

.catalog-hero h1 {
  margin: 0;
  color: #fdf8f1;
  font-size: clamp(2.55rem, 6.2vw, 5.2rem);
  line-height: 1.12;
  text-align: left;
  text-shadow: 0 2px 14px #1e0e09a6;
}

/* 大标题下一行定性文案，跟栏目页通栏里的副标题同一套字号与字色（与大标题同色，不压透明） */
.catalog-hero-lead {
  margin: clamp(6px, .9vw, 12px) 0 0;
  color: #fdf8f1;
  font-size: clamp(.92rem, 1.3vw, 1.08rem);
  line-height: 1.55;
  text-shadow: 0 2px 16px rgba(30, 14, 9, .62);
}

.catalog-hero-caption {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 44px;
  margin-top: 10px;
  padding-inline-start: 12px;
  color: #f5c9a9;
  font-size: clamp(1rem, 1.7vw, 1.35rem);
  line-height: 1.5;
}

.catalog-hero-caption::before {
  position: absolute;
  inset-inline-start: 0;
  width: 2px;
  height: 1.5em;
  background: #f88756;
  content: '';
}

.catalog .catalog-hero-feature {
  display: inline-flex;
  align-items: baseline;
  gap: clamp(6px, 1.2vw, 12px);
  min-width: 0;
  min-height: 44px;
  padding: 8px 0;
  border: 0;
  background: transparent;
  color: #ffe7c9;
  font: inherit;
  text-align: left;
  text-shadow: 0 1px 7px #1e0e09;
  white-space: nowrap;
}

.catalog-feature-label, .catalog-feature-arrow { color: #f5bb91; font-size: .8em; }

.catalog-feature-name {
  min-width: 0;
  overflow: hidden;
  text-decoration: underline;
  text-decoration-color: #f2ba8e85;
  text-underline-offset: .22em;
  text-overflow: ellipsis;
}

.catalog .catalog-hero-feature:is(:hover, :focus-visible) { color: #fff6e9; }
.catalog-hero-feature:is(:hover, :focus-visible) .catalog-feature-name { text-decoration-color: currentColor; }

.catalog .catalog-clear-search[hidden],
.catalog .catalog-item[hidden],
.catalog .catalog-hero-caption[hidden],
.catalog .catalog-empty [hidden] { display: none; }

.catalog-layout {
  position: relative;
  display: grid;
  grid-template-columns: minmax(184px, .66fr) minmax(0, 3.34fr);
  align-items: start;
  gap: clamp(20px, 3.4vw, 52px);
  /* 通栏收口加了圆拱后，内容区留一段呼吸空间再起卡片（与其余四页共用同一留白） */
  margin-top: var(--page-arc-gap, clamp(24px, 3.5vw, 46px));
  padding-bottom: clamp(42px, 7vw, 88px);
}

.catalog button {
  color: inherit;
  font: inherit;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.catalog-filters {
  position: sticky;
  top: calc(var(--site-header-height) + 12px);
  overflow: auto;
  overscroll-behavior: contain;
  max-height: calc(100dvh - var(--site-header-height) - 24px);
  padding: 20px 15px 17px;
  border: 1px solid #64372a;
  border-top: 3px solid #c57250;
  border-radius: 15px 4px 15px 4px;
  background:
    radial-gradient(ellipse at 90% 0, #7d3426a6, transparent 64%),
    linear-gradient(155deg, #42241c, #281813 70%);
  box-shadow: 0 14px 28px #42251b24;
  color: #f5e3cd;
}

.catalog-filter-head {
  margin: 0 9px 10px;
  padding-bottom: 12px;
  border-bottom: 1px solid #e8a67a56;
}

.catalog-filter-head h2 {
  color: #ffe4be;
  font-size: clamp(1.32rem, 1.8vw, 1.72rem);
  line-height: 1.2;
}

.catalog-filter-toggle { display: none; }
.catalog-category-list { display: grid; gap: 2px; }

#catalog-category-title,
.catalog-filter-toggle .display-title {
  font-family: "Microsoft YaHei";
}

.catalog-category-list button {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px;
  min-height: 42px;
  padding: 5px 10px;
  border: 1px solid transparent;
  border-radius: 5px;
  background: transparent;
  color: #f2deca;
  font-size: .95rem;
  line-height: 1.3;
  text-align: left;
  transition: color .2s, background-color .2s, border-color .2s;
}

.catalog-category-list button:hover { background: #fff1d918; }
.catalog-category-list button[aria-pressed="true"] {
  border-color: #e39c72;
  background-color: #f1bf91;
  color: #442319;
  font-weight: 700;
}

.catalog-category-count {
  min-width: 1.25em;
  color: #e4b396;
  font-size: .85em;
  font-weight: 400;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.catalog-category-list [aria-pressed="true"] .catalog-category-count { color: #653123; }

.catalog-results { min-width: 0; }

.catalog-results-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(230px, .82fr);
  align-items: center;
  gap: 12px 24px;
  padding: clamp(15px, 2vw, 26px) clamp(14px, 2.25vw, 28px);
  border-top: 3px solid #b84932;
  border-bottom: 1px solid #ddc2a7;
  border-radius: 4px 15px 10px 4px;
  background: linear-gradient(105deg, #fff7ea, #f7e8d6);
}

.catalog-results-copy {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.catalog-results-heading h2 {
  color: #52281e;
  font-size: clamp(1.8rem, 3.15vw, 2.85rem);
  line-height: 1.13;
}

.catalog-results-intro {
  color: var(--catalog-muted);
  font-size: clamp(.87rem, 1.22vw, 1rem);
  line-height: 1.55;
  text-wrap: pretty;
}

.catalog-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.catalog-search-field { position: relative; }

.catalog-search-field::before,
.catalog-search-field::after {
  position: absolute;
  pointer-events: none;
  content: '';
}

.catalog-search-field::before {
  top: calc(50% - 8px);
  left: 15px;
  width: 12px;
  height: 12px;
  border: 1.5px solid #8e503a;
  border-radius: 50%;
}

.catalog-search-field::after {
  top: calc(50% + 5px);
  left: 27px;
  width: 7px;
  height: 1.5px;
  border-radius: 1px;
  background: #8e503a;
  transform: rotate(45deg);
}

.catalog-search input {
  box-sizing: border-box;
  width: 100%;
  min-height: 48px;
  padding: 8px 46px 8px 43px;
  border: 1px solid #bda085;
  border-radius: 5px;
  background: #fffaf3;
  color: var(--catalog-ink);
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.35;
}

.catalog-search input::placeholder { color: #735748; }
.catalog-search input::-webkit-search-cancel-button { appearance: none; }

.catalog-search .catalog-clear-search {
  position: absolute;
  inset: 2px 2px 2px auto;
  width: 44px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--catalog-accent);
  font-size: 1.4rem;
  line-height: 1;
}

.catalog-clear-search:hover { background: #f1dfd2; }

.catalog-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(10px, 1.6vw, 21px);
  margin-top: clamp(16px, 2vw, 28px);
}

.catalog-item { min-width: 0; }

.catalog .catalog-card {
  --card-accent: #f4bd83;
  --card-illumination: #cf6738;
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-rows: auto 1fr;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border: 1px solid #714b37;
  border-radius: 20px 7px 17px 7px;
  background: var(--catalog-studio-base);
  color: #fff1da;
  text-align: left;
  transition: border-color .26s, box-shadow .26s;
}

.catalog-card::after {
  position: absolute;
  z-index: 1;
  inset: auto 0 0;
  height: clamp(100px, 41%, 144px);
  background: linear-gradient(0deg, #2e1a13, #261610e8 37%, #26161070 62%, #26161022 82%, transparent);
  pointer-events: none;
  content: '';
  transition: height .36s cubic-bezier(.22,.64,.32,1);
}

.catalog-item:is([data-category="huoguo"], [data-category="meiwayu"]) .catalog-card {
  --card-accent: #f8ab8a;
  --card-illumination: #c6533d;
}

.catalog-item[data-category="tangliao"] .catalog-card {
  --card-accent: #d1dfad;
  --card-illumination: #959c68;
}

.catalog-item:is([data-category="ganguo"], [data-category="shaokao"]) .catalog-card {
  --card-accent: #f4c78e;
  --card-illumination: #c88d4b;
}

.catalog-card-media {
  --card-media-ratio: 1.16;
  position: relative;
  display: grid;
  place-items: center;
  min-width: 0;
  overflow: hidden;
  aspect-ratio: var(--card-media-ratio);
}

.catalog-card-media .catalog-product-stage {
  --studio-art-width: 82%;
  width: calc(100% / var(--card-media-ratio));
}

.catalog-card::before {
  position: absolute;
  z-index: 2;
  inset: 0;
  background: radial-gradient(ellipse at var(--card-glow-at, 50% 45%), var(--card-illumination), transparent 62%);
  mix-blend-mode: screen;
  opacity: .18;
  pointer-events: none;
  content: '';
  transition: opacity .32s ease;
}

.catalog-card-media .catalog-product-artwork { z-index: 3; }
.catalog-card-media .catalog-product-art-note { position: relative; z-index: 3; font-size: .78rem; }

.catalog-card-copy {
  position: relative;
  z-index: 4;
  display: grid;
  align-content: start;
  gap: 5px;
  margin-top: -17px;
  padding: 11px clamp(10px, 1vw, 16px) 16px;
  overflow-wrap: anywhere;
  transition: translate .36s cubic-bezier(.22,.64,.32,1);
}

.catalog-card-name {
  font-size: clamp(.98rem, 1.45vw, 1.22rem);
  font-weight: 700;
  line-height: 1.34;
  text-wrap: pretty;
}

.catalog-card-spec { color: #e9c5a7; font-size: .82rem; line-height: 1.55; }

.catalog .catalog-card:hover {
  border-color: color-mix(in srgb, var(--card-accent) 72%, #714b37);
  box-shadow: 0 8px 20px #4d221c30;
}

.catalog-card:is(:focus-visible, :active)::after {
  height: clamp(127px, 54%, 181px);
}

.catalog-card:is(:focus-visible, :active) .catalog-card-copy { translate: 0 -4px; }
.catalog-card:is(:focus-visible, :active)::before { opacity: .42; }

@media (hover: hover) {
  .catalog-card:hover::after { height: clamp(127px, 54%, 181px); }
  .catalog-card:hover .catalog-card-copy { translate: 0 -4px; }
  .catalog-card:hover::before {
    --card-glow-at: var(--card-pointer-x, 50%) var(--card-pointer-y, 45%);
    opacity: .49;
  }
}

.catalog-empty {
  margin-top: 12px;
  padding: 35px 16px;
  border-bottom: 1px solid var(--catalog-line);
  background: #fff8eb;
  font-size: 1rem;
  text-align: center;
}

.catalog-empty button {
  min-height: 44px;
  margin: 12px 4px 0;
  padding: 6px 12px;
  border: 1px solid #ad6b56;
  border-radius: 4px;
  background: #fff8eb;
  color: var(--catalog-accent);
  font-size: .9rem;
}

.catalog-empty button:hover { background: #f5e0d3; }

.catalog-dialog {
  --detail-light: #ffecd4;
  --detail-inset: clamp(22px, 4vw, 68px);
  box-sizing: border-box;
  inset: 0 0 0 auto;
  width: 85%;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  overflow: hidden;
  border: 0;
  border-left: 1px solid #b46e49;
  background: #fbf0df;
  color: var(--catalog-ink);
  box-shadow: -12px 0 55px #1d100a44;
}

.catalog-dialog[open] { display: grid; grid-template-rows: minmax(0, 1fr); }
.catalog-dialog::backdrop { background: #21110bce; }

.catalog-detail-close-form {
  position: absolute;
  z-index: 8;
  inset: clamp(14px, 2.2vw, 30px) var(--detail-inset) auto auto;
  margin: 0;
}

.catalog .catalog-detail-close {
  display: grid;
  place-items: center;
  width: clamp(44px, 3.8vw, 58px);
  height: clamp(44px, 3.8vw, 58px);
  padding: 0;
  border: 1px solid #d29a73;
  border-radius: 50%;
  background: #261610bd;
  color: #ffe4bf;
  box-shadow: 0 5px 14px #14080552;
  transition: background-color .22s, border-color .22s, transform .22s;
}

.catalog .catalog-detail-close svg {
  width: 58%;
  height: 58%;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
}

.catalog .catalog-detail-close:hover {
  border-color: #ffe2bb;
  background: #8c3827e8;
  transform: rotate(8deg);
}

.catalog-detail {
  display: flex;
  flex-direction: column;
  overflow: auto;
  overscroll-behavior: contain;
}

.catalog-detail-cover {
  position: relative;
  flex: none;
  display: grid;
  grid-template-columns: minmax(0, .93fr) minmax(0, 1.07fr);
  grid-template-areas: 'copy visual' 'facts visual';
  grid-template-rows: 1fr auto;
  align-items: stretch;
  min-height: clamp(295px, 27vw, 405px);
  background: var(--catalog-studio-base);
  color: var(--detail-light);
}

.catalog-detail-copy {
  z-index: 1;
  grid-area: copy;
  align-self: end;
  min-width: 0;
  padding: clamp(18px, 2.4vw, 36px) 0 16px var(--detail-inset);
}

.catalog-detail h2 {
  margin: 0 0 9px;
  color: #fff0d7;
  font-size: clamp(2rem, 4vw, 4.35rem);
  font-weight: 400;
  line-height: 1.11;
  overflow-wrap: anywhere;
  text-wrap: balance;
}

.catalog-detail-tags {
  margin-bottom: 8px;
  color: #f4aa77;
  font-size: clamp(.8rem, 1.14vw, .98rem);
  line-height: 1.58;
}

.catalog-detail-tags:empty { display: none; }

.catalog-detail-description {
  max-width: 51ch;
  color: #ecd4bf;
  font-size: clamp(.88rem, 1.16vw, 1.03rem);
  line-height: 1.72;
  overflow-wrap: anywhere;
}

.catalog-detail-facts {
  z-index: 1;
  grid-area: facts;
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  column-gap: clamp(8px, 2vw, 26px);
  margin: 0 0 clamp(18px, 2vw, 30px) var(--detail-inset);
  padding-block: 8px 0;
  border-top: 1px solid #c17a567d;
}

.catalog-detail-facts dt { margin-bottom: 2px; color: #e5a67e; font-size: .8rem; }
.catalog-detail-facts dd {
  color: #ffebcb;
  font-size: clamp(.96rem, 1.5vw, 1.3rem);
  font-weight: 700;
  line-height: 1.35;
  overflow-wrap: anywhere;
  font-variant-numeric: tabular-nums;
}

.catalog-detail-visual {
  position: relative;
  grid-area: visual;
  display: grid;
  place-items: center;
  min-width: 0;
  margin: 0;
  padding-bottom: 9px;
  overflow: hidden;
}

.catalog-product-stage {
  position: relative;
  display: grid;
  place-items: center;
  min-width: 0;
  aspect-ratio: 1;
}

.catalog-detail-visual .catalog-product-stage { width: min(100%, clamp(278px, 29vw, 420px)); }

.catalog-product-stage:has(.catalog-product-artwork:not([hidden]))::before {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, var(--catalog-studio-base), transparent 15% 86%, var(--catalog-studio-base)),
    linear-gradient(0deg, var(--catalog-studio-base), transparent 10% 91%, var(--catalog-studio-base)),
    url('/images/product-studio.webp') center / 100% 100% no-repeat;
  content: '';
}

.catalog-product-stage:has(.catalog-product-artwork:not([hidden]))::after {
  position: absolute;
  inset: 79.5% auto auto 50%;
  width: 46%;
  height: 5.5%;
  border-radius: 50%;
  background: #100704;
  filter: blur(7px);
  opacity: .78;
  transform: translateX(-50%);
  content: '';
}

.catalog-product-artwork {
  position: absolute;
  z-index: 1;
  bottom: 18%;
  left: 50%;
  width: var(--studio-art-width, 68%);
  height: 73%;
  filter: drop-shadow(5px 9px 12px #13080461);
  transform: translateX(-50%);
}

.catalog-product-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center bottom;
}

.catalog-product-artwork[data-crop] {
  width: min(var(--studio-art-width, 68%), calc(73% * var(--art-ratio)));
  height: auto;
  aspect-ratio: var(--art-ratio);
}

.catalog-product-artwork[data-crop] .catalog-product-image {
  position: absolute;
  top: var(--art-top);
  left: var(--art-left);
  width: var(--art-width);
  height: var(--art-height);
  object-fit: fill;
  clip-path: var(--art-outline);
}

.catalog-product-art-note {
  color: #e8bb98;
  font-size: .9rem;
  text-align: center;
}

.catalog-detail-links {
  --external-link-rule: #e4b17eb3;
  position: absolute;
  inset: auto var(--detail-inset) 9px;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0 clamp(6px, 1vw, 14px);
}

.catalog-detail-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  color: #ffebce;
  font-size: .83rem;
  font-weight: 700;
  line-height: 1.4;
}

.catalog-detail-links .external-text-link > span { color: #f1c18f; }
.catalog-detail-links a:hover { color: #ffe0b9; }

.catalog-detail-workbench {
  --detail-paper: #f7ead4;
  --detail-rule: #cba883;
  --detail-oxide: #8c3727;
  flex: 1 0 auto;
  display: grid;
  align-content: start;
  grid-template-columns: minmax(176px, .38fr) minmax(0, 1.62fr);
  gap: clamp(20px, 3.5vw, 54px);
  min-height: 332px;
  padding: clamp(22px, 3vw, 43px) var(--detail-inset) clamp(34px, 4.5vw, 72px);
  border-top: 3px solid #b45639;
  background:
    radial-gradient(ellipse at 14% 0, #ebc6a27d, transparent 57%),
    repeating-linear-gradient(0deg, #8b492a04 0 1px, transparent 1px 6px),
    var(--detail-paper);
}

.catalog-detail-sidebar {
  position: sticky;
  top: 16px;
  z-index: 1;
  align-self: start;
}

.catalog-detail-tabs {
  display: grid;
  gap: 5px;
  padding: 10px 12px 12px;
  border: 1px solid #694131;
  border-top: 2px solid #bc7755;
  border-radius: 5px 17px 5px 17px;
  background: radial-gradient(ellipse at 110% 0, #693525 5%, transparent 90%), #322018;
  box-shadow: 0 11px 22px #5e30211a;
}

.catalog-detail-tab-list {
  display: grid;
  gap: 5px;
}

.catalog-dialog .catalog-detail-tabs button {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 7px 9px;
  border: 1px solid transparent;
  border-radius: 16px 4px 4px 16px;
  background: transparent;
  color: #efd1b4;
  font-size: clamp(.89rem, 1.2vw, 1.02rem);
  font-weight: 700;
  line-height: 1.3;
  text-align: left;
  transition: background-color .22s, color .22s, border-color .22s;
}

.catalog-detail-tabs button::before {
  flex: none;
  width: 7px;
  height: 7px;
  border: 1px solid #bf8968;
  border-radius: 50%;
  content: '';
}

.catalog-detail-tabs button::after {
  width: 10px;
  height: 1px;
  margin-inline-start: auto;
  background: currentColor;
  opacity: .46;
  content: '';
}

.catalog-dialog .catalog-detail-tabs button:hover { background: #704232; }
.catalog-dialog .catalog-detail-tabs button[aria-selected="true"] {
  border-color: #edba8d;
  background: #f1c99e;
  color: #52271b;
}
.catalog-detail-tabs button[aria-selected="true"]::before { border-color: #a34832; background: #a34832; }
.catalog-detail-tabs button[aria-selected="true"]::after { opacity: 1; }

.catalog-detail-tabs .catalog-detail-guide {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 7px 9px;
  border: 1px solid transparent;
  border-radius: 16px 4px 4px 16px;
  color: #efd1b4;
  font-size: clamp(.89rem, 1.2vw, 1.02rem);
  font-weight: 700;
  line-height: 1.3;
  text-decoration: none;
  transition: background-color .22s, color .22s, border-color .22s;
}

.catalog-detail-tabs .catalog-detail-guide::before {
  flex: none;
  width: 7px;
  height: 7px;
  border: 1px solid #bf8968;
  border-radius: 50%;
  content: '';
}

.catalog-detail-tabs .catalog-detail-guide::after {
  width: 10px;
  height: 1px;
  margin-inline-start: auto;
  background: currentColor;
  opacity: .46;
  content: '';
}

.catalog-detail-tabs .catalog-detail-guide:hover {
  border-color: transparent;
  background: #704232;
  color: #fff0dd;
}

.catalog-detail-tabs .catalog-detail-guide:hover::before {
  border-color: #f5c89b;
  background: #f5c89b;
}

.catalog-detail-tabs .catalog-detail-guide > span { color: #f8c499; font-size: .8em; }

.catalog-detail-panel {
  align-self: start;
  min-width: 0;
  color: #39251b;
  font-size: clamp(.96rem, 1.22vw, 1.08rem);
  line-height: 1.72;
  overflow-wrap: anywhere;
}

.catalog-detail-panel h3 {
  color: #562e21;
  font-family: "Microsoft YaHei";
  font-size: clamp(1.27rem, 2vw, 2rem);
  font-weight: 700;
  line-height: 1.25;
}

.catalog-detail-recipe { position: relative; }

.catalog-detail-sequence {
  position: relative;
  display: grid;
  gap: 0;
  padding: 2px 0 2px 22px;
}

.catalog-detail-sequence::before {
  position: absolute;
  top: 20px;
  bottom: 20px;
  left: 8px;
  width: 1px;
  background: linear-gradient(#b97856, #dfb98e 52%, #b97856);
  content: '';
}

.catalog-step-row {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(146px, .34fr) minmax(0, 1fr);
  align-items: start;
  gap: clamp(14px, 2vw, 30px);
  padding: 14px clamp(12px, 1.6vw, 24px) 16px 14px;
  border-bottom: 1px solid #cba88375;
  color: #5d4032;
}

.catalog-step-row:first-child { padding-top: 10px; }
.catalog-step-row:last-child { border-bottom: 0; }
.catalog-step-row[data-note] { color: #6c512f; }

.catalog-step-row .catalog-step-token {
  align-self: start;
  min-height: 36px;
  padding-top: 1px;
}

.catalog-step-row .catalog-step-label {
  font-weight: 700;
  line-height: 1.45;
}

.catalog-step-body {
  margin: 0;
  color: #51372a;
  font-size: clamp(.97rem, 1.18vw, 1.1rem);
  line-height: 1.72;
}

.catalog-step-row[data-note] .catalog-step-body { color: #634721; }

.catalog-step-token {
  display: flex;
  align-items: center;
  gap: 12px;
}

.catalog-step-label {
  width: fit-content;
  max-width: 100%;
  text-wrap: balance;
}

.catalog-step-mark {
  position: relative;
  display: grid;
  place-items: center;
  box-sizing: border-box;
  width: 36px;
  height: 36px;
  border: 1px solid #bc8b65;
  border-radius: 49% 51% 46% 54% / 52% 46% 54% 48%;
  background: linear-gradient(150deg, #fff6e3, #f3dcbb);
  color: #743e2d;
  font-size: .82rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  transition: color .2s, box-shadow .2s;
}

.catalog-step-mark::after {
  position: absolute;
  inset: 3px;
  border: 1px solid currentColor;
  border-right-color: transparent;
  border-radius: 49% 51% 48% 52%;
  opacity: .41;
  rotate: -21deg;
  content: '';
  pointer-events: none;
}

.catalog-step-mark > svg {
  width: 55%;
  height: 55%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}


.catalog-detail-uses:not([hidden]) {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr);
  min-height: 230px;
  overflow: hidden;
  border: 1px solid #caa882;
  border-radius: 4px 22px 4px 4px;
  background: #ffefd6;
  box-shadow: 0 11px 21px #63341719;
}

.catalog-uses-copy {
  display: grid;
  align-content: center;
  gap: 15px;
  padding: clamp(20px, 3.5vw, 45px);
}

.catalog-uses-copy h3::after {
  display: block;
  width: 48px;
  height: 2px;
  margin-top: 11px;
  background: var(--detail-oxide);
  content: '';
}

.catalog-uses-text p + p { margin-top: 10px; }

.catalog-uses-visual { position: relative; margin: 0; min-height: 150px; }

.catalog-uses-image {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.catalog-uses-visual figcaption {
  position: absolute;
  inset: auto 9px 9px auto;
  padding: 3px 7px;
  background: #2f1c13db;
  color: #ffe7cb;
  font-size: .75rem;
  line-height: 1.3;
}

@media (prefers-reduced-motion: no-preference) {
  .catalog-dialog[open] { animation: catalog-dialog-in .38s cubic-bezier(.2,.68,.3,1) both; }
  .catalog-dialog[data-closing] { animation: catalog-dialog-out .34s cubic-bezier(.55,.08,.72,.22) both; }
}

@keyframes catalog-dialog-in {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}

@keyframes catalog-dialog-out {
  from { transform: translateX(0); }
  to { transform: translateX(100%); }
}

@media (max-width: 1180px) {
  .catalog-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  /* 手机导航是实色条：通栏回到导航下方，图按 2:1 手机版原比例完整显示 */
  .catalog-hero {
    box-sizing: border-box;
    aspect-ratio: auto;
    height: calc(var(--site-header-height) + 50vw);
    padding-top: var(--site-header-height);
    padding-bottom: 0;
  }
  .catalog-hero > img {
    top: var(--site-header-height);
    bottom: auto;
    width: 100%;
    height: auto;
    aspect-ratio: 2 / 1;
    object-fit: cover;
  }
  .catalog-hero-inner {
    right: 20px;
    bottom: calc(var(--page-arc) + 10px);
    left: 20px;
    padding: 0;
  }
  .catalog-layout { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .catalog-filters {
    position: static;
    max-height: none;
    padding: 0;
    overflow: visible;
    border-radius: 10px 4px 10px 4px;
  }
  .catalog-filter-head { margin: 0; padding: 0; border: 0; }
  .catalog-filter-head h2 {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }
  .catalog .catalog-filter-toggle {
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: center;
    gap: 9px;
    width: 100%;
    min-height: 47px;
    padding: 7px 14px;
    border: 0;
    background: transparent;
    color: #ffdfb9;
    font-weight: 700;
    text-align: left;
  }
  .catalog-filter-current { color: #f1bc94; font-size: .87em; font-weight: 400; }
  .catalog-chevron {
    width: 7px;
    height: 7px;
    margin-inline: 3px;
    border: solid currentColor;
    border-width: 0 1px 1px 0;
    transform: translateY(-2px) rotate(45deg);
  }
  .catalog-filter-toggle[aria-expanded="true"] .catalog-chevron { transform: translateY(2px) rotate(225deg); }
  .catalog-filters:has(.catalog-filter-toggle[aria-expanded="false"]) .catalog-category-list { display: none; }
  .catalog-category-list {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 126px), 1fr));
    gap: 4px;
    margin: 0 8px 8px;
    padding-top: 5px;
    border-top: 1px solid #edb1834d;
  }
  .catalog-category-list button { min-height: 44px; }
}

@media (max-width: 780px) {
  .catalog-dialog {
    --detail-inset: clamp(12px, 4vw, 23px);
    inset: 0;
    width: 100%;
    height: 100dvh;
    border: 0;
    border-radius: 0;
  }
  .catalog-detail-cover {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: 'name' 'tags' 'visual' 'facts' 'description';
    grid-template-rows: auto;
    min-height: 0;
  }
  .catalog-detail-copy { display: contents; }
  .catalog-detail h2 {
    grid-area: name;
    margin: 14px var(--detail-inset) 5px;
    font-size: clamp(1.85rem, 6.5vw, 2.75rem);
  }
  .catalog-detail-tags { grid-area: tags; margin: 0 var(--detail-inset) 6px; }
  .catalog-detail-description { grid-area: description; margin: 0 var(--detail-inset) 12px; }
  .catalog-detail-facts {
    margin: 0 var(--detail-inset) 8px;
    padding-top: 7px;
    border-top-color: #c17a5666;
  }
  .catalog-detail-visual .catalog-product-stage { width: min(100%, clamp(255px, 80vw, 320px)); }
  .catalog-detail-visual .catalog-product-stage:has(.catalog-product-art-note:not([hidden])) { min-height: 150px; aspect-ratio: auto; }
  .catalog-detail-links { bottom: 5px; gap: 0 6px; }
  .catalog-detail-workbench { grid-template-columns: minmax(0, 1fr); gap: 15px; padding: 14px var(--detail-inset) 28px; }
  .catalog-detail-sidebar { top: 0; }
  .catalog-detail-tabs { padding: 6px 8px 8px; }
  .catalog-detail-tab-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .catalog-dialog .catalog-detail-tabs button { justify-content: center; gap: 5px; min-height: 44px; padding: 4px; }
  .catalog-detail-tabs button::before { width: 5px; height: 5px; }
  .catalog-detail-tabs button::after { content: none; }
  .catalog-step-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
    padding-inline: 9px;
  }
  .catalog-detail-uses:not([hidden]) { grid-template-columns: minmax(0, 1fr); }
  .catalog-uses-visual { min-height: clamp(150px, 40vw, 200px); }
}

@media (max-width: 640px) {
  .catalog-shell { width: calc(100% - 24px); }
  .catalog-hero-inner { min-height: 0; padding: 0; }
  .catalog-hero h1 { font-size: clamp(2.2rem, 10vw, 3.7rem); }
  .catalog-hero { --catalog-title-shade: linear-gradient(90deg, #1e0e09ed, #21110bc2 43%, #21110b25 96%); }
  .catalog-results-heading { grid-template-columns: minmax(0, 1fr); gap: 9px; padding: 12px; }
  .catalog .catalog-hero-feature { font-size: clamp(.82rem, 3.9vw, 1rem); }
  .catalog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .catalog-card-copy { padding-inline: 9px; }
}

@media (prefers-reduced-motion: no-preference) and (max-width: 780px) {
  .catalog-dialog[open] { animation: catalog-dialog-mobile-in .42s cubic-bezier(.22,.75,.28,1) both; }
  .catalog-dialog[data-closing] { animation: catalog-dialog-mobile-out .38s cubic-bezier(.42,0,.58,1) both; }
  .catalog-dialog[open]::backdrop { animation: catalog-backdrop-mobile-in .42s ease-out both; }
  .catalog-dialog[data-closing]::backdrop { animation: catalog-backdrop-mobile-out .18s ease-out .24s both; }
}

@keyframes catalog-dialog-mobile-in {
  from { opacity: 1; transform: translateY(100%); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes catalog-dialog-mobile-out {
  from { opacity: 1; transform: translateY(0); }
  to { opacity: 1; transform: translateY(100%); }
}

@keyframes catalog-backdrop-mobile-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes catalog-backdrop-mobile-out {
  from { opacity: 1; }
  to { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .catalog :is(button, img, .catalog-card-copy, .catalog-step-mark),
  .catalog-card::before,
  .catalog-card::after { transition: none; }
  .catalog-card:is(:hover, :focus-visible, :active) .catalog-card-copy { translate: none; }
}
