Files

148 lines
7.4 KiB
CSS

:root {
--bg: #140d2b;
--bg2: #1f1147;
--card: #271a52;
--accent: #b794ff;
--accent2: #7c4dff;
--text: #ece8ff;
--muted: #a99fd0;
--ok: #4ade80;
--line: #3a2a6b;
}
* { box-sizing: border-box; }
body {
margin: 0;
font-family: system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
background: linear-gradient(160deg, var(--bg), var(--bg2));
color: var(--text);
min-height: 100vh;
overflow-x: hidden;
-webkit-tap-highlight-color: transparent;
}
header {
display: flex; align-items: center; justify-content: space-between;
gap: 12px; padding: 14px 16px calc(14px + env(safe-area-inset-top));
position: sticky; top: 0; background: rgba(20,13,43,.85);
backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); z-index: 5;
}
.brand { display: flex; align-items: center; gap: 10px; }
h1 { font-size: 1.1rem; margin: 0; letter-spacing: .5px; }
h2 { font-size: .8rem; text-transform: uppercase; letter-spacing: 1px; color: var(--accent); margin: 0 0 12px; }
.card-head { display: flex; align-items: center; justify-content: space-between; }
.card-head h2 { margin-bottom: 0; }
.conn { display: flex; align-items: center; gap: 8px; font-size: .85rem; }
.dot { width: 10px; height: 10px; border-radius: 50%; background: #6b6b6b; box-shadow: 0 0 0 0 rgba(74,222,128,.6); }
.dot.on { background: var(--ok); animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(74,222,128,.5); } 70% { box-shadow: 0 0 0 8px rgba(74,222,128,0); } }
main { max-width: 640px; margin: 0 auto; padding: 16px; display: grid; gap: 16px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 18px; }
button {
font: inherit; cursor: pointer; border: 1px solid var(--line);
background: #34246b; color: var(--text); padding: 10px 16px; border-radius: 10px;
transition: filter .15s, transform .05s;
}
button:hover:not(:disabled) { filter: brightness(1.15); }
button:active:not(:disabled) { transform: translateY(1px); }
button:disabled { opacity: .4; cursor: not-allowed; }
button.primary { background: linear-gradient(135deg, var(--accent2), var(--accent)); border: none; color: #1a0f3a; font-weight: 600; }
button.mini { padding: 6px 10px; border-radius: 8px; }
select, input[type=number] {
font: inherit; background: #1c123e; color: var(--text);
border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px;
}
input[type=number] { width: 4.5rem; }
label { display: inline-flex; align-items: center; gap: 8px; font-size: .9rem; color: var(--muted); }
/* ---- graphical trim: waveform + dual-range slider ---- */
.trim { margin: 14px 0 4px; }
.wave-wrap { position: relative; height: 72px; margin-bottom: 8px; touch-action: none; }
.wave {
width: 100%; height: 100%; display: block;
background: #150d33; border: 1px solid var(--line); border-radius: 10px;
}
.trim-region {
position: absolute; top: 0; bottom: 0;
background: rgba(124, 77, 255, .20);
border-left: 2px solid var(--accent); border-right: 2px solid var(--accent);
pointer-events: none; border-radius: 4px;
}
/* Custom precision handles: a translucent 1px line with a chevron cap at top and
bottom. A wide transparent hit area keeps them easy to grab on touch. */
.handle {
position: absolute; top: 0; bottom: 0; width: 22px;
transform: translateX(-50%); cursor: ew-resize; touch-action: none; z-index: 3;
}
.handle .line {
position: absolute; left: 50%; top: 0; bottom: 0; width: 1px;
transform: translateX(-50%); background: rgba(183, 148, 255, .7);
}
.handle .chev {
position: absolute; left: 50%; transform: translateX(-50%);
width: 0; height: 0; border-left: 6px solid transparent; border-right: 6px solid transparent;
}
.handle .chev.top { top: -1px; border-top: 9px solid var(--accent); } /* points down */
.handle .chev.bot { bottom: -1px; border-bottom: 9px solid var(--accent); } /* points up */
.handle:focus { outline: none; }
.handle:focus .line, .handle.dragging .line { background: var(--accent); box-shadow: 0 0 6px var(--accent); }
.handle:focus .chev, .handle.dragging .chev { filter: drop-shadow(0 0 4px var(--accent)); }
.trim-readout { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 12px; font-size: .85rem; color: var(--muted); }
.time-fields { display: inline-flex; align-items: center; gap: 6px; flex-shrink: 0; }
.time-fields .dash { color: var(--muted); }
.time-in {
width: 3.8rem; min-width: 0; padding: 5px 7px; font-size: .85rem;
background: #1c123e; color: var(--text); border: 1px solid var(--line); border-radius: 7px;
}
.trim-readout .clip { margin-left: auto; color: var(--accent); font-weight: 600; }
.trim-readout button { flex-shrink: 0; }
.level { display: flex; align-items: center; gap: 10px; width: 100%; margin-top: 12px; font-size: .85rem; color: var(--muted); }
.level input[type=range] { flex: 1; min-width: 0; }
.level .unit { min-width: 3.2rem; text-align: right; color: var(--accent); font-weight: 600; }
input[type=range] { accent-color: var(--accent2); }
.vol-slider { width: 100%; }
.muted-val { color: var(--accent); font-weight: 600; font-size: .95rem; }
.drop {
border: 2px dashed var(--line); border-radius: 14px; padding: 26px 16px;
text-align: center; cursor: pointer; transition: border-color .15s, background .15s;
}
.drop:hover, .drop.hover { border-color: var(--accent); background: rgba(124,77,255,.08); }
.drop p { margin: 0 0 4px; font-weight: 600; }
.drop small { color: var(--muted); }
.opts { display: flex; gap: 16px; margin: 14px 0; flex-wrap: wrap; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 12px; }
.info { font-size: .9rem; color: var(--muted); min-height: 1.2em; margin: 12px 0 0; }
.hint { font-size: .8rem; color: var(--muted); margin: -6px 0 12px; }
.progress { height: 8px; background: #1c123e; border-radius: 6px; margin-top: 14px; overflow: hidden; }
.progress.active .bar { transition: width .2s; }
.bar { height: 100%; width: 0; background: linear-gradient(90deg, var(--accent2), var(--accent)); }
.slots { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.slots li { display: flex; align-items: center; justify-content: space-between; gap: 10px;
background: #1c123e; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.slots li.empty { color: var(--muted); justify-content: center; font-size: .9rem; }
.slot-meta { display: flex; align-items: center; gap: 12px; min-width: 0; }
.slot-num { background: var(--accent2); color: #1a0f3a; font-weight: 700; border-radius: 8px;
width: 30px; height: 30px; display: grid; place-items: center; flex: none; }
.slot-meta b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 46vw; }
.slot-meta small { color: var(--muted); }
.slot-actions { display: flex; gap: 6px; flex: none; }
.banner { background: #5a2a2a; color: #ffd9d9; padding: 10px 16px; text-align: center; font-size: .9rem; }
.log { background: #0d0822; border: 1px solid var(--line); border-radius: 10px; padding: 12px;
font-size: .78rem; color: var(--muted); max-height: 200px; overflow: auto; white-space: pre-wrap; margin: 0; }
footer { text-align: center; color: var(--muted); font-size: .78rem; padding: 8px 16px calc(24px + env(safe-area-inset-bottom)); }
footer a { color: var(--accent); }
@media (max-width: 480px) {
header { padding: 12px 12px calc(12px + env(safe-area-inset-top)); }
.conn { gap: 6px; font-size: .8rem; }
main { padding: 12px; gap: 12px; }
.card { padding: 14px; border-radius: 14px; }
.opts { gap: 12px; }
.slot-meta b { max-width: 42vw; }
}