/* Hero mock — inline visual of the Home surface */
.hero-mock {
  width: 100%;
  max-width: 820px;
  margin: 56px auto 0;
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(11, 13, 24, 1) 0%, rgba(6, 8, 16, 1) 100%);
  border: 1px solid rgba(255, 255, 255, 0.05);
  box-shadow:
    0 24px 80px rgba(0, 0, 0, 0.65),
    0 0 0 1px rgba(124, 107, 255, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.03);
  overflow: hidden;
  text-align: left;
  position: relative;
}
/* Items dim when their space isn't the one being hovered (desktop) OR tap-selected (touch) */
.hero-mock [data-space] { transition: opacity 0.18s ease; }
.hero-mock:has(.hm-pill[data-space="acme-app"]:hover) [data-space]:not([data-space="acme-app"]):not(.hm-pill),
.hero-mock.is-filter-acme-app [data-space]:not([data-space="acme-app"]):not(.hm-pill) { opacity: 0.25; }
.hero-mock:has(.hm-pill[data-space="pitch-deck"]:hover) [data-space]:not([data-space="pitch-deck"]):not(.hm-pill),
.hero-mock.is-filter-pitch-deck [data-space]:not([data-space="pitch-deck"]):not(.hm-pill) { opacity: 0.25; }
.hero-mock:has(.hm-pill[data-space="field-notes"]:hover) [data-space]:not([data-space="field-notes"]):not(.hm-pill),
.hero-mock.is-filter-field-notes [data-space]:not([data-space="field-notes"]):not(.hm-pill) { opacity: 0.25; }
/* Tap-active filter pill — lift it visually so the user can see what's engaged */
.hero-mock .hm-pill[data-space].is-filter-on {
  background: rgba(124, 107, 255, 0.16);
  border-color: rgba(124, 107, 255, 0.4);
  color: #a597ff;
}
/* cursor: pointer is load-bearing on iOS — without it, taps don't fire click events on non-button elements */
.hm-tile { transition: background 0.15s ease, transform 0.15s ease; cursor: pointer; }
.hm-tile:hover { background: rgba(255, 255, 255, 0.06); }
.hero-mock-chrome {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 14px;
  background: rgba(0, 0, 0, 0.45);
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.hero-mock-chrome .dot {
  width: 10px; height: 10px; border-radius: 50%;
}
.hero-mock-chrome .dot-r { background: #ff5f57; }
.hero-mock-chrome .dot-y { background: #febc2e; }
.hero-mock-chrome .dot-g { background: #28c840; }
.hero-mock-chrome-title {
  margin-left: 6px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.35);
}
.hero-mock-body {
  padding: 22px 24px;
  display: flex; flex-direction: column; gap: 22px;
}
.hero-mock-breadcrumb {
  display: flex; gap: 8px; flex-wrap: wrap;
  align-items: center;
}
.hm-pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: rgba(232, 233, 240, 0.55);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.hm-pill:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.12);
  color: rgba(232, 233, 240, 0.85);
}
.hm-pill-active {
  background: rgba(124, 107, 255, 0.16);
  border-color: rgba(124, 107, 255, 0.4);
  color: #a597ff;
}
.hm-pill-active:hover {
  background: rgba(124, 107, 255, 0.22);
  border-color: rgba(124, 107, 255, 0.55);
  color: #c4b5fd;
}
.hm-pill-icon {
  padding: 0;
  width: 32px; height: 32px;
  justify-content: center;
}
.hm-pill-icon svg { width: 14px; height: 14px; opacity: 1; }
.hm-pill .pip {
  width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0;
}
.hm-pill .pip-g { background: #4ade80; box-shadow: 0 0 5px #4ade80; }
.hm-pill .pip-a { background: #fbbf24; box-shadow: 0 0 5px #fbbf24; }
.hm-pill .pip-r { background: #f87171; box-shadow: 0 0 5px #f87171; }

/* Filter chips (lifted from filter-options.html) */
.hm-chips { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.hm-chip {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.04em;
  color: rgba(232, 233, 240, 0.55);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  padding: 3px 10px;
  border-radius: 9999px;
}
.hm-chip-selected {
  background: rgba(124, 107, 255, 0.18);
  border-color: rgba(124, 107, 255, 0.3);
  color: #a597ff;
}
.hm-chip .pip { width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0; }
.hm-chip .pip-g { background: #4ade80; box-shadow: 0 0 6px #4ade80; animation: hmBreathe 2.4s ease-in-out infinite; }
.hm-chip .pip-a { background: #fbbf24; box-shadow: 0 0 6px #fbbf24; }
.hm-chip .pip-r { background: #f87171; box-shadow: 0 0 6px #f87171; }
.hm-chip .pip-d { background: rgba(255, 255, 255, 0.18); }
@keyframes hmBreathe { 50% { opacity: 0.45; } }
@media (prefers-reduced-motion: reduce) {
  .hm-chip .pip-g { animation: none; }
}

/* Section heads + sessions */
.hm-section-head {
  display: flex; align-items: baseline; justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}
@media (max-width: 520px) {
  .hm-section-head { flex-direction: column; align-items: flex-start; }
}
.hm-section-name {
  font-family: 'Barlow', sans-serif;
  font-size: 11px; font-weight: 600;
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase; letter-spacing: 1.5px;
}
.hm-section-meta {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.3);
}
.hm-tiles { display: flex; flex-direction: column; gap: 6px; }
.hm-tile {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
}
.hm-status { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.hm-status-g { background: #4ade80; box-shadow: 0 0 8px rgba(74, 222, 128, 0.6); }
.hm-status-a { background: #fbbf24; box-shadow: 0 0 8px rgba(251, 191, 36, 0.6); }
.hm-status-r { background: #f87171; box-shadow: 0 0 8px rgba(248, 113, 113, 0.5); }
.hm-status-d { background: rgba(255, 255, 255, 0.22); }
.hm-status-running { background: #5eead4; box-shadow: 0 0 8px rgba(94, 234, 212, 0.6); animation: hmRtpPulse 2.4s ease-out infinite; }
@media (prefers-reduced-motion: reduce) {
  .hm-status-running { animation: none; }
}
.hm-tile-running {
  position: relative;
  border-left: 2px solid #5eead4;
  background: rgba(94, 234, 212, 0.05);
}
.hm-tile-running:hover { background: rgba(94, 234, 212, 0.1); }
.hm-tile-body { flex: 1; min-width: 0; }
.hm-tile-title {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.88);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.hm-tile-meta {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.35);
  margin-top: 1px;
}
.hm-tile-time {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.35);
  flex-shrink: 0;
}

/* Artefact tiles */
.hm-art-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 72px));
  gap: 14px 14px;
  justify-content: start;
}
.hm-art-cell {
  display: flex; flex-direction: column;
  align-items: center;
  gap: 6px;
  min-width: 0;
  width: 100%;
  cursor: pointer;
}
.hm-art {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    inset 0 -1px 0 rgba(0, 0, 0, 0.22),
    0 3px 10px rgba(0, 0, 0, 0.3);
  overflow: hidden;
  position: relative;
}
.hm-art-icon {
  width: 26px; height: 26px;
  color: rgba(255, 255, 255, 0.95);
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.45));
  stroke-width: 2;
}
/* Richer content-preview style — fills the tile, no centered icon */
.hm-art-preview {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.hm-art-label {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 10px; font-weight: 500;
  color: rgba(255, 255, 255, 0.78);
  text-align: center;
  width: 100%;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.hm-art-more {
  background: rgba(255, 255, 255, 0.03) !important;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08) !important;
}
.hm-art-more-text {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.45);
  letter-spacing: 0.04em;
}

/* Launchable rocket tile — telegraphs it's clickable + keyboard accessible */
.hm-art-cell-launchable { cursor: pointer; outline: none; }
.hm-art-cell-launchable .hm-art {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.hm-art-cell-launchable:hover .hm-art,
.hm-art-cell-launchable:focus-visible .hm-art {
  transform: translateY(-2px) scale(1.03);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    inset 0 -1px 0 rgba(0, 0, 0, 0.22),
    0 10px 24px rgba(124, 58, 237, 0.45);
}
.hm-art-cell-launchable:focus-visible .hm-art {
  outline: 2px solid rgba(169, 158, 255, 0.9);
  outline-offset: 3px;
}

/* Memories */
.hm-mems { display: flex; flex-direction: column; gap: 6px; }
.hm-mem {
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
}
.hm-mem-text {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.86);
  line-height: 1.4;
}
.hm-mem-meta {
  display: flex; gap: 8px; align-items: center;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.35);
  margin-top: 4px;
}
.hm-mem-space { color: #a99eff; }
.hm-mem-sep { opacity: 0.4; }

/* Floating preview window — shows on artefact hover */
.hm-preview {
  position: absolute;
  left: 24px; right: 24px;
  bottom: 110px;
  height: 158px;
  background: rgba(14, 15, 30, 0.97);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
  z-index: 6;
  overflow: hidden;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}
.hero-mock:has(.hm-art-cell[data-artefact]:hover) .hm-preview,
.hero-mock.is-preview-open .hm-preview {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
/* Close affordance — only visible while the preview is tap-pinned. Proper tap target sized for touch (28×28) */
.hm-preview-close {
  margin-left: auto;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  width: 28px; height: 28px;
  font-size: 20px; line-height: 1;
  color: rgba(255, 255, 255, 0.85);
  cursor: pointer;
  display: none;
  border-radius: 6px;
  padding: 0;
}
.hm-preview-close:hover,
.hm-preview-close:active { color: #fff; background: rgba(255, 255, 255, 0.16); border-color: rgba(255, 255, 255, 0.24); }
.hero-mock.is-preview-open .hm-preview-close { display: inline-flex; align-items: center; justify-content: center; }
.hm-preview-chrome {
  display: flex; align-items: center; gap: 7px;
  padding: 8px 12px;
  background: rgba(0, 0, 0, 0.25);
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.hm-preview-chrome span.dot { width: 9px; height: 9px; border-radius: 50%; }
.hm-preview-title {
  margin-left: 6px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.5);
}
.hm-preview-body {
  padding: 14px 18px;
  height: calc(100% - 32px);
  overflow: hidden;
}

/* Per-artefact preview shapes */
.pv-app-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; height: 100%; }
.pv-card {
  background: rgba(124, 107, 255, 0.08);
  border: 1px solid rgba(124, 107, 255, 0.18);
  border-radius: 8px;
  padding: 10px;
  display: flex; flex-direction: column; justify-content: space-between;
  font-family: 'Space Grotesk', sans-serif;
}
.pv-card-label { font-size: 9px; color: rgba(255, 255, 255, 0.4); font-family: 'IBM Plex Mono', monospace; letter-spacing: 0.06em; text-transform: uppercase; }
.pv-card-title { font-size: 11px; font-weight: 600; color: rgba(255, 255, 255, 0.85); }
.pv-slide { font-family: 'Space Grotesk', sans-serif; }
.pv-slide-num { font-family: 'IBM Plex Mono', monospace; font-size: 9px; color: rgba(255, 255, 255, 0.35); letter-spacing: 0.08em; margin-bottom: 8px; }
.pv-slide h4 { font-size: 16px; font-weight: 700; color: #fff; margin-bottom: 8px; letter-spacing: -0.01em; }
.pv-slide ul { list-style: none; display: flex; flex-direction: column; gap: 5px; }
.pv-slide li { font-size: 11px; color: rgba(255, 255, 255, 0.7); padding-left: 14px; position: relative; }
.pv-slide li::before { content: ''; position: absolute; left: 0; top: 6px; width: 5px; height: 5px; background: #7c6bff; border-radius: 50%; }
.pv-diag { display: flex; align-items: center; justify-content: center; gap: 14px; height: 100%; }
.pv-node {
  padding: 12px 16px;
  background: rgba(124, 107, 255, 0.12);
  border: 1px solid rgba(124, 107, 255, 0.3);
  border-radius: 8px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: #a597ff;
}
.pv-arrow {
  width: 32px; height: 1px; background: rgba(255, 255, 255, 0.25);
  position: relative;
}
.pv-arrow::after {
  content: ''; position: absolute; right: 0; top: -3px;
  border-left: 6px solid rgba(255, 255, 255, 0.4);
  border-top: 3px solid transparent;
  border-bottom: 3px solid transparent;
}
.pv-wire { display: flex; gap: 10px; height: 100%; }
.pv-wire-side {
  width: 24%;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 6px;
  display: flex; flex-direction: column; gap: 6px;
  padding: 10px;
}
.pv-wire-side-row { height: 6px; background: rgba(255, 255, 255, 0.1); border-radius: 3px; }
.pv-wire-side-row.active { background: rgba(124, 107, 255, 0.6); width: 70%; }
.pv-wire-main {
  flex: 1; background: rgba(255, 255, 255, 0.02); border-radius: 6px; padding: 12px;
  display: flex; flex-direction: column; gap: 7px;
}
.pv-wire-bar { height: 8px; border-radius: 3px; background: rgba(255, 255, 255, 0.08); }
.pv-wire-bar.long { width: 100%; }
.pv-wire-bar.med { width: 70%; }
.pv-wire-bar.short { width: 40%; }
.pv-list { font-family: 'Space Grotesk', sans-serif; }
.pv-list h4 { font-size: 13px; font-weight: 700; color: #fff; margin-bottom: 8px; }
.pv-list ul { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 4px 16px; }
.pv-list li {
  display: flex; align-items: center; gap: 8px;
  font-size: 11px; color: rgba(255, 255, 255, 0.78);
  padding: 6px 6px; border-radius: 5px;
  cursor: pointer;
  transition: background 0.12s;
}
.pv-list li:hover, .pv-list li:active { background: rgba(255, 255, 255, 0.05); }
.pv-chk {
  width: 14px; height: 14px; border-radius: 3px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 10px;
  flex-shrink: 0;
}
.pv-chk.done { background: #4ade80; border-color: #4ade80; color: #0a0b14; font-weight: 700; }
.pv-list li.done { color: rgba(255, 255, 255, 0.4); text-decoration: line-through; }

/* Settings preview — actual rows instead of a wireframe so it reads on mobile */
.pv-settings { display: flex; flex-direction: column; gap: 6px; padding: 2px 0; }
.pv-set-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  min-height: 36px;
}
.pv-set-label { font-family: 'IBM Plex Mono', monospace; font-size: 11px; color: rgba(255, 255, 255, 0.85); }
.pv-set-value { font-family: 'IBM Plex Mono', monospace; font-size: 11px; color: #a597ff; }
.pv-toggle {
  width: 28px; height: 16px; border-radius: 9px;
  background: rgba(255, 255, 255, 0.18);
  position: relative; flex-shrink: 0;
  cursor: pointer;
  transition: background 0.15s;
}
.pv-toggle::after {
  content: ''; position: absolute;
  top: 1.5px; left: 1.5px;
  width: 13px; height: 13px; border-radius: 50%;
  background: #fff;
  transition: transform 0.15s;
}
.pv-toggle.on { background: #4ade80; }
.pv-toggle.on::after { transform: translateX(12px); }

/* Slide-in side panel — preview when hovering a session */
.hm-side {
  position: absolute;
  top: 36px; right: 0; bottom: 0;
  width: 44%;
  padding: 22px 24px;
  background: rgba(20, 21, 40, 0.97);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-left: 1px solid rgba(255, 255, 255, 0.06);
  transform: translateX(102%);
  transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 5;
  pointer-events: none;
  box-shadow: -16px 0 40px rgba(0, 0, 0, 0.4);
  overflow-y: auto;
}
.hero-mock:has(.hm-tile:not(.hm-tile-running):hover) .hm-side,
.hero-mock:has(.hm-mem:hover) .hm-side,
.hero-mock.is-side-open .hm-side { transform: translateX(0); pointer-events: auto; }
/* Back button — pill-shaped, accent-coloured so it reads as the primary action when the drawer is pinned */
.hm-side-back {
  display: none;
  align-items: center;
  gap: 4px;
  background: rgba(124, 107, 255, 0.14);
  border: 1px solid rgba(124, 107, 255, 0.36);
  border-radius: 6px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: #c4b5fd;
  padding: 7px 12px;
  margin-right: 12px;
  cursor: pointer;
  text-transform: uppercase;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.hm-side-back:hover,
.hm-side-back:active { background: rgba(124, 107, 255, 0.22); border-color: rgba(124, 107, 255, 0.55); color: #fff; }
.hero-mock.is-side-open .hm-side-back { display: inline-flex; }
/* Tap-pinned tile/mem gets a clear active marker */
.hm-tile.is-active,
.hm-mem.is-active { background: rgba(124, 107, 255, 0.10); box-shadow: inset 2px 0 0 #a597ff; }
.hm-art-cell.is-active .hm-art { box-shadow: 0 0 0 2px rgba(165, 151, 255, 0.85); }
.hm-mem { transition: background 0.15s ease; }
.hm-mem { cursor: pointer; }
.hm-mem:hover { background: rgba(255, 255, 255, 0.06); }
.hm-status-mem {
  width: 10px; height: 10px; border-radius: 3px;
  background: #a597ff;
  box-shadow: 0 0 8px rgba(165, 151, 255, 0.55);
}
.hm-side-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 6px;
  margin-right: 6px;
}
.hm-side-pill .pip-g { width: 6px; height: 6px; border-radius: 50%; background: #4ade80; box-shadow: 0 0 5px #4ade80; }
.hm-side-pill .pip-d { width: 6px; height: 6px; border-radius: 50%; background: rgba(255, 255, 255, 0.22); }
.hm-side-bigtext {
  font-size: 14px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.92);
  padding: 14px 16px;
  background: rgba(124, 107, 255, 0.06);
  border: 1px solid rgba(124, 107, 255, 0.18);
  border-radius: 8px;
  margin-bottom: 18px;
}
.hm-side-head {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 4px;
}
.hm-side-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 14px; font-weight: 600;
  color: rgba(255, 255, 255, 0.92);
}
.hm-side-meta {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 18px;
}
.hm-side-block { margin-bottom: 16px; }
.hm-side-block-name {
  font-family: 'Barlow', sans-serif;
  font-size: 10px; font-weight: 600;
  color: rgba(255, 255, 255, 0.45);
  text-transform: uppercase; letter-spacing: 1.5px;
  margin-bottom: 8px;
}
.hm-side-line {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.65);
  padding: 3px 0;
}
.hm-side-line.user { color: rgba(255, 255, 255, 0.92); }
.hm-side-line.tool { color: #a597ff; }
.hm-side-file {
  display: flex; gap: 10px; align-items: center;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.7);
  padding: 4px 0;
}
.hm-side-file .add { color: #4ade80; }
.hm-side-file .rm { color: #f87171; }
.hm-side-file-name { flex: 1; }
.hm-side-mem {
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 6px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.45;
  margin-bottom: 6px;
}
.hm-side-arts { display: flex; gap: 6px; flex-wrap: wrap; }
.hm-side-art-chip {
  display: inline-flex; align-items: center;
  padding: 3px 10px;
  border-radius: 9999px;
  background: rgba(124, 107, 255, 0.12);
  border: 1px solid rgba(124, 107, 255, 0.22);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: #a597ff;
}
.hm-side-empty {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.3);
  font-style: italic;
}

@media (max-width: 700px) {
  .hero-mock-body { padding: 16px 16px; }
  .hm-art-grid { grid-template-columns: repeat(5, 1fr); }
  .hm-pill { font-size: 11px; padding: 5px 10px; }
  /* Side panel: hidden by default on mobile, becomes a full-width drawer when tap-opened */
  .hm-side { display: none; }
  .hero-mock.is-side-open .hm-side {
    display: block;
    top: 36px; left: 0; right: 0; bottom: 0;
    width: 100%;
    transform: translateX(0);
    border-left: 0;
    box-shadow: none;
  }
  /* Artefact preview: also full-width on mobile so the body content is readable */
  .hero-mock.is-preview-open .hm-preview {
    left: 0; right: 0; bottom: 0;
    height: 60%;
    border-radius: 10px 10px 0 0;
  }
  /* Preview content: stack horizontal layouts vertically so they fit narrow screens */
  .pv-diag {
    flex-direction: column;
    gap: 8px;
    justify-content: flex-start;
    padding: 8px 0;
  }
  .pv-arrow {
    width: 1px;
    height: 14px;
  }
  .pv-arrow::after {
    right: auto; top: auto;
    left: -3px; bottom: -1px;
    border-left: 3px solid transparent;
    border-right: 3px solid transparent;
    border-top: 6px solid rgba(255, 255, 255, 0.4);
    border-bottom: 0;
  }
  /* Onboarding 4-step grid → 2×2 on mobile */
  .pv-app-grid { grid-template-columns: repeat(2, 1fr); }
  /* Launch checklist → single column on mobile so items have room to breathe */
  .pv-list ul { grid-template-columns: 1fr; gap: 2px; }
  .pv-list li { padding: 9px 8px; font-size: 12px; }
  .pv-chk { width: 16px; height: 16px; font-size: 11px; }
}

/* ------------------------------------------------------------------ */
/* Running-terminals demo — pill, popover, simulated terminal panel.  */
/* Mirrors the in-app RunningTerminalsPill + TerminalWindow surface   */
/* shipped in PR #531.                                                */
/* ------------------------------------------------------------------ */

.hm-rtp-wrap { position: relative; display: inline-flex; }

.hm-rtp-pill {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 6px 12px;
  border-radius: 9999px;
  background: rgba(94, 234, 212, 0.08);
  border: 1px solid rgba(94, 234, 212, 0.28);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: rgba(167, 243, 224, 0.92);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  appearance: none;
}
.hm-rtp-pill:hover,
.hm-rtp-pill[aria-expanded="true"] {
  background: rgba(94, 234, 212, 0.16);
  border-color: rgba(94, 234, 212, 0.5);
  color: #ccfbf1;
}
.hm-rtp-pill .hm-rtp-count {
  color: #5eead4;
  font-variant-numeric: tabular-nums;
}
.hm-rtp-pip {
  width: 7px; height: 7px; border-radius: 50%;
  background: #5eead4;
  box-shadow: 0 0 0 0 rgba(94, 234, 212, 0.6);
  animation: hmRtpPulse 2.4s ease-out infinite;
}
@keyframes hmRtpPulse {
  0%   { box-shadow: 0 0 0 0   rgba(94, 234, 212, 0.55); }
  70%  { box-shadow: 0 0 0 8px rgba(94, 234, 212, 0); }
  100% { box-shadow: 0 0 0 0   rgba(94, 234, 212, 0); }
}
@media (prefers-reduced-motion: reduce) {
  .hm-rtp-pip { animation: none; box-shadow: 0 0 6px rgba(94, 234, 212, 0.55); }
}

.hm-rtp-popover {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  min-width: 280px;
  max-width: min(340px, 92vw);
  background: rgba(14, 15, 30, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55);
  padding: 6px;
  z-index: 7;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  opacity: 0;
  transform: translateY(-4px);
  pointer-events: none;
  transition: opacity 0.14s ease, transform 0.14s ease;
}
/* Invisible bridge so the cursor can cross the gap to the popover without
   triggering mouseleave on the wrap. */
.hm-rtp-popover::before {
  content: '';
  position: absolute;
  left: 0; right: 0;
  top: -10px;
  height: 10px;
}
.hm-rtp-wrap:hover .hm-rtp-popover,
.hm-rtp-wrap:focus-within .hm-rtp-popover,
.hm-rtp-popover.is-pinned {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.hm-rtp-arrow {
  position: absolute;
  top: -5px; left: 24px;
  width: 10px; height: 10px;
  background: rgba(14, 15, 30, 0.98);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  border-left: 1px solid rgba(255, 255, 255, 0.08);
  transform: rotate(45deg);
}

.hm-rtp-row {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 8px 8px 10px;
  border-radius: 8px;
  cursor: pointer;
  border-left: 2px solid #5eead4;
  background: rgba(94, 234, 212, 0.05);
  transition: background 0.15s;
  outline: none;
}
.hm-rtp-row:hover,
.hm-rtp-row:focus-visible { background: rgba(94, 234, 212, 0.12); }

.hm-rtp-dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: #5eead4;
  box-shadow: 0 0 6px rgba(94, 234, 212, 0.6);
  flex-shrink: 0;
}

.hm-rtp-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.hm-rtp-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.92);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.hm-rtp-meta {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.45);
  font-variant-numeric: tabular-nums;
}

/* Simulated terminal panel — same footprint family as .hm-preview */
.hm-terminal {
  position: absolute;
  left: 24px; right: 24px;
  bottom: 110px;
  height: 200px;
  background: #0a0c12;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(0, 0, 0, 0.3);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.22s ease, transform 0.22s ease;
  pointer-events: none;
  z-index: 6;
  overflow: hidden;
}
.hero-mock.is-terminal-open .hm-terminal {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.hm-terminal-chrome {
  display: flex; align-items: center; gap: 6px;
  padding: 7px 12px;
  background: #1d1f27;
  border-bottom: 1px solid rgba(0, 0, 0, 0.5);
}
.hm-term-dot {
  width: 12px; height: 12px; border-radius: 50%;
  appearance: none;
  border: 0.5px solid rgba(0, 0, 0, 0.25);
  padding: 0;
  display: inline-block;
}
.hm-term-dot-r { background: #ff5f57; }
.hm-term-dot-y { background: #febc2e; }
.hm-term-dot-g { background: #28c840; }
.hm-term-dot-r {
  cursor: pointer;
  position: relative;
  transition: filter 0.15s;
}
.hm-term-dot-r:hover { filter: brightness(1.15); }
.hm-term-dot-r:hover::after {
  content: '×';
  position: absolute;
  inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: rgba(0, 0, 0, 0.65);
  line-height: 1;
}
.hm-terminal-title {
  flex: 1;
  min-width: 0;
  padding: 0 10px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.62);
  text-align: center;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  letter-spacing: 0.02em;
}
.hm-terminal-tag {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 9.5px;
  color: rgba(167, 139, 250, 0.72);
  background: rgba(167, 139, 250, 0.1);
  border: 1px solid rgba(167, 139, 250, 0.2);
  border-radius: 4px;
  padding: 2px 6px;
  letter-spacing: 0.04em;
}

.hm-terminal-body {
  padding: 14px 16px 12px;
  height: calc(100% - 33px);
  overflow: hidden;
  font-family: 'IBM Plex Mono', 'SF Mono', Menlo, monospace;
  font-size: 12px;
  line-height: 1.55;
  color: #cfe3e1;
  background:
    radial-gradient(ellipse at top, rgba(94, 234, 212, 0.025), transparent 60%),
    #0a0c12;
}
.hm-term-banner {
  color: rgba(94, 234, 212, 0.55);
  font-size: 11px;
  margin-bottom: 6px;
  letter-spacing: 0.02em;
}
.hm-term-banner .accent { color: #5eead4; }
.hm-term-line {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  opacity: 0;
  transform: translateY(2px);
  animation: hmTermAppear 0.18s ease-out forwards;
}
.hm-term-line.user    { color: #ffffff; }
.hm-term-line.tool    { color: #c4b5fd; }
.hm-term-line.dim     { color: rgba(207, 227, 225, 0.55); padding-left: 18px; }
.hm-term-line.exit    { color: #5eead4; margin-top: 6px; }
.hm-term-line .pfx-user { color: #5eead4; margin-right: 8px; font-weight: 600; }
.hm-term-line .pfx-tool { color: #a78bfa; margin-right: 8px; }
.hm-term-line .pfx-dim  { color: rgba(207, 227, 225, 0.35); margin-right: 6px; margin-left: -18px; }
.hm-term-cursor {
  display: inline-block;
  width: 8px; height: 14px;
  vertical-align: -3px;
  background: #5eead4;
  margin-left: 2px;
  animation: hmTermBlink 1.05s steps(2) infinite;
}
@keyframes hmTermAppear { to { opacity: 1; transform: translateY(0); } }
@keyframes hmTermBlink { 50% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  .hm-term-line { animation: none; opacity: 1; transform: none; }
  .hm-term-cursor { animation: none; }
}

@media (max-width: 700px) {
  .hm-rtp-pill { font-size: 11px; padding: 5px 10px; gap: 6px; }
  .hm-rtp-popover {
    position: fixed;
    top: auto;
    left: 12px; right: 12px;
    bottom: 12px;
    max-width: none;
  }
  .hm-rtp-arrow { display: none; }
  /* Terminal fills the bottom on mobile, matching .hm-preview's mobile treatment */
  .hero-mock.is-terminal-open .hm-terminal {
    left: 0; right: 0; bottom: 0;
    height: 62%;
    border-radius: 10px 10px 0 0;
  }
}
@media (max-width: 420px) {
  /* Drop "running" label and the activity counter; keep the count + dot.
     The popover still works on tap to reveal the rest. */
  .hm-rtp-pill { padding: 5px 9px; font-size: 0; gap: 0; }
  .hm-rtp-pill .hm-rtp-pip { margin-right: 5px; }
  .hm-rtp-pill .hm-rtp-count { font-size: 11px; }
}
