/* Lucide-style line icons, hand-rolled to avoid a runtime icon dependency. */

const SvgBase = ({ children, size = 18, stroke = 1.6, className = '', ...rest }) => (
  <svg
    xmlns="http://www.w3.org/2000/svg"
    width={size}
    height={size}
    viewBox="0 0 24 24"
    fill="none"
    stroke="currentColor"
    strokeWidth={stroke}
    strokeLinecap="round"
    strokeLinejoin="round"
    className={className}
    aria-hidden="true"
    {...rest}
  >
    {children}
  </svg>
);

const IconSearch = (p) => (<SvgBase {...p}><circle cx="11" cy="11" r="7" /><path d="m20 20-3.5-3.5" /></SvgBase>);
const IconChevronDown = (p) => (<SvgBase {...p}><path d="m6 9 6 6 6-6" /></SvgBase>);
const IconChevronRight = (p) => (<SvgBase {...p}><path d="m9 6 6 6-6 6" /></SvgBase>);
const IconChevronLeft = (p) => (<SvgBase {...p}><path d="m15 6-6 6 6 6" /></SvgBase>);
const IconArrowRight = (p) => (<SvgBase {...p}><path d="M5 12h14" /><path d="m12 5 7 7-7 7" /></SvgBase>);
const IconArrowUpRight = (p) => (<SvgBase {...p}><path d="M7 17 17 7" /><path d="M8 7h9v9" /></SvgBase>);
const IconSun = (p) => (<SvgBase {...p}><circle cx="12" cy="12" r="4" /><path d="M12 2v2M12 20v2M4.93 4.93l1.41 1.41M17.66 17.66l1.41 1.41M2 12h2M20 12h2M4.93 19.07l1.41-1.41M17.66 6.34l1.41-1.41" /></SvgBase>);
const IconMoon = (p) => (<SvgBase {...p}><path d="M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z" /></SvgBase>);
const IconBolt = (p) => (<SvgBase {...p}><path d="M13 3 4 14h7l-1 7 9-11h-7l1-7z" /></SvgBase>);
const IconGlobe = (p) => (<SvgBase {...p}><circle cx="12" cy="12" r="9" /><path d="M3 12h18M12 3a14 14 0 0 1 0 18M12 3a14 14 0 0 0 0 18" /></SvgBase>);
const IconRefresh = (p) => (<SvgBase {...p}><path d="M3 12a9 9 0 0 1 15-6.7L21 8" /><path d="M21 3v5h-5" /><path d="M21 12a9 9 0 0 1-15 6.7L3 16" /><path d="M3 21v-5h5" /></SvgBase>);
const IconEye = (p) => (<SvgBase {...p}><path d="M2 12s3.5-7 10-7 10 7 10 7-3.5 7-10 7S2 12 2 12z" /><circle cx="12" cy="12" r="3" /></SvgBase>);
const IconCamera = (p) => (<SvgBase {...p}><path d="M5 7h3l2-2h4l2 2h3a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V9a2 2 0 0 1 2-2z" /><circle cx="12" cy="13" r="3.5" /></SvgBase>);
const IconGamepad = (p) => (<SvgBase {...p}><path d="M6 11h4M8 9v4" /><circle cx="15.5" cy="12" r="1" /><circle cx="17.5" cy="10" r="1" /><rect x="2" y="6" width="20" height="12" rx="4" /></SvgBase>);
const IconBattery = (p) => (<SvgBase {...p}><rect x="2" y="7" width="17" height="10" rx="2" /><path d="M22 11v2" /><path d="M5 10v4M8 10v4M11 10v4" /></SvgBase>);
const IconBriefcase = (p) => (<SvgBase {...p}><rect x="3" y="7" width="18" height="13" rx="2" /><path d="M9 7V5a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v2" /><path d="M3 13h18" /></SvgBase>);
const IconShare = (p) => (<SvgBase {...p}><circle cx="18" cy="5" r="3" /><circle cx="6" cy="12" r="3" /><circle cx="18" cy="19" r="3" /><path d="m8.6 13.5 6.8 4M15.4 6.5l-6.8 4" /></SvgBase>);
const IconBookmark = (p) => (<SvgBase {...p}><path d="M19 21 12 16l-7 5V5a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2z" /></SvgBase>);
const IconPrinter = (p) => (<SvgBase {...p}><path d="M6 9V3h12v6" /><rect x="3" y="9" width="18" height="9" rx="2" /><path d="M6 18h12v3H6z" /></SvgBase>);
const IconCheck = (p) => (<SvgBase {...p}><path d="m5 12 5 5L20 7" /></SvgBase>);
const IconX = (p) => (<SvgBase {...p}><path d="M6 6 18 18M18 6 6 18" /></SvgBase>);
const IconPlus = (p) => (<SvgBase {...p}><path d="M12 5v14M5 12h14" /></SvgBase>);
const IconMinus = (p) => (<SvgBase {...p}><path d="M5 12h14" /></SvgBase>);
const IconYouTube = (p) => (<SvgBase {...p}><rect x="2" y="5" width="20" height="14" rx="3" /><path d="m10 9 5 3-5 3z" fill="currentColor" /></SvgBase>);
const IconTikTok = (p) => (<SvgBase {...p}><path d="M14 4v9.5a3.5 3.5 0 1 1-3.5-3.5" /><path d="M14 4c0 2.8 2.2 5 5 5" /></SvgBase>);
const IconInstagram = (p) => (<SvgBase {...p}><rect x="3" y="3" width="18" height="18" rx="5" /><circle cx="12" cy="12" r="4" /><circle cx="17.5" cy="6.5" r="0.6" fill="currentColor" /></SvgBase>);
const IconXSocial = (p) => (<SvgBase {...p}><path d="M4 4l16 16M20 4 4 20" /></SvgBase>);
const IconCalendar = (p) => (<SvgBase {...p}><rect x="3" y="5" width="18" height="16" rx="2" /><path d="M3 10h18M8 3v4M16 3v4" /></SvgBase>);
const IconStar = (p) => (<SvgBase {...p}><path d="m12 3 2.7 5.7 6.3.9-4.5 4.4 1.1 6.2L12 17.3 6.4 20.2 7.5 14 3 9.6l6.3-.9z" /></SvgBase>);
const IconScale = (p) => (<SvgBase {...p}><path d="M12 3v18M5 21h14" /><path d="m5 8 3 7H2zM19 8l3 7h-6z" /><path d="M5 8h14" /></SvgBase>);
const IconTrendUp = (p) => (<SvgBase {...p}><path d="m3 17 6-6 4 4 8-8" /><path d="M14 7h7v7" /></SvgBase>);
const IconShield = (p) => (<SvgBase {...p}><path d="M12 3 4 6v6c0 5 3.5 8 8 9 4.5-1 8-4 8-9V6z" /></SvgBase>);
const IconSparkle = (p) => (<SvgBase {...p}><path d="M12 3v4M12 17v4M3 12h4M17 12h4M5.6 5.6l2.8 2.8M15.6 15.6l2.8 2.8M5.6 18.4l2.8-2.8M15.6 8.4l2.8-2.8" /></SvgBase>);

/* Geometric SpecEagle mark — abstract head in profile.
   Sharp triangles for beak/eye-line, single-color. NOT cartoony. */
const EagleMark = ({ size = 28, className = '' }) => (
  <svg
    xmlns="http://www.w3.org/2000/svg"
    width={size}
    height={size}
    viewBox="0 0 32 32"
    className={className}
    aria-label="SpecEagle mark"
  >
    {/* Head silhouette: angled chevron suggesting forehead → beak, with eye-dot */}
    <g fill="currentColor">
      {/* upper head wedge */}
      <path d="M3 19 L18 5 L23 10 L11 22 Z" />
      {/* lower beak wedge */}
      <path d="M14 19 L29 13 L24 22 L17 24 Z" />
    </g>
    {/* sharp eye dot (negative) */}
    <circle cx="17.2" cy="13.8" r="1.6" className="fill-paper dark:fill-d-bg" />
  </svg>
);

Object.assign(window, {
  SvgBase,
  IconSearch, IconChevronDown, IconChevronRight, IconChevronLeft,
  IconArrowRight, IconArrowUpRight,
  IconSun, IconMoon, IconBolt, IconGlobe, IconRefresh, IconEye,
  IconCamera, IconGamepad, IconBattery, IconBriefcase,
  IconShare, IconBookmark, IconPrinter,
  IconCheck, IconX, IconPlus, IconMinus,
  IconYouTube, IconTikTok, IconInstagram, IconXSocial,
  IconCalendar, IconStar, IconScale, IconTrendUp, IconShield, IconSparkle,
  EagleMark,
});
