*,*::before,*::after{box-sizing:border-box;margin:0;padding:0}
:root{
  --g:#1D9E75;--b:#378ADD;--p:#7F77DD;--o:#D85A30;--a:#BA7517;--r:#E24B4A;
  --bg:#0f1117;--bg2:#161820;--bg3:#1e2030;
  --border:rgba(255,255,255,0.1);
  --text:#ffffff;--text2:#aaaaaa;--text3:#555555;
  --rad:8px;--rad-lg:12px;
}
body{font-family:system-ui,-apple-system,sans-serif;background:var(--bg);color:var(--text);font-size:13px;height:100vh;overflow:hidden}
.app{display:grid;grid-template-columns:196px 1fr;grid-template-rows:46px 1fr;height:100vh}
.topbar{grid-column:1/-1;display:flex;align-items:center;justify-content:space-between;padding:0 14px;border-bottom:0.5px solid var(--border);background:var(--bg2)}
.sidebar{border-right:0.5px solid var(--border);display:flex;flex-direction:column;background:var(--bg2);overflow:hidden}
.main{display:flex;flex-direction:column;overflow:hidden}
.content{flex:1;overflow:hidden;padding:14px 16px;display:flex;flex-direction:column;gap:12px}
.screen{display:none;flex-direction:column;gap:12px;overflow-y:auto}
.screen.active{display:flex}
#screen-chat{flex:1;min-height:0;overflow:hidden}
.nav-group{font-size:10px;color:var(--text3);padding:9px 13px 3px;letter-spacing:.7px}
.nav-item{display:flex;align-items:center;gap:8px;padding:7px 13px;color:var(--text2);cursor:pointer;border-left:2px solid transparent;transition:all .1s}
.nav-item:hover{background:var(--bg);color:var(--text)}
.nav-item.active{color:var(--text);background:var(--bg);border-left-color:var(--g);font-weight:500}
.nav-badge{margin-left:auto;font-size:10px;padding:1px 6px;border-radius:20px;font-weight:500}
.card{border:0.5px solid var(--border);border-radius:var(--rad-lg);padding:12px 14px}
.card-title{font-size:13px;font-weight:500;color:var(--text);margin-bottom:10px}
.mcard{background:var(--bg2);border-radius:var(--rad);padding:10px 12px}
.mcard .lbl{font-size:11px;color:var(--text3);margin-bottom:4px}
.mcard .val{font-size:19px;font-weight:500;margin-bottom:2px}
.mcard .dlt{font-size:11px}
.btn{font-size:12px;padding:5px 12px;border-radius:var(--rad);border:0.5px solid var(--border);background:var(--bg2);color:var(--text);cursor:pointer}
.btn:hover{background:var(--bg3)}
.btn-primary{background:var(--g);border-color:var(--g);color:#fff}
.btn-primary:hover{opacity:.9}
.btn-danger{background:rgba(226,75,74,.15);border-color:rgba(226,75,74,.4);color:var(--r)}
.btn-sm{font-size:11px;padding:3px 8px}
input,select,textarea{background:var(--bg2);border:0.5px solid var(--border);border-radius:var(--rad);padding:7px 10px;color:var(--text);font-size:13px;outline:none;width:100%}
input:focus,select:focus{border-color:var(--g)}
.tag{font-size:10px;padding:2px 7px;border-radius:20px;font-weight:500}
.badge-dot{width:7px;height:7px;border-radius:50%;display:inline-block}
.grid-2{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.grid-3{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}
.grid-4{display:grid;grid-template-columns:repeat(4,1fr);gap:9px}
.flex{display:flex;align-items:center;gap:8px}
.flex-1{flex:1}
.chat-area{flex:1;overflow-y:auto;display:flex;flex-direction:column;gap:10px;min-height:0}
.bubble{max-width:84%;padding:9px 13px;border-radius:var(--rad-lg);font-size:13px;line-height:1.5}
.bubble-user{background:rgba(29,158,117,.15);border:0.5px solid rgba(29,158,117,.3);align-self:flex-end}
.bubble-ai{background:var(--bg2);border:0.5px solid var(--border);align-self:flex-start}
.bubble-label{font-size:10px;color:var(--text3);margin-bottom:5px}
.progress-bar{height:10px;background:var(--bg2);border-radius:5px;border:0.5px solid var(--border);position:relative;overflow:hidden}
.progress-fill{height:100%;border-radius:5px;transition:width .4s}
.toggle-track{width:28px;height:15px;border-radius:8px;cursor:pointer;position:relative;transition:background .15s;flex-shrink:0}
.toggle-thumb{position:absolute;top:1.5px;width:12px;height:12px;border-radius:50%;background:#fff;transition:left .15s}
table{width:100%;border-collapse:collapse;font-size:12px}
th{text-align:left;padding:6px 10px;font-weight:500;color:var(--text3);border-bottom:0.5px solid var(--border);background:var(--bg2)}
td{padding:7px 10px;border-bottom:0.5px solid rgba(255,255,255,0.05)}
tr:hover td{background:var(--bg2)}
::-webkit-scrollbar{width:4px}
::-webkit-scrollbar-track{background:transparent}
::-webkit-scrollbar-thumb{background:var(--bg3);border-radius:2px}
