:root {
  --ink: #243127; --muted: #6d766d; --paper: #f4f1e9;
  --card: #fffdf8; --line: #d8d6cc; --green: #1f4936; --orange: #c64f29;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, [tabindex]:focus-visible { outline: 2px solid var(--orange); outline-offset: 4px; }
.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; }
.site-header { min-height: 94px; padding: 20px clamp(20px, 5vw, 80px); display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 20px; border-bottom: 1px solid var(--line); }
.header-identity { min-width: 0; }
.header-tagline { margin: 8px 0 0 25px; color: var(--muted); font-size: 11px; line-height: 1.6; }
.header-nav { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; font-size: 12px; }
.header-nav a { display: inline-flex; align-items: center; min-height: 42px; padding: 8px 0; }
.nav-primary { color: var(--green); font-weight: 600; }
.cross-page-link { color: var(--muted); }
.header-nav a:hover { text-decoration: underline; text-underline-offset: 5px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-family: "Songti SC", "STSong", serif; font-size: 20px; font-weight: 700; letter-spacing: .04em; }
.brand-dot { flex: 0 0 15px; height: 15px; display: inline-block; border-radius: 50% 50% 50% 4px; background: #ee6a3c; transform: rotate(-18deg); box-shadow: 8px 6px 0 -4px var(--green); }
.text-button { padding: 8px 0; border: 0; border-bottom: 1px solid currentColor; background: none; color: var(--green); font-size: 12px; }
main { max-width: 1440px; margin: auto; padding: 0 clamp(20px, 5vw, 80px); }
.intro { display: grid; grid-template-columns: 1.25fr .8fr; align-items: center; gap: clamp(28px, 5vw, 80px); padding: 48px 0 44px; }
.eyebrow { margin: 0 0 16px; color: var(--orange); font-size: 10px; line-height: 1.6; font-weight: 700; letter-spacing: .16em; }
h1 { margin: 0; font-family: "Songti SC", "STSong", serif; font-size: clamp(36px, 4.4vw, 62px); font-weight: 500; line-height: 1.2; letter-spacing: -.045em; }
.intro-copy { margin: 22px 0 0; color: var(--muted); font-size: 14px; line-height: 1.9; }
.primary-button { margin-top: 23px; min-width: 185px; padding: 14px 20px; display: inline-flex; justify-content: space-between; gap: 25px; background: var(--green); color: white; font-size: 12px; }
.primary-button:hover { background: #163b2b; }
.service-note { padding: 25px 30px; border: 1px solid #d4c7a9; background: #e9e1ce; }
.service-note h2 { margin: 0; font: 500 28px "Songti SC", "STSong", serif; }
.service-note ol { list-style: none; padding: 0; margin: 20px 0; }
.service-note li { display: flex; gap: 13px; margin: 14px 0; font-size: 12px; line-height: 1.6; }
.service-note li span { color: var(--orange); font: italic 15px Georgia, serif; }
.machine-list { display: flex; flex-wrap: wrap; gap: 7px; padding-top: 17px; border-top: 1px solid #cfc5ad; }
.machine-list span { border: 1px solid #c9bfa7; padding: 5px 8px; font-size: 10px; }
.small-note { margin: 14px 0 0; color: #646a60; font-size: 11px; line-height: 1.7; }
.catalog { padding: 40px 0 64px; border-top: 1px solid var(--line); scroll-margin-top: 22px; }
.section-heading { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; }
.section-heading h2 { margin: 0; font: 500 clamp(30px, 3vw, 40px) "Songti SC", "STSong", serif; }
.section-heading .eyebrow { margin-bottom: 10px; }
.section-description { margin: 11px 0 0; color: var(--muted); font-size: 12px; line-height: 1.7; }
.search-box { width: min(100%, 290px); padding: 10px 2px; display: flex; align-items: center; border-bottom: 1px solid #9da39c; }
.search-box input { min-width: 0; width: 100%; border: 0; background: transparent; color: var(--ink); font-size: 13px; }
.search-box input::placeholder { color: var(--muted); }
.search-box span:last-child { font-size: 22px; }
.filter-row { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin: 26px 0 23px; }
.filter-buttons { display: flex; gap: 8px; flex-wrap: wrap; }
.filter-buttons button { padding: 8px 14px; border: 1px solid #bdc1b8; border-radius: 999px; background: transparent; color: #566157; font-size: 12px; }
.filter-buttons button:hover { border-color: var(--green); }
.filter-buttons button.active { background: var(--green); border-color: var(--green); color: white; }
.brand-select select { max-width: 200px; padding: 8px 28px 8px 10px; color: var(--green); border: 1px solid #bdc1b8; background: var(--card); border-radius: 2px; font-size: 12px; }
.result-count { margin-left: auto; color: var(--muted); font-size: 12px; }
.material-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.material-card, .item-card { min-width: 0; border: 1px solid var(--line); background: var(--card); overflow: hidden; }
.photo-button { position: relative; display: block; width: 100%; padding: 0; border: 0; background: #e3dfd5; color: var(--ink); overflow: hidden; }
.photo-button img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: contain; transition: transform .2s; }
.photo-button:hover img { transform: scale(1.025); }
.photo-button:focus-visible { outline-offset: -4px; }
.photo-note { position: absolute; right: 10px; bottom: 10px; padding: 5px 8px; background: rgba(255,253,248,.95); border: 1px solid var(--line); font-size: 10px; }
.material-content { padding: 19px 20px 16px; }
.material-brand { margin: 0 0 9px; color: var(--orange); font-size: 11px; }
.material-card h3 { margin: 0; font-size: 20px; font-weight: 600; }
.material-color { margin: 10px 0 18px; min-height: 22px; color: #546054; font-size: 13px; line-height: 1.6; overflow-wrap: anywhere; }
.material-footer { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding-top: 12px; border-top: 1px solid var(--line); color: var(--muted); font-size: 10px; }
.material-code { color: var(--green); font: 12px ui-monospace, monospace; }
.material-footer button { margin-left: auto; padding: 6px 0; border: 0; background: none; color: var(--green); font-size: 11px; }
.catalog-footnote { margin: 25px 0 0; color: var(--muted); font-size: 11px; line-height: 1.9; }
.idle-intro { grid-template-columns: 1.5fr .6fr; }
.idle-note { padding: 24px; border-left: 1px solid var(--line); }
.large-count { display: block; color: var(--green); font: 72px Georgia, serif; }
.idle-note p { font-size: 13px; }
.idle-note small { color: var(--muted); font-size: 11px; }
.sale-notes { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 16px 0; border-top: 1px solid var(--line); color: #566157; font-size: 11px; }
.sale-notes span::before { content: "✓"; color: var(--orange); margin-right: 8px; }
.item-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.product-photos { position: relative; background: #e3dfd5; }
.diagnostic-panel { padding: 22px 24px 17px; border-bottom: 1px solid var(--line); background: #e9eee7; }
.diagnostic-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; color: #556356; font-size: 10px; }
.diagnostic-code { font: 600 15px ui-monospace, monospace; letter-spacing: .04em; }
.diagnostic-result { margin: 18px 0; color: var(--green); font-size: 19px; font-weight: 600; line-height: 1.5; }
.diagnostic-metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 17px 14px; margin: 0; }
.diagnostic-metrics dt { color: #626d62; font-size: 10px; line-height: 1.6; }
.diagnostic-metrics dd { margin: 5px 0 0; font: 600 16px ui-monospace, monospace; overflow-wrap: anywhere; }
.diagnostic-caption { margin: 18px 0 0; color: #626d62; font-size: 10px; line-height: 1.7; }
.diagnostic-attention { background: #f0e7d7; }
.diagnostic-attention .diagnostic-result { color: #86551b; }
.diagnostic-fault { background: #f4e1da; border-color: #d4a697; }
.diagnostic-fault .diagnostic-result, .item-fault .condition { color: #a32e20; }
.diagnostic-warning { margin: 15px 0 0; color: #973a2c; font-size: 11px; line-height: 1.7; }
.item-fault { border-color: #ce9e90; }
.item-card .small-note { margin: 0 0 16px; }
.product-photos.has-gallery { display: grid; grid-template-columns: minmax(0, 1fr) minmax(64px, 25%); align-items: start; gap: 8px; padding: 8px; }
.product-photos.has-gallery > .diagnostic-panel { grid-column: 1 / -1; }
.photo-thumbnails { display: flex; flex-direction: column; gap: 8px; }
.secondary-photo { border: 2px solid var(--card); }
.secondary-photo .photo-note { display: none; }
.category-label { position: absolute; top: 14px; left: 14px; pointer-events: none; padding: 5px 9px; border: 1px solid var(--line); background: rgba(255,253,248,.94); font-size: 10px; }
.no-photo { display: grid; place-items: center; aspect-ratio: 4 / 3; color: var(--muted); font-size: 13px; }
.item-content { padding: 24px; }
.item-title-row { display: flex; justify-content: space-between; gap: 16px; }
.item-title-row h3 { margin: 0; font: 600 22px "Songti SC", "STSong", serif; overflow-wrap: anywhere; }
.condition { margin: 0 0 7px; color: var(--orange); font-size: 11px; }
.price { margin: 0; text-align: right; white-space: nowrap; }
.price strong { display: block; color: var(--green); font: 24px Georgia, serif; }
.price span { color: var(--muted); font-size: 10px; }
.item-note { margin: 18px 0; color: #616b61; font-size: 12px; line-height: 1.8; white-space: pre-line; overflow-wrap: anywhere; }
.spec-list { list-style: none; margin: 0 0 16px; padding: 0; display: flex; flex-wrap: wrap; gap: 7px; }
.spec-list li { padding: 5px 8px; border: 1px solid var(--line); border-radius: 20px; color: #59645b; font-size: 10px; }
.market-note { padding: 10px 12px; border-left: 2px solid var(--orange); background: #f2eee3; color: var(--muted); font-size: 11px; line-height: 1.7; }
.item-footer { padding-top: 14px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; line-height: 1.7; }
.empty-state, .catalog-loading { grid-column: 1 / -1; margin: 0; padding: 65px 20px; border: 1px dashed #bfc2ba; color: var(--muted); text-align: center; }
.empty-state p { font: 24px "Songti SC", "STSong", serif; }
footer { padding: 30px clamp(20px, 5vw, 80px); display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; }
footer .brand { color: var(--ink); }
.photo-dialog { max-width: min(900px, 94vw); max-height: 92dvh; padding: 18px; border: 1px solid var(--line); background: var(--card); color: var(--ink); }
.photo-dialog::backdrop { background: #17241ddb; }
.photo-dialog img { display: block; max-width: 100%; max-height: 70dvh; object-fit: contain; margin: 14px auto; }
.photo-dialog p { font-size: 12px; line-height: 1.8; }
.dialog-close { display: block; margin-left: auto; padding: 7px 12px; border: 1px solid var(--line); color: var(--green); background: transparent; }
.toast { max-width: calc(100vw - 30px); padding: 12px 18px; position: fixed; left: 50%; bottom: 25px; z-index: 50; background: var(--green); color: white; font-size: 12px; opacity: 0; transform: translate(-50%, 15px); transition: opacity .2s, transform .2s; pointer-events: none; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.back-to-top { position: fixed; right: max(20px, env(safe-area-inset-right)); bottom: max(20px, env(safe-area-inset-bottom)); z-index: 40; display: grid; place-items: center; width: 3rem; height: 3rem; padding: 0; border: 0; border-radius: 50%; background: var(--green); color: white; box-shadow: 0 3px 12px #17241d26; }
.back-to-top:hover { background: #163b2b; }
.back-to-top-arrow { width: 1.5rem; height: 1.5rem; }
@media (max-width: 1000px) {
  .material-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .intro { gap: 28px; }
  .service-note { padding: 23px; }
}
@media (max-width: 700px) {
  .site-header { min-height: 0; grid-template-columns: minmax(0, 1fr); gap: 12px; padding-block: 18px 10px; }
  .header-nav { justify-content: space-between; gap: 12px; border-top: 1px solid var(--line); }
  .brand { font-size: 17px; }
  .intro { grid-template-columns: 1fr; padding: 34px 0; gap: 28px; }
  h1 { font-size: clamp(32px, 7vw, 46px); }
  .intro-copy { font-size: 13px; }
  .service-note { padding: 22px; }
  .service-note ol { margin-block: 16px; }
  .section-heading { align-items: stretch; flex-direction: column; gap: 18px; }
  .search-box { width: 100%; }
  .catalog { padding-top: 28px; }
  .filter-row { gap: 12px; }
  .item-grid { grid-template-columns: 1fr; }
  .idle-note { display: flex; align-items: baseline; gap: 15px; flex-wrap: wrap; border-left: 0; border-top: 1px solid var(--line); padding: 18px 0 0; }
  .large-count { font-size: 48px; }
  .idle-note p { margin: 0; }
  .item-content { padding: 20px; }
  .item-title-row h3 { font-size: 21px; }
  .material-content { padding: 17px; }
  .material-card h3 { font-size: 18px; }
  footer { align-items: flex-start; }
}
@media (max-width: 460px) {
  .diagnostic-panel { padding: 20px; }
  .diagnostic-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .material-grid { grid-template-columns: 1fr; }
  .material-color { min-height: 0; }
  .sale-notes { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
