:root {
  --font-sans: "Avenir Next", "Segoe UI Variable Text", "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --font-serif: "Iowan Old Style", "Palatino Linotype", "Songti SC",
    "Noto Serif CJK SC", "Source Han Serif SC", "STSong", serif;
  --paper: #f4eee4;
  --surface: #fffdf8;
  --surface-soft: #faf5ec;
  --chat: #f7f1e7;
  --ink: #1e2722;
  --ink-soft: #4f5952;
  --muted: #878b80;
  --faint: #b2b1a4;
  --line: rgba(30, 39, 34, 0.09);
  --line-strong: rgba(30, 39, 34, 0.15);
  --pine: #173a33;
  --pine-deep: #0d2b25;
  --pine-mid: #2a5b4d;
  --coral: #d96b4c;
  --coral-soft: #f8e4db;
  --green: #4f9b75;
  --amber: #c58a40;
  --danger: #b94f3d;
  --shadow: 0 22px 60px rgba(20, 38, 30, 0.12);
  color-scheme: light;
}

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

html {
  min-height: 100%;
}

body {
  min-height: 100%;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 10% 4%, rgba(217, 107, 76, 0.08), transparent 28%),
    radial-gradient(circle at 92% 24%, rgba(23, 58, 51, 0.07), transparent 30%),
    linear-gradient(145deg, #f7f1e7 0%, #f1e8da 100%);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

button,
input,
textarea {
  font: inherit;
  color: inherit;
}

button {
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

h1,
h2,
h3,
p {
  margin: 0;
}

svg {
  display: block;
  width: 20px;
  height: 20px;
}

[hidden] {
  display: none !important;
}

.svg-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

:focus-visible {
  outline: 2px solid var(--coral);
  outline-offset: 3px;
}

.sr-only {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.noscript-note {
  position: fixed;
  right: 16px;
  bottom: 16px;
  left: 16px;
  z-index: 300;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--pine);
  color: #f8f1e5;
  font-size: 12px;
  text-align: center;
}

/* Header */

.shop-head {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 76px;
  padding: 12px clamp(18px, 4vw, 52px);
  border-bottom: 1px solid rgba(30, 39, 34, 0.08);
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  backdrop-filter: blur(18px);
}

.shop-brand {
  display: flex;
  align-items: center;
  gap: 11px;
  flex: none;
}

.shop-mark {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 13px;
  background: var(--pine);
  color: #f8f1e5;
  box-shadow: 0 6px 16px rgba(23, 58, 51, 0.18);
}

.shop-mark svg {
  width: 19px;
  height: 19px;
}

.shop-brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.shop-brand-copy strong {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.05em;
}

.shop-brand-copy small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 7px;
  font-weight: 600;
  letter-spacing: 0.27em;
}

.shop-actions {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
}

.head-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 32px;
  padding: 0 9px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 9px;
  white-space: nowrap;
  transition: background 150ms ease, color 150ms ease;
}

.head-link:hover {
  background: var(--chat);
  color: var(--ink);
}

.head-link svg {
  width: 13px;
  height: 13px;
}

.account-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: 116px;
  height: 32px;
  padding: 0 10px;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink-soft);
  font-size: 8.5px;
  font-weight: 600;
  white-space: nowrap;
}

.account-pill svg {
  width: 11px;
  height: 11px;
  flex: none;
  color: var(--pine-mid);
}

.account-pill span {
  overflow: hidden;
  text-overflow: ellipsis;
}

.cart-button {
  position: relative;
  display: grid;
  place-items: center;
  width: 39px;
  height: 39px;
  flex: none;
  border-radius: 50%;
  background: var(--pine);
  color: #f8f1e5;
  box-shadow: 0 6px 16px rgba(23, 58, 51, 0.18);
  transition: transform 150ms ease, background 150ms ease;
}

.cart-button:hover {
  background: var(--pine-mid);
  transform: translateY(-1px);
}

.cart-button svg {
  width: 17px;
  height: 17px;
}

.cart-count {
  position: absolute;
  top: -3px;
  right: -3px;
  display: grid;
  place-items: center;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border: 2px solid var(--surface);
  border-radius: 999px;
  background: var(--coral);
  color: #fffaf4;
  font-size: 7.5px;
  font-weight: 700;
  line-height: 1;
}

/* Layout */

.shop-main {
  width: 100%;
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 48px);
}

.shop-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  align-items: center;
  gap: 36px;
  min-height: 330px;
  padding: 30px 0 24px;
  overflow: hidden;
}

.hero-copy {
  position: relative;
  z-index: 2;
  max-width: 520px;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--pine-mid);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.hero-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--coral);
}

.hero-copy h1 {
  font-family: var(--font-serif);
  font-size: clamp(44px, 6.3vw, 70px);
  font-weight: 500;
  line-height: 1.22;
  letter-spacing: 0.01em;
}

.hero-copy h1 em {
  color: var(--coral);
  font-style: normal;
}

.hero-copy > p:last-child {
  max-width: 420px;
  margin-top: 16px;
  color: var(--ink-soft);
  font-size: 11.5px;
  line-height: 1.9;
}

.hero-art {
  position: relative;
  width: 300px;
  height: 260px;
  justify-self: end;
}

.hero-ring {
  position: absolute;
  border: 1px solid rgba(23, 58, 51, 0.14);
  border-radius: 50%;
}

.ring-a {
  inset: 10px 20px 30px 10px;
}

.ring-b {
  inset: 44px 54px 62px 44px;
  border-color: rgba(217, 107, 76, 0.2);
}

.hero-card {
  position: absolute;
  top: 50%;
  left: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 150px;
  height: 178px;
  border-radius: 26px 26px 8px 26px;
  background: linear-gradient(150deg, var(--pine-mid), var(--pine) 68%, var(--pine-deep));
  color: #f8f1e5;
  box-shadow: 0 26px 50px rgba(23, 58, 51, 0.22);
  transform: translate(-50%, -50%) rotate(-7deg);
}

.hero-card svg {
  width: 50px;
  height: 50px;
  opacity: 0.9;
}

.hero-card i {
  padding: 3px 8px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  font-size: 7px;
  font-style: normal;
  letter-spacing: 0.12em;
}

/* Products */

.shop-content {
  padding: 12px 0 50px;
}

.shop-toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  padding: 20px 0 18px;
  border-top: 1px solid var(--line);
}

.section-kicker {
  color: var(--coral);
  font-size: 7.5px;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.shop-toolbar h2 {
  margin-top: 3px;
  font-family: var(--font-serif);
  font-size: 27px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.shop-toolbar h2 span {
  color: var(--faint);
  font-family: var(--font-sans);
  font-size: 10px;
  font-weight: 500;
}

.shop-search {
  display: flex;
  align-items: center;
  gap: 6px;
  width: min(220px, 42vw);
  height: 37px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
}

.shop-search svg {
  width: 13px;
  height: 13px;
  flex: none;
  color: var(--faint);
}

.shop-search input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: 10px;
}

.shop-search input::placeholder {
  color: var(--faint);
}

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

body.sheet-open {
  overflow: hidden;
}

.product-card {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
  box-shadow: 0 8px 24px rgba(28, 45, 36, 0.05);
  transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease;
}

.product-card:hover {
  border-color: rgba(23, 58, 51, 0.18);
  box-shadow: 0 18px 36px rgba(28, 45, 36, 0.1);
  transform: translateY(-3px);
}

.product-open {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  text-align: left;
}

.product-media {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background:
    radial-gradient(circle at 32% 24%, rgba(217, 107, 76, 0.14), transparent 34%),
    linear-gradient(145deg, #f2e8d8, #e7dccb);
}

.product-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 380ms cubic-bezier(0.22, 0.8, 0.3, 1);
}

.product-card:hover .product-media img {
  transform: scale(1.035);
}

.product-placeholder {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  color: rgba(23, 58, 51, 0.28);
}

.product-placeholder svg {
  width: 42px;
  height: 42px;
}

.product-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 3px 7px;
  border-radius: 999px;
  background: rgba(255, 253, 248, 0.88);
  color: var(--coral);
  font-size: 7px;
  font-weight: 700;
  letter-spacing: 0.08em;
  backdrop-filter: blur(4px);
}

.product-tag.is-sold-out {
  color: var(--muted);
}

.product-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 12px 48px 14px 13px;
}

.product-name {
  overflow: hidden;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.55;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-desc {
  overflow: hidden;
  margin-top: 2px;
  color: var(--faint);
  font-size: 8.5px;
  line-height: 1.6;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-bottom {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px;
  margin-top: 11px;
}

.product-price {
  color: var(--coral);
  font-family: var(--font-serif);
  font-size: 19px;
  font-weight: 600;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.product-price small {
  margin-right: 1px;
  font-family: var(--font-sans);
  font-size: 9px;
  font-weight: 600;
}

.product-original {
  margin-left: 4px;
  color: var(--faint);
  font-family: var(--font-sans);
  font-size: 8px;
  font-weight: 400;
  text-decoration: line-through;
}

.product-add {
  position: absolute;
  right: 11px;
  bottom: 12px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 31px;
  height: 31px;
  flex: none;
  border-radius: 50%;
  background: var(--pine);
  color: #f8f1e5;
  transition: background 150ms ease, transform 150ms ease;
}

.product-add:hover:not(:disabled) {
  background: var(--coral);
  transform: scale(1.05);
}

.product-add:disabled {
  background: #e5e0d6;
  color: #a6a497;
  cursor: not-allowed;
}

.product-add svg {
  width: 14px;
  height: 14px;
}

.shop-empty,
.shop-loading {
  padding: 64px 20px;
  text-align: center;
}

.shop-empty[hidden],
.shop-loading[hidden] {
  display: none;
}

.empty-icon {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  margin: 0 auto 15px;
  border-radius: 22px;
  background: var(--surface);
  color: var(--faint);
  box-shadow: var(--shadow);
}

.empty-icon svg {
  width: 27px;
  height: 27px;
}

.shop-empty h3 {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 500;
}

.shop-empty p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 10px;
}

.shop-empty a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 16px;
  color: var(--coral);
  font-size: 10px;
}

.shop-empty a svg {
  width: 12px;
  height: 12px;
}

.shop-loading span {
  display: block;
  width: 28px;
  height: 28px;
  margin: 0 auto 12px;
  border: 2px solid var(--line-strong);
  border-top-color: var(--coral);
  border-radius: 50%;
  animation: spin 800ms linear infinite;
}

.shop-loading p {
  color: var(--faint);
  font-size: 9px;
}

.shop-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  max-width: 1160px;
  margin: 0 auto;
  padding: 20px clamp(16px, 4vw, 48px) 30px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: 8px;
  letter-spacing: 0.04em;
}

.shop-foot a {
  color: var(--muted);
}

/* Sheets */

.sheet {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.sheet-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(12, 24, 19, 0.56);
  backdrop-filter: blur(5px);
  animation: fade-in 160ms ease both;
}

.sheet-card {
  position: relative;
  z-index: 1;
  width: min(100%, 720px);
  max-height: min(90dvh, 760px);
  padding: 24px;
  overflow-y: auto;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--surface);
  box-shadow: 0 36px 100px rgba(10, 24, 18, 0.35);
  animation: pop-in 190ms cubic-bezier(0.22, 0.8, 0.3, 1) both;
}

.sheet-close {
  position: absolute;
  top: 13px;
  right: 13px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 253, 248, 0.8);
  color: var(--muted);
  transition: background 150ms ease, color 150ms ease;
}

.sheet-close:hover {
  background: var(--chat);
  color: var(--ink);
}

.sheet-close svg {
  width: 14px;
  height: 14px;
}

.sheet-head {
  padding-right: 34px;
}

.sheet-head h2 {
  margin-top: 3px;
  font-family: var(--font-serif);
  font-size: 27px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.sheet-head > p:last-child {
  max-width: 470px;
  margin-top: 7px;
  color: var(--muted);
  font-size: 9.5px;
  line-height: 1.7;
}

.product-sheet-card {
  width: min(100%, 820px);
}

.product-detail {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 26px;
  align-items: center;
}

.detail-image {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 16px;
  background: linear-gradient(145deg, #f2e8d8, #e7dccb);
}

.detail-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-image .product-placeholder svg {
  width: 60px;
  height: 60px;
}

.detail-copy {
  min-width: 0;
}

.detail-copy h2 {
  margin-top: 4px;
  font-family: var(--font-serif);
  font-size: 30px;
  font-weight: 500;
  line-height: 1.35;
}

.detail-price {
  margin-top: 12px;
  color: var(--coral);
  font-family: var(--font-serif);
  font-size: 30px;
  font-weight: 600;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.detail-price small {
  font-family: var(--font-sans);
  font-size: 12px;
}

.detail-price del {
  margin-left: 8px;
  color: var(--faint);
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 400;
}

.detail-stock {
  margin-top: 7px;
  color: var(--muted);
  font-size: 9px;
}

.detail-description {
  max-height: 160px;
  margin-top: 16px;
  overflow-y: auto;
  color: var(--ink-soft);
  font-size: 10.5px;
  line-height: 1.9;
  white-space: pre-wrap;
}

.detail-buy {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 20px;
}

.qty-control {
  display: flex;
  align-items: center;
  height: 39px;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
}

.qty-control button {
  display: grid;
  place-items: center;
  width: 33px;
  height: 100%;
  color: var(--muted);
}

.qty-control button:hover {
  background: var(--chat);
  color: var(--ink);
}

.qty-control button svg {
  width: 11px;
  height: 11px;
}

.qty-control span {
  min-width: 25px;
  color: var(--ink);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
  text-align: center;
}

.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: 40px;
  padding: 0 18px;
  border-radius: 999px;
  background: var(--pine);
  color: #f8f1e5;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.03em;
  box-shadow: 0 6px 16px rgba(23, 58, 51, 0.16);
  transition: background 150ms ease, transform 150ms ease, opacity 150ms ease;
}

.primary-button:hover:not(:disabled) {
  background: var(--pine-mid);
  transform: translateY(-1px);
}

.primary-button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  box-shadow: none;
}

.detail-add {
  flex: 1;
}

/* Cart */

.cart-sheet-card {
  width: min(100%, 520px);
}

.cart-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 340px;
  margin-top: 18px;
  overflow-y: auto;
}

.cart-item {
  display: flex;
  gap: 10px;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: var(--surface-soft);
}

.cart-thumb {
  width: 58px;
  height: 58px;
  flex: none;
  overflow: hidden;
  border-radius: 9px;
  background: #ede4d6;
}

.cart-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cart-thumb .product-placeholder svg {
  width: 22px;
  height: 22px;
}

.cart-item-copy {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
}

.cart-item-name {
  overflow: hidden;
  font-size: 10.5px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cart-item-price {
  margin-top: 2px;
  color: var(--coral);
  font-family: var(--font-serif);
  font-size: 14px;
  font-weight: 600;
}

.cart-item-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
}

.cart-qty {
  display: flex;
  align-items: center;
  height: 25px;
  border: 1px solid var(--line);
  border-radius: 999px;
}

.cart-qty button {
  display: grid;
  place-items: center;
  width: 25px;
  height: 100%;
  color: var(--muted);
}

.cart-qty button:hover {
  color: var(--ink);
}

.cart-qty button svg {
  width: 9px;
  height: 9px;
}

.cart-qty span {
  min-width: 18px;
  font-size: 8.5px;
  text-align: center;
}

.cart-remove {
  display: grid;
  place-items: center;
  width: 25px;
  height: 25px;
  border-radius: 50%;
  color: var(--faint);
}

.cart-remove:hover {
  background: var(--coral-soft);
  color: var(--coral);
}

.cart-remove svg {
  width: 12px;
  height: 12px;
}

.cart-summary {
  margin-top: 18px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
}

.cart-summary > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  font-size: 10px;
}

.cart-summary strong {
  color: var(--coral);
  font-family: var(--font-serif);
  font-size: 26px;
  font-weight: 600;
}

.cart-summary p {
  margin-top: 3px;
  color: var(--faint);
  font-size: 8px;
}

.cart-summary .primary-button {
  width: 100%;
  margin-top: 13px;
}

.cart-empty,
.orders-empty {
  padding: 42px 16px;
  text-align: center;
}

.cart-empty > span,
.orders-empty > span {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  margin: 0 auto 10px;
  border-radius: 18px;
  background: var(--surface-soft);
  color: var(--faint);
}

.cart-empty > span svg,
.orders-empty > span svg {
  width: 23px;
  height: 23px;
}

.cart-empty p,
.orders-empty p {
  color: var(--muted);
  font-size: 10px;
}

.text-button {
  padding: 0;
  color: var(--coral);
  font-size: 10px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.cart-empty .text-button {
  margin-top: 10px;
}

/* Checkout */

.checkout-card {
  width: min(100%, 470px);
}

.checkout-form {
  display: flex;
  flex-direction: column;
  margin-top: 18px;
}

.checkout-form label {
  margin: 8px 0 4px;
  color: var(--ink-soft);
  font-size: 8.5px;
  font-weight: 600;
}

.checkout-form label span {
  color: var(--faint);
  font-weight: 400;
}

.checkout-form input,
.checkout-form textarea {
  width: 100%;
  padding: 9px 11px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  outline: 0;
  background: var(--surface-soft);
  font-size: 11px;
  line-height: 1.6;
  resize: vertical;
  transition: border-color 150ms ease, box-shadow 150ms ease, background 150ms ease;
}

.checkout-form input {
  height: 39px;
}

.checkout-form input:focus,
.checkout-form textarea:focus {
  border-color: color-mix(in srgb, var(--pine) 40%, transparent);
  background: var(--surface);
  box-shadow: 0 0 0 3px rgba(23, 58, 51, 0.05);
}

.checkout-form input::placeholder,
.checkout-form textarea::placeholder {
  color: var(--faint);
}

.checkout-status {
  min-height: 16px;
  margin-top: 6px;
  color: var(--danger);
  font-size: 8.5px;
}

.checkout-form .primary-button {
  width: 100%;
  margin-top: 6px;
}

/* Orders */

.orders-card {
  width: min(100%, 580px);
}

.orders-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 480px;
  margin-top: 18px;
  overflow-y: auto;
}

.order-card {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface-soft);
}

.order-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  padding-bottom: 9px;
  border-bottom: 1px dashed var(--line);
}

.order-no {
  color: var(--ink-soft);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.order-time {
  margin-top: 2px;
  color: var(--faint);
  font-size: 7.5px;
}

.order-status {
  flex: none;
  padding: 2px 7px;
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 7.5px;
  font-weight: 600;
}

.order-status.is-pending {
  background: #fbf0d9;
  color: #a86d1e;
}

.order-status.is-confirmed,
.order-status.is-shipped {
  background: var(--coral-soft);
  color: #a34d35;
}

.order-status.is-completed {
  background: #e5f1e9;
  color: #347456;
}

.order-status.is-cancelled {
  background: #eee;
  color: var(--muted);
}

.order-items {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-top: 9px;
}

.order-item {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-soft);
  font-size: 9px;
}

.order-thumb {
  width: 34px;
  height: 34px;
  flex: none;
  overflow: hidden;
  border-radius: 6px;
  background: #e9dfd0;
}

.order-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.order-item-copy {
  display: flex;
  flex: 1;
  min-width: 0;
  flex-direction: column;
}

.order-item-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.order-item-meta {
  color: var(--faint);
  font-size: 7.5px;
}

.order-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 10px;
  padding-top: 9px;
  border-top: 1px solid var(--line);
}

.order-contact {
  overflow: hidden;
  color: var(--faint);
  font-size: 7.5px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.order-total {
  flex: none;
  color: var(--coral);
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 600;
}

/* Success */

.success-sheet {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(12, 24, 19, 0.62);
  backdrop-filter: blur(7px);
}

.success-card {
  width: min(100%, 360px);
  padding: 30px 24px;
  border-radius: 24px;
  background: var(--surface);
  text-align: center;
  box-shadow: 0 36px 100px rgba(10, 24, 18, 0.4);
  animation: pop-in 190ms ease both;
}

.success-icon {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: var(--pine);
  color: #f8f1e5;
}

.success-icon svg {
  width: 24px;
  height: 24px;
}

.success-card h2 {
  margin-top: 5px;
  font-family: var(--font-serif);
  font-size: 28px;
  font-weight: 500;
}

.success-card > p:nth-of-type(2) {
  margin-top: 6px;
  color: var(--muted);
  font-size: 9.5px;
}

.success-number {
  margin: 16px 0;
  padding: 9px;
  border: 1px dashed var(--line-strong);
  border-radius: 9px;
  color: var(--ink-soft);
  font-size: 9.5px;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.06em;
}

.success-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

/* Toast */

.toast {
  position: fixed;
  right: 20px;
  bottom: max(20px, env(safe-area-inset-bottom));
  left: 20px;
  z-index: 400;
  width: fit-content;
  max-width: calc(100vw - 40px);
  margin: 0 auto;
  padding: 9px 15px;
  border-radius: 999px;
  background: var(--pine);
  color: #f8f1e5;
  font-size: 9.5px;
  box-shadow: 0 12px 30px rgba(14, 32, 24, 0.26);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes pop-in {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 900px) {
  .shop-hero {
    grid-template-columns: minmax(0, 1fr) 230px;
    min-height: 290px;
  }

  .hero-art {
    width: 220px;
    height: 220px;
  }

  .hero-card {
    width: 128px;
    height: 150px;
  }

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

@media (max-width: 680px) {
  .shop-head {
    min-height: 64px;
    padding: 9px 14px;
  }

  .shop-brand-copy strong {
    font-size: 16px;
  }

  .shop-mark {
    width: 35px;
    height: 35px;
  }

  .head-link span,
  .chat-link {
    display: none;
  }

  .head-link {
    width: 32px;
    justify-content: center;
    padding: 0;
  }

  .shop-actions {
    gap: 2px;
  }

  .account-pill {
    max-width: 84px;
    height: 30px;
    padding: 0 8px;
  }

  .shop-main {
    padding: 0 12px;
  }

  .shop-hero {
    grid-template-columns: 1fr;
    min-height: 0;
    padding: 34px 4px 18px;
  }

  .hero-art {
    display: none;
  }

  .hero-copy h1 {
    font-size: clamp(42px, 12vw, 56px);
  }

  .hero-copy > p:last-child {
    font-size: 10.5px;
  }

  .shop-content {
    padding-bottom: 35px;
  }

  .shop-toolbar {
    align-items: center;
    padding: 16px 0 13px;
  }

  .shop-toolbar h2 {
    font-size: 22px;
  }

  .shop-search {
    width: 130px;
  }

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

  .product-card {
    border-radius: 14px;
  }

  .product-body {
    padding: 9px 42px 11px 10px;
  }

  .product-add {
    right: 9px;
    bottom: 10px;
  }

  .product-name {
    font-size: 11px;
  }

  .product-desc {
    display: none;
  }

  .product-price {
    font-size: 17px;
  }

  .product-add {
    width: 28px;
    height: 28px;
  }

  .shop-foot {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 16px 14px 24px;
  }

  .sheet {
    align-items: flex-end;
    padding: 0;
  }

  .sheet-card {
    width: 100%;
    max-height: 92dvh;
    padding: 21px 17px max(20px, env(safe-area-inset-bottom));
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 22px 22px 0 0;
  }

  .product-sheet-card {
    padding-top: 25px;
  }

  .product-detail {
    grid-template-columns: 1fr;
    gap: 17px;
  }

  .detail-image {
    width: min(100%, 260px);
    margin: 0 auto;
  }

  .detail-copy h2 {
    font-size: 25px;
  }

  .detail-description {
    max-height: 120px;
  }

  .detail-buy {
    position: sticky;
    bottom: 0;
    padding-top: 8px;
    background: var(--surface);
  }

  .detail-add {
    height: 41px;
  }

  .success-sheet {
    align-items: end;
    padding: 0;
  }

  .success-card {
    width: 100%;
    border-radius: 24px 24px 0 0;
    padding-bottom: max(28px, env(safe-area-inset-bottom));
  }
}

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