/* =====================================================================
   DEM-Osc v2 — the free-synth ad landing page, mobile-first, on the Hook / Pro-Osc system.
   Tokens first, then one block per section, each marked
   ---------- name ----------  in a block comment so you can grep for it.
   Osc's world: paper and ink, Courier Prime for the voice of the machines,
   Source Serif for the human voice, one accent per synth (--acc). Swap --acc
   and the name and this stylesheet serves every instrument in the collection.
   ===================================================================== */

:root {
  --bg: #f0e8d7;  --card: #f7f1e4;  --panel: #e9dfc9;  --line: #dccfb6;   /* one step lighter than demosc's #ece2d0; warmer than Hook's #F6EFE4, so the two read as siblings */
  --ink: #17120c;  --ink-soft: #6d6353;  --ink-faint: rgba(23,18,12,.34);
  --acc: #7a3ff2;  --acc-deep: #6432d0;  --on-acc: #f7f3ea;  --acc-soft: rgba(122,63,242,.14);
  --pink: #d85fa6;  --shadow: rgba(23,18,12,.55);
  --mono: "Courier Prime", "Courier New", ui-monospace, Menlo, monospace;
  --serif: "Source Serif 4", "Iowan Old Style", Georgia, serif;
  --sans: Nunito, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --nav-h: 64px;  --vh: 100vh;  --sec: clamp(72px, 10vw, 128px);
  --ease: cubic-bezier(.22,.61,.36,1);
}

/* ---------- base ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: auto; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--serif); font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased; transition: background-color .9s ease, color .9s ease; }
body.embedded { position: relative; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 clamp(18px, 4vw, 44px); }
.wrap.narrow { max-width: 760px; }
section { padding: var(--sec) 0; scroll-margin-top: calc(var(--nav-h) + 12px); }
:focus-visible { outline: 2px solid var(--acc); outline-offset: 3px; }

/* ---------- type ---------- */
h1, h2, h3 { font-family: var(--mono); font-weight: 700; letter-spacing: -.01em; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(56px, 8.4vw, 112px); line-height: .95; color: var(--acc); white-space: nowrap; }
h2 { font-size: clamp(30px, 4.4vw, 54px); line-height: 1.05; }
h3 { font-size: 1.18rem; line-height: 1.25; }
.micro { font-family: var(--mono); font-size: .76rem; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-soft); margin: 0 0 .9rem; display: flex; align-items: center; gap: .6em; }
.micro::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--acc); flex: 0 0 auto; }
.sec-head { max-width: 40em; margin-bottom: clamp(28px, 4vw, 48px); }
.sec-head .sub { color: var(--ink-soft); font-size: 1.12rem; margin: .9rem 0 0; max-width: 34em; }
.tagline { font-family: var(--mono); font-style: italic; color: var(--acc-deep); font-size: clamp(17px, 1.8vw, 21px); margin: 1rem 0 0; }
.lede { font-size: clamp(17px, 1.5vw, 19px); max-width: 34em; margin: 1.1rem 0 0; }
.fine { font-family: var(--mono); font-size: .8rem; color: var(--ink-soft); margin: .9rem 0 0; }
.fine a { color: var(--acc-deep); }
.hint { font-family: var(--mono); font-size: .82rem; color: var(--ink-soft); margin: 1.2rem 0 0; }
.hint a { color: var(--acc-deep); }

/* buttons: one accent, spent on the action */
.btn { display: inline-flex; align-items: center; gap: .5em; font-family: var(--mono); font-weight: 700; font-size: .98rem; color: var(--on-acc); background: var(--acc); border: 0; border-radius: 999px; padding: .85em 1.45em; text-decoration: none; cursor: pointer; transition: transform .2s var(--ease), background-color .2s; box-shadow: 0 10px 24px -14px var(--acc-deep); }
.btn:hover { transform: translateY(-1px); background: var(--acc-deep); }
.btn.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn.ghost:hover { background: var(--card); }
.btn.small { font-size: .86rem; padding: .7em 1.1em; margin-top: 1rem; }
.play-ico { width: 0; height: 0; border-style: solid; border-width: .34em 0 .34em .58em; border-color: transparent transparent transparent currentColor; }
.price { font-family: var(--mono); font-weight: 700; font-size: 2rem; letter-spacing: -.02em; }
.buy-row { display: flex; align-items: center; flex-wrap: wrap; gap: .9rem 1.1rem; margin-top: 1.6rem; }

/* ---------- nav: follows the page ---------- */
.nav { position: sticky; top: 0; z-index: 50; height: var(--nav-h); background: color-mix(in srgb, var(--bg) 82%, transparent); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border-bottom: 1px solid transparent; transform: translateZ(0); transition: border-color .4s ease, background-color .9s ease, box-shadow .4s ease; }
.nav.scrolled { border-bottom-color: var(--line); box-shadow: 0 8px 30px -22px var(--shadow); }
.nav:not(.embedded) { transition: opacity .35s var(--ease), transform .35s var(--ease), border-color .4s ease, box-shadow .4s ease; }
.nav:not(.embedded):not(.scrolled) { opacity: 0; transform: translateY(-8px) translateZ(0); pointer-events: none; }   /* at the top the C&K bar is the menu; ours arrives on scroll */
.nav-in { height: 100%; display: flex; align-items: center; gap: 1.6rem; }
.brand { display: inline-flex; align-items: baseline; gap: .7rem; text-decoration: none; }
.brand b { font-family: var(--mono); font-weight: 700; font-size: 1.1rem; color: var(--acc); }
.brand .tag { font-family: var(--mono); font-size: .74rem; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); }
.nav-links { margin-left: auto; display: flex; gap: 1.5rem; }
.nav-links a { font-family: var(--sans); font-weight: 700; font-size: .9rem; color: var(--ink-soft); text-decoration: none; }
.nav-links a:hover { color: var(--ink); }
.pill-cta { font-family: var(--mono); font-weight: 700; font-size: .88rem; color: var(--on-acc); background: var(--acc); border-radius: 999px; padding: .6em 1.1em; text-decoration: none; white-space: nowrap; }
.nav.embedded { position: absolute; top: 0; left: 0; right: 0; opacity: 0; pointer-events: none; will-change: transform; transition: opacity .35s var(--ease), border-color .4s ease, background-color .9s ease; border-bottom-color: var(--line); }
.nav.embedded.pinned { opacity: 1; pointer-events: auto; }


/* ---------- hero: the ask first, the tape beside it ---------- */
.hero { min-height: 0; padding-top: clamp(44px, 6.5vw, 96px); padding-bottom: clamp(36px, 6vw, 80px); }   /* room above the eyebrow; no viewport stretch */
.hero-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(24px, 5vw, 72px); align-items: center; }
.tagline em { color: var(--acc); font-style: italic; }
.rise { opacity: 0; transform: translateY(16px); animation: rise .95s var(--ease) forwards; animation-delay: calc(var(--i, 0) * 110ms + 60ms); }
@keyframes rise { to { opacity: 1; transform: none; } }
.get { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.5rem; }
.btn.big { font-size: 1.08rem; padding: 1em 1.6em; }
.phone-note { display: none; font-family: var(--serif); font-size: 1rem; line-height: 1.5; color: var(--ink); background: var(--card); border: 1px solid var(--line); border-left: 3px solid var(--acc); border-radius: 10px; padding: .8em 1em; margin: 1rem 0 0; }
.facts { list-style: none; display: flex; flex-wrap: wrap; gap: .5rem; margin: 1.4rem 0 0; padding: 0; }
.facts li { font-family: var(--mono); font-size: .8rem; color: var(--ink-soft); background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: .45em .9em; }
.facts b { color: var(--ink); font-weight: 700; }
.tape { margin: 0; text-align: center; opacity: 0; transform: translateY(30px) scale(.985); animation: rigRise 1.2s var(--ease) .35s forwards; }
@keyframes rigRise { to { opacity: 1; transform: none; } }
.tape-btn { display: block; width: 100%; padding: 0; border: 0; background: transparent; cursor: pointer; border-radius: 18px; }
.tape-btn img { width: 100%; height: auto; display: block; filter: drop-shadow(0 26px 40px rgba(23,18,12,.28)); transition: transform .25s var(--ease); }
.tape-btn:hover img { transform: translateY(-2px) rotate(-.6deg); }
.tape.playing img { animation: tapewobble 1.6s ease-in-out infinite; }
@keyframes tapewobble { 0%, 100% { transform: rotate(-1deg) translateY(0); } 50% { transform: rotate(1deg) translateY(-3px); } }
.tape figcaption { font-family: var(--mono); font-size: .76rem; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-soft); margin-top: .9rem; display: inline-flex; align-items: center; gap: .6em; }
.tape figcaption .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--acc); }
.tape.playing figcaption .dot { animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(1.6); opacity: .6; } }

/* ---------- inside: the numbers and the screen ---------- */
.inside-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 5vw, 64px); align-items: center; }
.rl-plain { font-size: clamp(17px, 1.5vw, 19px); margin: 1rem 0 0; max-width: 34em; }
.figs { list-style: none; margin: 1.6rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, auto); gap: 1.2rem 2rem; justify-content: start; }
.figs b { display: block; font-family: var(--mono); font-weight: 700; font-size: clamp(34px, 4vw, 52px); line-height: 1; color: var(--acc); }
.figs span { font-family: var(--mono); font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-soft); }
.shot { margin: 0; }
.shot img { border-radius: 14px; box-shadow: 0 30px 60px -30px var(--shadow), 0 0 0 1px var(--line); background: #fbf8f2; }
.shot figcaption { font-family: var(--mono); font-size: .74rem; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-soft); text-align: center; margin-top: .9rem; }

/* ---------- played, not configured ---------- */
.played { background: var(--card); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.played .sub { margin-top: 1rem; }
.chips { list-style: none; margin: 1.4rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem; }
.chips li { font-family: var(--mono); font-size: .84rem; color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 999px; padding: .5em 1em; }

/* ---------- the thumb-zone bar (phones only) ---------- */
.mob-bar { display: none; }
@media (max-width: 720px) {
  .phone-note { display: block; }
  .pill-cta { min-height: 44px; display: inline-flex; align-items: center; }   /* every tap target ≥ 44px on a phone */
  .get .btn.big { width: 100%; justify-content: center; min-height: 52px; }
  .get .btn.ghost { width: 100%; justify-content: center; min-height: 48px; }
  .figs { grid-template-columns: repeat(2, 1fr); }
  .mob-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; display: flex; align-items: center; gap: 12px; padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); background: color-mix(in srgb, var(--bg) 88%, transparent); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border-top: 1px solid var(--line); transform: translateY(110%); transition: transform .35s var(--ease); }
  .mob-bar.show { transform: none; }
  .mob-bar .mob-txt { font-family: var(--mono); font-size: .78rem; color: var(--ink-soft); line-height: 1.2; }
  .mob-bar .mob-txt b { color: var(--ink); display: block; font-size: .9rem; }
  .mob-bar .btn { margin-left: auto; white-space: nowrap; min-height: 46px; }
  body.has-bar { padding-bottom: 80px; }
}

/* ---------- hear it: the sound strip ---------- */
.hear { background: var(--card); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.sounds { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.snd { --p: 0; position: relative; text-align: left; font: inherit; color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px; cursor: pointer; display: grid; grid-template-columns: auto 1fr; column-gap: 14px; row-gap: 3px; align-items: center; overflow: hidden; transition: transform .2s var(--ease), border-color .2s, box-shadow .3s; }
.snd:hover { transform: translateY(-2px); border-color: var(--acc); }
.snd.on { border-color: var(--acc); box-shadow: 0 16px 34px -24px var(--acc-deep); }
.snd.song { grid-column: 1 / -1; }
.snd b { font-family: var(--mono); font-size: 1.05rem; grid-column: 2; }
.snd small { font-family: var(--mono); font-size: .74rem; color: var(--ink-soft); letter-spacing: .04em; grid-column: 2; }
/* the control: a play button at rest, the scope while playing */
.snd .pb, .snd .bars { grid-column: 1; grid-row: 1 / 3; width: 46px; height: 46px; }
.snd .pb { position: relative; border-radius: 50%; background: var(--acc); box-shadow: 0 10px 22px -12px var(--acc-deep), inset 0 1px 0 rgba(255,255,255,.28); transition: transform .2s var(--ease); }
.snd .pb::after { content: ""; position: absolute; left: 50%; top: 50%; transform: translate(-38%, -50%); border-style: solid; border-width: 8px 0 8px 13px; border-color: transparent transparent transparent var(--on-acc); }
.snd:hover .pb { transform: scale(1.06); }
.snd.on .pb { display: none; }
.bars { display: none; align-items: flex-end; justify-content: center; gap: 2px; padding: 10px 0; }
.snd.on .bars { display: flex; }
.bars i { width: 3px; height: 100%; border-radius: 2px; background: var(--acc); transform: scaleY(.12); transform-origin: bottom; transition: transform .12s linear; }
.snd::after { content: ""; position: absolute; left: 0; bottom: 0; height: 3px; width: 100%; background: var(--acc); transform: scaleX(var(--p)); transform-origin: left; opacity: 0; transition: opacity .3s; }
.snd.on::after { opacity: 1; }

/* ---------- two versions: side A (the Mac plugin) and side B (Kontakt, Mac and Windows) ----------
   Mac first by default and with no JS. app.js adds body.os-win on Windows, which swaps every
   for-mac / for-win pair and leads with side B; it marks the card that matches this computer. */
body:not(.os-win) .for-win, body.os-win .for-mac { display: none !important; }
body.os-win .phone-note { display: none !important; }   /* it promises a download link; the Kontakt order emails a serial */
.versions { border-top: 1px solid var(--line); }
.ways { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(14px, 2vw, 24px); align-items: stretch; }
body.os-win .way--k { order: -1; }
.way { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: clamp(22px, 3vw, 34px); transition: border-color .3s, box-shadow .3s; }
.way.is-yours { border-color: var(--acc); box-shadow: 0 24px 48px -34px var(--acc-deep); }
.way-side { display: flex; align-items: center; gap: .7em; margin: 0; min-height: 1.9rem; font-family: var(--mono); font-size: .76rem; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-soft); }
.reels { display: inline-flex; gap: 5px; padding: 4px 7px; border: 1px solid var(--line); border-radius: 6px; background: var(--bg); }
.reels i { width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--ink-faint); box-sizing: border-box; }
.way.is-yours .reels i { border-color: var(--acc); }
.yours { display: none; margin-left: auto; letter-spacing: .08em; text-transform: none; font-size: .78rem; color: var(--acc-deep); background: var(--acc-soft); border-radius: 999px; padding: .3em .8em; }
.way.is-yours .yours { display: inline-flex; }
.way h3 { font-size: clamp(26px, 3vw, 34px); line-height: 1.05; margin: 1.1rem 0 0; color: var(--ink); }
.way-what { font-family: var(--mono); font-size: .9rem; color: var(--acc-deep); margin: .45rem 0 0; }
.way ul { list-style: none; margin: 1.3rem 0 1.7rem; padding: 0; }
.way li { padding: .6rem 0; border-top: 1px dashed var(--line); font-size: 1.02rem; line-height: 1.45; }
.way li:last-child { border-bottom: 1px dashed var(--line); }
.way .btn { margin-top: auto; align-self: flex-start; }
body.os-win .way--k .btn { background: var(--acc); color: var(--on-acc); box-shadow: 0 10px 24px -14px var(--acc-deep); }
body.os-win .way--k .btn:hover { background: var(--acc-deep); }
body.os-win .way--p .btn { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
body.os-win .way--p .btn:hover { background: var(--bg); }
.way--k .btn.ghost:hover { background: var(--bg); }
@media (max-width: 720px) {
  .ways { grid-template-columns: 1fr; }
  .way .btn { align-self: stretch; justify-content: center; min-height: 48px; }
}

/* ---------- reveal on approach ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- closing: one centred column, the sentence in the serif, the button under it ---------- */
.closing { border-top: 1px solid var(--line); text-align: center; }
.closing .micro { justify-content: center; }
.closing h2 { font-family: var(--serif); font-weight: 600; font-size: clamp(32px, 4.6vw, 52px); line-height: 1.1; letter-spacing: -.015em; max-width: 14em; margin: 0 auto; }
.closing .sub { color: var(--ink-soft); font-size: 1.12rem; margin: 1rem auto 0; max-width: 30em; text-wrap: balance; }
.closing .get { justify-content: center; margin-top: 1.8rem; }
.closing .fine { margin-top: 1.1rem; }
.closing .cki { font-size: 1rem; line-height: 1.6; color: var(--ink-soft); max-width: 40em; margin: 3rem auto 0; padding-top: 2rem; border-top: 1px solid var(--line); }
.closing .cki a { color: var(--ink); }

/* ---------- makers ---------- */
.cki { font-size: clamp(19px, 2vw, 24px); line-height: 1.45; margin: 0; }

/* ---------- buy + faq ---------- */
.buy .wrap { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 4vw, 56px); align-items: start; }
.buy-card { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: clamp(24px, 3vw, 40px); }
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; font-family: var(--mono); font-weight: 700; padding: 1rem 2.2rem 1rem 0; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq-x { position: absolute; right: .2rem; top: 50%; width: 14px; height: 14px; transform: translateY(-50%); }
.faq-x::before, .faq-x::after { content: ""; position: absolute; background: var(--acc); left: 0; top: 6px; width: 14px; height: 2px; transition: transform .25s var(--ease); }
.faq-x::after { transform: rotate(90deg); }
details[open] .faq-x::after { transform: rotate(0); }
.faq p { margin: 0 0 1.1rem; color: var(--ink-soft); }

/* ---------- footer ---------- */
.foot { border-top: 1px solid var(--line); padding: 36px 0 56px; color: var(--ink-soft); font-size: .92rem; }
.foot-in { display: flex; align-items: center; gap: 1.2rem; flex-wrap: wrap; }
.foot-brand { font-family: var(--mono); color: var(--ink); }
.foot p { margin: 0; }
.foot nav { margin-left: auto; display: flex; gap: 1.2rem; }
.foot a { text-decoration: none; }

/* ---------- small screens ---------- */
@media (max-width: 900px) {
  .hero-grid, .inside-grid, .buy .wrap { grid-template-columns: 1fr; }
  .sounds { grid-template-columns: 1fr 1fr; }
  .nav-links, .brand .tag { display: none; }
}
@media (max-width: 480px) { .sounds { grid-template-columns: 1fr; } }

/* ---------- motion: off when asked ---------- */
@media (prefers-reduced-motion: reduce) {
  .rise, .rig { opacity: 1; transform: none; animation: none !important; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .rl { opacity: 1 !important; }
  .bars i { transition: none; }
}
