:root {
  color-scheme: light;
  --bg: #f3efe6;
  --surface: rgba(255, 253, 248, 0.78);
  --surface-solid: #fffdf8;
  --text: #25231f;
  --muted: #6d675e;
  --line: rgba(55, 49, 40, 0.13);
  --accent: #c9482a;
  --accent-soft: #f5c6b9;
  --page-glow: rgba(255, 255, 255, 0.75);
  --shadow: 0 20px 50px rgba(63, 51, 35, 0.08);
  --radius: 24px;
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg: #171815;
  --surface: rgba(35, 36, 32, 0.78);
  --surface-solid: #232420;
  --text: #f1eee5;
  --muted: #aaa69d;
  --line: rgba(255, 255, 255, 0.11);
  --accent: #f17c5f;
  --accent-soft: #663d33;
  --page-glow: rgba(72, 74, 66, 0.28);
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.22);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 50% -10%, var(--page-glow), transparent 34rem),
    var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  transition: background-color .25s ease, color .25s ease;
}

button, input { font: inherit; }

a { color: inherit; }

.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;
}

.ambient {
  position: fixed;
  z-index: -1;
  width: 28rem;
  height: 28rem;
  border-radius: 999px;
  filter: blur(90px);
  opacity: .16;
  pointer-events: none;
}

.ambient-one { top: 24rem; left: -17rem; background: #f3a274; }
.ambient-two { top: 9rem; right: -18rem; background: #8aa6d7; }

.site-header,
main,
footer {
  width: min(1180px, calc(100% - 48px));
  margin-inline: auto;
}

.site-header {
  height: 90px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
  letter-spacing: -.02em;
}

.brand-mark {
  width: 35px;
  height: 35px;
  display: grid;
  place-items: center;
  border-radius: 11px 11px 11px 3px;
  background: var(--text);
  color: var(--bg);
  font-family: Georgia, serif;
  font-size: 20px;
  font-style: italic;
}

.brand-dot { color: var(--accent); }

.header-actions { display: flex; align-items: center; gap: 16px; }

.online-note {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

.online-note i,
.status i {
  width: 7px;
  height: 7px;
  display: block;
  border-radius: 50%;
  background: #38a169;
  box-shadow: 0 0 0 4px rgba(56, 161, 105, .12);
}

.icon-button {
  width: 39px;
  height: 39px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
}

.icon-button:focus-visible,
.filter:focus-visible,
.product-card:focus-visible,
.search-wrap input:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent) 70%, white);
  outline-offset: 3px;
}

.icon-button svg {
  width: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.moon-icon, [data-theme="dark"] .sun-icon { display: none; }
[data-theme="dark"] .moon-icon { display: block; }

.hero {
  max-width: 780px;
  margin: 92px auto 118px;
  text-align: center;
}

.eyebrow,
.section-kicker,
.card-label {
  color: var(--accent);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .18em;
}

.eyebrow span { margin-right: 7px; }

h1 {
  margin: 22px 0 22px;
  font-family: "Noto Serif SC", "Songti SC", Georgia, serif;
  font-size: clamp(48px, 7vw, 82px);
  line-height: 1.13;
  letter-spacing: -.055em;
}

h1 em {
  position: relative;
  color: var(--accent);
  font-style: normal;
  white-space: nowrap;
}

h1 em::after {
  content: "";
  position: absolute;
  left: 4%;
  right: -1%;
  bottom: -7px;
  height: 10px;
  background: url("data:image/svg+xml,%3Csvg viewBox='0 0 280 14' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M3 10C67 2 183 2 277 8' fill='none' stroke='%23e45c3b' stroke-width='4' stroke-linecap='round'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
}

.intro {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.9;
}

.search-wrap {
  position: relative;
  width: min(490px, 100%);
  margin: 34px auto 0;
}

.search-wrap svg {
  position: absolute;
  top: 50%;
  left: 20px;
  width: 18px;
  transform: translateY(-50%);
  fill: none;
  stroke: var(--muted);
  stroke-width: 1.7;
  stroke-linecap: round;
}

.search-wrap input {
  width: 100%;
  height: 58px;
  padding: 0 58px 0 50px;
  border: 1px solid var(--line);
  border-radius: 18px;
  outline: 0;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 12px 35px rgba(60, 48, 31, .06);
  backdrop-filter: blur(16px);
  transition: border-color .2s, box-shadow .2s;
}

.search-wrap input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(228, 92, 59, .09), var(--shadow);
}

.search-wrap input::placeholder { color: var(--muted); }

kbd {
  position: absolute;
  top: 50%;
  right: 17px;
  min-width: 25px;
  padding: 3px 7px;
  transform: translateY(-50%);
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 7px;
  color: var(--muted);
  font-size: 12px;
}

.directory { padding-bottom: 70px; }

.directory-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 30px;
  margin-bottom: 30px;
}

.section-kicker { margin: 0 0 10px; }

h2 {
  margin: 0;
  font-family: "Noto Serif SC", "Songti SC", Georgia, serif;
  font-size: 32px;
  letter-spacing: -.04em;
}

.filters { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }

.filter {
  padding: 9px 13px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  cursor: pointer;
  transition: .2s ease;
}

.filter:hover { color: var(--text); }

.filter.active {
  border-color: var(--line);
  background: var(--surface-solid);
  color: var(--text);
  box-shadow: 0 5px 18px rgba(55, 44, 29, .06);
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.product-card {
  position: relative;
  min-height: 300px;
  display: flex;
  flex-direction: column;
  padding: 25px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
  box-shadow: 0 1px 0 rgba(255,255,255,.5) inset;
  backdrop-filter: blur(14px);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}

.product-card::after {
  content: "";
  position: absolute;
  width: 155px;
  height: 155px;
  right: -70px;
  bottom: -75px;
  border-radius: 50%;
  background: var(--tint, #e8c8b6);
  opacity: .14;
  transition: transform .3s ease, opacity .3s ease;
}

.product-card:hover {
  z-index: 2;
  transform: translateY(-6px);
  border-color: color-mix(in srgb, var(--tint) 45%, var(--line));
  box-shadow: var(--shadow);
}

.product-card:hover::after { transform: scale(1.3); opacity: .2; }

.product-card[hidden] { display: none; }

.card-top { display: flex; align-items: center; justify-content: space-between; }

.product-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 15px;
  background: color-mix(in srgb, var(--tint) 18%, var(--surface-solid));
  color: var(--tint);
}

.product-icon svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.status {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 11px;
}

.status i { width: 6px; height: 6px; box-shadow: none; }

.card-copy { margin-top: 35px; }

.card-label { color: var(--tint); font-size: 9px; }

.product-card h3 {
  margin: 8px 0 10px;
  font-family: "Noto Serif SC", "Songti SC", Georgia, serif;
  font-size: 25px;
  letter-spacing: -.035em;
}

.product-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.75;
}

.card-link {
  margin-top: auto;
  padding-top: 24px;
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
}

.card-link b {
  display: inline-block;
  margin-left: 4px;
  color: var(--tint);
  font-size: 16px;
  transition: transform .2s;
}

.product-card:hover .card-link b { transform: translate(3px, -3px); }

.featured { grid-column: span 2; }
.featured .card-copy { max-width: 69%; }
.featured h3 { font-size: 30px; }

.saffron { --tint: #c67c18; }
.coral { --tint: #dc654b; }
.plum { --tint: #9b628c; }
.indigo { --tint: #6471be; }
.blush { --tint: #d77483; }
.sky { --tint: #4a94b6; }
.cinematic { --tint: #725fa6; }
.moss { --tint: #648061; }
.paper { --tint: #927251; }
.mint { --tint: #4b947b; }
.blue { --tint: #477fbd; }
.slate { --tint: #68798d; }
.graphite { --tint: #5e696e; }
.amber { --tint: #bd7b34; }

.empty-state {
  padding: 80px 20px;
  text-align: center;
  color: var(--muted);
}

.empty-state span { font-size: 40px; color: var(--accent); }
.empty-state h3 { margin: 12px 0 4px; color: var(--text); }
.empty-state p { margin: 0; font-size: 13px; }

footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 32px 0 42px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
}

footer p { margin: 0; }
.footer-mark { color: var(--accent); margin-left: 5px; }

@media (max-width: 900px) {
  .hero { margin-top: 65px; }
  .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .featured { grid-column: span 2; }
  .directory-head { align-items: flex-start; flex-direction: column; }
  .filters { justify-content: flex-start; }
}

@media (max-width: 620px) {
  .site-header, main, footer { width: min(100% - 28px, 1180px); }
  .site-header { height: 74px; }
  .online-note { display: none; }
  .hero { margin: 68px auto 88px; }
  h1 { font-size: clamp(44px, 14vw, 60px); }
  .intro br { display: none; }
  .search-wrap input { height: 54px; }
  .filters { flex-wrap: nowrap; width: calc(100vw - 14px); overflow-x: auto; padding-right: 20px; scrollbar-width: none; }
  .filters::-webkit-scrollbar { display: none; }
  .filter { white-space: nowrap; }
  .card-grid { grid-template-columns: 1fr; }
  .featured { grid-column: span 1; }
  .featured .card-copy { max-width: none; }
  .product-card { min-height: 280px; }
  footer { flex-direction: column; }
}

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