/* git.bungee.systems front page. The hero is the bungee.systems instrument (fluid ink, hex lattice, reticle rings, kinetic
   Archivo letters) cut down to one band; below it, the live list of active repositories. */
.bs-home {
  --ink: #06080d; --light: #f2f4f8; --mist: #8a90a0; --cyan: #39d2ff;
  --line: rgba(57, 210, 255, .16); --line-strong: rgba(57, 210, 255, .5);
  font-family: "Archivo", "Helvetica Neue", Arial, sans-serif; color: var(--light);
  padding: 0 !important; margin: 0 !important;
}
.page-content.bs-home > .bh-hero:first-child { margin-top: 0; }
.bs-home ::selection { background: var(--light); color: var(--ink); }

/* ---------------------------------------------------------------------------------------------------- hero */
.bh-hero {
  position: relative; isolation: isolate; overflow: hidden; display: grid; place-items: center;
  min-height: clamp(520px, 80vh, 820px); background: var(--ink); border-bottom: 1px solid var(--line);
}
.bh-fluid { position: absolute; inset: 0; width: 100%; height: 100%; display: block; z-index: 0; touch-action: pan-y; }
.bh-plain .bh-fluid { display: none; }
.bh-plain .bh-hero::before { content: ""; position: absolute; inset: 0; z-index: 0; background: radial-gradient(ellipse 52% 44% at 50% 50%, rgba(92, 120, 209, .16), transparent 70%); }

.bh-rings { position: absolute; left: 50%; top: 50%; width: min(112vmin, 1080px); height: min(112vmin, 1080px); transform: translate(-50%, -50%); z-index: 1; pointer-events: none; opacity: .85; }
.bh-rings circle { fill: none; stroke: var(--cyan); stroke-width: .7; transform-origin: 0 0; vector-effect: non-scaling-stroke; }
.bh-rings .r1 { stroke-dasharray: 60 24 6 24; stroke-opacity: .35; animation: bh-spin 48s linear infinite; }
.bh-rings .r2 { stroke-dasharray: 1 5; stroke-opacity: .5; animation: bh-spin 90s linear infinite reverse; }
.bh-rings .r3 { stroke-dasharray: 120 180; stroke-opacity: .22; stroke-width: 1.2; animation: bh-spin 30s linear infinite reverse; }
.bh-rings .r4 { stroke-dasharray: 2 10; stroke-opacity: .25; animation: bh-spin 140s linear infinite; }
@keyframes bh-spin { to { transform: rotate(360deg); } }

.bh-centre { position: relative; z-index: 2; display: grid; justify-items: center; text-align: center; padding: 48px 16px; }

/* the name: real text, letters that decode, spring in and stretch towards the hand */
.bh-name {
  position: relative; margin: 0 !important; padding: .22em .36em .16em; overflow: visible;
  font-family: inherit !important; font-weight: 700; letter-spacing: -0.02em; line-height: 1; white-space: nowrap;
  font-size: clamp(2.2rem, 9.5vw, 8.5rem) !important; color: var(--light); cursor: default; font-stretch: 78%;
  text-shadow: 0 2px 24px rgba(5, 8, 20, .6), 0 0 28px rgba(57, 210, 255, .18);
}
.bh-name .l {
  display: inline-block; width: var(--slot, auto); text-align: center; font-stretch: var(--w, 78%);
  transform: translateY(var(--lift, 0));
  transition: font-stretch .55s cubic-bezier(.22, 1.6, .36, 1), transform .55s cubic-bezier(.22, 1.6, .36, 1);
}
.bh-name:not(.in) .l { transform: translateY(115%); font-stretch: 62%; transition: none; }
.bh-name.in .l { animation: bh-rise 1.1s cubic-bezier(.2, 1.35, .3, 1) both; animation-delay: var(--d, 0s); }
.bh-name .l[data-dot="true"] { color: var(--cyan); text-shadow: 0 0 18px rgba(57, 210, 255, .8); }
.bh-name .l.live { color: var(--cyan); opacity: .75; }
.bh-name.locked .l { animation: bh-split 7s steps(1, end) infinite; }
.bh-name.locked .l[data-dot="true"] { animation: none; }
.bh-name .frame { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.bh-name .frame path { fill: none; stroke: var(--cyan); stroke-width: 1.25; stroke-dasharray: 100; stroke-dashoffset: 100; opacity: 0; }
.bh-name.locked .frame path { animation: bh-draw .9s cubic-bezier(.2, .8, .2, 1) .1s forwards; }
.bh-name .rail { position: absolute; left: .36em; right: .36em; bottom: .02em; height: 6px; pointer-events: none; opacity: 0;
  background: repeating-linear-gradient(90deg, rgba(57, 210, 255, .45) 0 1px, transparent 1px 12px) bottom / 100% 3px no-repeat, linear-gradient(rgba(57, 210, 255, .35), rgba(57, 210, 255, .35)) bottom / 100% 1px no-repeat; }
.bh-name.locked .rail { opacity: 1; transition: opacity .6s .6s; }
.bh-name .rail i { position: absolute; bottom: -2px; width: 2px; height: 10px; margin-left: -1px; background: var(--cyan); box-shadow: 0 0 10px var(--cyan); left: var(--rail, 50%); transition: left .18s cubic-bezier(.2, .8, .2, 1); }
.bh-name .probe { position: absolute; left: 0; top: 0; visibility: hidden; white-space: pre; font-stretch: 78%; pointer-events: none; }

.bh-actions { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 12px 14px; margin-top: 2.2rem; animation: bh-fade .9s cubic-bezier(.2, .8, .2, 1) 1.5s both; }
.bh-btn {
  position: relative; display: inline-flex; align-items: center; min-height: 44px; padding: 0 22px;
  font-size: 1rem; font-weight: 600; font-stretch: 90%; letter-spacing: .01em; color: var(--light) !important;
  background: rgba(6, 8, 13, .55); border: 1px solid var(--line-strong); border-radius: 0;
  transition: background-color .2s, border-color .2s, color .2s, box-shadow .2s;
}
.bh-btn:hover, .bh-btn:focus-visible { background: rgba(57, 210, 255, .1); border-color: var(--cyan); box-shadow: 0 0 22px rgba(57, 210, 255, .25); text-decoration: none; }
.bh-btn-primary { background: var(--cyan); border-color: var(--cyan); color: var(--ink) !important; }
.bh-btn-primary:hover, .bh-btn-primary:focus-visible { background: #6bdeff; border-color: #6bdeff; color: var(--ink) !important; }
.bh-link { padding: 10px 4px; font-size: 1rem; color: var(--mist) !important; text-decoration: underline; text-decoration-color: rgba(138, 144, 160, .5); text-underline-offset: 4px; transition: color .2s, text-decoration-color .2s; }
.bh-link:hover, .bh-link:focus-visible { color: var(--light) !important; text-decoration-color: var(--cyan); }
.bs-home a:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; }

/* ---------------------------------------------------------------------------------------------- repositories */
.bh-repos { max-width: 1180px; margin: 0 auto; padding: 56px 16px 72px; }
.bh-repos-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.bh-repos-head h2 { margin: 0 !important; font-family: inherit !important; font-size: clamp(1.35rem, 2.4vw, 1.75rem) !important; font-weight: 700; font-stretch: 82%; letter-spacing: -0.01em; color: var(--light); }
.bh-count { margin-left: .35em; font-weight: 600; font-stretch: 100%; color: var(--cyan); font-variant-numeric: tabular-nums; }
.bh-more { flex: none; font-size: .95rem; color: var(--mist) !important; text-decoration: underline; text-decoration-color: rgba(138, 144, 160, .5); text-underline-offset: 4px; }
.bh-more:hover { color: var(--light) !important; text-decoration-color: var(--cyan); }

.bh-grid { list-style: none; margin: 24px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr)); gap: 16px; }
.bh-card { position: relative; min-width: 0; }
.bh-card a {
  position: relative; display: flex; flex-direction: column; gap: 10px; height: 100%; padding: 20px 20px 18px;
  color: var(--light) !important; text-decoration: none !important; background: #0b0f17; border: 1px solid var(--line);
  transition: border-color .2s, background-color .2s, transform .25s cubic-bezier(.2, .8, .2, 1);
  animation: bh-fade .6s cubic-bezier(.2, .8, .2, 1) both; animation-delay: var(--d, 0s);
}
/* corner brackets, drawn on hover the way the name's frame draws in */
.bh-card a::before, .bh-card a::after { content: ""; position: absolute; width: 14px; height: 14px; border: 0 solid var(--cyan); opacity: 0; transition: opacity .2s, transform .25s cubic-bezier(.2, .8, .2, 1); pointer-events: none; }
.bh-card a::before { top: -1px; left: -1px; border-top-width: 2px; border-left-width: 2px; transform: translate(4px, 4px); }
.bh-card a::after { bottom: -1px; right: -1px; border-bottom-width: 2px; border-right-width: 2px; transform: translate(-4px, -4px); }
.bh-card a:hover, .bh-card a:focus-visible { border-color: rgba(57, 210, 255, .38); background: #0e1420; transform: translateY(-2px); }
.bh-card a:hover::before, .bh-card a:hover::after, .bh-card a:focus-visible::before, .bh-card a:focus-visible::after { opacity: 1; transform: none; }
.bh-card-name { font-size: 1.15rem; font-weight: 700; font-stretch: 86%; letter-spacing: -0.005em; overflow-wrap: anywhere; }
.bh-card-desc { margin: 0; font-size: .95rem; line-height: 1.45; color: var(--mist); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.bh-card-meta { margin-top: auto; padding-top: 6px; display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: .85rem; color: var(--mist); font-variant-numeric: tabular-nums; }
.bh-lang { display: inline-flex; align-items: center; gap: 7px; color: var(--light); }
.bh-lang::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 8px rgba(57, 210, 255, .7); }
.bh-archived { margin: 28px 0 0; font-size: .95rem; }
.bh-archived a { color: var(--mist) !important; text-decoration: underline; text-decoration-color: rgba(138, 144, 160, .5); text-underline-offset: 4px; }
.bh-archived a:hover { color: var(--light) !important; text-decoration-color: var(--cyan); }
.bh-empty { grid-column: 1 / -1; color: var(--mist); }

@keyframes bh-rise {
  0% { transform: translateY(115%); font-stretch: 62%; opacity: 0; }
  40% { opacity: 1; }
  100% { transform: translateY(var(--lift, 0)); font-stretch: var(--w, 78%); opacity: 1; }
}
@keyframes bh-split {
  0%, 95.5% { text-shadow: 0 2px 24px rgba(5, 8, 20, .6), 0 0 28px rgba(57, 210, 255, .18); transform: translateY(var(--lift, 0)); }
  96% { text-shadow: -3px 0 0 rgba(57, 210, 255, .9), 3px 0 0 rgba(20, 70, 255, .9); transform: translate(2px, var(--lift, 0)); }
  97% { text-shadow: 3px 0 0 rgba(57, 210, 255, .9), -3px 0 0 rgba(20, 70, 255, .9); transform: translate(-2px, var(--lift, 0)); }
  97.6%, 100% { text-shadow: 0 2px 24px rgba(5, 8, 20, .6), 0 0 28px rgba(57, 210, 255, .18); transform: translateY(var(--lift, 0)); }
}
@keyframes bh-draw { 0% { stroke-dashoffset: 100; opacity: .9; } 100% { stroke-dashoffset: 0; opacity: .55; } }
@keyframes bh-fade { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

@media (max-width: 640px) {
  .bh-name { font-size: clamp(2.2rem, 12vw, 5rem) !important; }
  .bh-hero { min-height: clamp(480px, 78svh, 680px); }
  .bh-repos { padding-top: 40px; }
  .bh-repos-head { flex-direction: column; gap: 6px; }
}
@media (prefers-reduced-motion: reduce) {
  .bh-name .l, .bh-name.in .l, .bh-name.locked .l { animation: none; transition: none; transform: none; font-stretch: 78%; }
  .bh-rings circle, .bh-actions, .bh-card a { animation: none; }
  .bh-name.locked .frame path { animation: none; stroke-dashoffset: 0; opacity: .55; }
  .bh-card a { transition: none; }
}
