/* icons.jsx — friendly field-guide line icons (exported to window) */
const Ico = ({ d, size = 24, sw = 1.8, fill = "none", children, ...p }) => (
  <svg width={size} height={size} viewBox="0 0 24 24" fill={fill}
    stroke="currentColor" strokeWidth={sw} strokeLinecap="round" strokeLinejoin="round" {...p}>
    {d ? <path d={d} /> : children}
  </svg>
);

const IconCalendar = (p) => <Ico {...p}><rect x="3" y="4.5" width="18" height="16" rx="2.5"/><path d="M3 9h18M8 2.5v4M16 2.5v4"/><circle cx="8" cy="13.5" r="1.1" fill="currentColor" stroke="none"/><circle cx="12" cy="13.5" r="1.1" fill="currentColor" stroke="none"/></Ico>;
const IconFork = (p) => <Ico {...p}><path d="M6 2.5v7a2.5 2.5 0 0 0 5 0v-7M8.5 2.5v6M18 2.5c-1.7 0-3 2.2-3 5s1.3 4 3 4M18 11.5V21.5"/><path d="M8.5 12.5V21.5"/></Ico>;
const IconTree = (p) => <Ico {...p}><path d="M12 3 6.5 11h3L5 17h14l-4.5-6h3L12 3zM12 17v4.5"/></Ico>;
const IconPaw = (p) => <Ico {...p}><ellipse cx="7" cy="9.5" rx="1.7" ry="2.3"/><ellipse cx="12" cy="8" rx="1.8" ry="2.5"/><ellipse cx="17" cy="9.5" rx="1.7" ry="2.3"/><path d="M12 12.5c-2.6 0-4.6 2-4.6 4 0 1.6 1.4 2.3 2.6 2 .9-.2 1.3-.6 2-.6s1.1.4 2 .6c1.2.3 2.6-.4 2.6-2 0-2-2-4-4.6-4z"/></Ico>;
const IconTag = (p) => <Ico {...p}><path d="M3.5 12.4 12 3.9c.4-.4.9-.6 1.4-.6h5.3c.6 0 1 .4 1 1v5.3c0 .5-.2 1-.6 1.4l-8.5 8.5c-.8.8-2 .8-2.8 0l-4.9-4.9c-.8-.8-.8-2 0-2.8z"/><circle cx="15.5" cy="8.5" r="1.3"/></Ico>;
const IconShop = (p) => <Ico {...p}><path d="M4 9.5 5 4.5h14l1 5M4 9.5C4 11 5 12 6.2 12S8.5 11 8.5 9.5M8.5 9.5C8.5 11 9.6 12 11 12s2.5-1 2.5-2.5M13.5 9.5C13.5 11 14.6 12 16 12s2.4-1 2-2.5M5 11.5V20h14v-8.5M9.5 20v-5h5v5"/></Ico>;
const IconPlus = (p) => <Ico {...p} d="M12 5v14M5 12h14"/>;
const IconPin = (p) => <Ico {...p}><path d="M12 21.5c4-4.2 7-7.6 7-11.4A7 7 0 0 0 5 10.1c0 3.8 3 7.2 7 11.4z"/><circle cx="12" cy="10" r="2.4"/></Ico>;
const IconSearch = (p) => <Ico {...p}><circle cx="11" cy="11" r="6.5"/><path d="m20 20-3.6-3.6"/></Ico>;
const IconArrow = (p) => <Ico {...p} d="M5 12h14M13 6l6 6-6 6"/>;
const IconClock = (p) => <Ico {...p}><circle cx="12" cy="12" r="8.5"/><path d="M12 7.5V12l3 2"/></Ico>;
const IconStar = (p) => <Ico {...p} fill="currentColor" sw={0}><path d="M12 3.5l2.5 5.2 5.7.8-4.1 4 1 5.7-5.1-2.7-5.1 2.7 1-5.7-4.1-4 5.7-.8z"/></Ico>;
const IconHeart = (p) => <Ico {...p}><path d="M12 20.5C6.5 16.5 4 13 4 9.7A4.2 4.2 0 0 1 12 7.6 4.2 4.2 0 0 1 20 9.7c0 3.3-2.5 6.8-8 10.8z"/></Ico>;
const IconClose = (p) => <Ico {...p} d="M6 6l12 12M18 6 6 18"/>;
const IconMenu = (p) => <Ico {...p} d="M4 7h16M4 12h16M4 17h16"/>;
const IconRoute = (p) => <Ico {...p}><circle cx="6" cy="18" r="2.4"/><circle cx="18" cy="6" r="2.4"/><path d="M8.4 18H14a3 3 0 0 0 0-6H9a3 3 0 0 1 0-6h6.6"/></Ico>;
const IconMtn = (p) => <Ico {...p}><path d="M3 19.5h18L14.5 8l-3 4.5L9 9l-6 10.5z"/><path d="M13 11.2 14.5 8"/></Ico>;
const IconWater = (p) => <Ico {...p}><path d="M12 3.5c3.5 4 5.5 6.7 5.5 9.5A5.5 5.5 0 1 1 6.5 13c0-2.8 2-5.5 5.5-9.5z"/></Ico>;
const IconCheck = (p) => <Ico {...p} d="M5 12.5 10 17.5 19.5 7"/>;
const IconPhone = (p) => <Ico {...p}><path d="M6.5 3.5h3l1.5 4.5-2 1.5a11 11 0 0 0 5 5l1.5-2 4.5 1.5v3a2 2 0 0 1-2.2 2A16 16 0 0 1 4.5 5.7 2 2 0 0 1 6.5 3.5z"/></Ico>;
const IconGlobe = (p) => <Ico {...p}><circle cx="12" cy="12" r="8.5"/><path d="M3.5 12h17M12 3.5c2.5 2.4 2.5 14.6 0 17M12 3.5c-2.5 2.4-2.5 14.6 0 17"/></Ico>;
const IconBolt = (p) => <Ico {...p}><path d="M13 3 5 13.5h6L10 21l8-10.5h-6L13 3z"/></Ico>;
const IconLeaf = (p) => <Ico {...p}><path d="M5 19c0-8 6-13 14-13 0 8-5 14-13 14-1 0-1-1-1-1z"/><path d="M9 15c2-3 4.5-5 8-6.5"/></Ico>;
const IconTruck = (p) => <Ico {...p}><rect x="1" y="8" width="15" height="11" rx="2"/><path d="M16 13h4l2 4v3h-6V13z"/><circle cx="5.5" cy="20.5" r="1.5"/><circle cx="18.5" cy="20.5" r="1.5"/><path d="M1 12h15"/></Ico>;
const IconSprout = (p) => <Ico {...p}><path d="M12 22V10"/><path d="M12 10C12 6 9 3 5 3c0 4 2.5 7 7 7z"/><path d="M12 10c0-4 3-7 7-7 0 4-2.5 7-7 7z"/></Ico>;

Object.assign(window, {
  IconCalendar, IconFork, IconTree, IconPaw, IconTag, IconShop, IconPlus, IconPin,
  IconSearch, IconArrow, IconClock, IconStar, IconHeart, IconClose, IconMenu,
  IconRoute, IconMtn, IconWater, IconCheck, IconPhone, IconGlobe, IconBolt, IconLeaf,
  IconTruck, IconSprout
});
