/* views-audio-map.css — V9 phase 1 "Audio Map" monitor tab (flag audio_map).
   Read-only RF → Dante/AES67 → console chain view (js/views/audio-map.js).
   Uses the design tokens in tokens.css; every rule is scoped under .amap so it
   cannot leak into other tabs. Badges reuse components.css .badge-* variants
   (reported=ok, discovered=up, suggested=warn, manual/stale=neutral); the
   modifiers below only add what a variant does not carry. */

.amap { min-width: 0; background: var(--mon-1); display: flex; flex-direction: column; min-height: 100%; }

/* ===== header ===== */
.amap .amap-head { padding: 12px 16px 10px; border-bottom: 1px solid var(--border); }
.amap .amap-head-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.amap .amap-title { margin: 0; font-size: 15px; font-weight: 600; color: var(--text-1); }
.amap .amap-count {
  display: inline-flex; align-items: center; height: 22px; padding: 0 9px;
  border-radius: var(--r-pill); background: var(--bg-2); border: 1px solid var(--border);
  font-size: 11.5px; color: var(--text-2);
}
.amap .amap-count-review { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 45%, transparent); }
.amap .amap-fresh { font-size: 12px; color: var(--text-muted); }
.amap .amap-fresh.is-stale { color: var(--warn); }
.amap .amap-spacer { flex: 1 1 auto; }
.amap .amap-note { margin: 8px 0 0; font-size: 12px; color: var(--text-2); }
.amap .mono { font-family: var(--font-mono); }
.amap .faint { color: var(--text-muted); }

/* ===== body ===== */
.amap .amap-body { padding: 12px 16px 24px; display: flex; flex-direction: column; gap: 12px; }

/* nudges — a notice that points to the vendor tool, never an action */
.amap .amap-nudges { display: flex; flex-direction: column; gap: 8px; }
.amap .amap-nudge {
  display: flex; align-items: flex-start; gap: 10px; padding: 10px 12px;
  border-radius: var(--r-md); border: 1px solid color-mix(in srgb, var(--accent) 40%, transparent);
  background: var(--accent-soft); color: var(--text-1); font-size: 12.5px; line-height: 1.45;
}
.amap .amap-nudge-icon {
  flex: none; width: 18px; height: 18px; border-radius: 50%; display: inline-flex;
  align-items: center; justify-content: center; font: 600 11px/1 var(--font-mono);
  background: var(--accent); color: #fff;
}

/* chains */
.amap .amap-chains { display: flex; flex-direction: column; gap: 10px; }
.amap .amap-chain {
  border: 1px solid var(--border); border-radius: var(--r-md); background: var(--bg-card);
  padding: 10px 12px 12px; min-width: 0;
}
/* A suggestion never looks confirmed: dashed amber frame + tinted background. */
.amap .amap-chain.is-suggested {
  border: 1px dashed var(--warn);
  background: linear-gradient(90deg, var(--warn-dim), var(--bg-card) 60%);
}
.amap .amap-chain.is-stale { opacity: .78; }
.amap .amap-chain.is-stale .amap-hop-main { color: var(--text-2); }
.amap .amap-chain-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.amap .amap-seen { font-size: 11.5px; color: var(--text-muted); font-family: var(--font-mono); }
.amap .amap-seen.is-stale { color: var(--warn); }
.amap .amap-pending-note { font-size: 11.5px; color: var(--warn); }
.amap .amap-actions { display: inline-flex; gap: 6px; }

/* badge modifiers */
.amap .amap-badge { cursor: default; }
.amap .amap-badge-assumed { background: transparent; border: 1px dashed var(--warn); color: var(--warn); }
.amap .amap-badge-stale { border: 1px solid var(--border-strong); }

/* hops: marker → rx → tx → rx/console (stack under 760px) */
.amap .amap-hops {
  display: grid; align-items: stretch; gap: 6px;
  grid-template-columns: minmax(0, 1fr) 16px minmax(0, 1fr) 16px minmax(0, 1fr) 16px minmax(0, 1fr);
}
.amap .amap-hop {
  min-width: 0; padding: 8px 10px; border-radius: var(--r-sm);
  background: var(--bg-2); border: 1px solid var(--border-subtle);
  display: flex; flex-direction: column; gap: 2px;
}
.amap .amap-hop.is-missing { background: transparent; border: 1px dashed var(--border); }
.amap .amap-hop-title {
  font-size: 10.5px; letter-spacing: .07em; text-transform: uppercase; color: var(--text-muted);
  font-weight: 600; margin-bottom: 2px;
}
.amap .amap-hop-main { font-size: 13px; color: var(--text-1); overflow-wrap: anywhere; }
.amap .amap-hop-sub { font-size: 11.5px; color: var(--text-2); overflow-wrap: anywhere; }
.amap .amap-missing { color: var(--text-muted); font-style: italic; }
.amap .amap-subitem + .amap-subitem { margin-top: 6px; padding-top: 6px; border-top: 1px solid var(--border-subtle); }
.amap .amap-arrow { align-self: center; justify-self: center; color: var(--text-faint); font-size: 14px; }

/* discovered, not linked */
.amap .amap-unlinked { border: 1px solid var(--border); border-radius: var(--r-md); background: var(--bg-1); }
.amap .amap-unlinked-sum {
  cursor: pointer; padding: 10px 12px; font-size: 12px; font-weight: 600; color: var(--text-2);
  letter-spacing: .02em;
}
.amap .amap-unlinked-list { list-style: none; margin: 0; padding: 0 12px 10px; display: flex; flex-direction: column; gap: 6px; }
.amap .amap-unlinked-row {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 7px 10px;
  border-radius: var(--r-sm); background: var(--bg-2); font-size: 12px;
}
.amap .amap-u-dev { color: var(--text-1); font-weight: 500; }
.amap .amap-u-meta { color: var(--text-2); font-size: 11.5px; }

.amap .amap-empty { border: 1px dashed var(--border); border-radius: var(--r-md); }

@media (max-width: 760px) {
  .amap .amap-head { padding: 10px 12px 8px; }
  .amap .amap-body { padding: 10px 12px 20px; }
  .amap .amap-hops { grid-template-columns: minmax(0, 1fr); }
  .amap .amap-arrow { transform: rotate(90deg); line-height: 1; }
  .amap .amap-actions { width: 100%; }
  .amap .amap-actions .btn { flex: 1 1 0; min-height: var(--tap-min); }
}
