/* ---------- tokens ---------- */
:root {
  --bg: #faf9f5;
  --paper: #ffffff;
  --panel: #f1efe7;
  --ink: #141413;
  --ink-2: #3d3d3a;
  --muted: #73726c;
  --line: #e4e1d6;
  --line-strong: #cdcabd;
  --accent: #d4622b;
  --accent-ink: #a8481a;
  --plush: #dc6a2c;
  --ok: #4a7a47;
  --wait: #a8721a;
  --danger: #b3261e;

  --serif: 'Source Serif 4 Variable', Georgia, 'Times New Roman', serif;
  --sans: 'Inter Tight Variable', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --mono: 'JetBrains Mono Variable', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 1px 2px rgb(20 20 19 / 0.04), 0 24px 60px -24px rgb(20 20 19 / 0.28);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
a:hover { text-decoration-color: currentColor; }
h1, h2, h3, p, ul, ol, figure, fieldset { margin: 0; padding: 0; }
fieldset { border: 0; min-width: 0; }
ul, ol { list-style: none; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 4px; }
.svg-defs { position: absolute; }

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

/* ---------- shared type ---------- */
.eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  font: 500 12px/1 var(--mono);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}
.eyebrow::before { content: ''; width: 24px; height: 1px; background: currentColor; }

.title {
  margin-top: 18px;
  font: 340 clamp(34px, 4vw, 48px)/1.06 var(--serif);
  letter-spacing: -0.022em;
}
.headline em, .title em { font-style: italic; color: var(--accent); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 0 22px;
  border: 0;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  font-weight: 500;
  font-size: 15px;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color 0.15s, transform 0.15s;
}
.btn:hover { background: #2e2e2b; }
.btn:active { transform: scale(0.98); }
.btn[disabled] { opacity: 0.55; cursor: progress; }
.btn .arrow { transition: transform 0.15s; }
.btn:hover .arrow { transform: translateX(3px); }
.btn--wide { width: 100%; min-height: 52px; font-size: 16px; }
.btn-sep { opacity: 0.5; }

.link {
  padding: 0;
  border: 0;
  background: none;
  font: 500 13px/1.4 var(--mono);
  color: var(--ink-2);
  text-decoration: underline;
  text-decoration-color: var(--line-strong);
  text-underline-offset: 3px;
}
.link:hover { text-decoration-color: currentColor; }

.hint { margin-top: 12px; font-size: 13px; line-height: 1.45; color: var(--muted); }
.notice { margin-top: 32px; padding: 16px 20px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); }

/* ---------- topbar ---------- */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 20px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font: 400 17px/1.5 var(--serif);
  letter-spacing: -0.01em;
  text-decoration: none;
}
.brand b { font-weight: 500; }
.brand-tld { color: var(--muted); }
.brand-logo {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgb(20 20 19 / 0.08), 0 4px 10px -4px rgb(20 20 19 / 0.3);
}
.nav-meta {
  display: flex;
  align-items: center;
  gap: 22px;
  font: 400 12px/1 var(--mono);
  color: var(--ink-2);
}
.nav-meta a { text-decoration: none; }
.nav-meta a:hover { text-decoration: underline; }
.cart-open {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: transparent;
  font: inherit;
  transition: border-color 0.15s, background-color 0.15s;
}
.cart-open:hover { border-color: var(--ink); background: var(--paper); }
.cart-count {
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  font-size: 11px;
  line-height: 18px;
  text-align: center;
}

/* ---------- hero ---------- */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(32px, 6vw, 96px);
  min-height: calc(100svh - 74px - 56px);
  padding-block: 24px 72px;
}
.copy { padding-left: clamp(0px, 2.6vw, 32px); }
.headline {
  margin-top: 26px;
  font: 340 clamp(44px, 5.4vw, 72px)/1.02 var(--serif);
  letter-spacing: -0.025em;
  text-wrap: balance;
}
.sub { margin-top: 26px; max-width: 34em; font-size: 19px; line-height: 1.45; text-wrap: pretty; }
.sub--muted { margin-top: 14px; font-size: 17px; color: var(--ink-2); }

.cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 480px;
  margin-top: 34px;
  padding: 6px 6px 6px 24px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgb(255 255 255 / 0.5);
}
.cta-hint { color: var(--muted); font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fineprint { margin-top: 20px; font: 400 12px/1.6 var(--mono); color: var(--muted); }
.fineprint a { color: var(--ink-2); }

.photo { position: relative; }
.photo-frame {
  position: relative;
  aspect-ratio: 1 / 1.04;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel);
  box-shadow: 0 0 0 1px rgb(20 20 19 / 0.08), var(--shadow);
}
.photo-frame img { width: 100%; height: 100%; object-fit: cover; object-position: 44% 50%; }
.chip {
  position: absolute;
  padding: 7px 11px;
  border-radius: 999px;
  background: rgb(250 249 245 / 0.92);
  font: 400 11px/1 var(--mono);
  color: var(--ink-2);
  backdrop-filter: blur(6px);
}
.chip--tl { top: 16px; left: 16px; }
.chip--br { right: 16px; bottom: 16px; }
.note {
  position: absolute;
  left: -22px;
  bottom: -22px;
  display: grid;
  gap: 8px;
  padding: 14px 16px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  box-shadow: 0 12px 28px -14px rgb(20 20 19 / 0.35);
  transform: rotate(-3deg);
}
.note-title { font: italic 400 15px/1.2 var(--serif); }
.note-meta { font: 400 10px/1 var(--mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }

/* ---------- sections ---------- */
.section { padding-block: clamp(64px, 9vw, 112px); border-top: 1px solid var(--line); }
.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 24px;
}

.tabs {
  display: inline-flex;
  padding: 4px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgb(255 255 255 / 0.5);
}
.tab {
  min-height: 38px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-2);
  transition: background-color 0.15s, color 0.15s;
}
.tab[aria-selected='true'] { background: var(--ink); color: var(--bg); }

/* ---------- configurator ---------- */
.panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.92fr);
  align-items: start;
  gap: clamp(28px, 5vw, 72px);
  margin-top: 44px;
}
.stage-col { position: sticky; top: 24px; }
.stage {
  --plush: #dc6a2c;
  border-radius: var(--radius);
  background:
    radial-gradient(120% 90% at 50% 100%, rgb(255 255 255 / 0.7), transparent 60%),
    var(--panel);
  box-shadow: inset 0 0 0 1px rgb(20 20 19 / 0.05);
  overflow: hidden;
}
.stage svg { width: 100%; height: auto; }
.stage-floor { stroke: var(--line-strong); stroke-width: 1; stroke-dasharray: 2 5; }
.stage-shadow { fill: rgb(20 20 19 / 0.1); transition: transform 0.45s cubic-bezier(0.2, 0.8, 0.2, 1); }
.stage-plush, .stage-mug { transition: transform 0.45s cubic-bezier(0.2, 0.8, 0.2, 1); }
.mascot-fill { fill: var(--plush); }
.mascot-eye { fill: #1c1b19; }
.mug-line { fill: none; stroke: var(--muted); stroke-width: 2; stroke-linejoin: round; }
.stage[data-finish='fluffy'] .plush-body, .plush-furry { filter: url(#fur); }
.plush--mustard { --plush: #d2a12c; }
.plush--sky { --plush: #5f84ad; }
.plush--sage { --plush: #7f9a68; }
.stage-caption { margin-top: 14px; font: 400 12px/1.5 var(--mono); color: var(--muted); text-align: center; }

.config { display: grid; gap: 30px; min-width: 0; }
.config form { display: grid; gap: 18px; }
.group-title {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 12px;
  padding: 0;
  font-size: 15px;
  font-weight: 600;
}
.group-num { font: 400 12px/1 var(--mono); color: var(--muted); }

.sizes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.finishes, .choices { display: grid; gap: 10px; }

.option { position: relative; display: block; cursor: pointer; }
.option input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.option-card {
  display: grid;
  gap: 4px;
  height: 100%;
  padding: 14px 16px;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  background: rgb(255 255 255 / 0.45);
  transition: border-color 0.15s, background-color 0.15s, box-shadow 0.15s;
}
.option:hover .option-card { border-color: var(--muted); }
.option input:checked + .option-card {
  border-color: var(--ink);
  background: var(--paper);
  box-shadow: inset 0 0 0 1px var(--ink);
}
.option input:focus-visible + .option-card { outline: 2px solid var(--ink); outline-offset: 3px; }
.option input:disabled + .option-card { opacity: 0.45; cursor: not-allowed; }

.option-name { font-weight: 600; font-size: 15px; }
.option-meta { font: 400 12px/1.4 var(--mono); color: var(--muted); }
.option-note { font-size: 14px; line-height: 1.4; color: var(--ink-2); }
.option-price { margin-top: 8px; font: 400 22px/1 var(--serif); letter-spacing: -0.01em; }
.option-card--row { grid-template-columns: 1fr auto; align-items: start; column-gap: 16px; }
.option-card--row .option-note { grid-column: 1; }
.option-delta { grid-row: 1 / span 2; grid-column: 2; font: 400 12px/1.6 var(--mono); color: var(--muted); white-space: nowrap; }

.avail { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 10px; font-size: 14px; }
.avail-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--wait); box-shadow: 0 0 0 4px rgb(168 114 26 / 0.16); }
.avail-label { font-weight: 600; }
.avail-lead { color: var(--muted); }
.avail[data-status='in_stock'] .avail-dot { background: var(--ok); box-shadow: 0 0 0 4px rgb(74 122 71 / 0.16); }
.avail[data-status='unavailable'] .avail-dot { background: var(--line-strong); box-shadow: none; }

.buy { display: grid; grid-template-columns: auto 1fr; gap: 10px; }
.stepper {
  display: inline-grid;
  grid-template-columns: 40px minmax(28px, auto) 40px;
  align-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgb(255 255 255 / 0.45);
}
.stepper button { height: 100%; min-height: 44px; border: 0; border-radius: 999px; background: none; font-size: 18px; color: var(--ink-2); }
.stepper button:hover { color: var(--ink); background: rgb(20 20 19 / 0.05); }
.stepper button:disabled { opacity: 0.3; cursor: default; background: none; }
.stepper output { text-align: center; font: 500 14px/1 var(--mono); }
.stepper--sm { grid-template-columns: 32px minmax(22px, auto) 32px; }
.stepper--sm button { min-height: 32px; font-size: 15px; }
.config .hint { margin-top: -14px; }
.config form .hint { margin-top: -6px; }

/* ---------- forms ---------- */
.lead { font-size: 17px; line-height: 1.5; text-wrap: pretty; }
.custom-terms { font: 400 12px/1.6 var(--mono); color: var(--muted); margin-top: -8px; }
.field { display: grid; gap: 7px; min-width: 0; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.field-label { font-size: 13px; font-weight: 600; padding: 0; }
.field-label i { font-style: normal; font-weight: 400; color: var(--muted); }
.field input, .field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--paper);
  font-size: 16px;
  line-height: 1.4;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.field textarea { resize: vertical; min-height: 60px; }
.field input::placeholder, .field textarea::placeholder { color: #a5a399; }
.field input:focus, .field textarea:focus { outline: 0; border-color: var(--ink); box-shadow: 0 0 0 3px rgb(20 20 19 / 0.08); }
.was-validated .field :invalid, .was-validated .check input:invalid { border-color: var(--danger); outline-color: var(--danger); }
.contact-slot { display: grid; gap: 18px; }
.group--plain { display: grid; gap: 7px; }

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.check { display: grid; grid-template-columns: auto 1fr; gap: 10px; align-items: start; font-size: 13px; line-height: 1.45; color: var(--ink-2); cursor: pointer; }
.check input { width: 18px; height: 18px; margin: 1px 0 0; accent-color: var(--ink); }

.upload {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  min-height: 40px;
  padding: 0 16px;
  border: 1px dashed var(--line-strong);
  border-radius: 999px;
  font-size: 14px;
  cursor: pointer;
  transition: border-color 0.15s, background-color 0.15s;
}
.upload:hover { border-color: var(--ink); background: var(--paper); }
.upload input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.upload:focus-within { outline: 2px solid var(--ink); outline-offset: 3px; }
.thumbs { display: flex; flex-wrap: wrap; gap: 10px; }
.thumbs:empty { display: none; }
.thumb { position: relative; width: 72px; height: 72px; border-radius: 10px; overflow: hidden; box-shadow: 0 0 0 1px var(--line-strong); }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb button {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 22px;
  height: 22px;
  border: 0;
  border-radius: 50%;
  background: rgb(20 20 19 / 0.75);
  color: #fff;
  font-size: 14px;
  line-height: 1;
}

.form-error {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: #fbeceb;
  color: var(--danger);
  font-size: 14px;
  line-height: 1.45;
  white-space: pre-line;
}

.done { display: grid; gap: 14px; justify-items: start; padding: 28px; border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--paper); }
.done:focus { outline: 0; }
.done-title { font: 340 30px/1.1 var(--serif); letter-spacing: -0.02em; }
.code { font: 600 15px/1 var(--mono); letter-spacing: 0.04em; padding: 3px 8px; border-radius: 6px; background: var(--panel); white-space: nowrap; }

/* ---------- steps ---------- */
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; margin-top: 48px; }
.steps li { padding-top: 20px; border-top: 1px solid var(--ink); }
.step-num { font: 400 12px/1 var(--mono); color: var(--accent-ink); }
.steps h3 { margin-top: 14px; font: 400 24px/1.15 var(--serif); letter-spacing: -0.015em; }
.steps p { margin-top: 10px; font-size: 15px; line-height: 1.5; color: var(--ink-2); }

/* ---------- faq ---------- */
.faq { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.faq-list { border-bottom: 1px solid var(--line-strong); }
.faq details { border-top: 1px solid var(--line-strong); }
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 20px 0;
  font: 400 21px/1.25 var(--serif);
  letter-spacing: -0.01em;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; flex: none; font: 300 22px/1 var(--mono); color: var(--muted); transition: transform 0.2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { max-width: 38em; padding: 0 40px 22px 0; color: var(--ink-2); line-height: 1.55; text-wrap: pretty; }

/* ---------- footer ---------- */
.footer {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px 24px;
  padding-block: 22px 28px;
  border-top: 1px solid var(--line-strong);
  font: 400 12px/1.6 var(--mono);
  color: var(--muted);
}
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 20px; }
.footer a { color: var(--ink-2); }

/* ---------- drawer ---------- */
.drawer {
  width: min(480px, 100vw);
  max-width: none;
  height: 100dvh;
  max-height: none;
  margin: 0 0 0 auto;
  padding: 0;
  border: 0;
  background: var(--bg);
  color: var(--ink);
  box-shadow: -24px 0 60px -30px rgb(20 20 19 / 0.4);
}
.drawer[open] { display: flex; flex-direction: column; animation: drawer-in 0.28s cubic-bezier(0.2, 0.8, 0.2, 1); }
.drawer::backdrop { background: rgb(20 20 19 / 0.38); animation: fade-in 0.28s; }
@keyframes drawer-in { from { transform: translateX(40px); opacity: 0; } }
@keyframes fade-in { from { opacity: 0; } }
.drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px 14px; }
.drawer-title { font: 340 30px/1.1 var(--serif); letter-spacing: -0.02em; }
.icon-btn { width: 40px; height: 40px; border: 0; border-radius: 50%; background: none; font-size: 26px; line-height: 1; color: var(--ink-2); }
.icon-btn:hover { background: rgb(20 20 19 / 0.06); }
.drawer-body { flex: 1; display: flex; flex-direction: column; gap: 18px; min-height: 0; padding: 6px 24px 24px; overflow-y: auto; overscroll-behavior: contain; }
.drawer-body form { display: grid; gap: 18px; }
.drawer-foot { display: grid; gap: 14px; margin-top: auto; padding-top: 18px; border-top: 1px solid var(--line-strong); }
.empty { padding: 28px 0; color: var(--muted); }
.back { align-self: flex-start; }

.lines { display: grid; }
.line { display: grid; grid-template-columns: 64px 1fr auto; gap: 14px; align-items: center; padding: 16px 0; border-top: 1px solid var(--line); }
.line:first-child { border-top: 0; }
.line-pic { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 12px; background: var(--panel); }
.line-pic svg { width: 46px; height: auto; }
.line-name { font-weight: 600; font-size: 15px; }
.line-meta { margin-top: 2px; font-size: 13px; color: var(--muted); }
.line-tag { display: inline-block; margin-top: 6px; padding: 3px 8px; border-radius: 999px; font: 500 10px/1.3 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; }
.line-tag[data-status='in_stock'] { background: rgb(74 122 71 / 0.13); color: #35602f; }
.line-tag[data-status='preorder'] { background: rgb(168 114 26 / 0.15); color: #7c5310; }
.line-side { display: grid; justify-items: end; gap: 8px; }
.line-sum { font: 400 18px/1 var(--serif); white-space: nowrap; }
.line-remove { font-size: 11px; }
.preorder-note { font-size: 13px; line-height: 1.45; color: var(--ink-2); }
.total { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; font-size: 14px; color: var(--ink-2); }
.total b { font: 400 26px/1 var(--serif); color: var(--ink); white-space: nowrap; }
.drawer .hint { margin-top: -6px; }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; min-height: 0; padding-block: 24px 64px; gap: 44px; }
  .copy { padding-left: 0; }
  .photo { max-width: 560px; }
  .note { left: -8px; bottom: -18px; }
  .panel { grid-template-columns: 1fr; }
  .stage-col { position: static; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .faq { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .wrap { width: calc(100% - 32px); }
  .hide-sm { display: none; }
  .sub { font-size: 17px; }
  .sub--muted { font-size: 16px; }
  .cta { padding-left: 18px; }
  .cta-hint { font-size: 13px; }
  .tabs { width: 100%; }
  .tab { flex: 1; padding: 0 10px; font-size: 13px; }
  .sizes { gap: 8px; }
  .sizes .option-card { padding: 12px 10px; }
  .option-price { font-size: 19px; }
  .field-row { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; gap: 24px; }
  .faq summary { font-size: 19px; }
  .faq details p { padding-right: 0; }
  .drawer-head, .drawer-body { padding-inline: 18px; }
}

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