/* Product UI mocks — used in the homepage to render parts of the
   actual dashboard inline. Mirrors the dashboard's design tokens so a
   visitor sees the real shapes before they ever install. */

/* ── Studio mock (hero) ────────────────────────────────────────── */

.studio-mock {
  display: grid;
  grid-template-columns: 44px 1fr;
  background: var(--bg);
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 510px;
  box-shadow: var(--shadow-2);
  border: 1px solid var(--border);
}

/* Left vertical strip — matches the dashboard's ambient strip */
.studio-mock-strip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 8px 0;
  background: var(--bg-2);
  border-right: 1px solid var(--border);
}
.studio-mock-mark {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 6px;
}
.studio-mock-mark img {
  width: 28px;
  height: 28px;
  object-fit: contain;
  filter: drop-shadow(0 0 8px rgba(var(--axo-jade-rgb), .42));
}
.studio-mock-tab {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  color: var(--muted);
  font-size: 15px;
  position: relative;
  cursor: default;
  user-select: none;
}
.studio-mock-tab.active {
  color: var(--accent);
  background: rgba(var(--axo-jade-rgb), .14);
}
.studio-mock-tab.active::before {
  content: '';
  position: absolute;
  left: -6px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: var(--accent);
  border-radius: 2px;
}
.studio-mock-spacer { flex: 1; }

/* Shell — sidebar + canvas */
.studio-mock-shell {
  display: grid;
  grid-template-columns: 220px 1fr;
  min-height: 510px;
}

/* Sidebar */
.studio-mock-side {
  background: var(--bg-2);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  padding: 10px 0 14px;
  font-size: 12.5px;
}
.studio-mock-search {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 9px 8px;
  padding: 6px 9px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--muted-2);
  font-size: 11.5px;
  font-family: var(--font-body);
}
.studio-mock-search-icon {
  font-family: var(--font-mono);
  color: var(--muted-2);
  font-size: 12px;
}
.studio-mock-section { padding: 4px 0 2px; }
.studio-mock-section-head {
  padding: 6px 12px 4px;
  font-family: var(--font-display);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: .8px;
  color: var(--muted-2);
}
.studio-mock-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 6px;
  padding: 5px 9px;
  border-radius: 6px;
  color: var(--fg);
  font-size: 12.5px;
  transition: background .2s;
}
.studio-mock-row.run {
  background: rgba(var(--axo-jade-rgb), .14);
  color: var(--accent);
}
.studio-mock-row-name { flex: 1; }
.studio-mock-row-ct {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--muted-2);
}
.studio-mock-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--muted-2);
  flex-shrink: 0;
}
.studio-mock-dot.run {
  background: var(--accent);
  box-shadow: 0 0 8px rgba(var(--axo-jade-rgb), .7);
  animation: studio-mock-pulse 1.6s ease-in-out infinite;
}
.studio-mock-dot.team-eng { background: var(--accent); }
.studio-mock-dot.team-qa  { background: var(--accent-2); }
.studio-mock-dot.team-res { background: var(--accent-2); }

/* Recent events list (sidebar) */
.studio-mock-event {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 6px;
  padding: 5px 9px;
  font-size: 11.5px;
  color: var(--fg-soft);
  border-left: 2px solid var(--accent);
  border-radius: 0 6px 6px 0;
  background: rgba(var(--axo-jade-rgb), .06);
}
.studio-mock-event-time {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--muted-2);
}
.studio-mock-event-text { flex: 1; }

@keyframes studio-mock-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(var(--axo-jade-rgb), .65); }
  50%      { box-shadow: 0 0 0 6px rgba(var(--axo-jade-rgb), 0); }
}

/* Main canvas */
.studio-mock-main {
  display: flex;
  flex-direction: column;
  background: var(--panel);
  min-width: 0;
}

/* Toolbar */
.studio-mock-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--panel-2);
  min-height: 40px;
  font-size: 12px;
}
.studio-mock-mode {
  display: inline-flex;
  gap: 2px;
  padding: 2px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 7px;
}
.studio-mock-mode-btn {
  background: transparent;
  border: 0;
  color: var(--muted);
  padding: 4px 11px;
  border-radius: 5px;
  font-size: 12px;
  font-family: var(--font-display);
  cursor: pointer;
}
.studio-mock-mode-btn.active {
  color: var(--fg);
  background: var(--panel);
  box-shadow: 0 1px 2px rgba(0,0,0,.32);
}
.studio-mock-toolbar-help {
  flex: 1;
  text-align: right;
  color: var(--muted-2);
  font-size: 11px;
  font-family: var(--font-mono);
}
.studio-mock-toolbar-actions {
  display: flex;
  gap: 6px;
}
.studio-mock-toolbar-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--fg);
  font-family: var(--font-display);
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 5px;
  cursor: pointer;
}
.studio-mock-toolbar-btn:hover { background: var(--bg-3); border-color: var(--border-strong); }

/* Canvas — always dark regardless of site theme. The lattice itself
   renders on a dark backdrop, so the canvas needs to match in both
   light and dark mode (just like the dashboard's Studio tab does).
   The lattice is also non-interactive on the hero so visitors can't
   accidentally pan/zoom the demo away. */
.studio-mock-canvas {
  position: relative;
  flex: 1;
  min-height: 430px;
  background: var(--bg-2);
  overflow: hidden;
}
.studio-mock-canvas ax-scripted-lattice,
.studio-mock-canvas ax-lattice {
  position: absolute;
  inset: 0;
  display: block;
}
.studio-mock-canvas ax-lattice { pointer-events: none; }

/* Status pearls — floating, bottom-right */
.studio-mock-pearls {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-end;
  z-index: 2;
}
/* Pearls always render against the dark canvas, so they keep their
   dark-glass styling regardless of site theme. */
.studio-mock-pearl {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 11px;
  background: rgba(13, 16, 21, .86);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  font-size: 11.5px;
  color: var(--fg-soft);
  font-family: var(--font-mono);
}

/* Inspector pane — slides in from the top-right when a node is active.
   Stays dark-glass against the dark canvas. Non-interactive. */
.studio-mock-inspector {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 280px;
  background: rgba(13, 16, 21, .9);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  color: var(--fg);
  font-size: 12px;
  z-index: 3;
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity .25s ease-out, transform .25s ease-out;
  pointer-events: none;
}
.studio-mock-inspector.show {
  opacity: 1;
  transform: translateY(0);
}
.studio-mock-inspector-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 10px 13px;
  border-bottom: 1px solid var(--border);
}
.studio-mock-inspector-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: -.005em;
  color: var(--fg);
}
.studio-mock-inspector-meta {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--muted-2);
  margin-left: auto;
}
.studio-mock-inspector-body {
  padding: 10px 13px 13px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.studio-mock-inspector-section { display: flex; flex-direction: column; gap: 4px; }
.studio-mock-inspector-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .8px;
  color: var(--muted-2);
  font-family: var(--font-display);
  font-weight: 600;
}
.studio-mock-inspector-value {
  font-size: 12px;
  color: var(--fg-soft);
  display: flex;
  align-items: center;
  gap: 6px;
  line-height: 1.4;
}
.studio-mock-inspector-code {
  font-family: var(--font-mono);
  font-size: 11px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 8px 10px;
  margin: 0;
  color: var(--fg-soft);
  line-height: 1.55;
  white-space: pre;
  overflow-x: auto;
}
.studio-mock-inspector-code .diff-add { color: #5fb87c; }
.studio-mock-inspector-code .diff-del { color: #e57373; }

/* Mobile: inspector hides since there's no room. */
@media (max-width: 720px) {
  .studio-mock-inspector { display: none; }
}


/* ── Lattice node states ──────────────────────────────────────────
   The lattice package doesn't ship these — the dashboard's CSS does.
   Ported here so the marketing hero's scripted loop visibly pulses,
   activates (jade glow), and completes (bronze glow). Same vocabulary
   the dashboard uses: .axo-pulse / .axo-active / .axo-completed. */

@keyframes axoPulse {
  0%   { box-shadow: 0 0 0 0    rgba(var(--axo-jade-glow-rgb), .75),
                     0 0 0 0    rgba(var(--axo-jade-glow-rgb), .55); }
  60%  { box-shadow: 0 0 0 14px rgba(var(--axo-jade-glow-rgb), .15),
                     0 0 0 28px rgba(var(--axo-jade-glow-rgb), .08); }
  100% { box-shadow: 0 0 0 22px rgba(var(--axo-jade-glow-rgb), 0),
                     0 0 0 44px rgba(var(--axo-jade-glow-rgb), 0);    }
}
@keyframes axoActiveBreathe {
  0%, 100% {
    box-shadow:
      0 0 0  1px var(--axo-jade-glow),
      0 0 14px 4px rgba(var(--axo-jade-glow-rgb), .55),
      0 0 30px 10px rgba(var(--axo-jade-glow-rgb), .22);
  }
  50% {
    box-shadow:
      0 0 0  1px var(--axo-jade-glow),
      0 0 18px 5px rgba(var(--axo-jade-glow-rgb), .70),
      0 0 38px 14px rgba(var(--axo-jade-glow-rgb), .30);
  }
}

.studio-mock-canvas ax-node.axo-pulse {
  animation: axoPulse 0.95s ease-out;
}
.studio-mock-canvas ax-node.axo-active {
  outline: 2px solid var(--axo-jade-glow) !important;
  outline-offset: 2px;
  box-shadow:
    0 0 0  1px var(--axo-jade-glow),
    0 0 14px 4px rgba(var(--axo-jade-glow-rgb), .55),
    0 0 30px 10px rgba(var(--axo-jade-glow-rgb), .22) !important;
  animation: axoActiveBreathe 2.2s ease-in-out infinite;
}
.studio-mock-canvas ax-node.axo-completed {
  outline: 2px solid var(--axo-bronze-glow) !important;
  outline-offset: 2px;
  box-shadow:
    0 0 0  1px var(--axo-bronze-glow),
    0 0 12px 3px rgba(var(--axo-bronze-glow-rgb), .50),
    0 0 26px 8px rgba(var(--axo-bronze-glow-rgb), .18) !important;
}


/* ── Sessions cockpit mock ──────────────────────────────────────
   Strip + cockpit shell + three-pane body. Always dark since the
   real cockpit is a code workspace and reads as a dark surface in
   both themes. */

.sessions-mock {
  display: grid;
  grid-template-columns: 44px 1fr;
  background: var(--bg-2);
  color: var(--fg);
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 560px;
  box-shadow: var(--shadow-2);
  border: 1px solid var(--border);
}
/* Reuse .studio-mock-strip styling — same vocabulary. The Sessions
   mock just needs the cockpit body specific to it. */

.sessions-cockpit {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--bg-2);
}
.sessions-cockpit-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 40px;
  padding: 0 14px;
  background: var(--panel-2);
  border-bottom: 1px solid var(--border);
  font-size: 12.5px;
  color: var(--muted);
}
.sessions-back {
  font-family: var(--font-display);
  color: var(--fg-soft);
}
.sessions-title {
  color: var(--fg);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 13px;
}
.sessions-meta {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--muted);
}
.sessions-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--fg-soft);
}

.sessions-grid {
  flex: 1;
  display: grid;
  grid-template-columns: 230px 1fr 290px;
  min-height: 0;
}

.sessions-pane {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  border-right: 1px solid var(--border);
  background: var(--panel);
}
.sessions-pane:last-child { border-right: 0; }
.sessions-pane-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 12px;
  background: var(--panel-2);
  border-bottom: 1px solid var(--border);
  font-family: var(--font-display);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: .8px;
  color: var(--muted-2);
  font-weight: 600;
}
.sessions-pane-meta {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--muted-2);
  text-transform: none;
  letter-spacing: 0;
}

/* Files pane: tree + editor */
.sessions-files {
  padding: 8px 6px;
  border-bottom: 1px solid var(--border);
  font-size: 12.5px;
}
.sessions-file {
  display: flex;
  align-items: center;
  padding: 4px 8px;
  border-radius: 5px;
  color: var(--fg-soft);
  font-family: var(--font-mono);
  font-size: 12px;
  cursor: default;
}
.sessions-file.dir { color: var(--fg); font-weight: 600; }
.sessions-file.indent { padding-left: 22px; }
.sessions-file[data-editing] {
  background: rgba(var(--axo-jade-rgb), .14);
  color: var(--axo-jade-glow);
  position: relative;
}
.sessions-file[data-editing]::after {
  content: '';
  position: absolute;
  left: 8px;
  top: 50%;
  width: 5px;
  height: 5px;
  margin-top: -2.5px;
  border-radius: 50%;
  background: var(--axo-jade-glow);
  box-shadow: 0 0 0 0 rgba(var(--axo-jade-glow-rgb), .7);
  animation: edit-pulse 1.6s ease-out infinite;
}
@keyframes edit-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(var(--axo-jade-glow-rgb), .55); }
  100% { box-shadow: 0 0 0 8px rgba(var(--axo-jade-glow-rgb), 0); }
}

.sessions-editor {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.sessions-editor-tabs {
  display: flex;
  gap: 0;
  background: var(--bg-2);
  border-bottom: 1px solid var(--border);
}
.sessions-editor-tab {
  padding: 6px 12px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--muted-2);
  border-right: 1px solid var(--border);
  border-bottom: 2px solid transparent;
  cursor: default;
}
.sessions-editor-tab.active {
  color: var(--fg);
  background: var(--panel);
  border-bottom-color: var(--axo-jade);
}
.sessions-editor-code {
  flex: 1;
  margin: 0;
  padding: 12px 14px;
  background: var(--bg);
  color: var(--fg-soft);
  font-family: var(--font-mono);
  font-size: 11.5px;
  line-height: 1.65;
  overflow: auto;
  border: 0;
  border-radius: 0;
}
.sessions-editor-code .ed-comment { color: var(--muted-2); font-style: italic; }
.sessions-editor-code .ed-key     { color: #c98a4a; }
.sessions-editor-code .ed-str     { color: #5fb87c; }
.sessions-editor-code .ed-num     { color: #7eb6ff; }
.sessions-editor-code .ed-fn      { color: #4FCB8E; }
.sessions-editor-code .ed-var     { color: var(--fg); }

/* Activity pane: chat-like stream */
.sessions-msgs {
  flex: 1;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: auto;
  min-height: 0;
}
.sessions-msg {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.sessions-msg-who {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--muted-2);
}
.sessions-msg.user .sessions-msg-who { color: var(--axo-blue); }
.sessions-msg.agent .sessions-msg-who { color: var(--axo-jade-glow); }
.sessions-msg-body {
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--fg-soft);
}
.sessions-msg-body code {
  font-family: var(--font-mono);
  font-size: 11.5px;
  background: var(--border);
  color: var(--fg);
  padding: 1px 5px;
  border-radius: 3px;
}

/* Tool chips inside the Activity stream */
.sessions-toolchip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--fg-soft);
}
.sessions-toolchip-name {
  color: var(--axo-jade-glow);
  font-weight: 500;
}
.sessions-toolchip-arg {
  color: var(--fg-soft);
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sessions-toolchip-meta {
  color: var(--muted-2);
  font-size: 10.5px;
  white-space: nowrap;
}
.sessions-toolchip.ok::before {
  content: '✓';
  color: var(--axo-jade-glow);
  font-family: var(--font-mono);
  font-size: 11px;
}
.sessions-toolchip.running::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--axo-jade);
  box-shadow: 0 0 8px rgba(var(--axo-jade-rgb), .7);
  animation: studio-mock-pulse 1.6s ease-in-out infinite;
}
.sessions-toolchip-spinner {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: 1.5px solid var(--border-strong);
  border-top-color: var(--axo-jade-glow);
  animation: tool-spin 0.85s linear infinite;
}
@keyframes tool-spin {
  to { transform: rotate(360deg); }
}

/* Agent "typing" indicator at bottom of Activity */
.sessions-typing {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 10px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  width: max-content;
  margin-top: -2px;
}
.sessions-typing-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--muted-2);
  animation: type-bounce 1.2s ease-in-out infinite;
}
.sessions-typing-dot:nth-child(2) { animation-delay: .15s; }
.sessions-typing-dot:nth-child(3) { animation-delay: .30s; }
@keyframes type-bounce {
  0%, 80%, 100% { transform: translateY(0); background: var(--muted-2); }
  40%           { transform: translateY(-3px); background: var(--axo-jade-glow); }
}

/* Terminal pane */
.sessions-terminal {
  flex: 1;
  margin: 0;
  padding: 12px 14px;
  background: var(--bg);
  font-family: var(--font-mono);
  font-size: 11.5px;
  line-height: 1.65;
  color: var(--fg-soft);
  overflow: auto;
  border: 0;
  white-space: pre;
}
.sessions-terminal .term-dim { color: var(--muted-2); }
.sessions-terminal .term-jade { color: var(--axo-jade-glow); }
.sessions-terminal .term-cursor {
  background: var(--axo-jade-glow);
  color: var(--axo-jade-glow);
  animation: term-blink 1.1s steps(2) infinite;
}
@keyframes term-blink {
  50% { opacity: 0; }
}

/* Mobile: stack the panes for narrower screens */
@media (max-width: 980px) {
  .sessions-grid {
    grid-template-columns: 1fr;
    grid-auto-rows: minmax(220px, auto);
  }
  .sessions-pane { border-right: 0; border-bottom: 1px solid var(--border); }
  .sessions-pane:last-child { border-bottom: 0; }
}
@media (max-width: 720px) {
  .sessions-mock { grid-template-columns: 1fr; }
  .sessions-mock .studio-mock-strip { display: none; }
}

/* Mobile shrink: hide the strip + side, just show the canvas.  The
   toolbar's centred title (`fix-bug-273 · running`) collapses to
   nothing and the inspector overlay hides — both fight with the
   demo's three nodes for the narrow canvas.  Pearls scale down so
   they don't crowd the corner. */
@media (max-width: 720px) {
  .studio-mock { grid-template-columns: 1fr; min-height: 360px; border-radius: var(--radius); }
  .studio-mock-strip { display: none; }
  .studio-mock-shell { grid-template-columns: 1fr; min-height: 360px; }
  .studio-mock-side  { display: none; }
  .studio-mock-toolbar { padding: 8px 10px; gap: 6px; flex-wrap: wrap; }
  .studio-mock-toolbar-help { display: none; }
  .studio-mock-mode-btn,
  .studio-mock-toolbar-btn { padding: 4px 8px; font-size: 11px; }
  .studio-mock-canvas { min-height: 280px; }
  .studio-mock-inspector { display: none !important; }
  .studio-mock-pearls { transform: scale(.85); transform-origin: bottom right; bottom: 8px; right: 8px; gap: 4px; }
}


/* ── Automation cards (replaces the abstract pillars) ─────────────── */

.automations-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--s-4);
}

.automation-card {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  padding: var(--s-5) var(--s-5);
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color .15s, transform .15s, box-shadow .15s;
}
.automation-card:hover {
  border-color: var(--border-strong);
  transform: translateY(-1px);
  box-shadow: var(--shadow-1);
}
.automation-card-head {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  justify-content: space-between;
}
.automation-trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: var(--t-13);
  background: rgba(var(--axo-jade-rgb), .12);
  border: 1px solid rgba(var(--axo-jade-rgb), .25);
  color: var(--accent);
  white-space: nowrap;
}
.automation-trigger.trigger-event {
  background: rgba(var(--axo-blue-rgb), .12);
  border-color: rgba(var(--axo-blue-rgb), .28);
  color: var(--accent-2);
}
.automation-trigger.trigger-skill {
  background: rgba(181, 144, 74, .14);
  border-color: rgba(181, 144, 74, .32);
  color: #c98a4a;
}
.automation-trigger.trigger-session {
  background: var(--bg-3);
  border-color: var(--border-strong);
  color: var(--fg-soft);
}
.automation-trigger-glyph { font-size: 12px; line-height: 1; }
.automation-trigger-label { font-weight: 500; }
.automation-trigger-detail { color: var(--muted); }
.automation-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: var(--t-13);
  color: var(--muted);
}
.automation-status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 7px rgba(var(--axo-jade-rgb), .55);
}
.automation-status.status-disabled .automation-status-dot {
  background: var(--muted-2);
  box-shadow: none;
}

.automation-name {
  font-family: var(--font-display);
  font-size: var(--t-20);
  font-weight: 600;
  letter-spacing: -.012em;
  margin: 0;
  color: var(--fg);
}
.automation-body {
  color: var(--muted);
  font-size: var(--t-14);
  line-height: 1.55;
}
.automation-body p { margin: 0; max-width: none; color: var(--muted); }
.automation-chain {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  padding-top: var(--s-3);
  border-top: 1px dashed var(--border);
}
.automation-agent {
  font-family: var(--font-mono);
  font-size: var(--t-13);
  padding: 2px 9px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: 5px;
  color: var(--fg);
}
.automation-arrow {
  font-family: var(--font-mono);
  color: var(--muted-2);
  font-size: var(--t-14);
}

/* ══════════════════════════════════════════════════════════════════
   Sessions mock v2 — mirrors the actual Axocoatl dashboard cockpit.
   3 panes (Files / Activity / Browser) + 40px terminals rail.
   All `.sx-*` selectors so they don't collide with the older
   sessions-* rules above (which are dead code now).
   ════════════════════════════════════════════════════════════════ */

.sx-mock {
  display: grid;
  grid-template-columns: 40px 1fr;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 580px;
  box-shadow: var(--shadow-2);
  font-family: var(--font-body);
  color: var(--fg);
}

/* ─── Strip ─── */
.sx-strip {
  display: flex; flex-direction: column; align-items: center;
  padding: 6px 0;
  background: var(--bg-2);
  border-right: 1px solid var(--border);
  gap: 2px;
}
.sx-strip-mark { width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; margin-bottom: 4px; }
.sx-strip-mark img { width: 26px; height: 26px; object-fit: contain; filter: drop-shadow(0 0 6px rgba(var(--axo-jade-rgb), .35)); }
.sx-strip-item {
  width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 6px; cursor: default; user-select: none;
  color: var(--muted); font-size: 15px;
  position: relative;
}
.sx-strip-item.active { color: var(--accent); background: rgba(var(--axo-jade-rgb), .13); }
.sx-strip-item.active::before {
  content: ''; position: absolute; left: -6px; top: 6px; bottom: 6px;
  width: 2px; background: var(--accent); border-radius: 2px;
}
.sx-strip-spacer { flex: 1; }
.sx-strip-pearl {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--axo-jade-glow);
  box-shadow: 0 0 6px rgba(var(--axo-jade-glow-rgb), .65);
  margin-top: 6px;
}

/* ─── Cockpit shell ─── */
.sx-cockpit { display: flex; flex-direction: column; min-width: 0; background: var(--bg); }

/* Title bar — 40px high, flat, monochrome with one jade live pill. */
.sx-bar {
  display: flex; align-items: center; gap: 12px;
  height: 40px; padding: 0 14px;
  background: var(--panel-2);
  border-bottom: 1px solid var(--border);
  font-size: 12.5px; color: var(--muted);
  font-family: var(--font-display);
}
.sx-back { color: var(--fg-soft); cursor: default; }
.sx-name { color: var(--fg); font-weight: 600; font-size: 13px; letter-spacing: -.005em; }
.sx-dir { font-family: var(--font-mono); font-size: 11.5px; color: var(--muted); }
.sx-mid { flex: 1; }
.sx-live { display: inline-flex; align-items: center; gap: 6px; color: var(--fg-soft); font-family: var(--font-mono); font-size: 11.5px; }
.sx-live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--axo-jade-glow); box-shadow: 0 0 6px rgba(var(--axo-jade-glow-rgb), .7); }
.sx-panes-btn { color: var(--muted); font-size: 11.5px; cursor: default; }

/* ─── Shell: 3-pane grid + terminals rail ─── */
.sx-shell { flex: 1; display: flex; min-height: 0; position: relative; }
.sx-grid {
  flex: 1;
  display: grid;
  grid-template-columns: 240px 1fr 220px;
  min-height: 0;
  margin-right: 40px;        /* reserve room for terminals rail */
}

/* Pane */
.sx-pane {
  display: flex; flex-direction: column;
  min-width: 0; min-height: 0;
  background: var(--panel);
  border-right: 1px solid var(--border);
  overflow: hidden;
}
.sx-pane:last-of-type { border-right: 0; }
.sx-pane-head {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 11px 7px;
  background: var(--panel-2);
  border-bottom: 1px solid var(--border);
  font-family: var(--font-display);
  font-size: 10.5px; text-transform: uppercase; letter-spacing: .75px;
  color: var(--muted-2); font-weight: 600;
}
.sx-pane-title { color: var(--muted-2); }
.sx-pane-meta { color: transparent; }
.sx-pane-btn { color: var(--muted-2); font-size: 11px; margin-left: auto; padding: 0 2px; }
.sx-pane-btn + .sx-pane-btn { margin-left: 0; }

/* Files pane: search + tree + empty editor placeholder. */
.sx-files { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.sx-file-search { display: flex; align-items: center; gap: 6px; padding: 6px 8px; border-bottom: 1px solid var(--border); }
.sx-file-search-ico { color: var(--muted); font-size: 12px; }
.sx-file-search-input {
  flex: 1; background: var(--bg-3); border: 1px solid var(--border); border-radius: 4px;
  padding: 3px 7px; color: var(--fg); font-size: 12px; outline: none;
  font-family: inherit;
}
.sx-file-tree {
  padding: 5px 4px; font-family: var(--font-mono); font-size: 12px;
  border-bottom: 1px solid var(--border);
}
.sx-file { padding: 3px 8px; color: var(--fg-soft); border-radius: 4px; cursor: default; }
.sx-file.dir { color: var(--fg); font-weight: 600; }
.sx-file.indent { padding-left: 22px; }
.sx-file[data-editing] {
  background: rgba(var(--axo-jade-rgb), .14);
  color: var(--axo-jade-glow);
  position: relative;
}
.sx-file[data-editing]::after {
  content: '';
  position: absolute; left: 8px; top: 50%; width: 5px; height: 5px; margin-top: -2.5px;
  border-radius: 50%; background: var(--axo-jade-glow);
  animation: sx-edit-pulse 1.6s ease-out infinite;
}
@keyframes sx-edit-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(var(--axo-jade-glow-rgb), .55); }
  100% { box-shadow: 0 0 0 8px rgba(var(--axo-jade-glow-rgb), 0); }
}
.sx-file-empty {
  flex: 1; padding: 28px 20px; color: var(--muted); font-size: 12px; text-align: center;
}

/* Activity pane: ACTIVE chip row + msgs + tool chips + typing + input. */
.sx-active {
  display: flex; align-items: center; flex-wrap: wrap; gap: 6px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
  min-height: 36px;
}
.sx-active-eyebrow {
  font-family: var(--font-display);
  font-size: 10.5px; text-transform: uppercase; letter-spacing: .8px;
  color: var(--muted-2); font-weight: 600;
}
.sx-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px;
  background: rgba(var(--axo-jade-rgb), .10);
  border: 1px solid rgba(var(--axo-jade-rgb), .28);
  border-radius: 999px;
  font-size: 11.5px; color: var(--fg-soft);
  font-family: var(--font-mono);
}
.sx-chip-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--axo-jade-glow); }
.sx-chip-kind { color: var(--muted); text-transform: uppercase; letter-spacing: .6px; font-size: 9.5px; }
.sx-chip-name { color: var(--fg-soft); }

.sx-msgs {
  flex: 1;
  padding: 14px 14px 12px;
  display: flex; flex-direction: column; gap: 12px;
  overflow: auto;
  min-height: 0;
}
.sx-msg { font-size: 12.5px; line-height: 1.55; }
.sx-msg-role {
  font-family: var(--font-display);
  font-size: 11px; font-weight: 600; letter-spacing: .04em;
  text-transform: uppercase; color: var(--muted-2);
  margin-bottom: 4px;
}
.sx-msg-body { color: var(--fg-soft); }
.sx-msg-body code {
  font-family: var(--font-mono); font-size: 11.5px;
  background: var(--bg-3); color: var(--fg); padding: 1px 5px; border-radius: 3px;
}

/* Tool chip */
.sx-toolchip {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 10px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-family: var(--font-mono); font-size: 11.5px;
  color: var(--fg-soft);
}
.sx-toolchip.ok::before { content: '✓'; color: var(--axo-jade-glow); font-size: 11px; }
.sx-toolchip.running::before {
  content: ''; width: 9px; height: 9px; border-radius: 50%;
  border: 1.5px solid #2a2f3a; border-top-color: var(--axo-jade-glow);
  animation: sx-tc-spin .9s linear infinite;
}
@keyframes sx-tc-spin { to { transform: rotate(360deg); } }
.sx-toolchip-name { color: var(--axo-jade-glow); font-weight: 500; }
.sx-toolchip-arg { color: var(--fg-soft); flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sx-toolchip-meta { color: var(--muted-2); font-size: 10.5px; }
.sx-toolchip-spinner {
  width: 9px; height: 9px; border-radius: 50%;
  border: 1.5px solid #2a2f3a; border-top-color: var(--axo-jade-glow);
  animation: sx-tc-spin .9s linear infinite; margin-left: auto;
}

/* Typing dots */
.sx-typing {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 6px 10px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  width: max-content;
}
.sx-typing span {
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--muted-2);
  animation: sx-type-bounce 1.2s ease-in-out infinite;
}
.sx-typing span:nth-child(2) { animation-delay: .15s; }
.sx-typing span:nth-child(3) { animation-delay: .30s; }
@keyframes sx-type-bounce {
  0%,80%,100% { transform: translateY(0); background: var(--muted-2); }
  40%         { transform: translateY(-3px); background: var(--axo-jade-glow); }
}

/* Input: per-turn model picker row + textarea + send. */
.sx-input {
  display: flex; flex-direction: column; gap: 6px;
  padding: 10px;
  border-top: 1px solid var(--border);
  background: var(--panel);
}
.sx-input-bar { display: flex; align-items: center; gap: 8px; }
.sx-pick {
  background: var(--bg-3); border: 1px solid var(--border); border-radius: 5px;
  color: var(--fg-soft); font-family: var(--font-mono); font-size: 11px;
  padding: 3px 8px;
}
.sx-input-row { display: flex; gap: 8px; }
.sx-input-text {
  flex: 1; background: var(--bg-3); border: 1px solid var(--border); border-radius: 6px;
  padding: 8px 10px; color: var(--fg); font-size: 12.5px; outline: none;
  font-family: inherit;
}
.sx-input-text:focus { border-color: var(--accent); }
.sx-input-send {
  background: var(--accent); border: 0; color: #fff;
  padding: 8px 16px; border-radius: 6px; font-weight: 600;
  font-family: var(--font-display); font-size: 12.5px; cursor: default;
}

/* Browser pane: toolbar + body. */
.sx-browser-tools {
  display: flex; align-items: center; gap: 4px;
  padding: 7px 8px;
  border-bottom: 1px solid var(--border);
  background: var(--panel-2);
}
.sx-browser-btn {
  background: var(--bg-3); border: 1px solid var(--border); border-radius: 4px;
  color: var(--fg-soft); padding: 3px 7px; font-size: 11px;
}
.sx-browser-btn.pick { color: #E26060; }
.sx-browser-url {
  flex: 1;
  background: var(--bg-3); border: 1px solid var(--border); border-radius: 4px;
  padding: 3px 8px; color: var(--fg-soft);
  font-family: var(--font-mono); font-size: 11px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.sx-browser-body {
  flex: 1; padding: 16px 14px; color: var(--muted); font-size: 12px;
  text-align: center; line-height: 1.5;
}

/* ─── Terminals rail (40px on the right) ─── */
.sx-term-rail {
  position: absolute; top: 0; right: 0; bottom: 0;
  width: 40px;
  background: var(--panel);
  border-left: 1px solid var(--border);
  display: flex; flex-direction: column; align-items: center;
  padding: 6px 0 8px;
  gap: 8px;
}
.sx-term-toggle {
  background: transparent; border: 0;
  color: var(--axo-jade-glow); font-size: 13px; font-weight: 600;
  width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 6px;
}
.sx-term-rail-label {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-family: var(--font-display);
  font-size: 10.5px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 1.2px;
  color: var(--muted-2);
  flex: 1;
}
.sx-term-rail-add { color: var(--muted); font-size: 14px; padding: 4px; }

/* Mobile: stack panes vertically; hide strip + rail. */
@media (max-width: 900px) {
  .sx-mock { grid-template-columns: 1fr; min-height: 0; }
  .sx-strip { display: none; }
  .sx-grid { grid-template-columns: 1fr; margin-right: 0; grid-auto-rows: minmax(220px, auto); }
  .sx-pane { border-right: 0; border-bottom: 1px solid var(--border); }
  .sx-term-rail { display: none; }
}
