{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "bg-beacon-rings",
  "type": "registry:component",
  "title": "Beacon Rings",
  "description": "Segmented rings that launch from a pulsing core and rotate as they expand, over faint guide circles and a crosshair. Each launch kicks the core.",
  "author": "Hyperblur <hello@hyperblur.dev>",
  "dependencies": [],
  "registryDependencies": [],
  "categories": [
    "overlay",
    "background",
    "rings",
    "ripple",
    "pulse",
    "css",
    "signal"
  ],
  "docs": "https://hyperblur.dev/effects/bg-beacon-rings",
  "files": [
    {
      "path": "registry/hyperblur/bg-beacon-rings.tsx",
      "type": "registry:component",
      "target": "components/hyperblur/bg-beacon-rings.tsx",
      "content": "\"use client\";\n\nimport * as React from \"react\";\n\nexport interface BgBeaconRingsProps extends React.HTMLAttributes<HTMLDivElement> {\n  color?: string;\n  accent?: string;\n  background?: string;\n  rings?: number;\n  x?: number;\n  y?: number;\n  speed?: number;\n  children?: React.ReactNode;\n}\n\nconst css = `\n.hb-vd8 { position: absolute; inset: 0; overflow: hidden; pointer-events: none; box-sizing: border-box; background: radial-gradient(70% 70% at var(--hb-vd8-x) var(--hb-vd8-y), color-mix(in srgb, var(--hb-vd8-a) 16%, var(--hb-vd8-bg)) 0%, var(--hb-vd8-bg) 70%); container-type: size; }\n.hb-vd8 *, .hb-vd8 *::before, .hb-vd8 *::after { box-sizing: border-box; }\n.hb-vd8-guide, .hb-vd8-ring { position: absolute; left: var(--hb-vd8-x); top: var(--hb-vd8-y); aspect-ratio: 1; translate: -50% -50%; }\n.hb-vd8-guide { width: var(--s); border-radius: 50%; border: 1px solid color-mix(in srgb, var(--hb-vd8-c) 9%, transparent); }\n.hb-vd8-ring { width: 150cqmax; opacity: 0; animation: hb-vd8-grow calc(var(--d) * var(--hb-vd8-k)) cubic-bezier(0.22, 0.61, 0.36, 1) infinite; animation-delay: var(--dl); }\n.hb-vd8-ring svg { width: 100%; height: 100%; display: block; overflow: visible; }\n.hb-vd8-cross { position: absolute; left: var(--hb-vd8-x); top: var(--hb-vd8-y); width: 46cqmin; height: 46cqmin; translate: -50% -50%; background: linear-gradient(90deg, transparent calc(50% - 0.5px), color-mix(in srgb, var(--hb-vd8-c) 16%, transparent) calc(50% - 0.5px), color-mix(in srgb, var(--hb-vd8-c) 16%, transparent) calc(50% + 0.5px), transparent calc(50% + 0.5px)), linear-gradient(0deg, transparent calc(50% - 0.5px), color-mix(in srgb, var(--hb-vd8-c) 16%, transparent) calc(50% - 0.5px), color-mix(in srgb, var(--hb-vd8-c) 16%, transparent) calc(50% + 0.5px), transparent calc(50% + 0.5px)); -webkit-mask-image: radial-gradient(closest-side, #000 20%, transparent); mask-image: radial-gradient(closest-side, #000 20%, transparent); }\n.hb-vd8-core { position: absolute; left: var(--hb-vd8-x); top: var(--hb-vd8-y); width: 9px; height: 9px; translate: -50% -50%; border-radius: 50%; background: #fff; box-shadow: 0 0 0 3px color-mix(in srgb, var(--hb-vd8-a) 40%, transparent), 0 0 18px 4px var(--hb-vd8-a), 0 0 60px 14px color-mix(in srgb, var(--hb-vd8-a) 45%, transparent); animation: hb-vd8-pulse calc(var(--hb-vd8-p) * var(--hb-vd8-k)) cubic-bezier(0.3, 0, 0.2, 1) infinite; }\n.hb-vd8-in { position: relative; z-index: 1; width: 100%; height: 100%; pointer-events: auto; font-family: inherit; }\n@keyframes hb-vd8-grow {\n  0% { transform: scale(0.015) rotate(0deg); opacity: 0; }\n  6% { opacity: 1; }\n  70% { opacity: 0.35; }\n  100% { transform: scale(1) rotate(var(--rot)); opacity: 0; }\n}\n@keyframes hb-vd8-pulse {\n  0%, 100% { transform: scale(1); }\n  8% { transform: scale(1.5); }\n  30% { transform: scale(0.92); }\n}\n@media (prefers-reduced-motion: reduce) {\n  .hb-vd8-ring { animation: none; opacity: var(--ro); transform: scale(var(--rs)); }\n  .hb-vd8-core { animation: none; }\n}\n`;\n\nconst styles = [\n  { dash: \"none\", width: 1.2 },\n  { dash: \"3 5\", width: 1.4 },\n  { dash: \"46 10 8 10\", width: 1.1 },\n  { dash: \"0.8 4.2\", width: 5 },\n  { dash: \"90 30\", width: 2 },\n  { dash: \"1.5 2.5\", width: 1 },\n];\n\nexport function BgBeaconRings({\n  color = \"#7fb3ff\",\n  accent = \"#2f7bff\",\n  background = \"#04060b\",\n  rings = 6,\n  x = 50,\n  y = 50,\n  speed = 1,\n  children,\n  className = \"\",\n  style,\n  ...rest\n}: BgBeaconRingsProps) {\n  const n = Math.max(2, Math.min(12, Math.round(rings)));\n  const period = 9;\n  const list = Array.from({ length: n }, (_, i) => {\n    const st = styles[i % styles.length];\n    const rot = (i % 2 ? -1 : 1) * (40 + ((i * 37) % 70));\n    return {\n      ...st,\n      rot,\n      dl: -((i * period) / n),\n      rs: ((i + 1) / (n + 1)).toFixed(3),\n      ro: (0.55 - (0.4 * (i + 1)) / (n + 1)).toFixed(3),\n    };\n  });\n\n  return (\n    <div\n      className={`hb-vd8 ${className}`}\n      style={\n        {\n          \"--hb-vd8-bg\": background,\n          \"--hb-vd8-a\": accent,\n          \"--hb-vd8-c\": color,\n          \"--hb-vd8-x\": `${x}%`,\n          \"--hb-vd8-y\": `${y}%`,\n          \"--hb-vd8-p\": `${(period / n).toFixed(3)}s`,\n          \"--hb-vd8-k\": (1 / Math.max(0.05, speed)).toFixed(3),\n          ...style,\n        } as React.CSSProperties\n      }\n      {...rest}\n    >\n      <style href=\"hb-bg-beacon-rings\" precedence=\"default\">{css}</style>\n      <span className=\"hb-vd8-guide\" aria-hidden=\"true\" style={{ \"--s\": \"22cqmin\" } as React.CSSProperties} />\n      <span className=\"hb-vd8-guide\" aria-hidden=\"true\" style={{ \"--s\": \"48cqmin\" } as React.CSSProperties} />\n      <span className=\"hb-vd8-guide\" aria-hidden=\"true\" style={{ \"--s\": \"82cqmin\" } as React.CSSProperties} />\n      <span className=\"hb-vd8-cross\" aria-hidden=\"true\" />\n      {list.map((r, i) => (\n        <span\n          key={i}\n          className=\"hb-vd8-ring\"\n          aria-hidden=\"true\"\n          style={{ \"--d\": `${period}s`, \"--dl\": `${r.dl.toFixed(3)}s`, \"--rot\": `${r.rot}deg`, \"--rs\": r.rs, \"--ro\": r.ro } as React.CSSProperties}\n        >\n          <svg viewBox=\"0 0 100 100\">\n            <circle\n              cx=\"50\"\n              cy=\"50\"\n              r=\"49.5\"\n              fill=\"none\"\n              stroke={i % 3 === 0 ? accent : color}\n              strokeWidth={r.width}\n              strokeDasharray={r.dash}\n              pathLength={360}\n              vectorEffect=\"non-scaling-stroke\"\n            />\n          </svg>\n        </span>\n      ))}\n      <span className=\"hb-vd8-core\" aria-hidden=\"true\" />\n      {children ? <div className=\"hb-vd8-in\">{children}</div> : null}\n    </div>\n  );\n}\n"
    }
  ]
}