:root {
  --ink: #241433;
  --plum: #4a2170;
  --deep: #2d1248;
  --lavender: #efe6ff;
  --lilac: #d4c2f2;
  --petal: #fbf7ff;
  --card: #ffffff;
  --muted: #5c5470;
  --line: #e6dcf4;
  --gold: #8a6418;
  --spark: #efe6ff;
  --shadow: 0 12px 32px rgba(45, 18, 72, 0.08);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: "Avenir Next", "Segoe UI", "Helvetica Neue", sans-serif;
  color-scheme: light;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--petal);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.05rem;
  line-height: 1.5;
}

body.page-item { padding-bottom: 0; }

img { max-width: 100%; height: auto; }

a { color: var(--plum); }

a:hover { color: var(--deep); }

h1, h2, h3 { line-height: 1.15; }

p { margin: 0 0 0.8rem; }

.skip {
  position: absolute;
  left: 0.75rem;
  top: 0.75rem;
  transform: translateY(-150%);
  background: #fff;
  color: var(--ink);
  padding: 0.5rem 0.8rem;
  border-radius: 8px;
  z-index: 20;
}

.skip:focus { transform: none; }

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

:focus-visible {
  outline: 3px solid #e6b422;
  outline-offset: 2px;
}

.wrap {
  width: min(1120px, calc(100% - 2rem));
  margin-inline: auto;
}

.site-header {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 12% 20%, rgba(196, 181, 253, 0.35), transparent 28%),
    radial-gradient(circle at 88% 0%, rgba(167, 139, 250, 0.28), transparent 26%),
    var(--deep);
  color: #f7f2fc;
}

.header-inner { padding: 0.85rem 0 1rem; }

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: inherit;
  text-decoration: none;
}

.brand img {
  width: 68px;
  height: 68px;
  object-fit: contain;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.4);
}

.brand-name {
  display: block;
  margin: 0;
  font-family: var(--serif);
  font-size: 1.7rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
}

.brand-tag {
  display: block;
  margin-top: 0.1rem;
  color: #eadffb;
  font-size: 0.92rem;
}

.sparkles { position: absolute; inset: 0; pointer-events: none; }

.sparkle {
  position: absolute;
  width: 12px;
  height: 12px;
  background: var(--spark);
  clip-path: polygon(50% 0%, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0% 50%, 38% 38%);
  animation: twinkle 2.8s ease-in-out infinite;
}

.sparkle:nth-child(1) { left: 8%; top: 22%; animation-delay: 0s; }
.sparkle:nth-child(2) { left: 22%; top: 70%; width: 8px; height: 8px; animation-delay: 0.6s; }
.sparkle:nth-child(3) { left: 70%; top: 18%; animation-delay: 1.1s; }
.sparkle:nth-child(4) { left: 84%; top: 62%; width: 9px; height: 9px; animation-delay: 0.3s; }
.sparkle:nth-child(5) { left: 48%; top: 12%; width: 7px; height: 7px; animation-delay: 1.6s; }
.sparkle:nth-child(6) { left: 92%; top: 28%; width: 6px; height: 6px; animation-delay: 0.9s; }
.sparkle:nth-child(7) { left: 36%; top: 78%; width: 8px; height: 8px; animation-delay: 1.9s; }

@keyframes twinkle {
  0%, 100% { opacity: 0.25; transform: scale(0.75) rotate(0deg); }
  50% { opacity: 1; transform: scale(1) rotate(12deg); }
}

.about {
  margin: 1.1rem 0 0.4rem;
  padding: 0.95rem 1rem 0.35rem;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow);
}

.about p:last-child { margin-bottom: 0.7rem; }

.pickup-strip {
  margin: 0.85rem 0 0;
  padding: 0.75rem 0.95rem;
  background: var(--lavender);
  border-radius: 14px;
  color: var(--deep);
  font-weight: 600;
}

.tools {
  position: sticky;
  top: 0;
  z-index: 5;
  margin: 0.4rem 0 0.8rem;
  padding: 0.65rem 0 0.4rem;
  background: rgba(251, 247, 255, 0.94);
}

.search input,
.sort select {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--lilac);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  padding: 0.55rem 0.8rem;
}

.search { display: block; margin-bottom: 0.7rem; }

.tool-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.55rem;
}

.sort {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-weight: 650;
}

.sort select { width: auto; min-width: 11rem; }

.results { margin: 0; color: var(--muted); font-size: 0.95rem; }

.chips {
  display: flex;
  gap: 0.45rem;
  overflow-x: auto;
  padding-bottom: 0.35rem;
  scrollbar-width: thin;
}

.chips button {
  flex: 0 0 auto;
  min-height: 44px;
  border: 1px solid var(--lilac);
  background: #fff;
  color: var(--plum);
  border-radius: 999px;
  padding: 0.4rem 0.85rem;
  font: inherit;
  font-weight: 650;
}

.chips button[aria-pressed="true"] {
  background: var(--plum);
  border-color: var(--plum);
  color: #fff;
}

.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.card {
  display: flex;
  flex-direction: column;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.card[hidden] { display: none !important; }

.card-link {
  color: inherit;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.photo {
  position: relative;
  aspect-ratio: 1;
  background: #f6f2fb;
}

.photo .cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.photo-missing {
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--muted);
}

.photo-missing img { width: 42%; height: auto; }

.num-badge,
.cat-badge,
.sold-flag {
  position: absolute;
  z-index: 1;
  background: rgba(255, 255, 255, 0.94);
  color: var(--deep);
  border-radius: 999px;
  font-weight: 750;
}

.num-badge {
  top: 0.65rem;
  left: 0.65rem;
  padding: 0.2rem 0.55rem;
  font-variant-numeric: tabular-nums;
}

.cat-badge {
  top: 0.65rem;
  right: 0.65rem;
  padding: 0.2rem 0.55rem;
  font-size: 0.82rem;
}

.sold-flag {
  left: 0.65rem;
  bottom: 0.65rem;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.15rem 0.6rem 0.15rem 0.2rem;
  color: var(--muted);
  font-size: 0.85rem;
}

.sold-flag img { width: 28px; height: 28px; object-fit: contain; border-radius: 50%; background: #fff; }

.card-sold .cover { filter: grayscale(1); opacity: 0.72; }

.card-body { padding: 0.85rem 0.95rem 0.35rem; }

.card-body h2 {
  margin: 0 0 0.35rem;
  font-size: 1.2rem;
  font-family: var(--serif);
}

.card-meta {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  margin: 0;
  font-variant-numeric: tabular-nums;
}

.price {
  font-weight: 800;
  color: var(--deep);
  font-size: 1.15rem;
}

.weight { color: var(--muted); }

.card-actions {
  padding: 0.35rem 0.95rem 0.95rem;
  margin: 0;
}

.want-block {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.4rem;
}

.marketplace-note,
.square-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.35;
  font-weight: 500;
}

.want-block .btn-ghost { width: 100%; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.65rem 1rem;
  border-radius: 999px;
  background: var(--plum);
  color: #fff;
  font: inherit;
  font-weight: 750;
  text-decoration: none;
  border: 2px solid var(--plum);
  cursor: pointer;
}

.btn:hover { background: var(--deep); border-color: var(--deep); color: #fff; }

.btn-small { min-height: 44px; padding: 0.45rem 0.9rem; }

.btn-ghost {
  background: #fff;
  color: var(--plum);
}

.btn-ghost:hover { background: var(--lavender); color: var(--deep); }

.buybar .marketplace-note,
.buybar .square-note { text-align: left; }

.section-head { margin: 2rem 0 0.8rem; }

.section-head h2 {
  margin: 0 0 0.3rem;
  font-family: var(--serif);
  font-size: 1.7rem;
}

.section-head p { color: var(--muted); }

.inline-raccoon {
  width: 28px;
  height: 28px;
  vertical-align: -8px;
  object-fit: contain;
  border-radius: 50%;
  background: #fff;
}

.empty {
  margin: 1rem 0 2rem;
  padding: 1.4rem 1rem 1.2rem;
  text-align: center;
  background: #fff;
  border: 1px dashed var(--lilac);
  border-radius: 18px;
}

.empty img {
  width: min(180px, 50vw);
  height: auto;
}

.empty[hidden] { display: none !important; }

.noscript {
  margin: 0.8rem 0;
  padding: 0.7rem 0.85rem;
  background: #fff;
  border-radius: 12px;
}

.back {
  display: inline-block;
  margin: 0.9rem 0 0.2rem;
  font-weight: 700;
  text-decoration: none;
}

.item-layout { margin-top: 0.4rem; }

.gallery {
  margin: 0 0 1rem;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.gallery-main {
  width: 100%;
  aspect-ratio: 1;
  object-fit: contain;
  background: #f6f2fb;
  display: block;
}

.gallery figcaption {
  padding: 0.45rem 0.9rem 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.thumbs {
  display: flex;
  gap: 0.5rem;
  padding: 0.7rem 0.9rem 0.9rem;
}

.thumbs button {
  width: 72px;
  height: 72px;
  padding: 0;
  border-radius: 12px;
  border: 2px solid transparent;
  background: #f6f2fb;
  cursor: pointer;
}

.thumbs button[aria-current="true"] { border-color: var(--plum); }

.thumbs img { width: 100%; height: 100%; object-fit: cover; border-radius: 10px; }

.item-title { margin: 0.2rem 0 0.4rem; font-family: var(--serif); font-size: 2rem; }

.item-title .kicker {
  display: block;
  margin-bottom: 0.25rem;
  font-family: var(--sans);
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 750;
}

.item-title .kicker strong {
  font-size: 2.5rem;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.item-price {
  margin: 0 0 0.8rem;
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--deep);
  font-variant-numeric: tabular-nums;
}

.item-price .item-weight {
  display: inline-block;
  margin-left: 0.45rem;
  font-size: 1rem;
  font-weight: 600;
  color: var(--muted);
}

.status-note {
  display: inline-block;
  margin: 0 0 0.8rem;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background: var(--lavender);
  color: var(--deep);
  font-weight: 700;
  font-size: 0.92rem;
}

.prose p { font-size: 1.08rem; }

.specs { margin: 0.4rem 0 1rem; }

.specs div {
  display: grid;
  grid-template-columns: 8.5rem 1fr;
  gap: 0.5rem;
  padding: 0.45rem 0;
  border-top: 1px solid var(--line);
}

.specs dt { margin: 0; color: var(--muted); font-weight: 700; }
.specs dd { margin: 0; }

.extra-link { font-weight: 750; }

.video { margin: 0.8rem 0 1rem; }

.video iframe,
.video video {
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 0;
  border-radius: 16px;
  background: #111;
}

.sold-banner {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0.4rem 0 1rem;
  padding: 0.7rem 0.8rem;
  background: #f3f1f6;
  color: var(--muted);
  border-radius: 16px;
  font-weight: 750;
}

.sold-banner img { width: 56px; height: 56px; object-fit: contain; border-radius: 50%; background: #fff; }
.sold-banner p { margin: 0; }

.buybar {
  display: grid;
  gap: 0.75rem;
  margin-top: 0.8rem;
  padding: 0.9rem;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
}

.buybar-price { display: flex; flex-direction: column; line-height: 1.15; }
.buybar-price strong { font-size: 1.25rem; color: var(--deep); }
.buybar-price span { color: var(--muted); font-size: 0.9rem; }
.buybar-actions { display: block; }
.buybar .btn,
.buybar .btn-ghost { width: 100%; }

.want-dialog {
  width: min(26rem, calc(100% - 1.5rem));
  border: 0;
  border-radius: 20px;
  padding: 1.15rem 1.15rem 1rem;
  box-shadow: 0 24px 70px rgba(36, 16, 51, 0.28);
}

.want-dialog::backdrop { background: rgba(36, 16, 51, 0.48); }

.want-dialog h2 { margin: 0 0 0.3rem; font-family: var(--serif); }

.want-label { font-weight: 750; }

.want-actions { display: grid; gap: 0.55rem; margin: 0.8rem 0; }

.want-dialog .fine { color: var(--muted); font-size: 0.95rem; }

.text-btn {
  display: block;
  width: 100%;
  min-height: 44px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.site-footer {
  margin-top: 2.5rem;
  padding: 1.4rem 0 1.8rem;
  background: var(--deep);
  color: #f3eaff;
}

.footer-inner { display: flex; gap: 0.9rem; align-items: flex-start; }

.footer-inner > img {
  width: 64px;
  height: 64px;
  object-fit: contain;
  border-radius: 50%;
  background: #fff;
}

.footer-name {
  margin: 0 0 0.2rem;
  font-family: var(--serif);
  font-size: 1.3rem;
  color: #fff;
}

.site-footer a { color: #fff; }

.site-footer p:last-child { margin-bottom: 0; }

.missing {
  min-height: 70vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 2rem 1rem 3rem;
}

.missing img { width: min(220px, 60vw); }

@media (min-width: 720px) {
  .brand-name { font-size: 2rem; }
  .grid { grid-template-columns: 1fr 1fr; }
  .buybar { max-width: 28rem; }
}

@media (min-width: 960px) {
  body.page-item { padding-bottom: 0; }
  .grid { grid-template-columns: 1fr 1fr 1fr; }
  .item-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
    gap: 1.5rem;
    align-items: start;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .sparkle { animation: none; opacity: 0.85; }
}
