/* ---------- DAW (tela à esquerda do pedal) ---------- */
#dawRoot { max-width: 1180px; margin: 22px auto 30px; }
.dawload { padding: 60px 20px; text-align: center; color: var(--dim); }
.daw { border-radius: 16px; overflow: hidden; background: linear-gradient(#26282e, #1a1c21); border: 1px solid #33363e; box-shadow: 0 18px 40px #0009, inset 0 1px 0 #3c3f48; color: #e8e9ec; }
.daw button { font: inherit; color: inherit; cursor: pointer; }
/* transporte */
.daw .tp { display: flex; align-items: center; gap: 8px; padding: 12px 14px; background: #121317; border-bottom: 1px solid #2c2f37; flex-wrap: wrap; }
.daw .song { display: flex; flex-direction: column; min-width: 150px; max-width: 220px; }
.daw .song small { color: var(--dim); font-size: 10px; letter-spacing: 1px; text-transform: uppercase; }
.daw .song b { font-size: 15px; cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.daw .tbtn { width: 42px; height: 38px; border-radius: 9px; border: 1px solid #3a3e48; background: linear-gradient(#30333b, #24262c); box-shadow: 0 2px 0 #000; display: grid; place-items: center; font-size: 15px; padding: 0; }
.daw .tbtn.on { color: #2ee66b; }
.daw .tbtn.rec { color: #ff3b30; }
.daw .tbtn.rec.on { background: linear-gradient(#e83a2e, #b51d14); color: #fff; border-color: #ff6a5a; box-shadow: 0 2px 0 #6a0d07, 0 0 16px #e83a2e66; }
.daw .dlcd { font-family: ui-monospace, Menlo, monospace; background: #1530b8; color: #fff; border-radius: 8px; padding: 6px 14px; box-shadow: inset 0 2px 8px #0008; display: flex; gap: 14px; align-items: baseline; border: 2px solid #0a0a0a; white-space: nowrap; }
.daw .dlcd .t { font-size: 22px; font-weight: 800; letter-spacing: 1px; }
.daw .dlcd span { font-size: 11px; opacity: .85; }
.daw .recnote { font-size: 11px; color: #ff8a80; display: flex; align-items: center; gap: 6px; font-weight: 700; }
.daw .recnote[hidden] { display: none; }
.daw .recnote i { width: 8px; height: 8px; border-radius: 50%; background: #ff3b30; box-shadow: 0 0 8px #ff3b30; }
.daw .sp { flex: 1; }
.daw .btn { border-radius: 8px; padding: 9px 12px; font-weight: 700; background: linear-gradient(#30333b, #24262c); border: 1px solid #3a3e48; box-shadow: 0 2px 0 #000; font-size: 12px; white-space: nowrap; }
.daw .btn.accent { background: linear-gradient(#e83a2e, #b51d14); border-color: #ff6a5a; color: #fff; }
.daw .zoom { display: flex; align-items: center; gap: 4px; font-size: 10px; font-weight: 800; color: var(--dim); letter-spacing: 1px; }
.daw .zoom .btn { padding: 7px 11px; font-size: 14px; }
/* faixas */
.daw .arr { display: grid; grid-template-columns: 200px 1fr; }
.daw .heads { border-right: 1px solid #2c2f37; }
.daw .ruler-h { background: #121317; border-bottom: 1px solid #2c2f37; height: 28px; font-size: 10px; color: var(--dim); display: flex; align-items: center; padding-left: 12px; letter-spacing: 1px; }
.daw .th { height: 74px; border-bottom: 1px solid #24262c; border-left: 4px solid var(--c); padding: 9px 10px; display: flex; flex-direction: column; justify-content: space-between; background: #1d1f24; cursor: pointer; }
.daw .th.cur { background: #23262c; }
.daw .th.armed { background: linear-gradient(90deg, #3a1714, #1d1f24 70%); }
.daw .th b { font-size: 13px; } .daw .th small { color: var(--dim); font-size: 10px; }
.daw .th .row { display: flex; gap: 5px; align-items: center; }
.daw .ms { width: 26px; height: 22px; border-radius: 4px; border: 1px solid #3a3e48; background: #24262c; font-size: 10px; font-weight: 800; display: grid; place-items: center; color: #aeb3bf; padding: 0; }
.daw .ms.r { color: #ff6a5a; font-size: 12px; }
.daw .ms.r.on { background: #e83a2e; color: #fff; border-color: #ff6a5a; box-shadow: 0 0 10px #e83a2e99; }
.daw .ms.s.on { background: #ffd21a; color: #000; } .daw .ms.m.on { background: #4aa3ff; color: #000; }
.daw .th .vol { flex: 1; min-width: 0; accent-color: var(--c); height: 18px; margin: 0 0 0 4px; }
.daw .tl { position: relative; overflow-x: auto; overflow-y: hidden; overscroll-behavior-x: contain; touch-action: pan-x pan-y; scrollbar-width: thin; scrollbar-color: #3a3e48 transparent; }
.daw .tlin { position: relative; min-width: 100%; }
.daw .ruler { position: relative; height: 28px; background: #121317; border-bottom: 1px solid #2c2f37; cursor: pointer;
  background-image: repeating-linear-gradient(90deg, #3a3e48 0 1px, transparent 1px var(--beat)); background-size: 100% 6px; background-repeat: repeat-x; background-position: 0 100%; }
.daw .ruler span { position: absolute; top: 7px; font-size: 10px; color: #8b909c; transform: translateX(3px); pointer-events: none; }
.daw .ruler span::before { content: ''; position: absolute; left: -3px; top: -7px; width: 1px; height: 28px; background: #3a3e48; }
.daw .mk { position: absolute; top: 0; height: 28px; padding: 0 8px; display: flex; align-items: center; font-size: 10px; font-weight: 800; color: #000; background: #ff8a3d; border-radius: 0 0 6px 6px; z-index: 3; cursor: pointer; white-space: nowrap; }
.daw .lane { height: 74px; border-bottom: 1px solid #24262c; position: relative;
  background: repeating-linear-gradient(90deg, #ffffff10 0 1px, transparent 1px var(--bar)); }
.daw .lane:nth-of-type(even) { background-color: #ffffff04; }
.daw .clip { position: absolute; top: 6px; bottom: 6px; border-radius: 6px; overflow: hidden; background: color-mix(in srgb, var(--c) 22%, #15171b); border: 1px solid color-mix(in srgb, var(--c) 70%, #000); touch-action: none; cursor: grab; }
.daw .clip.sel { outline: 2px solid #fff; outline-offset: 1px; z-index: 2; overflow: visible; }
.daw .clip.muted { opacity: .45; }
.daw .clip .nm { position: absolute; left: 6px; top: 3px; right: 6px; font-size: 10px; font-weight: 800; color: #fff; text-shadow: 0 1px 2px #000; z-index: 2; letter-spacing: .3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none; }
.daw .clip .nm i { font-style: normal; color: #ffd9a8; }
.daw .clip canvas { position: absolute; left: 0; top: 0; width: 100%; height: 100%; pointer-events: none; border-radius: 6px; }
.daw .clip .hd { position: absolute; top: 0; bottom: 0; width: 8px; background: #fff4; z-index: 3; cursor: ew-resize; } .daw .clip .hd.l { left: 0; border-radius: 6px 0 0 6px; } .daw .clip .hd.r { right: 0; border-radius: 0 6px 6px 0; }
.daw .clip .fh { position: absolute; top: -6px; width: 14px; height: 14px; border-radius: 50%; background: #fff; z-index: 4; box-shadow: 0 0 0 2px #000a; cursor: ns-resize; }
.daw .clip .fh.l { left: 10px; } .daw .clip .fh.r { right: 10px; }
.daw .clip.recing { background: #e83a2e33; border: 1px solid #ff3b30; cursor: default; }
.daw .clip.recing .nm { color: #ffb3ad; }
.daw .ph { position: absolute; top: 0; bottom: 0; left: 0; width: 2px; background: #fff; box-shadow: 0 0 8px #fff8; z-index: 5; pointer-events: none; }
.daw .ph::before { content: ''; position: absolute; top: -1px; left: -6px; border: 7px solid transparent; border-top: 9px solid #fff; }
.daw .autosvg { position: absolute; left: 0; top: 0; pointer-events: none; z-index: 4; overflow: visible; }
.daw .autosvg polyline { fill: none; stroke: #ffd21a; stroke-width: 2; opacity: .55; }
.daw .autosvg.edit { pointer-events: auto; cursor: crosshair; }
.daw .autosvg.edit polyline { opacity: 1; }
.daw .autosvg circle { fill: #ffd21a; stroke: #000; stroke-width: 2; cursor: grab; }
/* barra de ferramentas lateral */
.daw .tbar { border-top: 1px solid #2c2f37; background: #121317; position: relative; }
.daw .tsel { display: flex; align-items: center; gap: 10px; padding: 9px 14px 0; font-size: 11px; color: var(--dim); flex-wrap: wrap; min-height: 22px; }
.daw .tsel b { color: #fff; }
.daw .tsel .chip { padding: 2px 8px; border-radius: 999px; background: color-mix(in srgb, var(--c) 22%, transparent); color: color-mix(in srgb, var(--c) 60%, #fff); font-weight: 800; font-size: 10px; }
.daw .sub { margin: 8px 14px 0; padding: 10px 14px; border-radius: 10px; background: #1d1f24; border: 1px solid #33363e; display: flex; align-items: center; gap: 14px; font-size: 11px; font-weight: 800; letter-spacing: .5px; flex-wrap: wrap; }
.daw .sub[hidden] { display: none; }
.daw .sub .st { white-space: nowrap; }
.daw .sub .sc { flex: 1; min-width: 180px; display: flex; align-items: center; gap: 10px; }
.daw .sub .sc small { font-size: 9px; color: var(--dim); letter-spacing: 1px; white-space: nowrap; }
.daw .sub .sc input { flex: 1; accent-color: #ff8a3d; min-width: 80px; }
.daw .sub .sc b { font-family: ui-monospace, Menlo, monospace; color: #ff8a3d; min-width: 74px; text-align: right; font-size: 11px; }
.daw .sub .ok { padding: 6px 14px; border-radius: 7px; border: none; background: linear-gradient(#e83a2e, #b51d14); color: #fff; font-weight: 800; }
.daw .sub .btn2 { padding: 6px 12px; border-radius: 7px; border: 1px solid #3a3e48; background: #2a2d34; font-weight: 800; font-size: 11px; }
.daw .sub .btn2.go, .daw .sub .btn2.on { background: #ff8a3d; color: #000; border-color: #ff8a3d; }
.daw .sub .hint2 { color: #aeb3bf; font-weight: 600; letter-spacing: 0; flex: 1; }
.daw .sub .sw { display: flex; gap: 6px; flex-wrap: wrap; }
.daw .sub .sw button { width: 28px; height: 28px; border-radius: 50%; border: 2px solid #000; }
.daw .sub .sw button.auto { width: auto; border-radius: 7px; padding: 0 10px; background: #2a2d34; border-color: #3a3e48; font-size: 10px; font-weight: 800; }
.daw .scroller { display: flex; gap: 4px; overflow-x: auto; padding: 10px 14px 14px; scroll-snap-type: x proximity; scrollbar-width: none; cursor: grab; overscroll-behavior-x: contain;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 24px, #000 calc(100% - 60px), transparent); mask-image: linear-gradient(90deg, transparent 0, #000 24px, #000 calc(100% - 60px), transparent); }
.daw .scroller::-webkit-scrollbar { display: none; }
.daw .grp { display: flex; flex-direction: column; gap: 4px; scroll-snap-align: start; }
.daw .grp > small { font-size: 9px; letter-spacing: 1.5px; color: #6c717c; font-weight: 800; padding-left: 4px; white-space: nowrap; }
.daw .grp > div { display: flex; gap: 4px; }
.daw .grp + .grp { border-left: 1px solid #2c2f37; padding-left: 8px; margin-left: 4px; }
.daw .tool { width: 74px; flex: none; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 9px 2px 8px; border-radius: 10px; color: #cfd3da; font-size: 10.5px; font-weight: 700; text-align: center; line-height: 1.15; background: none; border: none; }
.daw .tool svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; }
.daw .tool:hover { background: #1f2127; color: #fff; }
.daw .tool.on { background: #2a1d14; color: #ff8a3d; box-shadow: inset 0 0 0 1px #ff8a3d66; }
.daw .tool.danger { color: #ff8a80; }
.daw .hintdrag { position: absolute; right: 14px; bottom: 3px; font-size: 9px; color: #6c717c; letter-spacing: 1px; pointer-events: none; }
/* músicas */
.daw .bot { border-top: 1px solid #2c2f37; }
.daw .songs { padding: 12px 14px; }
.daw .songs .lbl { font-size: 10px; color: var(--dim); letter-spacing: 1px; text-transform: uppercase; margin-bottom: 6px; display: flex; justify-content: space-between; align-items: center; }
.daw .linkbtn { background: none; border: none; color: #ff8a3d; font-weight: 800; font-size: 10px; letter-spacing: 1px; }
.daw .row3 { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 6px; }
.daw .it { display: flex; align-items: center; gap: 8px; padding: 7px 10px; border-radius: 7px; background: #16181c; border: 1px solid #2c2f37; font-size: 12px; cursor: pointer; }
.daw .it span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.daw .it.cur { border-color: #ff8a3d; } .daw .it small { color: var(--dim); white-space: nowrap; }
.daw .it .x { background: none; border: none; color: #6c717c; font-size: 16px; line-height: 1; padding: 0 2px; }
.daw .it .x:hover { color: #ff6a5a; }
/* gravando: aviso no topo, visível em todas as telas */
.recpill { background: #e83a2e !important; color: #fff !important; border-color: #ff6a5a !important; font-weight: 800; }
@media (max-width: 760px) {
  .daw .arr { grid-template-columns: 112px 1fr; }
  .daw .th { padding: 6px 6px; } .daw .th small { display: none; }
  .daw .th .vol { display: none; }
  .daw .dlcd .t { font-size: 18px; } .daw .dlcd span.dBpm { display: none; }
  .daw .song { min-width: 0; max-width: 140px; }
}
