/* Shared SVG visuals for Liquid Data */
/* NOTE (2026-08-01): removed unused components — QRPattern, CanMini, SCStateMap,
   PhoneMock, Sparkline, Wordmark. SCStateMap was a South Carolina name on a Georgia
   map: the same stale-identifier trap as garnet/gold and SCWordmark. Do not carry
   another school's name into this file. */

/* ---------- Official UGA horizontal lockup, knockout white, transparent ----------
   Use this on dark or primary panels. Never wrap a mark in a filled box: the source
   PNGs shipped with an opaque background baked in, which is what produced the white
   square. Backgrounds were flood-cleared 2026-08-01. */
function UGALockup({ width = 210, className = '' }) {
  return (
    <img
      src="assets/uga-logo-white.png?v=2"
      alt="University of Georgia"
      className={className}
      style={{ width, height: 'auto', objectFit: 'contain', display: 'block' }}
    />
  );
}

/* ---------- Official University of Georgia top-shield mark ---------- */
function BlockC({ size = 200, tone = 'primary', className = '' }) {
  return (
    <img
      src="assets/uga-logo-top-shield.png?v=2"
      alt="University of Georgia"
      className={className}
      style={{
        width: size,
        height: size,
        objectFit: 'contain',
        display: 'block',
      }}
    />
  );
}


/* ---------- The production Bulldog Water can renders ---------- */
function CustomCan({ width = 280, rotate = 0, condensation, showQR, uid }) {
  const r = Math.max(-32, Math.min(32, rotate || 0));
  const height = width * (1536 / 1024);
  return (
    <img
      src={showQR ? 'assets/uga-can-back.png?v=2' : 'assets/uga-can-front.png?v=2'}
      alt={showQR ? 'University of Georgia Bulldog Water can back with QR code' : 'University of Georgia Bulldog Water custom can'}
      style={{
        width,
        height,
        maxWidth: '100%',
        display: 'block',
        objectFit: 'contain',
        transform: `rotateY(${r}deg)`,
        transition: 'transform 100ms linear',
        filter: 'drop-shadow(0 30px 30px rgba(15,25,45,0.35))',
      }}
    />
  );
}


/* NOTE (2026-08-01): the WelcomeKit() SVG component was removed here. It drew the
   gift box with hardcoded <text> labels ("GEORGIA", "GA", "BULLDOG WATER PACK")
   that rendered illegibly at display size. Figure 02b now uses the real photograph
   at assets/uga-welcome-kit.jpg?v=2. Do not reintroduce a synthetic box illustration. */




/* ---------- Small inline icons ---------- */
const Icon = {
  Pipeline: ({size=22}) => (
    <svg viewBox="0 0 24 24" width={size} height={size} fill="none" stroke="#BA0C2F" strokeWidth="1.6" strokeLinecap="square">
      <path d="M3 6 L9 6 M3 12 L9 12 M3 18 L9 18" />
      <path d="M9 6 L15 6 L21 12 L15 18 L9 18" />
    </svg>
  ),
  Revenue: ({size=22}) => (
    <svg viewBox="0 0 24 24" width={size} height={size} fill="none" stroke="#BA0C2F" strokeWidth="1.6" strokeLinecap="square">
      <path d="M4 20 L4 4 L20 4" />
      <path d="M4 16 L9 11 L13 14 L20 7" />
    </svg>
  ),
  People: ({size=22}) => (
    <svg viewBox="0 0 24 24" width={size} height={size} fill="none" stroke="#BA0C2F" strokeWidth="1.6" strokeLinecap="square">
      <circle cx="9" cy="8" r="3" />
      <circle cx="17" cy="9" r="2" />
      <path d="M3 20 C 3 16, 6 14, 9 14 C 12 14, 15 16, 15 20" />
      <path d="M15 20 C 15 17, 17 16, 19 16 C 21 16, 22 17, 22 20" />
    </svg>
  ),
  Data: ({size=22}) => (
    <svg viewBox="0 0 24 24" width={size} height={size} fill="none" stroke="#BA0C2F" strokeWidth="1.6" strokeLinecap="square">
      <rect x="4" y="4" width="6" height="6" />
      <rect x="14" y="4" width="6" height="6" />
      <rect x="4" y="14" width="6" height="6" />
      <rect x="14" y="14" width="6" height="6" />
    </svg>
  ),
  Arrow: ({size=14}) => (
    <svg viewBox="0 0 24 24" width={size} height={size} fill="none" stroke="currentColor" strokeWidth="1.6" strokeLinecap="square">
      <path d="M5 12 L19 12 M14 7 L19 12 L14 17" />
    </svg>
  ),
};


/* Expose to global */
Object.assign(window, {
  BlockC, UGALockup, CustomCan, Icon
});
