:root {
  --blush: #fae2e0;
  --blush-soft: #fdf1f0;
  --pink: #f9c8dd;
  --maroon: #6b1234;
  --maroon-dark: #520d27;
  --page: #ffffff;
  --panel: #f7f5f5;
  --field: #fbf6f6;
  --field-line: #e3d6d8;
  --ink: #111111;
  --body: #2a2426;
  --muted: #7a6d70;
  --rule: #ece4e5;
  --good: #1f7a4d;
  --bad: #b3261e;
  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Inter", "Segoe UI", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--page); color: var(--body); font: 16px/1.55 var(--sans); }
img { max-width: 100%; display: block; }
a { color: var(--maroon); }
hr { border: 0; border-top: 1px solid var(--rule); margin: 24px 0; }
[hidden] { display: none !important; }

/* Icons: Phosphor SVGs used as masks so they take the text colour. */
.ic {
  display: inline-block; width: 1.15em; height: 1.15em; flex: none;
  background: currentColor;
  -webkit-mask: var(--i) center / contain no-repeat; mask: var(--i) center / contain no-repeat;
  vertical-align: -0.2em;
}

/* ---- Layout: creator column + product column ------------------------------------ */
.store { max-width: 1160px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 900px) {
  .store { display: grid; grid-template-columns: 340px minmax(0, 660px); gap: 64px; justify-content: center; padding: 32px 24px; }
}

.creator { display: flex; align-items: center; gap: 12px; padding: 14px 0 6px; }
.creator .avatar { width: 48px; height: 48px; }
.creator-name { margin: 0; font-weight: 700; color: var(--ink); }
.creator-bio { margin: 0; font-size: .85rem; color: var(--muted); }
.socials { display: none; }
@media (min-width: 900px) {
  .creator {
    flex-direction: column; text-align: center; gap: 0;
    position: sticky; top: 32px; align-self: start; padding-top: 120px;
  }
  .creator .avatar { width: 160px; height: 160px; margin-bottom: 18px; filter: drop-shadow(0 6px 16px rgba(107,18,52,.15)); }
  .creator-name { font-size: 2rem; line-height: 1.2; }
  .creator-bio { font-size: .92rem; color: var(--body); font-weight: 500; margin: 6px 0 14px; }
  .socials { display: flex; justify-content: center; gap: 8px; }
  .socials a {
    display: grid; place-items: center; width: 42px; height: 42px;
    border: 1.5px solid var(--ink); border-radius: 10px; color: var(--ink); font-size: 1.25rem;
  }
}

/* ---- Cover ------------------------------------------------------------------------ */
.cover-wrap {
  background: linear-gradient(160deg, var(--blush-soft), var(--blush));
  border-radius: 14px;
  margin: 10px 0 18px;
  display: flex; justify-content: center; align-items: center; gap: 0;
  padding: 26px 16px; min-height: 280px; overflow: hidden;
}
.cover-img {
  width: 190px; height: auto; border-radius: 4px; position: relative; z-index: 2;
  box-shadow: 0 18px 40px rgba(107, 18, 52, .25), 0 2px 6px rgba(0,0,0,.1);
}
.cover-wrap picture { display: block; position: relative; z-index: 2; }
@media (min-width: 900px) {
  .cover-wrap { min-height: 360px; margin-top: 0; }
  .cover-img { width: 240px; }
}

/* ---- Title, price, description ------------------------------------------------------ */
.title { font-size: 1.55rem; line-height: 1.25; font-weight: 700; color: var(--ink); margin: 0 0 8px; letter-spacing: -.01em; }
.price { font-size: 1.45rem; font-weight: 700; color: var(--maroon); margin: 0; min-height: 1.5em; }
@media (min-width: 900px) { .title { font-size: 1.9rem; } }

.desc p { margin: 0 0 14px; }
.inside { list-style: none; padding: 0; margin: 0 0 18px; }
.inside li { display: flex; gap: 10px; align-items: flex-start; padding: 5px 0; }
.inside .ic { color: var(--maroon); margin-top: .2em; }
.digital { display: flex; gap: 8px; align-items: flex-start; color: var(--muted); font-size: .95rem; }
.digital .ic { margin-top: .2em; }

/* ---- Reviews ---------------------------------------------------------------------- */
.review-track {
  display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory;
  scrollbar-width: none; padding-bottom: 4px;
}
.review-track::-webkit-scrollbar { display: none; }
.review {
  flex: 0 0 min(78%, 300px); scroll-snap-align: start;
  background: var(--blush-soft); border: 1px solid var(--rule); border-radius: 12px; padding: 16px;
  display: flex; flex-direction: column;
}
.stars { color: var(--maroon); display: flex; gap: 2px; margin-bottom: 8px; }
.who { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--ink); margin-bottom: 6px; }
.initial {
  width: 28px; height: 28px; border-radius: 50%; background: var(--pink); color: var(--maroon);
  display: grid; place-items: center; font-size: .85rem; font-weight: 700;
}
.review .text {
  margin: 0; font-size: .93rem;
  display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden;
}
.review.open .text { -webkit-line-clamp: unset; }
.more { align-self: flex-end; margin-top: auto; padding-top: 8px; border: 0; background: none; color: var(--maroon); font: 600 .88rem var(--sans); cursor: pointer; }
.review-nav { display: flex; justify-content: flex-end; gap: 6px; margin-top: 8px; }
.review-nav button { border: 0; background: none; font-size: 1.2rem; color: var(--ink); cursor: pointer; padding: 4px; }

/* ---- Checkout --------------------------------------------------------------------- */
.checkout h2 { text-align: center; font-size: 1.55rem; font-weight: 700; color: var(--ink); margin: 0 0 18px; }
.field {
  display: block; width: 100%;
  background: var(--field); border: 1px solid var(--field-line); border-radius: 4px;
  padding: 14px 16px; margin: 0 0 14px;
  font: 16px var(--sans); color: var(--ink);
}
.field:focus { outline: 2px solid var(--maroon); outline-offset: -1px; border-color: var(--maroon); }
.consent { display: flex; gap: 10px; align-items: center; font-size: .92rem; margin: 0 0 18px; cursor: pointer; }
.consent input, .bump input { width: 20px; height: 20px; accent-color: var(--maroon); flex: none; margin: 0; }

.bump {
  display: flex; gap: 12px; align-items: flex-start;
  background: var(--blush); border: 2px dashed var(--maroon); border-radius: 10px;
  padding: 14px; margin: 0 0 20px; cursor: pointer;
}
.bump input { margin-top: 2px; }
.bump strong { color: var(--maroon); display: block; }
.bump span { display: block; font-size: .9rem; }

.label { display: block; font-weight: 600; font-size: .92rem; color: var(--ink); margin: 0 0 8px; }
.code-row { position: relative; }
.code-row .field { padding-right: 80px; margin: 0; }
.code-row button {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  border: 0; background: none; font: 600 .95rem var(--sans); color: var(--ink); padding: 8px 10px; cursor: pointer;
}
.code-msg { min-height: 1.3em; font-size: .88rem; margin: 6px 0 12px; }
.code-msg.good { color: var(--good); }
.code-msg.bad { color: var(--bad); }

.lines { margin: 0 0 20px; }
.line { display: flex; align-items: center; gap: 10px; margin: 6px 0; color: var(--muted); }
.line .dots { flex: 1; border-bottom: 1.5px dashed var(--field-line); transform: translateY(-3px); }
.line.total { color: var(--ink); font-weight: 700; font-size: 1.1rem; }
.line.total span:last-child { color: var(--maroon); }

.payment { min-height: 60px; margin: 0 0 12px; }
.turnstile { display: flex; justify-content: center; margin: 0 0 10px; }
.turnstile:empty { margin: 0; }
.pay-error { color: var(--bad); font-size: .92rem; min-height: 1.2em; margin: 0 0 10px; }

.purchase {
  display: block; width: 100%;
  background: var(--maroon); color: #fff; border: 0; border-radius: 10px;
  padding: 17px 18px; font: 700 1.05rem var(--sans); letter-spacing: .06em; text-transform: uppercase;
  cursor: pointer;
}
.purchase:hover { background: var(--maroon-dark); }
.purchase:disabled { opacity: .55; cursor: default; }
.secure { display: flex; justify-content: center; align-items: center; gap: 6px; font-size: .82rem; color: var(--muted); margin: 12px 0 0; }

footer { text-align: center; color: var(--muted); font-size: .85rem; padding: 40px 16px 48px; }

/* ---- Thank-you and message pages ------------------------------------------------------ */
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 560px; padding-top: 40px; padding-bottom: 48px; }
header.top { display: flex; align-items: center; gap: 10px; padding: 14px 0; font-weight: 600; }
header.top img { width: 34px; height: 34px; }
header.top a { color: var(--ink); text-decoration: none; }
.kicker { font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: var(--maroon); font-weight: 600; margin: 0 0 10px; }
.narrow h1 { font-size: 2rem; font-weight: 700; color: var(--ink); margin: 0 0 12px; }
.muted { color: var(--muted); }
.deliver { display: grid; gap: 12px; margin: 20px 0; }
.btn {
  display: block; text-align: center; text-decoration: none;
  background: var(--maroon); color: #fff; border-radius: 10px; padding: 15px 18px; font-weight: 600;
}
.btn.ghost { background: #fff; color: var(--maroon); border: 2px solid var(--maroon); }
.spinner { width: 28px; height: 28px; border-radius: 50%; border: 3px solid var(--rule); border-top-color: var(--maroon); animation: spin 1s linear infinite; margin: 20px 0; }
@keyframes spin { to { transform: rotate(360deg); } }
