﻿:root { color-scheme: dark; --bg:#0b1020; --panel:#111827; --muted:#94a3b8; --text:#e5e7eb; --line:#243045; --accent:#38bdf8; --accent-2:#2563eb; --danger:#fb7185; --ok:#34d399; }
* { box-sizing: border-box; }
body { margin:0; min-height:100vh; font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; background:radial-gradient(circle at top left,#172554 0,transparent 32rem),var(--bg); color:var(--text); }
.shell { display:grid; grid-template-columns:320px 1fr; gap:18px; min-height:100vh; padding:18px; }
.panel { background:rgba(17,24,39,.88); border:1px solid rgba(148,163,184,.18); border-radius:18px; box-shadow:0 24px 80px rgba(0,0,0,.28); }
.sidebar { padding:20px; }
.brand { display:flex; gap:12px; align-items:center; margin-bottom:24px; }
.logo { width:44px; height:44px; display:grid; place-items:center; border-radius:14px; background:linear-gradient(135deg,var(--accent),var(--accent-2)); color:white; font-weight:800; }
h1 { font-size:20px; margin:0; }
p { color:var(--muted); margin:4px 0 0; }
label { display:block; margin:14px 0; color:var(--muted); font-size:13px; }
input, select, textarea { width:100%; margin-top:7px; border:1px solid var(--line); border-radius:12px; background:#0f172a; color:var(--text); padding:12px; outline:none; }
textarea { resize:vertical; min-height:100px; line-height:1.5; }
input:focus, select:focus, textarea:focus { border-color:var(--accent); box-shadow:0 0 0 3px rgba(56,189,248,.12); }
.actions { display:flex; gap:10px; justify-content:flex-end; align-items:center; }
.actions.compact { justify-content:stretch; }
.actions.compact button { flex:1; }
button { border:0; border-radius:12px; padding:11px 16px; color:white; background:linear-gradient(135deg,var(--accent),var(--accent-2)); font-weight:700; cursor:pointer; }
button.secondary { background:#1f2937; color:var(--text); border:1px solid var(--line); }
button:disabled { opacity:.5; cursor:not-allowed; }
.status { margin-top:16px; padding:12px; border-radius:12px; background:#0f172a; color:var(--muted); word-break:break-word; }
.status.ok { color:var(--ok); }
.status.bad { color:var(--danger); }
.hint { margin-top:14px; color:var(--muted); font-size:13px; line-height:1.5; }
.chatPanel { display:grid; grid-template-rows:1fr auto; overflow:hidden; }
.messages { padding:22px; overflow:auto; }
.message { max-width:980px; margin:0 0 16px; }
.message .role { color:var(--muted); font-size:12px; margin-bottom:6px; }
.bubble { white-space:pre-wrap; overflow-wrap:anywhere; padding:14px 16px; border-radius:14px; border:1px solid var(--line); background:#0f172a; line-height:1.55; }
.message.user { margin-left:auto; }
.message.user .bubble { background:rgba(37,99,235,.16); border-color:rgba(56,189,248,.35); }
.message.assistant .bubble { font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace; font-size:13px; }
.composer { border-top:1px solid var(--line); padding:16px; background:rgba(15,23,42,.7); }
.composer .actions { margin-top:10px; }
@media (max-width:860px) { .shell { grid-template-columns:1fr; } .sidebar { order:2; } .chatPanel { min-height:70vh; } }
