/* CleanDeen — mock data (shared via window.CD) */

const SEVERITY = {
  high:  { label: "High load",   cls: "sev-high"  },
  med:   { label: "Moderate",    cls: "sev-med"   },
  low:   { label: "Low",         cls: "sev-low"   },
  clean: { label: "Cleared",     cls: "sev-clean" },
};

/* ---- Microbe reference library (admin picks from these) ---- */
const MICROBES = {
  staph:    { name: "Staphylococcus aureus", short: "S. aureus", group: "Bacteria", note: "Skin-borne; thrives on high-touch surfaces.", harm: "Can cause skin, wound, and bloodstream infections; some strains resist antibiotics." },
  mrsa:     { name: "MRSA", short: "MRSA", group: "Bacteria", note: "Antibiotic-resistant staph; locker rooms & gyms.", harm: "Serious, hard-to-treat skin and tissue infections." },
  ecoli:    { name: "Escherichia coli", short: "E. coli", group: "Bacteria", note: "Fecal indicator; signals restroom cross-contamination.", harm: "Causes stomach cramps, diarrhea, and urinary tract infections." },
  salmonella:{ name: "Salmonella", short: "Salmonella", group: "Bacteria", note: "Kitchens & food-prep surfaces.", harm: "Causes food poisoning — fever, cramps, diarrhea." },
  listeria: { name: "Listeria monocytogenes", short: "Listeria", group: "Bacteria", note: "Cold, damp surfaces; refrigeration areas.", harm: "Dangerous for pregnancy, newborns, and weak immune systems." },
  strep:    { name: "Streptococcus", short: "Strep", group: "Bacteria", note: "Respiratory; spreads in busy, crowded areas.", harm: "Causes strep throat, skin infections, and respiratory illness." },
  pseudo:   { name: "Pseudomonas", short: "Pseudomonas", group: "Bacteria", note: "Standing water; sinks and wet floors.", harm: "Causes ear, eye, and skin infections; thrives in damp environments." },
  klebsiella:{ name: "Klebsiella pneumoniae", short: "Klebsiella", group: "Bacteria", note: "High-touch and healthcare-style surfaces.", harm: "Causes pneumonia and urinary infections; often drug-resistant." },
  cdiff:    { name: "Clostridioides difficile", short: "C. diff", group: "Bacteria", note: "Spore-forming; survives on surfaces for weeks.", harm: "Severe, recurring diarrhea and colon inflammation." },
  mold:     { name: "Aspergillus (mold)", short: "Mold", group: "Fungi", note: "Damp carpets and trapped moisture.", harm: "Triggers allergies and asthma; risky for anyone with a weakened immune system." },
  candida:  { name: "Candida auris", short: "Candida", group: "Fungi", note: "Damp, warm surfaces; spreads easily.", harm: "Resistant yeast infection; serious for vulnerable people." },
  blackmold:{ name: "Stachybotrys (black mold)", short: "Black mold", group: "Fungi", note: "Chronically wet drywall and ceilings.", harm: "Respiratory irritation, headaches, and allergic reactions." },
  norovirus:{ name: "Norovirus", short: "Norovirus", group: "Viruses", note: "Highly contagious; restrooms & shared surfaces.", harm: "Sudden vomiting and diarrhea; spreads through whole facilities fast." },
  influenza:{ name: "Influenza A", short: "Influenza", group: "Viruses", note: "Door handles, desks, and shared electronics.", harm: "Fever, body aches, and respiratory illness." },
  rhino:    { name: "Rhinovirus", short: "Rhinovirus", group: "Viruses", note: "Common-cold virus on shared surfaces.", harm: "Runny nose, sore throat, and congestion." },
};

/* ---- A "hotspot" sits on a surface of the isometric room ---- */
/* x,y are % within the room footprint; surface: floor | wallL | wallR */

const ROOMS = [
  {
    id: "main-hall",
    name: "Main Hall",
    type: "Carpeted hall · 2,400 sq ft",
    before: "high",
    after: "clean",
    summary: "Heavy foot traffic and floor contact made the carpet the highest-load surface on site.",
    hotspots: [
      { id: 1, surface: "floor", x: 30, y: 55, microbe: "staph", before: "high", after: "clean", detail: "High-contact front zone" },
      { id: 2, surface: "floor", x: 64, y: 40, microbe: "strep", before: "med",  after: "clean", detail: "Center carpet field" },
      { id: 3, surface: "floor", x: 50, y: 78, microbe: "mold",  before: "med",  after: "low",   detail: "Rear carpet near entry" },
      { id: 4, surface: "wallL", x: 40, y: 60, microbe: "staph", before: "low",  after: "clean", detail: "Storage wall" },
    ],
  },
  {
    id: "wet-room",
    name: "Locker & Shower Room",
    type: "Wet area · 320 sq ft",
    before: "high",
    after: "low",
    summary: "Standing water and constant use kept moisture-loving microbes recurring between visits.",
    hotspots: [
      { id: 1, surface: "floor", x: 45, y: 50, microbe: "pseudo", before: "high", after: "low",   detail: "Floor drains & wet floor" },
      { id: 2, surface: "wallR", x: 55, y: 45, microbe: "ecoli",  before: "high", after: "clean", detail: "Tap & basin row" },
      { id: 3, surface: "wallL", x: 35, y: 55, microbe: "mold",   before: "med",  after: "low",   detail: "Lower tiled wall" },
    ],
  },
  {
    id: "restroom",
    name: "Restrooms",
    type: "Tile · 180 sq ft",
    before: "med",
    after: "clean",
    summary: "Standard restroom load, fully cleared after the protocol.",
    hotspots: [
      { id: 1, surface: "floor", x: 50, y: 55, microbe: "ecoli",  before: "med",  after: "clean", detail: "Floor & fixtures" },
      { id: 2, surface: "wallR", x: 60, y: 40, microbe: "staph",  before: "low",  after: "clean", detail: "Door & handles" },
    ],
  },
  {
    id: "entry",
    name: "Entry & Lobby",
    type: "Lobby · 260 sq ft",
    before: "med",
    after: "clean",
    summary: "Tracked-in contaminants concentrated at the threshold.",
    hotspots: [
      { id: 1, surface: "floor", x: 50, y: 60, microbe: "mold",  before: "med", after: "clean", detail: "Mat & threshold" },
      { id: 2, surface: "wallL", x: 45, y: 50, microbe: "staph", before: "low", after: "clean", detail: "Coat & shelving wall" },
    ],
  },
];

const FAQS = [
  { q: "What is microbial culture testing?", a: "We swab your high-touch surfaces, culture the samples in a lab, and then swab the same spots again once the clean is finished. You see photographs of both sets of plates, so the result is something you can check rather than take our word for." },
  { q: "Where do you offer service?", a: "Cambridge, Boston and the towns immediately around them. Staying inside that radius is what lets us get on site quickly and keep the same crew on your building." },
  { q: "Are your products safe for kids and pets?", a: "Yes. The standard line is Green-Seal-compatible. Pet-safe and fragrance-light products are available on request at no extra charge." },
  { q: "Do I have to sign a long contract?", a: "No. One-time cleans are welcome. Recurring rates come out of an ongoing conversation about your space and how often it needs attention." },
  { q: "How does pricing work?", a: "Every quote starts with a free on-site visit. We look at the rooms, the traffic they take and the testing you want, then send a written price within a business day." },
  { q: "What makes CleanDeen different?", a: "Very few cleaners in the area culture what they clean. We do it on every visit and send you the plates, which changes the conversation from how a room looks to what is actually on it." },
];

const SERVICE_AREAS = ["Cambridge", "Boston", "Somerville", "Brookline", "Allston", "Medford", "Watertown", "Malden"];

/* Real coordinates for the service-area map */
const SERVICE_POINTS = [
  { name: "Cambridge", lat: 42.3736, lng: -71.1097, core: true },
  { name: "Boston",    lat: 42.3601, lng: -71.0589, core: true },
  { name: "Somerville",lat: 42.3876, lng: -71.0995 },
  { name: "Brookline", lat: 42.3318, lng: -71.1212 },
  { name: "Allston",   lat: 42.3539, lng: -71.1337 },
  { name: "Medford",   lat: 42.4184, lng: -71.1062 },
  { name: "Watertown", lat: 42.3709, lng: -71.1828 },
  { name: "Malden",    lat: 42.4251, lng: -71.0662 },
];

/* Google Calendar appointment schedule */
const GOOGLE_BOOKING_URL = "https://calendar.app.google/J1ZAd7dRbnBSthj19";

window.CD = { SEVERITY, MICROBES, ROOMS, FAQS, SERVICE_AREAS, SERVICE_POINTS, GOOGLE_BOOKING_URL };
