.quality-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  padding: 9px 10px;
  border-radius: 10px;
  background: #f1f8f5;
  color: #17795d;
  font-size: 9px;
}

.quality-line span {
  color: #5e6b67;
  text-align: right;
}

.previs-panel { margin-top: 18px; max-width: none; }
.previs-output { margin-top: 16px; }
.previs-summary { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-bottom: 12px; }
.previs-summary > div { display: flex; flex-direction: column; padding: 13px; border-radius: 13px; background: #f7f8fc; }
.previs-summary span { color: #7b8496; font-size: 10px; margin-top: 4px; }
.missing-box { padding: 14px 16px; border: 1px solid #ffd7c9; border-radius: 14px; background: #fff7f3; color: #8a3f28; font-size: 11px; }
.missing-box ul { margin: 7px 0 0; padding-left: 18px; }
.previs-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 13px; }
.previs-card { overflow: hidden; border: 1px solid #e3e6ef; border-radius: 17px; background: #fff; }
.previs-card img { display: block; width: 100%; aspect-ratio: 16/9; object-fit: cover; background: #eef1f7; }
.previs-card > div { padding: 13px; }
.previs-card span { color: #5b5cf0; font-size: 9px; font-weight: 800; text-transform: uppercase; }
.previs-card h4 { margin: 5px 0; }
.previs-card p { color: #697286; font-size: 10px; line-height: 1.5; }
.previs-card details { margin-top: 9px; padding-top: 8px; border-top: 1px solid #eceef3; }
.previs-card summary { cursor: pointer; color: #4d5668; font-size: 10px; font-weight: 800; }
.previs-card small { color: #a34e43; line-height: 1.45; }

.assistant-workspace { display: grid; grid-template-columns: 1.25fr .75fr; gap: 18px; }
.assistant-messages { min-height: 520px; max-height: 70vh; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; }
.assistant-form { max-width: none; }
.assistant-bubble { max-width: 84%; padding: 14px 16px; border-radius: 17px; line-height: 1.6; white-space: pre-wrap; }
.assistant-bubble.ai { align-self: flex-start; background: #f1f0ff; color: #343251; }
.assistant-bubble.user { align-self: flex-end; background: #171c29; color: white; }

@media (max-width: 900px) {
  .previs-grid, .previs-summary, .assistant-workspace { grid-template-columns: 1fr; }
}


    .studio-grid{display:grid;grid-template-columns:minmax(260px,360px) minmax(0,1fr);gap:24px;align-items:start}
    .studio-stack{display:grid;gap:18px;min-width:0}.studio-panel{padding:24px;min-width:0;max-width:100%;overflow-wrap:anywhere}.studio-panel h3{margin:0 0 16px}
    .studio-panel label,.studio-panel input,.studio-panel select,.studio-panel textarea{min-width:0;max-width:100%}.studio-panel input:not([type=checkbox]),.studio-panel select,.studio-panel textarea{width:100%}
    .studio-job span,.studio-job b{min-width:0;white-space:normal}.studio-job{width:100%}
    .studio-panel label{display:grid;gap:6px;margin:14px 0}.studio-panel input[type=checkbox]{width:auto}
    .studio-panel .inline-check{display:flex;align-items:center;gap:10px}.studio-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:16px}
    .studio-agents{display:flex;flex-wrap:wrap;gap:8px;margin-bottom:22px}.studio-agent{padding:8px 12px;border-radius:20px;background:#f0f1f5;font-size:12px}
    .studio-agent.ready{background:#dcf5e9;color:#155b3d}.studio-source{width:100%;max-height:420px;border-radius:14px;background:#111}
    .studio-decision{padding:16px;border:1px solid #e3e5ed;border-radius:12px;margin-top:12px;background:white}
    .studio-decision p{margin:8px 0;line-height:1.5}.studio-decision .removed{color:#944439}.studio-decision .kept{color:#216744}
    .studio-log{font-size:13px;line-height:1.7;max-height:210px;overflow:auto;white-space:pre-wrap}
    .studio-muted{font-size:13px;color:#697386;line-height:1.55}.studio-error{background:#fff0eb;color:#873b28;padding:14px;border-radius:10px;white-space:pre-wrap}
    .studio-jobs{display:grid;gap:8px}.studio-job{display:flex;justify-content:space-between;text-align:left;gap:12px;padding:12px;border:1px solid #e3e5ed;border-radius:10px;background:white;cursor:pointer}
    .studio-transcript{max-height:260px;overflow:auto;line-height:1.8}.studio-word{border:0;background:transparent;padding:2px;cursor:pointer;color:inherit}
    .studio-word:hover{background:#e7e4ff}.studio-profile{white-space:pre-wrap;font-size:13px;line-height:1.6}
    .studio-word-edits{display:grid;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:8px;max-height:320px;overflow:auto}.studio-word-edits label{margin:0;font-size:11px}.studio-word-edits .uncertain{color:#944439}
    @media(max-width:1000px){.studio-grid{grid-template-columns:1fr}}
  
.prod-tabs{display:flex;gap:8px;flex-wrap:wrap;margin:24px 0}.prod-pane{display:none}.prod-pane.active{display:block}.prod-row{display:flex;gap:12px;flex-wrap:wrap}.prod-row>label{flex:1;min-width:100px}.prod-note{font-size:13px;color:#697386;line-height:1.6}.prod-result img{max-width:100%;border-radius:12px}.prod-result video{width:100%;max-height:430px;background:#111;border-radius:14px}.prod-beat{border:1px solid #e3e5ed;border-radius:12px;padding:16px;margin-top:12px}.prod-result a{overflow-wrap:anywhere}.prod-option-preview{width:100%;max-height:200px;object-fit:contain}.prod-badge{font-size:12px;color:#626c81}