:root {
  --canvas: #f3f0e9;
  --paper: #fbfaf7;
  --ink: #191816;
  --ink-soft: #2b2823;
  --muted: #68635b;
  --faint: #918a80;
  --line: rgba(25, 24, 22, .12);
  --line-strong: rgba(25, 24, 22, .24);
  --gold: #8a673f;
  --gold-dark: #64482d;
  --price: #9e3f32;
  --success: #2e6a52;
  --shadow-sm: 0 12px 34px rgba(35, 29, 20, .07);
  --shadow-lg: 0 30px 80px rgba(35, 29, 20, .14);
  --radius-sm: 12px;
  --radius-md: 20px;
  --radius-lg: 32px;
  --content: min(1240px, calc(100vw - 48px));
  --font-display: "Iowan Old Style", "Songti SC", "STSong", "Noto Serif CJK SC",
    "Source Han Serif SC", SimSun, serif;
  --font-ui: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  color-scheme: light;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  min-width: 0;
  overflow-x: hidden;
  overflow-x: clip;
  background: var(--canvas);
  scroll-behavior: smooth;
  scroll-padding-top: 112px;
}

body {
  min-width: 0;
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  overflow-x: clip;
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body.dialog-open {
  overflow: hidden;
}

button,
input,
select,
textarea {
  min-height: 44px;
  border-radius: 0;
  color: inherit;
  font: inherit;
}

button,
select {
  cursor: pointer;
}

button {
  border: 1px solid var(--line-strong);
  background: transparent;
}

button:disabled,
input:disabled,
select:disabled,
textarea:disabled,
[aria-disabled="true"] {
  cursor: not-allowed;
  opacity: .48;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration-color: rgba(25, 24, 22, .34);
  text-decoration-thickness: 1px;
  text-underline-offset: .22em;
}

p,
dl,
dd {
  margin: 0;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.12;
  text-wrap: balance;
}

h2 {
  font-size: clamp(2rem, 4vw, 3.75rem);
  letter-spacing: -.035em;
}

h3 {
  font-size: 1.3rem;
}

fieldset {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

textarea {
  resize: vertical;
}

:where(a, button, input, select, textarea, [tabindex]):focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

.atlas-stage button:focus-visible,
.site-footer button:focus-visible,
.site-footer a:focus-visible,
.cart-bar button:focus-visible,
.toast:focus-visible {
  outline-color: var(--paper);
}

::selection {
  background: var(--gold);
  color: var(--paper);
}

[hidden] {
  display: none !important;
}

[aria-busy="true"] {
  cursor: progress;
}

.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: fixed;
  top: 12px;
  left: 12px;
  z-index: 1200;
  min-height: 44px;
  padding: 9px 16px;
  border-radius: var(--radius-sm);
  background: var(--ink);
  color: var(--paper);
  transform: translateY(calc(-100% - 24px));
  transition: transform 180ms ease;
}

.skip-link:focus,
.skip-link:focus-visible {
  transform: translateY(0);
}

.eyebrow {
  color: var(--gold-dark);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .2em;
  line-height: 1.4;
  text-transform: uppercase;
}

.button-link,
.text-link {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 11px 22px;
  font-size: .92rem;
  font-weight: 650;
  letter-spacing: .04em;
  text-decoration: none;
  transition: background-color 180ms ease, border-color 180ms ease,
    color 180ms ease, transform 180ms ease;
}

.button-link {
  border: 1px solid var(--ink);
  border-radius: var(--radius-sm);
  background: var(--ink);
  color: var(--paper);
}

.text-link {
  border-bottom: 1px solid var(--line-strong);
  color: var(--ink);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 700;
  border-bottom: 1px solid var(--line);
  background: var(--canvas);
}

.site-header__inner {
  width: var(--content);
  min-height: 76px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: clamp(18px, 3vw, 42px);
}

.brand {
  display: inline-grid;
  flex: none;
  gap: 0;
  min-height: 48px;
  align-content: center;
  color: var(--ink);
  text-decoration: none;
}

.brand__cn {
  font-family: var(--font-display);
  font-size: 1.18rem;
  letter-spacing: .16em;
  line-height: 1.2;
}

.brand__en {
  color: var(--gold-dark);
  font-size: .62rem;
  font-weight: 750;
  letter-spacing: .31em;
  line-height: 1.4;
}

.brand__annotation {
  color: var(--muted);
  font-size: .78rem;
  letter-spacing: .04em;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(8px, 1.4vw, 24px);
  margin-left: auto;
}

.site-nav a {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  padding-inline: 5px;
  color: var(--muted);
  font-size: .86rem;
  text-decoration: none;
}

main > section {
  scroll-margin-top: 112px;
}

.hero,
.featured,
.atlas,
.catalog,
.service-notes {
  width: var(--content);
  margin-inline: auto;
}

.section-heading {
  display: grid;
  gap: 16px;
  margin-bottom: clamp(24px, 4vw, 44px);
}

.section-heading > div {
  display: grid;
  gap: 12px;
}

.section-heading > p {
  max-width: 38rem;
  color: var(--muted);
  font-size: .93rem;
}

/* Editorial hero */
.hero {
  min-height: min(720px, calc(100vh - 76px));
  padding-block: clamp(42px, 7vw, 96px);
  display: grid;
  grid-template-columns: minmax(0, .94fr) minmax(340px, 1.06fr);
  align-items: center;
  gap: clamp(30px, 6vw, 92px);
}

.hero-copy,
.hero__copy {
  min-width: 0;
  display: grid;
  align-content: center;
  justify-items: start;
}

.hero h1 {
  max-width: 8.6em;
  margin-top: 20px;
  font-size: clamp(2.8rem, 5.6vw, 5.8rem);
  letter-spacing: -.06em;
}

.hero__intro {
  max-width: 35rem;
  margin-top: 26px;
  color: var(--muted);
  font-size: clamp(.96rem, 1.4vw, 1.08rem);
}

.hero-actions {
  margin-top: 32px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 22px;
}

.hero-guide {
  width: 100%;
  max-width: 33rem;
  margin-top: clamp(36px, 6vw, 68px);
  padding-top: 18px;
  border-top: 1px solid var(--line);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.hero-guide div {
  min-width: 0;
}

.hero-guide dt {
  color: var(--gold-dark);
  font-family: var(--font-display);
  font-size: .88rem;
}

.hero-guide dd {
  margin-top: 2px;
  color: var(--muted);
  font-size: .8rem;
}

.hero-visual,
.hero__visual {
  position: relative;
  min-width: 0;
  min-height: 560px;
  overflow: hidden;
  isolation: isolate;
  border-radius: var(--radius-lg) var(--radius-sm) var(--radius-lg) var(--radius-sm);
  background: var(--ink-soft);
  box-shadow: var(--shadow-lg);
}

.hero-visual::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 50%;
  left: 50%;
  width: min(48vw, 420px);
  aspect-ratio: 1;
  border: 1px solid rgba(251, 250, 247, .22);
  border-radius: 50%;
  box-shadow: 0 0 0 72px rgba(251, 250, 247, .055),
    0 0 0 144px rgba(251, 250, 247, .035);
  transform: translate(-50%, -50%);
}

.hero-visual::after {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 50% 0 auto;
  border-top: 1px solid rgba(251, 250, 247, .12);
}

.hero-visual > img,
.hero-visual__image {
  width: 100%;
  height: 100%;
  min-height: inherit;
  object-fit: cover;
}

.hero-story {
  position: absolute;
  inset: 18px 18px 98px;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(112px, .62fr);
  gap: 10px;
}

.hero-story button {
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  padding: 0;
  border-color: rgba(251, 250, 247, .24);
  background: #d7d0c4;
}

.hero-story__primary:only-child {
  grid-column: 1 / -1;
}

.hero-story__auxiliary {
  min-width: 0;
  display: grid;
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.hero-story img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-story > p {
  grid-column: 1 / -1;
  place-self: center;
  color: var(--paper);
  font-family: var(--font-display);
}

.hero-visual__placeholder {
  position: absolute;
  top: 16%;
  right: 12%;
  bottom: 15%;
  left: 13%;
  border-radius: 48% 52% 46% 54%;
  background: #d7d0c4;
  box-shadow: 0 28px 70px rgba(0, 0, 0, .24);
  transform: rotate(-7deg);
}

.hero-visual__label {
  position: absolute;
  right: 22px;
  bottom: 22px;
  left: 22px;
  padding: 14px 16px;
  border: 1px solid rgba(251, 250, 247, .22);
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-display);
  font-size: .9rem;
}

.hero-visual__label span {
  display: block;
  margin-bottom: 4px;
  color: var(--gold-dark);
  font-family: var(--font-ui);
  font-size: .62rem;
  font-weight: 750;
  letter-spacing: .16em;
}

/* Homepage fate quiz */
.fate-quiz {
  --fate-accent: var(--gold);
  width: var(--content);
  margin-inline: auto;
  padding-block: clamp(72px, 10vw, 132px);
  border-top: 1px solid var(--line);
  display: grid;
  grid-template-columns: minmax(260px, .78fr) minmax(0, 1.22fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: start;
  background-color: var(--paper);
  background:
    linear-gradient(180deg, rgba(251, 250, 247, .62), rgba(251, 250, 247, 0) 52%),
    linear-gradient(90deg, rgba(138, 103, 63, .08), rgba(138, 103, 63, 0) 36%),
    var(--paper);
}

.fate-quiz__copy {
  position: sticky;
  top: 118px;
  min-width: 0;
  display: grid;
  justify-items: start;
}

.fate-quiz__copy h2 {
  max-width: 8em;
  margin-top: 16px;
}

.fate-quiz__copy > p:not(.eyebrow) {
  max-width: 28rem;
  margin-top: 18px;
  color: var(--muted);
  font-size: clamp(.96rem, 1.3vw, 1.06rem);
}

.fate-steps {
  width: 100%;
  max-width: 29rem;
  margin-top: 28px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-block: 1px solid var(--line);
}

.fate-steps span {
  min-width: 0;
  padding: 13px 10px;
  color: var(--gold-dark);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-align: center;
}

.fate-steps span + span {
  border-left: 1px solid var(--line);
}

.fate-quiz__start,
.fate-submit,
.fate-result__actions button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 11px 18px;
  border-radius: var(--radius-sm);
  font-size: .9rem;
  font-weight: 700;
  letter-spacing: .04em;
  transition: background-color 180ms ease, border-color 180ms ease,
    color 180ms ease, transform 180ms ease;
}

.fate-quiz__start {
  margin-top: 28px;
  border-color: var(--ink);
  background: var(--ink);
  color: var(--paper);
}

.fate-quiz__stage {
  min-width: 0;
  display: grid;
  gap: 18px;
}

.fate-quiz__mosaic {
  min-width: 0;
  min-height: 390px;
  display: grid;
  grid-template-columns: 1.1fr .86fr .72fr;
  grid-template-rows: 1fr .78fr;
  gap: 10px;
}

.fate-quiz__mosaic > * {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(251, 250, 247, .5);
  border-radius: var(--radius-md);
  background: #e8e1d5;
  box-shadow: var(--shadow-sm);
}

.fate-quiz__mosaic > :first-child {
  grid-row: 1 / span 2;
  border-radius: var(--radius-lg) var(--radius-sm) var(--radius-md) var(--radius-sm);
}

.fate-quiz__mosaic > :nth-child(2) {
  margin-top: 28px;
}

.fate-quiz__mosaic > :nth-child(3) {
  grid-row: 1 / span 2;
  margin-block: 58px 20px;
  border-radius: var(--radius-sm) var(--radius-md) var(--radius-lg) var(--radius-md);
}

.fate-quiz__mosaic > :nth-child(4) {
  margin-bottom: 22px;
}

.fate-mosaic-card {
  position: relative;
  padding: 0;
  border: 0;
}

.fate-mosaic-card img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
  transition: transform 260ms ease;
}

.fate-mosaic-card span {
  position: absolute;
  right: 10px;
  bottom: 10px;
  max-width: calc(100% - 20px);
  padding: 5px 8px;
  border: 1px solid rgba(251, 250, 247, .4);
  background: rgba(25, 24, 22, .54);
  color: var(--paper);
  font-size: .7rem;
  line-height: 1.35;
}

.fate-panel {
  min-width: 0;
  padding: clamp(18px, 3vw, 28px);
  display: grid;
  gap: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: rgba(251, 250, 247, .92);
  box-shadow: var(--shadow-sm);
}

.fate-panel__grid {
  min-width: 0;
  display: grid;
  grid-template-columns: 1.1fr .8fr .8fr;
  gap: 12px;
}

.fate-panel__grid--stacked {
  grid-template-columns: 1fr;
}

.fate-field {
  min-width: 0;
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .06em;
}

.fate-field input,
.fate-field select {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--paper);
  color: var(--ink);
}

.fate-field input {
  padding: 10px 12px;
}

.fate-field select {
  padding: 10px 34px 10px 12px;
}

.fate-field--wish {
  gap: 10px;
}

.fate-field--wish legend {
  padding: 0;
}

.fate-wishes {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 9px;
}

.fate-wish {
  min-width: 0;
  min-height: 56px;
  padding: 10px;
  display: grid;
  gap: 2px;
  align-content: center;
  border-color: var(--line);
  border-radius: var(--radius-sm);
  background: rgba(253, 249, 242, .7);
  text-align: left;
}

.fate-wish strong {
  overflow-wrap: anywhere;
  font-size: .88rem;
}

.fate-wish span {
  color: var(--muted);
  font-size: .7rem;
}

.fate-wish[aria-checked="true"] {
  border-color: var(--gold);
  background: rgba(138, 103, 63, .1);
  box-shadow: inset 0 0 0 1px rgba(138, 103, 63, .18);
}

.fate-submit {
  width: 100%;
  border-color: var(--gold-dark);
  background: var(--gold-dark);
  color: var(--paper);
}

.fate-note {
  color: var(--faint);
  font-size: .76rem;
}

.fate-result {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(138, 103, 63, .22);
  border-radius: var(--radius-md);
  background: var(--paper);
  box-shadow: var(--shadow-lg);
}

.fate-result__inner {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(210px, .85fr) minmax(0, 1.15fr);
}

.fate-result__media {
  position: relative;
  width: 100%;
  min-height: 390px;
  padding: 0;
  overflow: hidden;
  border: 0;
  background: #e7e1d7;
  text-align: left;
}

.fate-result__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.fate-result__badge {
  position: absolute;
  left: 16px;
  bottom: 16px;
  padding: 6px 10px;
  border: 1px solid rgba(251, 250, 247, .48);
  background: rgba(25, 24, 22, .58);
  color: var(--paper);
  font-size: .76rem;
  font-weight: 700;
}

.fate-result__body {
  min-width: 0;
  padding: clamp(22px, 4vw, 36px);
  display: grid;
  gap: 18px;
  align-content: center;
}

.fate-result__body h3 {
  font-size: clamp(1.7rem, 3vw, 2.5rem);
}

.fate-result__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: .82rem;
}

.fate-result__meta span {
  padding: 4px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(253, 249, 242, .72);
}

.fate-result__reasons {
  display: grid;
  gap: 10px;
}

.fate-reason {
  min-width: 0;
  padding-left: 14px;
  border-left: 2px solid rgba(138, 103, 63, .46);
}

.fate-reason strong {
  display: block;
  color: var(--gold-dark);
  font-size: .78rem;
  letter-spacing: .08em;
}

.fate-reason p {
  margin-top: 3px;
  color: var(--muted);
  font-size: .88rem;
}

.fate-result__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.fate-result__actions button:first-child {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--paper);
}

.fate-result__actions button:nth-child(2) {
  border-color: var(--gold-dark);
  color: var(--gold-dark);
}

.fate-result__actions button:nth-child(3) {
  border-color: transparent;
  color: var(--muted);
}

.fate-result__placeholder {
  padding: 24px;
  color: var(--muted);
}

/* Editorial feature wall */
.featured {
  padding-block: clamp(72px, 10vw, 132px);
  border-top: 1px solid var(--line);
}

.featured-grid {
  min-width: 0;
  min-height: 470px;
  display: grid;
  grid-template-columns: 1.2fr .9fr .9fr;
  gap: clamp(12px, 1.8vw, 24px);
}

.featured-grid > * {
  min-width: 0;
}

.featured-placeholder,
.featured-card {
  min-height: 100%;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--paper);
}

.featured-placeholder:nth-child(2),
.featured-card:nth-child(2) {
  margin-top: 42px;
  margin-bottom: 16px;
}

.featured-placeholder:nth-child(3),
.featured-card:nth-child(3) {
  margin-top: 84px;
  margin-bottom: 32px;
}

.featured-card {
  position: relative;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  box-shadow: var(--shadow-sm);
  transition: border-color 180ms ease, box-shadow 180ms ease, transform 220ms ease;
}

.featured-card__media,
.featured-card > button:first-child {
  position: relative;
  min-height: 0;
  overflow: hidden;
  border: 0;
  background: #e7e1d7;
}

.featured-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 280ms ease;
}

.featured-card__body {
  padding: 18px 19px 20px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 8px 14px;
}

.featured-card__body h3,
.featured-card__title {
  overflow-wrap: anywhere;
  font-size: clamp(1.05rem, 2vw, 1.45rem);
}

.featured-card__price,
.product-card__price,
.product-price {
  color: var(--price);
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  white-space: nowrap;
}

/* Selection atlas */
.atlas {
  min-height: 560px;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(260px, .72fr) minmax(0, 1.28fr);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--paper);
  box-shadow: var(--shadow-sm);
}

.atlas-copy,
.atlas__copy {
  padding: clamp(38px, 5vw, 72px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.atlas-copy h2,
.atlas__copy h2 {
  margin-top: 14px;
}

.atlas-copy > p:last-child,
.atlas__copy > p:last-child {
  max-width: 30rem;
  margin-top: 22px;
  color: var(--muted);
}

.atlas-stage {
  position: relative;
  min-width: 0;
  min-height: 526px;
  margin: 16px;
  overflow: hidden;
  display: grid;
  grid-template-rows: minmax(430px, 1fr) auto;
  isolation: isolate;
  border-radius: calc(var(--radius-lg) - 8px);
  background: var(--ink-soft);
  color: var(--paper);
}

.atlas-stage::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 50%;
  left: 50%;
  width: 168px;
  aspect-ratio: 1;
  border: 1px solid rgba(251, 250, 247, .2);
  border-radius: 50%;
  box-shadow: 0 0 0 92px rgba(251, 250, 247, .07),
    0 0 0 184px rgba(251, 250, 247, .045);
  transform: translate(-50%, -50%);
}

.atlas-stage::after {
  content: "";
  position: absolute;
  z-index: -1;
  top: 50%;
  right: 7%;
  left: 7%;
  border-top: 1px solid rgba(251, 250, 247, .11);
}

.atlas-placeholder {
  position: relative;
  grid-row: 1;
  width: 100%;
  height: auto;
  min-height: 430px;
}

.atlas-placeholder span {
  position: absolute;
  width: 64px;
  aspect-ratio: 1;
  min-height: 0;
  border: 1px solid rgba(251, 250, 247, .24);
  border-radius: 50%;
  background: rgba(251, 250, 247, .14);
}

.atlas-placeholder span:nth-child(1) {
  top: 19%;
  left: 18%;
}

.atlas-placeholder span:nth-child(2) {
  top: 29%;
  right: 18%;
  width: 82px;
}

.atlas-placeholder span:nth-child(3) {
  top: 49%;
  left: 42%;
  width: 92px;
}

.atlas-placeholder span:nth-child(4) {
  right: 30%;
  bottom: 15%;
  width: 56px;
}

.atlas-placeholder span:nth-child(5) {
  bottom: 22%;
  left: 16%;
  width: 74px;
}

.atlas-map,
.atlas-stage__canvas,
.atlas-nodes {
  position: relative;
  grid-row: 1;
  width: 100%;
  height: auto;
  min-height: 430px;
}

.atlas-node {
  --size: 82px;
  position: absolute;
  top: var(--y, 50%);
  left: var(--x, 50%);
  z-index: 2;
  width: var(--size);
  min-height: var(--size);
  padding: 8px;
  border: 1px solid rgba(251, 250, 247, .35);
  border-radius: 50%;
  background: var(--ink-soft);
  color: var(--paper);
  font-size: .76rem;
  line-height: 1.25;
  transform: translate(-50%, -50%);
  transition: background-color 180ms ease, border-color 180ms ease,
    color 180ms ease, transform 180ms ease;
}

.atlas-node small,
.atlas-node__count {
  display: block;
  margin-top: 2px;
  color: #d5c8b7;
  font-size: .66rem;
}

.atlas-node:nth-child(1) { --x: 15%; --y: 22%; }
.atlas-node:nth-child(2) { --x: 35%; --y: 16%; --size: 72px; }
.atlas-node:nth-child(3) { --x: 59%; --y: 21%; --size: 92px; }
.atlas-node:nth-child(4) { --x: 83%; --y: 27%; --size: 68px; }
.atlas-node:nth-child(5) { --x: 24%; --y: 47%; --size: 94px; }
.atlas-node:nth-child(6) { --x: 49%; --y: 45%; --size: 76px; }
.atlas-node:nth-child(7) { --x: 73%; --y: 49%; --size: 104px; }
.atlas-node:nth-child(8) { --x: 91%; --y: 53%; --size: 62px; }
.atlas-node:nth-child(9) { --x: 13%; --y: 74%; --size: 70px; }
.atlas-node:nth-child(10) { --x: 37%; --y: 78%; --size: 88px; }
.atlas-node:nth-child(11) { --x: 63%; --y: 76%; --size: 74px; }
.atlas-node:nth-child(12) { --x: 84%; --y: 80%; --size: 86px; }

.atlas-node[aria-pressed="true"],
.atlas-node.is-active {
  border-color: #c7ad8c;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 12px 30px rgba(0, 0, 0, .25);
}

.atlas-node[aria-pressed="true"] small,
.atlas-node[aria-pressed="true"] .atlas-node__count {
  color: var(--gold-dark);
}

.atlas-node[data-picked="true"],
.atlas-node.has-picked {
  box-shadow: 0 0 0 3px rgba(199, 173, 140, .2);
}

.atlas-node[data-picked="true"]::after {
  content: "";
  position: absolute;
  top: 7px;
  right: 7px;
  width: 7px;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #d8b680;
}

.atlas-price-controls {
  position: relative;
  z-index: 3;
  inset: auto;
  grid-row: 2;
  padding: 12px 18px 16px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  border-top: 1px solid rgba(251, 250, 247, .12);
  background: var(--ink-soft);
}

.atlas-price,
.price-ring,
.atlas-price-ring {
  min-height: 44px;
  padding: 9px 14px;
  border-color: rgba(251, 250, 247, .26);
  background: var(--ink-soft);
  color: var(--paper);
  font-size: .75rem;
}

.atlas-price[aria-pressed="true"],
.price-ring[aria-pressed="true"],
.atlas-price-ring[aria-pressed="true"] {
  border-color: #c7ad8c;
  background: var(--paper);
  color: var(--ink);
}

/* Catalog controls and results */
.catalog {
  padding-block: clamp(90px, 12vw, 156px);
}

.catalog__heading {
  align-items: end;
}

.catalog-toolbar {
  position: sticky;
  top: 76px;
  z-index: 600;
  padding: 14px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: end;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--paper);
  box-shadow: var(--shadow-sm);
}

.field {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.field--search {
  grid-column: 1 / -1;
}

.field label {
  color: var(--muted);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .06em;
}

.field input,
.field select {
  width: 100%;
  min-width: 0;
  padding: 9px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  background: var(--paper);
  color: var(--ink);
}

.field input::placeholder {
  color: var(--muted);
  opacity: .78;
}

.field input:focus,
.field select:focus {
  border-color: var(--gold);
}

.catalog-toolbar > button,
.load-more,
.category-nav button,
.filter-chip {
  min-height: 44px;
  padding: 9px 14px;
  border-radius: 9px;
  font-size: .82rem;
  font-weight: 650;
  transition: background-color 160ms ease, border-color 160ms ease,
    color 160ms ease;
}

#pickedFilter {
  border-color: var(--gold);
  color: var(--gold-dark);
}

#resetFilters {
  border-color: transparent;
  color: var(--muted);
  text-decoration: underline;
  text-decoration-color: var(--line-strong);
  text-underline-offset: .25em;
}

[aria-pressed="true"],
.is-active,
.active-filter,
.filter-chip.is-active {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--paper);
}

#pickedFilter[aria-pressed="true"] {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--paper);
}

.catalog-layout {
  min-width: 0;
  margin-top: 32px;
}

.catalog__meta {
  min-width: 0;
  margin-bottom: 22px;
}

#resultSummary {
  color: var(--muted);
  font-size: .85rem;
}

.category-nav {
  max-width: 100%;
  margin-top: 12px;
  padding: 3px;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--line-strong) transparent;
}

.category-nav button {
  flex: none;
  border-color: var(--line);
  background: transparent;
  color: var(--muted);
  white-space: nowrap;
}

.category-nav button[aria-pressed="true"],
.category-nav button[aria-current="true"] {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--paper);
}

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

.product-grid {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  gap: 24px 16px;
}

.product-grid > * {
  min-width: 0;
}

.product-grid noscript,
.product-grid > .empty-state {
  grid-column: 1 / -1;
}

.product-card {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--paper);
  box-shadow: 0 1px 0 rgba(25, 24, 22, .03);
  transition: border-color 180ms ease, box-shadow 220ms ease, transform 220ms ease;
}

.product-card.is-picked,
.product-card[data-picked="true"] {
  border-color: var(--gold);
  box-shadow: 0 0 0 1px var(--gold), var(--shadow-sm);
}

.product-card__media,
.product-card__image-button,
.product-card > button:first-child {
  position: relative;
  width: 100%;
  min-height: 0;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  display: block;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: #e8e2d8;
}

.product-card__media img,
.product-card__image,
.product-card > button:first-child img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 260ms ease;
}

.product-card__badge,
.stock-badge,
.image-count {
  position: absolute;
  top: 10px;
  left: 10px;
  min-height: 28px;
  padding: 4px 8px;
  border: 1px solid rgba(251, 250, 247, .58);
  border-radius: 6px;
  background: var(--paper);
  color: var(--ink);
  font-size: .68rem;
  font-weight: 700;
  line-height: 1.35;
}

.image-count {
  right: 10px;
  left: auto;
}

.product-card__body {
  min-width: 0;
  padding: 15px;
  display: grid;
  gap: 10px;
}

.product-card__heading {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 8px;
}

.product-card h3,
.product-card__title,
.product-card__title-button {
  min-width: 0;
  overflow-wrap: anywhere;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.03rem;
  font-weight: 500;
  line-height: 1.35;
  text-align: left;
}

.product-card__title-button {
  min-height: 44px;
  padding: 0;
  border: 0;
}

.product-card__meta,
.product-meta {
  color: var(--muted);
  font-size: .75rem;
}

.product-card__actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
}

.product-card__actions > button,
.add-to-cart,
.add-button {
  min-height: 44px;
  padding: 9px 12px;
  border-color: var(--ink);
  border-radius: 8px;
  background: var(--ink);
  color: var(--paper);
  font-size: .78rem;
  font-weight: 700;
}

.quantity-control,
.quantity-stepper,
.stepper {
  min-width: 0;
  display: inline-grid;
  grid-template-columns: 44px minmax(32px, auto) 44px;
  align-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--paper);
}

.quantity-control button,
.quantity-stepper button,
.stepper button {
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  border: 0;
  border-radius: 0;
  font-size: 1.1rem;
}

.quantity-control output,
.quantity-stepper output,
.stepper output,
.quantity-value {
  min-width: 32px;
  text-align: center;
  font-size: .86rem;
  font-variant-numeric: tabular-nums;
}

.quantity-control button:disabled,
.quantity-stepper button:disabled,
.stepper button:disabled {
  background: var(--canvas);
  color: var(--faint);
  opacity: .62;
}

.product-card__quantity {
  grid-column: 1 / -1;
  width: 100%;
  grid-template-columns: 44px minmax(0, 1fr) 44px;
}

.product-card[data-picked="false"] .product-card__quantity {
  display: none;
}

.load-more {
  min-width: min(100%, 220px);
  margin: 42px auto 0;
  display: block;
  border-color: var(--ink);
  background: transparent;
  color: var(--ink);
}

.load-more.is-loading,
.load-more[aria-busy="true"] {
  color: var(--muted);
}

/* Service notes and footer */
.service-notes {
  padding-block: clamp(64px, 9vw, 112px);
  border-top: 1px solid var(--line);
}

.service-notes__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid var(--line-strong);
}

.service-notes__grid article {
  min-width: 0;
  min-height: 190px;
  padding: 28px clamp(18px, 3vw, 38px) 30px;
  border-right: 1px solid var(--line);
}

.service-notes__grid article:first-child {
  padding-left: 0;
}

.service-notes__grid article:last-child {
  padding-right: 0;
  border-right: 0;
}

.service-notes__grid article::before {
  display: block;
  margin-bottom: 38px;
  color: var(--gold-dark);
  font-family: var(--font-display);
  font-size: .76rem;
}

.service-notes__grid article:nth-child(1)::before { content: "01"; }
.service-notes__grid article:nth-child(2)::before { content: "02"; }
.service-notes__grid article:nth-child(3)::before { content: "03"; }

.service-notes__grid p {
  margin-top: 12px;
  color: var(--muted);
  font-size: .9rem;
}

.site-footer {
  padding: clamp(52px, 7vw, 82px) 0 calc(52px + env(safe-area-inset-bottom));
  background: var(--ink-soft);
  color: var(--paper);
}

.site-footer__inner {
  width: var(--content);
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: end;
  gap: 28px clamp(28px, 5vw, 70px);
}

.site-footer__brand {
  margin-bottom: 8px;
  font-family: var(--font-display);
  font-size: 1.45rem;
  letter-spacing: .08em;
}

.site-footer__brand span {
  margin-left: 8px;
  color: #d5c8b7;
  font-family: var(--font-ui);
  font-size: .66rem;
  font-weight: 750;
  letter-spacing: .2em;
}

.site-footer__inner > div:first-child > p:last-child,
.site-footer__contact {
  color: #e1dcd3;
  font-size: .84rem;
}

.site-footer__contact {
  display: grid;
  gap: 8px;
}

.site-footer__contact button {
  justify-self: start;
  min-height: 44px;
  padding: 8px 14px;
  border-color: rgba(251, 250, 247, .36);
  border-radius: 8px;
  color: var(--paper);
}

.site-footer__inner > a {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  color: #e1dcd3;
  font-size: .84rem;
}

/* Dialogs, selection list, cart bar, and feedback */
.dialog-overlay {
  position: fixed;
  z-index: 890;
  inset: 0;
  background: rgba(25, 24, 22, .58);
  opacity: 0;
  transition: opacity 180ms ease;
}

.dialog-overlay:not([hidden]),
.dialog-overlay.is-open {
  opacity: 1;
}

.dialog {
  position: fixed;
  z-index: 900;
  inset: 0;
  width: 100%;
  max-width: none;
  height: 100%;
  margin: 0;
  padding: clamp(12px, 4vw, 44px);
  border: 0;
  background: transparent;
  display: grid;
  place-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.dialog[open],
.dialog[aria-hidden="false"],
.dialog.is-open {
  display: grid;
  opacity: 1;
  pointer-events: auto;
}

.dialog__panel {
  width: min(1080px, 100%);
  max-height: min(880px, calc(100vh - 40px));
  overflow: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--paper);
  box-shadow: var(--shadow-lg);
  transform: translateY(16px) scale(.99);
  transition: transform 220ms ease;
}

.dialog[open] .dialog__panel,
.dialog[aria-hidden="false"] .dialog__panel,
.dialog.is-open .dialog__panel {
  transform: translateY(0) scale(1);
}

.dialog__panel--compact {
  width: min(640px, 100%);
  padding-bottom: 24px;
}

.dialog__panel--cart {
  width: min(860px, 100%);
}

.dialog__panel--compact > p,
.dialog__panel--compact > label,
.dialog__panel--compact > textarea {
  margin-inline: 24px;
}

.dialog__panel--compact > p {
  margin-bottom: 14px;
  color: var(--muted);
  font-size: .9rem;
}

.dialog__header {
  position: sticky;
  top: 0;
  z-index: 4;
  min-height: 82px;
  padding: 17px clamp(18px, 3vw, 30px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) 52px;
  align-items: center;
  gap: 6px 16px;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}

.dialog__header .eyebrow {
  grid-column: 1;
}

.dialog__header h2 {
  grid-column: 1;
  font-size: clamp(1.65rem, 3vw, 2.45rem);
}

.dialog__header button {
  grid-column: 2;
  grid-row: 1 / span 2;
  width: 48px;
  min-height: 48px;
  padding: 0;
  border-color: var(--line);
  border-radius: 50%;
  font-size: 1.65rem;
  line-height: 1;
}

#productDialogBody {
  min-width: 0;
}

.product-dialog,
.product-dialog__layout,
#productDialogBody > .product-detail-layout {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(280px, .88fr);
}

.product-gallery {
  min-width: 0;
  padding: clamp(16px, 3vw, 28px);
  background: #e8e2d8;
}

.product-gallery__main,
.product-dialog__image {
  width: 100%;
  aspect-ratio: 1;
  overflow: hidden;
  border: 0;
  background: #ddd5ca;
}

.product-gallery__main img,
.product-dialog__image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.product-gallery__main.image-fallback {
  display: grid;
  place-items: center;
  color: var(--muted);
}

.product-thumbnails,
.product-gallery__thumbs {
  margin-top: 12px;
  padding-bottom: 3px;
  display: flex;
  gap: 9px;
  overflow-x: auto;
}

.product-thumbnails button,
.product-gallery__thumbs button {
  flex: 0 0 64px;
  width: 64px;
  min-height: 64px;
  overflow: hidden;
  padding: 0;
  border-color: var(--line);
  border-radius: 7px;
}

.product-thumbnails button[aria-pressed="true"],
.product-gallery__thumbs button[aria-pressed="true"] {
  border-color: var(--gold);
  box-shadow: 0 0 0 1px var(--gold);
}

.product-thumbnails button.image-fallback,
.product-gallery__thumbs button.image-fallback {
  min-height: 64px;
}

.product-thumbnails img,
.product-gallery__thumbs img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-detail,
.product-dialog__details {
  min-width: 0;
  padding: clamp(26px, 5vw, 58px);
}

.product-detail h3,
.product-dialog__details h3 {
  margin-bottom: 14px;
  font-size: clamp(1.8rem, 4vw, 3.5rem);
}

.product-detail .product-price,
.product-dialog__details .product-price {
  font-size: 1.35rem;
}

.product-detail__meta,
.product-dialog__meta {
  margin-block: 24px;
  padding-block: 16px;
  display: grid;
  gap: 8px;
  border-block: 1px solid var(--line);
  color: var(--muted);
  font-size: .86rem;
}

.product-detail__actions,
.product-dialog__actions {
  margin-top: 26px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.product-detail__actions > button,
.product-dialog__actions > button,
.copy-product-link {
  min-height: 48px;
  padding: 10px 18px;
  border-radius: 8px;
}

#cartItems,
#discountControls,
.cart-summary,
.cart-actions {
  margin-inline: clamp(18px, 4vw, 42px);
}

#cartItems {
  padding-block: 14px;
}

.cart-item,
#cartItems > article {
  min-width: 0;
  padding-block: 16px;
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  border-bottom: 1px solid var(--line);
}

.cart-item__image {
  width: 68px;
  aspect-ratio: 1;
  min-height: 68px;
  overflow: hidden;
  border-radius: 8px;
  background: #e7e1d7;
}

.cart-item__image img,
.cart-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cart-item__image.image-fallback {
  min-height: 68px;
  border-radius: 8px;
}

.cart-item__image.image-fallback::before {
  font-size: .66rem;
  letter-spacing: .08em;
}

.cart-item__image.image-fallback::after {
  display: none;
}

.cart-item__details {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.cart-item h3,
.cart-item__name {
  overflow-wrap: anywhere;
  font-family: var(--font-display);
  font-size: 1rem;
}

.cart-item__price,
.cart-item__subtotal {
  color: var(--price);
  font-size: .82rem;
  font-variant-numeric: tabular-nums;
}

.cart-item__controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.cart-item__controls .quantity-control {
  grid-template-columns: 42px minmax(30px, auto) 42px;
}

.cart-item__controls .quantity-control button {
  min-width: 42px;
  min-height: 42px;
}

.cart-item__remove,
.remove-item {
  min-width: 44px;
  min-height: 44px;
  border-color: transparent;
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: .2em;
}

#discountControls {
  padding-block: 20px;
  border-bottom: 1px solid var(--line);
}

#discountControls legend {
  margin-bottom: 12px;
  font-family: var(--font-display);
  font-size: 1.12rem;
}

.discount-help {
  margin: -4px 0 14px;
  color: var(--muted);
  font-size: .8rem;
}

#discountOptions,
.discount-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

#discountOptions label,
.discount-option {
  min-height: 44px;
  padding: 8px 12px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: .82rem;
  cursor: pointer;
  transition: border-color 160ms ease, background-color 160ms ease;
}

#discountOptions label:has(input:checked),
.discount-option:has(input:checked) {
  border-color: var(--gold);
  background: rgba(138, 103, 63, .09);
  color: var(--gold-dark);
}

#discountOptions input,
.discount-option input {
  min-height: 0;
  accent-color: var(--gold-dark);
}

.discount-custom {
  margin-top: 15px;
  display: grid;
  grid-template-columns: auto minmax(116px, 170px) minmax(0, 1fr);
  align-items: start;
  gap: 8px 12px;
  color: var(--muted);
  font-size: .82rem;
}

.discount-custom > label {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.discount-custom > div {
  position: relative;
}

.discount-custom input {
  width: 100%;
  padding: 8px 34px 8px 11px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--paper);
  font-size: 16px;
  font-variant-numeric: tabular-nums;
}

.discount-custom > div > span {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
}

.discount-custom input[aria-invalid="true"] {
  border-color: var(--price);
  box-shadow: 0 0 0 1px var(--price);
}

.field-error {
  min-height: 1.4em;
  padding-top: 10px;
  color: var(--price);
  font-size: .78rem;
  line-height: 1.4;
}

.cart-summary {
  padding-block: 22px;
  display: grid;
  gap: 8px;
  border-bottom: 1px solid var(--line);
}

.cart-summary > div,
.cart-summary > p {
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

.cart-summary strong,
.cart-summary__total {
  color: var(--price);
  font-size: 1.18rem;
  font-variant-numeric: tabular-nums;
}

.cart-summary__discount strong {
  color: var(--success);
}

.cart-summary__empty {
  color: var(--muted);
  font-size: .84rem;
}

.cart-actions {
  padding-block: 22px 30px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
}

.cart-actions > button {
  min-height: 48px;
  padding: 10px 18px;
  border-radius: 8px;
}

#copyList {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--paper);
}

#clearCart {
  border-color: transparent;
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: .25em;
}

.clear-cart-confirm {
  grid-column: 1 / -1;
  padding: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid rgba(158, 63, 50, .3);
  border-radius: 9px;
  background: rgba(158, 63, 50, .055);
}

.clear-cart-confirm > p {
  color: var(--ink);
  font-size: .86rem;
}

.clear-cart-confirm > div {
  flex: none;
  display: flex;
  gap: 8px;
}

.clear-cart-confirm button {
  min-height: 44px;
  padding: 8px 13px;
  border-radius: 8px;
}

#confirmClearCart {
  border-color: var(--price);
  background: var(--price);
  color: var(--paper);
}

.cart-empty {
  min-height: 150px;
  margin-block: 8px;
  font-size: .88rem;
}

.cart-actions p {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: .82rem;
}

#manualCopyText {
  width: calc(100% - 48px);
  min-height: 240px;
  padding: 14px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--canvas);
  font-size: 16px;
  line-height: 1.6;
}

.cart-bar {
  position: fixed;
  z-index: 800;
  right: 50%;
  bottom: max(16px, env(safe-area-inset-bottom));
  width: min(720px, calc(100vw - 32px));
  min-height: 66px;
  padding: 8px 8px 8px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border: 1px solid rgba(251, 250, 247, .18);
  border-radius: var(--radius-sm);
  background: var(--ink-soft);
  color: var(--paper);
  box-shadow: var(--shadow-lg);
  transform: translateX(50%);
}

.cart-bar > div {
  min-width: 0;
  display: flex;
  align-items: baseline;
  gap: 16px;
}

.cart-bar span {
  color: #e1dcd3;
  font-size: .84rem;
}

.cart-bar strong {
  color: var(--paper);
  font-size: 1.1rem;
  font-variant-numeric: tabular-nums;
}

.cart-bar button {
  flex: none;
  min-height: 48px;
  padding: 10px 18px;
  border-color: var(--paper);
  border-radius: 8px;
  background: var(--paper);
  color: var(--ink);
  font-weight: 700;
}

.toast {
  position: fixed;
  z-index: 1100;
  right: 50%;
  bottom: calc(98px + env(safe-area-inset-bottom));
  max-width: min(420px, calc(100vw - 32px));
  padding: 12px 16px;
  border: 1px solid rgba(251, 250, 247, .2);
  border-radius: 8px;
  background: var(--ink-soft);
  color: var(--paper);
  box-shadow: var(--shadow-lg);
  font-size: .86rem;
  transform: translateX(50%);
}

.toast.is-success {
  background: var(--success);
}

.toast.is-error {
  background: var(--price);
}

.empty-state {
  width: 100%;
  min-height: 180px;
  padding: 28px;
  display: grid;
  place-items: center;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--paper);
  color: var(--muted);
  text-align: center;
}

.empty-state button,
.empty-state__action {
  min-height: 44px;
  margin-top: 12px;
  padding: 9px 15px;
  border-radius: 8px;
}

.image-fallback {
  position: relative;
  min-height: 180px;
  overflow: hidden;
  display: grid;
  place-content: center;
  gap: 8px;
  border: 1px solid var(--line);
  background: #e7e1d7;
  color: var(--muted);
  text-align: center;
}

.image-fallback img {
  display: none;
}

.image-fallback::before {
  content: "ONEZEN";
  color: var(--gold-dark);
  font-family: var(--font-display);
  font-size: 1.2rem;
  letter-spacing: .18em;
}

.image-fallback::after {
  content: "图片暂不可用";
  font-size: .78rem;
}

.clipboard-proxy {
  position: fixed;
  inset: 0 auto auto -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.skeleton {
  overflow: hidden;
  background: #ded8ce;
  color: transparent;
  animation: skeleton-pulse 1.3s ease-in-out infinite alternate;
}

.catalog-skeleton {
  aspect-ratio: 3 / 4;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}

@keyframes skeleton-pulse {
  from { opacity: .55; }
  to { opacity: .92; }
}

@media (min-width: 700px) {
  .section-heading {
    grid-template-columns: minmax(0, 1fr) minmax(240px, .48fr);
    align-items: end;
  }

  .catalog-toolbar {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .catalog-toolbar .field--search {
    grid-column: span 2;
  }

  .product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .dialog__panel--cart {
    width: min(820px, 100%);
  }
}

@media (min-width: 960px) {
  .catalog-layout {
    display: grid;
    grid-template-columns: 170px minmax(0, 1fr);
    align-items: start;
    gap: 30px;
  }

  .catalog__meta {
    position: static;
    top: auto;
    margin-bottom: 0;
  }

  .category-nav {
    margin-top: 16px;
    padding: 0;
    flex-direction: column;
    align-items: stretch;
    overflow: visible;
  }

  .category-nav button {
    width: 100%;
    justify-content: flex-start;
    border-color: transparent;
    border-bottom-color: var(--line);
    border-radius: 0;
    text-align: left;
    white-space: normal;
  }
}

@media (min-width: 1180px) {
  .catalog-toolbar {
    grid-template-columns: minmax(220px, 1.7fr) repeat(3, minmax(126px, 1fr)) auto auto;
  }

  .catalog-toolbar .field--search {
    grid-column: auto;
  }

  .catalog__meta {
    position: sticky;
    top: 190px;
  }

  .product-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 699px) {
  :root {
    --content: calc(100vw - 32px);
  }

  html {
    scroll-padding-top: 82px;
  }

  .site-header__inner {
    min-height: 66px;
    gap: 12px;
  }

  .brand__annotation {
    display: none;
  }

  .brand__cn {
    font-size: 1rem;
  }

  .brand__en {
    font-size: .56rem;
  }

  .site-nav {
    gap: 5px;
  }

  .site-nav a {
    padding-inline: 6px;
    font-size: .76rem;
  }

  .site-nav a:last-child {
    display: none;
  }

  main > section {
    scroll-margin-top: 82px;
  }

  .hero {
    min-height: 0;
    padding-block: 48px 72px;
    grid-template-columns: minmax(0, 1fr);
    gap: 42px;
  }

  .hero h1 {
    max-width: none;
    margin-top: 16px;
    font-size: clamp(2.55rem, 12.2vw, 4rem);
    line-height: 1.08;
  }

  .hero__intro {
    margin-top: 22px;
  }

  .hero-actions {
    width: 100%;
    margin-top: 28px;
  }

  .hero-actions .button-link {
    flex: 1 1 160px;
  }

  .hero-actions .text-link {
    flex: 1 1 130px;
  }

  .hero-guide {
    margin-top: 34px;
  }

  .hero-visual,
  .hero__visual {
    min-height: 0;
    aspect-ratio: 4 / 4.8;
    border-radius: var(--radius-md) var(--radius-sm) var(--radius-md) var(--radius-sm);
  }

  .hero-visual::before {
    width: 62vw;
  }

  .hero-visual__label {
    right: 14px;
    bottom: 14px;
    left: 14px;
  }

  .fate-quiz {
    padding-block: 70px 88px;
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
  }

  .fate-quiz__copy {
    position: static;
  }

  .fate-quiz__copy h2 {
    max-width: none;
  }

  .fate-steps {
    margin-top: 22px;
  }

  .fate-steps span {
    padding-inline: 6px;
    font-size: .72rem;
  }

  .fate-quiz__start {
    width: 100%;
  }

  .fate-quiz__mosaic {
    min-height: 310px;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 8px;
  }

  .fate-quiz__mosaic > :first-child,
  .fate-quiz__mosaic > :nth-child(3) {
    grid-row: auto;
  }

  .fate-quiz__mosaic > :nth-child(2),
  .fate-quiz__mosaic > :nth-child(3),
  .fate-quiz__mosaic > :nth-child(4) {
    margin: 0;
  }

  .fate-quiz__mosaic > * {
    border-radius: 12px;
  }

  .fate-mosaic-card span {
    font-size: .66rem;
  }

  .fate-panel {
    padding: 16px;
    border-radius: 14px;
  }

  .fate-panel__grid,
  .fate-wishes,
  .fate-result__inner {
    grid-template-columns: minmax(0, 1fr);
  }

  .fate-wish {
    min-height: 50px;
    text-align: center;
  }

  .fate-result__media {
    min-height: 320px;
  }

  .fate-result__body {
    padding: 20px;
  }

  .fate-result__actions button {
    flex: 1 1 150px;
  }

  .featured {
    padding-block: 70px 88px;
  }

  .featured-grid {
    min-height: 356px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .featured-placeholder,
  .featured-card {
    min-height: 0;
    margin: 0;
    border-radius: 10px;
  }

  .featured-placeholder:first-child,
  .featured-card:first-child {
    grid-row: 1 / span 2;
  }

  .featured-placeholder:nth-child(2),
  .featured-card:nth-child(2),
  .featured-placeholder:nth-child(3),
  .featured-card:nth-child(3) {
    margin: 0;
  }

  .featured-card__body {
    padding: 12px;
    grid-template-columns: minmax(0, 1fr);
  }

  .atlas {
    min-height: 0;
    grid-template-columns: minmax(0, 1fr);
    border-radius: var(--radius-md);
  }

  .atlas-copy,
  .atlas__copy {
    padding: 34px 24px 25px;
  }

  .atlas-stage {
    min-height: 340px;
    margin: 0 10px 10px;
    overflow-x: auto;
    overflow-y: hidden;
    grid-template-rows: minmax(320px, 1fr) auto;
    overscroll-behavior-inline: contain;
    border-radius: calc(var(--radius-md) - 5px);
  }

  .atlas-placeholder,
  .atlas-map,
  .atlas-stage__canvas,
  .atlas-nodes {
    width: 560px;
    min-width: 560px;
    min-height: 320px;
  }

  .atlas-stage::before {
    left: 280px;
  }

  .atlas-stage::after {
    right: auto;
    left: 38px;
    width: 484px;
  }

  .atlas-node {
    --size: 72px;
  }

  .atlas-price-controls {
    grid-row: 2;
    width: 560px;
    min-width: 560px;
    flex-wrap: nowrap;
    justify-content: center;
    padding: 10px 12px 14px;
  }

  .atlas-price-controls > * {
    flex: 0 0 auto;
    min-width: 112px;
  }

  .catalog {
    padding-block: 88px 104px;
  }

  .catalog__heading {
    margin-bottom: 26px;
  }

  .catalog-toolbar {
    position: static;
    top: auto;
    padding: 12px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-radius: var(--radius-sm);
  }

  .catalog-toolbar .field--search {
    grid-column: 1 / -1;
  }

  .catalog-toolbar > button {
    width: 100%;
  }

  .catalog-layout {
    margin-top: 22px;
  }

  .catalog__meta {
    margin-bottom: 18px;
  }

  .category-nav {
    width: calc(100vw - 16px);
    margin-left: -8px;
    padding: 3px 8px 7px;
  }

  .category-nav button,
  .filter-chip {
    border-radius: 999px;
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 12px;
  }

  .product-card__body {
    padding: 12px;
    gap: 8px;
  }

  .product-card__heading {
    grid-template-columns: minmax(0, 1fr);
  }

  .product-card__price {
    font-size: .9rem;
  }

  .product-card__actions {
    grid-template-columns: minmax(0, 1fr);
  }

  .product-card__actions .quantity-control,
  .product-card__actions .quantity-stepper,
  .product-card__actions .stepper {
    width: 100%;
    grid-template-columns: 44px minmax(0, 1fr) 44px;
  }

  .service-notes {
    padding-block: 70px 78px;
  }

  .service-notes__grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .service-notes__grid article,
  .service-notes__grid article:first-child,
  .service-notes__grid article:last-child {
    min-height: 0;
    padding: 24px 0 28px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .service-notes__grid article:last-child {
    border-bottom: 0;
  }

  .service-notes__grid article::before {
    margin-bottom: 18px;
  }

  .site-footer__inner {
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    gap: 28px;
  }

  .site-footer__inner > a {
    justify-self: start;
  }

  .dialog {
    padding: 0;
    place-items: end stretch;
  }

  .dialog__panel,
  .dialog__panel--compact,
  .dialog__panel--cart {
    width: 100%;
    max-height: calc(100dvh - 24px);
    border-width: 1px 0 0;
    border-radius: var(--radius-md) var(--radius-md) 0 0;
  }

  .dialog__header {
    min-height: 72px;
  }

  .product-dialog,
  .product-dialog__layout,
  #productDialogBody > .product-detail-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .product-gallery {
    padding: 12px;
  }

  .product-detail,
  .product-dialog__details {
    padding: 26px 18px 34px;
  }

  .cart-item,
  #cartItems > article {
    grid-template-columns: 58px minmax(0, 1fr);
  }

  .cart-item__image,
  .cart-item img {
    width: 58px;
  }

  .cart-item__controls {
    grid-column: 1 / -1;
    justify-content: flex-end;
  }

  .discount-custom {
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
  }

  .discount-custom > label {
    min-height: 32px;
  }

  .field-error {
    padding-top: 2px;
  }

  .clear-cart-confirm {
    align-items: stretch;
    flex-direction: column;
  }

  .clear-cart-confirm > div {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cart-actions {
    grid-template-columns: minmax(0, 1fr);
  }

  .cart-actions > button,
  .cart-actions p {
    grid-column: 1;
  }

  .cart-bar {
    bottom: max(10px, env(safe-area-inset-bottom));
    width: calc(100vw - 20px);
    min-height: 64px;
    padding-left: 14px;
    gap: 10px;
  }

  .cart-bar > div {
    display: grid;
    gap: 0;
  }

  .cart-bar button {
    padding-inline: 14px;
  }
}

@media (max-width: 340px) {
  :root {
    --content: calc(100vw - 24px);
  }

  .site-nav a:first-child {
    display: none;
  }

  .hero-actions,
  .catalog-toolbar {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-actions {
    display: grid;
  }

  .catalog-toolbar .field--search,
  .catalog-toolbar .field,
  .catalog-toolbar > button {
    grid-column: 1;
  }

  .product-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .cart-bar {
    align-items: stretch;
  }
}

@media (hover: hover) and (pointer: fine) {
  .site-nav a:hover,
  .text-link:hover {
    color: var(--gold-dark);
  }

  .button-link:hover,
  .product-card__actions > button:hover,
  .add-to-cart:hover,
  .add-button:hover,
  .fate-quiz__start:hover,
  .fate-submit:hover,
  .fate-result__actions button:first-child:hover {
    background: var(--gold-dark);
    border-color: var(--gold-dark);
    transform: translateY(-1px);
  }

  .featured-card:hover,
  .product-card:hover {
    border-color: var(--line-strong);
    box-shadow: var(--shadow-sm);
    transform: translateY(-3px);
  }

  .featured-card:hover img,
  .product-card:hover .product-card__image,
  .product-card:hover .product-card__media img {
    transform: scale(1.025);
  }

  .fate-mosaic-card:hover img {
    transform: scale(1.035);
  }

  .fate-wish:hover,
  .fate-result__actions button:nth-child(2):hover,
  .fate-result__actions button:nth-child(3):hover {
    border-color: var(--gold);
    color: var(--gold-dark);
  }

  .atlas-node:hover {
    border-color: #c7ad8c;
    transform: translate(-50%, -50%) scale(1.045);
  }

  .category-nav button:not([aria-pressed="true"]):not([aria-current="true"]):hover,
  .catalog-toolbar > button:not([aria-pressed="true"]):hover,
  .load-more:hover {
    border-color: var(--gold);
    color: var(--gold-dark);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation: none !important;
    transition: none !important;
  }
}
