// Line-style icons for HVAC services. Hand-drawn minimal SVGs.

const Icon = ({ children, size = 48, stroke = 1.4 }) => (
  <svg
    width={size}
    height={size}
    viewBox="0 0 48 48"
    fill="none"
    stroke="currentColor"
    strokeWidth={stroke}
    strokeLinecap="round"
    strokeLinejoin="round"
  >
    {children}
  </svg>
);

const IconClimate = (p) => (
  <Icon {...p}>
    <rect x="6" y="14" width="36" height="14" rx="2" />
    <line x1="12" y1="20" x2="36" y2="20" />
    <line x1="14" y1="32" x2="14" y2="40" />
    <line x1="24" y1="32" x2="24" y2="42" />
    <line x1="34" y1="32" x2="34" y2="40" />
    <circle cx="38" cy="20" r="1.2" fill="currentColor" />
  </Icon>
);

const IconHeating = (p) => (
  <Icon {...p}>
    <path d="M16 8c0 4 4 5 4 10s-4 6-4 10 4 5 4 10" />
    <path d="M28 8c0 4 4 5 4 10s-4 6-4 10 4 5 4 10" />
  </Icon>
);

const IconVent = (p) => (
  <Icon {...p}>
    <circle cx="24" cy="24" r="16" />
    <path d="M24 8 C 28 14, 28 20, 24 24 C 20 28, 20 34, 24 40" />
    <path d="M40 24 C 34 28, 28 28, 24 24 C 20 20, 14 20, 8 24" />
    <circle cx="24" cy="24" r="2" fill="currentColor" />
  </Icon>
);

const IconMaintenance = (p) => (
  <Icon {...p}>
    <path d="M30 14 L 38 22 M 26 18 L 12 32 a 4 4 0 0 0 0 5.6 a 4 4 0 0 0 5.6 0 L 30 24" />
    <path d="M34 10 a 6 6 0 0 0 -8 8 l -4 4 4 4 4 -4 a 6 6 0 0 0 8 -8 l -4 4 -4 -4 z" />
  </Icon>
);

const IconRepair = (p) => (
  <Icon {...p}>
    <path d="M8 40 L 24 24 L 40 8" />
    <path d="M24 24 L 30 30 L 38 22" />
    <circle cx="14" cy="34" r="2" />
    <path d="M40 8 v 6 h -6" />
  </Icon>
);

const IconVRF = (p) => (
  <Icon {...p}>
    <rect x="6" y="8" width="36" height="10" rx="2" />
    <rect x="6" y="22" width="22" height="8" rx="2" />
    <rect x="6" y="34" width="22" height="6" rx="2" />
    <path d="M32 24 v 12 M 32 30 h 8 M 36 24 v 12" />
  </Icon>
);

const IconArrow = ({ size = 14 }) => (
  <svg width={size} height={size} viewBox="0 0 14 14" fill="none" stroke="currentColor" strokeWidth="1.5" strokeLinecap="round" strokeLinejoin="round">
    <line x1="2" y1="7" x2="12" y2="7" />
    <polyline points="8 3 12 7 8 11" />
  </svg>
);

const IconStar = ({ size = 14 }) => (
  <svg width={size} height={size} viewBox="0 0 14 14" fill="currentColor">
    <path d="M7 1 L 8.7 5.1 L 13 5.5 L 9.7 8.4 L 10.7 12.7 L 7 10.5 L 3.3 12.7 L 4.3 8.4 L 1 5.5 L 5.3 5.1 Z" />
  </svg>
);

const IconCheck = ({ size = 14 }) => (
  <svg width={size} height={size} viewBox="0 0 14 14" fill="none" stroke="currentColor" strokeWidth="1.6" strokeLinecap="round" strokeLinejoin="round">
    <polyline points="2 7.5 5.5 11 12 3.5" />
  </svg>
);

const IconShield = ({ size = 14 }) => (
  <svg width={size} height={size} viewBox="0 0 14 14" fill="none" stroke="currentColor" strokeWidth="1.4" strokeLinecap="round" strokeLinejoin="round">
    <path d="M7 1 L 12 3 V 7 c 0 3 -2.5 5 -5 6 c -2.5 -1 -5 -3 -5 -6 V 3 z" />
  </svg>
);

const IconSun = (p) => (
  <Icon {...p} size={p.size || 18} stroke={1.5}>
    <circle cx="24" cy="24" r="6" />
    <path d="M24 4 v6 M24 38 v6 M4 24 h6 M38 24 h6 M10 10 l4 4 M34 34 l4 4 M10 38 l4 -4 M34 14 l4 -4" />
  </Icon>
);

const IconMoon = (p) => (
  <Icon {...p} size={p.size || 18} stroke={1.5}>
    <path d="M30 8 a 16 16 0 1 0 10 32 A 14 14 0 0 1 30 8 z" />
  </Icon>
);

const IconPhone = ({ size = 14 }) => (
  <svg width={size} height={size} viewBox="0 0 14 14" fill="none" stroke="currentColor" strokeWidth="1.4" strokeLinecap="round" strokeLinejoin="round">
    <path d="M2.5 3 a 1 1 0 0 1 1 -1 H 5 l 1 3 -1.5 1 a 8 8 0 0 0 4 4 L 9 8.5 l 3 1 V 11 a 1 1 0 0 1 -1 1 A 9 9 0 0 1 2.5 3 z" />
  </svg>
);

Object.assign(window, {
  IconClimate, IconHeating, IconVent, IconMaintenance, IconRepair, IconVRF,
  IconArrow, IconStar, IconCheck, IconShield, IconSun, IconMoon, IconPhone,
});
