// Shared SVG icons & primitives
const Mark = ({ size = 26 }) => (
  <svg viewBox="0 0 40 40" width={size} height={size} aria-hidden="true">
    <g fill="none" stroke="currentColor" strokeWidth="1.2">
      <circle cx="20" cy="20" r="18.5" opacity="0.5" />
      {/* abstract delta wing */}
      <path d="M6 28 L20 8 L34 28 L20 22 Z" fill="currentColor" stroke="none" />
    </g>
  </svg>
);

const Arrow = ({ size = 12 }) => (
  <svg className="arrow" viewBox="0 0 16 12" width={size} height={size * 0.75} fill="none" stroke="currentColor" strokeWidth="1.5" aria-hidden="true">
    <path d="M0 6 H14 M9 1 L14 6 L9 11" />
  </svg>
);

const Plus = () => (
  <svg viewBox="0 0 12 12" width="12" height="12" fill="none" stroke="currentColor" strokeWidth="1.4">
    <path d="M6 1 V11 M1 6 H11" />
  </svg>
);

const AircraftSilhouette = ({ variant = "midsize" }) => {
  // simplified top-down jet silhouette — abstract, not brand-specific
  const paths = {
    light: "M50 14 L52 8 L54 14 L60 16 L64 18 L80 20 L84 22 L84 24 L66 24 L62 27 L58 36 L57 36 L56 28 L54 26 L50 26 L46 26 L46 28 L44 36 L43 36 L42 27 L38 24 L20 24 L20 22 L24 20 L40 18 L46 16 Z",
    midsize: "M50 12 L52 6 L54 12 L62 14 L66 16 L82 18 L88 20 L92 22 L92 24 L66 25 L60 28 L56 38 L55 38 L54 30 L52 28 L48 28 L44 28 L42 30 L41 38 L40 38 L36 28 L30 25 L8 24 L8 22 L18 18 L34 16 L42 14 Z",
    supermid: "M50 10 L52 4 L54 10 L62 12 L66 14 L84 16 L92 18 L98 20 L98 24 L68 26 L60 30 L54 40 L53 40 L52 32 L50 30 L48 30 L46 30 L44 32 L43 40 L42 40 L36 30 L28 26 L2 24 L2 20 L8 18 L16 16 L34 14 L42 12 Z",
    heavy: "M50 8 L52 2 L54 8 L62 10 L68 12 L88 14 L96 17 L100 21 L100 24 L70 26 L62 32 L54 42 L53 42 L52 33 L50 30 L48 30 L46 30 L44 33 L43 42 L42 42 L34 32 L26 26 L0 24 L0 21 L4 17 L12 14 L32 12 L42 10 Z",
    ultra: "M50 6 L52 0 L54 6 L62 8 L68 10 L88 12 L98 16 L104 20 L104 24 L72 26 L62 34 L54 44 L53 44 L52 34 L50 32 L48 32 L46 32 L44 34 L43 44 L42 44 L32 34 L22 26 L-4 24 L-4 20 L2 16 L12 12 L32 10 L42 8 Z",
  };
  return (
    <svg viewBox="0 0 100 50" width="100%" height="100%" className="silhouette" aria-hidden="true">
      <path d={paths[variant] || paths.midsize} fill="currentColor" stroke="currentColor" strokeWidth="0.3" strokeLinejoin="round" opacity="0.85" />
    </svg>
  );
};

window.Icons = { Mark, Arrow, Plus, AircraftSilhouette };
