/* ============================================================
   The Harperverse — an SVG star chart over the real site index
   ============================================================ */
.harperverse-page { max-width: 1680px; }
.hv-hero {
  position: relative; overflow: hidden; margin-bottom: 22px; padding: clamp(28px, 5vw, 58px);
  border: 1px solid var(--border-strong); border-radius: 22px;
  background:
    radial-gradient(circle at 12% 28%, rgba(34,229,255,.13), transparent 24%),
    radial-gradient(circle at 82% 22%, rgba(255,94,203,.16), transparent 27%),
    radial-gradient(circle at 58% 90%, rgba(168,85,247,.2), transparent 34%),
    var(--panel);
  box-shadow: var(--glow-purple), inset 0 0 70px rgba(3,0,12,.28);
}
.hv-hero::after {
  content: ''; position: absolute; inset: 0; pointer-events: none; opacity: .34;
  background-image: radial-gradient(circle, rgba(255,255,255,.72) 0 1px, transparent 1.4px);
  background-size: 37px 37px; mask-image: linear-gradient(90deg, transparent, #000 30%, #000);
}
.hv-hero > * { position: relative; z-index: 1; }
.hv-eyebrow, .hv-toolbar-kicker {
  color: var(--cyan); font-size: .7rem; font-weight: 800; letter-spacing: .15em; text-transform: uppercase;
}
.hv-hero h1 { margin: 9px 0 12px; font-size: clamp(2.7rem, 7vw, 5.4rem); letter-spacing: -.045em; overflow-wrap: anywhere; }
.hv-hero p { max-width: 760px; color: var(--text-muted); font-size: clamp(.96rem, 1.7vw, 1.18rem); }
.hv-hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }

.hv-console, .hv-destinations {
  padding: clamp(16px, 2.2vw, 26px); border: 1px solid var(--border); border-radius: 19px;
  background: color-mix(in srgb, var(--panel) 90%, transparent); box-shadow: 0 18px 50px rgba(0,0,0,.2);
}
.hv-toolbar { display: flex; align-items: end; justify-content: space-between; gap: 18px; }
.hv-toolbar h2 { margin-top: 3px; font-size: clamp(1.35rem, 2.6vw, 2rem); }
.hv-search {
  display: flex; align-items: center; gap: 8px; width: min(330px, 100%); padding: 9px 12px;
  border: 1px solid var(--border); border-radius: 12px; color: var(--cyan); background: var(--panel-2);
}
.hv-search:focus-within { border-color: var(--purple-bright); box-shadow: 0 0 0 3px rgba(168,85,247,.12); }
.hv-search input { width: 100%; border: 0; outline: 0; color: var(--text); background: transparent; font: inherit; }
.hv-search input::placeholder { color: var(--text-dim); }
.hv-filters { display: flex; flex-wrap: wrap; gap: 7px; margin: 18px 0; }
.hv-filter {
  padding: 7px 11px; border: 1px solid var(--border); border-radius: 999px;
  color: var(--text-muted); background: rgba(255,255,255,.025); font: 700 .73rem/1 var(--font); cursor: pointer;
}
.hv-filter:hover { color: var(--text); border-color: var(--border-strong); }
.hv-filter.is-active { color: #fff; border-color: transparent; background: var(--grad-brand); box-shadow: var(--glow-purple); }

.hv-map-layout { display: grid; grid-template-columns: minmax(0, 1fr) 270px; gap: 16px; }
.hv-map-frame {
  position: relative; min-width: 0; overflow: hidden; border: 1px solid var(--border); border-radius: 16px;
  background:
    linear-gradient(rgba(168,85,247,.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(168,85,247,.025) 1px, transparent 1px),
    radial-gradient(circle at center, color-mix(in srgb, var(--bg-2) 82%, #13022c), var(--bg) 75%);
  background-size: 32px 32px, 32px 32px, auto;
}
.hv-map { display: block; width: 100%; min-height: 560px; }
.hv-cluster-halo { fill: var(--hv-color); opacity: .055; stroke: var(--hv-color); stroke-width: 1; stroke-dasharray: 4 11; }
.hv-cluster-core { fill: var(--hv-color); opacity: .24; }
.hv-cluster-label {
  fill: var(--hv-color); font: 800 15px/1 var(--font); letter-spacing: 2px; text-anchor: middle;
  paint-order: stroke; stroke: var(--bg); stroke-width: 5px; stroke-linejoin: round;
}
.hv-orbit { stroke: var(--hv-color); stroke-width: 1; opacity: .15; }
.hv-star { color: var(--hv-color); }
.hv-star .star-hit { fill: transparent; }
.hv-star .star-glow { fill: var(--hv-color); opacity: 0; }
.hv-star .star-core { fill: var(--bg); stroke: var(--hv-color); stroke-width: 2.2; }
.hv-star .star-label {
  fill: var(--text); opacity: 0; pointer-events: none; font: 700 12px/1 var(--font);
  paint-order: stroke; stroke: var(--bg); stroke-width: 4px; stroke-linejoin: round;
}
.hv-star.is-hub .star-core { fill: var(--hv-color); stroke: #fff; stroke-width: 2.5; }
.hv-star.is-hub .star-label, .hv-star:hover .star-label, .hv-star:focus .star-label,
.hv-star.is-selected .star-label { opacity: 1; }
.hv-star.is-visited .star-core { fill: var(--green); stroke: #d9fff0; }
.hv-star.is-visited .star-glow { opacity: .22; }
.hv-star:hover .star-glow, .hv-star:focus .star-glow, .hv-star.is-selected .star-glow { opacity: .5; }
.hv-star:hover .star-core, .hv-star:focus .star-core, .hv-star.is-selected .star-core { fill: var(--hv-color); stroke: #fff; }
.hv-star:focus { outline: none; }
.hv-star.is-hidden, .hv-orbit.is-hidden, .hv-cluster.is-hidden { display: none; }
.hv-map-key {
  position: absolute; left: 12px; bottom: 10px; display: flex; flex-wrap: wrap; gap: 11px;
  color: var(--text-dim); font-size: .68rem; pointer-events: none;
}
.hv-map-key span { display: flex; align-items: center; gap: 5px; }
.hv-map-key i { width: 9px; height: 9px; border: 1px solid var(--purple-bright); border-radius: 50%; background: var(--bg); }
.hv-map-key i.known { border-color: #d9fff0; background: var(--green); box-shadow: 0 0 8px var(--green); }
.hv-map-key i.hub { border-color: #fff; background: var(--purple-bright); }

.hv-readout {
  min-height: 330px; padding: 18px; border: 1px solid var(--border); border-radius: 15px;
  background: linear-gradient(160deg, var(--panel-2), rgba(4,2,10,.22));
}
.hv-readout-signal { color: var(--green); font: 800 .64rem/1 var(--font); letter-spacing: .13em; }
.hv-readout-ico { margin: 24px 0 13px; font-size: 2.5rem; filter: drop-shadow(0 0 14px var(--purple-bright)); }
.hv-readout h2 { margin-bottom: 9px; font-size: 1.35rem; }
.hv-readout p { color: var(--text-muted); font-size: .84rem; line-height: 1.55; }
.hv-readout-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 15px; }
.hv-readout-tags span { padding: 4px 7px; border: 1px solid var(--border); border-radius: 6px; color: var(--text-dim); font-size: .64rem; }
.hv-readout-link { display: inline-flex; margin-top: 18px; color: var(--cyan); font-size: .82rem; font-weight: 800; }

.hv-destinations { margin-top: 20px; }
.hv-destination-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 9px; margin-top: 15px; }
.hv-destination {
  display: grid; grid-template-columns: 34px 1fr auto; align-items: center; gap: 9px; min-width: 0;
  padding: 11px; border: 1px solid var(--border); border-radius: 11px; background: rgba(255,255,255,.02);
}
.hv-destination:hover { border-color: var(--border-strong); background: var(--panel-2); transform: translateY(-1px); }
.hv-destination .ico { font-size: 1.2rem; }
.hv-destination strong { display: block; overflow: hidden; color: var(--text); font-size: .77rem; text-overflow: ellipsis; white-space: nowrap; }
.hv-destination small { display: block; color: var(--text-dim); font-size: .64rem; }
.hv-destination .arrow { color: var(--purple-bright); }
.hv-destination.is-visited small { color: var(--green); }
.hv-empty { grid-column: 1/-1; padding: 34px; color: var(--text-muted); text-align: center; }

@media (prefers-reduced-motion: no-preference) {
  .hv-cluster-halo { animation: hv-orbit 24s linear infinite; transform-box: fill-box; transform-origin: center; }
  .hv-star .star-glow { animation: hv-pulse 3.4s ease-in-out infinite; }
  @keyframes hv-orbit { to { transform: rotate(360deg); } }
  @keyframes hv-pulse { 50% { opacity: .32; } }
}
html[data-signal="quiet"] .hv-cluster-halo { stroke-dasharray: none; opacity: .035; }
html[data-signal="feral"] .hv-map-frame { box-shadow: inset 0 0 45px rgba(132,255,55,.1), inset 0 0 90px rgba(255,25,159,.1); }

@media (max-width: 1050px) {
  .hv-map-layout { grid-template-columns: 1fr; }
  .hv-readout { min-height: 0; }
  .hv-readout-ico { float: left; margin: 4px 14px 8px 0; }
  .hv-destination-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 720px) {
  .hv-hero { padding: 24px 19px; }
  .hv-hero h1 { font-size: clamp(2rem, 10.5vw, 2.55rem); }
  .hv-toolbar { align-items: stretch; flex-direction: column; }
  .hv-search { width: 100%; }
  .hv-map { min-height: 430px; }
  .hv-destination-grid { grid-template-columns: 1fr; }
  .hv-map-key { display: none; }
}
