/* ============================================================
   Hermes Logios — INTERFACES chip strip (chips.css)
   ------------------------------------------------------------
   A restrained horizontal strip of interface pills — the
   protocols/standards you speak to talk to the Logios chain.
   Rendered by hermes/chips.js into any <div data-hl-chips> /
   #hl-chips found on the page.

   Visual language matches site.css: cyan #51DCFB on near-black,
   IBM Plex Mono labels, hairline #2F3337 borders, panel #1B1C1D.
   Tokens are inherited from site.css :root when present, with
   local fallbacks so this file is self-sufficient if loaded alone.

   LOAD ORDER: after hermes/site.css (so its tokens are defined).
   ============================================================ */

.hl-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 22px 0 4px;
}

/* small uppercase mono eyebrow on the left */
.hl-chips__label {
  font-family: var(--font-mono, "IBM Plex Mono", monospace);
  font-size: 10.5px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted, #a1a6aa);
  margin-right: 6px;
  white-space: nowrap;
  user-select: none;
}

/* the pill itself */
.hl-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 13px 6px 11px;
  background: var(--panel, #1b1c1d);
  border: 1px solid var(--border, #2f3337);
  border-radius: 999px;
  font-family: var(--font-mono, "IBM Plex Mono", monospace);
  font-size: 12px;
  letter-spacing: 0.04em;
  line-height: 1;
  color: var(--text, #f5f5f5);
  white-space: nowrap;
  transition: border-color 0.18s ease, transform 0.18s ease,
    box-shadow 0.18s ease, color 0.18s ease;
}

.hl-chip__label {
  display: inline-block;
}

/* glyph: ~16px, cyan-tinted, follows currentColor */
.hl-chip svg,
.hl-chip__ico {
  width: 16px;
  height: 16px;
  display: block;
  flex: 0 0 auto;
  color: var(--accent, #51dcfb);
}

.hl-chip svg {
  stroke: currentColor;
  fill: none;
}

/* hover: cyan border, faint glow, subtle lift */
.hl-chip:hover,
.hl-chip:focus-visible {
  border-color: var(--accent, #51dcfb);
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 0 0 1px rgba(81, 220, 251, 0.15),
    0 4px 16px -8px rgba(81, 220, 251, 0.5);
  outline: none;
}

.hl-chip:hover .hl-chip__ico,
.hl-chip:focus-visible .hl-chip__ico {
  color: #8be8ff;
}

/* respect reduced-motion: drop the lift transition + transform */
@media (prefers-reduced-motion: reduce) {
  .hl-chip {
    transition: border-color 0.18s ease, color 0.18s ease;
  }
  .hl-chip:hover,
  .hl-chip:focus-visible {
    transform: none;
  }
}

/* mobile: tighten + let the eyebrow sit on its own line */
@media (max-width: 560px) {
  .hl-chips {
    gap: 8px;
  }
  .hl-chips__label {
    flex-basis: 100%;
    margin-right: 0;
  }
  .hl-chip {
    font-size: 11.5px;
  }
}

/* chips are now links */
.hl-chip{text-decoration:none;cursor:pointer}
.hl-chip:visited{color:inherit}

/* ============================================================
   HOMEPAGE strip — fixed bar just above the bottom quick-nav
   ------------------------------------------------------------
   .hl-chips-home          = full-width fixed flex centerer (no hit area)
   .hl-chips-home__inner   = the dark-glass pill bar (re-uses .hl-chips)
   Quick-nav sits at bottom:16px (~44px tall, z 2147482000); this
   bar floats above it at bottom:64px, one notch lower in stacking.
   ============================================================ */
.hl-chips-home {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 64px;
  z-index: 2147481500;
  display: flex;
  justify-content: center;
  pointer-events: none; /* let clicks pass except on the inner bar */
  padding: 0 16px;
  box-sizing: border-box;
}

/* the dark-glass bar — mirrors .hl-quicknav__inner styling */
.hl-chips-home__inner.hl-chips {
  pointer-events: auto;
  flex-wrap: nowrap;            /* single row; scroll on overflow */
  margin: 0;                    /* override the .hl-chips block margin */
  max-width: 100%;
  padding: 7px 12px;
  gap: 8px;
  background: rgba(13, 13, 13, 0.82);
  border: 1px solid var(--border, #2f3337);
  border-radius: 999px;
  -webkit-backdrop-filter: blur(12px) saturate(120%);
  backdrop-filter: blur(12px) saturate(120%);
  box-shadow: 0 8px 28px -14px rgba(0, 0, 0, 0.7);
  /* horizontal scroll on overflow, no visible scrollbar */
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;        /* Firefox */
  -ms-overflow-style: none;     /* old Edge */
}
.hl-chips-home__inner.hl-chips::-webkit-scrollbar {
  display: none;                /* Chrome/Safari */
}

/* keep the eyebrow + chips from collapsing inside the scroller */
.hl-chips-home__inner.hl-chips .hl-chips__label {
  flex: 0 0 auto;
  margin-right: 2px;
}
.hl-chips-home__inner.hl-chips .hl-chip {
  flex: 0 0 auto;
}

/* ---- entrance animation: bar fades in, chips slide-up in a stagger ---- */
.hl-chips-home {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.45s ease, transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}
.hl-chips-home.is-in {
  opacity: 1;
  transform: translateY(0);
}

.hl-chips-home .hl-chip {
  opacity: 0;
  transform: translateY(8px);
}
.hl-chips-home.is-in .hl-chip {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.4s ease, transform 0.4s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.18s ease, box-shadow 0.18s ease, color 0.18s ease;
  /* per-index stagger set via --i on each chip in home-chips.js */
  transition-delay: calc(120ms + var(--i, 0) * 45ms),
    calc(120ms + var(--i, 0) * 45ms), 0s, 0s, 0s;
}

/* mobile: hide the home strip entirely — quick-nav is the priority,
   two stacked fixed bars is too much on a phone. */
@media (max-width: 640px) {
  .hl-chips-home {
    display: none !important;
  }
}

/* reduced-motion: show everything instantly, no fade/slide/stagger */
@media (prefers-reduced-motion: reduce) {
  .hl-chips-home,
  .hl-chips-home.is-in {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .hl-chips-home .hl-chip,
  .hl-chips-home.is-in .hl-chip {
    opacity: 1;
    transform: none;
    transition: border-color 0.18s ease, color 0.18s ease;
    transition-delay: 0s;
  }
}
