/* RiffDrop — dark, dense DAW styling. */

:root {
  --bg: #141615;
  --panel: #212328;
  --panel-2: #27292f;
  --panel-3: #30333a;
  --lane: #1a1b1f;
  --line: #0c0d0f;
  --line-soft: #34373e;
  --grid-bar: rgba(255, 255, 255, 0.075);
  --grid-beat: rgba(255, 255, 255, 0.03);
  --text: #eee9df;
  --text-dim: #a0a59f;
  --accent: #d8ae75;
  --lamp: #d8ae75;
  --rec: #e5484d;
  --play: #4cc472;
  --mute: #f0a23d;
  --solo: #f1d548;
  --header-w: 224px; /* keep in sync with HEADER_W in daw.js */
  --track-h: 68px;
  --ruler-h: 36px;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 12px/1.35 ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); }
button, input { font: inherit; color: inherit; }
[hidden] { display: none !important; }
.muted { color: var(--text-dim); }
.spacer { flex: 1; }
.error-text { color: #ff8d8f; }

/* ── Top bar (shared by home + DAW) ───────────────────────────────── */

.topbar {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 46px;
  padding: 0 10px;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
  flex: none;
  min-width: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 800;
  font-size: 14px;
  letter-spacing: 0.01em;
  color: var(--text);
  text-decoration: none;
  flex: none;
}
.brand-wordmark { white-space: nowrap; }
.brand-drop { color: var(--lamp); }
.product-mark { display: block; width: 26px; height: 26px; flex: none; }

.drop-name {
  font-weight: 600;
  font-size: 13px;
  max-width: 220px;
  min-width: 60px;
  padding: 3px 6px;
  border-radius: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  cursor: default;
}
.drop-name:hover { background: var(--panel-3); }

.transport, .tempo, .zoom { display: flex; align-items: center; gap: 3px; flex: none; }

.tbtn {
  display: inline-grid;
  place-items: center;
  min-width: 30px;
  height: 28px;
  padding: 0 6px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: linear-gradient(#33363d, #2a2d33);
  color: var(--text);
  cursor: pointer;
}
.tbtn:hover { background: linear-gradient(#3a3d45, #30333a); }
.tbtn .icon { width: 14px; height: 14px; fill: currentColor; }
.tbtn.play .icon { fill: #c9ccd2; }
.tbtn.play.on { background: #1f3a29; }
.tbtn.play.on .icon { fill: var(--play); }
.tbtn.rec .icon { fill: var(--rec); }
.tbtn.rec.on { background: var(--rec); }
.tbtn.rec.on .icon { fill: #fff; }
.tbtn.rec.blink { animation: blink 0.5s steps(2, start) infinite; }
.tbtn.toggle.on { background: #263b57; color: #cfe3ff; border-color: #0d1a2b; }
.tbtn.toggle.on .icon { fill: #9cc8ff; }
.tbtn.text { font-size: 11px; font-weight: 600; color: var(--text-dim); }
.tbtn.text.on { color: #cfe3ff; }
@keyframes blink { to { background: var(--rec); } }

.lcd {
  font-family: var(--mono);
  background: #0e0f11;
  border: 1px solid #000;
  border-radius: 3px;
  padding: 1px 10px;
  min-width: 112px;
  text-align: right;
  line-height: 1.15;
  flex: none;
}
.lcd-main { font-size: 15px; color: #e8f1ff; letter-spacing: 0.02em; }
.lcd-sub { font-size: 10px; color: var(--text-dim); }

.field-btn, .field-static {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  height: 28px;
  padding: 0 8px;
  border: 1px solid #000;
  border-radius: 3px;
  background: #0e0f11;
  font-family: var(--mono);
  line-height: 26px;
}
.field-btn { cursor: text; }
.field-btn .bpm-value { font-size: 14px; color: #e8f1ff; }
.field-btn .unit, .field-static { font-size: 10px; color: var(--text-dim); }
.field-static { font-size: 12px; color: #c9ccd2; }

.author-input {
  width: 110px;
  height: 26px;
  padding: 0 7px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: #18191c;
}

.share-btn, .btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 28px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: linear-gradient(#33363d, #2a2d33);
  cursor: pointer;
  text-decoration: none;
  color: var(--text);
  font-weight: 600;
}
.share-btn .icon, .add-track .icon { width: 13px; height: 13px; fill: currentColor; }
.btn.primary { background: linear-gradient(#3d79c9, #2f63a8); border-color: #10233d; color: #fff; }
.btn:disabled { opacity: 0.5; cursor: default; }
.text-btn { background: none; border: 0; color: var(--text-dim); cursor: pointer; text-decoration: underline; }

.inline-edit {
  width: 100%;
  min-width: 60px;
  height: 22px;
  padding: 0 5px;
  border: 1px solid var(--accent);
  border-radius: 2px;
  background: #0e0f11;
  outline: none;
}
.bpm-edit { width: 58px; font-family: var(--mono); }

.notice-bar {
  padding: 6px 12px;
  background: #3a2a12;
  color: #ffd9a3;
  border-bottom: 1px solid var(--line);
}

/* ── DAW layout ───────────────────────────────────────────────────── */

body.daw-page { overflow: hidden; display: flex; flex-direction: column; height: 100vh; height: 100dvh; }
.daw-page #app { flex: 1; min-height: 0; }
.daw { display: flex; flex-direction: column; height: 100%; }

.arrange {
  position: relative;
  flex: 1;
  overflow: auto;
  background: var(--bg);
  overscroll-behavior: contain;
}
.arrange-inner {
  position: relative;
  width: calc(var(--header-w) + var(--timeline-w, 1000px));
  min-height: 100%;
}

/* Ruler (sticky on top) */
.ruler-row {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  height: var(--ruler-h);
  background: var(--panel);
  border-bottom: 1px solid var(--line);
}
.corner {
  position: sticky;
  left: 0;
  z-index: 6;
  width: var(--header-w);
  flex: none;
  background: var(--panel);
  border-right: 1px solid var(--line);
}
.ruler {
  position: relative;
  width: var(--timeline-w);
  flex: none;
  cursor: pointer;
  user-select: none;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, 0.32) 1px, transparent 1px),
    linear-gradient(to right, rgba(255, 255, 255, 0.16) 1px, transparent 1px);
  background-size: var(--bar-px) 100%, var(--beat-px) 7px;
  background-position: 0 0, 0 100%;
  background-repeat: repeat-x;
}
.dense .ruler { background-size: var(--bar-px) 100%, 0 0; }
.bar-label {
  position: absolute;
  top: 15px;
  padding-left: 4px;
  font-size: 11px;
  color: #aeb3bc;
  font-family: var(--mono);
  pointer-events: none;
}
.ruler-head {
  position: absolute;
  bottom: 0;
  left: -6px;
  width: 0;
  height: 0;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-top: 8px solid #f4f4f4;
  pointer-events: none;
}

/* Tracks */
.track-row {
  display: flex;
  height: var(--track-h);
  border-bottom: 1px solid var(--line);
}
.track-header {
  position: sticky;
  left: 0;
  z-index: 6;
  display: flex;
  width: var(--header-w);
  flex: none;
  background: var(--panel-2);
  border-right: 1px solid var(--line);
  user-select: none;
}
.track-row.selected .track-header { background: #31353d; }
.track-row.selected .track-name { color: #fff; }
.color-chip {
  width: 7px;
  flex: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}
.track-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 7px;
  padding: 0 8px 0 9px;
}
.track-top { display: flex; align-items: center; gap: 4px; min-width: 0; }
.track-name {
  flex: 1;
  min-width: 0;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #c9ccd2;
}
.more {
  display: grid;
  place-items: center;
  width: 20px;
  height: 18px;
  padding: 0;
  border: 0;
  border-radius: 2px;
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
}
.more:hover { background: var(--panel-3); color: var(--text); }
.more .icon { width: 12px; height: 12px; fill: currentColor; }
.track-controls { display: flex; align-items: center; gap: 4px; }
.flag {
  width: 22px;
  height: 18px;
  padding: 0;
  border: 1px solid #111215;
  border-radius: 2px;
  background: #3a3d44;
  color: #c3c7ce;
  font-size: 10px;
  font-weight: 700;
  cursor: pointer;
}
.flag:hover { background: #454952; }
.flag.arm.on { background: var(--rec); color: #fff; }
.flag.mute.on { background: var(--mute); color: #1d1406; }
.flag.solo.on { background: var(--solo); color: #1d1a06; }
.meter {
  flex: 1;
  height: 6px;
  margin-left: 4px;
  background: #0f1012;
  border-radius: 1px;
  overflow: hidden;
  visibility: hidden;
}
.track-row.armed .meter { visibility: visible; }
.meter-fill { width: 0; height: 100%; background: var(--play); transition: width 50ms linear; }
.meter-fill.hot { background: var(--rec); }

.lane {
  position: relative;
  width: var(--timeline-w);
  flex: none;
  background-color: var(--lane);
  background-image:
    linear-gradient(to right, var(--grid-bar) 1px, transparent 1px),
    linear-gradient(to right, var(--grid-beat) 1px, transparent 1px);
  background-size: var(--bar-px) 100%, var(--beat-px) 100%;
}
.dense .lane { background-size: var(--bar-px) 100%, 0 0; }
.track-row.selected .lane { background-color: #1e2025; }

.add-row { height: 34px; }
.add-cell { align-items: center; padding-left: 10px; background: var(--panel); }
.add-track {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 24px;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: linear-gradient(#33363d, #2a2d33);
  color: var(--text);
  font-weight: 600;
  cursor: pointer;
}
.add-track:hover { background: linear-gradient(#3a3d45, #30333a); }
.lane.filler { background-color: transparent; }

/* Clips */
.clip {
  position: absolute;
  top: 3px;
  bottom: 3px;
  overflow: hidden;
  border-radius: 3px;
  /* Plain fallbacks first for Safari < 16.2 (no color-mix). */
  border: 1px solid var(--track-color);
  background: #2a2c31;
  border: 1px solid color-mix(in srgb, var(--track-color) 75%, #000);
  background: color-mix(in srgb, var(--track-color) 26%, #121316);
}
.clip-label {
  height: 14px;
  padding: 0 5px;
  font-size: 10px;
  line-height: 14px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: rgba(255, 255, 255, 0.92);
  background: var(--track-color);
  background: color-mix(in srgb, var(--track-color) 62%, #000);
}
.clip .wave {
  position: absolute;
  left: 0;
  top: 15px;
  width: 100%;
  height: calc(100% - 16px);
  fill: var(--track-color);
  stroke: var(--track-color);
  fill: color-mix(in srgb, var(--track-color) 80%, #fff);
  stroke: color-mix(in srgb, var(--track-color) 80%, #fff);
  stroke-width: 0.6px;
}
.clip.loading { animation: pulse 1.2s ease-in-out infinite; }
.clip.error {
  border-color: var(--rec);
  background: repeating-linear-gradient(45deg, #3b1d1f 0 6px, #2a1517 6px 12px);
}
.clip.saving .clip-label { font-style: italic; }
.clip-progress { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: rgba(0, 0, 0, 0.45); }
.clip-progress > div { height: 100%; background: #fff; transition: width 0.15s; }
.clip.failed { border: 1px dashed var(--rec); }
.clip.failed .clip-label { background: var(--rec); }
.clip.recording { border-color: var(--rec); background: rgba(229, 72, 77, 0.22); }
.clip.recording .clip-label { background: var(--rec); }
.clip.recording .wave { fill: #ffc9cb; stroke: #ffc9cb; }
@keyframes pulse { 50% { opacity: 0.45; } }

/* Playhead */
.playhead {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 1px;
  background: #f4f4f4;
  z-index: 4;
  pointer-events: none;
  will-change: transform;
}

.load-error { padding: 40px 20px; text-align: center; color: var(--text-dim); }

/* Menus */
.menu {
  position: fixed;
  z-index: 50;
  min-width: 170px;
  padding: 4px;
  background: #2b2e34;
  border: 1px solid #0b0c0e;
  border-radius: 4px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}
.menu-item {
  display: block;
  width: 100%;
  padding: 5px 10px;
  border: 0;
  border-radius: 2px;
  background: none;
  text-align: left;
  cursor: pointer;
}
.menu-item:hover { background: var(--accent); color: #171a16; }
.menu-item.danger { color: #ff8d8f; }
.menu-item.danger:hover { background: var(--rec); color: #fff; }
.swatches { display: grid; grid-template-columns: repeat(6, 20px); gap: 5px; padding: 6px 8px; }
.swatch { width: 20px; height: 20px; border: 1px solid #000; border-radius: 3px; cursor: pointer; padding: 0; }
.swatch.on { outline: 2px solid #fff; outline-offset: 1px; }

/* Toasts */
.toasts { position: fixed; right: 14px; bottom: 14px; display: grid; gap: 6px; z-index: 60; }
.toast {
  padding: 7px 12px;
  background: #2f333a;
  border: 1px solid #0b0c0e;
  border-left: 3px solid var(--accent);
  border-radius: 3px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
  max-width: 360px;
}

/* ── Home ─────────────────────────────────────────────────────────── */

.home-page { background: #101211; }
.home-topbar { max-width: 1200px; height: 88px; padding: 0 32px; margin: auto; background: transparent; border-color: #2a2e29; gap: 18px; }
.home-topbar .brand { font-size: 23px; letter-spacing: -1px; }
.home-topbar .product-mark { width: 34px; height: 34px; }
.brand-byline { color: var(--text-dim); font: 10px var(--mono); padding-left: 18px; border-left: 1px solid #383d35; }
.home-nav { display: flex; align-items: center; gap: 28px; margin-left: auto; font-size: 12px; }
.home-nav a { color: #c3c6bc; text-decoration: none; padding-block: 12px; }
.home-nav a:hover { color: var(--lamp); }
.home-nav a span { margin-left: 5px; }
.home { max-width: 1200px; margin: 0 auto; padding: 0 32px 64px; }
.eyebrow { font: 10px/1.5 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--text-dim); }
.signal-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--lamp); box-shadow: 0 0 10px #d8ae7530; flex: none; }
.hero { display: grid; grid-template-columns: 1fr 1fr; gap: 54px; align-items: center; padding: 72px 0 58px; }
.hero-copy > .eyebrow { display: flex; align-items: center; gap: 10px; margin: 0 0 24px; color: var(--lamp); }
.hero h1 { font-size: clamp(42px, 4.8vw, 64px); line-height: 1.08; letter-spacing: -.055em; font-weight: 650; margin: 0 0 26px; }
.hero h1 > span { color: var(--lamp); }
.hero-description { max-width: 370px; color: #adb2a9; font-size: 15px; line-height: 1.7; margin: 0 0 28px; }
.home .btn.primary { background: #e2d9c6; border: 1px solid #eee5d3; color: #1a1d18; border-radius: 5px; height: 40px; padding: 0 16px; }
.home .btn.primary:hover { background: #f3ead7; }
.home .btn.hero-cta { height: 48px; gap: 12px; font-size: 13px; }
.hero-cta svg { width: 17px; height: 17px; }
.cta-arrow { margin-left: 17px; font-size: 17px; }
.cta-note { font-size: 11px; color: var(--text-dim); margin: 12px 0 0; }
.origin-note { max-width: 36em; font-size: 13px; color: var(--text-dim); line-height: 1.7; overflow-wrap: anywhere; }
.session-figure { margin: 28px 0 0; min-width: 0; }
.session-caption { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 0 2px 15px; }
.session-caption .eyebrow, .session-no { font: 9px var(--mono); letter-spacing: .06em; }
.session-no { color: #93998e; white-space: nowrap; }
.session-preview { border: 1px solid #41453b; border-radius: 8px; background: #191c19; overflow: hidden; box-shadow: 0 24px 64px #0004, 0 1px 0 #ffffff0a inset; transform: rotate(-2deg); }
.preview-title { height: 48px; display: flex; align-items: center; gap: 9px; padding: 0 16px; border-bottom: 1px solid #30352e; font-size: 12px; font-weight: 600; }
.preview-format { margin-left: auto; color: #a5ac9e; font: 9px var(--mono); }
.preview-transport { display: flex; height: 46px; align-items: center; gap: 18px; padding: 0 18px; background: #232720; border-bottom: 1px solid #30352e; }
.preview-stop { width: 8px; height: 8px; background: #9da398; }
.preview-play { border-left: 9px solid #c2c8b9; border-top: 5px solid transparent; border-bottom: 5px solid transparent; }
.preview-record { width: 9px; height: 9px; background: #e07868; border-radius: 50%; }
.preview-position { font: 13px var(--mono); background: #131611; padding: 6px 12px; border: 1px solid #343c2c; border-radius: 3px; color: #e2dccb; }
.preview-mode { margin-left: auto; font: 8px var(--mono); letter-spacing: .1em; color: #a5ac9e; }
.preview-ruler, .preview-track { display: grid; grid-template-columns: 118px 1fr; }
.preview-ruler { height: 27px; font: 8px var(--mono); color: #9ca591; background: #121510; }
.preview-ruler > span { padding: 8px 14px; border-right: 1px solid #353c2d; letter-spacing: .08em; }
.preview-ruler > div { display: grid; grid-template-columns: repeat(4, 1fr); }
.preview-ruler > div span { border-left: 1px solid #343b2e; padding: 8px; }
.preview-track { height: 83px; border-bottom: 1px solid #32382e; --clip-color: #d8ae75; }
.preview-track.bass { --clip-color: #98b6a2; }
.preview-track.texture { --clip-color: #a5a6cf; }
.preview-track-label { position: relative; border-right: 1px solid #343b2e; border-left: 3px solid var(--clip-color); padding: 17px 8px 8px 13px; background: #22261f; }
.preview-track-label strong { display: block; font-size: 10px; font-weight: 500; }
.preview-track-label small { color: #a2a998; font-size: 9px; }
.preview-track-number { display: block; font: 8px var(--mono); color: var(--clip-color); margin-bottom: 5px; }
.preview-lane { min-width: 0; padding: 8px 10px; background: repeating-linear-gradient(90deg, #ffffff07 0 1px, transparent 1px 25%); }
.preview-clip { height: 100%; border: 1px solid color-mix(in srgb, var(--clip-color) 45%, #171a16); border-radius: 3px; color: var(--clip-color); background: color-mix(in srgb, var(--clip-color) 12%, #171a16); overflow: hidden; }
.preview-clip > span { display: block; font: 8px var(--mono); padding: 4px 7px; border-bottom: 1px solid color-mix(in srgb, var(--clip-color) 25%, #171a16); }
.illustrated-wave { display: block; width: 100%; height: 100%; }
.preview-clip .illustrated-wave { height: 40px; }
.bass .preview-clip { margin-left: 16%; }
.texture .preview-clip { margin-left: 29%; }
.preview-bottom { display: flex; justify-content: space-between; align-items: center; height: 33px; padding: 0 13px; color: #a2a998; font: 8px var(--mono); }
.preview-meter { color: #b3c1a3; letter-spacing: 1px; }
.session-figure figcaption { display: flex; justify-content: center; align-items: center; gap: 10px; margin-top: 26px; color: var(--text-dim); font-size: 11px; }
.layer-dots { display: flex; padding-left: 5px; }
.layer-dots i { width: 14px; height: 14px; border-radius: 50%; border: 2px solid #101211; background: #d8ae75; margin-left: -5px; }
.layer-dots i:nth-child(2) { background: #98b6a2; }
.layer-dots i:nth-child(3) { background: #a5a6cf; }
.home-details { display: flex; justify-content: space-between; gap: 20px; padding: 22px 0; border-block: 1px solid #2a2e29; color: #acb1a6; font-size: 11px; }
.home-details > span { display: flex; align-items: center; gap: 9px; }
.home-details > span > span { color: var(--lamp); font-size: 17px; }
.how-it-works { padding-top: 68px; scroll-margin-top: 30px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 32px; }
.section-heading .eyebrow { margin: 0 0 10px; color: var(--lamp); }
.section-heading h2 { font-size: 29px; font-weight: 550; letter-spacing: -.035em; margin: 0; }
.section-heading > p { margin: 0 0 2px; font-size: 12px; line-height: 1.7; color: var(--text-dim); }
.steps { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px; margin: 0; padding: 0; }
.step-art { height: 124px; border: 1px solid #30362c; border-radius: 5px; background: #181c16; margin-bottom: 25px; display: flex; align-items: center; justify-content: center; padding: 20px 22px; color: var(--lamp); overflow: hidden; }
.record-art { gap: 15px; }
.art-record { width: 11px; height: 11px; flex: none; border-radius: 50%; background: #e07868; box-shadow: 0 0 0 7px #e078680d; }
.record-art .illustrated-wave { flex: 1; min-width: 0; height: 55px; }
.art-time { font: 9px var(--mono); color: #adb5a5; }
.share-art { gap: 7px; }
.art-person { display: grid; place-items: center; flex: none; width: 48px; height: 48px; border: 1px solid #63583e; border-radius: 50%; color: #d8ae75; background: #d8ae7509; font: 9px var(--mono); }
.art-person.friend { color: #98b6a2; border-color: #435949; background: #98b6a209; width: 58px; height: 58px; }
.share-art svg { min-width: 45px; width: 120px; fill: none; stroke: #8f9a84; stroke-width: 1.5; }
.layers-art { flex-direction: column; gap: 5px; padding: 20px 45px; }
.art-layer { width: 100%; height: 24px; background: #d8ae7514; border: 1px solid #d8ae7540; border-radius: 2px; color: #d8ae75; }
.art-layer:nth-child(2) { width: 78%; align-self: end; color: #98b6a2; border-color: #98b6a240; background: #98b6a214; }
.art-layer:nth-child(3) { width: 63%; align-self: end; color: #a5a6cf; border-color: #a5a6cf40; background: #a5a6cf14; }
.step-heading { display: flex; align-items: baseline; gap: 11px; }
.step-number { color: var(--lamp); font: 10px var(--mono); }
.step h3 { font-size: 17px; font-weight: 550; letter-spacing: -.02em; margin: 0; }
.step > p { font-size: 12px; line-height: 1.85; color: #a9afa2; margin: 12px 0 0; max-width: 29em; }
.headphone-tip { display: flex; align-items: center; justify-content: center; gap: 10px; margin: 36px 0 0; padding: 20px 0 0; color: var(--text-dim); font-size: 11px; }
.headphone-tip svg { width: 17px; height: 17px; flex: none; color: var(--lamp); }
.browser-head { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin: 54px 0 28px; }
.browser-head h1 { margin: 0; font-size: 34px; letter-spacing: -.035em; }
.browser-head .eyebrow { color: var(--lamp); margin: 0 0 6px; }
.drop-table-wrap { width: 100%; overflow-x: auto; border: 1px solid #343a30; border-radius: 6px; }
.drop-table { width: 100%; border-collapse: collapse; background: #191d17; }
.drop-table th, .drop-table td { padding: 16px 18px; text-align: left; border-bottom: 1px solid #30362b; }
.drop-table th { font: 10px var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--text-dim); background: #20251d; }
.drop-table th:not(:first-child), .drop-table td:not(:first-child) { white-space: nowrap; }
.drop-table tr:last-child td { border: 0; }
.drop-table tr:hover td { background: #242a20; }
.drop-table a { color: var(--text); font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.drop-table a:hover { color: var(--lamp); }
.empty-drops { padding: 60px 20px; text-align: center; border: 1px dashed #343a30; border-radius: 6px; background: #171b15; }
.empty-record { display: inline-grid; place-items: center; height: 42px; width: 42px; color: var(--lamp); font-size: 18px; border: 1px solid #464532; border-radius: 50%; }
.empty-drops h2 { font-size: 18px; font-weight: 500; }

/* Documents (privacy, terms) and the footer linking to them. */
.doc { max-width: 680px; margin: 0 auto; padding: 22px 16px 24px; font-size: 14px; line-height: 1.6; }
.doc h1 { font-size: 24px; margin: 18px 0 2px; }
.doc h2 { font-size: 15px; margin: 26px 0 6px; }
.doc p, .doc ul { margin: 0 0 10px; }
.doc ul { padding-left: 20px; }
.doc li { margin: 3px 0; }
.doc code { font-family: var(--mono); font-size: 12px; }
.site-footer { display: flex; align-items: center; flex-wrap: wrap; gap: 28px 36px; max-width: 1200px; margin: 0 auto; padding: 32px 32px 36px; border-top: 1px solid #2a2e29; font-size: 12px; }
.studio-brand { display: flex; width: fit-content; align-items: center; gap: 9px; color: inherit; text-decoration: none; font-size: 15px; font-weight: 600; letter-spacing: -.04em; line-height: 1.05; }
.studio-mark { width: 30px; height: 30px; flex: none; }
.studio-audio { display: block; font-size: 10px; letter-spacing: .17em; font-weight: 400; margin-top: 4px; }
.footer-studio p { color: var(--text-dim); font-size: 10px; margin: 13px 0 0; }
.footer-contact { display: flex; flex-direction: column; gap: 9px; margin-left: auto; }
.footer-contact .eyebrow { font-size: 8px; }
.footer-contact a { color: var(--text); text-decoration: none; }
.footer-contact a span { margin-left: 10px; color: var(--lamp); }
.footer-links { display: flex; gap: 18px; font-size: 11px; }
.footer-links a { color: var(--text-dim); text-underline-offset: 4px; }
.site-footer a:hover { color: var(--lamp); }

/* A little hardware finish; the arrangement stays a compact DAW. */
.daw .topbar { background: linear-gradient(#2b2e2b, #222522); border-bottom-color: #090b09; box-shadow: 0 1px 0 #ffffff08 inset; height: 50px; }
.daw .brand { letter-spacing: -.04em; padding: 0 6px; }
.daw .drop-name { border-left: 1px solid #42473e; border-radius: 0; padding-left: 12px; }
.daw .transport { padding: 3px; background: #151815; border: 1px solid #353d30; border-radius: 5px; gap: 3px; }
.daw .lcd { background: #10150e; border-color: #080b06; box-shadow: 0 1px 0 #ffffff0b; }
.daw .lcd-main { color: #e0dfbe; }
.daw .lcd-sub { color: #a2ac90; }
.daw .field-btn, .daw .field-static { background: #131810; border-color: #090c07; }
.daw .tbtn { box-shadow: 0 1px 0 #ffffff0a inset; }
.daw .share-btn { background: #d8ae75; color: #201d13; border-color: #e3be8b; }
.daw .share-btn:hover { background: #e6c38f; }
.daw .ruler-row, .daw .corner { background-color: #242824; }
.daw .track-header { background: #272c26; }
.daw .track-row.selected .track-header { background: #343b30; }
.daw .track-row.selected .lane { background-color: #20251f; }
.daw .track-name { color: #e0e2d8; }
.daw .clip { box-shadow: 0 1px 3px #0003; }
.daw .playhead { box-shadow: 0 0 5px #ffffff20; }
.daw-footer { flex: none; display: flex; align-items: center; gap: 24px; min-height: 30px; padding: 4px 14px; background: #1d211c; border-top: 1px solid #353d30; font: 9px var(--mono); color: #a2ac99; }
.daw-workspace-label { text-transform: uppercase; letter-spacing: .07em; }
.daw-shortcuts { display: flex; align-items: center; gap: 6px; }
.daw-shortcuts kbd { font: 8px var(--mono); padding: 1px 4px; border: 1px solid #454d3f; border-radius: 3px; color: #c9cebe; margin-left: 8px; }
.daw-studio { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; color: #c9cebe; text-decoration: none; }
.daw-studio:hover { color: var(--lamp); }
.daw-studio .studio-mark { width: 15px; height: 15px; }
:focus-visible { outline: 2px solid var(--lamp); outline-offset: 4px; }
.skip-link { position: fixed; top: -100px; left: 16px; z-index: 100; padding: 12px 18px; background: #e2d9c6; color: #101211; }
.skip-link:focus { top: 12px; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* Narrow screens: keep the DAW layout, just tighter. */
@media (max-width: 760px) {
  :root { --header-w: 150px; }
  .topbar { overflow-x: auto; }
  .drop-name, .author-input, .zoom { display: none; }
}

@media (max-width: 960px) {
  .hero { gap: 32px; padding-top: 55px; }
  .hero h1 { font-size: 50px; }
  .preview-ruler, .preview-track { grid-template-columns: 96px 1fr; }
  .preview-track-label { padding-left: 9px; }
  .preview-track-label strong { font-size: 9px; }
  .session-no, .preview-mode { display: none; }
  .steps { gap: 20px; }
  .step-art { padding-inline: 16px; }
  .section-heading h2 { font-size: 26px; }
  .daw-shortcuts { display: none; }
}
@media (max-width: 760px) {
  .home-topbar { height: 72px; padding-inline: 22px; overflow: visible; }
  .home-topbar .brand { font-size: 21px; }
  .home-topbar .product-mark { width: 28px; height: 28px; }
  .brand-byline { display: none; }
  .home-nav { gap: 18px; font-size: 11px; min-width: 0; }
  .account-name { max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .home { padding: 0 22px 40px; }
  .hero { grid-template-columns: 1fr; padding: 44px 0 34px; gap: 28px; }
  .hero h1 { font-size: clamp(42px, 8.5vw, 64px); }
  .desktop-break { display: none; }
  .hero-description { max-width: 32em; }
  .session-figure { margin: 15px 5px 0; }
  .session-no, .preview-mode { display: block; }
  .preview-ruler, .preview-track { grid-template-columns: 110px 1fr; }
  .preview-track-label strong { font-size: 10px; }
  .preview-track { height: 76px; }
  .preview-clip .illustrated-wave { height: 34px; }
  .home-details { flex-direction: column; gap: 10px; padding-block: 20px; }
  .how-it-works { padding-top: 40px; }
  .section-heading { display: block; margin-bottom: 24px; }
  .section-heading h2 { font-size: 26px; }
  .section-heading > p { margin-top: 14px; }
  .steps { grid-template-columns: 1fr; gap: 30px; }
  .step-art { height: 118px; margin-bottom: 18px; }
  .record-art { padding-inline: 30px; }
  .layers-art { padding-inline: 60px; }
  .step > p { max-width: none; margin-top: 8px; font-size: 13px; }
  .headphone-tip { align-items: start; line-height: 1.7; text-align: left; }
  .headphone-tip svg { margin-top: 2px; }
  .site-footer { padding: 30px 22px; gap: 26px; align-items: start; flex-direction: column; }
  .footer-contact { margin-left: 0; }
  .footer-contact a { overflow-wrap: anywhere; }
  .browser-head { margin-top: 35px; }
  .daw-footer { gap: 10px; padding-inline: 10px; font-size: 8px; }
}
@media (max-width: 380px) {
  .hero h1 { font-size: 38px; }
  .home-topbar { flex-wrap: wrap; height: auto; padding-block: 16px 12px; gap: 10px; }
  .home-nav { width: 100%; justify-content: space-between; }
  .session-no, .preview-mode { display: none; }
  .home-nav { gap: 12px; }
  .preview-ruler, .preview-track { grid-template-columns: 96px 1fr; }
}

/* Account colors reuse the DAW's palette, including lanes, faders and chrome. */
:root[data-theme="aurora"], .palette-aurora {
  --bg: #111b1d; --panel: #19292d; --panel-2: #203339; --panel-3: #29434a;
  --lane: #142327; --line: #0c1719; --line-soft: #36515a;
  --text: #e6f1ec; --text-dim: #a1bdb7; --accent: #8bddbd; --lamp: #8bddbd;
}
:root[data-theme="midnight-tape"], .palette-midnight-tape {
  --bg: #191723; --panel: #252236; --panel-2: #302b42; --panel-3: #3d3654;
  --lane: #1e1b2a; --line: #100f19; --line-soft: #514463;
  --text: #f0e7ef; --text-dim: #b9abc4; --accent: #d4aff0; --lamp: #d4aff0;
}
.palette-studio { --panel: #212328; --panel-2: #27292f; --lane: #1a1b1f; --accent: #d8ae75; --line-soft: #34373e; }
:root:not([data-theme="studio"]) .home-page,
:root:not([data-theme="studio"]) .home-topbar { background: var(--bg); }
.account-page { min-height: 100vh; }
.account-main { max-width: 1040px; padding: 72px 32px 96px; margin: auto; font-size: 15px; line-height: 1.65; }
.account-main[data-view="support"], .account-main[data-view="thanks"] { max-width: 780px; }
.account-main h1 { font-size: clamp(30px, 4.2vw, 48px); line-height: 1.12; letter-spacing: -.045em; margin: 12px 0 20px; }
.account-main h2 { font-size: 19px; line-height: 1.3; margin: 0 0 8px; letter-spacing: -.02em; }
.account-intro { color: var(--text-dim); font-size: 20px; max-width: 600px; }
.account-main .btn { min-height: 44px; padding: 10px 18px; font-size: 14px; }
.account-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 16px 0; }
.support-symbol { display: grid; place-items: center; color: var(--accent); border: 1px solid var(--line-soft); border-radius: 50%; width: 62px; height: 62px; font-size: 34px; margin-bottom: 30px; }
.support-form { margin: 36px 0 26px; max-width: 520px; }
.support-form fieldset { padding: 0; border: 0; margin: 0 0 24px; }
.support-form legend { margin-bottom: 12px; font-size: 13px; }
.support-amounts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.support-amounts label { position: relative; cursor: pointer; }
.support-amounts input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.support-amounts span { display: block; padding: 15px; text-align: center; font-size: 24px; font-weight: 650; border: 1px solid var(--line-soft); border-radius: 8px; background: var(--panel); }
.support-amounts input:checked + span { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); color: var(--accent); }
.support-amounts input:focus-visible + span { outline: 2px solid var(--text); outline-offset: 4px; }
.support-submit { width: 100%; justify-content: center; }
.checkout-note { font-size: 12px; text-align: center; }
.support-fineprint { font-size: 12px; color: var(--text-dim); max-width: 490px; margin-top: 32px; }
.signin-support { border-top: 1px solid var(--line-soft); margin: 30px 0; padding-top: 15px; }
.theme-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin: 36px 0 26px; }
.theme-card { min-width: 0; }
.theme-preview { border: 1px solid var(--line-soft); border-radius: 12px; padding: 14px; width: 100%; text-align: left; background: var(--panel); cursor: pointer; }
.theme-preview:hover { border-color: var(--text-dim); }
.theme-preview[aria-pressed="true"] { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.theme-title { display: flex; gap: 6px; justify-content: space-between; align-items: center; font-weight: 650; font-size: 15px; margin-top: 16px; }
.theme-label { color: var(--text-dim); font-size: 10px; font-weight: 400; }
.theme-description { display: block; font-size: 12px; color: var(--text-dim); margin-top: 5px; }
.mini-daw { display: block; background: var(--lane); border: 1px solid var(--line-soft); border-radius: 6px; overflow: hidden; height: 144px; }
.mini-top { display: flex; align-items: center; gap: 5px; height: 28px; background: var(--panel-2); border-bottom: 1px solid var(--line-soft); padding: 8px; }
.mini-top i { height: 4px; width: 15px; background: var(--accent); opacity: .7; }
.mini-track { display: flex; height: 38px; border-bottom: 1px solid var(--line-soft); position: relative; align-items: center; }
.mini-track > i { width: 36px; background: var(--panel); border-right: 1px solid var(--line-soft); height: 100%; margin-right: 12px; }
.mini-track b { font-size: 24px; line-height: 25px; height: 25px; width: 66%; letter-spacing: 2px; background: var(--accent); color: var(--lane); border-radius: 3px; overflow: hidden; opacity: .8; }
.mini-track:nth-child(3) b { width: 40%; margin-left: 18%; opacity: .5; }
.mini-track:nth-child(4) b { width: 55%; opacity: .65; }
.theme-actions { display: flex; align-items: center; justify-content: space-between; gap: 25px; padding: 20px 0; border-bottom: 1px solid var(--line-soft); }
.theme-actions p { margin: 0; max-width: 460px; font-size: 13px; }
.account-support { margin-top: 42px; font-size: 14px; }
.account-support p { color: var(--text-dim); }
.support-card { display: flex; align-items: center; justify-content: space-between; gap: 30px; border: 1px solid var(--line-soft); border-radius: 12px; padding: 28px 32px; margin-top: 40px; background: var(--panel); }
.support-card h2 { font-size: 21px; margin: 4px 0 10px; }
.support-card p { color: var(--text-dim); font-size: 14px; line-height: 1.6; margin: 0; }
.support-card .eyebrow { color: var(--accent); font-size: 10px; }
.support-card .btn { white-space: nowrap; }
.supporter-thanks { color: var(--accent); padding: 22px 0; font-size: 13px; line-height: 1.8; }
.supporter-thanks a { margin-left: 12px; }
@media (max-width: 700px) {
  .account-main { padding: 42px 20px 64px; }
  .theme-grid { grid-template-columns: 1fr; gap: 14px; }
  .mini-daw { height: 120px; }
  .mini-track { height: 30px; }
  .theme-actions, .support-card { align-items: flex-start; flex-direction: column; gap: 12px; }
  .support-card { padding: 24px; }
  .home-nav .account-name { display: none; }
  .account-page .home-nav { gap: 12px; font-size: 11px; }
}
.account-page .btn.primary { background: var(--accent); border-color: var(--accent); color: var(--bg); }
.account-page .btn.primary:hover { filter: brightness(1.08); }
:root:not([data-theme="studio"]) .daw .share-btn { background: var(--accent); border-color: var(--accent); color: var(--bg); }

/* Language menu (topbars, DAW footer). */
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.lang-picker { position: relative; display: inline-flex; align-items: center; gap: 6px; flex: none; color: #c3c6bc; font-size: 12px; cursor: pointer; }
.lang-picker svg { width: 15px; height: 15px; flex: none; opacity: 0.8; }
.lang-select { appearance: none; -webkit-appearance: none; padding: 5px 22px 5px 8px; border: 1px solid var(--line-soft); border-radius: 6px; background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%23a0a59f' stroke-width='1.4'/%3E%3C/svg%3E") no-repeat right 7px center / 9px; color: inherit; font: inherit; cursor: pointer; }
.lang-select:hover { border-color: var(--text-dim); }
.lang-select:focus-visible { outline: 2px solid var(--lamp, var(--accent)); outline-offset: 2px; }
.lang-select option { background: var(--panel); color: var(--text); }
.doc-topbar { gap: 14px; }
.doc-topbar .lang-picker { margin-left: auto; }
.daw-footer .lang-picker { margin-left: auto; font: inherit; color: inherit; }
.daw-footer .lang-picker + .daw-studio { margin-left: 0; }
.daw-footer .lang-picker svg { width: 12px; height: 12px; }
.daw-footer .lang-select { padding: 2px 18px 2px 6px; border-radius: 4px; background-position: right 5px center; }
@media (max-width: 760px) {
  .lang-picker { font-size: 11px; }
  .lang-select { padding: 4px 20px 4px 6px; }
}

/* Audio files dragged over the arrangement: the target track and where the clip will start. */
.track-row.drop-target .lane { background-color: color-mix(in srgb, var(--track-color, var(--accent)) 14%, var(--lane)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--track-color, var(--accent)) 60%, transparent); }
.add-row.drop-target .lane { background-color: color-mix(in srgb, var(--accent) 10%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 50%, transparent); }
.drop-marker { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: var(--track-color, var(--accent)); box-shadow: 0 0 8px var(--track-color, var(--accent)); pointer-events: none; z-index: 4; }

/* Clip editing: selection, trim edges, dragging, box selection. */
.clip.editable { cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none; }
.clip.selected { box-shadow: inset 0 0 0 2px #fff, 0 0 0 1px rgba(0, 0, 0, 0.6); z-index: 2; }
.clip.selected .clip-label { background: #fff; color: #111; }
.clip-edge { position: absolute; top: 0; bottom: 0; width: 7px; z-index: 3; cursor: ew-resize; }
.clip-edge[data-edge="start"] { left: 0; }
.clip-edge[data-edge="end"] { right: 0; }
.clip.editable:hover .clip-edge, .clip.trimming .clip-edge { background: rgba(255, 255, 255, 0.12); }
.clip.dragging { pointer-events: none; z-index: 6; opacity: 0.85; box-shadow: inset 0 0 0 2px #fff, 0 8px 22px rgba(0, 0, 0, 0.5); }
body.clip-dragging, body.clip-dragging * { cursor: grabbing !important; }
.marquee { position: absolute; z-index: 7; pointer-events: none; border: 1px solid var(--accent); background: color-mix(in srgb, var(--accent) 16%, transparent); }

/* Transport: undo/redo and the snap grid. */
.edit-tools { display: flex; align-items: center; gap: 4px; flex: none; }
.grid-picker { display: inline-flex; align-items: center; gap: 4px; margin-left: 4px; color: var(--text-dim); cursor: pointer; }
.grid-picker .icon { width: 13px; height: 13px; fill: currentColor; }
.grid-select { appearance: none; -webkit-appearance: none; height: 26px; padding: 0 20px 0 7px; border: 1px solid #0d0e10; border-radius: 3px; background: #24262b url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%23a0a59f' stroke-width='1.4'/%3E%3C/svg%3E") no-repeat right 6px center / 8px; color: var(--text); font: 600 11px var(--mono); cursor: pointer; }
.grid-select:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.grid-select option { background: var(--panel); color: var(--text); }

/* Menus: shortcuts and separators. */
.menu-item { display: flex; justify-content: space-between; align-items: center; gap: 24px; }
.menu-shortcut { color: var(--text-dim); font: 11px var(--mono); }
.menu-item:hover .menu-shortcut { color: inherit; }
.menu-item:disabled { opacity: 0.4; cursor: default; }
.menu-item:disabled:hover { background: none; color: inherit; }
.menu-sep { height: 1px; margin: 4px 2px; background: #41454d; }
@media (max-width: 760px) { .edit-tools .grid-picker .icon { display: none; } }

/* Loop region: the ruler's top strip, and lines across the arrangement while looping. */
.loop-strip { position: absolute; left: 0; right: 0; top: 0; height: 12px; z-index: 2; cursor: crosshair; background: rgba(255, 255, 255, 0.025); border-bottom: 1px solid rgba(0, 0, 0, 0.35); }
.loop-strip:hover { background: rgba(255, 255, 255, 0.06); }
.loop-band { position: absolute; top: 1px; bottom: 1px; min-width: 4px; border-radius: 2px; cursor: grab; background: #5b606b; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.35); }
.loop-band.on { background: var(--accent); box-shadow: 0 0 10px color-mix(in srgb, var(--accent) 45%, transparent); }
.loop-marker { position: absolute; top: -1px; bottom: -1px; width: 7px; cursor: ew-resize; }
.loop-marker[data-edge="start"] { left: -3px; border-left: 3px solid #f4f4f4; }
.loop-marker[data-edge="end"] { right: -3px; border-right: 3px solid #f4f4f4; }
.loop-line { position: absolute; top: var(--ruler-h); bottom: 0; left: 0; width: 1px; z-index: 3; pointer-events: none; background: color-mix(in srgb, var(--accent) 70%, transparent); }

/* ── Instruments, mixer and collaboration ─────────────────────────── */

/* Top bar: view buttons and the faces of the others; never cut off (scrolls sideways if it must). */
.daw .topbar { overflow-x: auto; scrollbar-width: none; }
.daw .topbar::-webkit-scrollbar { display: none; }
.daw .topbar > * { flex: none; }
.daw .topbar .spacer { flex: 1 0 8px; }
.view-tools { display: flex; align-items: center; gap: 3px; flex: none; }
.notepad-btn.unread { position: relative; }
.notepad-btn.unread::after { content: ""; position: absolute; top: 3px; right: 3px; width: 7px; height: 7px; border-radius: 50%; background: var(--rec); box-shadow: 0 0 0 2px var(--panel); }
.presence { display: flex; align-items: center; flex: none; padding-left: 4px; }
.presence:empty { display: none; }
.avatar { display: grid; place-items: center; width: 28px; height: 28px; margin-left: -6px; border-radius: 50%; border: 2px solid var(--panel); background: hsl(var(--avatar-hue, 30) 55% 46%); color: #fff; font: 700 10px/1 ui-sans-serif, system-ui, sans-serif; letter-spacing: .02em; cursor: default; user-select: none; }
.avatar:first-child { margin-left: 0; }
.avatar.owner { box-shadow: 0 0 0 1px var(--accent); }
.avatar.recording { border-color: var(--rec); animation: pulse 1.4s ease-in-out infinite; }
.avatar.playing { border-color: var(--play); }
.avatar.more { background: var(--panel-3); color: var(--text-dim); }

/* Layout: the arrangement with the side panel next to it, the editor dock below. */
.workspace { flex: 1; min-height: 0; display: flex; position: relative; }
.workspace .arrange { min-width: 0; }
.side-panel { position: relative; flex: none; width: 300px; min-width: 0; display: flex; flex-direction: column; background: var(--panel); border-left: 1px solid var(--line); }
.side-body { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.side-close { position: absolute; top: 6px; right: 6px; z-index: 2; }
.rotate-hint { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 6px 12px; background: #23303a; color: #cfe3ff; border-bottom: 1px solid var(--line); font-size: 12px; }
.rotate-hint .text-btn { color: inherit; }

/* Track headers: kind, comments, volume and pan, effects, instrument. */
.track-kind { display: grid; place-items: center; width: 14px; flex: none; color: var(--text-dim); }
.track-kind .icon { width: 12px; height: 12px; fill: currentColor; }
.track-row.midi .track-kind { color: var(--track-color); }
.track-controls { gap: 3px; }
.track-controls .knob { flex: none; }
.flag.fx { width: auto; min-width: 22px; padding: 0 3px; font-size: 9px; letter-spacing: .02em; }
.flag.fx.on { background: #2f4a3a; color: #bff0cf; }
.flag.inst { display: grid; place-items: center; }
.flag.inst .icon { width: 12px; height: 12px; fill: currentColor; }
.comment-badge { display: inline-flex; align-items: center; gap: 2px; height: 18px; padding: 0 3px; border: 0; border-radius: 2px; background: transparent; color: var(--text-dim); cursor: pointer; font-size: 10px; opacity: .55; }
.comment-badge.has { opacity: 1; color: var(--accent); }
.track-header:hover .comment-badge { opacity: 1; }
.comment-badge:hover { background: var(--panel-3); }
.comment-badge .icon { width: 12px; height: 12px; fill: currentColor; }
.add-cell { gap: 6px; }
.add-instrument { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 9px; border: 1px solid var(--line); border-radius: 3px; background: linear-gradient(#33363d, #2a2d33); color: var(--text); font-weight: 600; cursor: pointer; }
.add-instrument:hover { background: linear-gradient(#3a3d45, #30333a); }
.add-instrument .icon { width: 13px; height: 13px; fill: currentColor; }

/* MIDI clips: a miniature of the notes, with the loop repeats marked. */
.clip.midi { background: color-mix(in srgb, var(--track-color) 18%, #121316); }
.clip .notes { position: absolute; left: 0; top: 16px; width: 100%; height: calc(100% - 19px); fill: color-mix(in srgb, var(--track-color) 80%, #fff); }
.clip .notes .loop-marks { stroke: rgba(255, 255, 255, 0.3); stroke-dasharray: 2 2; fill: none; }
.clip.recording .notes { fill: #ffc9cb; }
.comment-marker { position: absolute; top: 2px; z-index: 3; display: grid; place-items: center; width: 16px; height: 16px; margin-left: -8px; padding: 0; border: 0; border-radius: 3px 3px 3px 0; background: var(--accent); color: #1a1710; cursor: pointer; box-shadow: 0 1px 4px #0006; }
.comment-marker .icon { width: 10px; height: 10px; fill: currentColor; }

/* Knobs and faders. */
.knob { display: inline-flex; flex-direction: column; align-items: center; gap: 1px; width: 42px; touch-action: none; user-select: none; -webkit-user-select: none; cursor: ns-resize; outline: none; }
.knob-dial { width: 30px; height: 30px; display: block; }
.knob-track { fill: none; stroke: #0d0e10; stroke-width: 3.5; stroke-linecap: round; }
.knob-arc { fill: none; stroke: var(--accent); stroke-width: 3.5; stroke-linecap: round; }
.knob-cap { fill: #3a3e46; stroke: #15171a; stroke-width: 1; }
.knob-pointer { stroke: #f2f2ee; stroke-width: 2; stroke-linecap: round; }
.knob:hover .knob-cap, .knob.active .knob-cap { fill: #474c56; }
.knob:focus-visible .knob-dial { outline: 2px solid var(--accent); outline-offset: 1px; border-radius: 50%; }
.knob-label { max-width: 100%; font: 9px/1.2 var(--mono); color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: center; }
.knob.active .knob-label { color: var(--text); }
.knob.sm { width: 34px; }
.knob.sm .knob-dial { width: 24px; height: 24px; }
.knob.xs { position: relative; width: 20px; gap: 0; }
.knob.xs .knob-dial { width: 19px; height: 19px; }
.knob.xs .knob-label { display: none; }
.knob.xs.active .knob-label { display: block; position: absolute; top: 20px; left: 50%; transform: translateX(-50%); z-index: 20; max-width: none; padding: 1px 4px; background: #0e0f11; border: 1px solid var(--line); border-radius: 2px; color: var(--text); }
.fader { position: relative; width: 16px; height: 100%; min-height: 70px; margin: 0 auto; border-radius: 3px; background: #0d0e10; box-shadow: inset 0 0 0 1px #000; touch-action: none; cursor: ns-resize; outline: none; }
.fader::before { content: ""; position: absolute; left: 7px; top: 6px; bottom: 6px; width: 2px; background: #2a2d33; }
.fader-thumb { position: absolute; left: -5px; width: 26px; height: 12px; margin-bottom: -6px; border-radius: 2px; background: linear-gradient(#6a6f78, #3c4048); border: 1px solid #0b0c0e; box-shadow: inset 0 5px 0 -4px #fff8, 0 2px 4px #0008; }
.fader.active .fader-thumb, .fader:focus-visible .fader-thumb { background: linear-gradient(#8a8f98, #4c5058); }

/* Device panels (instruments, effects): labelled sections of knobs. */
.device { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-start; }
.device-section { padding: 6px 8px 8px; border: 1px solid var(--line); border-radius: 5px; background: rgba(0, 0, 0, 0.18); }
.device-section h4 { display: flex; align-items: center; gap: 6px; margin: 0 0 6px; font: 700 10px/1.2 var(--mono); letter-spacing: .08em; color: var(--text-dim); text-transform: uppercase; }
.device-section h4:has(> span:empty:only-child) { display: none; }
.device-controls { display: flex; flex-wrap: wrap; gap: 6px 4px; align-items: flex-end; }
.param-choice { display: inline-flex; flex-direction: column; gap: 3px; font-size: 10px; color: var(--text-dim); }
.param-choice .param-label { font: 9px var(--mono); }
.param-select, .preset-select { height: 24px; max-width: 160px; padding: 0 6px; border: 1px solid #0d0e10; border-radius: 3px; background: #1b1d21; color: var(--text); font: 600 11px ui-sans-serif, system-ui, sans-serif; }
.led-toggle { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 6px; border: 1px solid #0d0e10; border-radius: 3px; background: #24262b; color: var(--text-dim); font-size: 10px; cursor: pointer; }
.led { width: 8px; height: 8px; border-radius: 50%; background: #2c3a2f; box-shadow: inset 0 1px 2px #000a; }
.led-toggle.on .led { background: #63e07f; box-shadow: 0 0 6px #63e07f99; }
.led-toggle.on { color: var(--text); }
.device-section h4 .led-toggle { height: 16px; padding: 0 3px; font-size: 0; gap: 0; }

/* The dock (piano roll, instrument, mixer). */
.dock { flex: none; display: flex; flex-direction: column; height: var(--dock-h, 320px); min-height: 0; background: #17191c; border-top: 1px solid #000; box-shadow: 0 -6px 18px #0005; position: relative; }
.dock.max { height: 74vh; height: 74dvh; }
.dock-handle { position: absolute; top: -4px; left: 0; right: 0; height: 8px; cursor: ns-resize; z-index: 5; touch-action: none; }
.dock-head { display: flex; align-items: center; gap: 6px; height: 34px; padding: 0 6px; background: var(--panel); border-bottom: 1px solid var(--line); flex: none; }
.dock-tabs { display: flex; gap: 2px; }
.dock-tab { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border: 1px solid transparent; border-radius: 3px; background: transparent; color: var(--text-dim); font-weight: 600; cursor: pointer; }
.dock-tab .icon { width: 13px; height: 13px; fill: currentColor; }
.dock-tab:hover { background: var(--panel-3); color: var(--text); }
.dock-tab.on { background: #0e0f11; border-color: var(--line); color: var(--text); }
.dock-title { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dock-title:not(:empty)::before { content: ""; width: 9px; height: 9px; border-radius: 2px; background: var(--track-color); }
.dock-body { flex: 1; min-height: 0; display: flex; flex-direction: column; overflow: hidden; }

/* Piano roll. */
.piano-roll { flex: 1; min-height: 0; display: flex; flex-direction: column; --pr-white: #24272c; --pr-black: #1c1e22; --pr-line: rgba(255, 255, 255, 0.045); --pr-beat: rgba(255, 255, 255, 0.1); --pr-bar: rgba(255, 255, 255, 0.24); }
.pr-toolbar { display: flex; align-items: center; gap: 6px; padding: 4px 6px; border-bottom: 1px solid var(--line); background: #1d2023; overflow-x: auto; scrollbar-width: none; flex: none; }
.pr-toolbar > * { flex: none; }
.pr-toolbar .spacer { flex: 1 0 6px; }
.pr-tools { display: flex; gap: 2px; padding: 2px; background: #0e0f11; border: 1px solid #000; border-radius: 4px; }
.pr-tool { display: grid; place-items: center; width: 28px; height: 24px; padding: 0; border: 0; border-radius: 3px; background: transparent; color: var(--text-dim); cursor: pointer; }
.pr-tool .icon { width: 14px; height: 14px; fill: currentColor; }
.pr-tool:hover { background: var(--panel-3); color: var(--text); }
.pr-tool.on { background: var(--accent); color: #1a1710; }
.pr-zoom, .pr-typing { display: flex; align-items: center; gap: 2px; }
.pr-octave { min-width: 22px; text-align: center; font: 11px var(--mono); color: var(--text-dim); }
.pr-info { font: 11px var(--mono); color: var(--text-dim); }
.pr-body { flex: 1; min-height: 0; display: grid; grid-template-columns: 64px minmax(0, 1fr); grid-template-rows: 26px minmax(0, 1fr) 72px; }
.pr-corner { background: #1d2023; border-right: 1px solid #000; border-bottom: 1px solid #000; }
.pr-velocity-label { display: flex; align-items: center; justify-content: center; background: #1d2023; border-right: 1px solid #000; border-top: 1px solid #000; font: 9px var(--mono); color: var(--text-dim); }
.pr-ruler, .pr-velocity, .pr-keys { display: block; touch-action: none; }
.pr-ruler { cursor: pointer; border-bottom: 1px solid #000; }
.pr-velocity { border-top: 1px solid #000; cursor: ns-resize; }
.pr-keys { border-right: 1px solid #000; cursor: pointer; }
.pr-main { position: relative; min-height: 0; overflow: hidden; }
.pr-scroll { position: absolute; inset: 0; overflow: auto; overscroll-behavior: contain; }
.pr-grid { position: sticky; left: 0; top: 0; display: block; touch-action: none; cursor: crosshair; }
.pr-grid[data-tool="delete"] { cursor: not-allowed; }
.pr-grid[data-tool="select"] { cursor: default; }
.pr-grid[data-tool="slice"] { cursor: col-resize; }
.pr-sizer { pointer-events: none; }
.pr-playhead { position: absolute; top: 0; bottom: 0; left: 0; width: 1px; background: #f4f4f4; box-shadow: 0 0 5px #fff6; pointer-events: none; will-change: transform; z-index: 2; }

/* Popovers: note properties, quantize, comments, tuner. */
.popover { position: fixed; z-index: 55; min-width: 220px; max-width: min(380px, calc(100vw - 16px)); padding: 10px 12px; background: #2b2e34; border: 1px solid #0b0c0e; border-radius: 6px; box-shadow: 0 14px 40px rgba(0, 0, 0, 0.55); }
.popover h4 { margin: 0 0 8px; font-size: 12px; }
.popover-head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.popover-head .icon { width: 14px; height: 14px; fill: var(--accent); }
.popover-head .muted { font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.popover-head .plugin-close { margin-left: auto; }
.popover-actions { display: flex; justify-content: flex-end; gap: 6px; margin-top: 10px; }
.audio-transform-panel { left: 50%; top: 50%; transform: translate(-50%, -50%); width: 420px; max-width: calc(100vw - 24px); max-height: calc(100vh - 24px); overflow-y: auto; }
.audio-transform-panel .popover-head { justify-content: space-between; }
.audio-transform-panel .popover-head h4 { flex: none; margin: 0; }
.audio-transform-panel .popover-head > span { max-width: 45%; }
.audio-transform-description { margin: 8px 0 16px; font-size: 12px; line-height: 1.5; color: var(--text-dim); }
.audio-transform-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.audio-transform-field { display: flex; flex-direction: column; gap: 6px; font-size: 11px; min-width: 0; }
.audio-transform-field > div { display: flex; align-items: center; gap: 7px; }
.audio-transform-field input { width: 100%; min-width: 0; padding: 8px; background: #161a20; color: var(--text); border: 1px solid #46535c; border-radius: 4px; font: 14px var(--mono); }
.audio-transform-field input:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.audio-transform-field input[aria-invalid=true] { border-color: #df8a76; }
.audio-transform-comparison { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 18px; padding: 12px; background: #1b2027; border: 1px solid #3a434c; border-radius: 5px; }
.audio-transform-comparison > div { display: grid; gap: 7px; min-width: 0; }
.audio-transform-comparison strong { font-size: 10px; color: var(--text-dim); font-weight: 500; }
.audio-transform-comparison .mono { font-size: 11px; white-space: nowrap; }
.audio-transform-bar { height: 5px; }
.audio-transform-bar i { display: block; height: 100%; border-radius: 3px; background: #7a8a99; }
.audio-transform-bar.result i { background: #65d8c5; }
.audio-transform-speed, .audio-transform-help { font-size: 10px; line-height: 1.5; }
.audio-transform-error { color: #f2a18e; font-size: 11px; line-height: 1.5; }
.audio-transform-panel .popover-actions { flex-wrap: wrap; }
.audio-transform-panel .popover-actions > :first-child { margin-right: auto; font-size: 10px; }
.clip-transform-badge { position: absolute; right: 5px; bottom: 4px; padding: 1px 4px; border-radius: 3px; background: #14252ce0; color: #9ce3d6; font: 9px var(--mono); line-height: 13px; pointer-events: none; }
.prop { display: flex; align-items: center; gap: 8px; margin: 6px 0; font-size: 11px; color: var(--text-dim); }
.prop > span:first-child { min-width: 64px; }
.prop input[type="range"] { flex: 1; accent-color: var(--accent); }
.prop input[type="number"] { width: 70px; height: 24px; padding: 0 6px; border: 1px solid #0d0e10; border-radius: 3px; background: #18191c; color: var(--text); }
.prop.check { gap: 6px; }
.prop.check > span:first-child { min-width: 0; }
.prop-row { display: flex; gap: 14px; }
.mono { font-family: var(--mono); }
.btn.small { height: 24px; padding: 0 9px; font-size: 11px; }

/* Mixer (FL Studio style): channel strips, and the selected channel's insert slots. */
.mixer { flex: 1; min-height: 0; display: flex; }
.mixer-strips { flex: 1; min-width: 0; display: flex; gap: 2px; padding: 6px; overflow-x: auto; overflow-y: hidden; background: #131417; }
.strip { flex: none; width: 66px; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 5px 3px; border: 1px solid #0b0c0e; border-top: 3px solid var(--track-color); border-radius: 3px; background: linear-gradient(#2a2d33, #222429); cursor: pointer; min-height: 0; }
.strip.master { width: 74px; background: linear-gradient(#33302a, #26241f); margin-right: 6px; }
.strip.selected { background: linear-gradient(#3a4250, #2c323d); box-shadow: 0 0 0 1px var(--accent); }
.strip-name { width: 100%; font-size: 10px; font-weight: 700; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.strip-meter { position: relative; width: 8px; height: 46px; flex: none; border-radius: 2px; background: #0b0c0e; overflow: hidden; }
.strip-level { position: absolute; left: 0; right: 0; bottom: 0; height: 0; background: linear-gradient(to top, #4cc472, #4cc472 65%, #e8c547 85%, #e5484d); }
.strip-level.hot { box-shadow: 0 -2px 0 #e5484d; }
.strip .fader { flex: 1; min-height: 60px; }
.strip-db { font-size: 9px; color: var(--text-dim); }
.strip-led, .slot-led { width: 12px; height: 12px; flex: none; padding: 0; border: 1px solid #0b0c0e; border-radius: 50%; background: #213326; cursor: pointer; }
.strip-led.on, .slot-led.on { background: #63e07f; box-shadow: 0 0 6px #63e07f88; }
.strip-led-gap, .slot-led-gap { width: 12px; height: 12px; flex: none; }
.strip-fx { min-height: 12px; font: 9px var(--mono); color: #8fd4a5; }
.mixer-rack { flex: none; width: 280px; display: flex; flex-direction: column; border-left: 1px solid #000; background: #1d1f23; overflow-y: auto; }
.rack-head { position: sticky; top: 0; z-index: 1; background: #1d1f23; padding: 6px 10px; border-bottom: 1px solid #000; font-size: 11px; color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rack-head strong { color: var(--text); }
.slots { list-style: none; margin: 0; padding: 4px; display: grid; gap: 3px; }
.slot { display: flex; align-items: center; gap: 5px; height: 26px; padding: 0 5px; border: 1px solid #0b0c0e; border-radius: 3px; background: #26292e; }
.slot.filled { background: linear-gradient(#323740, #2a2e35); }
.slot.off .slot-name { color: var(--text-dim); text-decoration: line-through; }
.slot-menu { display: grid; place-items: center; width: 20px; height: 20px; padding: 0; border: 1px solid #0b0c0e; border-radius: 2px; background: #3a3e46; color: var(--text); cursor: pointer; }
.slot-menu .icon { width: 10px; height: 10px; fill: currentColor; }
.slot-name { flex: 1; min-width: 0; height: 22px; padding: 0 6px; border: 0; border-radius: 2px; background: transparent; color: var(--text); text-align: left; font-size: 11px; font-weight: 600; cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.slot:not(.filled) .slot-name { color: #6d727b; font-weight: 400; font-style: italic; }
.slot-name:hover { background: var(--panel-3); }
.knob-gap { width: 20px; flex: none; }
.rack-hint { margin: 6px 10px 10px; font-size: 10px; color: var(--text-dim); }

/* Effect windows (like FL Studio's plugin windows). */
.plugin-window { position: fixed; z-index: 54; min-width: 260px; max-width: calc(100vw - 16px); background: #24272c; border: 1px solid #0b0c0e; border-radius: 6px; box-shadow: 0 18px 50px rgba(0, 0, 0, 0.6); }
.plugin-title { display: flex; align-items: center; gap: 8px; height: 30px; padding: 0 6px 0 9px; border-bottom: 1px solid #000; border-radius: 6px 6px 0 0; background: linear-gradient(#3a3e46, #2c2f35); cursor: move; user-select: none; touch-action: none; }
.plugin-name { font-weight: 700; }
.plugin-channel { flex: 1; color: var(--text-dim); font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plugin-close { display: grid; place-items: center; width: 22px; height: 22px; padding: 0; border: 0; border-radius: 3px; background: transparent; color: var(--text-dim); cursor: pointer; }
.plugin-close:hover { background: var(--panel-3); color: var(--text); }
.plugin-close .icon { width: 11px; height: 11px; fill: currentColor; }
.plugin-body { padding: 10px; display: flex; flex-direction: column; gap: 8px; }
.plugin-body .device-section { border: 0; background: transparent; padding: 0; }
.eq-curve { width: 100%; height: 96px; background: #141518; border: 1px solid #000; border-radius: 3px; }
.eq-editor { width: 100%; min-width: 0; padding: 0 12px; box-sizing: border-box; }
.eq-plot { position: relative; height: 180px; }
.eq-plot .eq-curve { display: block; height: 180px; }
.eq-node { position: absolute; z-index: 1; width: 24px; height: 24px; padding: 0; border: 2px solid var(--eq-band-color); border-radius: 50%; background: #20242a; color: var(--eq-band-color); transform: translate(-50%, -50%); font: 700 10px/1 ui-sans-serif, system-ui, sans-serif; cursor: grab; touch-action: none; user-select: none; }
.eq-node:hover, .eq-node:focus-visible, .eq-node.selected { background: var(--eq-band-color); color: #11151b; outline: 2px solid #11151b; outline-offset: 1px; }
.eq-editor.active .eq-node.selected { cursor: grabbing; }
.eq-graph-toolbar { display: flex; align-items: center; gap: 10px; min-height: 28px; padding-top: 6px; }
.eq-readout { flex: 1; min-width: 0; font-size: 10px; color: var(--text-dim); }
.eq-graph-toolbar button { font-size: 11px; }
.eq-graph-toolbar button:disabled { opacity: .35; cursor: default; }
.eq-graph-hint { margin: 2px 0 0; max-width: 580px; font-size: 10px; color: var(--text-dim); }
.gr-meter { position: relative; display: flex; align-items: center; height: 16px; border-radius: 2px; background: #141518; border: 1px solid #000; overflow: hidden; }
.gr-fill { position: absolute; top: 0; right: 0; bottom: 0; width: 0; background: #e8a33d; }
.gr-label { position: relative; padding-left: 6px; font-size: 9px; color: var(--text-dim); }

/* Compressor monitoring: measured envelopes, gain history and transfer curves. */
.compressor-window { width: 760px; }
.compressor-window .plugin-body { max-height: calc(100vh - 62px); overflow-y: auto; overscroll-behavior: contain; }
.compressor-view { min-width: 0; padding: 10px 10px 8px; border: 1px solid #34414b; border-radius: 6px; background: linear-gradient(130deg, #17232c, #131b22 55%, #1c252e); box-shadow: inset 0 1px #ffffff07; }
.compression-top { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-bottom: 9px; }
.compression-heading { font-size: 11px; font-weight: 700; color: #d8e5ed; }
.compression-tabs { display: flex; gap: 3px; padding: 3px; background: #0b1319; border-radius: 5px; }
.compression-tabs button { --band-color: #6fe0ce; min-height: 24px; padding: 4px 9px; border: 1px solid transparent; border-radius: 3px; background: transparent; color: #9eafbd; font-size: 10px; cursor: pointer; }
.compression-tabs button[aria-selected=true] { color: var(--band-color); background: #26333e; border-color: #40505c; box-shadow: inset 0 -2px var(--band-color); }
.compression-tabs button:focus-visible { outline: 2px solid var(--band-color); outline-offset: 2px; }
.compression-status { display: flex; align-items: center; gap: 5px; color: #8d9da9; font-size: 10px; }
.compression-status::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: #64717a; }
.compression-status.live { color: #a7d8ce; }
.compression-status.live::before { background: #6fe0ce; box-shadow: 0 0 7px #6fe0ce77; }
.compression-plots { display: grid; grid-template-columns: minmax(0, 2.1fr) minmax(0, 1fr); gap: 10px; }
.compression-plot { min-width: 0; }
.compression-caption { display: flex; justify-content: space-between; gap: 7px; padding: 0 2px 6px; font-size: 9px; color: #8d9da9; }
.compression-caption strong { color: #bccbd5; font-weight: 500; }
.compression-plot canvas { display: block; width: 100%; height: 172px; border: 1px solid #35424d; border-radius: 4px; }
.compression-footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 6px 12px; padding: 8px 0 5px; }
.compression-legend { display: flex; gap: 12px; font-size: 10px; color: #9eafbd; }
.compression-legend > span { display: inline-flex; align-items: center; gap: 5px; }
.compression-legend > span::before { content: ""; width: 12px; height: 3px; border-radius: 2px; }
.legend-input::before { background: #81929e; }
.legend-output::before { background: #6fe0ce; }
.legend-reduction::before { background: #f0b66a; }
.compression-readout { font-size: 10px; color: #cee1ea; font-variant-numeric: tabular-nums; }
.compression-note { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 4px 10px; font-size: 9px; color: #83939f; }
.compression-mix { white-space: nowrap; }
.compressor-view.bypassed .compression-plots { opacity: .45; }
.compressor-window .effect-multiband { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; }
.compressor-window .effect-multiband .device-section { padding: 8px; border: 1px solid #3b424b; border-radius: 4px; background: #1d2228; min-width: 0; }
.compressor-window .effect-multiband .device-section h4 { margin-bottom: 7px; }
.compressor-window .effect-multiband .section-crossovers { grid-column: span 2; order: 0; }
.compressor-window .effect-multiband .section-output { order: 0; }
.compressor-window .effect-multiband .section-low { --accent: #e6af6d; border-top-color: #e6af6d; order: 1; }
.compressor-window .effect-multiband .section-mid { --accent: #76d6ba; border-top-color: #76d6ba; order: 1; }
.compressor-window .effect-multiband .section-high { --accent: #92b6f8; border-top-color: #92b6f8; order: 1; }
.compressor-window .effect-multiband :is(.section-low, .section-mid, .section-high) .device-controls { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px 4px; justify-items: center; }
.compressor-window .effect-compressor .device-controls { justify-content: center; gap: 12px; }
.compressor-window .knob { width: 56px; max-width: 100%; }
.compressor-window .effect-lfo { border-top: 1px solid #3b424b; padding-top: 9px; }
@media (max-width: 600px) {
  .compression-plots { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 6px; }
  .compression-plot canvas { height: 145px; }
  .compression-caption { font-size: 8px; }
  .compression-caption > span { display: none; }
  .compression-tabs button { padding: 4px 6px; }
  .compressor-window .knob-label { font-size: 8px; }
  .compressor-window .effect-multiband { grid-template-columns: minmax(0, 1fr); }
  .compressor-window .effect-multiband .section-crossovers { grid-column: auto; }
  .compressor-window .effect-multiband :is(.section-low, .section-mid, .section-high) .device-controls { grid-template-columns: repeat(6, minmax(0, 1fr)); }
}

/* Instrument panels. */
.instrument-panel { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.instrument-head { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-bottom: 1px solid var(--line); background: #1d2023; flex: none; overflow-x: auto; scrollbar-width: none; }
.instrument-head > * { flex: none; }
.instrument-head .spacer { flex: 1 0 6px; }
.instrument-hint { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; }
.instrument-hint .icon { width: 14px; height: 14px; fill: currentColor; }
.device-brand { font: 800 13px/1 ui-sans-serif, system-ui, sans-serif; letter-spacing: .14em; color: #62e0d0; text-shadow: 0 0 10px #62e0d066; }
.device-brand b { color: var(--text); margin-left: 3px; }
.device-brand.drums { color: #ff9f5a; text-shadow: 0 0 10px #ff9f5a55; }
.instrument-scroll { flex: 1; min-height: 0; overflow: auto; padding: 8px; }
.synth-panel { --accent: #62e0d0; }
.synth-panel .device-section { background: linear-gradient(#20252b, #1a1e23); border-color: #0c1013; }
.synth-panel :is(.section-env1, .section-env2) { width: 280px; max-width: 100%; }
.synth-envelope { margin: 0 0 9px; border: 1px solid #314047; border-radius: 4px; background: #10171b; --envelope-color: #62e0d0; }
.synth-envelope.env2 { --envelope-color: #84b8fa; }
.synth-envelope figcaption { display: flex; justify-content: space-between; gap: 8px; padding: 6px 8px 0; color: #a5bbc3; font-size: 10px; }
.envelope-kind { color: var(--envelope-color); font: 10px var(--mono); letter-spacing: .12em; }
.envelope-chart { display: block; width: 100%; height: auto; font: 11px var(--mono); fill: #99aeb8; }
.envelope-grid { stroke: #34444e; stroke-width: .7; }
.envelope-fill { fill: var(--envelope-color); opacity: .09; }
.envelope-line { stroke: var(--envelope-color); stroke-width: 2; fill: none; stroke-linejoin: round; }
.envelope-note-off { stroke: #c3cdd3; stroke-width: 1; stroke-dasharray: 3 3; opacity: .65; }
.wave-view { display: block; width: 100%; max-width: 220px; height: 64px; margin-bottom: 6px; background: #0d1114; border: 1px solid #000; border-radius: 3px; }
.drum-panel { --accent: #ff9f5a; }
.drum-body { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(220px, 1fr); gap: 10px; padding: 8px; overflow: auto; }
.drum-pads { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.pads { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.pad { position: relative; display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; height: 54px; padding: 6px; border: 1px solid #0b0c0e; border-radius: 5px; background: linear-gradient(#3a3d44, #2b2e34); color: var(--text); cursor: pointer; text-align: left; touch-action: none; user-select: none; }
.pad:hover { background: linear-gradient(#444851, #33363d); }
.pad.selected { box-shadow: 0 0 0 2px var(--accent); }
.pad.hit { background: linear-gradient(#ffb37a, #ff9f5a); color: #2a1606; }
.pad-short { font: 700 10px var(--mono); color: var(--accent); }
.pad.hit .pad-short { color: inherit; }
.pad-name { font-size: 10px; color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.pad-editor { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.pad-editor-name { min-width: 90px; font-weight: 700; }
.pad-editor .device-section { border: 0; background: transparent; padding: 0; }
.drum-loops { display: flex; flex-direction: column; min-width: 0; min-height: 0; border: 1px solid var(--line); border-radius: 5px; background: rgba(0, 0, 0, 0.18); }
.loops-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 8px; border-bottom: 1px solid var(--line); }
.loop-list { list-style: none; margin: 0; padding: 4px; overflow: auto; }
.loop-item { display: flex; align-items: center; gap: 6px; padding: 3px 4px; border-radius: 3px; }
.loop-item:hover { background: var(--panel-3); }
.loop-name { flex: 1; min-width: 0; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.loop-meta { font-size: 10px; color: var(--text-dim); white-space: nowrap; }

/* Browser (side panel). */
.browser { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.panel-tabs { display: flex; gap: 2px; padding: 6px 36px 0 6px; border-bottom: 1px solid var(--line); flex: none; }
.panel-tab { height: 28px; padding: 0 10px; border: 1px solid transparent; border-bottom: 0; border-radius: 4px 4px 0 0; background: transparent; color: var(--text-dim); font-weight: 600; cursor: pointer; }
.panel-tab.on { background: #18191c; border-color: var(--line); color: var(--text); }
.browser-search { margin: 6px; height: 28px; padding: 0 8px; border: 1px solid var(--line); border-radius: 3px; background: #18191c; flex: none; }
.browser-list { flex: 1; min-height: 0; overflow-y: auto; padding: 0 4px 10px; }
.browser-group ul { list-style: none; margin: 0 0 4px; padding: 0; }
.group-head { display: flex; align-items: center; gap: 6px; width: 100%; height: 26px; padding: 0 4px; border: 0; background: transparent; color: var(--text); font-weight: 700; font-size: 11px; cursor: pointer; text-align: left; }
.group-head .icon { width: 10px; height: 10px; fill: var(--text-dim); transform: rotate(-90deg); transition: transform .12s; }
.browser-group.open .group-head .icon { transform: none; }
.group-count { margin-left: auto; font: 10px var(--mono); color: var(--text-dim); }
.browser-item { display: flex; align-items: center; gap: 7px; padding: 4px 6px; border-radius: 3px; cursor: grab; user-select: none; -webkit-user-select: none; touch-action: pan-y; }
.browser-item:hover { background: var(--panel-3); }
.browser-item > .icon { width: 13px; height: 13px; flex: none; fill: var(--text-dim); }
.item-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.item-label { font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item-meta { font-size: 10px; color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item-btn { display: grid; place-items: center; width: 22px; height: 22px; flex: none; padding: 0; border: 1px solid var(--line); border-radius: 3px; background: #2a2d33; color: var(--text); cursor: pointer; opacity: .7; }
.browser-item:hover .item-btn, .item-btn:focus-visible { opacity: 1; }
.item-btn .icon { width: 10px; height: 10px; fill: currentColor; }
.drag-ghost { position: fixed; left: 0; top: 0; z-index: 70; display: inline-flex; align-items: center; gap: 6px; padding: 5px 9px; border: 1px solid var(--accent); border-radius: 4px; background: #2b2e34; box-shadow: 0 8px 24px #0008; pointer-events: none; font-weight: 600; }
.drag-ghost .icon { width: 13px; height: 13px; fill: var(--accent); }
body.browser-dragging, body.browser-dragging * { cursor: grabbing !important; }
.browser-target.track-row .lane, .browser-target.add-row .lane { background-color: color-mix(in srgb, var(--accent) 14%, var(--lane)); box-shadow: inset 0 0 0 1px var(--accent); }
.browser-target.track-row .track-header { box-shadow: inset 0 0 0 1px var(--accent); }
.browser-target.strip, .browser-target.mixer-rack { box-shadow: inset 0 0 0 2px var(--accent); }

/* Notepad. */
.notepad { flex: 1; min-height: 0; display: flex; flex-direction: column; padding: 8px; gap: 6px; }
.notepad-head { display: flex; align-items: baseline; gap: 8px; padding-right: 30px; }
.notepad-status { font-size: 10px; color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.notepad-text { flex: 1; min-height: 0; width: 100%; resize: none; padding: 10px; border: 1px solid var(--line); border-radius: 4px; background: #16171a; color: var(--text); font: 13px/1.55 var(--mono); outline: none; tab-size: 4; }
.notepad-text:focus { border-color: var(--accent); }

/* Comments. */
.popover.comments { width: 340px; }
.comment-list { list-style: none; margin: 0; padding: 0; max-height: 260px; overflow-y: auto; }
.comment { padding: 7px 4px; border-bottom: 1px solid #3a3e46; }
.comment.highlight { background: color-mix(in srgb, var(--accent) 12%, transparent); }
.comment.empty { border: 0; text-align: center; font-size: 11px; }
.comment-meta { display: flex; align-items: center; gap: 6px; font-size: 11px; }
.comment-meta .muted { font-size: 10px; }
.comment-time { padding: 0 4px; border: 1px solid var(--line); border-radius: 2px; background: #1b1d21; color: var(--accent); font-size: 10px; cursor: pointer; }
.comment-resolve { margin-left: auto; width: 22px; height: 20px; padding: 0; border: 1px solid var(--line); border-radius: 3px; background: transparent; color: var(--text-dim); cursor: pointer; }
.comment-resolve:hover { background: #2f4a3a; color: #bff0cf; }
.comment-text { margin: 4px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 12px; }
.comment-compose { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.comment-compose .btn { align-self: flex-end; }
.comment-input { width: 100%; resize: vertical; padding: 6px 8px; border: 1px solid var(--line); border-radius: 3px; background: #18191c; color: var(--text); font: inherit; }

/* Tuner. */
.popover.tuner { width: 330px; }
.tuner-display { text-align: center; padding: 4px 0 8px; }
.tuner-main { display: inline-flex; align-items: flex-start; gap: 2px; }
.tuner-note { font: 700 52px/1 ui-sans-serif, system-ui, sans-serif; color: var(--text); }
.tuner-octave { margin-top: 6px; font: 600 16px var(--mono); color: var(--text-dim); }
.tuner-cents { font: 600 14px var(--mono); color: var(--text-dim); min-height: 18px; }
.tuner-freq { font-size: 10px; color: var(--text-dim); min-height: 14px; }
.popover.tuner.in-tune .tuner-note, .popover.tuner.in-tune .tuner-cents { color: #63e07f; }
.tuner-scale { position: relative; height: 34px; margin: 4px 6px 10px; border-radius: 4px; background: linear-gradient(to right, #3b2020, #2b2e34 40%, #24402c 47%, #24402c 53%, #2b2e34 60%, #3b2020); border: 1px solid #000; }
.tuner-tick { position: absolute; bottom: 2px; transform: translateX(-50%); font: 9px var(--mono); color: var(--text-dim); }
.tuner-tick::before { content: ""; position: absolute; left: 50%; bottom: 14px; width: 1px; height: 8px; background: #6b7078; }
.tuner-tick.zero::before { height: 16px; background: #63e07f; }
.tuner-needle { position: absolute; top: -3px; bottom: -3px; left: 50%; width: 3px; margin-left: -1.5px; border-radius: 2px; background: #f4f4f4; box-shadow: 0 0 8px #fff8; transition: left .08s linear; }
.popover.tuner.in-tune .tuner-needle { background: #63e07f; box-shadow: 0 0 10px #63e07f; }
.tuner-strings { display: flex; justify-content: center; gap: 5px; margin-bottom: 8px; flex-wrap: wrap; }
.tuner-string { min-width: 38px; height: 28px; border: 1px solid var(--line); border-radius: 14px; background: #1b1d21; color: var(--text); font: 600 12px var(--mono); cursor: pointer; }
.tuner-string.near { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 22%, #1b1d21); }
.tuner-options { display: flex; flex-wrap: wrap; gap: 4px 14px; }
.tuner-options .prop > span:first-child { min-width: 0; }
.tuner-a4 { width: 56px !important; }
.tuner-hint { margin: 6px 0 0; font-size: 10px; }
.popover.latency-panel { width: 340px; }
.latency-panel p { margin: 0 0 6px; font-size: 12px; line-height: 1.4; }
.latency-panel p.muted { font-size: 11px; }
.latency-actions { display: flex; align-items: center; gap: 10px; margin: 10px 0 4px; }
.latency-actions .latency-status { margin: 0; font-size: 11px; color: var(--text-dim); }
.latency-ms { width: 64px; }
.latency-panel .latency-details { margin: 6px 0 0; font-size: 10px; }

/* Narrow screens. */
@media (max-width: 760px) {
  .side-panel { position: fixed; top: 50px; right: 0; bottom: 0; z-index: 45; width: min(320px, 88vw); box-shadow: -10px 0 30px #0008; }
  .mixer-rack { width: 220px; }
  .drum-body { grid-template-columns: 1fr; }
  .presence .avatar:nth-child(n + 4) { display: none; }
}

/* Phones turned sideways: every row of pixels counts. */
@media (orientation: landscape) and (max-height: 520px) {
  .daw .topbar { height: 40px; gap: 6px; }
  .daw .topbar .brand-wordmark, .daw .drop-name, .daw .author-input, .daw .zoom, .daw .lcd-sub, .daw .field-static { display: none; }
  .daw .lcd { min-width: 70px; }
  .daw .tbtn { min-width: 34px; height: 30px; }
  :root { --track-h: 56px; --ruler-h: 30px; --header-w: 190px; }
  .daw-footer { display: none; }
  .dock { height: calc(100vh - 40px) !important; height: calc(100dvh - 40px) !important; }
  .dock-head { height: 32px; }
  .pr-body { grid-template-rows: 22px minmax(0, 1fr) 56px; }
  .side-panel { position: fixed; top: 40px; right: 0; bottom: 0; z-index: 45; width: min(320px, 60vw); box-shadow: -10px 0 30px #0008; }
  .popover, .plugin-window { max-height: calc(100vh - 16px); overflow-y: auto; }
}
@media (pointer: coarse) {
  .flag { min-width: 26px; height: 22px; }
  .knob.xs { width: 24px; }
  .knob.xs .knob-dial { width: 23px; height: 23px; }
  .slot { height: 34px; }
  .clip-edge { width: 12px; }
}
@supports (padding: env(safe-area-inset-left)) {
  body.daw-page { padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right); }
}

/* ── Share dialog, listen-only links, copies, dragging tracks ─────────────── */

.share-pop { position: fixed; z-index: 60; width: min(400px, calc(100vw - 16px)); max-height: calc(100vh - 16px); overflow: auto; padding: 12px 14px; background: #2b2e34; border: 1px solid #0b0c0e; border-radius: 6px; box-shadow: 0 14px 40px rgba(0, 0, 0, 0.55); }
.share-title { font-weight: 700; font-size: 13px; margin-bottom: 6px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.share-section { padding: 8px 0; border-top: 1px solid var(--line-soft); }
.share-section:first-of-type { border-top: 0; }
.share-section h3 { margin: 0 0 3px; font-size: 12px; }
.share-section p { margin: 0 0 8px; font-size: 11px; }
.share-link { display: flex; gap: 6px; align-items: center; margin-top: 6px; }
.share-url { flex: 1; min-width: 0; height: 26px; padding: 0 6px; border: 1px solid var(--line); border-radius: 3px; background: #0e0f11; color: var(--text); font-family: var(--mono); font-size: 11px; }
.share-link .text-btn { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; text-decoration: none; color: var(--text); }
.share-link .text-btn .icon { width: 12px; height: 12px; fill: currentColor; }
.socials { display: flex; flex-wrap: wrap; gap: 6px; }
.social { height: 26px; padding: 0 10px; border: 1px solid var(--line); border-radius: 13px; background: var(--panel-3); color: var(--text); font-size: 11px; font-weight: 600; cursor: pointer; }
.social:hover { background: #3a3d45; border-color: var(--accent); }
.social.more { background: none; color: var(--text-dim); }

.listen-bar, .copy-bar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; background: #1d2a3a; color: #bcd6f5; }
.listen-bar .text-btn { display: inline-flex; align-items: center; gap: 4px; color: #fff; text-decoration: none; font-weight: 600; }
.listen-bar .icon { width: 12px; height: 12px; fill: currentColor; }
/* A listen-only link plays and copies; nothing that would change the Drop shows. */
.listen-only .transport .rec, .listen-only .edit-tools, .listen-only .author-input, .listen-only .notepad-btn,
.listen-only .add-row, .listen-only .flag.arm, .listen-only .clip-edge, .listen-only .comment-badge, .listen-only .comment-marker,
.listen-only .track-header .more, .listen-only .flag.fx, .listen-only .flag.inst, .listen-only .mixer-btn { display: none !important; }
.listen-only .track-header .knob, .listen-only .field-btn { pointer-events: none; opacity: 0.6; }

.track-kind[draggable="true"] { cursor: grab; }
.add-row.drop-target .add-cell { outline: 2px dashed var(--accent); outline-offset: -3px; }

/* ── Export ─────────────────────────────────────────────────────────────── */

.export-panel { left: 50%; top: 64px; transform: translateX(-50%); width: min(460px, calc(100vw - 16px)); max-width: none; max-height: calc(100vh - 80px); overflow: auto; }
.export-row { display: flex; align-items: center; gap: 10px; margin: 7px 0; }
.export-label { width: 84px; flex: none; font-size: 11px; color: var(--text-dim); }
.export-about { margin: 2px 0 6px 94px; font-size: 11px; }
.export-credit { margin: 6px 0 0; font-size: 10px; }
.segmented { display: inline-flex; flex-wrap: wrap; border: 1px solid var(--line); border-radius: 4px; overflow: hidden; }
.segmented button { height: 24px; padding: 0 9px; border: 0; border-right: 1px solid var(--line); background: var(--panel-3); color: var(--text-dim); font-size: 11px; cursor: pointer; }
.segmented button:last-child { border-right: 0; }
.segmented button.on { background: #3d79c9; color: #fff; }
.export-progress { margin-top: 10px; }
.export-bar { height: 6px; border-radius: 3px; background: #0e0f11; overflow: hidden; margin-bottom: 4px; }
.export-bar > div { height: 100%; width: 0; background: var(--play); transition: width 0.2s; }
.export-go .icon { width: 12px; height: 12px; fill: currentColor; margin-right: 4px; vertical-align: -1px; }
@media (max-width: 520px) { .export-about { margin-left: 0; } .export-label { width: 70px; } }

/* ── Audio quantize (editor dock) ────────────────────────────────────────── */

.audio-editor { display: flex; flex-direction: column; height: 100%; min-height: 0; }
.aq-toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 6px 10px; border-bottom: 1px solid var(--line); background: var(--panel-2); }
.aq-slider { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; color: var(--text-dim); }
.aq-slider input { width: 110px; }
.aq-slider .mono { width: 34px; color: var(--text); font-family: var(--mono); }
.aq-toolbar .btn.ab.on { border-color: var(--accent); color: var(--accent); }
.aq-status { font-size: 11px; }
.aq-shift-amount { width: 68px; }
.aq-shift-label, .aq-selection { font-size: 11px; color: var(--text-dim); }
.aq-marker-toolbar { gap: 8px; }
.aq-scroll { position: relative; flex: 1; min-height: 0; overflow-x: auto; overflow-y: hidden; background: var(--lane); }
.aq-sizer { height: 1px; }
.aq-canvas { position: absolute; top: 0; cursor: crosshair; touch-action: none; }
.aq-hint { padding: 3px 10px; font-size: 10px; border-top: 1px solid var(--line); }
.clip-badge { position: absolute; top: 2px; right: 4px; padding: 0 4px; border-radius: 3px; background: rgba(255, 200, 120, 0.85); color: #1a1205; font-size: 9px; font-weight: 700; pointer-events: none; }

/* Laptop widths: the Drop's top bar keeps every control, dropping the wordmark (the logo stays) and then fixed labels. */
@media (max-width: 1500px) and (min-width: 761px) {
  .daw .topbar { gap: 8px; }
  .daw .topbar .brand-wordmark { display: none; }
}
@media (max-width: 1400px) and (min-width: 761px) {
  .daw .topbar { gap: 6px; }
}
@media (max-width: 1300px) and (min-width: 761px) {
  .daw .topbar { gap: 6px; overflow-x: auto; }
  .daw .field-static, .daw .zoom { display: none; } /* ⌘/Ctrl + scroll still zooms */
}

/* ── Inside an app's built-in browser (Instagram, Facebook, TikTok…) ───────── */

.inapp-banner { position: relative; z-index: 70; flex: none; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; padding: 10px 44px 10px 14px; background: #2a1f3d; color: #f0e8ff; border-bottom: 1px solid #000; font-size: 13px; line-height: 1.4; }
.inapp-banner strong { display: block; color: #fff; }
.inapp-text { flex: 1 1 260px; }
.inapp-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; }
.inapp-actions .btn { white-space: nowrap; }
.inapp-dismiss { position: absolute; top: 4px; right: 4px; width: 36px; height: 36px; border: 0; border-radius: 50%; background: transparent; color: #f0e8ff; font-size: 22px; line-height: 1; cursor: pointer; }
.inapp-dismiss:hover, .inapp-dismiss:focus-visible { background: rgba(255, 255, 255, 0.12); }
.inapp-card .inapp-note { color: var(--text); }
.inapp-how { flex-basis: 100%; font-size: 12px; color: #d7c9f2; }
.inapp-sheet { position: fixed; inset: 0; z-index: 200; display: flex; align-items: flex-end; justify-content: center; padding: 16px; background: rgba(0, 0, 0, 0.6); }
.inapp-card { width: min(440px, 100%); padding: 18px 18px 14px; border-radius: 12px; background: #2b2e34; border: 1px solid #0b0c0e; color: var(--text); box-shadow: 0 18px 50px rgba(0, 0, 0, 0.6); }
.inapp-card h2 { margin: 0 0 8px; font-size: 17px; }
.inapp-card p { margin: 0 0 12px; font-size: 14px; line-height: 1.45; color: var(--text-dim); }
.inapp-card .inapp-how { color: var(--text-dim); }
.inapp-close { margin-top: 12px; width: 100%; }

/* ── A Drop on this device (the landing page) ────────────────────────────── */

.local-bar { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 14px; background: #1f2b22; color: #cfe8d3; }
.local-bar strong { color: #fff; }
.local-actions { display: inline-flex; flex-wrap: wrap; gap: 4px 12px; }
.local-actions .text-btn { color: #fff; font-weight: 600; text-decoration: none; }
.local-actions .text-btn:hover { text-decoration: underline; }
.local-drop .copy-btn, .local-drop .presence { display: none; }
/* Phones and tablets: no keyboard to press; a phone also keeps it to one short line. */
@media (pointer: coarse) { .local-bar .local-keys { display: none; } }
@media (max-height: 500px), (max-width: 600px) {
  .local-bar { padding-top: 6px; padding-bottom: 6px; }
  .local-bar .local-keys, .local-bar .local-more { display: none; }
}
.device-drop { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin: 0 0 16px; border-radius: 8px; }
.device-drop[hidden] { display: none; }
.device-drop-actions { display: inline-flex; align-items: center; gap: 12px; }
.daw-footer .daw-about { color: var(--text-dim); text-decoration: none; font-size: 11px; }
.daw-footer .daw-about:hover { color: var(--text); }
