/* ════════════════════════════════════════════════════════════════
   BLOOM Console — homepage signature interaction (Phase 3E, 2026-05-07)

   On-brand: shows the actual agent fleet that builds and operates
   Reaves Labs and Learning, dispatching tasks in real time. Tokens
   come from /css/observatory.css.

   Layout: glass-card terminal with monospace task feed. New lines
   appear at the top every 2.4s; older lines fade as they age out.
   Status icons animate (⟶ pulses, ✓ flashes green on transition).

   Motion respects prefers-reduced-motion via the global override
   in observatory.css (transitions/animations down to 0.01ms).
   ════════════════════════════════════════════════════════════════ */

.bloom-console-section {
  max-width: 1100px;
  margin: 64px auto;
  padding: 0 24px;
}

.bloom-console-eyebrow {
  font-family: var(--rll-sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-cyan, var(--cyan));
  text-align: center;
  margin-bottom: 12px;
}

.bloom-console-title {
  font-family: var(--rll-serif);
  font-variation-settings: var(--rll-vf-display);
  font-size: clamp(1.6rem, 3.4vw, 2.4rem);
  text-align: center;
  margin-bottom: 8px;
  color: var(--text);
  line-height: 1.15;
}
.bloom-console-title em {
  font-style: italic;
  color: var(--accent-gold, var(--gold));
  font-variation-settings: var(--rll-vf-italic);
}

.bloom-console-sub {
  font-family: var(--rll-body);
  font-size: 0.95rem;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 28px;
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.6;
}

.bloom-console {
  position: relative;
  background: linear-gradient(180deg, oklch(15% 0.03 250) 0%, oklch(11% 0.03 250) 100%);
  border: 1px solid var(--border-default, var(--border));
  border-radius: 14px;
  overflow: hidden;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.05) inset,
    0 24px 60px oklch(0% 0 0 / 0.34);
  font-family: var(--rll-mono);
  font-feature-settings: "tnum" 1, "calt" 1;
}

/* Top bar — looks like a terminal title bar with traffic lights + status */
.bloom-console-bar {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 18px;
  border-bottom: 1px solid var(--border-subtle, rgba(255,255,255,0.06));
  background: oklch(20% 0.02 250 / 0.4);
  backdrop-filter: blur(10px);
}
.bloom-console-dots {
  display: flex;
  gap: 6px;
}
.bloom-console-dots span {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  display: block;
}
.bloom-console-dots span:nth-child(1) { background: oklch(70% 0.16 25); }
.bloom-console-dots span:nth-child(2) { background: oklch(85% 0.16 80); }
.bloom-console-dots span:nth-child(3) { background: oklch(78% 0.16 158); }

.bloom-console-id {
  font-family: var(--rll-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
}
.bloom-console-id strong {
  color: var(--text);
  font-weight: 600;
  font-family: var(--rll-sans);
  letter-spacing: 0.02em;
}

.bloom-console-status {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.72rem;
  color: var(--text-muted);
}
.bloom-console-status .pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: oklch(78% 0.16 158);
  box-shadow: 0 0 0 0 oklch(78% 0.16 158 / 0.6);
  animation: bc-pulse 1.8s ease-out infinite;
}
@keyframes bc-pulse {
  0%   { box-shadow: 0 0 0 0 oklch(78% 0.16 158 / 0.6); }
  100% { box-shadow: 0 0 0 12px oklch(78% 0.16 158 / 0); }
}

/* Feed body */
.bloom-console-feed {
  position: relative;
  padding: 18px 22px 22px;
  min-height: 320px;
  max-height: 360px;
  overflow: hidden;
  /* Soft fade at the bottom of the visible feed */
  -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 78%, transparent 100%);
          mask-image: linear-gradient(180deg, #000 0%, #000 78%, transparent 100%);
}

.bloom-console-row {
  display: grid;
  grid-template-columns: 78px 110px 1fr 28px;
  align-items: baseline;
  gap: 14px;
  padding: 6px 0;
  font-size: 0.84rem;
  line-height: 1.5;
  color: oklch(86% 0.02 250);
  opacity: 0;
  transform: translateY(-6px);
  animation: bc-row-in 280ms var(--ease-soft, cubic-bezier(0.32, 0.72, 0, 1)) forwards;
}
@keyframes bc-row-in {
  to { opacity: 1; transform: translateY(0); }
}

.bloom-console-row.dim {
  opacity: 0.42;
}

.bloom-console-time {
  color: var(--text-muted);
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
}

.bloom-console-arrow {
  color: var(--accent-brand, var(--primary));
  font-weight: 500;
  letter-spacing: 0.04em;
}

.bloom-console-agent {
  display: inline-block;
  font-family: var(--rll-sans);
  font-weight: 600;
  letter-spacing: 0.04em;
  font-size: 0.78rem;
  text-transform: uppercase;
}
.bloom-console-agent[data-color="rocket"]   { color: oklch(76% 0.18 30); }
.bloom-console-agent[data-color="infra"]    { color: oklch(72% 0.16 215); }
.bloom-console-agent[data-color="sage"]     { color: oklch(82% 0.14 215); }
.bloom-console-agent[data-color="revi"]     { color: oklch(78% 0.16 158); }
.bloom-console-agent[data-color="content"]  { color: oklch(85% 0.16 80); }
.bloom-console-agent[data-color="trading"]  { color: oklch(76% 0.20 250); }
.bloom-console-agent[data-color="research"] { color: oklch(74% 0.14 320); }
.bloom-console-agent[data-color="bloom"]    { color: var(--text); font-weight: 700; }

.bloom-console-task {
  color: oklch(80% 0.02 250);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bloom-console-status-icon {
  font-family: var(--rll-mono);
  text-align: right;
}
.bloom-console-status-icon[data-state="running"] {
  color: var(--accent-cyan, var(--cyan));
  animation: bc-run-pulse 1.4s ease-in-out infinite;
}
@keyframes bc-run-pulse {
  0%, 100% { opacity: 0.55; }
  50% { opacity: 1; }
}
.bloom-console-status-icon[data-state="done"] {
  color: oklch(78% 0.16 158);
}
.bloom-console-status-icon[data-state="queued"] {
  color: var(--text-muted);
  opacity: 0.6;
}

/* Footer caption beneath the console */
.bloom-console-caption {
  margin-top: 14px;
  font-family: var(--rll-body);
  font-size: 0.85rem;
  color: var(--text-muted);
  text-align: center;
  letter-spacing: 0.01em;
}
.bloom-console-caption a {
  color: var(--accent-cyan, var(--cyan));
  text-decoration: none;
  border-bottom: 1px dotted oklch(82% 0.14 215 / 0.4);
  transition: color 0.2s, border-color 0.2s;
}
.bloom-console-caption a:hover {
  color: var(--text);
  border-bottom-color: var(--text);
}

/* Mobile */
@media (max-width: 720px) {
  .bloom-console-row {
    grid-template-columns: 64px 88px 1fr 24px;
    gap: 10px;
    font-size: 0.78rem;
  }
  .bloom-console-feed {
    padding: 14px 16px 18px;
    min-height: 280px;
    max-height: 320px;
  }
  .bloom-console-time { font-size: 0.66rem; }
  .bloom-console-agent { font-size: 0.72rem; }
}

/* Reduced motion: kill row entrance + pulses; static snapshot */
@media (prefers-reduced-motion: reduce) {
  .bloom-console-row {
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
  }
  .bloom-console-status .pulse,
  .bloom-console-status-icon[data-state="running"] {
    animation: none !important;
  }
}
