* { box-sizing: border-box; }
body { margin: 0; font-family: system-ui, -apple-system, Segoe UI, Roboto, 'Helvetica Neue', Arial, 'Noto Sans', 'Apple Color Emoji','Segoe UI Emoji', 'Segoe UI Symbol'; color: #eaeef2; background: #0b1220; }
header { padding: 16px 20px; background: #0f172a; border-bottom: 1px solid #1f2937; }
h1 { margin: 0; font-size: 20px; }
p { margin: 6px 0 0; color: #9ca3af; }
main { display: grid; grid-template-columns: 1.2fr 1fr; gap: 16px; padding: 16px; }
section.left, section.right { background: #0f172a; border: 1px solid #1f2937; border-radius: 16px; padding: 12px; }
.video-wrap { position: relative; width: 100%; aspect-ratio: 4/3; background: #111827; border-radius: 12px; overflow: hidden; }
video, canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.controls { margin-top: 12px; display: grid; gap: 8px; }
.controls .row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.controls label { width: 120px; color: #94a3b8; }
.controls button { background: #1e293b; border: 1px solid #334155; color: #e2e8f0; padding: 8px 10px; border-radius: 10px; cursor: pointer; }
.controls button:hover { background: #243447; }
.controls input { background: #0b1220; color: #e5e7eb; border: 1px solid #334155; padding: 8px; border-radius: 10px; }
.output { border: 1px dashed #334155; border-radius: 12px; padding: 10px; }
#predLabel { font-size: 48px; line-height: 1.1; margin-top: 6px; }
.probs { display: grid; gap: 4px; margin-top: 8px; max-height: 220px; overflow: auto; }
.prob-row { display: grid; grid-template-columns: 84px 1fr 58px; gap: 6px; align-items: center; }
.prob-bar { height: 10px; background: #1f2937; border-radius: 6px; overflow: hidden; }
.prob-bar > i { display: block; height: 100%; background: #22d3ee; }
.translator { margin-top: 12px; border: 1px dashed #334155; border-radius: 12px; padding: 10px; }
.translator .row { display: flex; gap: 8px; align-items: center; margin-top: 8px; flex-wrap: wrap; }
.translator button { background: #1e293b; border: 1px solid #334155; color: #e2e8f0; padding: 8px 10px; border-radius: 10px; cursor: pointer; }
.translator button.active { outline: 2px solid #22d3ee; }
#transcript { width: 100%; min-height: 140px; background: #0b1220; color: #e5e7eb; border: 1px solid #334155; padding: 8px; border-radius: 10px; }
footer { text-align: center; color: #6b7280; padding: 8px 0 16px; }
@media (max-width: 980px) { main { grid-template-columns: 1fr; } }
