.v2-play-page {
  --play-on: #5fc2c2;
}
.v2-play-page button { color: inherit; }

/* Header: intro on the left, sound and scale on the right */
.v2-play-page .play-top { display: grid; grid-template-columns: 1fr auto; gap: 56px; align-items: end; padding: 96px 0 34px; }
.v2-play-page .play-intro h1 { margin: 0; max-width: 820px; font-size: clamp(2.4rem, 5vw, 4rem); line-height: 1.02; text-wrap: balance; }
.v2-play-page .play-intro p { max-width: 620px; margin: 16px 0 0; font-size: 18px; }
.v2-play-page .tune { display: grid; gap: 12px; justify-items: end; }
.v2-play-page .sound { display: flex; align-items: center; gap: 14px; padding: 8px 18px 8px 8px; border: 1px solid var(--v2-line); border-radius: 999px; background: var(--v2-card); color: var(--v2-ink); font: 500 15px var(--font-heading); cursor: pointer; }
.v2-play-page .sound .dot { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 50%; background: var(--v2-ink); color: var(--v2-bg); font-size: 16px; transition: background .3s; }
.v2-play-page .sound.on .dot { background: var(--play-on); }
.v2-play-page .sound .eq { display: inline-flex; gap: 2px; align-items: end; height: 14px; }
.v2-play-page .sound .eq i { width: 3px; height: 4px; border-radius: 1px; background: var(--play-on); opacity: .3; }
.v2-play-page .sound.on .eq i { opacity: 1; animation: play-eq 1.1s ease-in-out infinite alternate; }
.v2-play-page .sound.on .eq i:nth-child(2) { animation-delay: -.4s; }
.v2-play-page .sound.on .eq i:nth-child(3) { animation-delay: -.8s; }
@keyframes play-eq { from { height: 3px; } to { height: 14px; } }
.v2-play-page .chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.v2-play-page .chips .lbl { margin-right: 4px; color: var(--v2-muted); font: 500 11px var(--font-mono); letter-spacing: .06em; text-transform: uppercase; }
.v2-play-page .chips button { display: inline-flex; gap: 6px; align-items: center; padding: 6px 12px; border: 1px solid var(--v2-line); border-radius: 999px; background: transparent; color: var(--v2-muted); font: 500 13px var(--font-heading); cursor: pointer; }
.v2-play-page .chips button:hover { border-color: rgba(255,255,255,.3); color: var(--v2-ink); }
.v2-play-page .chips button.on { border-color: var(--v2-ink); background: var(--v2-ink); color: var(--v2-bg); }
.v2-play-page .chips button b { display: inline-block; width: 10px; height: 10px; border-radius: 50%; }

/* Piece index */
/* styles.css styles every <nav> as the old fixed site header; reset that here. */
.v2-play-page .index {
  position: static;
  z-index: auto;
  height: auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  align-items: stretch;
  gap: 0 2px;
  margin-bottom: 18px;
  padding: 0;
  border-bottom: 1px solid var(--v2-line);
  background: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.v2-play-page .index a { margin-bottom: -1px; padding: 11px 9px 13px; border-bottom: 2px solid transparent; color: var(--v2-muted); font: 500 15px var(--font-heading); text-decoration: none; white-space: nowrap; }
.v2-play-page .index a:hover { color: var(--v2-ink); }
.v2-play-page .index a span { margin-right: 6px; font: 500 11px var(--font-mono); opacity: .7; }
.v2-play-page .index a.on { border-color: var(--v2-ink); color: var(--v2-ink); }

/* Stage */
.v2-play-page .stage { position: relative; height: min(78vh, 820px); min-height: 520px; overflow: hidden; border-radius: 20px; background: #111; box-shadow: 0 40px 80px -40px rgba(0,0,0,.8); outline: 1px solid rgba(255,255,255,.06); }
.v2-play-page .stage:fullscreen { height: 100vh; border-radius: 0; }
.v2-play-page .stage.max { position: fixed; inset: 0; z-index: 1000; height: 100vh; height: 100dvh; min-height: 0; border-radius: 0; }
.v2-play-page .stage::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  opacity: .05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}
.v2-play-page .layer { position: absolute; inset: 0; touch-action: none; user-select: none; -webkit-user-select: none; cursor: crosshair; }
.v2-play-page .layer[hidden] { display: none; }
.v2-play-page .layer canvas { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }
.v2-play-page .hint { position: absolute; left: 22px; bottom: 20px; z-index: 2; padding: 6px 10px; border-radius: 999px; font: 12px var(--font-mono); pointer-events: none; backdrop-filter: blur(6px); transition: opacity 1s; }
.v2-play-page .layer.touched .hint { opacity: 0; }
.v2-play-page .readout { position: absolute; right: 22px; bottom: 20px; z-index: 2; font: 12px var(--font-mono); pointer-events: none; }
.v2-play-page .fs { position: absolute; right: 16px; top: 16px; z-index: 4; width: 38px; height: 38px; border: 1px solid rgba(255,255,255,.25); border-radius: 50%; background: rgba(0,0,0,.18); color: #fff; cursor: pointer; backdrop-filter: blur(6px); transition: opacity .5s; }
.v2-play-page .nogl { position: absolute; inset: 0; display: grid; place-items: center; margin: 0; color: #aaa; font: 14px var(--font-mono); }

/* Floating bar in full screen */
.v2-play-page .fsbar { display: none; }
.v2-play-page .stage:fullscreen .fsbar,
.v2-play-page .stage.max .fsbar { position: absolute; left: 16px; right: 66px; top: 16px; z-index: 4; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 12px; transition: opacity .5s; }
.v2-play-page .stage.idle .fsbar,
.v2-play-page .stage.idle .fs { opacity: 0; pointer-events: none; }
.v2-play-page .fsbar .grp { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding: 5px; border: 1px solid rgba(255,255,255,.12); border-radius: 999px; background: rgba(12,14,18,.42); color: #eef1f6; backdrop-filter: blur(14px) saturate(1.2); -webkit-backdrop-filter: blur(14px) saturate(1.2); }
.v2-play-page .fsbar #fsR { margin-left: auto; flex-wrap: nowrap; }
.v2-play-page .fsbar #fsR > * + * { padding-left: 10px; border-left: 1px solid rgba(255,255,255,.14); }
.v2-play-page .fsbar .grp > * { flex: none; }
.v2-play-page .fsbar .fst { min-width: 120px; padding: 0 6px; font: 500 14px var(--font-heading); text-align: center; }
.v2-play-page .fsbar .fst span { margin-right: 8px; font: 500 11px var(--font-mono); opacity: .6; }
.v2-play-page .fsbar #lCtrl:empty { display: none; }
.v2-play-page .fsbar #lCtrl:empty + #scales { padding-left: 0; border-left: 0; }
.v2-play-page .fsbar .chips { flex-wrap: nowrap; }
.v2-play-page .fsbar .chips button { border-color: rgba(255,255,255,.16); color: rgba(238,241,246,.78); }
.v2-play-page .fsbar .chips button:hover { border-color: rgba(255,255,255,.4); color: #fff; }
.v2-play-page .fsbar .chips button.on { border-color: #eef1f6; background: #eef1f6; color: #111; }
.v2-play-page .fsbar .chips .lbl { margin-left: 4px; color: rgba(238,241,246,.55); }
.v2-play-page .fsbar .sound { padding: 0 12px 0 0; border: 0; background: transparent; color: #eef1f6; font-size: 14px; white-space: nowrap; }
.v2-play-page .fsbar .sound .dot { width: 30px; height: 30px; background: #eef1f6; color: #111; font-size: 13px; }
.v2-play-page .fsbar .sound.on .dot { background: var(--play-on); color: #fff; }
.v2-play-page #fsL > button { width: 32px; height: 32px; border: 1px solid rgba(255,255,255,.2); border-radius: 50%; background: transparent; color: #fff; cursor: pointer; }
.v2-play-page #fsL > button:hover { background: rgba(255,255,255,.14); }

/* Label row */
.v2-play-page .label { display: grid; grid-template-columns: 340px 1fr auto; gap: 48px; align-items: start; padding: 26px 4px 96px; }
.v2-play-page .label .num { color: var(--v2-muted); font: 500 12px var(--font-mono); }
.v2-play-page .label h2 { margin: 4px 0 0; font: 600 34px/1.05 var(--font-heading); letter-spacing: -.03em; }
.v2-play-page .label .medium { display: block; margin-top: 8px; color: var(--v2-muted); font: 12px var(--font-mono); }
.v2-play-page .label p { max-width: 620px; margin: 0; color: #c9cfdb; font-size: 16px; }
.v2-play-page .label p.how { margin-top: 10px; color: var(--v2-muted); font: 13px var(--font-mono); }
.v2-play-page .label .ctrl { display: grid; gap: 14px; justify-items: end; }
.v2-play-page .arrows { display: flex; gap: 8px; }
.v2-play-page .arrows button { width: 42px; height: 42px; border: 1px solid var(--v2-line); border-radius: 50%; background: transparent; font-size: 16px; cursor: pointer; }
.v2-play-page .arrows button:hover { background: var(--v2-ink); color: var(--v2-bg); }

@media (max-width: 900px) {
  .v2-play-page .play-top { grid-template-columns: 1fr; gap: 28px; padding-top: 72px; }
  .v2-play-page .tune { justify-items: start; }
  .v2-play-page .index { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .v2-play-page .index::-webkit-scrollbar { display: none; }
  .v2-play-page .stage { height: 70vh; min-height: 440px; border-radius: 16px; }
  .v2-play-page .label { grid-template-columns: 1fr; gap: 18px; }
  .v2-play-page .label .ctrl { justify-items: start; }
}

/* Embedded on the homepage: just the instrument, no page chrome. */
html.embed,
html.embed body,
html.embed .v2-site { background: transparent; }
html.embed body { overflow: hidden; }
html.embed .skip-link,
html.embed .v2-nav,
html.embed .play-intro,
html.embed .v2-site footer { display: none; }
html.embed .v2-play-page .v2-shell { width: 100%; }
html.embed .v2-play-page .play-top { display: block; padding: 0 0 14px; }
html.embed .v2-play-page .tune { display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; align-items: center; }
html.embed .v2-play-page .stage { height: 620px; min-height: 0; }
html.embed .v2-play-page .label { padding-bottom: 8px; }
@media (max-width: 900px) {
  html.embed .v2-play-page .stage { height: 480px; }
}
