:root{--bg:#fff;--text:#1c2430;--muted:#6b7686;--border:#dde2e9;--brand:#1f3b63;--on-brand:#fff;--bot-bg:#f1f4f8;--accent:#f5a524;--error:#b42318;--warn-bg:#fff6e5;color:var(--text);font:15px/1.5 system-ui,-apple-system,Segoe UI,Roboto,sans-serif}*{box-sizing:border-box}html,body,#root{height:100%;margin:0}body{background:var(--bg)}.chat{flex-direction:column;height:100%;display:flex}.chat-header{background:var(--brand);color:var(--on-brand);justify-content:space-between;align-items:center;gap:8px;padding:10px 10px 10px 16px;display:flex}.brand{align-items:center;gap:10px;display:flex}.avatar{background:var(--accent);width:34px;height:34px;color:var(--brand);border-radius:50%;place-items:center;font-weight:700;display:grid}.brand h1{margin:0;font-size:16px;line-height:1.2}.brand p{opacity:.85;margin:0;font-size:12px}.header-actions{gap:2px;display:flex}.icon-btn{width:34px;height:34px;color:inherit;cursor:pointer;background:0 0;border:0;border-radius:8px;place-items:center;display:grid}.icon-btn:hover{background:#ffffff26}.icon-btn svg{width:18px;height:18px}.idle-bar{background:var(--warn-bg);border-bottom:1px solid var(--border);justify-content:space-between;align-items:center;gap:8px;padding:8px 16px;font-size:13px;display:flex}.messages{flex-direction:column;flex:1;gap:10px;padding:16px;display:flex;overflow-y:auto}.msg{white-space:pre-wrap;overflow-wrap:anywhere;border-radius:14px;max-width:85%;padding:9px 13px}.msg.assistant{white-space:normal}.md>:first-child{margin-top:0}.md>:last-child{margin-bottom:0}.md p{margin:0 0 8px}.md .md-heading{font-weight:700}.md ul,.md ol{margin:0 0 8px;padding-left:20px}.md li{margin:2px 0}.md li>ul,.md li>ol{margin:2px 0 0}.md a{color:var(--brand)}.md code{background:#0000000d;border-radius:4px;padding:0 4px;font-size:13px}.md-table{margin:0 0 8px;overflow-x:auto}.md table{border-collapse:collapse;font-size:13px}.md th,.md td{border:1px solid var(--border);text-align:left;vertical-align:top;padding:4px 8px}.md th{background:#00000008}.msg.user{background:var(--brand);color:var(--on-brand);border-bottom-right-radius:4px;align-self:flex-end}.msg.assistant{background:var(--bot-bg);border-bottom-left-radius:4px;align-self:flex-start}.msg.pending{color:var(--muted)}.msg .error{color:var(--error);margin-top:4px;font-size:13px;display:block}.status-note{text-align:center;color:var(--muted);margin:0;font-size:13px}.ended{text-align:center;color:var(--muted);padding:8px 0}.ended p{margin:0 0 10px}.form-card{background:var(--bg);border:1px solid var(--border);border-radius:14px 14px 14px 4px;align-self:flex-start;width:85%;padding:14px;box-shadow:0 1px 3px #0000000f}.form-title{margin:0 0 4px;font-weight:600;display:block}.form-note{color:var(--muted);margin:0 0 12px;font-size:13px}.form-note.resend{margin:10px 0 0}.form-actions{gap:8px;display:flex}.form-error{color:var(--error);margin:10px 0 0;font-size:13px}.phone-field{border:1px solid var(--border);border-radius:10px;align-items:center;margin-bottom:12px;display:flex;overflow:hidden}.phone-field span{background:var(--bot-bg);border-right:1px solid var(--border);color:var(--muted);padding:9px 10px}.phone-field input,.otp-input{min-width:0;font:inherit;color:inherit;background:0 0;border:0;outline:none;flex:1;padding:9px 12px;font-size:16px}.otp-input{border:1px solid var(--border);letter-spacing:.3em;border-radius:10px;width:100%;margin-bottom:12px}.phone-field:focus-within,.otp-input:focus{border-color:var(--brand)}.btn{font:inherit;color:var(--text);background:var(--bg);border:1px solid var(--border);cursor:pointer;border-radius:999px;padding:8px 16px;font-weight:600}.btn.primary{color:var(--on-brand);background:var(--brand);border-color:var(--brand)}.btn:disabled{opacity:.5;cursor:default}.link{font:inherit;color:var(--brand);cursor:pointer;background:0 0;border:0;padding:0;text-decoration:underline}.link:disabled{opacity:.5;cursor:default}.composer{border-top:1px solid var(--border);gap:8px;padding:12px;display:flex}.composer input{min-width:0;font:inherit;color:inherit;background:var(--bg);border:1px solid var(--border);border-radius:999px;outline:none;flex:1;padding:10px 14px;font-size:16px}.composer input:focus{border-color:var(--brand)}.composer input:disabled{background:var(--bot-bg)}.composer button{font:inherit;color:var(--brand);background:var(--accent);cursor:pointer;border:0;border-radius:999px;padding:10px 18px;font-weight:600}.composer button:disabled{opacity:.5;cursor:default}button:focus-visible,input:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
