/* Rec Yourself, product page: hero, A/B player, configurator drawer, human help.
   Uses tokens.css only (orange accent on black). */

/* Components below set display:grid/flex, which would beat the [hidden] attribute. */
[hidden] { display: none !important; }

/* ---------- Draft markers (remove at launch) ---------- */
.draft-banner {
  background: var(--color-surface-2); color: var(--color-text-muted);
  font-family: var(--font-mono); font-size: var(--text-xs); text-align: center;
  padding: var(--space-2) var(--gutter); border-bottom: 1px dashed var(--color-border-strong);
}
.tbd { outline: 1px dashed var(--color-accent); outline-offset: 3px; border-radius: 3px; color: var(--color-text-muted); }

.btn--block { width: 100%; justify-content: center; }
.btn[disabled] { opacity: 0.4; cursor: not-allowed; transform: none; box-shadow: none; }

/* ---------- Product hero ---------- */
.product { padding-block: var(--space-7) var(--space-8); position: relative; overflow: hidden; isolation: isolate; }
.product::before {
  content: ""; position: absolute; z-index: -1; width: 60vmax; height: 60vmax; left: -25vmax; top: -15vmax;
  background: radial-gradient(circle, var(--color-accent-glow) 0%, transparent 60%); opacity: 0.4; filter: blur(40px);
}
.product__grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-7); align-items: start; }
@media (max-width: 920px) { .product__grid { grid-template-columns: 1fr; gap: var(--space-6); } }
.product__visual { position: sticky; top: calc(64px + var(--space-4)); }
@media (max-width: 920px) { .product__visual { position: relative; top: 0; } }
.product__macro { display: grid; justify-items: center; gap: var(--space-3); padding-block: var(--space-5); }
.knob--big { width: min(200px, 50vw); }
.product__shot-note { font-size: var(--text-xs); text-align: center; padding: var(--space-2); }
.product__info { display: grid; gap: var(--space-4); }
.product__title { font-size: var(--text-3xl); line-height: 1.05; }
.product__price { display: flex; align-items: baseline; gap: var(--space-3); flex-wrap: wrap; font-family: var(--font-display); font-size: var(--text-xl); }
.product__price .muted { font-family: var(--font-body); font-size: var(--text-sm); }
.product__actions { display: grid; gap: var(--space-3); }
.guarantee { font-size: var(--text-sm); color: var(--color-accent); text-align: center; }

.perks { list-style: none; margin: 0; padding: 0; border: 1px solid var(--color-border); border-radius: var(--radius-md); background: var(--color-surface); }
.perks li { display: flex; gap: var(--space-3); padding: var(--space-3) var(--space-4); align-items: center; }
.perks li + li { border-top: 1px solid var(--color-border); }
.perks__icon {
  flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center;
  background: var(--color-accent-soft); color: var(--color-accent); font-family: var(--font-mono); font-size: var(--text-xs); font-weight: var(--weight-bold);
}
.perks strong { display: block; font-weight: var(--weight-medium); }
.perks span:not(.perks__icon) { display: block; font-size: var(--text-sm); color: var(--color-text-muted); }

/* ---------- Human help ---------- */
.human {
  display: flex; gap: var(--space-4); align-items: flex-start; padding: var(--space-4);
  border: 1px solid var(--color-border); border-radius: var(--radius-md); background: var(--color-surface);
}
.human__avatar {
  position: relative; flex: none; width: 56px; height: 56px; border-radius: 50%;
  background: linear-gradient(135deg, var(--color-accent), #6b1a03); display: grid; place-items: center;
  font-family: var(--font-display); font-size: var(--text-sm); color: var(--color-on-accent);
}
.human__online { position: absolute; right: 0; bottom: 0; width: 14px; height: 14px; border-radius: 50%; background: var(--color-success); border: 3px solid var(--color-surface); }
.human__body { display: grid; gap: var(--space-2); justify-items: start; }
.human__body p { color: var(--color-text-muted); font-size: var(--text-sm); }
.human__hours { font-size: var(--text-xs); }
.human--compact { margin-top: var(--space-5); }

/* ---------- A/B player ---------- */
.ab {
  --ab-on: var(--color-accent); --ab-off: var(--color-surface-3);
  display: grid; grid-template-columns: 280px 1fr; border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-lg); background: var(--color-surface); overflow: hidden; outline: none;
}
.ab[data-side="sans"] { --ab-on: var(--color-text-muted); }
@media (max-width: 760px) { .ab { grid-template-columns: 1fr; } }
.ab__tracks { list-style: none; margin: 0; padding: var(--space-3); display: grid; gap: var(--space-1); border-right: 1px solid var(--color-border); align-content: start; }
@media (max-width: 760px) { .ab__tracks { border-right: 0; border-bottom: 1px solid var(--color-border); } }
.ab__tracks button {
  width: 100%; display: flex; align-items: center; gap: var(--space-3); text-align: left;
  background: none; border: 1px solid transparent; border-radius: var(--radius-sm); padding: var(--space-3); cursor: pointer;
}
.ab__tracks button:hover { background: var(--color-surface-2); }
.ab__tracks button[aria-current="true"] { background: var(--color-surface-2); border-color: var(--color-border-strong); }
.ab__tracks em { margin-left: auto; font-style: normal; font-size: var(--text-xs); color: var(--color-text-dim); }
.ab__num { font-family: var(--font-mono); font-size: var(--text-xs); color: var(--color-accent); }
.ab__deck { padding: var(--space-5); display: grid; gap: var(--space-4); }
.ab__row { display: flex; align-items: center; gap: var(--space-4); flex-wrap: wrap; }
.ab__play {
  width: 64px; height: 64px; border-radius: 50%; border: 0; cursor: pointer; display: grid; place-items: center;
  background: var(--color-accent); color: var(--color-on-accent); transition: transform var(--duration-fast);
}
.ab__play:active { transform: scale(0.94); }
.ab__play svg { width: 26px; height: 26px; fill: currentColor; }
.ab .i-pause, .ab.is-playing .i-play { display: none; }
.ab.is-playing .i-pause { display: block; }
.ab__switch { display: inline-flex; padding: 4px; border-radius: var(--radius-pill); background: var(--color-surface-3); }
.ab__switch button {
  min-width: 92px; min-height: 44px; border: 0; border-radius: var(--radius-pill); background: none; cursor: pointer;
  font-family: var(--font-display); font-size: var(--text-sm); color: var(--color-text-muted);
  transition: background var(--duration-base) var(--ease-out), color var(--duration-base);
}
.ab__switch button[aria-pressed="true"] { background: var(--color-text); color: var(--color-bg); }
.ab__switch button[data-ab-side="avec"][aria-pressed="true"] { background: var(--color-accent); color: var(--color-on-accent); }
.ab__time { margin-left: auto; font-family: var(--font-mono); font-size: var(--text-sm); color: var(--color-text-muted); }
.ab__wave { width: 100%; height: 96px; cursor: pointer; }
.ab__foot { display: flex; gap: var(--space-4); align-items: center; flex-wrap: wrap; font-size: var(--text-sm); }
.ab__match { display: inline-flex; gap: var(--space-2); align-items: center; cursor: pointer; }
.ab__match input { accent-color: var(--color-accent); width: 16px; height: 16px; }
kbd { font-family: var(--font-mono); font-size: var(--text-xs); padding: 1px 6px; border: 1px solid var(--color-border-strong); border-radius: 4px; }
.ab__status > span { display: none; }
.ab.is-loading .ab__loading { display: inline; color: var(--color-text-muted); }
.ab.is-error .ab__error { display: inline; color: var(--color-error); }

/* ---------- FAQ ---------- */
.faq-wrap { display: grid; grid-template-columns: 1fr 1.4fr; gap: var(--space-6); }
@media (max-width: 880px) { .faq-wrap { grid-template-columns: 1fr; } }
.faq { display: grid; gap: var(--space-2); }
.faq details { border: 1px solid var(--color-border); border-radius: var(--radius-sm); background: var(--color-surface); }
.faq summary {
  cursor: pointer; padding: var(--space-3) var(--space-4); font-weight: var(--weight-medium); list-style: none;
  display: flex; justify-content: space-between; gap: var(--space-3);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--color-accent); font-family: var(--font-mono); }
.faq details[open] summary::after { content: "−"; }
.faq details p { padding: 0 var(--space-4) var(--space-4); color: var(--color-text-muted); font-size: var(--text-sm); }
.faq__title { color: var(--color-text-muted); margin-bottom: var(--space-1); }
.faq__title strong { color: var(--color-text); font-weight: var(--weight-medium); }

/* ---------- Configurator drawer ---------- */
html.drawer-open { overflow: hidden; }
.drawer { position: fixed; inset: 0; z-index: 100; }
.drawer__overlay { position: absolute; inset: 0; background: rgba(0, 0, 0, 0.7); opacity: 0; transition: opacity var(--duration-base); }
.drawer__panel {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(480px, 100vw); overflow-y: auto; outline: none;
  background: var(--color-surface); border-left: 1px solid var(--color-border-strong);
  transform: translateX(100%); transition: transform var(--duration-base) var(--ease-out);
  display: flex; flex-direction: column;
}
.drawer.is-open .drawer__overlay { opacity: 1; }
.drawer.is-open .drawer__panel { transform: none; }
.drawer__head, .drawer__progress { flex: none; }
.drawer__head { display: flex; justify-content: space-between; align-items: center; padding: var(--space-5) var(--space-5) var(--space-3); }
.drawer__head h2 { font-size: var(--text-xl); }
.drawer__close {
  width: 40px; height: 40px; border-radius: var(--radius-sm); border: 1px solid var(--color-border-strong);
  background: var(--color-surface-2); cursor: pointer; font-size: 1.4rem; line-height: 1;
}
.drawer__progress { margin: 0 var(--space-5); height: 4px; border-radius: 2px; background: var(--color-surface-3); overflow: hidden; }
.drawer__progress span { display: block; height: 100%; background: var(--color-accent); transition: width var(--duration-base) var(--ease-out); }
.drawer__body { padding: var(--space-5); display: grid; gap: var(--space-4); }

.step { border: 0; margin: 0; padding: 0; display: grid; gap: var(--space-3); }
.step legend, .step__legend { font-size: var(--text-lg); margin-bottom: var(--space-3); padding: 0; }
.step legend span, .step__legend span { color: var(--color-text-muted); }
.choice { display: block; cursor: pointer; }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice__body {
  display: grid; gap: var(--space-2); padding: var(--space-4); border-radius: var(--radius-md);
  border: 1px solid var(--color-border-strong); background: var(--color-surface-2);
  transition: border-color var(--duration-fast), box-shadow var(--duration-fast);
}
.choice:hover .choice__body { border-color: var(--color-text-dim); }
.choice input:checked + .choice__body { border-color: var(--color-accent); box-shadow: var(--shadow-glow); }
.choice input:focus-visible + .choice__body { outline: 2px solid var(--color-accent); outline-offset: 2px; }
.choice__top { display: flex; justify-content: space-between; gap: var(--space-3); align-items: baseline; }
.choice__top strong { font-weight: var(--weight-medium); }
.choice__top strong::before {
  content: ""; display: inline-block; width: 14px; height: 14px; margin-right: var(--space-2); vertical-align: -1px;
  border-radius: 50%; border: 2px solid var(--color-text-dim);
}
.choice input:checked + .choice__body .choice__top strong::before { border-color: var(--color-accent); background: radial-gradient(circle, var(--color-accent) 40%, transparent 45%); }
.choice__price { font-family: var(--font-mono); font-size: var(--text-sm); color: var(--color-accent); white-space: nowrap; }
.choice__desc { font-size: var(--text-sm); color: var(--color-text-muted); }
.choice__list { display: grid; gap: var(--space-1); margin-top: var(--space-2); font-size: var(--text-sm); }
.choice__list span::before { content: "✓ "; color: var(--color-accent); }

.drawer__nav { display: grid; gap: var(--space-2); }
.summary { border: 1px solid var(--color-border-strong); border-radius: var(--radius-md); background: var(--color-surface-2); padding: var(--space-2) var(--space-4); margin-bottom: var(--space-3); }
.summary__row { display: flex; justify-content: space-between; gap: var(--space-3); padding: var(--space-3) 0; font-size: var(--text-sm); }
.summary__row + .summary__row { border-top: 1px solid var(--color-border); }
.summary__row span { color: var(--color-text-muted); }
.summary__row strong { font-weight: var(--weight-medium); text-align: right; }
.summary__detail { font-size: var(--text-xs); margin-top: calc(-1 * var(--space-2)); padding-bottom: var(--space-2); }
.summary__total strong { font-family: var(--font-display); color: var(--color-accent); }
.ok { color: var(--color-success); }
.drawer__faq { margin-top: var(--space-4); }

@media (prefers-reduced-motion: reduce) {
  .drawer__panel, .drawer__overlay { transition: none; }
}

/* ---------- Plugin in action (videos) ---------- */
.demo { display: grid; gap: var(--space-4); }
.demo__tabs { display: inline-flex; justify-self: start; padding: 4px; border-radius: var(--radius-pill); background: var(--color-surface-3); }
.demo__tabs button {
  min-height: 40px; padding: 0 var(--space-4); border: 0; border-radius: var(--radius-pill); background: none; cursor: pointer;
  font-size: var(--text-sm); color: var(--color-text-muted);
}
.demo__tabs button[aria-selected="true"] { background: var(--color-text); color: var(--color-bg); }
.demo__screen {
  position: relative; border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 740 / 880;
  max-height: 80vh; margin-inline: auto; width: 100%;
  border: 1px solid var(--color-border-strong); background: var(--color-surface); box-shadow: 0 30px 80px -40px var(--color-accent-glow);
  display: grid; place-items: center;
}
.demo__screen video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.demo__fallback { font-size: var(--text-sm); padding: var(--space-3); }
.demo.has-video .demo__fallback { display: none; }

/* ---------- Benefit cards (4) ---------- */
.cards--4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 1000px) { .cards--4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .cards--4 { grid-template-columns: 1fr; } }

/* ---------- Creator ---------- */
.creator { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: var(--space-7); align-items: center; }
@media (max-width: 920px) { .creator { grid-template-columns: 1fr; gap: var(--space-5); } }
.creator__photo {
  aspect-ratio: 4 / 5; border-radius: var(--radius-lg); display: grid; place-items: center; text-align: center;
  background: radial-gradient(circle at 30% 20%, var(--color-accent-soft), transparent 60%), var(--color-surface-2);
  border: 1px solid var(--color-border-strong); font-size: var(--text-sm); background-size: cover; background-position: center;
}
.creator__body { display: grid; gap: var(--space-4); }
.creator__body strong { color: var(--color-text); font-weight: var(--weight-medium); }
.stats--4 { grid-template-columns: repeat(2, 1fr); border: 1px solid var(--color-border); border-radius: var(--radius-md); }
.stats--4 .stat + .stat { border-left: 0; }
.stats--4 .stat:nth-child(even) { border-left: 1px solid var(--color-border); }
.stats--4 .stat:nth-child(n+3) { border-top: 1px solid var(--color-border); }
.stats--4 .stat { padding: var(--space-4); }

/* ---------- Success story ---------- */
.story { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: var(--space-7); align-items: center; }
@media (max-width: 920px) { .story { grid-template-columns: 1fr; gap: var(--space-5); } }
.story__body { display: grid; gap: var(--space-4); justify-items: start; }
.story__quote { margin: 0; padding-left: var(--space-4); border-left: 3px solid var(--color-accent); display: grid; gap: var(--space-2); }
.story__quote p { font-size: var(--text-lg); }
.story__quote cite { font-style: normal; font-size: var(--text-sm); color: var(--color-text-muted); }
.story__tracks { display: grid; gap: var(--space-2); }
.track {
  display: grid; grid-template-columns: auto 1fr auto; gap: var(--space-3); align-items: center;
  padding: var(--space-3) var(--space-4); border-radius: var(--radius-md); border: 1px solid var(--color-border); background: var(--color-surface);
}
.track__num { font-family: var(--font-mono); font-size: var(--text-xs); color: var(--color-accent); }
.track__plays { font-family: var(--font-mono); font-size: var(--text-sm); color: var(--color-accent); }
.story__src { font-size: var(--text-xs); }

/* ---------- Reviews ---------- */
.reviews { display: grid; gap: var(--space-3); justify-items: center; text-align: center; }
.reviews__box { display: grid; gap: var(--space-3); justify-items: center; width: min(100%, 420px); margin-top: var(--space-3); }
.reviews__box a { color: var(--color-accent); }
.reviews__note { font-size: var(--text-xs); }

/* Final CTA visual: no sticky */
.product__visual--static { position: relative; }

/* Real plugin capture (hero and final CTA) */
.product__shot { margin: 0; border-radius: var(--radius-md); overflow: hidden; border: 1px solid var(--color-border-strong); box-shadow: 0 30px 80px -40px var(--color-accent-glow); align-self: center; }
.product__shot img { width: 100%; height: auto; }
.demo[data-view="face"] .demo__screen { aspect-ratio: 1480 / 860; }
.demo .demo__screen { aspect-ratio: 1480 / 1820; max-height: 90vh; }

/* ---------- Origin (creator + MLVSong) ---------- */
.origin { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: var(--space-7); align-items: start; }
@media (max-width: 920px) { .origin { grid-template-columns: 1fr; gap: var(--space-5); } }
.origin__side { display: grid; gap: var(--space-3); position: sticky; top: calc(64px + var(--space-4)); }
@media (max-width: 920px) { .origin__side { position: relative; top: 0; } }
.origin__side .creator__photo { aspect-ratio: 4 / 3; }
.origin__caption { font-size: var(--text-sm); color: var(--color-text-muted); }
.origin__caption strong { color: var(--color-text); font-weight: var(--weight-medium); }
.origin__body { display: grid; gap: var(--space-4); }
.origin__story { display: grid; gap: var(--space-3); font-size: var(--text-lg); color: var(--color-text-muted); max-width: 40rem; }
.origin__story strong { color: var(--color-text); font-weight: var(--weight-medium); }
.origin__story em { font-style: normal; color: var(--color-text); }
.origin__sign { font-family: var(--font-mono); font-size: var(--text-sm); color: var(--color-accent); }
[data-counter] { font-variant-numeric: tabular-nums; display: inline-block; }
/* Odometer: each digit is a wheel, the window shows exactly one digit, the strip slides. */
.odo { display: inline-flex; align-items: flex-start; line-height: 1.15; }
.odo__col { display: inline-block; height: 1.15em; overflow: hidden; position: relative;
  -webkit-mask-image: linear-gradient(transparent, #000 22%, #000 78%, transparent);
  mask-image: linear-gradient(transparent, #000 22%, #000 78%, transparent); }
.odo__strip { display: flex; flex-direction: column; will-change: transform; }
.odo__strip span { height: 1.15em; text-align: center; }
.odo__sep { display: inline-block; width: 0.25em; }

.product__grid > .product__visual { align-self: start; margin-top: var(--space-8); }
@media (max-width: 920px) { .product__grid > .product__visual { margin-top: 0; } }

.creator__photo--img { margin: 0; padding: 0; overflow: hidden; }
.creator__photo--img img { width: 100%; height: 100%; object-fit: cover; object-position: 62% 35%; }

/* Teaser (before launch): blurred visuals with a badge on top */
.is-veiled { position: relative; overflow: hidden; }
.veil-badge {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  padding: var(--space-2, .5rem) var(--space-4, 1rem);
  border: 1px solid var(--color-accent); border-radius: 999px;
  background: rgba(5, 5, 5, .72); color: var(--color-text, #fff);
  font-family: "JetBrains Mono", monospace; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase;
  white-space: nowrap; pointer-events: none; z-index: 2;
}
