:root {
  --brand: #3a5fa8;
  --brand-strong: #2c4c8c;
  --brand-soft: #e3ebfa;
  --p1: #4f8ff7;
  --p2: #f05a5a;
  --p3: #3fbf6a;
  --p4: #f5c242;
  --text: #16181d;
  --muted: #5d6470;
  --bg: #ffffff;
  --tint: #f4f6fa;
  --line: #e2e6ee;
  --card: #ffffff;
  --shadow: 0 10px 30px rgba(20, 30, 60, .12);
  --radius: 16px;
  --wrap: 1120px;
  --gutter: 24px;
  --topbar: 60px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--topbar); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand); }
h1, h2, h3 { line-height: 1.15; margin: 0 0 .4em; letter-spacing: -.01em; }
h2 { font-size: clamp(28px, 4vw, 42px); }
h3 { font-size: 22px; }
p { margin: 0 0 1em; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.center { text-align: center; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
@media (max-width: 600px) { :root { --gutter: 16px; } body { font-size: 16px; } }

/* Buttons */
.btn {
  display: inline-block; padding: 12px 22px; border-radius: 999px; border: 0;
  background: var(--brand); color: #fff; font-weight: 600; text-decoration: none; font-size: 16px;
  transition: background .2s, transform .2s;
}
.btn:hover { background: var(--brand-strong); transform: translateY(-1px); }
.btn-small { padding: 7px 16px; font-size: 15px; }
.btn-tonal { background: var(--brand-soft); color: var(--brand-strong); }
.btn-tonal:hover { background: #d3e0f7; }
.btn-text { background: none; color: var(--brand); }
.btn-text:hover { background: var(--tint); }
button.link { background: none; border: 0; padding: 0; color: var(--brand); font: inherit; text-decoration: underline; cursor: pointer; }

/* Top bar */
.topbar {
  position: fixed; inset: 0 0 auto; z-index: 10; height: var(--topbar);
  display: flex; align-items: center; justify-content: space-between; padding: 0 var(--gutter);
  background: rgba(255, 255, 255, .85); backdrop-filter: saturate(1.6) blur(12px); -webkit-backdrop-filter: saturate(1.6) blur(12px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 700; }
.brand img { width: 32px; height: 32px; border-radius: 8px; }
.topbar nav { display: flex; align-items: center; gap: 22px; }
.topbar nav a:not(.btn) { color: var(--text); text-decoration: none; font-size: 15px; }
.topbar nav a:not(.btn):hover { color: var(--brand); }
@media (max-width: 600px) {
  .topbar nav { gap: 14px; }
  .hide-small, .brand span { display: none; }
}

/* Opening: sticky stage, the mockup turns into the bar photo while scrolling (main.js sets --p from 0 to 1). */
.hero { position: relative; height: 230vh; --p: 0; }
.hero-sticky {
  position: sticky; top: 0; height: 100vh; overflow: hidden;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: calc(var(--topbar) + 3vh) var(--gutter) 3vh;
}
.hero-text { text-align: center; max-width: 780px; opacity: calc(1 - var(--p) * 2.2); transform: translateY(calc(var(--p) * -40px)); }
.hero h1 { font-size: clamp(36px, 6.4vw, 72px); font-weight: 800; }
.accent {
  background: linear-gradient(90deg, var(--p1), var(--p2) 40%, var(--p4) 70%, var(--p3));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.lead { font-size: clamp(17px, 2vw, 20px); color: var(--muted); }
.hero-actions { display: flex; gap: 16px; align-items: center; justify-content: center; flex-wrap: wrap; }
.hero-stage { width: 100%; max-width: 1400px; flex: 1 1 auto; min-height: 0; display: flex; align-items: center; justify-content: center;
  transform: scale(calc(1 + var(--p) * .15)); }
.hero-mockup { max-height: 100%; width: auto; object-fit: contain; }
.hero-photo {
  position: absolute; inset: 0; opacity: clamp(0, calc(var(--p) * 2 - .35), 1);
  pointer-events: none;
}
.hero-photo img { width: 100%; height: 100%; object-fit: cover; transform: scale(calc(1.12 - var(--p) * .12)); }
.hero-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(transparent 55%, rgba(0, 0, 0, .65)); }
.hero-photo-caption {
  position: absolute; left: 0; right: 0; bottom: 6vh; z-index: 1; margin: 0; padding: 0 var(--gutter);
  text-align: center; color: #fff; font-size: clamp(20px, 3vw, 32px); font-weight: 700;
  opacity: clamp(0, calc(var(--p) * 3 - 2), 1);
}
/* Phones and reduced motion: no scroll effect — the mockup, then the photo below it. */
@media (max-width: 700px), (prefers-reduced-motion: reduce) {
  .hero { height: auto; }
  .hero-sticky { position: static; height: auto; overflow: visible; padding-bottom: 0; }
  .hero-text, .hero-stage { opacity: 1; transform: none; }
  .hero-stage { margin: 24px calc(-1 * var(--gutter)) 32px; width: calc(100% + 2 * var(--gutter)); }
  .hero-mockup { width: 100%; }
  .hero-photo { position: relative; opacity: 1; margin: 0 calc(-1 * var(--gutter)); width: calc(100% + 2 * var(--gutter)); }
  .hero-photo img { height: auto; aspect-ratio: 4 / 3; transform: none; object-position: 50% 40%; }
  .hero-photo-caption { opacity: 1; font-size: 20px; bottom: 24px; }
}

/* Sections */
.section { padding: 96px 0; }
.tint { background: var(--tint); }
.section-lead { font-size: 19px; color: var(--muted); max-width: 720px; }
.center .section-lead, .feature-text.center p { margin-left: auto; margin-right: auto; }
@media (max-width: 600px) { .section { padding: 64px 0; } }

.cards.three { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 40px; }
@media (max-width: 860px) { .cards.three { grid-template-columns: 1fr; } }
.card { background: var(--tint); border-radius: var(--radius); padding: 28px; }
.card h3 { font-size: 19px; }
.card p { color: var(--muted); margin: 0; }
.ico { width: 36px; height: 36px; fill: none; stroke: var(--brand); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 14px; }
.card:nth-child(2) .ico { stroke: var(--p2); }
.card:nth-child(3) .ico { stroke: var(--p3); }

/* Feature rows: picture and text side by side, swapped every other row */
.feature { display: grid; grid-template-columns: 1.25fr 1fr; gap: 56px; align-items: center; margin-top: 96px; }
.feature.flip .feature-media { order: 2; }
.feature.wide { display: block; }
.feature-media img, .feature-media .compare, .feature-media .txt { border-radius: 12px; box-shadow: var(--shadow); }
/* The mockup has a white background: multiplied, it takes on the section's tint instead of showing a white box. */
.feature-media img.blend { box-shadow: none; border-radius: 0; mix-blend-mode: multiply; }
.feature-media.narrow img { max-width: 380px; margin: 0 auto; }
.kicker { display: inline-block; font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--brand); margin-bottom: 8px; }
.feature:nth-of-type(4n+2) .kicker { color: var(--p2); }
.feature:nth-of-type(4n+3) .kicker { color: #2e9c55; }
.feature:nth-of-type(4n) .kicker { color: #c8901a; }
.feature-text p { color: var(--muted); }
@media (max-width: 860px) {
  .feature { grid-template-columns: 1fr; gap: 24px; margin-top: 64px; }
  .feature.flip .feature-media { order: 0; }
}

/* Songbook: four steps left to right, top to bottom on phones */
.steps-strip { list-style: none; padding: 0; margin: 32px 0 0; display: grid; grid-template-columns: repeat(4, auto); justify-content: space-between; gap: 40px; counter-reset: step; }
.steps-strip li { position: relative; display: flex; flex-direction: column; align-items: center; gap: 14px; counter-increment: step; }
.steps-strip li > img { height: 300px; width: auto; max-width: 100%; object-fit: contain; border-radius: 12px; box-shadow: var(--shadow); background: #fff; }
.steps-strip li > img.qr { height: 150px; margin: 75px 0; padding: 10px; }
.steps-strip li:nth-child(3) > img { box-shadow: none; background: none; }
.steps-strip li span { max-width: 220px; text-align: center; font-weight: 600; font-size: 15px; }
.steps-strip li span::before {
  content: counter(step); display: inline-grid; place-items: center; width: 24px; height: 24px; margin-right: 8px;
  border-radius: 50%; background: var(--brand); color: #fff; font-size: 13px;
}
.steps-strip li:not(:last-child)::after {
  content: "→"; position: absolute; right: -32px; top: 136px; color: var(--muted); font-size: 22px;
}
@media (max-width: 860px) {
  .steps-strip { grid-template-columns: 1fr; gap: 48px; }
  .steps-strip li > img { height: auto; max-height: 460px; }
  .steps-strip li > img.qr { margin: 0; }
  .steps-strip li:not(:last-child)::after { content: "↓"; right: auto; top: auto; bottom: -40px; }
}

/* Streaming or a file: a plain play button (not YouTube's logo) and a music file */
.source-icons { display: flex; gap: 12px; margin-bottom: 4px; }
.source-icons .ico { width: 44px; height: 44px; margin: 0; }
.source-icons .stream .fill { fill: var(--brand); stroke: none; }
.source-icons .file { stroke: var(--muted); }

/* The song file */
.txt { margin: 0; padding: 28px 32px; background: #1d2230; color: #e6e9f0; font: 15px/1.7 ui-monospace, "SF Mono", Menlo, Consolas, monospace; overflow-x: auto; }
.txt .c { color: var(--p4); }

/* Light / dark: the dark picture is clipped to the right of the handle */
.compare { position: relative; overflow: hidden; }
.compare img { width: 100%; }
.compare .compare-top { position: absolute; inset: 0; height: 100%; clip-path: inset(0 0 0 var(--pos)); }
.compare input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; }
.compare-handle { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 3px; margin-left: -1.5px; background: #fff; box-shadow: 0 0 8px rgba(0, 0, 0, .4); pointer-events: none; }
.compare-handle::after {
  content: "◂ ▸"; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  padding: 6px 10px; border-radius: 999px; background: #fff; color: var(--text); font-size: 13px; white-space: nowrap; box-shadow: var(--shadow);
}

/* Languages: a line globe with speech bubbles around it (static) */
.globe { position: relative; width: min(80%, 352px); aspect-ratio: 1; margin: 0 auto; }
.globe-earth { position: absolute; inset: 20%; width: 60%; height: 60%; fill: none; stroke: var(--brand); stroke-width: 1.4; opacity: .85; }
.globe-earth circle { fill: var(--brand-soft); }
.globe-words { list-style: none; margin: 0; padding: 0; position: absolute; inset: 0; }
.globe-words li {
  position: absolute; transform: translate(-50%, -50%); padding: 5px 11px; border-radius: 12px; white-space: nowrap;
  background: #fff; box-shadow: 0 6px 18px rgba(20, 30, 60, .14); font-weight: 600; font-size: clamp(12px, 2.9vw, 15px);
  border-bottom: 3px solid var(--c);
}
.globe-words .p1 { --c: var(--p1); } .globe-words .p2 { --c: var(--p2); } .globe-words .p3 { --c: var(--p3); } .globe-words .p4 { --c: var(--p4); }
.lang-list { list-style: none; padding: 0; margin: 8px 0 0; display: flex; flex-wrap: wrap; gap: 8px; }
.lang-list li { padding: 4px 12px; border-radius: 999px; background: var(--bg); border: 1px solid var(--line); font-size: 15px; }

/* Photo break */
.band { height: 46vh; min-height: 260px; overflow: hidden; }
.band img { width: 100%; height: 100%; object-fit: cover; object-position: center 40%; }

/* Setup timeline */
.timeline { list-style: none; padding: 0; margin: 48px 0 0; counter-reset: step; }
.timeline li {
  counter-increment: step; position: relative; display: grid; grid-template-columns: 1fr 260px; gap: 32px; align-items: start;
  padding: 0 0 40px 72px;
}
.timeline li::before {
  content: counter(step); position: absolute; left: 0; top: 0; width: 44px; height: 44px; border-radius: 50%;
  display: grid; place-items: center; background: var(--brand); color: #fff; font-weight: 700; font-size: 18px;
}
.timeline li:nth-child(4n+2)::before { background: var(--p2); }
.timeline li:nth-child(4n+3)::before { background: var(--p3); }
.timeline li:nth-child(4n)::before { background: var(--p4); color: var(--text); }
.timeline li:not(:last-child)::after { content: ""; position: absolute; left: 21px; top: 52px; bottom: 8px; width: 2px; background: var(--line); }
.timeline h3 { font-size: 20px; margin-top: 8px; }
.timeline p { color: var(--muted); margin: 0; }
.timeline img { width: 260px; height: 208px; object-fit: cover; object-position: top; border-radius: 10px; box-shadow: var(--shadow); }
@media (max-width: 700px) {
  .timeline li { grid-template-columns: 1fr; gap: 16px; padding-left: 60px; }
  .timeline img { width: 100%; height: 260px; }
}

/* System icons */
.os { width: 1em; height: 1em; fill: currentColor; vertical-align: -0.12em; margin-right: .35em; }
.os-list { display: inline-flex; gap: 14px; flex-wrap: wrap; }
.os-list span { white-space: nowrap; }

/* Download */
.downloads { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin: 32px 0 20px; }
@media (max-width: 900px) { .downloads { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .downloads { grid-template-columns: 1fr; } }
.dl {
  display: flex; flex-direction: column; gap: 4px; padding: 22px; border-radius: var(--radius);
  background: var(--card); border: 2px solid var(--line); color: var(--text); text-decoration: none; transition: border-color .2s, transform .2s;
}
.dl .os { width: 28px; height: 28px; margin-bottom: 6px; color: var(--text); }
.dl span { color: var(--muted); font-size: 14px; }
.dl:hover { border-color: var(--brand); transform: translateY(-2px); }
.dl.mine { border-color: var(--brand); background: var(--brand-soft); }

/* Feedback */
.feedback-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 24px; }

/* Sister app (same card as on the Creator Tool's page) */
.promo {
  display: flex; align-items: center; gap: 24px; max-width: 820px; margin: 0 auto; padding: 24px 28px;
  background: var(--card); border: 2px solid var(--line); border-radius: var(--radius); color: var(--text); text-decoration: none;
  transition: border-color .2s, transform .2s;
}
.promo:hover { border-color: var(--brand); transform: translateY(-2px); }
.promo img { width: 88px; height: 88px; flex: none; border-radius: 20px; }
.promo b { display: block; font-size: 20px; margin-bottom: 4px; }
.promo span span { color: var(--muted); font-size: 16px; }
.promo-arrow { margin-left: auto; font-size: 28px; color: var(--brand); flex: none; }
@media (max-width: 600px) { .promo { flex-direction: column; text-align: center; } .promo-arrow { display: none; } }

/* Footer */
.footer { padding: 32px 0; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.footer .wrap { display: flex; gap: 24px; flex-wrap: wrap; justify-content: space-between; }

/* First-start help */
.help {
  width: min(560px, calc(100vw - 32px)); border: 0; border-radius: 20px; padding: 28px; box-shadow: 0 30px 80px rgba(0, 0, 0, .35);
  color: var(--text); background: var(--bg);
}
.help::backdrop { background: rgba(15, 20, 35, .55); }
.help-title { font-size: 24px; padding-right: 32px; }
.help-close { position: absolute; top: 14px; right: 14px; margin: 0; }
.help-close button { width: 36px; height: 36px; border-radius: 50%; border: 0; background: var(--tint); cursor: pointer; font-size: 16px; color: var(--text); }
.tabs { display: flex; gap: 6px; background: var(--tint); padding: 4px; border-radius: 999px; margin: 16px 0; }
.tabs button { flex: 1; padding: 8px; border: 0; border-radius: 999px; background: none; font: inherit; font-weight: 600; cursor: pointer; color: var(--muted); }
.tabs button[aria-selected="true"] { background: #fff; color: var(--text); box-shadow: 0 1px 4px rgba(0, 0, 0, .12); }
.tab ol { padding-left: 22px; margin: 0 0 12px; }
.tab li { margin-bottom: 8px; }
.tab code { background: var(--tint); padding: 1px 6px; border-radius: 6px; font-size: 14px; }
.tool-list { list-style: none; padding: 0; margin: 16px 0; display: grid; gap: 14px; }
.tool-list li { display: flex; flex-direction: column; gap: 2px; padding: 14px 16px; border-radius: 12px; background: var(--tint); }
.tool-list span { color: var(--muted); font-size: 15px; }
