/* Bandstand product page. The app's own palette: a black stage, amber
   chords, sky-blue section labels; Archivo (wide for display) and
   JetBrains Mono for anything chord-like. */

:root {
  --stage: #000;
  --panel: #111316;
  --line: #2a2e33;
  --text: #f2efe8;
  --muted: #a39f97;
  --dim: #3b3a37;
  --amber: #f2b134;
  --amber-ink: #8a4f00;
  --sky: #7fb2ff;
  --paper: #f5f3ee;
  --paper-2: #ebe7df;
  --ink: #1a1c1e;
  --ink-2: #55524c;
  --sky-ink: #1f5fb8;
  --wide: 'Archivo', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
  --max: 1180px;
  --gut: clamp(16px, 4vw, 40px);
}

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--stage);
  color: var(--text);
  font-family: var(--wide);
  font-size: 18px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img {
  display: block;
  max-width: 100%;
  height: auto;
}
a {
  color: inherit;
}
:focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 3px;
  border-radius: 6px;
}
h1,
h2,
h3,
p,
figure,
ul,
pre {
  margin: 0;
}
ul {
  padding: 0;
  list-style: none;
}

/* ---------------------------------------------------------------- nav */

.nav {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(8, 8, 9, 0.9);
  -webkit-backdrop-filter: saturate(180%) blur(18px);
  backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.nav-in {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gut);
  height: 56px;
  display: flex;
  align-items: center;
  gap: 28px;
}
.wordmark {
  font-weight: 800;
  font-size: 15px;
  letter-spacing: 0.32em;
  text-decoration: none;
  color: var(--text);
}
.nav nav {
  display: flex;
  gap: 24px;
  margin-left: auto;
}
.nav nav a {
  font-size: 14px;
  color: var(--muted);
  text-decoration: none;
  padding: 12px 0;
}
.nav nav a:hover {
  color: var(--text);
}
.nav-cta {
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  color: var(--stage);
  background: var(--text);
  border-radius: 999px;
  padding: 7px 16px;
}
@media (max-width: 720px) {
  .nav nav {
    display: none;
  }
  .nav-cta {
    margin-left: auto;
  }
}

/* ---------------------------------------------------------- sections */

section {
  padding: clamp(88px, 13vw, 168px) var(--gut);
}
.dark {
  background: var(--stage);
  color: var(--text);
}
.light {
  background: var(--paper);
  color: var(--ink);
}

.eyebrow,
.kicker {
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber);
}
.light .kicker {
  color: var(--amber-ink);
}

.display,
.display-2,
.title {
  font-stretch: 125%;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.02;
}
.display {
  font-size: clamp(44px, 8.6vw, 112px);
  margin-top: 18px;
}
.display-2 {
  font-size: clamp(64px, 14vw, 184px);
  line-height: 0.95;
  margin-top: 12px;
}
.title {
  font-size: clamp(34px, 5.4vw, 68px);
  margin-top: 14px;
}
.lede,
.sub {
  font-size: clamp(18px, 2vw, 22px);
  line-height: 1.5;
  color: var(--muted);
  max-width: 40em;
}
.light .sub {
  color: var(--ink-2);
}
.lede {
  margin: 26px auto 0;
}
.sub {
  margin-top: 22px;
}

.head {
  max-width: var(--max);
  margin: 0 auto;
}
.center {
  text-align: center;
}
.center .sub {
  margin-left: auto;
  margin-right: auto;
}

.btn {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 17px;
  text-decoration: none;
}
.btn-amber {
  background: var(--amber);
  color: #1a1205;
}
.btn-amber:hover {
  background: #ffc552;
}
.btn-ghost {
  color: var(--text);
  box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.35);
}
.btn-ghost:hover {
  box-shadow: inset 0 0 0 1.5px var(--text);
}
.ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: center;
  margin-top: 36px;
}

/* -------------------------------------------------------------- hero */

.hero {
  text-align: center;
  padding-top: clamp(64px, 10vw, 120px);
  padding-bottom: 0;
  overflow: hidden;
}
.hero-stage {
  position: relative;
  max-width: 1080px;
  margin: clamp(56px, 8vw, 96px) auto 0;
  perspective: 1600px;
  padding-bottom: clamp(56px, 9vw, 120px);
}
/* A stage light, under the iPad */
.hero-stage::before {
  content: '';
  position: absolute;
  inset: 10% 8% 0;
  background: radial-gradient(
    closest-side,
    rgba(242, 177, 52, 0.28),
    transparent
  );
  filter: blur(40px);
}

/* ---------------------------------------------------------- devices */

.ipad,
.phone,
.browser {
  position: relative;
  background: #0d0d0e;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.1),
    0 40px 80px -24px rgba(0, 0, 0, 0.6);
}
.ipad {
  border-radius: clamp(18px, 3vw, 38px);
  padding: clamp(8px, 1.4vw, 16px);
}
.ipad img {
  border-radius: clamp(10px, 1.8vw, 22px);
}
.phone {
  border-radius: clamp(36px, 4.6vw, 54px);
  padding: clamp(8px, 1vw, 12px);
  width: min(340px, 74vw);
}
.phone img {
  border-radius: clamp(28px, 3.8vw, 44px);
}
.phone.small {
  width: min(230px, 56vw);
}
.browser {
  border-radius: 14px;
  overflow: hidden;
  background: #e2ded6;
}
.browser-bar {
  height: 34px;
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 0 14px;
}
.browser-bar i {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #c4bfb5;
}
.light .ipad,
.light .phone,
.light .browser {
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.08),
    0 40px 80px -30px rgba(40, 30, 10, 0.35);
}

/* -------------------------------------------------------- statement */

.statement {
  padding-top: clamp(120px, 16vw, 220px);
  padding-bottom: clamp(120px, 16vw, 220px);
}
.words {
  max-width: 980px;
  margin: 0 auto;
  font-stretch: 112%;
  font-weight: 700;
  font-size: clamp(30px, 4.6vw, 58px);
  line-height: 1.14;
  letter-spacing: -0.015em;
}

/* ----------------------------------------------------------- charts */

.chapter .head {
  margin-bottom: clamp(48px, 7vw, 80px);
}
.chapter > figure,
.chapter > .parts,
.chapter > .bento,
.chapter > .points {
  max-width: var(--max);
  margin-left: auto;
  margin-right: auto;
}
.points {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 40px);
  margin-top: clamp(48px, 6vw, 72px);
}
.points h3 {
  font-size: 22px;
  font-weight: 800;
  margin-top: 14px;
}
.points p {
  color: var(--ink-2);
  margin-top: 6px;
  font-size: 17px;
}
.pt-mono {
  font-family: var(--mono);
  font-weight: 700;
  font-size: 22px;
  color: var(--amber-ink);
  display: inline-block;
  border: 1.5px solid #cfc9bd;
  border-radius: 10px;
  padding: 4px 12px;
}
@media (max-width: 760px) {
  .points {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ----------------------------------------------------------- split */

.split {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: clamp(48px, 8vw, 120px);
  overflow: hidden;
}
.split-text {
  flex: 1 1 380px;
  max-width: 520px;
}

/* ------------------------------------------------------------ parts */

.parts {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}
.card {
  background: #fff;
  border-radius: 22px;
  padding: clamp(14px, 2vw, 24px);
  box-shadow:
    0 1px 0 rgba(0, 0, 0, 0.04),
    0 24px 50px -30px rgba(40, 30, 10, 0.3);
}
.card figcaption {
  font-size: 15px;
  color: var(--ink-2);
  margin-top: 14px;
  padding: 0 6px;
}
@media (max-width: 820px) {
  .parts {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------------------------------------------------------- perform */

.perform {
  overflow: hidden;
}
.duo {
  display: flex;
  justify-content: center;
  gap: clamp(20px, 5vw, 64px);
  margin: clamp(56px, 8vw, 96px) auto 0;
  max-width: var(--max);
}
.duo .phone {
  width: min(340px, 44vw);
}
.specs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(24px, 3vw, 40px);
  max-width: var(--max);
  margin: clamp(64px, 8vw, 104px) auto 0;
}
.specs svg {
  width: 34px;
  height: 34px;
  fill: none;
  stroke: var(--amber);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.specs h3 {
  font-size: 20px;
  font-weight: 800;
  margin-top: 14px;
}
.specs p {
  color: var(--muted);
  font-size: 16px;
  margin-top: 6px;
}
@media (max-width: 900px) {
  .specs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 480px) {
  .specs {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ------------------------------------------------------------ bento */

.bento {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.tile {
  background: #fff;
  border-radius: 28px;
  padding: clamp(22px, 2.6vw, 34px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 22px;
  min-height: 300px;
}
.tile.wide {
  grid-column: span 2;
}
.tile h3 {
  font-size: 24px;
  font-weight: 800;
  font-stretch: 110%;
  letter-spacing: -0.01em;
}
.tile p {
  color: var(--ink-2);
  font-size: 16px;
  margin-top: 8px;
  max-width: 34em;
}
.tile .shot {
  border-radius: 12px;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.07);
  margin-top: auto;
}
.tile .phone {
  margin: auto auto -90px;
}
.homescreen {
  margin-top: auto;
  display: grid;
  justify-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
}
.homescreen img {
  width: 76px;
  height: 76px;
  border-radius: 18px;
  box-shadow: 0 12px 26px -12px rgba(0, 0, 0, 0.45);
}
.notif {
  margin-top: auto;
  background: rgba(240, 237, 230, 0.9);
  border-radius: 20px;
  padding: 14px 16px;
  display: grid;
  gap: 2px;
  font-size: 15px;
  box-shadow: 0 12px 30px -16px rgba(0, 0, 0, 0.35);
}
.notif-app {
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--ink-2);
  font-weight: 700;
}
.notif span:last-child {
  color: var(--ink-2);
}
.bands {
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.bands span {
  font-size: 15px;
  font-weight: 700;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--paper-2);
}
.bands span:first-child {
  background: var(--ink);
  color: var(--paper);
}
@media (max-width: 900px) {
  .bento {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .tile.wide {
    grid-column: span 2;
  }
}
@media (max-width: 600px) {
  .bento {
    grid-template-columns: minmax(0, 1fr);
  }
  .tile.wide {
    grid-column: span 1;
  }
}

/* ------------------------------------------------------------- host */

.code {
  max-width: 860px;
  margin: clamp(48px, 7vw, 80px) auto 0;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: clamp(20px, 3vw, 32px);
  font-family: var(--mono);
  font-size: clamp(13px, 1.4vw, 15px);
  line-height: 1.75;
  color: var(--text);
  overflow-x: auto;
}
.code .c {
  color: var(--sky);
}
.facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
  max-width: 860px;
  margin: 48px auto 0;
}
.facts b {
  display: block;
  font-size: 18px;
}
.facts span {
  color: var(--muted);
  font-size: 16px;
}
@media (max-width: 720px) {
  .facts {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ----------------------------------------------------------- footer */

.foot {
  border-top: 1px solid var(--line);
  padding: 40px var(--gut) 56px;
}
.foot-in {
  max-width: var(--max);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 16px 32px;
  align-items: center;
}
.foot p {
  color: var(--muted);
  font-size: 14px;
  flex: 1 1 320px;
}
.foot nav {
  display: flex;
  gap: 22px;
}
.foot nav a {
  color: var(--muted);
  font-size: 14px;
}
.foot nav a:hover {
  color: var(--text);
}

/* ===================================================== scroll motion */

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(48px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@keyframes tilt {
  from {
    transform: rotateX(28deg) scale(0.84) translateY(40px);
    opacity: 0.4;
  }
  to {
    transform: none;
    opacity: 1;
  }
}
@keyframes phone-rise {
  from {
    transform: translateY(160px) rotate(4deg);
  }
  to {
    transform: none;
  }
}
@keyframes from-left {
  from {
    transform: translateX(-90px) rotate(-10deg);
    opacity: 0.3;
  }
  to {
    transform: rotate(-3deg);
    opacity: 1;
  }
}
@keyframes from-right {
  from {
    transform: translateX(90px) rotate(10deg);
    opacity: 0.3;
  }
  to {
    transform: rotate(3deg) translateY(36px);
    opacity: 1;
  }
}
@keyframes light-up {
  from {
    background-position: 0 100%;
  }
  to {
    background-position: 0 0;
  }
}

/* The words light up line by line as they cross the screen */
.words {
  background-image: linear-gradient(to bottom, var(--text) 42%, var(--dim) 58%);
  background-size: 100% 200%;
  background-position: 0 0;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    .reveal {
      animation: rise linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 70%;
    }
    .tilt {
      transform-origin: 50% 100%;
      animation: tilt linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 45%;
    }
    .rise {
      animation: phone-rise linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 50%;
    }
    .left-in {
      animation: from-left linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 45%;
    }
    .right-in {
      animation: from-right linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 45%;
    }
    .words {
      animation: light-up linear both;
      animation-timeline: view();
      animation-range: cover 20% cover 65%;
    }
  }

  /* Without scroll timelines: each piece arrives once, as it scrolls in */
  .io .reveal,
  .io .tilt {
    opacity: 0;
    transform: translateY(40px);
    transition:
      opacity 0.9s ease,
      transform 0.9s cubic-bezier(0.2, 0.7, 0.2, 1);
  }
  .io .tilt {
    transform: rotateX(20deg) scale(0.9);
    transform-origin: 50% 100%;
  }
  .io .reveal.in,
  .io .tilt.in {
    opacity: 1;
    transform: none;
  }
  .io .words {
    background-position: 0 100%;
    transition: background-position 1.6s ease;
  }
  .io .words.in {
    background-position: 0 0;
  }
}
.duo .left-in {
  transform: rotate(-3deg);
}
.duo .right-in {
  transform: rotate(3deg) translateY(36px);
}

/* Phones: headings wrap where they fall, not at the desktop's breaks */
@media (max-width: 600px) {
  .title br {
    display: none;
  }
}
