/* Fallback with Nunito's measurements, so text doesn't jump when the web font arrives (layout shift). */
@font-face { font-family: "Nunito Fallback"; src: local("Arial"), local("Helvetica"), local("Liberation Sans"); size-adjust: 101%; ascent-override: 100.1%; descent-override: 34.95%; line-gap-override: 0%; }
/* Layout: a gift-wrap toolbar on the left, a big live stage on the right; stacks on phones */
:root {
  /* tinytada: neutral surfaces, one purple accent; logo colors stay in the logo */
  --bg: #f6f6f7;
  --panel: #ffffff;
  --ink: #17171c;
  --muted: #6c6c78;
  --line: #e5e5ea;
  --line-strong: #d4d4db;
  --accent: #6a4ee0;
  --accent-ink: #ffffff;
  --accent-soft: #f2efff;
  --sel: #f3f3f5;
  --coral: #fd7373;
  --purple: #997bf2;
  --sky: #70b5fd;
  --sun: #fdbb5b;
  --mint: #15803d;
  --check-a: #ececf0;
  --check-b: #ffffff;
  --shadow: 0 1px 2px rgba(16,16,24,0.04), 0 1px 1px rgba(16,16,24,0.03);
  --font-display: "Fredoka", "Nunito", "Nunito Fallback", system-ui, sans-serif;
  --font-ui: "Geist", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: var(--font-ui);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e0e11; --panel: #17171b; --ink: #f4f4f6; --muted: #9d9daa; --line: #26262d; --line-strong: #34343d;
    --accent: #a894ff; --accent-ink: #0e0e11; --accent-soft: #221d38; --sel: #202026; --coral: #ff8a8a; --purple: #b39bff; --sky: #8cc4ff; --sun: #ffc970; --mint: #4ade80; --check-a: #26262d; --check-b: #1c1c21; --shadow: none; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0e0e11; --panel: #17171b; --ink: #f4f4f6; --muted: #9d9daa; --line: #26262d; --line-strong: #34343d;
    --accent: #a894ff; --accent-ink: #0e0e11; --accent-soft: #221d38; --sel: #202026; --coral: #ff8a8a; --purple: #b39bff; --sky: #8cc4ff; --sun: #ffc970; --mint: #4ade80; --check-a: #26262d; --check-b: #1c1c21; --shadow: none; color-scheme: dark;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { background: var(--bg); color: var(--ink); font-family: var(--font-ui); font-size: 14.5px; line-height: 1.5; -webkit-font-smoothing: antialiased; letter-spacing: -0.003em; }
.wrap { max-width: 1240px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); padding-block: 20px 40px; }
header { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.logo { font-family: var(--font-display); font-weight: 700; font-size: 26px; letter-spacing: -0.015em; display: flex; align-items: center; gap: 6px; line-height: 1; }
.logo img { width: 38px; height: 38px; object-fit: contain; }
.logo .lt { color: var(--coral); } .logo .ld { color: var(--purple); }
.head-right { display: flex; align-items: center; gap: 14px; }
.acct { font: inherit; font-size: 13px; font-weight: 500; border: 1px solid var(--line-strong); background: var(--panel); color: var(--ink); border-radius: 8px; padding: 6px 12px; cursor: pointer; display: flex; align-items: center; gap: 8px; }
.acct .av { width: 22px; height: 22px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; font-size: 11px; font-weight: 600; }
.acct .gc { color: var(--muted); font-variant-numeric: tabular-nums; }
.auth-modal, .buy-modal { max-width: 380px; gap: 10px; }
.issue-opts { display: flex; flex-direction: column; gap: 8px; }
.issue-opts label { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-size: 14px; margin: 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; cursor: pointer; }
.issue-opts label:has(input:checked) { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.issue-opts input { accent-color: var(--accent); margin-top: 3px; }
.auth-sub { margin: -2px 0 6px !important; font-size: 13.5px !important; color: var(--muted); }
.oauth { font: inherit; font-size: 14px; font-weight: 500; display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; padding: 10px; border-radius: 8px; border: 1px solid var(--line-strong); background: var(--panel); color: var(--ink); cursor: pointer; }
.oauth:hover { background: var(--sel); }
.oauth svg { width: 18px; height: 18px; }
.or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 12px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.auth-email { display: flex; gap: 8px; }
.auth-email input { flex: 1; min-width: 0; font: inherit; color: var(--ink); background: var(--panel); border: 1px solid var(--line-strong); border-radius: 8px; padding: 8px 11px; }
.fine { font-size: 12px !important; }
#auth-cancel { align-self: center; }
.pack { display: flex; align-items: center; justify-content: space-between; gap: 12px; border: 1px solid var(--ink); box-shadow: inset 0 0 0 1px var(--ink); border-radius: 10px; padding: 12px 14px; }
.pack b { display: block; font-size: 15px; font-weight: 600; }
.pack span { font-size: 12.5px; color: var(--muted); }
.pack-price { font-size: 26px; font-weight: 600; letter-spacing: -0.03em; }
.buy-row { align-items: center; justify-content: space-between; }
.buy-row .publish { flex: 1; }
.credits .linkbtn { font-size: 12px; color: var(--accent); }
.demo-tag { font-size: 13px; font-weight: 500; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.demo-tag i { width: 6px; height: 6px; border-radius: 50%; background: var(--mint); }
.grid { display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: 20px; align-items: start; }
@media (max-width: 880px) { .grid { grid-template-columns: 1fr; } .stage-col { order: -1; } }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 20px; display: flex; flex-direction: column; gap: 0; box-shadow: var(--shadow); }
.panel > .step + .step, .panel > .step + .checkout { border-top: 1px solid var(--line); padding-top: 18px; margin-top: 18px; }
.step h2 { font-size: 15px; color: var(--ink); margin: 0 0 12px; font-weight: 600; letter-spacing: -0.01em; display: flex; align-items: center; gap: 10px; }
.step h2 .n { font-size: 12px; font-weight: 500; color: var(--muted); font-variant-numeric: tabular-nums; width: 20px; height: 20px; border-radius: 6px; border: 1px solid var(--line); display: grid; place-items: center; }
.templates { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.occasions { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.occasions button { font: inherit; font-size: 13px; font-weight: 500; border: 1px solid var(--line); background: var(--panel); color: var(--muted); border-radius: 8px; padding: 6px 11px; cursor: pointer; transition: color .15s, border-color .15s; }
.occasions button:hover { color: var(--ink); border-color: var(--line-strong); }
.occasions button[aria-pressed="true"] { background: var(--ink); color: var(--panel); border-color: var(--ink); }
.tpl { border: 1px solid var(--line); background: var(--panel); color: var(--ink); border-radius: 10px; padding: 12px 6px 10px; cursor: pointer; font: inherit; font-size: 12.5px; font-weight: 500; transition: border-color .15s, background .15s; display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; }
.tpl .ico { width: 36px; height: 36px; border-radius: 9px; background: var(--sel); color: var(--ink); display: grid; place-items: center; margin-bottom: 4px; transition: background .15s, color .15s; }
.tpl .ico svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.tpl[aria-pressed="true"] .ico { background: var(--accent); color: var(--accent-ink); }
.tpl:hover { border-color: var(--line-strong); }
.tpl small { font-weight: 400; color: var(--muted); font-size: 11px; }
.tpl[aria-pressed="true"] { border-color: var(--ink); background: var(--sel); box-shadow: inset 0 0 0 1px var(--ink); }
.tpl:focus-visible, button:focus-visible, input:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
label { display: block; font-weight: 500; font-size: 13px; margin-bottom: 6px; }
.hint { font-size: 12px; color: var(--muted); margin-top: 3px; }
.field { display: flex; flex-direction: column; gap: 2px; }
.fields { display: flex; flex-direction: column; gap: 12px; }
.field textarea, input[type="date"] { width: 100%; font: inherit; color: var(--ink); background: var(--panel); border: 1px solid var(--line-strong); border-radius: 8px; padding: 8px 11px; box-shadow: var(--shadow); resize: vertical; }
.replay { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); z-index: 4; font-size: 15px; padding: 9px 20px; }
input[type="text"] { width: 100%; font: inherit; color: var(--ink); background: var(--panel); border: 1px solid var(--line-strong); border-radius: 8px; padding: 8px 11px; box-shadow: var(--shadow); }
.photos { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.thumb { width: 56px; height: 56px; border-radius: 10px; border: 1px solid var(--line); background: repeating-conic-gradient(var(--check-a) 0% 25%, var(--check-b) 0% 50%) 50% / 12px 12px; }
.thumb-btn { padding: 0; overflow: hidden; cursor: pointer; background: none; position: relative; }
.thumb-btn { overflow: visible; }
.thumb-btn img { width: 100%; height: 100%; object-fit: contain; display: block; border-radius: 10px; }
.thumb-btn::after { content: "✎"; position: absolute; right: -6px; bottom: -6px; width: 20px; height: 20px; border-radius: 50%; background: var(--ink); color: var(--panel); border: 2px solid var(--panel); font-size: 11px; display: grid; place-items: center; }
.bg-thumb { cursor: pointer; }
.crop-modal { max-width: 520px; }
.crop-stage { position: relative; width: 100%; aspect-ratio: 4 / 3; max-width: 100%; border-radius: 12px; overflow: hidden; background: #1a1120; touch-action: none; cursor: grab; }
.crop-stage:active { cursor: grabbing; }
.crop-stage:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.crop-stage canvas { width: 100%; height: 100%; display: block; }
.crop-tools { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.crop-tools input[type=range] { flex: 1; min-width: 140px; accent-color: var(--accent); }
.crop-prev { width: 56px; height: 56px; border-radius: 50%; border: 2px solid var(--accent); flex: none; background: var(--bg); }
.crop-prev.rect { width: 80px; height: 50px; border-radius: 8px; }
.crop-legend { font-size: 12.5px; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.crop-legend i { width: 18px; height: 0; border-top: 2px dashed currentColor; display: inline-block; color: var(--ink); }
.upload { font: inherit; font-size: 13px; font-weight: 500; border: 1px dashed var(--line-strong); color: var(--ink); background: transparent; border-radius: 8px; padding: 8px 12px; cursor: pointer; }
.linkbtn { font: inherit; font-size: 12.5px; background: none; border: 0; color: var(--muted); text-decoration: underline; cursor: pointer; padding: 0; }
.swatches { display: flex; gap: 8px; flex-wrap: wrap; }
.sw { width: 36px; height: 36px; border-radius: 8px; border: 1px solid var(--line); cursor: pointer; padding: 0; }
.sw[aria-pressed="true"] { border-color: var(--panel); box-shadow: 0 0 0 2px var(--ink); }
.ai { display: flex; gap: 8px; margin-top: 10px; }
.ai input { flex: 1; min-width: 0; }
.btn { font: inherit; font-weight: 500; border: 0; border-radius: 8px; padding: 9px 14px; cursor: pointer; background: var(--ink); color: var(--bg); white-space: nowrap; }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }
.credits { font-size: 12px; color: var(--muted); margin-top: 6px; font-variant-numeric: tabular-nums; }
.credits b { color: var(--accent); }
.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-bottom: 10px; }
.seg button { font: inherit; font-size: 13px; font-weight: 500; border: 1px solid var(--line); background: transparent; color: var(--ink); border-radius: 10px; padding: 8px; cursor: pointer; }
.seg button[aria-pressed="true"] { border-color: var(--ink); background: var(--sel); box-shadow: inset 0 0 0 1px var(--ink); }
.seg small { display: block; font-weight: 500; color: var(--muted); font-size: 11.5px; }
.addr { display: flex; align-items: center; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--panel); overflow: hidden; box-shadow: var(--shadow); }
.addr input { border: 0; border-radius: 0; background: transparent; min-width: 0; box-shadow: none; }
.addr span { padding-right: 11px; color: var(--muted); font-size: 14px; white-space: nowrap; }
.addr-wrap { position: relative; }
.suggest { position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 6; list-style: none; margin: 0; padding: 6px; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 12px 32px rgba(16, 16, 24, 0.12); max-height: 290px; overflow-y: auto; }
.suggest .sh { font-size: 12px; font-weight: 500; color: var(--muted); padding: 6px 8px 4px; }
.suggest li[role="option"] { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 10px; border-radius: 8px; cursor: pointer; font-size: 14px; }
.suggest li[role="option"] .nm { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.suggest li[role="option"] .nm b { font-weight: 700; }
.suggest li[role="option"] .st { font-size: 12px; font-weight: 700; white-space: nowrap; color: var(--mint); font-variant-numeric: tabular-nums; }
.suggest li[role="option"][aria-disabled="true"] { cursor: default; opacity: 0.55; }
.suggest li[role="option"][aria-disabled="true"] .st { color: var(--muted); }
.suggest li[role="option"]:not([aria-disabled="true"]):hover, .suggest li[role="option"].active { background: var(--accent-soft); }
.suggest .foot { font-size: 11.5px; color: var(--muted); padding: 6px 10px 2px; }
.bg-own { display: flex; align-items: center; gap: 10px; margin-top: 10px; flex-wrap: wrap; }
.bg-thumb { width: 64px; height: 40px; object-fit: cover; border-radius: 8px; border: 2px solid var(--ink); }
.avail { font-size: 12.5px; margin-top: 5px; font-weight: 600; }
.avail.ok { color: var(--mint); } .avail.bad { color: var(--accent); }
.checkout { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.price { font-family: var(--font-ui); font-weight: 600; letter-spacing: -0.03em; font-size: 28px; line-height: 1; font-variant-numeric: tabular-nums; }
.price small { font-size: 13px; color: var(--muted); font-weight: 400; letter-spacing: 0; }
.publish { background: var(--accent); color: var(--accent-ink); font-size: 15px; font-weight: 600; padding: 11px 20px; border-radius: 10px; box-shadow: 0 1px 0 rgba(255,255,255,0.18) inset, 0 1px 2px rgba(16,16,24,0.2); }
.publish:hover { filter: brightness(1.06); }
.stage-col { display: flex; flex-direction: column; gap: 10px; position: sticky; top: calc(env(safe-area-inset-top, 0px) + 12px); min-width: 0; }
@media (max-width: 880px) { .stage-col { position: static; } }
.browser { border-radius: 14px; overflow: hidden; border: 1px solid var(--line); background: var(--panel); box-shadow: 0 1px 2px rgba(16,16,24,0.04), 0 12px 32px -12px rgba(16,16,24,0.14); }
.bar { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border-bottom: 1px solid var(--line); }
.dots { display: flex; gap: 5px; } .dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--line); display: block; }
.url { flex: 1; min-width: 0; font-size: 13px; color: var(--muted); background: var(--bg); border-radius: 8px; padding: 4px 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.url b { color: var(--ink); font-weight: 600; }
.stage { position: relative; aspect-ratio: 16 / 10; max-width: 100%; overflow: hidden; touch-action: none; user-select: none; -webkit-user-select: none; }
.stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.stage.nocursor { cursor: none; }
.overlay { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; padding: 6% 6% 0; pointer-events: none; text-align: center; }
.headline { font-family: var(--font-display); font-weight: 700; color: #fff; font-size: clamp(22px, 5.2vw, 54px); line-height: 1.05; text-shadow: 0 3px 0 rgba(0,0,0,0.18), 0 6px 22px rgba(0,0,0,0.18); text-wrap: balance; margin: 0; }
.msg { color: #fff; font-weight: 600; font-size: clamp(13px, 1.8vw, 18px); margin-top: 8px; text-shadow: 0 2px 10px rgba(0,0,0,0.3); max-width: 40ch; }
.hud { position: absolute; top: 12px; right: 14px; font-family: var(--font-display); color: #fff; font-size: 20px; text-shadow: 0 2px 6px rgba(0,0,0,0.3); pointer-events: none; font-variant-numeric: tabular-nums; }
@media (max-width: 600px) { .hud { font-size: 14px; top: 8px; right: 10px; } .overlay { padding-top: 34px; } }
.val { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.val-card { background: #fffafb; color: #2a1630; border-radius: 22px; padding: 20px 28px 22px; text-align: center; max-width: 80%; display: flex; flex-direction: column; align-items: center; gap: 10px; box-shadow: 0 2px 0 rgba(242,95,108,0.15), 0 18px 50px rgba(150,20,70,0.22); border: 2px solid #ffd3df; }
.val-pic { position: relative; height: 112px; display: flex; justify-content: center; }
.val-pic img { height: 100%; width: auto; max-width: 180px; object-fit: contain; filter: drop-shadow(0 6px 10px rgba(120, 20, 60, 0.25)); }
.val-badge { position: absolute; right: -18px; top: -8px; font-size: 30px; line-height: 1; }
.val-pic.shake img { animation: valShake 0.5s ease; }
.val-pic.bounce img { animation: valBounce 0.8s ease-in-out infinite; }
@keyframes valShake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-6px) rotate(-3deg); } 75% { transform: translateX(6px) rotate(3deg); } }
@keyframes valBounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
.val-eyebrow { font-size: 11.5px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: #f25f6c; }
.val-q { font-family: var(--font-display); font-size: clamp(20px, 3.4vw, 34px); line-height: 1.1; margin: 0; text-wrap: balance; font-weight: 700; }
.val-btns { display: flex; gap: 18px; align-items: center; justify-content: center; min-height: 64px; padding: 6px 0; }
.vbtn { font: inherit; font-weight: 800; border: 0; border-radius: 999px; padding: 10px 28px; font-size: 17px; cursor: pointer; }
.vyes { background: #f25f6c; color: #fff; transition: transform 0.45s cubic-bezier(.3,1.4,.5,1); box-shadow: 0 6px 16px rgba(242,95,108,0.35); }
.vno { background: #ffffff; color: #2a1630; border: 2px solid #f1d6df; }
.vno.ghost { visibility: hidden; }
.vno.free { position: absolute; left: 0; top: 0; z-index: 3; will-change: transform; transform-origin: center; touch-action: none; }
.val-done { font-family: var(--font-display); font-size: clamp(24px, 4.4vw, 44px); color: #f25f6c; margin: 0; font-weight: 700; }
.val-card.exam { max-width: min(560px, 94%); max-height: 94%; overflow-y: auto; gap: 8px; padding: 16px 20px; }
.exam .val-pic { height: 80px; }
.exam-sub { margin: 0; font-size: 13px; color: #7a6580; }
.exam-bar { width: 100%; height: 8px; border-radius: 4px; background: #f6dbe4; overflow: hidden; }
.exam-bar i { display: block; height: 100%; background: #f25f6c; transition: width 0.3s; }
.exam-q { margin: 0; font-weight: 700; font-size: clamp(14px, 2vw, 19px); text-wrap: balance; }
.exam-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; width: 100%; }
.exam-opts button { font: inherit; font-weight: 600; font-size: 14px; border: 2px solid #f1d6df; background: #ffffff; color: #2a1630; border-radius: 12px; padding: 9px 8px; cursor: pointer; }
.exam-opts button:hover { border-color: #f25f6c; }
.exam-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; width: min(210px, 100%); }
.exam-grid button { aspect-ratio: 1; font-size: 26px; border: 2px solid #f1d6df; border-radius: 10px; background: #ffffff; cursor: pointer; padding: 0; }
.exam-grid button[aria-pressed="true"] { border-color: #1f9e7a; background: #e5f4e4; }
.exam-verify { background: #2a1630; color: #ffffff; padding: 8px 22px; font-size: 15px; }
.exam-yes { font-size: 14px; padding: 8px 18px; transition: transform 0.4s cubic-bezier(.3,1.4,.5,1); }
.exam-fb { margin: 0; min-height: 1.3em; font-size: 13px; font-weight: 600; color: #1f9e7a; }
.exam-fb.bad { color: #f25f6c; }
.exam-shake { animation: valShake 0.45s ease; }
.endcard { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: rgba(42, 22, 48, 0.32); z-index: 4; }
.endcard .box { background: #fffafb; color: #2a1630; border-radius: 22px; padding: 22px 30px; text-align: center; display: flex; flex-direction: column; gap: 8px; align-items: center; box-shadow: 0 18px 50px rgba(40,0,30,0.3); max-width: 86%; }
.endcard h2 { font-family: var(--font-display); font-size: clamp(24px, 4.4vw, 42px); margin: 0; color: #d9466a; font-weight: 700; line-height: 1.05; }
.endcard p { margin: 0 0 6px; font-weight: 600; color: #6b5470; font-variant-numeric: tabular-nums; }
.tip { font-size: 13px; color: var(--muted); display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.scrim { position: fixed; inset: 0; background: rgba(10, 10, 14, 0.5); backdrop-filter: blur(2px); display: flex; align-items: center; justify-content: center; padding: 16px; z-index: 20; }
.modal { background: var(--panel); color: var(--ink); border-radius: 14px; padding: 24px; max-width: 440px; width: 100%; display: flex; flex-direction: column; gap: 12px; border: 1px solid var(--line); }
.modal h3 { font-family: var(--font-ui); font-size: 20px; letter-spacing: -0.02em; margin: 0; color: var(--ink); font-weight: 600; }
.modal dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 0; font-size: 14px; }
.modal dt { color: var(--muted); } .modal dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.modal p { margin: 0; font-size: 13px; color: var(--muted); }
.row { display: flex; gap: 8px; flex-wrap: wrap; }
@media (prefers-reduced-motion: reduce) { .vyes { transition: none; } .val-pic img { animation: none !important; } }
.modal { max-height: 100%; overflow-y: auto; }
.lbl-sub { font-weight: 500; color: var(--muted); font-size: 12px; margin-left: 4px; }

/* account */
.edit-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); font-size: 13.5px; color: var(--muted); }
.edit-bar b { color: var(--ink); font-weight: 600; }
.edit-bar .linkbtn { color: var(--accent); }
.account { display: flex; flex-direction: column; gap: 18px; }
.acct-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.acct-head h1 { font-size: 24px; letter-spacing: -0.02em; margin: 0; font-weight: 600; }
.acct-who { color: var(--muted); font-size: 13.5px; }
.acct-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.acct-tabs button { font: inherit; font-size: 14px; font-weight: 500; background: none; border: 0; border-bottom: 2px solid transparent; color: var(--muted); padding: 8px 12px; cursor: pointer; white-space: nowrap; margin-bottom: -1px; }
.acct-tabs button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--ink); }
.site-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.site-card { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column; }
.sc-thumb { height: 110px; display: grid; place-items: center; }
.sc-ico { width: 48px; height: 48px; border-radius: 12px; background: rgba(255,255,255,0.9); color: #17171c; display: grid; place-items: center; }
.sc-ico svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.sc-body { padding: 14px; display: flex; flex-direction: column; gap: 4px; }
.sc-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.sc-top b { font-weight: 600; font-size: 15px; }
.sc-url { font-size: 13.5px; color: var(--accent); overflow-wrap: anywhere; }
.sc-meta { font-size: 12.5px; color: var(--muted); }
.sc-actions { display: flex; gap: 8px; align-items: center; margin-top: 8px; flex-wrap: wrap; }
.sc-actions .linkbtn { margin-left: auto; }
.badge { font-size: 11.5px; font-weight: 600; padding: 2px 8px; border-radius: 999px; white-space: nowrap; }
.badge.ok { background: color-mix(in srgb, var(--mint) 14%, transparent); color: var(--mint); }
.badge.off { background: var(--sel); color: var(--muted); }
.bill-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; margin-bottom: 14px; }
.bill-card { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 14px; display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.bc-label { font-size: 12.5px; color: var(--muted); }
.bc-main { font-size: 16px; font-weight: 600; }
.bc-sub { font-size: 12.5px; color: var(--muted); margin-bottom: 6px; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }
.acct-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.acct-table th { text-align: left; font-weight: 500; color: var(--muted); padding: 10px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.acct-table td { padding: 10px 14px; border-bottom: 1px solid var(--line); }
.acct-table tr:last-child td { border-bottom: 0; }
.acct-table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
/* cutout editor */
.cut-modal { max-width: 560px; }
.cut-sub { margin: -6px 0 0; font-size: 13px; color: var(--muted); }
.cut-tools { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.cut-tools button { font: inherit; font-size: 12.5px; font-weight: 500; border: 1px solid var(--line); background: transparent; color: var(--ink); border-radius: 10px; padding: 7px 4px; cursor: pointer; }
.cut-tools button[aria-pressed="true"] { border-color: var(--ink); background: var(--sel); box-shadow: inset 0 0 0 1px var(--ink); }
@media (max-width: 440px) { .cut-tools { grid-template-columns: repeat(2, 1fr); } }
.cut-stage { position: relative; width: 100%; aspect-ratio: 4 / 3; max-width: 100%; border-radius: 12px; overflow: hidden; background: #2a1d30; touch-action: none; cursor: crosshair; }
.cut-stage canvas { width: 100%; height: 100%; display: block; }
.cut-help { font-size: 12.5px; color: var(--muted); margin: 0; min-height: 2.6em; }
.cut-help.err { color: var(--accent); font-weight: 600; }
.cut-opts { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.cut-opts label { margin: 0; }
.cut-opts input[type=range] { flex: 1; min-width: 140px; accent-color: var(--accent); }
.cut-bottom { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.cut-bottom .row { flex-direction: column; align-items: flex-start; gap: 6px; }
#cut-prev { width: 120px; height: 90px; border-radius: 10px; border: 1px solid var(--line); flex: none; }
.cut-prev-label { font-size: 12px; color: var(--muted); }
/* pet pack */
.jaw-row { display: flex; gap: 12px; align-items: center; }
.jaw-row canvas { width: 88px; height: 88px; border-radius: 12px; flex: none; background: repeating-conic-gradient(var(--check-a) 0% 25%, var(--check-b) 0% 50%) 50% / 12px 12px; }
.jaw-ctl { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1; }
.jaw-ctl input { width: 100%; accent-color: var(--accent); }
.pet-palette { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.pet-tile { border: 1px solid var(--line); background: var(--bg); color: var(--ink); border-radius: 12px; padding: 4px 2px 6px; cursor: grab; font: inherit; font-size: 12px; font-weight: 600; display: flex; flex-direction: column; align-items: center; touch-action: manipulation; }
.pet-tile:hover { border-color: var(--accent); }
.pet-tile canvas { width: 60px; height: 50px; pointer-events: none; }
.pet-tile.full { opacity: 0.45; }
.pet-tile.dragging { opacity: 0.4; }
.pack-zone { margin-top: 8px; border: 2px dashed var(--line); border-radius: 14px; padding: 8px; display: flex; flex-direction: column; gap: 6px; transition: border-color 0.15s, background 0.15s; }
.pack-zone.over { border-color: var(--accent); background: var(--accent-soft); }
.pack-head { display: flex; justify-content: space-between; font-size: 12px; font-weight: 500; color: var(--muted); padding: 0 2px; font-variant-numeric: tabular-nums; }
.pack-list { display: flex; flex-direction: column; gap: 6px; }
.pack-slot { display: flex; align-items: center; gap: 10px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 6px 34px 6px 8px; min-height: 62px; position: relative; }
.pack-slot.asking { border-color: var(--accent); }
.pack-slot.empty { min-height: 40px; justify-content: center; color: var(--muted); font-size: 12.5px; border-style: dashed; background: transparent; padding: 6px 8px; }
.pack-pic { width: 60px; height: 50px; flex: none; border-radius: 8px; background: var(--accent-soft); }
.pack-body { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1; }
.pack-name { display: flex; gap: 6px; align-items: baseline; }
.pack-name b { font-size: 13.5px; }
.pack-sub { font-size: 11.5px; color: var(--muted); }
.pack-q { font-size: 12.5px; color: var(--ink); }
.pack-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.mini { font: inherit; font-size: 12px; font-weight: 500; border: 1px solid var(--line); background: transparent; color: var(--ink); border-radius: 8px; padding: 4px 9px; cursor: pointer; }
.mini.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.pack-x { position: absolute; top: 4px; right: 4px; width: 26px; height: 26px; border-radius: 50%; border: 0; background: transparent; color: var(--muted); font: inherit; font-size: 18px; line-height: 1; cursor: pointer; }
.pack-x:hover:not(:disabled) { background: var(--accent-soft); color: var(--accent); }
.pack-x:disabled { opacity: 0.3; cursor: not-allowed; }
.pack-note { color: var(--accent); font-weight: 600; }
/* reactions */
.reacts { display: flex; flex-direction: column; gap: 8px; }
.react { display: flex; gap: 10px; align-items: flex-start; border: 1px solid var(--line); border-radius: 10px; padding: 8px; }
.react-pv { width: 64px; height: 64px; border-radius: 10px; flex: none; }
.react-info { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.react-info b { font-size: 13.5px; }
.react-when { font-size: 12px; color: var(--muted); }
.react-prompt { font-size: 12px; color: var(--ink); background: var(--bg); border-radius: 8px; padding: 5px 8px; }
.react-seg { display: flex; gap: 4px; margin-top: 3px; flex-wrap: wrap; align-items: center; }
.react-seg button:not(.linkbtn) { font: inherit; font-size: 12px; font-weight: 500; border: 1px solid var(--line); background: transparent; color: var(--ink); border-radius: 8px; padding: 4px 10px; cursor: pointer; }
.react-seg button[aria-pressed="true"] { border-color: var(--ink); background: var(--sel); box-shadow: inset 0 0 0 1px var(--ink); }
.react-seg button:disabled { opacity: 0.45; cursor: not-allowed; }

/* toast */
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 50; max-width: min(92vw, 460px); background: var(--ink); color: var(--panel); padding: 10px 16px; border-radius: 10px; font-size: 14px; box-shadow: 0 10px 30px rgba(0,0,0,0.25); }
.toast.good { background: var(--mint); color: #fff; }
.auth-sent { display: flex; flex-direction: column; gap: 4px; padding: 12px; border: 1px solid var(--line); border-radius: 10px; font-size: 14px; }
.auth-sent span { color: var(--muted); }
a.mini { text-decoration: none; display: inline-block; }
.avail:not(.ok):not(.bad) { color: var(--muted); }
/* player: a published gift site fills the screen */
body.player { min-height: 100dvh; display: grid; place-items: center; overflow: hidden; }
.player header, .player .masthead, .player #home-extras, .player .site-foot, .player #builder, .player .edit-bar, .player .tip, .player #account, .player .bar { display: none !important; }
.player .wrap { max-width: none; width: 100%; padding: 0; }
.player .grid { display: block; }
.player .stage-col { position: static; }
.player .browser { border: 0; border-radius: 0; box-shadow: none; background: transparent; }
.player .stage { width: 100vw; height: 100vh; height: 100dvh; aspect-ratio: auto; margin: 0; box-shadow: none; }
.tt-foot { position: fixed; left: 10px; bottom: 8px; z-index: 5; display: flex; gap: 6px; align-items: center; font-size: 12px; color: rgba(255,255,255,0.85); background: rgba(0,0,0,0.28); padding: 4px 10px; border-radius: 999px; backdrop-filter: blur(4px); }
.tt-foot a, .tt-foot button { color: inherit; text-decoration: none; font: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
.tt-foot b { font-weight: 700; }

body { margin: 0; }

/* renewal terms + removal confirmation */
.terms-text { font-size: 13px; line-height: 1.55; color: var(--ink) !important; background: var(--sel); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.consent { display: flex; gap: 8px; align-items: flex-start; font-size: 13.5px; font-weight: 500; cursor: pointer; }
.consent input { margin-top: 3px; accent-color: var(--accent); }
#remove-go:disabled { opacity: .45; cursor: not-allowed; }
.badge.warn { background: #fff4e5; color: #9a5b00; }

/* ===== tinytada: the ribbon logo sets the palette. Blush-white paper, oxblood ink, Bodoni for the voice, ribbon colours used sparingly ===== */
:root {
  --bg: #fcf9f8; --panel: #ffffff; --ink: #2b1a22; --muted: #74636b; --line: #f0e7e8; --line-strong: #e2d5d7;
  --accent: #c9375b; --accent-ink: #ffffff; --accent-soft: #fcebef; --sel: #f8f2f2; --gold: #b4691a;
  --coral: #e8604f; --rose: #d9466a; --orange: #ee8e3e; --amber: #f2b24f;
  --ribbon: linear-gradient(90deg, #e8604f 0%, #d9466a 42%, #ee8e3e 78%, #f2b24f 100%);
  --check-a: #f3ecec; --check-b: #ffffff;
  --shadow: 0 1px 2px rgba(43,26,34,.05);
  --lift: 0 1px 2px rgba(43,26,34,.04), 0 8px 24px -12px rgba(43,26,34,.16);
  --deep: 0 2px 6px rgba(43,26,34,.06), 0 40px 80px -40px rgba(43,26,34,.45);
  --font-serif: "Bodoni Moda", "Didot", "Bodoni 72", Georgia, serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #161012; --panel: #1f171a; --ink: #f7eff0; --muted: #b19fa5; --line: #31252a; --line-strong: #43343a;
    --accent: #ff7a93; --accent-ink: #161012; --accent-soft: #3a1e27; --sel: #281e22; --gold: #f2b24f;
    --check-a: #31252a; --check-b: #241b1f; --shadow: none; --lift: 0 0 0 1px var(--line); --deep: 0 40px 80px -40px rgba(0,0,0,.7);
  }
}
:root[data-theme="dark"] {
  --bg: #161012; --panel: #1f171a; --ink: #f7eff0; --muted: #b19fa5; --line: #31252a; --line-strong: #43343a;
  --accent: #ff7a93; --accent-ink: #161012; --accent-soft: #3a1e27; --sel: #281e22; --gold: #f2b24f;
  --check-a: #31252a; --check-b: #241b1f; --shadow: none; --lift: 0 0 0 1px var(--line); --deep: 0 40px 80px -40px rgba(0,0,0,.7);
}
body { font-size: 14.5px; }
.wrap { padding-block: 22px 64px; }
header { border-bottom: 0; margin-bottom: 8px; padding-bottom: 10px; }

/* masthead: the one loud thing */
.masthead { padding: 28px 0 34px; max-width: 760px; }
.masthead h1 { font-family: var(--font-serif); font-optical-sizing: auto; font-weight: 500; font-size: clamp(36px, 5.6vw, 68px); line-height: 1.02; letter-spacing: -0.015em; margin: 0 0 14px; text-wrap: balance; color: var(--ink); }
.masthead p { margin: 0; font-size: 16.5px; line-height: 1.55; color: var(--muted); max-width: 52ch; }
@media (max-width: 600px) { .masthead { padding: 14px 0 22px; } .masthead p { font-size: 15px; } }

/* builder panel */
.grid { grid-template-columns: 400px minmax(0, 1fr); gap: 28px; }
@media (max-width: 880px) { .grid { grid-template-columns: 1fr; } }
.panel { border-radius: 20px; padding: 26px; box-shadow: var(--lift); border-color: var(--line); }
.panel > .step + .step, .panel > .step + .checkout { padding-top: 24px; margin-top: 24px; }
.step h2 { font-family: var(--font-serif); font-weight: 500; font-size: 22px; letter-spacing: -0.01em; gap: 12px; margin-bottom: 16px; align-items: baseline; }
.step h2 .n { border: 0; width: auto; height: auto; font-family: var(--font-serif); font-size: 22px; color: var(--gold); font-weight: 400; }
label { font-size: 13px; color: var(--ink); }
.occasions { gap: 6px; margin-bottom: 14px; }
.occasions button { border-radius: 999px; padding: 6px 14px; border-color: var(--line-strong); }
.occasions button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.templates { gap: 10px; }
.tpl { border-radius: 14px; padding: 14px 6px 12px; border-color: var(--line); }
.tpl .ico { border-radius: 50%; width: 40px; height: 40px; }
.tpl[aria-pressed="true"] { background: var(--panel); border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.tpl[aria-pressed="true"] .ico { background: var(--ink); color: var(--bg); }
input[type="text"], .field textarea, input[type="date"], .auth-email input { border-radius: 12px; padding: 10px 13px; border-color: var(--line-strong); box-shadow: none; transition: border-color .15s, box-shadow .15s; }
input[type="text"]:focus, .field textarea:focus, .auth-email input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.addr { border-radius: 12px; box-shadow: none; }
.addr:focus-within { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.addr input:focus { box-shadow: none; }
.sw { border-radius: 50%; width: 34px; height: 34px; }
.sw[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--panel), 0 0 0 3.5px var(--ink); }
.seg { gap: 8px; }
.seg button { border-radius: 14px; padding: 10px 8px; border-color: var(--line-strong); }
.seg button[aria-pressed="true"] { background: var(--panel); border-color: var(--ink); }
.pet-tile, .pack-slot, .react { border-radius: 14px; }
.pack-zone { border-radius: 16px; border-width: 1.5px; }
.upload, .mini { border-radius: 999px; }
.mini { padding: 5px 12px; border-color: var(--line-strong); }
.mini.primary { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.btn { border-radius: 12px; padding: 10px 16px; }
.price { font-family: var(--font-serif); font-weight: 500; font-size: 40px; letter-spacing: -0.01em; }
.price small { font-family: var(--font-ui); display: block; margin-top: 8px; line-height: 1.4; }
.publish { background: var(--ink); color: var(--bg); font-weight: 500; font-size: 15px; letter-spacing: .01em; padding: 13px 26px; border-radius: 14px; box-shadow: 0 1px 0 rgba(255,255,255,.08) inset, 0 10px 24px -10px rgba(43,26,34,.55); transition: transform .15s, box-shadow .15s; }
.publish:hover { filter: none; transform: translateY(-1px); box-shadow: 0 1px 0 rgba(255,255,255,.08) inset, 0 14px 28px -10px rgba(43,26,34,.6); }
.checkout { padding-top: 26px !important; }

/* the preview: framed like the gift it is */
.stage-col { gap: 14px; }
.browser { border-radius: 22px; border-color: var(--line); box-shadow: var(--deep); }
.bar { padding: 12px 16px; gap: 12px; border-bottom-color: var(--line); }
.dots i { width: 9px; height: 9px; background: var(--line-strong); }
.url { border-radius: 999px; padding: 5px 14px; background: var(--sel); font-size: 13px; text-align: center; }
.tip { padding: 0 6px; font-size: 13px; }

/* account button + menu */
.acct-wrap { position: relative; }
.acct { border-radius: 999px; padding: 5px 12px 5px 5px; border-color: var(--line-strong); gap: 8px; }
.acct:not(:has(.av)) { padding: 7px 16px; }
.acct .av { width: 28px; height: 28px; font-size: 12.5px; background: var(--ink); color: var(--bg); font-family: var(--font-serif); font-weight: 600; }
.acct .chev { width: 12px; height: 12px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; color: var(--muted); transition: transform .15s; }
.acct[aria-expanded="true"] .chev { transform: rotate(180deg); }
.acct-menu { position: absolute; right: 0; top: calc(100% + 8px); z-index: 30; min-width: 240px; background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 6px; box-shadow: 0 2px 6px rgba(43,26,34,.06), 0 24px 48px -16px rgba(43,26,34,.3); display: flex; flex-direction: column; }
.am-who { display: flex; flex-direction: column; padding: 10px 12px 12px; margin-bottom: 4px; border-bottom: 1px solid var(--line); }
.am-who b { font-family: var(--font-serif); font-weight: 500; font-size: 18px; }
.am-who span { font-size: 12.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acct-menu [role=menuitem] { font: inherit; font-size: 14px; text-align: left; background: none; border: 0; color: var(--ink); padding: 9px 12px; border-radius: 10px; cursor: pointer; }
.acct-menu [role=menuitem]:hover, .acct-menu [role=menuitem]:focus-visible { background: var(--sel); outline: none; }
.am-sep { height: 1px; background: var(--line); margin: 4px 6px; }
@media (prefers-reduced-motion: reduce) { .acct .chev, .publish { transition: none; } }

/* account pages */
.account { gap: 22px; padding-top: 18px; }
.acct-head h1 { font-family: var(--font-serif); font-weight: 500; font-size: clamp(32px, 4vw, 44px); letter-spacing: -0.015em; }
.acct-head .publish { padding: 11px 20px; }
.acct-tabs { gap: 18px; }
.acct-tabs button { padding: 10px 2px; font-size: 14.5px; }
.site-list { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 20px; }
.site-card { border-radius: 18px; box-shadow: var(--lift); }
.sc-thumb { height: auto; aspect-ratio: 16 / 10; position: relative; overflow: hidden; display: block; border-bottom: 1px solid var(--line); }
.sc-thumb iframe { position: absolute; left: 0; top: 0; width: 1280px; height: 800px; border: 0; transform: scale(var(--s, .25)); transform-origin: 0 0; pointer-events: none; }
.sc-body { padding: 16px 18px 18px; gap: 5px; }
.sc-top b { font-family: var(--font-serif); font-weight: 500; font-size: 20px; letter-spacing: -0.005em; }
.sc-url { font-size: 13.5px; }
.badge { font-weight: 500; padding: 3px 10px; }
.bill-grid { gap: 16px; }
.bill-card { border-radius: 18px; padding: 18px 20px; box-shadow: var(--lift); }
.bc-main { font-family: var(--font-serif); font-weight: 500; font-size: 20px; line-height: 1.25; letter-spacing: -0.005em; }
.table-wrap { border-radius: 18px; box-shadow: var(--lift); }
.acct-table th { font-size: 12.5px; padding: 12px 18px; }
.acct-table td { padding: 14px 18px; }

/* dialogs */
.modal { border-radius: 22px; padding: 28px; box-shadow: var(--deep); }
.modal h3 { font-family: var(--font-serif); font-weight: 500; font-size: 26px; letter-spacing: -0.01em; }
.scrim { background: rgba(43, 26, 34, .42); backdrop-filter: blur(6px); }
.oauth { border-radius: 12px; padding: 11px; }
.toast { border-radius: 14px; }

/* site-card preview pages */
body.is-thumb { cursor: default; }
body.is-thumb .player .stage, body.is-thumb .stage { box-shadow: none; }

/* logo + wordmark */
.logo { gap: 8px; }
.logo img { width: 50px; height: 50px; margin: -6px -2px -6px -6px; }
.logo .wm { font-family: var(--font-serif); font-weight: 600; font-size: 29px; letter-spacing: -0.01em; color: var(--ink); }
.logo .lt, .logo .ld { color: inherit; }

/* the ribbon: tied once around the builder box, once along the top of the preview */
.panel, .browser { position: relative; }
.panel::before, .browser::before { content: ""; position: absolute; inset: -1px; border-radius: inherit; background: var(--ribbon) top / 100% 4px no-repeat; pointer-events: none; z-index: 1; }
.player .browser::before, body.is-thumb .browser::before { display: none; }

/* ===== Style B: rounded type, roomy cards. Palette tokens last so it can be swapped in one place ===== */
:root { --font-serif: "Nunito", "Nunito Fallback", system-ui, sans-serif; --font-ui: "Nunito", "Nunito Fallback", system-ui, -apple-system, "Segoe UI", sans-serif; }
body { font-family: var(--font-ui); font-size: 15px; letter-spacing: 0; }
.masthead h1, .step h2, .price, .logo .wm, .acct-head h1, .sc-top b, .bc-main, .modal h3, .am-who b, .step h2 .n, .home-sec h2, .acct .av { font-family: var(--font-serif); font-weight: 800; letter-spacing: -0.02em; }
.masthead h1 { font-size: clamp(38px, 5.4vw, 64px); line-height: 1.04; }
.step h2 { font-size: 20px; } .step h2 .n { font-size: 20px; }
.logo .wm { font-size: 27px; letter-spacing: -0.025em; }
.price { font-size: 38px; }
.panel, .browser { border-radius: 28px; }
.panel { border-color: transparent; }
.tpl, .seg button, .pet-tile, .pack-slot, .react { border-radius: 18px; }
.site-card, .bill-card, .table-wrap { border-radius: 24px; }

/* header nav */
header { flex-wrap: nowrap; }
.head-nav { display: flex; gap: 4px; margin-left: auto; margin-right: 8px; }
.head-nav a { color: var(--muted); text-decoration: none; font-weight: 600; font-size: 14.5px; padding: 8px 12px; border-radius: 999px; }
.head-nav a:hover { color: var(--ink); background: var(--sel); }
@media (max-width: 920px) { .head-nav { display: none; } }
body:has(#account:not([hidden])) .head-nav { display: none; }

/* home sections */
#home-extras { display: flex; flex-direction: column; gap: 104px; margin-top: 104px; }
.home-sec { scroll-margin-top: 24px; }
.sec-head { max-width: 640px; margin-bottom: 32px; }
.home-sec h2 { font-size: clamp(30px, 3.6vw, 44px); line-height: 1.08; margin: 0 0 12px; color: var(--ink); }
.sec-head p { margin: 0; font-size: 17px; line-height: 1.55; color: var(--muted); }

.game-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
@media (max-width: 1040px) { .game-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .game-grid { gap: 12px; } .gc-body { padding: 12px; } .gc-desc { display: none; } .gc-body b { font-size: 15px; } }
.game-card { font: inherit; color: inherit; text-align: left; padding: 0; border: 0; background: var(--panel); border-radius: 24px; overflow: hidden; cursor: pointer; display: flex; flex-direction: column; box-shadow: var(--lift); transition: transform .2s, box-shadow .2s; }
.game-card:hover { transform: translateY(-3px); box-shadow: 0 2px 6px rgba(0,0,0,.05), 0 24px 40px -20px rgba(0,0,0,.25); }
.game-card:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.game-card img { width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; display: block; }
.gc-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.gc-occ { font-size: 13px; font-weight: 700; color: var(--accent); }
.gc-body b { font-size: 18px; font-weight: 800; letter-spacing: -0.01em; }
.gc-desc { font-size: 14px; color: var(--muted); line-height: 1.45; flex: 1; }
.gc-try { margin-top: 10px; font-size: 14px; font-weight: 700; color: var(--ink); }
.game-card:hover .gc-try { color: var(--accent); }

.how-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
@media (max-width: 800px) { .how-list { grid-template-columns: 1fr; } }
.how-list li { background: var(--panel); border-radius: 24px; padding: 28px; box-shadow: var(--lift); display: flex; flex-direction: column; gap: 8px; }
.how-n { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 20px; background: var(--accent-soft); color: var(--accent); margin-bottom: 8px; }
.how-list b { font-size: 20px; font-weight: 800; }
.how-list p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.55; }

.price-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; max-width: 880px; }
@media (max-width: 700px) { .price-grid { grid-template-columns: 1fr; } }
.price-card { background: var(--panel); border-radius: 28px; padding: 30px; box-shadow: var(--lift); display: flex; flex-direction: column; gap: 6px; border: 2px solid transparent; }
.price-card.feature { border-color: var(--accent); }
.price-card > b { font-size: 18px; font-weight: 800; }
.pc-amt { font-family: var(--font-serif); font-weight: 800; font-size: 44px; letter-spacing: -0.03em; line-height: 1.1; }
.pc-amt small { font-size: 16px; font-weight: 600; color: var(--muted); letter-spacing: 0; }
.pc-eg { margin: 0 0 10px; color: var(--muted); font-size: 14.5px; }
.price-card ul { margin: 0; padding: 14px 0 0; border-top: 1px solid var(--line); list-style: none; display: flex; flex-direction: column; gap: 9px; font-size: 15px; }
.price-card li { padding-left: 26px; position: relative; }
.price-card li::before { content: ""; position: absolute; left: 2px; top: 5px; width: 12px; height: 7px; border-left: 2.5px solid var(--accent); border-bottom: 2.5px solid var(--accent); transform: rotate(-45deg); }
.pc-note { margin: 18px 0 0; color: var(--muted); font-size: 14.5px; }

.about { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 56px; align-items: center; background: var(--panel); border-radius: 32px; padding: 56px; box-shadow: var(--lift); }
@media (max-width: 800px) { .about { grid-template-columns: 1fr; padding: 32px 24px; gap: 20px; } .about-mark { justify-content: flex-start !important; } .about-mark img { width: 96px !important; height: 96px !important; } }
.about-mark { display: flex; justify-content: center; }
.about-mark img { width: 200px; height: 200px; }
.about-copy { max-width: 62ch; }
.about-copy p { margin: 0 0 14px; font-size: 17px; line-height: 1.65; color: var(--ink); }
.about-copy p:last-child { margin-bottom: 0; color: var(--muted); }

.faq-list { display: flex; flex-direction: column; gap: 12px; max-width: 820px; }
.faq-list details { background: var(--panel); border-radius: 20px; box-shadow: var(--lift); }
.faq-list summary { cursor: pointer; list-style: none; padding: 20px 56px 20px 24px; font-weight: 700; font-size: 17px; position: relative; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; position: absolute; right: 24px; top: 50%; transform: translateY(-50%); font-size: 24px; font-weight: 500; color: var(--muted); }
.faq-list details[open] summary::after { content: "\2212"; }
.faq-list summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 20px; }
.faq-list details p { margin: 0; padding: 0 24px 22px; color: var(--muted); font-size: 15.5px; line-height: 1.6; max-width: 70ch; }

.cta { text-align: center; padding: 64px 24px; border-radius: 32px; background: var(--ink); color: var(--bg); position: relative; overflow: hidden; }
.cta::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 6px; background: var(--ribbon); }
.cta h2 { color: inherit; margin-bottom: 10px; }
.cta p { margin: 0 0 24px; font-size: 17px; opacity: .8; }
.cta .publish { background: var(--bg); color: var(--ink); }

.site-foot { max-width: 1240px; margin: 96px auto 0; padding: 40px max(16px, env(safe-area-inset-left, 0px)) 40px; border-top: 1px solid var(--line); }
.sf-in { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; align-items: flex-start; }
.sf-brand p { margin: 8px 0 0; color: var(--muted); font-size: 14.5px; }
.sf-links { display: flex; gap: 22px; flex-wrap: wrap; }
.sf-links a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: 14.5px; }
.sf-links a:hover { color: var(--accent); }
.sf-fine { color: var(--muted); font-size: 13px; margin: 24px 0 0; }
.wrap { padding-bottom: 0; }
@media (prefers-reduced-motion: reduce) { .game-card { transition: none; } .game-card:hover { transform: none; } }

/* palette (swappable) */
:root {
  --bg: #ffffff; --panel: #ffffff; --ink: #1f1a24; --muted: #6b6572; --line: #ece9ef; --line-strong: #dcd8e0;
  --accent: #d9466a; --accent-ink: #ffffff; --accent-soft: #fdecf0; --sel: #f6f5f8; --gold: #d9466a;
  --lift: 0 1px 2px rgba(31,26,36,.05), 0 10px 30px -14px rgba(31,26,36,.18);
}
.panel, .browser { border: 1px solid var(--line); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --bg: #141117; --panel: #1d1921; --ink: #f5f2f7; --muted: #a8a1ae; --line: #2c2731; --line-strong: #3c3642; --accent: #ff7a93; --accent-ink: #141117; --accent-soft: #3a1e29; --sel: #252029; --gold: #ff7a93; --lift: 0 0 0 1px var(--line); } }
:root[data-theme="dark"] { --bg: #141117; --panel: #1d1921; --ink: #f5f2f7; --muted: #a8a1ae; --line: #2c2731; --line-strong: #3c3642; --accent: #ff7a93; --accent-ink: #141117; --accent-soft: #3a1e29; --sel: #252029; --gold: #ff7a93; --lift: 0 0 0 1px var(--line); }

/* card vs website story */
.story-grid { display: grid; grid-template-columns: 150px repeat(4, minmax(0, 1fr)); gap: 16px 18px; align-items: stretch; }
.story-when { font-weight: 800; font-size: 15px; color: var(--muted); padding: 0 4px; align-self: end; }
.story-label { font-weight: 800; font-size: 18px; align-self: center; color: var(--muted); }
.story-label.site { color: var(--accent); }
.st { margin: 0; display: flex; flex-direction: column; gap: 10px; }
.st figcaption { font-size: 14px; line-height: 1.45; color: var(--muted); padding: 0 4px; }
.scene { position: relative; aspect-ratio: 4 / 3; border-radius: 22px; overflow: hidden; display: grid; place-items: center; }
.st-card .scene { background: #f3efe9; }
.st-site .scene { background: var(--accent-soft); }
/* the card fades out over time */
.st-card.s1 { filter: none; } .st-card.s2 { filter: saturate(.55); } .st-card.s3 { filter: saturate(.2) brightness(.97); }
.st-card.s4 .scene { background: #ece9e5; }
.st-card.s2 figcaption, .st-card.s3 figcaption { opacity: .85; } .st-card.s4 figcaption { opacity: .7; }
.gcard { position: absolute; width: 34%; aspect-ratio: 3 / 4; }
.gc-front { position: absolute; inset: 0; border-radius: 4px; background: linear-gradient(160deg, #f2788c, #e8604f 60%, #ee8e3e); box-shadow: 0 6px 14px -6px rgba(60,30,20,.45); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; }
.gc-front svg { width: 40%; fill: #fff; opacity: .95; }
.gc-front i { display: block; width: 50%; height: 3px; border-radius: 2px; background: rgba(255,255,255,.75); }
.gc-front i + i { width: 34%; }
.mantel::after { content: ""; position: absolute; left: 8%; right: 8%; bottom: 22%; height: 8px; border-radius: 3px; background: #b88b63; box-shadow: 0 6px 0 -2px #9b7151; }
.gcard.stand { bottom: 25%; left: 33%; transform: perspective(300px) rotateY(-18deg); }
.gcard.stand::after { content: ""; position: absolute; left: 6%; right: -14%; bottom: -6px; height: 8px; border-radius: 50%; background: rgba(80,50,30,.18); filter: blur(3px); }
.shelf::after { content: ""; position: absolute; left: 0; right: 0; bottom: 26%; height: 10px; background: #a98262; }
.stack-books { position: absolute; left: 12%; bottom: calc(26% + 10px); display: flex; align-items: flex-end; gap: 3px; }
.stack-books i { display: block; width: 14px; border-radius: 2px 2px 0 0; }
.stack-books i:nth-child(1) { height: 70px; background: #7d8a9c; } .stack-books i:nth-child(2) { height: 58px; background: #c9b48e; } .stack-books i:nth-child(3) { height: 76px; background: #8f6f6a; }
.gcard.lean { width: 30%; left: 30%; bottom: calc(26% + 10px); transform-origin: bottom left; transform: rotate(-10deg); }
.mail { position: absolute; bottom: calc(26% + 10px); height: 22%; border-radius: 3px; background: #f7f3ec; border: 1px solid #ddd3c4; z-index: 2; }
.mail.m1 { left: 36%; width: 40%; transform: rotate(-4deg); } .mail.m2 { left: 46%; width: 36%; height: 16%; transform: rotate(3deg); background: #e9eef5; border-color: #cdd6e2; }
.mail::after { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 60%; background: linear-gradient(to bottom right, transparent 49%, #ddd3c4 50%, transparent 52%), linear-gradient(to bottom left, transparent 49%, #ddd3c4 50%, transparent 52%); }
.drawer-box { position: absolute; left: 12%; right: 12%; top: 18%; bottom: 34%; background: #8f6b4e; border-radius: 4px 4px 0 0; overflow: hidden; }
.gcard.tilt { width: 32%; left: 18%; top: 22%; transform: rotate(-14deg); }
.gcard.tilt.t2 { left: 50%; top: 34%; transform: rotate(9deg); }
.gcard.tilt.t2 .gc-front { background: #d9d3c8; }
.drawer-front { position: absolute; left: 8%; right: 8%; bottom: 14%; height: 24%; background: #a98262; border-radius: 4px; display: grid; place-items: center; box-shadow: 0 8px 14px -8px rgba(60,40,20,.5); }
.drawer-front span { width: 22%; height: 8px; border-radius: 4px; background: #6f5038; }
.gone .ghost { width: 34%; aspect-ratio: 3 / 4; border: 2.5px dashed #bdb5aa; border-radius: 6px; display: grid; place-items: center; font-size: 34px; font-weight: 800; color: #bdb5aa; }
/* the site stays bright */
.dev img { display: block; width: 100%; height: 100%; object-fit: cover; }
.dev.phone { width: 70%; aspect-ratio: 19.5 / 9; border-radius: 18px; background: #1b1b1f; padding: 6px 12px; box-shadow: 0 14px 26px -12px rgba(0,0,0,.45); }
.dev.phone img { border-radius: 8px; }
.dev.laptop { width: 72%; display: flex; flex-direction: column; align-items: center; }
.dev.laptop .lid { width: 100%; aspect-ratio: 16 / 10; background: #1b1b1f; border-radius: 10px 10px 0 0; padding: 5px 5px 7px; }
.dev.laptop .lid img { border-radius: 4px; }
.dev.laptop .base { width: 116%; height: 9px; background: #c9c9cf; border-radius: 0 0 10px 10px; }
.pin { position: absolute; right: 7%; top: 9%; background: var(--panel); color: var(--accent); font-weight: 800; font-size: 13px; padding: 5px 11px; border-radius: 999px; box-shadow: var(--lift); }
.anywhere .globe { position: absolute; right: 6%; bottom: 8%; width: 20%; fill: none; stroke: var(--accent); stroke-width: 1.4; background: var(--panel); border-radius: 50%; padding: 6px; box-shadow: var(--lift); }
@media (max-width: 900px) {
  .story-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .story-when { display: none; }
  .story-label { grid-column: 1 / -1; margin-top: 8px; }
}

/* games and gift sites use the brand's rounded face too */
:root { --font-display: "Nunito", "Nunito Fallback", system-ui, sans-serif; }
.headline, .val-q, .val-done, .endcard h2 { font-weight: 900; letter-spacing: -0.01em; }
.hud { font-weight: 800; }
/* overlay text scales with the stage itself, so the builder preview, card previews and the live site all match */
.stage { container-type: inline-size; }
.headline { font-size: clamp(20px, 6.6cqw, 84px); }
.msg { font-size: clamp(12px, 2.3cqw, 26px); font-weight: 700; max-width: 46ch; margin-top: 0.5cqw; }
.hud { font-size: clamp(13px, 2cqw, 22px); }
@container (min-width: 1000px) {
  .val-card { padding: 28px 44px 30px; gap: 14px; }
  .val-pic { height: 160px; } .val-pic img { max-width: 240px; }
  .val-eyebrow { font-size: 13px; }
  .val-q { font-size: 44px; }
  .vbtn { font-size: 20px; padding: 12px 36px; }
}
.home-sec h2, .masthead h1 { text-wrap: balance; }
body.is-thumb .hud { display: none !important; }
body:has(#account:not([hidden])) .site-foot { display: none; }

/* painted scene backgrounds: light scenes get dark text */
.stage.ink-dark .headline { color: #3a2a2e; text-shadow: 0 2px 0 rgba(255,255,255,.55), 0 6px 22px rgba(255,255,255,.5); }
.stage.ink-dark .msg { color: #5a4448; text-shadow: 0 1px 10px rgba(255,255,255,.7); }
.sw.scene { border-radius: 10px; width: 46px; }
.sw.scene[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--panel), 0 0 0 3.5px var(--ink); }
.stage.ink-dark .hud { color: #3a2a2e; text-shadow: 0 1px 8px rgba(255,255,255,.8); }

/* phones: the preview stays pinned at the top while the settings scroll beneath it */
@media (max-width: 880px) {
  body:not(.player) .grid > .stage-col {
    position: sticky; top: 0; z-index: 20; gap: 0;
    margin: 0 -16px; padding: max(8px, env(safe-area-inset-top, 0px)) 16px 10px;
    background: var(--bg); box-shadow: 0 12px 14px -14px rgba(31, 26, 36, .35);
  }
  body:not(.player) .grid > .stage-col .tip { display: none; }
  body:not(.player) .grid > .stage-col .bar { padding: 7px 12px; }
  body:not(.player) .grid > .stage-col .browser { border-radius: 16px; }
  body:not(.player) .grid > .stage-col .browser::before { display: none; }
  body:not(.player) .grid > .stage-col .stage { max-height: 34vh; max-height: 34dvh; width: 100%; }
}

/* text that reads well at every stage size: small previews, phones held either way, big screens */
.headline { font-size: clamp(15px, 6.6cqw, 84px); }
.msg { font-size: clamp(10.5px, 2.3cqw, 26px); }
.hud { font-size: clamp(10.5px, 2cqw, 22px); }
@media (max-aspect-ratio: 1/1) {
  .player .headline { font-size: clamp(28px, 9.5vw, 56px); line-height: 1.08; }
  .player .msg { font-size: clamp(15px, 4.2vw, 22px); max-width: 30ch; }
  .player .hud { font-size: clamp(12px, 3.4vw, 16px); }
}

/* published sites: size the words from the screen's shorter side so big and wide screens get big, readable text */
.player .headline { font-size: clamp(26px, min(6.6vw, 10.5vh), 150px); }
.player .msg { font-size: clamp(14px, min(2.3vw, 3.7vh), 44px); max-width: 46ch; }
.player .hud { font-size: clamp(12px, min(1.6vw, 2.6vh), 24px); }
@media (max-aspect-ratio: 1/1) {
  .player .headline { font-size: clamp(28px, 9.5vw, 64px); }
  .player .msg { font-size: clamp(15px, 4.2vw, 26px); max-width: 30ch; }
}
@container (min-width: 1700px) {
  .val-card { padding: 40px 64px 44px; gap: 18px; }
  .val-pic { height: 230px; } .val-pic img { max-width: 340px; }
  .val-eyebrow { font-size: 17px; }
  .val-q { font-size: 64px; }
  .vbtn { font-size: 28px; padding: 16px 50px; }
}
@media (max-aspect-ratio: 1/1) and (min-width: 700px) {
  .player .val-pic { height: 200px; } .player .val-pic img { max-width: 300px; }
  .player .val-q { font-size: 44px; } .player .val-card { padding: 32px 44px 36px; }
  .player .vbtn { font-size: 24px; padding: 14px 44px; }
}

/* the builder's small preview on phones: keep the valentine card inside the frame */
@container (max-width: 520px) {
  body:not(.player) .val-card { padding: 10px 16px 12px; gap: 5px; }
  body:not(.player) .val-pic { height: 64px; } body:not(.player) .val-pic img { max-width: 100px; }
  body:not(.player) .val-eyebrow { font-size: 9px; }
  body:not(.player) .val-q { font-size: 16px; }
  body:not(.player) .vbtn { font-size: 13px; padding: 6px 18px; }
}
/* home page story: phones are shown upright, the way gifts are opened */
.dev.phone { width: 30%; height: auto; aspect-ratio: 9 / 19.5; padding: 4px; border-radius: 16px; }
.dev.phone img { border-radius: 13px; object-position: 50% 50%; }

/* background picker: painted scenes and plain colours, each on an even grid */
.sw-group { display: flex; flex-direction: column; gap: 8px; margin-bottom: 14px; }
.sw-label { font-size: 13px; font-weight: 700; color: var(--muted); }
.swatches.scenes { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 10px; }
.swatches.scenes .sw.scene { width: 100%; height: auto; aspect-ratio: 16 / 10; border-radius: 12px; border: 1px solid var(--line); }
.swatches.colours { display: grid; grid-template-columns: repeat(5, 40px); justify-content: space-between; row-gap: 12px; }
.swatches.colours .sw { width: 40px; height: 40px; border-radius: 50%; }
@media (max-width: 880px) { .swatches.colours { grid-template-columns: repeat(5, 46px); } .swatches.colours .sw { width: 46px; height: 46px; } }

/* iPhone Safari zooms into any text box under 16px and leaves the page zoomed and shifted; keep them at 16px on touch screens */
@media (hover: none), (max-width: 880px) {
  input, textarea, select, .addr input, .auth-email input, .field textarea { font-size: 16px !important; }
}
/* nothing may push the page sideways */
html, body { overflow-x: clip; }

/* ===== under construction ===== */
.building { position: fixed; inset: 0; z-index: 200; overflow-y: auto; background: radial-gradient(1100px 600px at 50% -10%, #fff1e8 0%, transparent 70%), radial-gradient(900px 500px at 100% 100%, #fde7ee 0%, transparent 60%), var(--bg); display: flex; align-items: center; justify-content: center; padding: 32px 20px max(32px, env(safe-area-inset-bottom)); }
.bld-in { width: min(640px, 100%); text-align: center; display: flex; flex-direction: column; align-items: center; }
.bld-scene { width: min(520px, 100%); }
.bld-scene svg { width: 100%; height: auto; display: block; overflow: visible; }
.bld-title { font-family: var(--font-serif); font-weight: 800; letter-spacing: -0.02em; font-size: clamp(28px, 5vw, 44px); line-height: 1.08; margin: 10px 0 12px; text-wrap: balance; color: var(--ink); }
.bld-text { margin: 0; max-width: 48ch; font-size: clamp(15.5px, 2.2vw, 18px); line-height: 1.55; color: var(--muted); text-wrap: pretty; }
.bld-addr { margin-top: 18px; display: inline-flex; align-items: center; gap: 10px; max-width: 100%; background: var(--panel); border: 1px solid var(--line); border-radius: 999px; padding: 6px 6px 6px 18px; box-shadow: var(--lift); }
.bld-addr span { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bld-status { margin: 22px 0 0; display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 15px; color: var(--ink); }
.bld-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); animation: bldPulse 1.2s ease-in-out infinite; }
.bld-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; margin-top: 22px; }
.bld-small { margin: 18px 0 0; font-size: 13.5px; color: var(--muted); }
@keyframes bldPulse { 0%, 100% { transform: scale(.7); opacity: .5; } 50% { transform: scale(1.15); opacity: 1; } }
.building .hook { animation: bldHook 4.2s ease-in-out infinite; }
.building .trolley { animation: bldTrolley 8.4s ease-in-out infinite; }
@keyframes bldHook { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(26px); } }
@keyframes bldTrolley { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(-60px); } }
.building .hat { animation: bldHat 1.8s ease-in-out infinite; transform-box: fill-box; }
@keyframes bldHat { 0%, 100% { translate: 0 0; } 50% { translate: 0 -6px; } }
.building .bar { animation: bldBar 6s ease-in-out infinite; }
@keyframes bldBar { 0% { width: 0; } 70%, 100% { width: 256px; } }
.building .draw-heart { stroke-dasharray: 100; animation: bldDraw 3.2s ease-in-out infinite; }
@keyframes bldDraw { 0% { stroke-dashoffset: 100; } 60%, 100% { stroke-dashoffset: 0; } }
.building .blk { animation: bldShimmer 2.4s ease-in-out infinite; }
.building .blk.b2 { animation-delay: .4s; } .building .blk.b3 { animation-delay: .8s; }
@keyframes bldShimmer { 0%, 100% { opacity: .45; } 50% { opacity: 1; } }
.building .cone { animation: bldCone 2.6s ease-in-out infinite; transform-box: fill-box; transform-origin: 50% 100%; }
@keyframes bldCone { 0%, 100% { rotate: -2deg; } 50% { rotate: 2deg; } }
.building .spk { transform-box: fill-box; transform-origin: center; animation: bldSpk 1.6s ease-in-out infinite; }
.building .spk.s2 { animation-delay: .5s; } .building .spk.s3 { animation-delay: 1s; }
@keyframes bldSpk { 0%, 100% { scale: .4; opacity: .3; } 50% { scale: 1.2; opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .building *, .building *::before { animation: none !important; } .building .bar { width: 180px; } .building .draw-heart { stroke-dashoffset: 0; } }
@media (max-width: 520px) { .bld-actions .btn { flex: 1 1 100%; } .building { align-items: flex-start; padding-top: 24px; } }
.building .bld-alt { background: var(--panel); color: var(--ink); border: 1.5px solid var(--line-strong); box-shadow: none; }
.building .bld-alt:hover { border-color: var(--ink); }
.browser .url:empty::before { content: "\200b"; } /* keeps the address bar its full height before the address is filled in (no layout shift) */
/* Phones: the headline breaks after the comma, never inside "made for one person." */
@media (max-width: 520px) { .masthead h1 { font-size: clamp(26px, 8.2vw, 40px); } .masthead h1 .nw { white-space: nowrap; } }

/* Touch screens: every button in the builder is at least 44px to tap (Apple's guideline) */
@media (hover: none), (max-width: 880px) {
  .mini, .react-seg button:not(.linkbtn) { min-height: 44px; padding: 8px 14px; font-size: 14px; }
  .pack-x { width: 44px; height: 44px; top: -4px; right: -4px; font-size: 22px; }
  #pack-sample, .react-seg .linkbtn { min-height: 44px; padding: 8px 6px; font-size: 14px; }
}

/* Naughty or Nice: "Scan again" sits at the top of the readout panel (positioned by the game), clear of the gauge */
.stage .replay.replay-panel { bottom: auto; transform: translateX(-50%); font-size: clamp(11px, 2.2cqw, 15px); padding: 0.45em 1.2em; min-height: 0; white-space: nowrap; }

/* No Exam: Verify and "Or just say yes" side by side; on small previews the captcha sits beside the question so it all fits */
.exam-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; align-items: center; }
@container (max-width: 760px) {
  body:not(.player) .val-card.exam { padding: 10px 14px; gap: 5px; max-width: 96%; }
  body:not(.player) .val-card.exam.has-grid { display: grid; grid-template-columns: auto 1fr; column-gap: 14px; row-gap: 5px; align-items: center; text-align: left; }
  body:not(.player) .exam.has-grid > .exam-grid { grid-column: 1; grid-row: 1 / span 6; width: min(150px, 30cqw); }
  body:not(.player) .exam.has-grid > :not(.exam-grid) { grid-column: 2; }
  body:not(.player) .exam.has-grid .exam-actions { justify-content: flex-start; }
  body:not(.player) .exam.has-grid .exam-sub { display: none; }
  body:not(.player) .exam-grid button { font-size: 18px; }
  body:not(.player) .exam-q { font-size: 14px; }
  body:not(.player) .exam-opts button { font-size: 13px; padding: 6px; }
  body:not(.player) .exam-verify, body:not(.player) .exam-yes { font-size: 13px; padding: 6px 14px; }
}

/* staging.tinytada.com only */
.stage-ribbon { position: fixed; left: 12px; bottom: 12px; z-index: 50; background: #2a1630; color: #fff; font-size: 12px; font-weight: 700; padding: 6px 12px; border-radius: 999px; opacity: 0.88; pointer-events: none; }
