.demo-hero {
  max-width: 860px;
  margin: 0 auto;
  padding: 9rem 2.5rem 3rem;
}

.demo-body {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 2.5rem 5rem;
}

.input-panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.75rem;
  margin-bottom: 2rem;
  transition: opacity 0.2s;
}

.input-panel.locked { opacity: 0.5; pointer-events: none; }

.input-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
  font-family: var(--mono);
}

textarea {
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.6;
  padding: 0.875rem 1rem;
  resize: none;
  outline: none;
  transition: border-color 0.15s;
}

textarea:focus { border-color: var(--accent); }
textarea::placeholder { color: var(--text-dim); }

.input-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 1rem;
  gap: 1rem;
}

.input-hint {
  font-size: 12px;
  color: var(--text-dim);
}

button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 14px;
  font-weight: 500;
  font-family: var(--font);
  padding: 0.6rem 1.4rem;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: opacity 0.15s;
  white-space: nowrap;
}

button:hover { opacity: 0.85; }
button:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border);
  padding: 0.5rem 1rem;
}

.btn-ghost:hover { color: var(--text); background: rgba(255,255,255,0.04); opacity: 1; }

.spinner {
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

.hidden { display: none !important; }

@keyframes spin { to { transform: rotate(360deg); } }

.pipeline-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 12px;
  font-family: var(--mono);
  color: var(--text-dim);
  margin-bottom: 1rem;
}

.pipeline-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.agents-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 1rem;
}

.agent-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.25rem;
  transition: border-color 0.3s;
}

.agent-card.done { border-color: rgba(124,111,255,0.3); }

.agent-header {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.agent-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 600;
  flex-shrink: 0;
}

.agent-icon.skeptic  { background: rgba(239,68,68,0.15); color: #f87171; }
.agent-icon.advocate { background: rgba(52,211,153,0.15); color: #34d399; }
.agent-icon.pragmatist { background: rgba(251,191,36,0.15); color: #fbbf24; }
.agent-icon.synthesis { background: var(--accent-dim); color: var(--accent); font-size: 16px; }

.agent-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 2px;
}

.agent-role {
  font-size: 11px;
  color: var(--text-dim);
  font-family: var(--mono);
}

.agent-status { margin-left: auto; }

.dot-pulse {
  display: block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-dim);
  animation: pulse 1s ease-in-out infinite;
}

.done-dot {
  display: block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
}

.agent-body {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.65;
  min-height: 60px;
}

.synthesis-card {
  background: var(--bg-card-featured);
  border: 1px solid rgba(124,111,255,0.25);
  border-radius: 10px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.synthesis-header {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.synthesis-body {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.75;
}

.reset-row {
  display: flex;
  justify-content: flex-start;
}

.nav-badge {
  font-size: 11px;
  font-family: var(--mono);
  color: var(--accent);
  background: var(--accent-dim);
  padding: 0.25rem 0.75rem;
  border-radius: 4px;
  letter-spacing: 0.04em;
}

@media (max-width: 768px) {
  .demo-hero { padding: 8rem 1.25rem 2rem; }
  .demo-body { padding: 0 1.25rem 4rem; }
  .agents-grid { grid-template-columns: 1fr; }
  .input-meta { flex-direction: column; align-items: flex-start; }
}

/* ===== shared form inputs (text + select) ===== */
input[type="text"], select {
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-family: var(--font);
  font-size: 15px;
  padding: 0.7rem 0.9rem;
  outline: none;
  transition: border-color 0.15s;
}
input[type="text"]:focus, select:focus { border-color: var(--accent); }
input[type="text"]::placeholder { color: var(--text-dim); }
select { cursor: pointer; appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'><path d='M2 4l4 4 4-4' stroke='%237a7a8a' stroke-width='1.5' fill='none' stroke-linecap='round'/></svg>");
  background-repeat: no-repeat; background-position: right 0.9rem center; padding-right: 2.2rem; }
.opt { color: var(--text-dim); font-weight: 400; }

/* ===== thought partner: advisor picker ===== */
.advisor-picker { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.advisor-chip {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: rgba(255,255,255,0.03); color: var(--text-muted);
  border: 1px solid var(--border); border-radius: 8px;
  padding: 0.5rem 0.85rem; font-size: 13px; font-weight: 500;
  cursor: pointer; transition: all 0.15s; opacity: 0.55;
}
.advisor-chip:hover { opacity: 0.85; }
.advisor-chip.active { opacity: 1; background: rgba(255,255,255,0.06); border-color: var(--border-hover); color: var(--text); }
.chip-mark {
  width: 20px; height: 20px; border-radius: 5px; display: inline-flex;
  align-items: center; justify-content: center; font-size: 11px; font-weight: 600; font-family: var(--mono);
}
.chip-mark.v, .agent-icon.adv-v { background: rgba(124,111,255,0.15); color: #a39bff; }
.chip-mark.o, .agent-icon.adv-o { background: rgba(52,211,153,0.15); color: #34d399; }
.chip-mark.c, .agent-icon.adv-c { background: rgba(239,68,68,0.15); color: #f87171; }
.chip-mark.f, .agent-icon.adv-f { background: rgba(251,191,36,0.15); color: #fbbf24; }
.chip-mark.u, .agent-icon.adv-u { background: rgba(56,189,248,0.15); color: #38bdf8; }

/* ===== comms expert ===== */
.comms-controls { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 1.25rem; }
.control-col { display: flex; flex-direction: column; }
.comms-result-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1.5rem; }
.comms-col { display: flex; flex-direction: column; gap: 0.6rem; }
.comms-col-label { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-dim); }
.comms-col-label.accent { color: var(--accent); }
.comms-text {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px;
  padding: 1rem 1.15rem; font-size: 14px; line-height: 1.65; color: var(--text-muted); white-space: pre-wrap;
}
.comms-text.rewrite { background: var(--bg-card-featured); border-color: rgba(124,111,255,0.25); color: var(--text); }

.scores-block { margin-bottom: 1.5rem; }
.scores-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem 2rem; margin-top: 0.85rem; }
.score-row { display: flex; flex-direction: column; gap: 0.4rem; }
.score-head { display: flex; align-items: baseline; justify-content: space-between; }
.score-label { font-size: 13px; color: var(--text); font-weight: 500; }
.score-nums { font-family: var(--mono); font-size: 12px; }
.num-before { color: var(--text-dim); }
.num-arrow { color: var(--text-dim); }
.num-after { color: var(--green); font-weight: 500; }
.score-track { display: flex; flex-direction: column; gap: 4px; }
.score-fill { height: 5px; border-radius: 3px; transition: width 0.9s cubic-bezier(0.22,1,0.36,1); }
.score-fill.before { background: var(--text-dim); }
.score-fill.after { background: var(--accent); }

.changes-reaction { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1.5rem; }
.changes-card, .reaction-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 1.15rem; }
.changes-list { list-style: none; margin: 0.75rem 0 0; padding: 0; display: flex; flex-direction: column; gap: 0.6rem; }
.changes-list li { font-size: 13px; color: var(--text-muted); line-height: 1.55; padding-left: 1.1rem; position: relative; }
.changes-list li::before { content: "→"; position: absolute; left: 0; color: var(--accent); }
.reaction-text { font-size: 13px; color: var(--text-muted); line-height: 1.65; margin-top: 0.75rem; }

/* ===== meeting prep ===== */
.brief-header { border-left: 2px solid var(--accent); padding-left: 1rem; margin-bottom: 1.5rem; }
.brief-title { font-size: 13px; font-family: var(--mono); color: var(--text-muted); margin-bottom: 0.5rem; }
.brief-objective { font-size: 1.15rem; font-weight: 500; color: var(--text); line-height: 1.5; }
.brief-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1rem; }
.brief-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 1.25rem; }
.brief-card.full { margin-bottom: 1rem; }
.brief-card-label { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-dim); margin-bottom: 0.9rem; display: flex; align-items: center; gap: 0.5rem; }
.bi { color: var(--accent); font-size: 9px; }
.brief-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 0.65rem; counter-reset: pt; }
.brief-list li { font-size: 14px; color: var(--text-muted); line-height: 1.55; padding-left: 1.4rem; position: relative; }
.brief-list:not(.ordered) li::before { content: "◆"; position: absolute; left: 0; color: var(--accent); font-size: 8px; top: 5px; }
.brief-list.ordered li { counter-increment: pt; }
.brief-list.ordered li::before { content: counter(pt); position: absolute; left: 0; top: 0; color: var(--accent); font-family: var(--mono); font-size: 12px; font-weight: 500; }

.objections { display: flex; flex-direction: column; gap: 0.6rem; }
.objection-item { border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
.objection-q {
  width: 100%; background: rgba(255,255,255,0.02); border: none; border-radius: 0;
  display: flex; align-items: center; gap: 0.75rem; text-align: left;
  padding: 0.85rem 1rem; font-size: 14px; font-weight: 400; color: var(--text); cursor: pointer;
}
.objection-q:hover { background: rgba(255,255,255,0.05); opacity: 1; }
.objection-q > span:nth-child(2) { flex: 1; }
.obj-icon { width: 20px; height: 20px; border-radius: 5px; background: rgba(251,191,36,0.15); color: #fbbf24; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 600; flex-shrink: 0; }
.obj-chevron { font-family: var(--mono); color: var(--text-dim); font-size: 16px; }
.objection-a { max-height: 0; overflow: hidden; font-size: 13px; color: var(--text-muted); line-height: 1.6; padding: 0 1rem; transition: max-height 0.3s ease, padding 0.3s ease; }
.objection-a.open { max-height: 300px; padding: 0 1rem 0.95rem 2.75rem; }

.brief-quote { font-size: 14px; color: var(--text); line-height: 1.6; font-style: italic; }
.brief-outcome { font-size: 14px; color: var(--text-muted); line-height: 1.6; }

@media (max-width: 768px) {
  .comms-controls, .comms-result-grid, .scores-grid, .changes-reaction, .brief-grid { grid-template-columns: 1fr; }
}

/* ============ shared: typing dots, toolbar, presence ============ */
.typing { display: inline-flex; gap: 4px; align-items: center; min-height: 18px; }
.typing span { width: 6px; height: 6px; border-radius: 50%; background: var(--text-dim); animation: blink 1.2s infinite; }
.typing span:nth-child(2){ animation-delay: 0.2s; } .typing span:nth-child(3){ animation-delay: 0.4s; }
@keyframes blink { 0%,60%,100%{ opacity:0.25; } 30%{ opacity:1; } }
.toolbar-btns { display: flex; gap: 0.75rem; align-items: center; }
.presence-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--green); }
.presence-dot.busy { background: #fbbf24; }
.sidebar-note { font-size: 12px; color: var(--text-dim); line-height: 1.55; margin-top: 1rem; }

/* ============ voice caller ============ */
.phone-stage { display: grid; grid-template-columns: 1fr 260px; gap: 1.25rem; }
.phone-frame { background: var(--bg-card); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; display: flex; flex-direction: column; min-height: 460px; }
.phone-status-bar { display: flex; justify-content: space-between; align-items: center; padding: 0.85rem 1.1rem; border-bottom: 1px solid var(--border); background: var(--bg-card-featured); }
.phone-brand { font-size: 13px; font-weight: 500; color: var(--text); }
.call-timer { font-family: var(--mono); font-size: 13px; color: var(--text-muted); }
.call-transcript { flex: 1; padding: 1.25rem; overflow-y: auto; display: flex; flex-direction: column; gap: 0.75rem; max-height: 420px; }
.call-hint { margin: auto; text-align: center; color: var(--text-dim); max-width: 320px; }
.call-hint p { font-size: 13px; line-height: 1.6; margin-top: 0.5rem; }
.hint-sub { font-size: 12px !important; color: var(--text-dim); }
.hint-ring { width: 56px; height: 56px; border-radius: 50%; border: 2px solid var(--border-hover); display: flex; align-items: center; justify-content: center; margin: 0 auto 1rem; font-size: 22px; color: var(--text-muted); }
.bubble { max-width: 78%; padding: 0.7rem 0.95rem; border-radius: 12px; font-size: 14px; line-height: 1.5; }
.bubble.agent { align-self: flex-start; background: var(--bg-card-featured); border: 1px solid var(--border); color: var(--text); border-bottom-left-radius: 4px; }
.bubble.caller { align-self: flex-end; background: var(--accent); color: #fff; border-bottom-right-radius: 4px; }
.call-controls { padding: 1rem 1.1rem; border-top: 1px solid var(--border); }
.call-start { width: 100%; justify-content: center; background: var(--green); }
.live-controls { display: flex; gap: 0.5rem; align-items: center; }
.mic-btn { background: var(--bg-card-featured); border: 1px solid var(--border-hover); width: 42px; height: 42px; border-radius: 50%; justify-content: center; padding: 0; font-size: 18px; flex-shrink: 0; }
.mic-btn.recording { background: rgba(239,68,68,0.2); border-color: #f87171; animation: pulse 1s infinite; }
.text-input { flex: 1; }
.send-btn { flex-shrink: 0; }
.end-btn { background: rgba(239,68,68,0.15); color: #f87171; flex-shrink: 0; }
.call-sidebar { background: var(--bg-card); border: 1px solid var(--border); border-radius: 14px; padding: 1.25rem; align-self: start; }
.sidebar-label { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-dim); margin-bottom: 1rem; }
.read-card { display: flex; flex-direction: column; gap: 0.85rem; }
.read-row { display: flex; flex-direction: column; gap: 2px; }
.read-k { font-size: 11px; color: var(--text-dim); font-family: var(--mono); }
.read-v { font-size: 14px; color: var(--text); font-weight: 500; }
.read-v.route-human { color: #fbbf24; } .read-v.route-ai { color: var(--green); }

/* ============ teams bot ============ */
.chat-shell { max-width: 640px; margin: 0 auto; background: var(--bg-card); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; }
.chat-head { display: flex; align-items: center; gap: 0.75rem; padding: 1rem 1.25rem; border-bottom: 1px solid var(--border); background: var(--bg-card-featured); }
.bot-avatar { width: 36px; height: 36px; border-radius: 9px; background: var(--accent-dim); color: var(--accent); display: flex; align-items: center; justify-content: center; font-size: 15px; }
.bot-name { font-size: 14px; font-weight: 500; color: var(--text); }
.bot-presence { font-size: 12px; color: var(--text-muted); display: flex; align-items: center; gap: 5px; }
.chat-log { padding: 1.25rem; display: flex; flex-direction: column; gap: 0.85rem; max-height: 440px; overflow-y: auto; }
.chat-msg { display: flex; }
.chat-msg.user { justify-content: flex-end; }
.msg-text { max-width: 80%; padding: 0.7rem 0.95rem; border-radius: 12px; font-size: 14px; line-height: 1.55; }
.chat-msg.bot .msg-text { background: var(--bg-card-featured); border: 1px solid var(--border); color: var(--text); border-bottom-left-radius: 4px; }
.chat-msg.user .msg-text { background: var(--accent); color: #fff; border-bottom-right-radius: 4px; }
.tool-step { background: rgba(124,111,255,0.06); border: 1px solid rgba(124,111,255,0.2); border-radius: 10px; padding: 0.7rem 0.9rem; font-size: 13px; }
.tool-head { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem; color: var(--text-muted); font-family: var(--mono); font-size: 12px; }
.tool-spark { color: var(--accent); }
.tool-args { color: var(--text-dim); }
.tool-result { display: grid; grid-template-columns: auto 1fr; gap: 3px 12px; margin-top: 0.6rem; padding-top: 0.6rem; border-top: 1px solid rgba(124,111,255,0.15); }
.tool-result.err { display: block; color: #fbbf24; margin-top: 0.5rem; }
.tr-k { font-family: var(--mono); font-size: 11px; color: var(--text-dim); text-transform: capitalize; }
.tr-v { font-size: 13px; color: var(--text); }
.chat-suggestions { display: flex; flex-wrap: wrap; gap: 0.5rem; padding: 0 1.25rem 0.5rem; }
.chat-suggestions button { background: var(--bg-card-featured); border: 1px solid var(--border); color: var(--text-muted); font-size: 12px; font-weight: 400; padding: 0.4rem 0.75rem; border-radius: 16px; }
.chat-suggestions button:hover { color: var(--text); border-color: var(--border-hover); opacity: 1; }
.chat-input-row { display: flex; gap: 0.5rem; padding: 1rem 1.25rem; border-top: 1px solid var(--border); }
.chat-input-row input { flex: 1; }

/* ============ inbox roundup ============ */
.inbox-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.25rem; }
.inbox-list { display: flex; flex-direction: column; gap: 0.75rem; }
.email-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 0.9rem 1rem; display: flex; flex-direction: column; gap: 0.5rem; }
.email-meta { display: flex; gap: 0.5rem; align-items: center; }
.email-from { flex: 1; font-weight: 500; font-size: 13px !important; padding: 0.4rem 0.6rem !important; }
.email-del { background: transparent; border: 1px solid var(--border); color: var(--text-dim); width: 28px; height: 28px; border-radius: 6px; padding: 0; justify-content: center; font-size: 16px; flex-shrink: 0; }
.email-subject { font-size: 13px !important; padding: 0.4rem 0.6rem !important; }
.email-body { font-size: 13px; line-height: 1.5; }
.triage-summary { font-size: 14px; color: var(--text-muted); margin-bottom: 1.25rem; }
.pill { display: inline-block; font-size: 11px; font-weight: 500; font-family: var(--mono); padding: 0.15rem 0.55rem; border-radius: 5px; }
.pill.p-high { background: rgba(239,68,68,0.15); color: #f87171; }
.pill.p-med { background: rgba(251,191,36,0.15); color: #fbbf24; }
.pill.p-low { background: rgba(122,122,138,0.15); color: var(--text-muted); }
.triage-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 1.1rem 1.25rem; margin-bottom: 0.75rem; }
.triage-top { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.6rem; }
.triage-cat { font-size: 12px; font-family: var(--mono); color: var(--text-dim); }
.triage-subject { font-size: 15px; font-weight: 500; color: var(--text); margin-bottom: 0.35rem; }
.triage-sum { font-size: 13px; color: var(--text-muted); line-height: 1.5; margin-bottom: 0.75rem; }
.draft-toggle { background: transparent; border: none; color: var(--accent); font-size: 13px; padding: 0; gap: 0.4rem; }
.draft-toggle:hover { opacity: 0.8; }
.draft-body { max-height: 0; overflow: hidden; font-size: 13px; line-height: 1.6; color: var(--text-muted); white-space: pre-wrap; transition: max-height 0.3s ease, margin 0.3s ease; }
.draft-body.open { max-height: 400px; margin-top: 0.75rem; padding: 0.9rem; background: var(--bg-card-featured); border: 1px solid var(--border); border-radius: 8px; }

/* ============ service dashboard ============ */
.dash-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.25rem; }
.live-pill { display: inline-flex; align-items: center; gap: 0.5rem; font-family: var(--mono); font-size: 12px; color: var(--text-muted); }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: #f87171; animation: pulse 1.4s infinite; }
.metric-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-bottom: 1.5rem; }
.metric-tile { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 1.1rem 1.25rem; transition: border-color 0.3s, background 0.3s; }
.metric-tile.warn { border-color: rgba(239,68,68,0.4); background: rgba(239,68,68,0.05); }
.metric-label { font-size: 12px; color: var(--text-dim); font-family: var(--mono); margin-bottom: 0.5rem; }
.metric-value { font-size: 1.8rem; font-weight: 600; color: var(--text); letter-spacing: -0.02em; }
.metric-tile.warn .metric-value { color: #f87171; }
.analysis-card { background: var(--bg-card-featured); border: 1px solid rgba(124,111,255,0.25); border-radius: 12px; padding: 1.5rem; }
.analysis-head { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 1rem; }
.status-chip { margin-left: auto; font-family: var(--mono); font-size: 12px; padding: 0.25rem 0.7rem; border-radius: 6px; }
.status-chip.s-ok { background: var(--green-dim); color: var(--green); }
.status-chip.s-watch { background: rgba(251,191,36,0.15); color: #fbbf24; }
.status-chip.s-crit { background: rgba(239,68,68,0.15); color: #f87171; }
.analysis-headline { font-size: 1.05rem; color: var(--text); line-height: 1.5; margin-bottom: 1.25rem; }
.analysis-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }

/* ============ salesforce softphone ============ */
.sf-stage { display: grid; grid-template-columns: 1fr 240px; gap: 1.25rem; }
.sf-window { background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.sf-header { display: flex; align-items: center; gap: 0.75rem; padding: 0.75rem 1rem; background: #1a4d8f; color: #fff; font-size: 13px; font-weight: 500; }
.sf-cloud { font-size: 15px; }
.sf-tab { font-size: 12px; padding: 0.25rem 0.7rem; border-radius: 5px; color: rgba(255,255,255,0.7); }
.sf-tab.active { background: rgba(255,255,255,0.15); color: #fff; }
.sf-body { display: grid; grid-template-columns: 1fr 280px; gap: 1px; background: var(--border); min-height: 380px; }
.sf-record { background: var(--bg-card); padding: 1.5rem; }
.sf-record-empty { color: var(--text-dim); text-align: center; margin-top: 3rem; }
.rec-ico { font-size: 32px; display: block; margin-bottom: 0.75rem; }
.sf-record-empty p { font-size: 13px; line-height: 1.6; max-width: 280px; margin: 0 auto; }
.rec-head { display: flex; align-items: center; gap: 0.85rem; margin-bottom: 1.25rem; }
.rec-avatar { width: 48px; height: 48px; border-radius: 50%; background: var(--accent-dim); color: var(--accent); display: flex; align-items: center; justify-content: center; font-weight: 600; }
.rec-name { font-size: 16px; font-weight: 600; color: var(--text); }
.rec-sub { font-size: 12px; color: var(--text-muted); font-family: var(--mono); }
.rec-pop { margin-left: auto; font-size: 11px; font-family: var(--mono); color: var(--accent); background: var(--accent-dim); padding: 0.2rem 0.6rem; border-radius: 5px; animation: pulse 1.5s 2; }
.rec-fields { display: flex; flex-direction: column; gap: 0.7rem; }
.rec-field { display: flex; justify-content: space-between; font-size: 13px; padding-bottom: 0.7rem; border-bottom: 1px solid var(--border); }
.rec-field span:first-child { color: var(--text-dim); }
.rec-field span:last-child { color: var(--text); font-weight: 500; }
.softphone { background: var(--bg-card-featured); padding: 1.25rem; display: flex; flex-direction: column; }
.sp-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.25rem; }
.sp-title { font-size: 13px; font-weight: 500; color: var(--text); }
.sp-presence { font-size: 11px; color: var(--text-muted); display: flex; align-items: center; gap: 5px; }
.sp-state { font-family: var(--mono); font-size: 12px; color: var(--text-dim); text-align: center; }
.sp-number { font-size: 18px; color: var(--text); text-align: center; margin: 0.35rem 0; min-height: 24px; font-family: var(--mono); }
.sp-timer { font-family: var(--mono); font-size: 13px; color: var(--green); text-align: center; min-height: 18px; margin-bottom: 0.75rem; }
.dial-input { text-align: center; margin-bottom: 0.75rem; font-family: var(--mono); }
.dial-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem; margin-bottom: 0.85rem; }
.dial-grid button { background: var(--bg-card); border: 1px solid var(--border); color: var(--text); justify-content: center; font-size: 16px; padding: 0.7rem 0; }
.dial-grid button:hover { background: var(--bg-card-featured); border-color: var(--border-hover); opacity: 1; }
.sp-call { width: 100%; justify-content: center; background: var(--green); }
.sp-incoming { text-align: center; padding: 1rem 0; }
.ringing { font-size: 13px; color: var(--text-muted); animation: pulse 1.2s infinite; }
.ring-num { font-family: var(--mono); font-size: 16px; color: var(--text); margin: 0.5rem 0 1rem; }
.ring-actions { display: flex; gap: 0.5rem; }
.ring-accept { flex: 1; justify-content: center; background: var(--green); }
.ring-decline { flex: 1; justify-content: center; background: rgba(239,68,68,0.15); color: #f87171; }
.sp-active { margin-top: auto; }
.active-actions { display: flex; gap: 0.5rem; margin-bottom: 0.75rem; }
.aa { flex: 1; justify-content: center; background: var(--bg-card); border: 1px solid var(--border); color: var(--text-muted); font-size: 12px; padding: 0.5rem 0; }
.aa.on { background: var(--accent-dim); color: var(--accent); border-color: var(--accent); }
.sp-hangup { width: 100%; justify-content: center; background: #e24b4a; }
.sf-controls { align-self: start; }
.sf-controls .btn-ghost { width: 100%; justify-content: center; margin-bottom: 0.5rem; }

/* ============ sync pipeline ============ */
.pipe-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; }
.pipe-stat { font-family: var(--mono); font-size: 13px; color: var(--text-muted); }
.pipe-stat .ok { color: var(--green); } .pipe-stat .err { color: #fbbf24; }
.pipe-stages { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; margin-bottom: 2rem; }
.pipe-stage { flex: 1; background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 1rem; text-align: center; transition: border-color 0.2s, background 0.2s; }
.pipe-stage.active { border-color: var(--accent); background: rgba(124,111,255,0.08); }
.ps-icon { width: 36px; height: 36px; border-radius: 9px; display: flex; align-items: center; justify-content: center; font-size: 15px; font-weight: 600; margin: 0 auto 0.6rem; font-family: var(--mono); }
.ps-icon.src { background: rgba(56,189,248,0.15); color: #38bdf8; }
.ps-icon.val { background: rgba(52,211,153,0.15); color: var(--green); }
.ps-icon.push { background: var(--accent-dim); color: var(--accent); }
.ps-icon.rec { background: rgba(251,191,36,0.15); color: #fbbf24; }
.ps-name { font-size: 13px; font-weight: 500; color: var(--text); }
.ps-sub { font-size: 11px; color: var(--text-dim); font-family: var(--mono); margin-top: 2px; }
.ps-count { font-size: 1.4rem; font-weight: 600; color: var(--text); margin-top: 0.5rem; }
.pipe-arrow { color: var(--text-dim); font-size: 18px; flex-shrink: 0; }
.pipe-feed-wrap { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 1.1rem 1.25rem; }
.pipe-feed { display: flex; flex-direction: column; gap: 0.4rem; margin-top: 0.85rem; max-height: 340px; overflow-y: auto; }
.feed-row { display: grid; grid-template-columns: 90px 1fr 90px 1.4fr; gap: 0.75rem; align-items: center; padding: 0.55rem 0.75rem; border-radius: 7px; background: var(--bg-card-featured); font-size: 13px; animation: rowin 0.25s ease; }
@keyframes rowin { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.fr-id { font-family: var(--mono); font-size: 12px; color: var(--text-dim); }
.fr-name { color: var(--text); }
.fr-region { font-size: 12px; color: var(--text-muted); font-family: var(--mono); }
.fr-status { font-size: 12px; font-family: var(--mono); text-align: right; }
.fr-status.processing { color: var(--text-dim); }
.fr-status.synced { color: var(--green); }
.fr-status.held { color: #fbbf24; }
.feed-row.row-held { border-left: 2px solid #fbbf24; }
.feed-row.row-synced { border-left: 2px solid var(--green); }

@media (max-width: 768px) {
  .phone-stage, .sf-stage, .sf-body, .metric-grid, .analysis-cols { grid-template-columns: 1fr; }
  .metric-grid { grid-template-columns: 1fr 1fr; }
  .pipe-stages { flex-direction: column; }
  .pipe-arrow { transform: rotate(90deg); }
  .feed-row { grid-template-columns: 1fr 1fr; }
}
