Full pharmacology all drugs system wise in which condition dose (oral,iv,im) and side effects contraindications

Asking for Preferences
Reading File
Reading File
Reading File
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Running Command

mkdir -p /home/daytona/workspace/pharmacology-reference && ls /home/daytona/workspace/pharmacology-reference/

Writing File

~/pharmacology-reference/build_pharma_pptx.js

const pptxgen = require("pptxgenjs");

const pres = new pptxgen();
pres.layout = "LAYOUT_WIDE";
pres.title = "System-Wise Pharmacology Reference";
pres.author = "Orris Medical Reference";

// ─── COLOR PALETTE ───────────────────────────────────────────────────
const C = {
  navy:    "0D1B2A",
  teal:    "1B998B",
  gold:    "FFBC42",
  white:   "FFFFFF",
  light:   "F0F4F8",
  red:     "E63946",
  green:   "2D9E5F",
  purple:  "6A4C93",
  orange:  "F4884A",
  blue:    "2176AE",
  gray:    "4A5568",
  lgray:   "CBD5E0",
  darkbg:  "101820",
};

// ─── HELPERS ─────────────────────────────────────────────────────────
function titleSlide(title, subtitle) {
  const sl = pres.addSlide();
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: "100%", h: "100%", fill: { color: C.darkbg } });
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: "100%", h: 0.06, fill: { color: C.teal } });
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 7.44, w: "100%", h: 0.06, fill: { color: C.teal } });
  sl.addText(title, { x: 0.5, y: 1.8, w: 12.3, h: 1.8, fontSize: 46, bold: true, color: C.white, align: "center", fontFace: "Calibri" });
  if (subtitle) sl.addText(subtitle, { x: 0.5, y: 3.8, w: 12.3, h: 0.8, fontSize: 22, color: C.teal, align: "center", fontFace: "Calibri" });
  sl.addText("Compiled from Goodman & Gilman | Katzung | Lippincott Pharmacology", { x: 0.5, y: 6.6, w: 12.3, h: 0.4, fontSize: 13, color: C.lgray, align: "center", italic: true });
}

function sectionHeader(system, icon, color) {
  const sl = pres.addSlide();
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: "100%", h: "100%", fill: { color: color || C.navy } });
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 0.12, h: "100%", fill: { color: C.teal } });
  sl.addText(icon + " " + system, { x: 0.5, y: 2.8, w: 12.3, h: 1.8, fontSize: 42, bold: true, color: C.white, align: "center", fontFace: "Calibri" });
  sl.addText("System-Wise Drug Reference", { x: 0.5, y: 5.0, w: 12.3, h: 0.5, fontSize: 18, color: C.teal, align: "center" });
}

function drugSlide(system, drugClass, drugs) {
  // drugs = [{name, indication, oral, iv, im, se, ci}]
  const sl = pres.addSlide();
  // header bar
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: "100%", h: 0.65, fill: { color: C.navy } });
  sl.addText(system + "  |  " + drugClass, { x: 0.2, y: 0.05, w: 12.9, h: 0.55, fontSize: 17, bold: true, color: C.white, fontFace: "Calibri", margin: 0 });

  const colW = [2.1, 2.0, 1.7, 1.5, 1.5, 2.5, 2.0];
  const headers = ["Drug", "Indication", "Oral Dose", "IV Dose", "IM Dose", "Side Effects", "Contraindications"];
  const hColors = [C.navy, C.teal, C.green, C.blue, C.purple, C.orange, C.red];

  // column headers
  let xPos = 0.1;
  headers.forEach((h, i) => {
    sl.addShape(pres.ShapeType.rect, { x: xPos, y: 0.68, w: colW[i], h: 0.42, fill: { color: hColors[i] } });
    sl.addText(h, { x: xPos, y: 0.68, w: colW[i], h: 0.42, fontSize: 10.5, bold: true, color: C.white, align: "center", valign: "middle", margin: 2 });
    xPos += colW[i] + 0.04;
  });

  // rows
  const rowH = (7.5 - 1.13) / drugs.length;
  const actualRowH = Math.min(rowH, 1.0);

  drugs.forEach((d, ri) => {
    const rowY = 1.13 + ri * actualRowH;
    const bg = ri % 2 === 0 ? C.light : C.white;
    xPos = 0.1;
    const vals = [d.name, d.indication, d.oral || "—", d.iv || "—", d.im || "—", d.se, d.ci];
    vals.forEach((v, ci) => {
      sl.addShape(pres.ShapeType.rect, { x: xPos, y: rowY, w: colW[ci], h: actualRowH, fill: { color: bg }, line: { color: C.lgray, width: 0.5 } });
      const fSize = ci === 0 ? 9.5 : 8.5;
      const bold = ci === 0;
      sl.addText(v, { x: xPos + 0.03, y: rowY + 0.02, w: colW[ci] - 0.06, h: actualRowH - 0.04, fontSize: fSize, bold: bold, color: ci === 0 ? C.navy : C.gray, valign: "top", shrinkText: true });
      xPos += colW[ci] + 0.04;
    });
  });

  // footer
  sl.addText("Ref: Goodman & Gilman | Katzung | Lippincott", { x: 0.1, y: 7.3, w: 12, h: 0.2, fontSize: 8, color: C.lgray, italic: true });
}

// ═══════════════════════════════════════════════════════════════════
// SLIDE 1: Title
// ═══════════════════════════════════════════════════════════════════
titleSlide(
  "System-Wise Pharmacology",
  "Indications • Doses (Oral / IV / IM) • Side Effects • Contraindications"
);

// ═══════════════════════════════════════════════════════════════════
// SECTION 1: CARDIOVASCULAR SYSTEM
// ═══════════════════════════════════════════════════════════════════
sectionHeader("Cardiovascular System (CVS)", "❤️", "0A2540");

drugSlide("CVS", "ACE Inhibitors", [
  { name: "Enalapril", indication: "HTN, HFrEF, post-MI", oral: "5–40 mg/day (1–2 doses)", iv: "1.25 mg q6h", im: "—", se: "Dry cough, hyperkalemia, angioedema, hypotension, renal impairment", ci: "Pregnancy, bilateral RAS, prior angioedema, hyperkalemia" },
  { name: "Lisinopril", indication: "HTN, HF, diabetic nephropathy", oral: "10–40 mg/day", iv: "—", im: "—", se: "Dry cough, hypotension, hyperkalemia, angioedema", ci: "Pregnancy, angioedema history, bilateral RAS" },
  { name: "Ramipril", indication: "HTN, HF, post-MI, CKD", oral: "2.5–10 mg/day", iv: "—", im: "—", se: "Cough, hyperkalemia, renal impairment, dizziness", ci: "Pregnancy, bilateral RAS, hyperkalemia" },
  { name: "Captopril", indication: "HTN, HF, post-MI, diabetic nephropathy", oral: "25–150 mg TID", iv: "—", im: "—", se: "Cough, rash, dysgeusia, neutropenia, proteinuria", ci: "Pregnancy, bilateral RAS, angioedema" },
]);

drugSlide("CVS", "ARBs (Angiotensin Receptor Blockers)", [
  { name: "Losartan", indication: "HTN, HF, CKD in type 2 DM", oral: "50–100 mg/day", iv: "—", im: "—", se: "Hyperkalemia, dizziness, renal impairment (rare angioedema)", ci: "Pregnancy, bilateral RAS, hyperkalemia" },
  { name: "Valsartan", indication: "HTN, HFrEF, post-MI", oral: "80–320 mg/day", iv: "—", im: "—", se: "Hypotension, hyperkalemia, headache, dizziness", ci: "Pregnancy, bilateral RAS, severe hepatic impairment" },
  { name: "Telmisartan", indication: "HTN, CV risk reduction", oral: "40–80 mg/day", iv: "—", im: "—", se: "Hyperkalemia, dizziness, back pain", ci: "Pregnancy, biliary obstruction" },
  { name: "Candesartan", indication: "HTN, HFrEF", oral: "8–32 mg/day", iv: "—", im: "—", se: "Hyperkalemia, renal impairment, dizziness", ci: "Pregnancy, severe hepatic impairment" },
]);

drugSlide("CVS", "Beta-Blockers", [
  { name: "Metoprolol (β1 selective)", indication: "HTN, angina, HF, MI, arrhythmia", oral: "25–200 mg/day (succinate) or BID (tartrate)", iv: "5 mg q5min × 3 (MI/arrhythmia)", im: "—", se: "Bradycardia, fatigue, sexual dysfunction, cold extremities, mask hypoglycemia", ci: "Asthma, cardiogenic shock, severe bradycardia, 2nd/3rd degree AV block" },
  { name: "Carvedilol (α1+β)", indication: "HFrEF, HTN, post-MI", oral: "3.125–25 mg BID", iv: "—", im: "—", se: "Dizziness, hypotension, weight gain, bradycardia, fatigue", ci: "Decompensated HF, severe bradycardia, severe asthma" },
  { name: "Atenolol (β1 selective)", indication: "HTN, angina, post-MI", oral: "25–100 mg/day", iv: "2.5–5 mg IV (arrhythmia)", im: "—", se: "Bradycardia, fatigue, cold extremities, depression", ci: "Asthma, heart block, cardiogenic shock" },
  { name: "Propranolol (non-selective)", indication: "HTN, angina, arrhythmia, thyrotoxicosis, migraine prophylaxis, tremor", oral: "40–320 mg/day (divided)", iv: "1–3 mg IV slowly", im: "—", se: "Bradycardia, bronchospasm, mask hypoglycemia, fatigue", ci: "Asthma/COPD, heart block, Raynaud's, IDDM" },
  { name: "Bisoprolol (β1 selective)", indication: "HFrEF, HTN, angina", oral: "2.5–10 mg/day", iv: "—", im: "—", se: "Bradycardia, fatigue, dizziness, cold extremities", ci: "Cardiogenic shock, heart block, severe asthma" },
]);

drugSlide("CVS", "Calcium Channel Blockers", [
  { name: "Amlodipine (DHP)", indication: "HTN, stable angina, vasospastic angina", oral: "5–10 mg/day", iv: "—", im: "—", se: "Peripheral edema, flushing, headache, reflex tachycardia", ci: "Cardiogenic shock, severe aortic stenosis" },
  { name: "Nifedipine (DHP)", indication: "HTN, angina, Raynaud's, preterm labor", oral: "30–90 mg/day (XL)", iv: "—", im: "—", se: "Flushing, headache, edema, reflex tachycardia, gingival hyperplasia", ci: "Cardiogenic shock, acute MI (short-acting), unstable angina" },
  { name: "Diltiazem (non-DHP)", indication: "HTN, angina, AF/AFL rate control, SVT", oral: "120–360 mg/day", iv: "0.25 mg/kg bolus then 5–15 mg/hr", im: "—", se: "Bradycardia, AV block, constipation, edema, hypotension", ci: "Sick sinus syndrome, 2nd/3rd degree AV block, cardiogenic shock" },
  { name: "Verapamil (non-DHP)", indication: "SVT, HTN, angina, hypertrophic CMP", oral: "120–480 mg/day (divided)", iv: "2.5–5 mg bolus", im: "—", se: "Constipation, bradycardia, AV block, hypotension, HF exacerbation", ci: "Heart failure, sick sinus syndrome, AV block, concurrent beta-blocker IV" },
]);

drugSlide("CVS", "Diuretics", [
  { name: "Furosemide (Loop)", indication: "Pulmonary edema, HF, hypertensive emergency, edema, hypercalcemia", oral: "20–80 mg/day (up to 600 mg)", iv: "20–80 mg (or 40–200 mg infusion)", im: "20–40 mg", se: "Hypokalemia, hyponatremia, hypomagnesemia, ototoxicity, hyperuricemia, dehydration", ci: "Anuria, sulfonamide allergy (relative), hepatic coma" },
  { name: "Hydrochlorothiazide (Thiazide)", indication: "HTN, edema, nephrolithiasis (Ca stones), DI", oral: "12.5–50 mg/day", iv: "—", im: "—", se: "Hypokalemia, hyponatremia, hyperuricemia, hypercalcemia, hyperglycemia, hyperlipidemia", ci: "Anuria, sulfonamide allergy (relative), severe renal impairment (GFR<30)" },
  { name: "Spironolactone (K+-sparing)", indication: "HFrEF, hyperaldosteronism, ascites, HTN, hirsutism", oral: "25–400 mg/day", iv: "—", im: "—", se: "Hyperkalemia, gynecomastia, menstrual irregularity, GI upset", ci: "Hyperkalemia, Addison's disease, renal failure, concurrent K+ supps with ACEi" },
  { name: "Mannitol (Osmotic)", indication: "Raised ICP, acute glaucoma, acute renal failure prevention", oral: "—", iv: "0.25–2 g/kg infusion over 30–60 min", im: "—", se: "Pulmonary edema, fluid/electrolyte imbalance, headache, nausea", ci: "Anuria (established), severe HF, pulmonary edema, intracranial bleeding" },
]);

drugSlide("CVS", "Antiarrhythmics (Vaughan Williams Classes)", [
  { name: "Lidocaine (Class Ib)", indication: "Ventricular arrhythmias (VT/VF) post-MI", oral: "—", iv: "1–1.5 mg/kg bolus; 1–4 mg/min infusion", im: "4–5 mg/kg (auto-injector)", se: "CNS toxicity (seizures, drowsiness), cardiovascular depression", ci: "Stokes-Adams attacks, severe heart block, allergy to amide anesthetics" },
  { name: "Amiodarone (Class III)", indication: "VT, VF, AF, AFL rate/rhythm control", oral: "200 mg TID (loading) → 200 mg/day (maint)", iv: "150 mg bolus over 10 min → 1 mg/min × 6h → 0.5 mg/min", im: "—", se: "Pulmonary toxicity, thyroid (hypo/hyper), hepatotoxicity, corneal deposits, photosensitivity, blue-gray skin", ci: "Sinus bradycardia, heart block, iodine allergy, severe thyroid disease" },
  { name: "Adenosine (Class misc.)", indication: "SVT (AVNRT, AVRT) diagnosis/termination", oral: "—", iv: "6 mg rapid IV push; repeat 12 mg × 2", im: "—", se: "Transient asystole, flushing, chest tightness, bronchospasm", ci: "Sick sinus syndrome, 2nd/3rd degree AV block, severe asthma" },
  { name: "Digoxin (Cardiac glycoside)", indication: "AF rate control, HFrEF (adjunct)", oral: "0.125–0.25 mg/day", iv: "0.5 mg loading (divided doses)", im: "Not recommended", se: "Nausea, visual disturbances (yellow-green), bradycardia, heart block, arrhythmias", ci: "VF, 2nd/3rd degree AV block, WPW syndrome, hypertrophic CMP with obstruction" },
]);

drugSlide("CVS", "Antianginals & Statins", [
  { name: "Nitroglycerine (Nitrate)", indication: "Acute angina, acute HF, hypertensive emergency", oral: "SL: 0.3–0.6 mg; Transdermal patch: 0.2–0.8 mg/hr", iv: "5–200 mcg/min infusion", im: "—", se: "Headache, hypotension, reflex tachycardia, methemoglobinemia (high dose)", ci: "Severe hypotension (SBP<90), right ventricular infarction, PDE5 inhibitors concurrent use" },
  { name: "Isosorbide Mononitrate", indication: "Angina prophylaxis, esophageal spasm", oral: "20–120 mg/day (extended release)", iv: "—", im: "—", se: "Headache, hypotension, tolerance (nitrate-free interval needed)", ci: "Hypotension, concurrent PDE5 inhibitors, shock" },
  { name: "Atorvastatin (HMG-CoA-RI)", indication: "Hyperlipidemia, CV risk reduction, post-ACS", oral: "10–80 mg/day (at night)", iv: "—", im: "—", se: "Myopathy/rhabdomyolysis, elevated LFTs, GI upset, headache", ci: "Active liver disease, pregnancy, breastfeeding, concurrent fibrates (caution)" },
  { name: "Rosuvastatin", indication: "Hyperlipidemia, primary prevention", oral: "5–40 mg/day", iv: "—", im: "—", se: "Myopathy, hepatotoxicity (rare), proteinuria (high dose)", ci: "Pregnancy, active liver disease, severe renal impairment (high dose)" },
]);

// ═══════════════════════════════════════════════════════════════════
// SECTION 2: RESPIRATORY SYSTEM
// ═══════════════════════════════════════════════════════════════════
sectionHeader("Respiratory System", "🫁", "0D3B1A");

drugSlide("Respiratory", "Bronchodilators – Beta-2 Agonists", [
  { name: "Salbutamol / Albuterol (SABA)", indication: "Acute bronchospasm, asthma, COPD (rescue)", oral: "2–4 mg TID-QID; Neb: 2.5 mg q4–6h", iv: "250 mcg slow IV; infusion 5–20 mcg/min", im: "500 mcg IM (severe asthma)", se: "Tachycardia, tremor, hypokalemia, hyperglycemia, palpitations", ci: "Tachyarrhythmia, hypersensitivity" },
  { name: "Salmeterol (LABA)", indication: "Asthma maintenance (+ ICS), COPD maintenance", oral: "Inhaler: 50 mcg BID", iv: "—", im: "—", se: "Tachycardia, tremor, paradoxical bronchospasm, hypokalemia", ci: "Monotherapy in asthma (without ICS), tachyarrhythmia" },
  { name: "Formoterol (LABA)", indication: "Asthma (+ ICS), COPD maintenance", oral: "Inhaler: 12 mcg BID (DPI)", iv: "—", im: "—", se: "Tachycardia, tremor, hypokalemia", ci: "Monotherapy in asthma (without ICS)" },
  { name: "Terbutaline", indication: "Asthma, COPD, preterm labor", oral: "2.5–5 mg TID", iv: "0.25 mg slow IV (severe asthma)", im: "0.25 mg SC/IM", se: "Tremor, tachycardia, hypokalemia, hyperglycemia", ci: "Tachyarrhythmia, eclampsia (in tocolysis)" },
]);

drugSlide("Respiratory", "Anticholinergics & Methylxanthines", [
  { name: "Ipratropium (SAMA)", indication: "COPD (first-line), acute asthma (adjunct)", oral: "Neb: 0.25–0.5 mg q4–6h; MDI: 40–80 mcg QID", iv: "—", im: "—", se: "Dry mouth, urinary retention, blurred vision, constipation, paradoxical bronchospasm", ci: "Narrow-angle glaucoma (eye exposure), urinary retention (caution)" },
  { name: "Tiotropium (LAMA)", indication: "COPD maintenance (first-line)", oral: "Inhaler: 18 mcg/day (HandiHaler)", iv: "—", im: "—", se: "Dry mouth, urinary retention, constipation, tachycardia, blurred vision", ci: "Narrow-angle glaucoma, urinary retention, severe renal impairment" },
  { name: "Theophylline", indication: "Asthma (add-on), COPD (adjunct), neonatal apnea", oral: "5–10 mcg/mL target; 200–400 mg BID (XR)", iv: "Loading: 5 mg/kg; Maint: 0.5 mg/kg/hr", im: "—", se: "Nausea, vomiting, headache, tachycardia, seizures, arrhythmias (toxicity)", ci: "Acute MI, arrhythmias, peptic ulcer, seizure disorder, porphyria" },
]);

drugSlide("Respiratory", "Inhaled Corticosteroids & Anti-asthmatics", [
  { name: "Budesonide (ICS)", indication: "Asthma maintenance, COPD, group croup", oral: "Inhaler: 200–800 mcg/day (divided); Neb: 0.25–2 mg/day", iv: "—", im: "—", se: "Oral candidiasis, dysphonia, HPA suppression (high dose), osteoporosis (long-term)", ci: "Active pulmonary TB (relative), not for acute attacks" },
  { name: "Fluticasone (ICS)", indication: "Asthma maintenance, COPD", oral: "Inhaler: 100–1000 mcg/day", iv: "—", im: "—", se: "Oral candidiasis, dysphonia, HPA suppression", ci: "Acute asthma attack; not for acute bronchospasm" },
  { name: "Montelukast (LTRA)", indication: "Asthma (adjunct/mild), allergic rhinitis, exercise-induced bronchoconstriction", oral: "10 mg/day (adults); 5 mg/day (6–14 yr)", iv: "—", im: "—", se: "Headache, GI upset, neuropsychiatric effects (depression, suicidality – FDA black box)", ci: "Phenylketonuria (chewable tabs), severe psychiatric history" },
  { name: "Cromolyn Sodium", indication: "Asthma prophylaxis (exercise/allergen induced), allergic rhinitis, mastocytosis", oral: "Inhaler/Neb: 20 mg QID", iv: "—", im: "—", se: "Cough, throat irritation, bronchospasm (paradoxical)", ci: "Acute asthma attack, hypersensitivity" },
]);

// ═══════════════════════════════════════════════════════════════════
// SECTION 3: CNS / NEUROLOGICAL
// ═══════════════════════════════════════════════════════════════════
sectionHeader("Central Nervous System (CNS)", "🧠", "1A0D2E");

drugSlide("CNS", "Opioid Analgesics", [
  { name: "Morphine", indication: "Severe pain, pulmonary edema (acute), MI pain", oral: "5–30 mg q4h (IR); 15–200 mg q8–12h (SR)", iv: "2–4 mg slow IV q3–4h; PCA: 0.5–3 mg/h", im: "5–10 mg q4h", se: "Respiratory depression, sedation, constipation, nausea/vomiting, pruritus, euphoria, miosis", ci: "Respiratory depression, paralytic ileus, acute abdomen, MAOIs, head injury (relative), renal failure (accumulation)" },
  { name: "Fentanyl", indication: "Procedural analgesia, chronic pain (patch), anesthesia adjunct", oral: "Transmucosal: 200–1600 mcg; Patch: 12–100 mcg/hr q72h", iv: "1–2 mcg/kg bolus; infusion 25–200 mcg/hr", im: "50–100 mcg", se: "Respiratory depression, chest wall rigidity (high IV dose), sedation, nausea, euphoria", ci: "Significant respiratory depression (non-intubated), MAOIs, acute/severe asthma (relative)" },
  { name: "Tramadol", indication: "Moderate-severe pain (opioid-SNRI hybrid)", oral: "50–100 mg q4–6h (max 400 mg/day)", iv: "50–100 mg q4–6h", im: "50–100 mg q4–6h", se: "Seizures, serotonin syndrome (+ SSRIs), nausea, dizziness, respiratory depression (less than others)", ci: "MAOIs, seizure disorder, SSRIs/SNRIs (serotonin syndrome risk), acute intoxication" },
  { name: "Codeine", indication: "Mild-moderate pain, antitussive (low dose)", oral: "15–60 mg q4–6h", iv: "—", im: "30–60 mg q4h", se: "Constipation, nausea, sedation, respiratory depression (ultra-rapid metabolizers)", ci: "Children post-tonsillectomy (FDA black box), breastfeeding, CYP2D6 ultra-rapid metabolizers" },
]);

drugSlide("CNS", "NSAIDs & Non-Opioid Analgesics", [
  { name: "Ibuprofen (NSAID)", indication: "Pain, fever, dysmenorrhea, RA, OA, gout", oral: "200–800 mg TID-QID (max 3200 mg/day)", iv: "400–800 mg q6h", im: "—", se: "GI ulceration/bleeding, renal impairment, fluid retention, HTN, CV events (prolonged), bronchospasm (aspirin-sensitive)", ci: "Active peptic ulcer, severe renal/hepatic failure, 3rd trimester pregnancy, aspirin-exacerbated asthma, CABG perioperative" },
  { name: "Aspirin (COX-1/2 NSAID)", indication: "Antiplatelet (75–325 mg), analgesic/anti-inflammatory (higher doses), Kawasaki disease", oral: "75–325 mg/day (antiplatelet); 325–650 mg q4–6h (analgesic); 4–8 g/day (anti-inflammatory)", iv: "—", im: "—", se: "GI bleeding, peptic ulcer, Reye's syndrome (children), salicylism (tinnitus, dizziness), bronchospasm", ci: "Children < 12 yrs with viral illness (Reye's), active bleeding, peptic ulcer, allergy, anticoagulant therapy (caution)" },
  { name: "Paracetamol / Acetaminophen", indication: "Pain, fever (all ages including children, pregnancy)", oral: "500–1000 mg q4–6h (max 4 g/day; 2 g/day in liver disease)", iv: "1 g q4–6h (over 15 min)", im: "—", se: "Hepatotoxicity (overdose – N-acetylcysteine antidote), rash (rare)", ci: "Severe hepatic impairment, alcoholism (caution), paracetamol allergy" },
  { name: "Celecoxib (COX-2 selective)", indication: "OA, RA, ankylosing spondylitis, pain, familial adenomatous polyposis", oral: "100–200 mg BID", iv: "—", im: "—", se: "CV events (MI, stroke), fluid retention, renal impairment, less GI toxicity than non-selective NSAIDs", ci: "Sulfonamide allergy, post-CABG, active peptic ulcer, advanced renal disease, 3rd trimester pregnancy" },
]);

drugSlide("CNS", "Antiepileptics (AEDs)", [
  { name: "Phenytoin", indication: "Focal & tonic-clonic seizures, status epilepticus, trigeminal neuralgia, neuropathic pain", oral: "300–400 mg/day (adult maintenance)", iv: "15–20 mg/kg loading (≤50 mg/min); maint 100 mg q6–8h", im: "Not recommended (erratic absorption)", se: "Gingival hyperplasia, hirsutism, ataxia, nystagmus, SJS/TEN, folic acid deficiency, teratogenicity, hypotension (IV)", ci: "Bradycardia, SA/AV block, porphyria, pregnancy (relative), concurrent delavirdine" },
  { name: "Valproate / Valproic Acid", indication: "Absence, tonic-clonic, myoclonic seizures; bipolar disorder; migraine prophylaxis", oral: "500–2500 mg/day (divided)", iv: "Loading 15–45 mg/kg; maint 1–4 mg/kg/hr", im: "—", se: "Hepatotoxicity (children <2yr at highest risk), teratogenicity (neural tube defects), pancreatitis, weight gain, tremor, alopecia, thrombocytopenia", ci: "Hepatic disease, pregnancy (esp. neural tube defects – absolute contraindication in childbearing), mitochondrial disorders (Alpers)" },
  { name: "Carbamazepine", indication: "Focal & tonic-clonic seizures, trigeminal neuralgia, bipolar disorder", oral: "200–1600 mg/day (divided)", iv: "—", im: "—", se: "Diplopia, ataxia, SJS/TEN (HLA-B*1502 - Asian populations), SIADH, hyponatremia, aplastic anemia, agranulocytosis", ci: "AV block, bone marrow depression, MAOIs, porphyria; test HLA-B*1502 in Asians" },
  { name: "Levetiracetam", indication: "Focal seizures, JME, tonic-clonic, status epilepticus (off-label IV)", oral: "500–3000 mg/day (BID)", iv: "Same dose range; loading 20–60 mg/kg for SE", im: "—", se: "Somnolence, behavioral changes (irritability, aggression, depression), dizziness, headache", ci: "Hypersensitivity; caution in renal impairment (dose reduce)" },
]);

drugSlide("CNS", "Antidepressants", [
  { name: "Sertraline (SSRI)", indication: "MDD, OCD, panic disorder, PTSD, social anxiety, PMDD", oral: "50–200 mg/day", iv: "—", im: "—", se: "GI upset, sexual dysfunction, insomnia, serotonin syndrome (overdose/interactions), SIADH, QT prolongation (rare)", ci: "MAOIs (14-day washout), pimozide, linezolid, methylene blue, uncontrolled seizures" },
  { name: "Fluoxetine (SSRI)", indication: "MDD, OCD, bulimia nervosa, panic disorder, PMDD", oral: "20–80 mg/day", iv: "—", im: "—", se: "Insomnia, agitation, GI upset, sexual dysfunction, weight loss initially, serotonin syndrome", ci: "MAOIs (5-week washout after fluoxetine; 2 weeks before), thioridazine, pimozide" },
  { name: "Venlafaxine (SNRI)", indication: "MDD, GAD, social anxiety, panic disorder, neuropathic pain", oral: "75–225 mg/day (XR: once daily)", iv: "—", im: "—", se: "Hypertension (dose-dependent), sexual dysfunction, nausea, dizziness, discontinuation syndrome", ci: "MAOIs, uncontrolled HTN, concurrent linezolid/methylene blue" },
  { name: "Amitriptyline (TCA)", indication: "MDD, neuropathic pain, migraine prophylaxis, fibromyalgia, IBS", oral: "25–150 mg/day (usually at night)", iv: "—", im: "—", se: "Anticholinergic (dry mouth, urinary retention, constipation, blurred vision), sedation, orthostatic hypotension, QT prolongation, cardiac toxicity (OD)", ci: "Recent MI, arrhythmias, glaucoma (narrow angle), urinary retention, MAOIs, concurrent QT-prolonging drugs" },
]);

drugSlide("CNS", "Antipsychotics & Mood Stabilizers", [
  { name: "Haloperidol (FGA)", indication: "Schizophrenia, acute psychosis, mania, delirium, Tourette's, nausea/vomiting", oral: "0.5–20 mg/day", iv: "2–10 mg IV (delirium/agitation)", im: "2–10 mg IM (acute agitation); depot: 50–300 mg q4wks", se: "EPS (akathisia, dystonia, parkinsonism, tardive dyskinesia), NMS, QT prolongation, sedation, hyperprolactinemia", ci: "NMS, Parkinson's disease, CNS depression, QT prolongation, pheochromocytoma" },
  { name: "Olanzapine (SGA)", indication: "Schizophrenia, bipolar disorder (mania, maintenance), agitation (IM)", oral: "5–20 mg/day", iv: "—", im: "10 mg IM (acute agitation)", se: "Metabolic syndrome (weight gain, dyslipidemia, DM), sedation, EPS (less), orthostatic hypotension, anticholinergic effects", ci: "Narrow-angle glaucoma (caution), QT prolongation, dementia-related psychosis (black box)" },
  { name: "Lithium (Mood stabilizer)", indication: "Bipolar disorder (acute mania & prophylaxis), schizoaffective disorder, augmentation in MDD", oral: "900–2400 mg/day (TID-QID); target serum: 0.6–1.2 mEq/L", iv: "—", im: "—", se: "Tremor, polyuria, polydipsia, weight gain, hypothyroidism, nephrotoxicity (long-term), teratogenicity (Ebstein's anomaly), toxicity (narrow TI)", ci: "Renal impairment, sodium-depleted states, pregnancy (1st trimester), diuretics/NSAIDs (increase levels), hypothyroidism" },
  { name: "Clonazepam (Benzodiazepine)", indication: "Panic disorder, seizures (absence, akinetic), acute anxiety, status epilepticus", oral: "0.25–4 mg/day (BID-TID)", iv: "0.5–1 mg slow IV (seizures)", im: "0.5–1 mg IM", se: "CNS depression, dependence/tolerance, amnesia, respiratory depression, paradoxical excitability in children", ci: "Acute narrow-angle glaucoma, severe hepatic disease, myasthenia gravis, respiratory depression, pregnancy (relative)" },
]);

// ═══════════════════════════════════════════════════════════════════
// SECTION 4: ANTIMICROBIALS
// ═══════════════════════════════════════════════════════════════════
sectionHeader("Antimicrobials (Anti-infectives)", "🦠", "1A1400");

drugSlide("Antimicrobials", "Penicillins & Cephalosporins", [
  { name: "Amoxicillin (Aminopenicillin)", indication: "RTI, UTI, H. pylori, otitis media, Lyme disease (early)", oral: "250–500 mg TID or 875 mg BID", iv: "—", im: "—", se: "Diarrhea, nausea, rash (maculopapular in EBV), anaphylaxis, pseudomembranous colitis", ci: "Penicillin allergy, infectious mononucleosis" },
  { name: "Amox-Clavulanate (Co-amoxiclav)", indication: "Community-acquired pneumonia, sinusitis, animal bites, skin & soft tissue infections", oral: "500/125 mg TID or 875/125 mg BID", iv: "1.2 g q8h", im: "—", se: "Diarrhea (clavulanate), cholestatic jaundice, rash, C. diff", ci: "Penicillin allergy, previous amox-clavulanate cholestatic jaundice" },
  { name: "Cefazolin (1st gen Ceph)", indication: "Surgical prophylaxis, skin/soft tissue, UTI", oral: "—", iv: "1–2 g q8h (or q12h)", im: "0.5–1 g q8–12h", se: "Rash, GI upset, thrombophlebitis (IV), neutropenia (rare), C. diff", ci: "Cephalosporin allergy; cross-reactivity with penicillin (≈1–2%)" },
  { name: "Ceftriaxone (3rd gen Ceph)", indication: "Meningitis, pneumonia, gonorrhea, Lyme disease, typhoid", oral: "—", iv: "1–4 g/day (max 4 g)", im: "0.5–2 g/day (IM with lidocaine)", se: "Biliary sludge/cholecystitis, diarrhea (C. diff), rash, phlebitis, disulfiram-like reaction (cefoperazone)", ci: "Neonates with hyperbilirubinemia, hypersensitivity" },
]);

drugSlide("Antimicrobials", "Macrolides, Fluoroquinolones & Tetracyclines", [
  { name: "Azithromycin (Macrolide)", indication: "Community-acquired pneumonia, atypical pneumonia (Mycoplasma/Chlamydia/Legionella), STIs (Chlamydia), MAC prophylaxis", oral: "500 mg Day 1, then 250 mg Days 2–5 (Z-pack); 1 g single dose (STI)", iv: "500 mg/day", im: "—", se: "GI upset, QT prolongation, cholestatic jaundice (rare), hepatotoxicity", ci: "QT prolongation, torsades history, myasthenia gravis (worsening), hepatic impairment (IV)" },
  { name: "Ciprofloxacin (Fluoroquinolone)", indication: "UTI, traveler's diarrhea, anthrax, typhoid, STIs (gonorrhea), pseudomonal infections", oral: "250–750 mg BID", iv: "200–400 mg q8–12h", im: "—", se: "Tendinopathy/tendon rupture (black box), QT prolongation, CNS effects, phototoxicity, peripheral neuropathy, dysglycemia", ci: "Pregnancy, children <18 (growing cartilage), myasthenia gravis, concurrent QT-prolonging drugs, seizure disorder" },
  { name: "Doxycycline (Tetracycline)", indication: "Atypical pneumonia, Lyme disease, RMSF, malaria prophylaxis/treatment, STIs (Chlamydia/PID), acne, brucellosis", oral: "100 mg BID (loading 200 mg Day 1)", iv: "100–200 mg/day", im: "—", se: "Photosensitivity, GI upset (take with food), esophagitis, tooth discoloration/enamel hypoplasia (children), teratogenicity", ci: "Pregnancy, children <8 years, severe hepatic impairment" },
]);

drugSlide("Antimicrobials", "Metronidazole, Vancomycin & Antifungals", [
  { name: "Metronidazole (Nitroimidazole)", indication: "Anaerobic infections, C. difficile, H. pylori, BV, Trichomonas, amebiasis, Giardia", oral: "400–500 mg TID; 2 g single dose (Trich/BV)", iv: "500 mg q6–8h", im: "—", se: "Metallic taste, nausea, peripheral neuropathy (long-term), seizures (high dose), disulfiram-like reaction with alcohol", ci: "Alcohol consumption (disulfiram-like), first trimester pregnancy (relative), concurrent warfarin (increase INR)" },
  { name: "Vancomycin (Glycopeptide)", indication: "MRSA, C. difficile colitis (PO), MRSA meningitis (IV+IT), severe Gram+ infections", oral: "125–500 mg QID (only for C. diff – not absorbed)", iv: "15–20 mg/kg q8–12h (target AUC/MIC); monitor troughs", im: "Not recommended", se: "Red man syndrome (infuse >60 min), nephrotoxicity, ototoxicity, thrombophlebitis, neutropenia", ci: "Rapid IV infusion, concurrent nephrotoxins (caution), severe allergy to glycopeptides" },
  { name: "Fluconazole (Azole Antifungal)", indication: "Candidiasis (oral, esophageal, vaginal, systemic), Cryptococcal meningitis (consolidation), coccidioidomycosis", oral: "100–400 mg/day (150 mg single dose for vaginal candidiasis)", iv: "Same doses", im: "—", se: "Hepatotoxicity, nausea, headache, QT prolongation, drug interactions (CYP2C9/3A4 inhibitor)", ci: "Concurrent QT-prolonging drugs, pimozide, terfenadine, pregnancy (teratogenic at high doses)" },
  { name: "Amphotericin B (Polyene)", indication: "Invasive fungal infections (Aspergillosis, Cryptococcosis, Candida, Mucormycosis)", oral: "—", iv: "Conventional: 0.3–1 mg/kg/day; Liposomal: 3–5 mg/kg/day", im: "—", se: "Nephrotoxicity (dose-limiting), infusion reactions (fever/chills/rigors), hypokalemia, hypomagnesemia, anemia", ci: "Hypersensitivity; use liposomal form for pre-existing renal impairment" },
]);

// ═══════════════════════════════════════════════════════════════════
// SECTION 5: ENDOCRINE SYSTEM
// ═══════════════════════════════════════════════════════════════════
sectionHeader("Endocrine System", "⚗️", "0D2A1A");

drugSlide("Endocrine", "Antidiabetics – Oral", [
  { name: "Metformin (Biguanide)", indication: "Type 2 DM (first-line), PCOS, pre-diabetes, obesity", oral: "500 mg–2550 mg/day (BID-TID with meals)", iv: "—", im: "—", se: "GI upset (nausea, diarrhea), lactic acidosis (rare, especially renal impairment), B12 deficiency", ci: "eGFR <30 (hold if <45 for contrast), hepatic failure, alcoholism, contrast medium use (hold 48h), heart failure (NYHA III-IV – relative)" },
  { name: "Glibenclamide/Glyburide (Sulfonylurea)", indication: "Type 2 DM", oral: "2.5–20 mg/day (BD)", iv: "—", im: "—", se: "Hypoglycemia (prolonged), weight gain, GI upset, SIADH", ci: "T1DM, renal/hepatic impairment (risk of prolonged hypoglycemia), sulfonamide allergy, pregnancy" },
  { name: "Sitagliptin (DPP-4 inhibitor)", indication: "Type 2 DM (monotherapy or combination)", oral: "100 mg/day (50 mg if eGFR 30–50; 25 mg if eGFR <30)", iv: "—", im: "—", se: "Nasopharyngitis, UTI, pancreatitis (rare), arthralgia, bullous pemphigoid (rare)", ci: "T1DM, DKA, history of pancreatitis (caution), severe renal impairment (dose reduce)" },
  { name: "Empagliflozin (SGLT-2 inhibitor)", indication: "Type 2 DM, CV risk reduction, HFrEF, CKD", oral: "10–25 mg/day", iv: "—", im: "—", se: "Genital mycotic infections, UTI, DKA (euglycemic), polyuria, volume depletion, Fournier's gangrene (rare)", ci: "eGFR <20 (for glycemic), eGFR <45 for most indications, recurrent UTIs, DKA, T1DM" },
]);

drugSlide("Endocrine", "Insulin Types", [
  { name: "Insulin Lispro/Aspart (Rapid-acting)", indication: "T1DM, T2DM prandial coverage, DKA (infusion)", oral: "—", iv: "0.05–0.1 units/kg/hr (DKA infusion) – only regular insulin by IV technically but lispro/aspart can be used in pumps", im: "SC: 0.1–0.2 units/kg per meal (inject 0–15 min before meal)", se: "Hypoglycemia (most important), lipodystrophy at injection sites, weight gain", ci: "Hypoglycemia, hypersensitivity" },
  { name: "Regular Insulin (Short-acting)", indication: "DKA, hyperkalemia (with dextrose), pre-meal coverage, IV infusions", oral: "—", iv: "0.05–0.1 units/kg/hr infusion (DKA); 10 units with 50% dextrose (hyperkalemia)", im: "SC: 0.5–1 unit/kg/day (T1DM total split)", se: "Hypoglycemia, hypokalemia (DKA protocol), lipodystrophy, weight gain", ci: "Hypoglycemia" },
  { name: "NPH Insulin (Intermediate-acting)", indication: "T1DM (basal), T2DM", oral: "—", iv: "—", im: "SC: 0.5–1 unit/kg/day (T1DM basal-bolus regimen)", se: "Hypoglycemia (nocturnal peak), weight gain, lipodystrophy", ci: "Hypoglycemia, hypersensitivity" },
  { name: "Insulin Glargine/Detemir (Long-acting)", indication: "T1DM and T2DM basal insulin coverage", oral: "—", iv: "—", im: "SC: 0.2–0.4 units/kg/day once daily (glargine) or BID (detemir)", se: "Hypoglycemia (less nocturnal than NPH), weight gain, injection site reactions", ci: "Hypoglycemia, hypersensitivity; do NOT mix with other insulins (glargine)" },
]);

drugSlide("Endocrine", "Thyroid & Adrenal Drugs", [
  { name: "Levothyroxine (T4)", indication: "Hypothyroidism, myxedema coma (IV), thyroid cancer (TSH suppression)", oral: "25–200 mcg/day (titrate by TSH)", iv: "200–500 mcg loading (myxedema coma)", im: "—", se: "Hyperthyroid symptoms if over-replaced (tachycardia, weight loss, anxiety, osteoporosis)", ci: "Uncorrected adrenal insufficiency, thyrotoxicosis, recent MI, allergy" },
  { name: "Propylthiouracil (PTU)", indication: "Hyperthyroidism, thyroid storm (preferred in 1st trimester & thyroid storm), Grave's disease", oral: "100–150 mg q8h (maint 50–300 mg/day)", iv: "—", im: "—", se: "Agranulocytosis, hepatotoxicity (black box – fulminant hepatic necrosis), rash, ANCA vasculitis", ci: "Hepatic disease, prior PTU-associated hepatotoxicity; 2nd/3rd trimester pregnancy preferred methimazole" },
  { name: "Prednisolone / Prednisone", indication: "Asthma, RA, IBD, nephrotic syndrome, adrenal insufficiency, allergic reactions, autoimmune diseases", oral: "5–60 mg/day (varies by condition)", iv: "—", im: "—", se: "Cushingoid features, hyperglycemia, osteoporosis, HTN, GI ulceration, infection susceptibility, adrenal suppression, cataract, glaucoma, psychosis", ci: "Active untreated infections, live vaccines during high-dose therapy, GI perforation" },
  { name: "Hydrocortisone", indication: "Adrenal insufficiency (replacement), severe asthma, septic shock (relative adrenal insuff.)", oral: "20–30 mg/day in divided doses (replacement)", iv: "100–300 mg/day (stress doses); 200 mg/day in septic shock", im: "100 mg IM (acute adrenal crisis)", se: "Same as other glucocorticoids; mineralocorticoid effects (Na retention, hypokalemia) at high doses", ci: "Systemic fungal infections, live vaccines (immunosuppressed doses)" },
]);

// ═══════════════════════════════════════════════════════════════════
// SECTION 6: GASTROINTESTINAL
// ═══════════════════════════════════════════════════════════════════
sectionHeader("Gastrointestinal (GI) System", "🫃", "1A0F00");

drugSlide("GI", "Acid Suppression & Prokinetics", [
  { name: "Omeprazole (PPI)", indication: "GERD, peptic ulcer, H. pylori (triple therapy), Zollinger-Ellison syndrome, NSAID gastroprotection", oral: "20–40 mg/day (before meal)", iv: "40 mg/day; 80 mg bolus then 8 mg/hr (bleeding ulcer)", im: "—", se: "Headache, diarrhea, hypomagnesemia (long-term), C. diff risk, B12/Fe deficiency, fracture risk (long-term), CYP2C19 drug interactions", ci: "Concurrent clopidogrel (consider alternative PPI), hypersensitivity, concurrent nelfinavir/rilpivirine" },
  { name: "Ranitidine / Famotidine (H2RA)", indication: "GERD, peptic ulcer, dyspepsia, stress ulcer prophylaxis (famotidine preferred post-ranitidine withdrawal)", oral: "Famotidine: 20–40 mg BID; Ranitidine discontinued (NDMA contamination)", iv: "Famotidine: 20 mg q12h", im: "Famotidine: 20 mg q12h", se: "Headache, dizziness, constipation; IV ranitidine: bradycardia; gynecomastia (cimetidine)", ci: "Porphyria (cimetidine), severe renal impairment (dose reduce)" },
  { name: "Metoclopramide (Prokinetic/Antiemetic)", indication: "GERD, gastroparesis, nausea/vomiting, migraine (adjunct), small bowel intubation", oral: "10 mg TID (before meals)", iv: "10–20 mg slow IV", im: "10–20 mg IM", se: "EPS/tardive dyskinesia (black box – >3 months), drowsiness, hyperprolactinemia, depression", ci: "GI obstruction/perforation, Parkinson's disease, pheochromocytoma, seizure disorder, prolactin-dependent tumor" },
  { name: "Ondansetron (5-HT3 antagonist)", indication: "PONV, chemotherapy-induced N&V, radiation-induced N&V, hyperemesis gravidarum", oral: "4–8 mg BID-TID", iv: "4–8 mg slow IV", im: "4–8 mg IM", se: "Headache, constipation, QT prolongation (dose-dependent), serotonin syndrome (rare)", ci: "Congenital long QT, concurrent apomorphine, concurrent QT-prolonging drugs" },
]);

drugSlide("GI", "Laxatives, Antidiarrheals & IBD Drugs", [
  { name: "Mesalazine / 5-ASA", indication: "Ulcerative colitis (induction & maintenance), Crohn's (limited efficacy)", oral: "2–4 g/day (varied formulations)", iv: "—", im: "—", se: "GI upset, nephrotoxicity (interstitial nephritis – rare), rash, headache", ci: "Salicylate allergy, severe renal impairment, G6PD deficiency (risk of hemolysis)" },
  { name: "Infliximab (Anti-TNF biologic)", indication: "Crohn's disease, UC, RA, AS, psoriasis, psoriatic arthritis, fistulizing Crohn's", oral: "—", iv: "5–10 mg/kg infusion at 0, 2, 6 wks, then q8wks", im: "—", se: "Infection risk (TB reactivation – screen beforehand), infusion reactions, lymphoma, demyelination, worsening HF", ci: "Active infection/sepsis, TB (until treated), HIV, severe HF (NYHA III-IV), malignancy (recent)" },
  { name: "Loperamide (Antidiarrheal)", indication: "Acute & chronic diarrhea, IBS-D", oral: "4 mg initial dose, then 2 mg after each loose stool (max 16 mg/day)", iv: "—", im: "—", se: "Constipation, abdominal cramping, toxic megacolon (in IBD/C. diff – contraindicated)", ci: "Bloody diarrhea/dysentery, pseudomembranous colitis, IBD acute flare, children <2 yrs" },
]);

// ═══════════════════════════════════════════════════════════════════
// SECTION 7: ANTICOAGULANTS & ANTIPLATELETS
// ═══════════════════════════════════════════════════════════════════
sectionHeader("Anticoagulants & Antiplatelets", "🩸", "2A0505");

drugSlide("Anticoagulants", "Anticoagulants", [
  { name: "Heparin (UFH)", indication: "VTE treatment/prophylaxis, ACS, PE, DVT, AF (bridging), DIC, ECMO/dialysis circuit", oral: "—", iv: "80 units/kg bolus then 18 units/kg/hr (therapeutic); monitor APTT 1.5–2.5× normal", im: "Not recommended (hematoma)", se: "HIT (heparin-induced thrombocytopenia – check platelet day 5–10), hemorrhage, osteoporosis (long-term), hypoaldosteronism", ci: "HIT, active bleeding, severe thrombocytopenia, intracranial hemorrhage; antidote: Protamine sulfate" },
  { name: "Enoxaparin (LMWH)", indication: "VTE prophylaxis/treatment, ACS (NSTEMI), bridging therapy", oral: "—", iv: "—", im: "Prophylaxis: 40 mg SC OD; Treatment DVT/PE: 1 mg/kg SC q12h", se: "Bleeding, HIT (less than UFH), thrombocytopenia, injection site bruising, hyperkalemia", ci: "Active major bleeding, HIT, eGFR <30 (use UFH or adjust dose), spinal/epidural anesthesia (timing required); antidote: Protamine sulfate (partial)" },
  { name: "Warfarin (Vitamin K antagonist)", indication: "AF (stroke prevention), VTE (treatment/secondary prevention), mechanical heart valves, antiphospholipid syndrome", oral: "2–10 mg/day (titrate to INR 2–3; INR 2.5–3.5 for mechanical valves)", iv: "—", im: "—", se: "Hemorrhage (major), skin necrosis (protein C/S deficiency), purple toe syndrome, teratogenicity, drug/food interactions (Vit K)", ci: "Pregnancy, active bleeding, poorly controlled HTN, recent surgery (relative), non-compliant patient; antidote: Vitamin K, FFP, 4-factor PCC" },
  { name: "Rivaroxaban (Direct Xa inhibitor)", indication: "AF (stroke prevention), VTE treatment/prophylaxis, post-arthroplasty prophylaxis, ACS adjunct", oral: "10–20 mg OD with food (dose varies by indication)", iv: "—", im: "—", se: "Bleeding, hepatotoxicity (rare), wound complications", ci: "Active major bleeding, severe hepatic impairment (Child-Pugh C), pregnancy, eGFR <15; antidote: Andexanet alfa" },
  { name: "Dabigatran (Direct thrombin inhibitor)", indication: "AF (stroke prevention), VTE treatment/prophylaxis", oral: "150 mg BID (110 mg BID if >80 yr or bleeding risk); 220 mg OD (post-surgery prophylaxis)", iv: "—", im: "—", se: "Bleeding, GI upset (dyspepsia), GI bleeding (higher than warfarin)", ci: "Severe renal impairment (eGFR <30), mechanical heart valves, active bleeding, severe hepatic disease; antidote: Idarucizumab" },
]);

drugSlide("Anticoagulants", "Antiplatelet Agents", [
  { name: "Aspirin (low-dose antiplatelet)", indication: "ACS secondary prevention, PCI post-stenting (DAPT), stroke (ischemic) prevention, MI prophylaxis", oral: "75–325 mg/day", iv: "—", im: "—", se: "GI bleeding, peptic ulcer, bronchospasm (aspirin-sensitive), Reye's syndrome (children)", ci: "Active peptic ulcer, bleeding disorders, aspirin allergy, children with viral illness" },
  { name: "Clopidogrel (P2Y12 inhibitor)", indication: "ACS, post-PCI DAPT (with aspirin), peripheral artery disease, stroke prevention", oral: "75 mg/day (loading: 300–600 mg)", iv: "—", im: "—", se: "Bleeding, thrombotic thrombocytopenic purpura (TTP – rare), GI upset, rash, neutropenia (rare)", ci: "Active bleeding, severe hepatic impairment; avoid with omeprazole/esomeprazole (CYP2C19 interaction)" },
  { name: "Ticagrelor (P2Y12 inhibitor)", indication: "ACS (superior to clopidogrel in ACS), post-ACS maintenance", oral: "Loading: 180 mg; Maint: 90 mg BID (for 12 months then 60 mg BID)", iv: "—", im: "—", se: "Dyspnea (bradykinin-related, not bronchospasm), bleeding, bradycardia, headache, hyperuricemia", ci: "Active bleeding, prior intracranial hemorrhage, severe hepatic impairment, concurrent strong CYP3A4 inhibitors, high-dose aspirin (>100 mg/day)" },
]);

// ═══════════════════════════════════════════════════════════════════
// SECTION 8: RENAL & UROLOGY
// ═══════════════════════════════════════════════════════════════════
sectionHeader("Renal & Genitourinary", "🫘", "001A2A");

drugSlide("Renal/GU", "Drugs in Renal & Urological Conditions", [
  { name: "Tamsulosin (Alpha-1 blocker)", indication: "BPH, ureteric stones (medical expulsive therapy)", oral: "0.4–0.8 mg/day (after meals)", iv: "—", im: "—", se: "Orthostatic hypotension, dizziness, retrograde ejaculation, intraoperative floppy iris syndrome", ci: "Concurrent strong CYP3A4 inhibitors (ketoconazole), severe hepatic impairment, concurrent PDE5 inhibitors (significant hypotension)" },
  { name: "Finasteride (5-alpha reductase inhibitor)", indication: "BPH, androgenic alopecia", oral: "5 mg/day (BPH); 1 mg/day (alopecia)", iv: "—", im: "—", se: "Sexual dysfunction (ED, decreased libido, ejaculatory disorder), gynecomastia, teratogenicity (crushed tabs – pregnant women avoid contact)", ci: "Pregnancy/women of childbearing potential, children" },
  { name: "Desmopressin (ADH analogue)", indication: "Central DI, nocturia, nocturnal enuresis, von Willebrand disease (type I), hemophilia A (mild)", oral: "0.1–0.4 mg BID-TID; Intranasal: 10–40 mcg/day", iv: "0.3 mcg/kg infusion over 15–30 min (vWD/hemophilia)", im: "0.3 mcg/kg IM (emergency)", se: "Hyponatremia (dilutional), water retention, seizures (from hyponatremia), headache, flushing", ci: "Polydipsia, psychogenic polydipsia, hyponatremia, moderate-severe renal impairment (eGFR<50), vWD type IIB" },
]);

// ═══════════════════════════════════════════════════════════════════
// SECTION 9: CHEMOTHERAPY / ONCOLOGY
// ═══════════════════════════════════════════════════════════════════
sectionHeader("Oncology / Chemotherapy", "💊", "0F1A0A");

drugSlide("Oncology", "Key Chemotherapy Agents", [
  { name: "Methotrexate (Antimetabolite – DHFR inhibitor)", indication: "Leukemia (ALL), RA, psoriasis, ectopic pregnancy, osteosarcoma, lymphoma", oral: "RA: 7.5–25 mg/week; Psoriasis: 10–25 mg/week", iv: "High-dose: 1–12 g/m² (with leucovorin rescue)", im: "15–30 mg/week (RA/psoriasis)", se: "Hepatotoxicity, pulmonary toxicity (pneumonitis), bone marrow suppression, mucositis, teratogenicity, renal toxicity (HD-MTX), folate deficiency", ci: "Pregnancy, breastfeeding, significant renal/hepatic impairment, immunodeficiency, active infection, pleural effusion/ascites (high-dose)" },
  { name: "Cyclophosphamide (Alkylating agent)", indication: "Lymphoma, leukemia, multiple myeloma, solid tumors, SLE nephritis, vasculitis, RA (severe)", oral: "1–5 mg/kg/day", iv: "600–1000 mg/m² q3–4wks (pulsed)", im: "—", se: "Hemorrhagic cystitis (MESNA prevents), bone marrow suppression, alopecia, SIADH, infertility, secondary malignancy (bladder cancer)", ci: "Pregnancy, severe bone marrow suppression, urinary tract obstruction; always co-administer MESNA" },
  { name: "Doxorubicin (Anthracycline)", indication: "Breast cancer, leukemia, lymphoma, sarcoma, multiple myeloma, thyroid cancer", oral: "—", iv: "60–75 mg/m² q3wks (cumulative lifetime max ~500 mg/m²)", im: "—", se: "Cardiotoxicity (dilated CMP – dose-dependent, irreversible), alopecia, mucositis, bone marrow suppression, hand-foot syndrome (pegylated liposomal), red/orange urine", ci: "Severe cardiac impairment (LVEF<40%), cumulative dose exceeded, severe hepatic dysfunction, prior mediastinal radiation to heart" },
  { name: "Cisplatin (Platinum compound)", indication: "Testicular, ovarian, lung, bladder, head & neck cancers, cervical cancer", oral: "—", iv: "50–100 mg/m² per cycle (with aggressive pre-hydration)", im: "—", se: "Nephrotoxicity (dose-limiting – hydrate aggressively), peripheral neuropathy, ototoxicity (high-frequency hearing loss), severe nausea/vomiting, myelosuppression, hypomagnesemia, hypokalemia", ci: "Pre-existing renal impairment, pre-existing neuropathy, hearing impairment, pregnancy, bone marrow failure" },
]);

// ═══════════════════════════════════════════════════════════════════
// SECTION 10: MUSCULOSKELETAL
// ═══════════════════════════════════════════════════════════════════
sectionHeader("Musculoskeletal System", "🦴", "1A0A0A");

drugSlide("Musculoskeletal", "DMARDs, Gout & Bone Drugs", [
  { name: "Allopurinol (Xanthine oxidase inhibitor)", indication: "Gout (chronic prophylaxis), hyperuricemia (tumor lysis syndrome)", oral: "100–800 mg/day (start low, titrate)", iv: "200–400 mg/m²/day (TLS)", im: "—", se: "SJS/TEN (especially HLA-B*5801 – Asian populations), rash, hepatotoxicity, bone marrow suppression, GI upset", ci: "Acute gout attack (don't initiate during), concurrent azathioprine (toxic accumulation – reduce AZA dose by 75%), HLA-B*5801 in Asians" },
  { name: "Colchicine (Alkaloid)", indication: "Acute gout attack, gout prophylaxis, pericarditis, FMF", oral: "1.2 mg then 0.6 mg 1 hr later (acute gout); 0.5–1 mg/day (prophylaxis)", iv: "Not recommended (severe toxicity)", im: "—", se: "GI toxicity (diarrhea, nausea, vomiting – dose-limiting), bone marrow suppression (overdose), myopathy, neuropathy", ci: "Severe renal impairment (GFR<30), severe hepatic impairment, concurrent strong CYP3A4 inhibitors (clarithromycin, ritonavir) – life-threatening toxicity" },
  { name: "Alendronate (Bisphosphonate)", indication: "Osteoporosis (postmenopausal, glucocorticoid-induced), Paget's disease, bone metastases (zoledronate)", oral: "70 mg once weekly (osteoporosis prevention/treatment); take fasted with full glass of water, remain upright 30 min", iv: "—", im: "—", se: "Esophagitis/esophageal ulceration, GI upset, osteonecrosis of jaw (ONJ), atypical femur fracture (long-term), hypocalcemia, atrial fibrillation (IV)", ci: "Esophageal abnormalities (stricture, achalasia), inability to remain upright 30 min, hypocalcemia, severe renal impairment (GFR<35)" },
  { name: "Hydroxychloroquine (DMARD/Antimalarial)", indication: "RA, SLE, malaria treatment/prophylaxis, Sjögren's syndrome", oral: "200–400 mg/day (≤5 mg/kg actual body weight/day)", iv: "—", im: "—", se: "Retinopathy (dose/duration-dependent – annual eye exam after 5 yrs), cardiomyopathy, QT prolongation, GI upset, rash, hypoglycemia", ci: "Pre-existing retinopathy, G6PD deficiency (risk of hemolysis), porphyria, QT prolongation" },
]);

// ═══════════════════════════════════════════════════════════════════
// CLOSING / SUMMARY SLIDE
// ═══════════════════════════════════════════════════════════════════
const sl = pres.addSlide();
sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: "100%", h: "100%", fill: { color: C.darkbg } });
sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: "100%", h: 0.06, fill: { color: C.gold } });
sl.addShape(pres.ShapeType.rect, { x: 0, y: 7.44, w: "100%", h: 0.06, fill: { color: C.gold } });
sl.addText("Systems Covered in This Reference", { x: 0.5, y: 0.5, w: 12.3, h: 0.8, fontSize: 26, bold: true, color: C.gold, align: "center" });

const systems = [
  ["❤️ Cardiovascular", "ACE-I, ARBs, Beta-blockers, CCBs, Diuretics, Antiarrhythmics, Nitrates, Statins"],
  ["🫁 Respiratory", "SABAs, LABAs, SAMAs, LAMAs, Theophylline, ICS, Montelukast"],
  ["🧠 CNS / Neurological", "Opioids, NSAIDs, Paracetamol, AEDs, Antidepressants (SSRI/SNRI/TCA), Antipsychotics, Benzodiazepines"],
  ["🦠 Antimicrobials", "Penicillins, Cephalosporins, Macrolides, Fluoroquinolones, Tetracyclines, Metronidazole, Vancomycin, Antifungals"],
  ["⚗️ Endocrine", "Oral antidiabetics (Metformin/SU/DPP4/SGLT2), Insulin types, Thyroid drugs, Corticosteroids"],
  ["🫃 Gastrointestinal", "PPIs, H2RAs, Prokinetics, Antiemetics, 5-ASA, Anti-TNF biologics, Loperamide"],
  ["🩸 Anticoagulants / Antiplatelets", "UFH, LMWH, Warfarin, DOACs (Rivaroxaban/Dabigatran), Aspirin, Clopidogrel, Ticagrelor"],
  ["🫘 Renal / GU", "Alpha-blockers, 5-ARIs, Desmopressin"],
  ["💊 Oncology", "MTX, Cyclophosphamide, Doxorubicin, Cisplatin"],
  ["🦴 Musculoskeletal", "Allopurinol, Colchicine, Bisphosphonates, Hydroxychloroquine"],
];

const cols = 2, rows = 5, cw = 6.3, ch = 1.1;
systems.forEach(([title, drugs], i) => {
  const col = i % cols;
  const row = Math.floor(i / cols);
  const x = 0.3 + col * (cw + 0.4);
  const y = 1.5 + row * (ch + 0.1);
  sl.addShape(pres.ShapeType.rect, { x, y, w: cw, h: ch, fill: { color: "1A2A3A" }, line: { color: C.teal, width: 1.0 } });
  sl.addText([
    { text: title + "\n", options: { bold: true, fontSize: 12, color: C.gold, breakLine: false } },
    { text: drugs, options: { fontSize: 9, color: C.lgray } }
  ], { x: x + 0.1, y: y + 0.05, w: cw - 0.2, h: ch - 0.1, valign: "top" });
});

sl.addText("For clinical use, always verify doses against local formulary and patient-specific factors.", { x: 0.5, y: 7.1, w: 12.3, h: 0.3, fontSize: 10, color: C.lgray, align: "center", italic: true });

// WRITE FILE
pres.writeFile({ fileName: "/home/daytona/workspace/pharmacology-reference/SystemWise_Pharmacology_Reference.pptx" })
  .then(() => console.log("✅ PPTX written successfully"))
  .catch(e => console.error("❌ Error:", e));
Your credits are exhausted. Your daily credits reset tomorrow, or you can purchase a top-up for more.
This is a shared conversation. Sign in to Orris to start your own chat.