/* ZeekWeb AI Office — design tokens and components. No external fonts or CDNs (works offline). */
:root {
  --bg: #04060A; --bg-2: #080E18; --panel: #0C1420; --panel-2: #101B2A; --line: #18263A; --line-2: #22344D;
  --lime: #B6FF4E; --cyan: #00D9FF; --teal: #00F0C8; --mint: #67FFB8;
  --text: #F5F7FA; --text-2: #94A3B8; --text-3: #64748B;
  --warn: #FFB547; --high: #FF7A45; --crit: #FF4D6A; --info: #00D9FF; --ok: #67FFB8; --off: #475569; --paused: #A78BFA;
  --radius: 12px; --radius-sm: 8px;
  --font: "Inter", "Segoe UI", system-ui, -apple-system, Roboto, Helvetica, Arial, sans-serif;
  --mono: "JetBrains Mono", "Cascadia Code", Consolas, "SF Mono", monospace;
  --sidebar: 236px; --topbar: 60px;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--text); font: 14px/1.5 var(--font); -webkit-font-smoothing: antialiased; }
body { background-image: linear-gradient(rgba(0,217,255,.025) 1px, transparent 1px), linear-gradient(90deg, rgba(0,217,255,.025) 1px, transparent 1px); background-size: 32px 32px; }
a { color: var(--cyan); text-decoration: none; } a:hover { text-decoration: underline; }
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -.01em; }
h1 { font-size: 22px; } h2 { font-size: 16px; } h3 { font-size: 13px; color: var(--text-2); text-transform: uppercase; letter-spacing: .06em; font-weight: 600; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }
.mono { font-family: var(--mono); font-size: 12.5px; }
.muted { color: var(--text-2); } .dim { color: var(--text-3); } .small { font-size: 12px; }
.hidden { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- shell ---------- */
.shell { display: grid; grid-template-columns: var(--sidebar) 1fr; grid-template-rows: var(--topbar) 1fr; height: 100vh; }
.sidebar { grid-row: 1 / 3; background: rgba(8,14,24,.92); border-right: 1px solid var(--line); display: flex; flex-direction: column; overflow-y: auto; }
.brand { display: flex; align-items: center; gap: 10px; padding: 16px 18px; height: var(--topbar); border-bottom: 1px solid var(--line); }
.brand img { height: 28px; max-width: 150px; object-fit: contain; }
.brand .word { font-weight: 700; font-size: 17px; letter-spacing: .01em; }
.brand .word b { color: var(--lime); font-weight: 700; }
.brand .tag { font-size: 10px; color: var(--text-3); text-transform: uppercase; letter-spacing: .12em; display: block; line-height: 1; margin-top: 2px; }
.nav { padding: 10px 10px 20px; display: flex; flex-direction: column; gap: 2px; }
.nav a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: var(--radius-sm); color: var(--text-2); font-weight: 500; text-decoration: none; }
.nav a:hover { background: var(--panel); color: var(--text); }
.nav a.on { background: linear-gradient(90deg, rgba(182,255,78,.12), rgba(182,255,78,0)); color: var(--text); box-shadow: inset 2px 0 0 var(--lime); }
.nav a .badge { margin-left: auto; }
.nav .sep { height: 1px; background: var(--line); margin: 8px 6px; }
.ico { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.sidebar .foot { margin-top: auto; padding: 14px 18px; border-top: 1px solid var(--line); font-size: 12px; color: var(--text-3); }

.topbar { display: flex; align-items: center; gap: 14px; padding: 0 22px; border-bottom: 1px solid var(--line); background: rgba(4,6,10,.85); backdrop-filter: blur(8px); position: relative; z-index: 5; }
.search { position: relative; flex: 1; max-width: 460px; }
.search input[type=search] { width: 100%; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px 8px 34px; }
.search .ico { position: absolute; left: 10px; top: 9px; color: var(--text-3); width: 16px; height: 16px; }
.search .results { position: absolute; top: 42px; left: 0; right: 0; background: var(--panel-2); border: 1px solid var(--line-2); border-radius: 10px; padding: 6px; box-shadow: 0 16px 40px rgba(0,0,0,.5); max-height: 380px; overflow-y: auto; }
.search .results a { display: flex; gap: 10px; padding: 7px 10px; border-radius: 8px; color: var(--text); }
.search .results a:hover { background: var(--panel); text-decoration: none; }
.topbar .spacer { flex: 1; }
.conn { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--text-2); padding: 5px 10px; border: 1px solid var(--line); border-radius: 999px; }
.clock { font-size: 12.5px; color: var(--text-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
.iconbtn { position: relative; background: none; border: 1px solid var(--line); border-radius: 10px; width: 36px; height: 36px; display: grid; place-items: center; cursor: pointer; color: var(--text-2); }
.iconbtn:hover { color: var(--text); border-color: var(--line-2); }
.iconbtn .dot { position: absolute; top: -4px; right: -4px; }
.main { overflow-y: auto; padding: 24px 28px 60px; }
.page-head { display: flex; align-items: flex-end; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.page-head .sub { color: var(--text-2); margin-top: 4px; }
.page-head .actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.page-head .actions select, .page-head .actions input, .row > select, .row > input { width: auto; }
.main > .note { margin-bottom: 14px; }

/* ---------- components ---------- */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--panel); color: var(--text); cursor: pointer; font-weight: 500; white-space: nowrap; }
.btn:hover { border-color: var(--text-3); }
.btn.primary { background: var(--lime); color: #071006; border-color: var(--lime); font-weight: 600; }
.btn.primary:hover { filter: brightness(1.06); }
.btn.danger { border-color: rgba(255,77,106,.5); color: #ffb3c0; }
.btn.ghost { background: none; border-color: transparent; color: var(--text-2); }
.btn.sm { padding: 5px 10px; font-size: 12.5px; border-radius: 8px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.panel { background: rgba(12,20,32,.82); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.panel.glass { background: linear-gradient(180deg, rgba(16,27,42,.75), rgba(12,20,32,.75)); backdrop-filter: blur(6px); }
.panel-head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.panel-head .right { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.grid { display: grid; gap: 16px; align-items: start; }
.g2 { grid-template-columns: repeat(2, minmax(0,1fr)); } .g3 { grid-template-columns: repeat(3, minmax(0,1fr)); } .g4 { grid-template-columns: repeat(4, minmax(0,1fr)); }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; }
.stat { background: rgba(12,20,32,.82); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; min-height: 92px; }
.stat .label { font-size: 12px; color: var(--text-2); display: flex; align-items: center; gap: 6px; }
.stat .value { font-size: 26px; font-weight: 650; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.stat .foot { font-size: 11.5px; color: var(--text-3); margin-top: auto; }
.stat.accent .value { color: var(--lime); }
.stat.warn .value { color: var(--warn); } .stat.bad .value { color: var(--crit); }
.stat.sm .value { font-size: 16px; font-weight: 600; }
.stat .label .tag { font-size: 10px; padding: 1px 6px; }
.stat.na .value { color: var(--text-3); font-size: 15px; font-weight: 500; }
.tag { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--line-2); color: var(--text-2); white-space: nowrap; }
.tag.est { border-color: rgba(255,181,71,.4); color: var(--warn); }
.tag.live { border-color: rgba(103,255,184,.4); color: var(--mint); }
.tag.demo { border-color: rgba(167,139,250,.5); color: var(--paused); }
.badge { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; font-size: 11px; font-weight: 700; background: var(--crit); color: #fff; }
.badge.soft { background: var(--panel-2); color: var(--text-2); border: 1px solid var(--line-2); }

/* status lights */
.light { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex: none; background: var(--off); }
.s-busy .light, .light.s-busy { background: var(--lime); box-shadow: 0 0 0 0 rgba(182,255,78,.6); animation: pulse 1.8s infinite; }
.s-active .light, .light.s-active { background: var(--mint); }
.s-idle .light, .light.s-idle { background: var(--cyan); opacity: .75; }
.s-waiting .light, .light.s-waiting { background: var(--warn); animation: pulse-w 2.2s infinite; }
.s-paused .light, .light.s-paused { background: var(--paused); }
.s-offline .light, .light.s-offline { background: var(--off); }
.s-error .light, .light.s-error { background: var(--crit); box-shadow: 0 0 10px rgba(255,77,106,.7); }
.light.ok { background: var(--ok); } .light.warn { background: var(--warn); } .light.bad { background: var(--crit); } .light.pending { background: var(--text-3); }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(182,255,78,.55); } 70% { box-shadow: 0 0 0 8px rgba(182,255,78,0); } 100% { box-shadow: 0 0 0 0 rgba(182,255,78,0); } }
@keyframes pulse-w { 0%,100% { opacity: 1; } 50% { opacity: .45; } }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
.state { display: inline-flex; align-items: center; gap: 7px; font-weight: 500; text-transform: capitalize; }

/* tables */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th { text-align: left; color: var(--text-3); font-weight: 600; font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em; padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 10px; border-bottom: 1px solid rgba(24,38,58,.6); vertical-align: top; }
tr.click { cursor: pointer; } tr.click:hover td { background: rgba(16,27,42,.6); }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.empty { padding: 26px; text-align: center; color: var(--text-3); }

/* forms */
.form { display: grid; gap: 14px; }
.field { display: grid; gap: 6px; }
.field label { font-size: 12.5px; color: var(--text-2); font-weight: 500; }
.field .hint { font-size: 11.5px; color: var(--text-3); }
input:not([type]), input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], input[type=datetime-local], input[type=search], select, textarea {
  background: var(--bg-2); border: 1px solid var(--line-2); border-radius: 9px; padding: 9px 11px; width: 100%; }
textarea { min-height: 110px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--cyan); outline: none; }
.check { display: flex; gap: 9px; align-items: flex-start; font-size: 13px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.seg { display: inline-flex; border: 1px solid var(--line-2); border-radius: 10px; overflow: hidden; }
.seg button { background: none; border: 0; padding: 6px 12px; color: var(--text-2); cursor: pointer; font-size: 12.5px; }
.seg button.on { background: var(--panel-2); color: var(--text); }
.err { color: #ffb3c0; font-size: 13px; }
.note { border: 1px solid var(--line-2); border-left: 3px solid var(--cyan); background: rgba(0,217,255,.05); padding: 10px 12px; border-radius: 8px; color: var(--text-2); font-size: 12.5px; }
.note.warn { border-left-color: var(--warn); background: rgba(255,181,71,.06); }
.note.bad { border-left-color: var(--crit); background: rgba(255,77,106,.06); }

/* feed */
.feed { display: flex; flex-direction: column; }
.feed .ev { display: grid; grid-template-columns: 74px 10px 1fr auto; gap: 10px; align-items: baseline; padding: 8px 4px; border-bottom: 1px solid rgba(24,38,58,.55); }
.feed .ev .t { color: var(--text-3); font-size: 12px; font-variant-numeric: tabular-nums; }
.feed .ev .sv { width: 8px; height: 8px; border-radius: 50%; background: var(--cyan); align-self: center; }
.feed .ev .sv.warning { background: var(--warn); } .feed .ev .sv.high { background: var(--high); } .feed .ev .sv.critical { background: var(--crit); }
.feed .ev .src { font-size: 11px; color: var(--text-3); }
.feed .ev.new { animation: flash 1.2s ease-out; }
@keyframes flash { from { background: rgba(182,255,78,.12); } to { background: transparent; } }

/* office */
.office { position: relative; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; padding: 18px; border-radius: var(--radius);
  background: radial-gradient(1200px 400px at 50% -10%, rgba(0,240,200,.06), transparent), rgba(8,14,24,.7); border: 1px solid var(--line); }
.desk { position: relative; text-align: left; background: linear-gradient(180deg, rgba(16,27,42,.9), rgba(12,20,32,.9)); border: 1px solid var(--line-2); border-radius: 14px; padding: 16px; cursor: pointer; color: inherit; transition: transform .15s ease, border-color .15s ease; }
.desk:hover { transform: translateY(-2px); border-color: var(--cyan); }
.desk .screen { height: 70px; border-radius: 9px; background: #050a12; border: 1px solid var(--line); margin-bottom: 12px; position: relative; overflow: hidden; display: grid; place-items: center; }
.desk .screen svg { width: 100%; height: 100%; }
.desk.s-busy .screen { border-color: rgba(182,255,78,.45); }
.desk.s-busy .bar { animation: typing 1.6s ease-in-out infinite; }
.desk.s-busy .bar:nth-child(2) { animation-delay: .2s; } .desk.s-busy .bar:nth-child(3) { animation-delay: .4s; } .desk.s-busy .bar:nth-child(4) { animation-delay: .6s; }
@keyframes typing { 0%,100% { opacity: .25; } 50% { opacity: 1; } }
.desk.s-error { border-color: rgba(255,77,106,.6); }
.desk.s-offline { opacity: .6; }
.desk .who { display: flex; align-items: center; gap: 8px; font-weight: 600; }
.desk .role { color: var(--text-2); font-size: 12px; }
.desk .task { margin-top: 8px; font-size: 12.5px; color: var(--text-2); min-height: 36px; }
.desk .meta { display: flex; justify-content: space-between; margin-top: 8px; font-size: 11.5px; color: var(--text-3); }

/* agent cards */
.agent-card { display: grid; gap: 10px; }
.agent-card .top { display: flex; align-items: center; gap: 12px; }
.avatar { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; font-weight: 700; background: linear-gradient(135deg, rgba(0,217,255,.2), rgba(182,255,78,.15)); border: 1px solid var(--line-2); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: 12.5px; }
.kv dt { color: var(--text-3); } .kv dd { margin: 0; }

/* charts */
.chart { width: 100%; height: 220px; display: block; }
.chart .axis { stroke: var(--line-2); stroke-width: 1; }
.chart .grid { stroke: rgba(24,38,58,.7); stroke-width: 1; }
.chart text { fill: var(--text-3); font-size: 10.5px; font-family: var(--font); }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--text-2); margin-top: 6px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.bars { display: grid; gap: 8px; }
.bars .b { display: grid; grid-template-columns: 120px 1fr 70px; gap: 10px; align-items: center; font-size: 12.5px; }
.bars .track { height: 8px; border-radius: 6px; background: var(--bg-2); overflow: hidden; }
.bars .fill { height: 100%; background: linear-gradient(90deg, var(--cyan), var(--lime)); border-radius: 6px; }
.meter { height: 8px; border-radius: 6px; background: var(--bg-2); overflow: hidden; }
.meter > div { height: 100%; background: var(--mint); }
.meter.w > div { background: var(--warn); } .meter.b > div { background: var(--crit); }

/* drawer + modal */
.overlay { position: fixed; inset: 0; background: rgba(2,4,8,.6); z-index: 40; display: flex; justify-content: flex-end; }
.drawer { width: min(520px, 100%); height: 100%; background: var(--bg-2); border-left: 1px solid var(--line-2); padding: 22px; overflow-y: auto; box-shadow: -20px 0 50px rgba(0,0,0,.4); }
.modal-wrap { position: fixed; inset: 0; background: rgba(2,4,8,.65); z-index: 50; display: grid; place-items: center; padding: 20px; }
.modal { width: min(560px, 100%); background: var(--bg-2); border: 1px solid var(--line-2); border-radius: 14px; padding: 22px; box-shadow: 0 30px 80px rgba(0,0,0,.6); }
.modal .actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.toast-wrap { position: fixed; bottom: 90px; right: 22px; z-index: 60; display: grid; gap: 8px; }
.toast { background: var(--panel-2); border: 1px solid var(--line-2); border-left: 3px solid var(--cyan); padding: 10px 14px; border-radius: 10px; min-width: 260px; max-width: 380px; box-shadow: 0 10px 30px rgba(0,0,0,.4); font-size: 13px; }
.toast.err { border-left-color: var(--crit); } .toast.ok { border-left-color: var(--mint); }

/* ask zeek */
.ask { position: fixed; right: 22px; bottom: 22px; z-index: 30; }
.ask .fab { width: 52px; height: 52px; border-radius: 16px; border: 1px solid rgba(182,255,78,.5); background: linear-gradient(135deg, #0f1c10, #0c1420); color: var(--lime); cursor: pointer; display: grid; place-items: center; box-shadow: 0 10px 30px rgba(0,0,0,.5); }
.ask .box { position: absolute; right: 0; bottom: 64px; width: min(400px, calc(100vw - 40px)); height: 460px; background: var(--bg-2); border: 1px solid var(--line-2); border-radius: 14px; display: flex; flex-direction: column; box-shadow: 0 30px 80px rgba(0,0,0,.6); }
.ask .msgs { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.ask .m { padding: 9px 12px; border-radius: 10px; max-width: 88%; font-size: 13px; }
.ask .m.me { align-self: flex-end; background: rgba(0,217,255,.12); border: 1px solid rgba(0,217,255,.25); }
.ask .m.bot { align-self: flex-start; background: var(--panel); border: 1px solid var(--line-2); }
.ask form { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--line); }

/* auth */
.auth { min-height: 100vh; display: grid; place-items: center; padding: 20px; background: radial-gradient(900px 500px at 50% 0%, rgba(0,240,200,.08), transparent); }
.auth .card { width: min(400px, 100%); background: rgba(12,20,32,.9); border: 1px solid var(--line-2); border-radius: 16px; padding: 28px; }
.auth .brand { border: 0; padding: 0; height: auto; margin-bottom: 18px; }

pre.out { white-space: pre-wrap; word-break: break-word; background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 14px; max-height: 520px; overflow-y: auto; font-family: var(--mono); font-size: 12.5px; color: var(--text); }
.timeline { border-left: 1px solid var(--line-2); margin-left: 6px; padding-left: 16px; display: grid; gap: 10px; }
.timeline .it { position: relative; font-size: 13px; }
.timeline .it::before { content: ""; position: absolute; left: -21px; top: 6px; width: 9px; height: 9px; border-radius: 50%; background: var(--cyan); border: 2px solid var(--bg); }
.timeline .it.warning::before { background: var(--warn); } .timeline .it.high::before, .timeline .it.critical::before { background: var(--crit); }

@media (max-width: 1100px) { .g4 { grid-template-columns: repeat(2, minmax(0,1fr)); } .g3 { grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (max-width: 860px) {
  .shell { grid-template-columns: 1fr; grid-template-rows: var(--topbar) auto 1fr; }
  .sidebar { grid-row: auto; flex-direction: row; overflow-x: auto; }
  .sidebar .brand, .sidebar .foot, .nav .sep { display: none; }
  .nav { flex-direction: row; padding: 6px; }
  .nav a { padding: 6px 10px; white-space: nowrap; }
  .g2, .g3, .g4 { grid-template-columns: 1fr; }
  .main { padding: 18px 16px 80px; }
  .clock, .conn span.txt { display: none; }
}
@media print {
  .sidebar, .topbar, .ask, .page-head .actions, .btn { display: none !important; }
  .shell { display: block; } body { background: #fff; color: #000; } .panel, .stat { border-color: #ccc; background: #fff; }
  .muted, .dim, th { color: #444; }
}

/* ---------- Office Room ---------- */
.office-strip { display: flex; flex-wrap: wrap; gap: 8px 22px; padding: 12px 16px; border: 1px solid var(--line); border-radius: var(--radius); background: rgba(12,20,32,.7); color: var(--text-2); font-size: 13.5px; }
.office-strip b { color: var(--text); font-size: 15px; margin-right: 2px; font-variant-numeric: tabular-nums; }
.office-strip .warn b { color: var(--warn); }
.office-room { margin-top: 14px; border: 1px solid var(--line); border-radius: 16px; overflow: hidden;
  background: radial-gradient(1100px 520px at 50% 10%, #16233A 0%, #0A111D 55%, #060A12 100%); }
.office-svg { width: 100%; height: auto; display: block; max-height: 82vh; }
.office-svg .ws { cursor: pointer; outline: none; }
.office-svg .ws:hover .tag rect, .office-svg .ws:focus-visible .tag rect { stroke: var(--cyan); stroke-width: 2; }
.office-svg .ws:focus-visible { filter: drop-shadow(0 0 6px rgba(0,217,255,.6)); }
.office-svg .typing .body { animation: zw-bob 1.3s ease-in-out infinite; }
.office-svg .keys circle { animation: zw-key .9s ease-in-out infinite; }
.office-svg .keys circle:nth-child(2) { animation-delay: .15s; } .office-svg .keys circle:nth-child(3) { animation-delay: .3s; }
.office-svg .s-busy .screenglow { animation: zw-glow 2.6s ease-in-out infinite; }
.office-svg .wave { animation: zw-wave 1.1s ease-in-out infinite; transform-box: fill-box; transform-origin: 50% 100%; }
.office-svg .steam { animation: zw-steam 3s ease-in-out infinite; }
.office-svg .alarm circle, .office-svg .blink { animation: zw-blink 1.1s steps(2) infinite; }
.office-svg .bubble.loud { animation: zw-float 3.4s ease-in-out infinite; }
.office-svg .twinkle { animation: zw-twinkle 7s ease-in-out infinite; }
.office-svg .leaf { animation: zw-sway 6s ease-in-out infinite; transform-box: fill-box; transform-origin: 50% 100%; }
.office-svg .neon { animation: zw-neon 9s linear infinite; }
@keyframes zw-bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-1.2px); } }
@keyframes zw-key { 0%,100% { opacity: .2; } 50% { opacity: 1; } }
@keyframes zw-glow { 0%,100% { opacity: .75; } 50% { opacity: 1; } }
@keyframes zw-wave { 0%,100% { transform: rotate(-7deg); } 50% { transform: rotate(9deg); } }
@keyframes zw-steam { 0% { opacity: 0; transform: translateY(4px); } 40% { opacity: .8; } 100% { opacity: 0; transform: translateY(-7px); } }
@keyframes zw-blink { 0% { opacity: 1; } 50% { opacity: .2; } }
@keyframes zw-float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
@keyframes zw-twinkle { 0%,100% { opacity: .75; } 50% { opacity: .15; } }
@keyframes zw-sway { 0%,100% { transform: rotate(-2deg); } 50% { transform: rotate(2deg); } }
@keyframes zw-neon { 0%,92%,96%,100% { opacity: 1; } 94% { opacity: .55; } }
.office-legend { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 12px; font-size: 12.5px; color: var(--text-2); }
.office-legend span { display: inline-flex; align-items: center; gap: 7px; }

/* Lead Engine */
.lead-gap { height: 16px; }
.lead-key { margin-bottom: 14px; }
.lead-key .row { flex-wrap: nowrap; align-items: center; }
.lead-key .row input { flex: 1; min-width: 0; }
/* Lead Engine progress card */
.lead-progress { border: 1px solid var(--line-2); border-radius: var(--radius); padding: 14px 16px; margin: 12px 0 4px; background: var(--panel); }
.lead-progress.hidden { display: none; }
.lead-progress.run { border-color: var(--cyan); background: rgba(0, 217, 255, .06); }
.lead-progress.ok { border-color: var(--mint); background: rgba(103, 255, 184, .06); }
.lead-progress.bad { border-color: var(--crit); background: rgba(255, 77, 106, .07); }
.lead-progress .row { align-items: center; gap: 10px; }
.lead-progress .muted { margin-top: 4px; }
.lead-bar { height: 6px; margin-top: 10px; border-radius: 3px; background: var(--line); overflow: hidden; }
.lead-bar > i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--cyan), var(--lime)); transition: width .5s ease; }
.lead-spin { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--line-2); border-top-color: var(--cyan); animation: lead-spin .8s linear infinite; flex: none; }
@keyframes lead-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .lead-spin { animation: none; } .lead-bar > i { transition: none; } }
/* Supplier detail */
.lead-detail { display: grid; gap: 14px; max-height: 78vh; overflow: auto; padding-right: 4px; }
.lead-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.lead-score { display: flex; align-items: baseline; gap: 6px; } .lead-score b { font-size: 28px; color: var(--lime); }
.lead-sec { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; background: var(--panel); }
.lead-sec h3 { margin: 0 0 10px; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--text-2); }
.lead-sec p { margin: 10px 0 4px; font-size: 12.5px; line-height: 1.5; }
.lead-meters { display: grid; gap: 9px; } .lead-meter .row { justify-content: space-between; font-size: 12.5px; margin-bottom: 4px; }
.lead-shots { display: flex; gap: 14px; align-items: flex-start; } .lead-shots figure { margin: 0; flex: 3; }
.lead-shots figure.mob { flex: 1; max-width: 220px; } .lead-shots img { width: 100%; max-height: 340px; object-fit: cover; object-position: top; border-radius: 8px; border: 1px solid var(--line-2); display: block; }
.lead-shots figcaption { font-size: 11.5px; color: var(--text-3); margin-top: 4px; }
.lead-cat h4 { margin: 16px 0 6px; font-size: 13px; color: var(--cyan); } .lead-cat td { vertical-align: top; font-size: 12.5px; }
@media (max-width: 760px) { .lead-shots { flex-direction: column; } .lead-shots figure.mob { max-width: none; } }

/* ---------- lead engine: list, report, review queue ---------- */
.lead-auto { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 12px; padding: 10px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--panel); font-size: 13px; }
.lead-auto .btn { margin-left: auto; }
.lead-filters { flex-wrap: wrap; gap: 8px; align-items: center; }
.lead-filters input[type=search] { flex: 1; min-width: 180px; }
.lead-check { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-2); cursor: pointer; margin: 4px 0 10px; }
.lead-co { min-width: 220px; max-width: 340px; } .lead-co strong { display: block; }
.lead-clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.lead-contacts { font-size: 12.5px; line-height: 1.6; min-width: 190px; } .lead-contacts .mono { font-size: 12px; }
.lead-copy { background: none; border: 1px solid var(--line-2); border-radius: 6px; color: var(--text-2); font-size: 11px; padding: 0 6px; cursor: pointer; }
.lead-copy:hover { color: var(--cyan); border-color: var(--cyan); }
.lead-sc { display: inline-flex; align-items: center; gap: 6px; } .lead-sc b { font-size: 18px; color: var(--lime); }
.lead-top { margin: 4px 0 0; padding-left: 16px; font-size: 12.5px; color: var(--text-2); max-width: 360px; } .lead-top li { margin: 1px 0; }
.lead-busy { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--cyan); margin-top: 4px; }
.lead-busy .lead-spin { width: 11px; height: 11px; }
.lead-failhead { justify-content: space-between; align-items: center; margin-top: 14px; }
.lead-review-top { justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.lead-drafts { display: grid; gap: 12px; }
.lead-draft { border: 1px solid var(--line-2); border-radius: var(--radius-sm); padding: 12px 14px; background: var(--panel-2); display: grid; gap: 8px; }
.lead-draft-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; flex-wrap: wrap; }
.lead-draft-head .row { gap: 6px; align-items: center; }
.lead-subj, .lead-body { width: 100%; background: var(--bg-2); border: 1px solid var(--line-2); border-radius: 8px; padding: 8px 10px; color: var(--text); }
.lead-body { font-size: 13px; line-height: 1.55; resize: vertical; }
.lead-subj:disabled, .lead-body:disabled { opacity: .75; }
.lead-draft-actions { flex-wrap: wrap; gap: 6px; }
.lead-pre { white-space: pre-wrap; font-size: 12.5px; line-height: 1.55; color: var(--text-2); max-height: 220px; overflow: auto; }
.lead-verdict { font-size: 13.5px !important; color: var(--text); }
.lead-issues { margin: 8px 0; padding-left: 20px; display: grid; gap: 8px; font-size: 13px; }
.lead-report .row { gap: 6px; flex-wrap: wrap; align-items: center; margin-top: 6px; }
@media (max-width: 760px) { .lead-co, .lead-top { max-width: none; } .lead-auto .btn { margin-left: 0; } }
@media (max-width: 760px) { .lead-review-top .seg { display: flex; flex-wrap: wrap; } .lead-review-top .seg button { flex: 1 1 45%; } .panel-head .right .tag { white-space: normal; } .lead-draft-actions .btn { flex: 1 1 auto; } }
.lead-auto-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.lead-auto-grid .lead-sec { display: grid; gap: 10px; align-content: start; }
.lead-auto-grid .row { flex-wrap: wrap; gap: 8px; align-items: center; }
.lead-auto-grid details summary { cursor: pointer; margin-bottom: 8px; }
.lead-kv { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.lead-kv > div { border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; display: grid; }
.lead-kv b { font-size: 20px; color: var(--lime); } .lead-kv span { font-size: 11.5px; color: var(--text-2); }
@media (max-width: 1100px) { .lead-auto-grid { grid-template-columns: 1fr; } }
.lead-two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; } .lead-two input { min-width: 0; width: 100%; }

.tag.lead-warn { border-color: rgba(255,181,71,.5); color: var(--warn); }

/* 2-step login */
.tfa-steps { margin: 6px 0 6px 18px; padding: 0; display: grid; gap: 6px; }
.tfa-grid { display: grid; grid-template-columns: auto 1fr; gap: 16px; align-items: center; }
.tfa-qr svg { display: block; width: 190px; height: 190px; border-radius: 8px; }
.tfa-key { font-size: 15px; letter-spacing: .06em; margin: 6px 0; user-select: all; word-break: normal; }
.tfa-codes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 18px; padding: 12px 14px; border: 1px dashed var(--line); border-radius: 8px; font-size: 15px; }
.tfa .row input[type=text] { max-width: 140px; font-size: 18px; letter-spacing: .2em; text-align: center; }
.auth .card .tfa { text-align: left; }
@media (max-width: 560px) { .tfa-grid { grid-template-columns: 1fr; justify-items: center; } }

.tfa label.row { display: flex; flex-wrap: nowrap; align-items: flex-start; gap: 10px; }
.tfa label.row input { margin-top: 3px; flex: none; }

/* ---------- Stage 2: Home, Pipeline, Reports ---------- */
.kpis { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.kpi { text-align: left; font: inherit; color: inherit; background: linear-gradient(180deg, rgba(16,27,42,.9), rgba(12,20,32,.85)); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; display: flex; flex-direction: column; gap: 6px; min-height: 108px; position: relative; overflow: hidden; }
.kpi::after { content: ""; position: absolute; inset: 0 0 auto 0; height: 2px; background: linear-gradient(90deg, var(--cyan), transparent); opacity: .5; }
button.kpi { cursor: pointer; } button.kpi:hover { border-color: var(--line-2); }
.kpi-top { display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--text-2); font-weight: 500; }
.kpi-top .ico { width: 15px; height: 15px; color: var(--text-3); }
.kpi-value { font-size: 30px; font-weight: 680; letter-spacing: -.02em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.kpi-foot { font-size: 11.5px; color: var(--text-3); margin-top: auto; }
.kpi.good .kpi-value { color: var(--lime); } .kpi.good::after { background: linear-gradient(90deg, var(--lime), transparent); }
.kpi.warn .kpi-value { color: var(--warn); } .kpi.warn::after { background: linear-gradient(90deg, var(--warn), transparent); opacity: .8; }
.banner { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 16px; margin-bottom: 16px; border-radius: var(--radius); border: 1px solid rgba(255,181,71,.45); background: linear-gradient(90deg, rgba(255,181,71,.12), rgba(255,181,71,.03)); color: var(--text); }
.banner:hover { text-decoration: none; border-color: var(--warn); } .banner .ico { color: var(--warn); } .banner span { color: var(--text-2); }
.home-a { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); margin-bottom: 16px; }
.home-b { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); margin-bottom: 16px; }
.panel-head h2 { display: flex; align-items: center; gap: 8px; } .panel-head h2 .ico { color: var(--cyan); }
.digest-meta { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 10px; }
.digest-text { white-space: pre-wrap; line-height: 1.65; color: var(--text); font-size: 13.5px; background: rgba(4,6,10,.5); border: 1px solid var(--line); border-left: 3px solid var(--lime); border-radius: 8px; padding: 12px 14px; }
.allclear { display: flex; gap: 12px; align-items: center; padding: 14px; border-radius: 10px; background: rgba(103,255,184,.06); border: 1px solid rgba(103,255,184,.25); }
.allclear .ico { color: var(--mint); width: 22px; height: 22px; }
.needs { display: grid; gap: 8px; max-height: 420px; overflow-y: auto; }
.need { text-align: left; font: inherit; color: inherit; cursor: pointer; background: var(--panel-2); border: 1px solid var(--line); border-left: 3px solid var(--warn); border-radius: 10px; padding: 10px 12px; display: grid; gap: 4px; }
.need:hover { border-color: var(--line-2); border-left-color: var(--warn); }
.need-top { display: flex; align-items: center; gap: 8px; } .ml { margin-left: auto; }
.need-why { color: var(--warn); font-size: 12.5px; } .need-body { color: var(--text-2); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.tag.ch-wa { border-color: rgba(103,255,184,.45); color: var(--mint); } .tag.ch-mail { border-color: rgba(0,217,255,.4); color: var(--cyan); }
.tag.need-tag { border-color: rgba(255,181,71,.55); color: var(--warn); }
.acts { display: grid; gap: 2px; max-height: 420px; overflow-y: auto; }
.act { display: flex; align-items: center; gap: 12px; padding: 7px 4px; border-bottom: 1px solid rgba(24,38,58,.6); font-size: 13px; }
.act > i { width: 8px; height: 8px; border-radius: 50%; flex: none; background: var(--cyan); }
.act.t-lime > i { background: var(--lime); } .act.t-teal > i { background: var(--teal); } .act.t-warn > i { background: var(--warn); } .act.t-violet > i { background: var(--paused); }
.funnel { display: grid; gap: 10px; }
.fstep { display: grid; grid-template-columns: 110px 1fr; grid-template-areas: "h t" ". c"; column-gap: 12px; align-items: center; }
.fhead { grid-area: h; display: flex; justify-content: space-between; gap: 8px; font-size: 13px; } .ftrack { grid-area: t; height: 10px; background: var(--bg); border-radius: 99px; overflow: hidden; border: 1px solid var(--line); }
.ftrack i { display: block; height: 100%; background: linear-gradient(90deg, var(--cyan), var(--lime)); border-radius: 99px; }
.fconv { grid-area: c; font-size: 11px; color: var(--text-3); }
.syslist { display: grid; gap: 4px; }
.sys { display: flex; align-items: center; gap: 12px; padding: 8px 4px; border-bottom: 1px solid rgba(24,38,58,.6); }
.sys > div { min-width: 0; } .sys .dim { overflow-wrap: anywhere; }
/* pipeline board */
input.pl-search { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 6px 10px; min-width: 220px; }
.pl-sum { display: flex; gap: 18px; flex-wrap: wrap; align-items: baseline; margin-bottom: 14px; font-size: 13px; color: var(--text-2); } .pl-sum b { color: var(--text); font-size: 18px; }
.board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(196px, 1fr); gap: 12px; overflow-x: auto; padding-bottom: 12px; align-items: start; }
.pcol { background: rgba(8,14,24,.7); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px; display: flex; flex-direction: column; gap: 10px; min-height: 260px; }
.pcol.manual { border-style: dashed; } .pcol.over { border-color: var(--lime); background: rgba(182,255,78,.05); }
.pcol-head { display: grid; grid-template-columns: auto 1fr auto; gap: 2px 8px; align-items: center; padding: 2px 4px 6px; border-bottom: 1px solid var(--line); }
.pcol-head i { width: 9px; height: 9px; border-radius: 3px; } .pcol-head .small { grid-column: 1 / -1; }
.pcol-list { display: grid; gap: 8px; max-height: calc(100vh - 290px); overflow-y: auto; padding-right: 2px; }
.pcol-empty { font-size: 12px; color: var(--text-3); text-align: center; padding: 24px 6px; border: 1px dashed var(--line); border-radius: 8px; }
.pcard { background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px; padding: 10px 11px; cursor: pointer; display: grid; gap: 5px; transition: border-color .15s, transform .15s; }
.pcard:hover { border-color: var(--line-2); transform: translateY(-1px); } .pcard.drag { opacity: .45; }
.pc-top { display: flex; gap: 8px; align-items: flex-start; } .pc-top b { font-size: 13px; line-height: 1.3; overflow-wrap: anywhere; }
.pc-score { margin-left: auto; font-size: 11px; padding: 1px 6px; border-radius: 6px; background: rgba(182,255,78,.1); color: var(--lime); }
.pc-dom { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .pc-tags { display: flex; gap: 4px; flex-wrap: wrap; } .pc-tags:empty { display: none; }
.pc-foot { display: flex; align-items: center; gap: 6px; } .pc-foot > span { white-space: nowrap; }
.pl-move { margin-left: auto; background: var(--bg); border: 1px solid var(--line); border-radius: 6px; font-size: 11.5px; padding: 2px 4px; color: var(--text-2); max-width: 104px; width: auto; }
/* reports + settings */
.dlist { display: grid; gap: 8px; } .dl { border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; background: var(--panel-2); }
.dl summary { cursor: pointer; display: flex; gap: 8px; align-items: center; } .dl[open] summary { margin-bottom: 8px; }
.alert-opts { display: grid; gap: 10px; } .alert-opt span { display: grid; gap: 1px; }
.alert-opt input { margin-top: 3px; accent-color: var(--lime); }
@media (max-width: 1280px) { .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 1000px) { .home-a, .home-b { grid-template-columns: 1fr; } }
@media (max-width: 620px) { .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } .kpi-value { font-size: 24px; } .fstep { grid-template-columns: 90px 1fr; } .pl-search { min-width: 0; width: 100%; }
  .board { grid-auto-columns: 82%; scroll-snap-type: x mandatory; } .pcol { scroll-snap-align: start; } .pcol-list { max-height: none; } }
@media print { .kpis { grid-template-columns: repeat(3, 1fr); } .board { grid-auto-flow: row; } }
.top-title { color: var(--text-3); font-size: 12.5px; font-family: var(--mono); }
.panel-head .right .btn { white-space: nowrap; }

/* ---------- AI Agency OS ---------- */
.nav .navgroup { font-size: 10.5px; text-transform: uppercase; letter-spacing: .09em; color: var(--text-3); padding: 14px 10px 4px; font-weight: 600; }
.nav .navgroup:first-child { padding-top: 4px; }
.avatar { --dc: var(--cyan); width: 36px; height: 36px; border-radius: 50%; display: inline-grid; place-items: center; flex: none; font-weight: 700; font-size: 13px; color: var(--bg);
  background: radial-gradient(circle at 30% 25%, #fff6 0 18%, transparent 19%), var(--dc); box-shadow: 0 0 0 2px var(--bg), 0 0 0 3px var(--dc); }
.avatar.lg { width: 48px; height: 48px; font-size: 16px; } .avatar.xl { width: 72px; height: 72px; font-size: 24px; }
.floor { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 8px; }
.desk { display: flex; gap: 10px; align-items: center; padding: 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); color: inherit; text-decoration: none; min-width: 0; }
a.desk:hover { border-color: var(--line-2); text-decoration: none; } .desk > div { min-width: 0; flex: 1; } .desk .iconbtn { margin-left: auto; }
.busy { color: var(--lime); } .idle { color: var(--text-3); }
.desk .small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.clist { display: grid; gap: 6px; }
.crow { display: grid; grid-template-columns: minmax(0, 1.4fr) auto minmax(110px, .8fr) auto; gap: 12px; align-items: center; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; color: inherit; text-decoration: none; background: var(--panel-2); }
.crow:hover { border-color: var(--line-2); text-decoration: none; } .crow .tag { margin-left: 6px; }
.cbud { display: grid; gap: 4px; min-width: 110px; }
.htag { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; white-space: nowrap; } .htag i { width: 8px; height: 8px; border-radius: 50%; background: var(--text-3); }
.htag.ok i { background: var(--mint); } .htag.warn i { background: var(--warn); } .htag.bad i { background: var(--crit); }
.plans { display: grid; gap: 10px; }
.plan { display: flex; gap: 14px; align-items: center; justify-content: space-between; flex-wrap: wrap; padding: 12px 14px; border: 1px solid rgba(182,255,78,.35); border-radius: 10px; background: rgba(182,255,78,.05); }
.plan > div:first-child { min-width: 0; flex: 1 1 320px; }
.crumbs { font-size: 12.5px; color: var(--text-3); margin-bottom: 6px; } .crumbs a { color: var(--text-2); }
.tabs { display: flex; gap: 4px; overflow-x: auto; border-bottom: 1px solid var(--line); margin: 0 0 16px; scrollbar-width: none; }
.tabs a { padding: 9px 12px; color: var(--text-2); text-decoration: none; border-bottom: 2px solid transparent; white-space: nowrap; display: inline-flex; gap: 6px; align-items: center; }
.tabs a.on { color: var(--text); border-bottom-color: var(--lime); } .tabs a:hover { color: var(--text); text-decoration: none; }
.scores { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.sc { border: 1px solid var(--line); border-radius: 10px; padding: 12px; text-align: center; background: var(--panel-2); }
.sc b { display: block; font-size: 30px; font-weight: 680; } .sc span { font-size: 12px; color: var(--text-2); }
.sc.good b { color: var(--lime); } .sc.fair b { color: var(--warn); } .sc.weak b { color: var(--crit); }
dl.kv { display: grid; grid-template-columns: 110px 1fr; gap: 6px 12px; margin: 0; font-size: 13px; } dl.kv dt { color: var(--text-3); } dl.kv dd { margin: 0; overflow-wrap: anywhere; }
.kv2 { display: grid; gap: 8px; } .kv2 b { font-size: 20px; }
.steps { margin: 0; padding-left: 20px; display: grid; gap: 6px; color: var(--text-2); }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin: 6px 0; }
.issues { list-style: none; margin: 8px 0; padding: 0; display: grid; gap: 6px; font-size: 13px; }
.issues li { padding: 6px 10px; border-radius: 8px; background: var(--panel-2); border-left: 3px solid var(--text-3); }
.issues li.sev-high { border-left-color: var(--crit); } .issues li.sev-medium { border-left-color: var(--warn); } .issues li.sev-low { border-left-color: var(--cyan); }
.sub2 { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); display: grid; gap: 6px; }
.wpform { display: flex; gap: 8px; flex-wrap: wrap; } .wpform input { flex: 1 1 180px; min-width: 0; }
.tag.ts-awaiting_approval, .tag.ts-proposed { border-color: rgba(255,181,71,.55); color: var(--warn); }
.tag.ts-done { border-color: rgba(103,255,184,.45); color: var(--mint); } .tag.ts-in_progress, .tag.ts-qa, .tag.ts-approved { border-color: rgba(0,217,255,.45); color: var(--cyan); }
.tag.ts-failed, .tag.ts-rejected, .tag.ts-returned, .tag.ts-blocked { border-color: rgba(255,77,106,.5); color: var(--crit); }
.tag.lv { font-family: var(--mono); } .tag.lv5, .tag.lv4 { border-color: rgba(255,181,71,.5); color: var(--warn); } .tag.lv6 { border-color: rgba(255,77,106,.6); color: var(--crit); }
.emps { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 10px; }
.emp { display: flex; gap: 12px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel-2); color: inherit; text-decoration: none; }
.emp:hover { border-color: var(--line-2); text-decoration: none; transform: translateY(-1px); } .emp > div { min-width: 0; }
.panel-head h2 .dot, i.dot { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 8px; background: var(--cyan); }
.profile { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; margin-bottom: 16px; } .profile h1 { margin: 0; } .profile .actions { margin-left: auto; }
.depts { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 14px; } .dept .floor { grid-template-columns: 1fr; margin-top: 10px; }
.taskbox { display: grid; gap: 10px; } .taskbox h3 { margin: 6px 0 0; font-size: 13px; color: var(--text-2); } .taskbox .actions { justify-content: flex-start; flex-wrap: wrap; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.svc { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 6px; }
.form textarea, .form select { width: 100%; }
a.kpi { text-decoration: none; color: inherit; } a.kpi:hover { border-color: var(--line-2); }
@media (max-width: 860px) { .nav .navgroup { display: none; } .scores { grid-template-columns: repeat(3, minmax(0, 1fr)); } .crow { grid-template-columns: 1fr auto; } .crow .cbud, .crow > :last-child { display: none; } }
@media (max-width: 620px) { .grid2 { grid-template-columns: 1fr; } .scores { grid-template-columns: repeat(2, minmax(0, 1fr)); } .depts { grid-template-columns: 1fr; } }
/* plan review */
.review .rv-sum{padding:12px 14px;border:1px solid var(--line,#1f2a33);border-radius:10px;margin-bottom:10px}
.review .rv-sum p{margin:6px 0 10px;line-height:1.5}
.review .rv-list{display:flex;flex-direction:column;gap:8px;max-height:56vh;overflow:auto;padding-right:4px}
.review .rv-task{border:1px solid var(--line,#1f2a33);border-radius:10px;padding:10px 12px}
.review .rv-top{display:flex;justify-content:space-between;gap:8px;align-items:flex-start;flex-wrap:wrap}
.review .rv-task p{margin:6px 0}
.review .rv-ctl{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin-top:6px}
.review .rv-ctl select{width:auto;max-width:100%}
.review .actions{margin-top:12px;justify-content:flex-end}
/* keyword tracker */
.kw-head{justify-content:space-between;margin-bottom:10px}
.tag.pos.good{color:#0b1;border-color:#2b6}.tag.pos.near{color:#B6FF4E;border-color:#B6FF4E}.tag.pos.mid{color:#FFB547;border-color:#FFB547}
.move.up{color:#67FFB8;font-weight:600}.move.down{color:#FF7A45;font-weight:600}
.tag.small{font-size:10px;padding:1px 6px;margin-left:6px}
ol.ideas{columns:2;column-gap:28px;margin:0;padding-left:20px}ol.ideas li{margin:0 0 6px;break-inside:avoid}
@media(max-width:700px){ol.ideas{columns:1}}
/* search team */
pre.answer{white-space:pre-wrap;font:inherit;font-size:13px;line-height:1.55;max-height:60vh;overflow:auto;margin:0}
ul.kpi-list li,ul.routine li{margin:2px 0}
.swatches{display:flex;gap:6px;align-items:center;flex-wrap:wrap;margin:8px 0}.swatch{width:22px;height:22px;border-radius:6px;border:1px solid var(--line)}
/* agent runtime: proposed changes */
.changes{margin:14px 0}.change{border:1px solid var(--line);border-radius:10px;padding:10px 12px;margin:8px 0;display:grid;gap:6px}
.change-head{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.diff{display:grid;grid-template-columns:140px 1fr 1fr;gap:8px;align-items:start;font-size:13px}.diff-b{text-decoration:line-through;opacity:.6}.diff-a{font-weight:600}
.note.working{display:flex;gap:6px;align-items:center}.note.bad,.small.bad{color:var(--crit)}
@media (max-width:640px){.diff{grid-template-columns:1fr}}
.academy{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:10px;margin-top:10px}.acad{border:1px solid var(--line);border-radius:10px;padding:10px 12px}.acad-head{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.acad ul{margin:6px 0;padding-left:16px}.acad li{margin:3px 0}
.onb{list-style:none;padding:0;margin:8px 0;display:grid;gap:6px}.onb li{display:flex;gap:10px;align-items:flex-start}.onb-i{width:20px;text-align:center;font-weight:700}.onb li.ok .onb-i{color:var(--lime)}.onb li.skip{opacity:.55}.onb li.todo .onb-i{color:var(--warn)}
