:root{font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif;color:#17202a;background:#f5f7fb;font-synthesis:none;text-rendering:optimizeLegibility}*{box-sizing:border-box}body{margin:0}button,input,select{font:inherit}.app{min-height:100vh}.topbar{display:flex;align-items:center;justify-content:space-between;padding:24px 28px 16px;background:#fff;border-bottom:1px solid #d9e0ea}.topbar h1,.page h2,.detail h2,.panel h2,.suggestions h2{margin:0;letter-spacing:0}.topbar h1{font-size:24px}.topbar p,.detailHeader p,.sectionHeader p{margin:6px 0 0;color:#627086}.iconButton,.approve,.secondaryButton{display:inline-flex;align-items:center;justify-content:center;height:36px;border:1px solid #cbd6e3;background:#fff;color:#17202a;cursor:pointer}.iconButton{width:36px;border-radius:6px}.secondaryButton{gap:7px;width:auto;padding:0 12px;border-radius:6px;font-weight:700;white-space:nowrap}.secondaryButton:disabled,.iconButton:disabled{cursor:not-allowed;opacity:.55}.topActions{display:flex;align-items:center;gap:10px}.tabs{display:flex;gap:4px;padding:10px 20px 0;background:#fff;border-bottom:1px solid #d9e0ea}.tabs button{display:inline-flex;align-items:center;gap:7px;height:40px;padding:0 14px;border:0;border-bottom:3px solid transparent;background:transparent;color:#465368;cursor:pointer;font-weight:700}.tabs button.active{color:#143947;border-bottom-color:#29657d}.errorBanner{margin:12px 20px 0;padding:10px 12px;border:1px solid #e2a0a0;border-radius:6px;background:#fff4f4;color:#8d2525;overflow-wrap:anywhere}.metrics{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:1px;background:#d9e0ea;border-bottom:1px solid #d9e0ea}.partnerSegments{display:flex;gap:10px;padding:14px 20px;overflow-x:auto;background:#edf1f6;border-bottom:1px solid #d9e0ea}.partnerSegment{min-width:170px;padding:10px 12px;border:1px solid #cbd6e3;border-radius:6px;background:#fff;color:#17202a;text-align:left;cursor:pointer}.partnerSegment strong,.partnerSegment span{display:block}.partnerSegment span{margin-top:4px;color:#627086;font-size:13px}.partnerSegment.active{border-color:#29657d;box-shadow:inset 0 0 0 1px #29657d}.page{padding:20px}.sectionHeader{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:16px}.sectionHeader select,.filters select{height:38px;min-width:150px;border:1px solid #cbd6e3;border-radius:6px;background:#fff;color:#17202a}.overviewGrid{display:grid;grid-template-columns:minmax(280px,.35fr) minmax(0,.65fr);gap:16px;align-items:start;margin-bottom:16px}.categoryList{display:flex;flex-direction:column;gap:8px;margin-top:14px}.categoryList div{display:flex;justify-content:space-between;gap:12px;padding:10px 0;border-bottom:1px solid #e5ebf2;text-transform:capitalize}.filters{display:grid;grid-template-columns:minmax(180px,.25fr) minmax(180px,.25fr) minmax(280px,1fr);gap:10px;margin-bottom:16px}.filters label{display:flex;align-items:center;gap:8px;height:38px;padding:0 10px;border:1px solid #cbd6e3;border-radius:6px;background:#fff}.filters label select{min-width:0;width:100%;border:0;outline:none}.metric{display:flex;align-items:center;gap:12px;min-height:84px;padding:16px 20px;background:#fff}.metric svg{width:20px;height:20px;color:#29657d}.metric strong{display:block;font-size:24px}.metric small,.messageMeta,.trace small,.conversationRow small{color:#627086}table{width:100%;border-collapse:collapse;margin-top:12px;font-size:13px}th,td{padding:9px 8px;border-bottom:1px solid #e5ebf2;text-align:right;white-space:nowrap}th:first-child,td:first-child{text-align:left}th{color:#465368;font-size:12px;font-weight:800;text-transform:uppercase}.tableList{display:flex;flex-direction:column;gap:9px;margin-top:14px}.failureRow{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;align-items:center;padding:12px;border:1px solid #d9e0ea;border-radius:6px;background:#fff}.failureRow>button:first-child{display:grid;grid-template-columns:minmax(180px,.35fr) minmax(130px,.2fr) minmax(0,.3fr) minmax(160px,.4fr);gap:12px;align-items:center;border:0;background:transparent;color:#17202a;text-align:left;cursor:pointer}.failureRow strong,.failureRow span,.failureRow small{overflow-wrap:anywhere}.failureRow small{color:#627086}.workspace{display:grid;grid-template-columns:300px minmax(0,1fr);min-height:calc(100vh - 170px)}.conversationList{background:#fff;border-right:1px solid #d9e0ea;padding:16px;overflow:auto}.search{display:flex;align-items:center;gap:8px;height:38px;padding:0 10px;border:1px solid #cbd6e3;border-radius:6px;margin-bottom:12px}.search input{width:100%;border:0;outline:none;background:transparent}.conversationRow{display:block;width:100%;text-align:left;padding:12px;margin-bottom:6px;border:1px solid transparent;border-radius:6px;background:#fff;cursor:pointer}.conversationRow span,.conversationRow strong,.conversationRow small{display:block}.conversationRow strong{margin-top:3px}.conversationRow.active{border-color:#8ab7c6;background:#edf7fa}.detail{padding:20px;overflow:auto}.detailHeader{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:16px}.columns{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(360px,.8fr);gap:16px;align-items:start}.panel,.suggestions{background:#fff;border:1px solid #d9e0ea;border-radius:8px;padding:16px}.panelTitle{display:flex;align-items:baseline;justify-content:space-between;gap:12px}.panelTitle span{color:#627086;font-size:13px;white-space:nowrap}.humanReplies{margin-top:16px}.timeline,.traceList{display:flex;flex-direction:column;gap:10px;margin-top:14px}.message,.trace,.suggestion{border:1px solid #e0e6ef;border-radius:6px;padding:12px;background:#fff}.message.customer{border-color:#9cc8e2;border-left:5px solid #1f6f9f;background:#f4faff}.message.human_agent{border-color:#9fcfb0;border-left:5px solid #2f7d4f;background:#f3fbf5}.message.bot{border-color:#dcc071;border-left:5px solid #9a6a13;background:#fff9ec}.message.private_note,.message.system{border-color:#c5ccd6;border-left:5px solid #6d7380;background:#f7f8fa}.messageMeta{display:flex;align-items:center;gap:8px;font-size:13px;margin-bottom:8px}.senderBadge{display:inline-flex;align-items:center;gap:4px;padding:3px 7px;border-radius:4px;font-size:11px;font-weight:800;line-height:1;text-transform:uppercase}.senderBadge.customer{background:#d9edf8;color:#14557f}.senderBadge.human_agent{background:#dcefe2;color:#1f643d}.senderBadge.bot{background:#f4e5bf;color:#744b06}.senderBadge.private_note,.senderBadge.system{background:#e4e8ee;color:#4f5662}.senderName{color:#17202a;font-weight:700}.messageMeta time{margin-left:auto}.labelPills{display:flex;flex-wrap:wrap;gap:5px;margin-top:7px}.labelPills span,.statusPill{display:inline-flex;align-items:center;min-height:22px;padding:3px 7px;border-radius:4px;background:#eef2f7;color:#364254;font-size:12px;font-weight:800;line-height:1}.statusPill.pending,.statusPill.high,.statusPill.critical{background:#fde7e7;color:#8d2525}.statusPill.no_problem,.statusPill.none{background:#e4f1e8;color:#1f643d}.statusPill.medium,.statusPill.low{background:#fff0cf;color:#76520d}.message p,.trace p,.suggestion p,.emptyState{margin:0;white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.45}.emptyState{color:#627086;font-size:14px}.attachments{display:flex;flex-direction:column;gap:8px;margin-top:10px}.attachment{display:grid;grid-template-columns:minmax(96px,160px) minmax(0,1fr) 34px;gap:10px;align-items:center;padding:8px;border:1px solid #d9e0ea;border-radius:6px;background:#f8fafc}.attachmentPreview{display:flex;align-items:center;justify-content:center;min-height:46px;color:#29657d;overflow:hidden}.attachment.image .attachmentPreview{min-height:92px;background:#fff;border-radius:4px}.attachmentPreview img,.attachmentPreview video{display:block;width:100%;max-height:220px;object-fit:contain}.attachmentPreview audio{width:100%;min-width:220px}.attachmentInfo{min-width:0}.attachmentInfo span,.attachmentInfo small{display:flex;align-items:center;gap:6px}.attachmentInfo span{overflow-wrap:anywhere;font-size:13px;font-weight:600}.attachmentInfo small{margin-top:4px;color:#627086}.attachmentAction{display:inline-flex;align-items:center;justify-content:center;width:30px;height:30px;border:1px solid #cbd6e3;border-radius:6px;background:#fff;color:#17202a}.trace.error,.trace.failed,.trace.timeout{border-left:4px solid #b93c3c}.trace.ok{border-left:4px solid #7794a3}.trace strong,.trace small{display:block}.suggestions{margin-top:16px}.suggestion{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;margin-top:10px}.suggestion.no_problem{border-left:5px solid #2f7d4f}.suggestion.pending{border-left:5px solid #b47b1c}.suggestionHeader{display:flex;align-items:center;flex-wrap:wrap;gap:7px}.suggestionBody{margin-top:8px}.suggestionBody p{color:#465368;font-size:14px;margin-top:2px}.suggestionBody pre{max-height:260px;margin:10px 0 0;overflow:auto;padding:10px;border:1px solid #d9e0ea;border-radius:6px;background:#f8fafc;color:#253043;font:12px/1.45 ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,monospace;white-space:pre-wrap;overflow-wrap:anywhere}.approve{border-radius:6px;color:#1c6b42}@media(max-width:1100px){.metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.workspace,.columns,.overviewGrid,.filters{grid-template-columns:1fr}.sectionHeader,.detailHeader{align-items:stretch;flex-direction:column}.failureRow,.failureRow>button:first-child{grid-template-columns:1fr}.conversationList{border-right:0;border-bottom:1px solid #d9e0ea;max-height:280px}.attachment{grid-template-columns:1fr 34px}.attachmentPreview{grid-column:1 / -1}.attachmentPreview audio{min-width:0}}
