Can you make pharmacology cards that look like these pictures

Asking for Preferences
Please go ahead and upload your reference pictures! Once I can see the style/layout you're going for, I'll also need to know:
  1. Which drugs or drug classes do you want cards for? (e.g., beta-blockers, ACE inhibitors, antibiotics, etc.)
  2. What format do you want the output in? (e.g., PDF, PowerPoint slides, image files, printable Word doc)
attachment
attachment
attachment
attachment
attachment
attachment

Can you make pharmacology notes like these , put the medication picture in middle and write notes on sides , make it pdf if possible

Asking for Preferences
Asking for Preferences
Reading File
Running Command

mkdir -p /home/daytona/workspace/pharmcards && ls /home/daytona/workspace/pharmcards

Writing File

~/pharmcards/generate_cards.py

"""
Pharmacology Cards PDF Generator
Style: Drug name + class at top, illustration in center, colored notes on sides
"""

from reportlab.lib.pagesizes import A4
from reportlab.lib import colors
from reportlab.lib.units import mm, cm
from reportlab.pdfgen import canvas
from reportlab.lib.colors import HexColor, white, black
from reportlab.platypus import Paragraph
from reportlab.lib.styles import ParagraphStyle
from reportlab.lib.enums import TA_LEFT, TA_CENTER
import math

# ── Colour palette (matches the warm pastel + red-accent style) ──────────────
BG          = HexColor("#FDFAF5")      # warm off-white page
HEADER_BG   = HexColor("#1A1A2E")      # dark navy header band
DRUG_NAME   = HexColor("#FFFFFF")
CLASS_NAME  = HexColor("#FFD700")      # gold subtitle
SECTION_DIVIDER = HexColor("#E8E0D0")

# Section tag colours (matching coloured labels in the reference)
COL_MECHANISM  = HexColor("#D64045")   # red
COL_PK         = HexColor("#4A90D9")   # blue
COL_DOSE       = HexColor("#E8A838")   # amber
COL_INDIC      = HexColor("#3DAA6B")   # green
COL_CI         = HexColor("#9B59B6")   # purple
COL_ADR        = HexColor("#E05C2A")   # orange
COL_INTERACT   = HexColor("#2C7873")   # teal

# Section label text colours (white text on coloured badge)
LABEL_TXT = white

# Page dimensions
W, H = A4          # 595.27 x 841.89 pt
MARGIN = 18 * mm
HEADER_H = 52 * mm
FOOTER_H = 12 * mm
CARD_AREA_TOP    = H - MARGIN - HEADER_H
CARD_AREA_BOTTOM = MARGIN + FOOTER_H

# Column widths
CENTER_W = 110 * mm
SIDE_W   = (W - 2 * MARGIN - CENTER_W) / 2   # ~58mm each

LEFT_X   = MARGIN
CENTER_X = MARGIN + SIDE_W
RIGHT_X  = MARGIN + SIDE_W + CENTER_W


# ── Drug data ─────────────────────────────────────────────────────────────────
DRUG_DATA = [

    # ══════════════════════════════════════════════════════
    # SECTION DIVIDER
    # ══════════════════════════════════════════════════════
    {"_section": "CARDIOVASCULAR DRUGS"},

    # ── Beta-blockers ──────────────────────────────────────
    {
        "name": "Metoprolol",
        "class": "Beta-1 Selective Blocker",
        "drug_type": "pill",
        "color": HexColor("#C0392B"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Selective β1-adrenergic antagonist → ↓ HR, ↓ contractility, ↓ renin release; minimal β2 effects at therapeutic doses"),
            ("Contraindications", COL_CI,
             "Cardiogenic shock · Decompensated HF · Severe bradycardia · 2nd/3rd degree AV block · Sick-sinus syndrome"),
            ("Interactions", COL_INTERACT,
             "Verapamil/diltiazem → additive bradycardia · MAOIs · Clonidine withdrawal rebound"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV · Bioavailability 50% (first-pass) · t½ 3–7 h · Hepatic metabolism (CYP2D6) · Not renal-adjusted normally"),
            ("Dose", COL_DOSE,
             "HTN: 25–100 mg PO BID\nAngina: 50–200 mg PO BID\nHF (succinate): 12.5–200 mg PO OD\nAMI: 5 mg IV q5 min × 3"),
            ("Indications", COL_INDIC,
             "Hypertension · Angina · HFrEF · Post-MI · Atrial fibrillation rate control · SVT"),
            ("Side Effects", COL_ADR,
             "Fatigue · Bradycardia · Cold extremities · Impotence · Masking hypoglycaemia · Bronchospasm (high dose)"),
        ],
    },
    {
        "name": "Atenolol",
        "class": "Beta-1 Selective Blocker",
        "drug_type": "pill",
        "color": HexColor("#922B21"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Cardioselective β1-blocker → ↓ HR and BP; does NOT cross BBB well (fewer CNS effects)"),
            ("Contraindications", COL_CI,
             "Bronchospastic disease · Severe bradycardia · AV block 2nd/3rd · Hypotension"),
            ("Interactions", COL_INTERACT,
             "NSAIDs ↓ antihypertensive effect · Insulin masks hypoglycaemia symptoms · CCBs additive bradycardia"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO · Bioavailability 50% · t½ 6–9 h · Renal excretion (dose-reduce in CKD) · Hydrophilic"),
            ("Dose", COL_DOSE,
             "HTN: 25–100 mg PO OD\nAngina: 50–100 mg PO OD\nMax: 200 mg/day"),
            ("Indications", COL_INDIC,
             "Hypertension · Angina pectoris · Post-MI · Rate control in AF"),
            ("Side Effects", COL_ADR,
             "Bradycardia · Fatigue · Cold extremities · Hypotension · Less CNS effects than propranolol"),
        ],
    },
    {
        "name": "Propranolol",
        "class": "Non-selective Beta-Blocker",
        "drug_type": "pill",
        "color": HexColor("#6C3483"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Non-selective β1 + β2 antagonist → ↓ HR, ↓ contractility, ↓ renin; also membrane-stabilising (Class II antiarrhythmic)"),
            ("Contraindications", COL_CI,
             "Asthma / COPD (β2 block → bronchospasm) · Raynaud's · Decompensated HF · AV block"),
            ("Interactions", COL_INTERACT,
             "Epinephrine → severe hypertension · Rifampin ↑ metabolism · Cimetidine ↑ propranolol levels"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV · High first-pass ~70% · t½ 3–6 h · Hepatic · Lipophilic (crosses BBB)"),
            ("Dose", COL_DOSE,
             "HTN: 40–160 mg PO BID\nMigraine prophylaxis: 40–240 mg/day\nEsophageal varices: 20–40 mg BID\nThyroid storm: 60–80 mg q4h"),
            ("Indications", COL_INDIC,
             "HTN · Angina · Arrhythmias · Migraine prophylaxis · Essential tremor · Thyroid storm · Pheochromocytoma (with alpha-blocker)"),
            ("Side Effects", COL_ADR,
             "Bronchospasm · Nightmares · Depression · Bradycardia · ↑ TG · Cold extremities"),
        ],
    },

    # ── ACE Inhibitors ────────────────────────────────────
    {"_section": "ACE INHIBITORS"},
    {
        "name": "Lisinopril",
        "class": "ACE Inhibitor",
        "drug_type": "pill",
        "color": HexColor("#1A5276"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Inhibits ACE → ↓ Angiotensin II → vasodilation + ↓ aldosterone → ↓ preload & afterload; ↑ bradykinin (→ cough)"),
            ("Contraindications", COL_CI,
             "Pregnancy (teratogenic) · Bilateral renal artery stenosis · History of ACE-inhibitor angioedema · Hyperkalemia"),
            ("Interactions", COL_INTERACT,
             "K-sparing diuretics → hyperkalemia · NSAIDs ↓ efficacy + ↑ nephrotoxicity · Lithium toxicity ↑"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO · Bioavailability 25% · t½ 12 h · Renal excretion (dose-reduce CKD) · Not hepatically metabolised"),
            ("Dose", COL_DOSE,
             "HTN: 5–40 mg PO OD\nHF: 2.5–40 mg PO OD\nPost-MI: 5–10 mg OD\nDiabetic nephropathy: 10–40 mg OD"),
            ("Indications", COL_INDIC,
             "Hypertension · HFrEF · Post-MI · Diabetic nephropathy · CKD proteinuria"),
            ("Side Effects", COL_ADR,
             "Dry cough (bradykinin) · Angioedema · Hyperkalemia · ↑ Creatinine (1st-use) · Hypotension (1st dose)"),
        ],
    },
    {
        "name": "Enalapril",
        "class": "ACE Inhibitor (Prodrug)",
        "drug_type": "pill",
        "color": HexColor("#154360"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Prodrug → enalaprilat (active) · Inhibits ACE → ↓ AII · Also ↑ bradykinin and prostaglandins → vasodilation"),
            ("Contraindications", COL_CI,
             "Pregnancy · Angioedema history · Bilateral RAS · Severe hyperkalemia · Concurrent aliskiren in DM"),
            ("Interactions", COL_INTERACT,
             "Diuretics (1st dose hypotension) · Aliskiren (DM/CKD contraindicated) · NSAIDs"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV (enalaprilat) · Hydrolysed in liver to active form · t½ 11 h · Renal excretion"),
            ("Dose", COL_DOSE,
             "HTN: 5–40 mg PO OD–BID\nHF: 2.5–20 mg PO BID\nIV (enalaprilat): 1.25 mg q6h"),
            ("Indications", COL_INDIC,
             "Hypertension · HFrEF (CONSENSUS trial showed ↓ mortality) · LV dysfunction post-MI"),
            ("Side Effects", COL_ADR,
             "Cough · Angioedema · Hypotension · Hyperkalemia · Renal impairment"),
        ],
    },

    # ── ARBs ──────────────────────────────────────────────
    {"_section": "ANGIOTENSIN RECEPTOR BLOCKERS (ARBs)"},
    {
        "name": "Losartan",
        "class": "Angiotensin Receptor Blocker",
        "drug_type": "pill",
        "color": HexColor("#1E8BC3"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Selective AT1 receptor antagonist → blocks AII effects (vasoconstriction, aldosterone release) · Does NOT affect bradykinin → no cough"),
            ("Contraindications", COL_CI,
             "Pregnancy · Bilateral RAS · Hyperkalemia · Concurrent ACEi + aliskiren in DM/CKD"),
            ("Interactions", COL_INTERACT,
             "K-sparing diuretics → hyperkalemia · Rifampin ↓ levels · Fluconazole ↑ levels (CYP2C9)"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO · Bioavailability 33% · Converted to active metabolite E-3174 (CYP2C9) · t½ losartan 2h, E-3174 6–9h · Fecal + renal"),
            ("Dose", COL_DOSE,
             "HTN: 25–100 mg PO OD–BID\nDiabetic nephropathy: 50–100 mg OD\nHF: 25–150 mg OD"),
            ("Indications", COL_INDIC,
             "Hypertension · HFrEF (ACEi intolerant) · Diabetic nephropathy type 2 · Stroke prevention (with HTN + LVH)"),
            ("Side Effects", COL_ADR,
             "Hyperkalemia · Hypotension · Dizziness · ↑ Creatinine · Angioedema (rare, <ACEi)"),
        ],
    },

    # ── Calcium Channel Blockers ──────────────────────────
    {"_section": "CALCIUM CHANNEL BLOCKERS"},
    {
        "name": "Amlodipine",
        "class": "Dihydropyridine CCB",
        "drug_type": "pill",
        "color": HexColor("#117A65"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Blocks L-type Ca²⁺ channels in vascular smooth muscle → vasodilation (peripheral + coronary) · Minimal cardiac conduction effect"),
            ("Contraindications", COL_CI,
             "Severe aortic stenosis · Cardiogenic shock · Unstable angina (without nitrates)"),
            ("Interactions", COL_INTERACT,
             "CYP3A4 inhibitors (clarithromycin, ketoconazole) ↑ levels · Simvastatin max 20 mg with amlodipine 10 mg"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO · Bioavailability 64–90% · t½ 30–50 h (once-daily dosing) · Hepatic CYP3A4 · 60% renal, 20–25% feces"),
            ("Dose", COL_DOSE,
             "HTN/Angina: 2.5–10 mg PO OD\nStart 5 mg, titrate over 7–14 days\nElderly/hepatic: start 2.5 mg"),
            ("Indications", COL_INDIC,
             "Hypertension · Stable angina · Vasospastic (Prinzmetal) angina · Raynaud's phenomenon"),
            ("Side Effects", COL_ADR,
             "Peripheral oedema (ankle) · Flushing · Headache · Reflex tachycardia · Gingival hyperplasia"),
        ],
    },
    {
        "name": "Verapamil",
        "class": "Non-dihydropyridine CCB",
        "drug_type": "pill",
        "color": HexColor("#0E6655"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Blocks L-type Ca²⁺ channels in HEART (SA/AV node) + smooth muscle → ↓ HR, ↓ AV conduction, vasodilation · Class IV antiarrhythmic"),
            ("Contraindications", COL_CI,
             "WPW syndrome (→ VF risk) · Cardiogenic shock · Sick sinus · 2nd/3rd AV block · With beta-blockers IV"),
            ("Interactions", COL_INTERACT,
             "Beta-blockers (IV): severe bradycardia/asystole · Digoxin ↑ levels · CYP3A4 substrate + inhibitor · Colchicine toxicity ↑"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV · Bioavailability 20–35% (high first-pass) · t½ 6–8 h (IR), 12 h (SR) · Hepatic metabolism · 70% renal"),
            ("Dose", COL_DOSE,
             "HTN: 80–120 mg PO TID (IR) or 120–240 mg OD (SR)\nSVT IV: 5–10 mg IV bolus over 2 min\nRate control: 120–360 mg/day"),
            ("Indications", COL_INDIC,
             "HTN · Angina · Rate control in AF/flutter · PSVT termination · Cluster headache prevention"),
            ("Side Effects", COL_ADR,
             "Constipation · Bradycardia · AV block · Hypotension · Peripheral oedema · Negative inotropy"),
        ],
    },

    # ── Diuretics ────────────────────────────────────────
    {"_section": "DIURETICS"},
    {
        "name": "Furosemide",
        "class": "Loop Diuretic",
        "drug_type": "pill",
        "color": HexColor("#F39C12"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Inhibits Na⁺/K⁺/2Cl⁻ cotransporter (NKCC2) in thick ascending loop of Henle → ↑ excretion of Na⁺, K⁺, Cl⁻, Ca²⁺, Mg²⁺, H₂O"),
            ("Contraindications", COL_CI,
             "Anuria · Sulfonamide allergy (cross-reactivity) · Hepatic coma (if electrolyte imbalance present) · Hypovolemia"),
            ("Interactions", COL_INTERACT,
             "Aminoglycosides → ototoxicity ↑ · NSAIDs ↓ efficacy · Digoxin toxicity ↑ (hypokalemia) · Lithium toxicity"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV / IM · Bioavailability PO 50–60% · Onset IV 5 min, PO 30–60 min · Duration 2h (IV), 6–8h (PO) · Renal excretion"),
            ("Dose", COL_DOSE,
             "Oedema: 20–80 mg PO/IV OD–BID\nAcute pulmonary oedema: 40–100 mg IV\nHTN: 40–80 mg PO BID\nMax: 600 mg/day"),
            ("Indications", COL_INDIC,
             "Acute pulmonary oedema · HF · Hepatic ascites · Nephrotic syndrome · Hypercalcaemia · Hypertensive urgency"),
            ("Side Effects", COL_ADR,
             "Hypokalemia · Hyponatremia · Hypomagnesaemia · Metabolic alkalosis · Ototoxicity (high dose IV) · Hyperuricemia"),
        ],
    },
    {
        "name": "Hydrochlorothiazide",
        "class": "Thiazide Diuretic",
        "drug_type": "pill",
        "color": HexColor("#D35400"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Inhibits Na⁺/Cl⁻ cotransporter (NCC) in distal convoluted tubule → ↑ Na⁺, Cl⁻ excretion · ↑ Ca²⁺ reabsorption (unique vs loop)"),
            ("Contraindications", COL_CI,
             "Anuria · Sulfonamide allergy · Hyponatremia / hypokalemia · Gout (relative) · Pregnancy (1st trimester, relative)"),
            ("Interactions", COL_INTERACT,
             "Digoxin toxicity ↑ (hypokalemia) · NSAIDs ↓ antihypertensive effect · Lithium ↑ toxicity · Antidiabetics ↓ efficacy"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO only · Bioavailability 60–80% · Onset 2h · Duration 6–12h · t½ 6–15h · Renal excretion unchanged"),
            ("Dose", COL_DOSE,
             "HTN: 12.5–25 mg PO OD\nOedema: 25–100 mg PO OD\nDiabetes insipidus: 25 mg OD\nHypercalciuria: 25–50 mg OD"),
            ("Indications", COL_INDIC,
             "Hypertension · Oedema · Heart failure · Diabetes insipidus (nephrogenic) · Hypercalciuria · Osteoporosis prevention"),
            ("Side Effects", COL_ADR,
             "Hypokalemia · Hyperuricemia · Hyperglycemia · Hyponatremia · Hyperlipidemia · Erectile dysfunction · Photosensitivity"),
        ],
    },
    {
        "name": "Spironolactone",
        "class": "Potassium-Sparing Diuretic",
        "drug_type": "pill",
        "color": HexColor("#8E44AD"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Aldosterone receptor antagonist → blocks Na⁺ reabsorption + K⁺ excretion in collecting duct · Also blocks androgen receptors"),
            ("Contraindications", COL_CI,
             "Hyperkalemia (K⁺ >5.5) · Addison's disease · Severe renal failure · Concurrent K⁺ supplements + ACEi/ARB (caution)"),
            ("Interactions", COL_INTERACT,
             "ACEi/ARBs → severe hyperkalemia · Digoxin interference (spironolactone ↑ digoxin half-life) · NSAIDs ↓ efficacy"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO · Bioavailability 60–90% · Prodrug → active canrenone · t½ spironolactone 1.4h, canrenone 16–23h · Hepatic metabolism"),
            ("Dose", COL_DOSE,
             "HFrEF: 12.5–50 mg PO OD\nHTN: 25–100 mg OD\nAscites: 100–400 mg OD\nHyperaldosteronism: 100–400 mg OD"),
            ("Indications", COL_INDIC,
             "HFrEF (RALES trial ↓ mortality) · Primary hyperaldosteronism · Resistant HTN · Ascites · Hirsutism / acne in women"),
            ("Side Effects", COL_ADR,
             "Hyperkalemia · Gynecomastia (anti-androgen) · Menstrual irregularities · Metabolic acidosis · GI upset"),
        ],
    },

    # ══════════════════════════════════════════════════════
    # CNS DRUGS
    # ══════════════════════════════════════════════════════
    {"_section": "CNS / NEUROLOGICAL DRUGS"},
    {
        "name": "Midazolam",
        "class": "Benzodiazepine",
        "drug_type": "ampoule",
        "color": HexColor("#F1C40F"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Positive allosteric modulator of GABA-A receptor → ↑ Cl⁻ influx → hyperpolarisation · ↑ frequency of Cl⁻ channel opening"),
            ("Contraindications", COL_CI,
             "Acute narrow-angle glaucoma · Pregnancy (1st trimester) · Myasthenia gravis · Obstructive sleep apnea (caution)"),
            ("Interactions", COL_INTERACT,
             "CNS depressants (opioids, alcohol) → respiratory depression · CYP3A4 inhibitors ↑ midazolam levels · Flumazenil (reversal)"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV / IM / Intranasal · Bioavailability PO 36%, IN 50% · t½ 1.5–2.5h · CYP3A4 hepatic · Active metabolite 1-OH-midazolam"),
            ("Dose", COL_DOSE,
             "Sedation IV: 0.01–0.05 mg/kg titrate\nSeizures (status): 0.1–0.2 mg/kg IV/IM\nPre-op: 0.07–0.08 mg/kg IM\nPediatric IN: 0.2 mg/kg"),
            ("Indications", COL_INDIC,
             "Pre-operative sedation · Procedural sedation · Status epilepticus · ICU sedation · Anxiolysis"),
            ("Side Effects", COL_ADR,
             "Respiratory depression · Anterograde amnesia · Paradoxical excitation · Hypotension · Dependence (chronic use)"),
        ],
    },
    {
        "name": "Diazepam",
        "class": "Benzodiazepine",
        "drug_type": "pill",
        "color": HexColor("#F9E79F"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "GABA-A positive allosteric modulator → ↑ Cl⁻ channel opening frequency · Also active metabolites (desmethyldiazepam, oxazepam)"),
            ("Contraindications", COL_CI,
             "Pregnancy · Myasthenia gravis · Severe respiratory insufficiency · Sleep apnea · Phobia of needles (IV form)"),
            ("Interactions", COL_INTERACT,
             "Alcohol → synergistic CNS depression · CYP2C19/3A4 inhibitors ↑ levels · Rifampin ↓ levels · Opioids → resp. depression"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV / PR · Bioavailability PO 100% · Highly lipophilic → rapid CNS entry · t½ 20–70h (long-acting) · Hepatic metabolism"),
            ("Dose", COL_DOSE,
             "Anxiety: 2–10 mg PO TID–QID\nStatus epilepticus: 5–10 mg IV q5–10 min\nAlcohol withdrawal: 10 mg PO TID–QID\nMuscle spasm: 2–10 mg TID"),
            ("Indications", COL_INDIC,
             "Anxiety disorder · Status epilepticus · Alcohol withdrawal · Muscle spasm · Pre-operative sedation"),
            ("Side Effects", COL_ADR,
             "Sedation · Ataxia · Anterograde amnesia · Dependence / withdrawal seizures · Respiratory depression · Paradoxical agitation"),
        ],
    },
    {
        "name": "Phenytoin",
        "class": "Antiepileptic (Hydantoin)",
        "drug_type": "pill",
        "color": HexColor("#E74C3C"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Blocks voltage-gated Na⁺ channels (use-dependent) → stabilises inactivated state → ↓ repetitive neuronal firing · Also ↓ Ca²⁺ influx"),
            ("Contraindications", COL_CI,
             "Sinus bradycardia · SA/AV block · Sinoatrial node disease · Adams-Stokes syndrome · IV in hypotension"),
            ("Interactions", COL_INTERACT,
             "Strong CYP2C9/3A4 INDUCER → ↓ warfarin, OCP, cyclosporine · Valproate displaces protein binding · Many interactions"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV · Bioavailability 100% (PO slow) · Zero-order kinetics (saturable) · t½ 7–42 h variable · Therapeutic 10–20 mg/L · Hepatic CYP2C9/2C19"),
            ("Dose", COL_DOSE,
             "Maintenance: 200–400 mg PO OD–BID (4–8 mg/kg/day)\nLoading (SE): 15–20 mg/kg IV ≤50 mg/min\nPediatric: 4–8 mg/kg/day"),
            ("Indications", COL_INDIC,
             "Focal + generalised tonic-clonic seizures · Status epilepticus (IV) · Trigeminal neuralgia · Arrhythmias (digitalis-induced)"),
            ("Side Effects", COL_ADR,
             "Nystagmus · Ataxia · Gingival hyperplasia · Hirsutism · Megaloblastic anaemia (folate↓) · Teratogenic (fetal hydantoin syndrome) · SJS/TEN"),
        ],
    },
    {
        "name": "Haloperidol",
        "class": "Typical Antipsychotic (Butyrophenone)",
        "drug_type": "pill",
        "color": HexColor("#2980B9"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "D2 receptor antagonist (mesolimbic pathway → ↓ positive symptoms) · Also blocks α1, H1, M1 receptors · High D2 affinity"),
            ("Contraindications", COL_CI,
             "Parkinson's disease · QTc prolongation · CNS depression · Severe cardiac disease · Dementia-related psychosis (↑ mortality)"),
            ("Interactions", COL_INTERACT,
             "QT-prolonging drugs (risk of Torsades) · CNS depressants · CYP3A4/2D6 inhibitors ↑ levels · Lithium (neurotoxicity)"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IM / IV / Depot · Bioavailability PO 40–70% · t½ 12–36h · CYP3A4/2D6 metabolism · Active reduced metabolite"),
            ("Dose", COL_DOSE,
             "Psychosis: 1–15 mg PO BID–TID\nAcute agitation: 5–10 mg IM/IV\nDelirium: 0.5–5 mg PO/IV\nDepot (decanoate): 50–200 mg IM q4wk"),
            ("Indications", COL_INDIC,
             "Schizophrenia (positive symptoms) · Acute agitation / delirium · Tourette syndrome · Nausea/vomiting · Bipolar mania"),
            ("Side Effects", COL_ADR,
             "EPS: akathisia, dystonia, parkinsonism, tardive dyskinesia · QT prolongation · Neuroleptic malignant syndrome (NMS) · Hyperprolactinaemia"),
        ],
    },
    {
        "name": "Levodopa/Carbidopa",
        "class": "Dopaminergic (Parkinson's)",
        "drug_type": "pill",
        "color": HexColor("#27AE60"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Levodopa = dopamine precursor → crosses BBB → converted to dopamine · Carbidopa = peripheral DOPA decarboxylase inhibitor → ↑ CNS levodopa (prevents peripheral conversion)"),
            ("Contraindications", COL_CI,
             "Narrow-angle glaucoma · MAO-A inhibitors (hypertensive crisis) · Melanoma (promotes growth) · Psychosis"),
            ("Interactions", COL_INTERACT,
             "MAO-A inhibitors → hypertensive crisis · Antipsychotics → ↓ efficacy (D2 block) · Vitamin B6 (without carbidopa) ↑ peripheral conversion · High-protein meal ↓ absorption"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO · Levodopa t½ 1–2h (extends to 3–5h with carbidopa) · Amino acid transporter absorption · Hepatic + peripheral metabolism · BBB penetration"),
            ("Dose", COL_DOSE,
             "Initial: 25/100 mg PO TID (carbidopa/levodopa)\nMaintenance: 75/300–200/2000 mg/day in divided doses\nER form: 50/200 mg BID–TID"),
            ("Indications", COL_INDIC,
             "Parkinson's disease (gold standard) · Post-encephalitic parkinsonism · Symptomatic parkinsonism (trauma, manganism)"),
            ("Side Effects", COL_ADR,
             "Nausea/vomiting · On-Off fluctuations · Dyskinesias (peak dose) · Hallucinations · Postural hypotension · Impulse control disorders"),
        ],
    },

    # ══════════════════════════════════════════════════════
    # ANTIBIOTICS
    # ══════════════════════════════════════════════════════
    {"_section": "ANTIBIOTICS"},
    {
        "name": "Amoxicillin",
        "class": "Aminopenicillin",
        "drug_type": "capsule",
        "color": HexColor("#F39C12"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Inhibits bacterial cell wall synthesis by binding Penicillin-Binding Proteins (PBPs) → ↓ transpeptidation of peptidoglycan → cell lysis · Bactericidal"),
            ("Contraindications", COL_CI,
             "Penicillin hypersensitivity (anaphylaxis) · Infectious mononucleosis (EBV → maculopapular rash) · Severe renal failure (dose adjust)"),
            ("Interactions", COL_INTERACT,
             "Warfarin ↑ INR (rare) · Methotrexate ↑ toxicity · OCP (minor, theoretical) · Probenecid ↑ amoxicillin levels"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV · Bioavailability 74–92% (acid-stable, better than ampicillin) · t½ 1–1.5h · Renal excretion · Dose adjust GFR <30"),
            ("Dose", COL_DOSE,
             "Adults: 250–500 mg PO TID or 500–875 mg BID\nSevere: 875 mg PO BID or 1–2 g IV q8h\nH. pylori: 1 g BID (with PPI + clarithromycin)"),
            ("Indications", COL_INDIC,
             "URTI · Otitis media · Sinusitis · Community-acquired pneumonia · UTI · Lyme disease (early) · H. pylori eradication"),
            ("Side Effects", COL_ADR,
             "Diarrhoea / GI upset · Skin rash (10% if given with EBV) · Urticaria · Anaphylaxis · C. difficile colitis (less common than cephalosporins)"),
        ],
    },
    {
        "name": "Ciprofloxacin",
        "class": "Fluoroquinolone",
        "drug_type": "pill",
        "color": HexColor("#C0392B"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Inhibits bacterial DNA gyrase (topoisomerase II) + topoisomerase IV → prevents DNA supercoiling/decatenation → bactericidal · Concentration-dependent killing"),
            ("Contraindications", COL_CI,
             "Pregnancy / breastfeeding · Children <18 (cartilage) · Myasthenia gravis · QTc prolongation · Concurrent tizanidine"),
            ("Interactions", COL_INTERACT,
             "Theophylline → ↑ toxicity (CYP1A2 inhibition) · Warfarin ↑ INR · Antacids/iron ↓ absorption · QT-prolonging drugs"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV · Bioavailability 70–80% (PO) · t½ 3–5h · Hepatic + renal excretion · Tissue penetration excellent · Dose adjust CKD"),
            ("Dose", COL_DOSE,
             "UTI: 250–500 mg PO BID × 3–7 days\nGonorrhoea: 500 mg PO single dose\nPneumonia: 500–750 mg PO BID × 7–14 days\nAnthrax: 400 mg IV q12h"),
            ("Indications", COL_INDIC,
             "UTI · Prostatitis · GI infections (Salmonella, Shigella, Campylobacter) · Anthrax · Pseudomonas infections · Gonorrhoea · Traveller's diarrhoea"),
            ("Side Effects", COL_ADR,
             "Tendinopathy / tendon rupture (Achilles) · QT prolongation · Photosensitivity · GI upset · Seizures · Peripheral neuropathy · C. diff"),
        ],
    },
    {
        "name": "Azithromycin",
        "class": "Macrolide Antibiotic",
        "drug_type": "pill",
        "color": HexColor("#8E44AD"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Binds 50S ribosomal subunit (23S rRNA) → inhibits translocation → ↓ protein synthesis · Bacteriostatic (bactericidal at high concentrations)"),
            ("Contraindications", COL_CI,
             "QT prolongation / torsades risk · Macrolide hypersensitivity · Severe hepatic disease · Concurrent pimozide"),
            ("Interactions", COL_INTERACT,
             "QT-prolonging drugs → additive risk · Warfarin ↑ INR · Antacids ↓ peak levels · Digoxin ↑ levels (CYP3A4 inhibition mild)"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV · Bioavailability 37% (PO) · Very long t½ 68h (tissue accumulation) · CYP3A4 minor inhibitor · Biliary excretion · Excellent intracellular penetration"),
            ("Dose", COL_DOSE,
             "Z-pak: 500 mg day 1, 250 mg days 2–5\nCAP: 500 mg OD × 3 days\nSTI (chlamydia): 1 g single dose\nMAC prophylaxis (HIV): 1.2 g weekly"),
            ("Indications", COL_INDIC,
             "CAP · Atypical pneumonia (Mycoplasma, Chlamydophila) · Chlamydia/gonorrhoea · Otitis media · Pharyngitis · MAC in HIV · Pertussis"),
            ("Side Effects", COL_ADR,
             "GI upset (nausea, diarrhoea) · QT prolongation · Hepatotoxicity (rare) · Ototoxicity (high dose/prolonged) · Cholestatic jaundice"),
        ],
    },
    {
        "name": "Vancomycin",
        "class": "Glycopeptide Antibiotic",
        "drug_type": "ampoule",
        "color": HexColor("#E74C3C"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Binds D-Ala-D-Ala terminus of peptidoglycan precursors → inhibits transglycosylation + transpeptidation → cell wall synthesis arrest · Bactericidal"),
            ("Contraindications", COL_CI,
             "Vancomycin hypersensitivity · Use with caution in renal impairment (nephrotoxic) · Avoid rapid IV infusion (Red Man Syndrome)"),
            ("Interactions", COL_INTERACT,
             "Aminoglycosides → additive nephrotoxicity + ototoxicity · NSAIDs ↑ nephrotoxicity · Loop diuretics + ototoxicity · Neuromuscular blockers ↑ effect"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "IV / PO (oral = GI-only, not absorbed systemically) · t½ 4–8h (renal-dependent) · Renal excretion · Therapeutic monitoring: trough 10–20 mg/L (AUC-guided now preferred)"),
            ("Dose", COL_DOSE,
             "MRSA: 15–20 mg/kg IV q8–12h (AUC/MIC guided)\nC. diff (oral): 125 mg PO QID × 10 days\nEndocarditis: 30–45 mg/kg/day in divided doses\nTDM required"),
            ("Indications", COL_INDIC,
             "MRSA infections · Gram-positive infections (penicillin-resistant) · C. difficile colitis (oral) · Endocarditis · Meningitis (MRSA/penicillin-resistant pneumococcus)"),
            ("Side Effects", COL_ADR,
             "Red Man Syndrome (rapid infusion → histamine) · Nephrotoxicity · Ototoxicity · Thrombophlebitis · Neutropenia (prolonged) · DRESS syndrome"),
        ],
    },

    # ══════════════════════════════════════════════════════
    # RESPIRATORY DRUGS
    # ══════════════════════════════════════════════════════
    {"_section": "RESPIRATORY DRUGS"},
    {
        "name": "Salbutamol",
        "class": "Short-acting Beta-2 Agonist (SABA)",
        "drug_type": "inhaler",
        "color": HexColor("#3498DB"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Selective β2-adrenergic agonist → ↑ cAMP (via adenylyl cyclase) → bronchial smooth muscle relaxation + mast cell stabilisation · Onset 5 min, duration 4–6h"),
            ("Contraindications", COL_CI,
             "Hypersensitivity · Tachyarrhythmias · Caution in thyrotoxicosis, diabetes, hypokalemia, cardiac disease"),
            ("Interactions", COL_INTERACT,
             "Beta-blockers (non-selective) → antagonism · Theophylline → additive hypokalemia/tachycardia · MAOIs / TCAs → ↑ cardiovascular effects"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "Inhaled / PO / IV · Inhaled onset 5 min, peak 1–2h, duration 4–6h · PO onset 30 min · Hepatic metabolism (sulfation) · Renal excretion"),
            ("Dose", COL_DOSE,
             "Acute bronchospasm: 2.5–5 mg nebulised q20 min × 3 (severe asthma)\nPuffer: 100–200 mcg (1–2 puffs) PRN\nEIA prevention: 200 mcg 15 min before exercise"),
            ("Indications", COL_INDIC,
             "Acute asthma (reliever) · COPD exacerbation · Exercise-induced bronchoconstriction · Hyperkalemia (IV/nebulised) · Premature labour (tocolysis)"),
            ("Side Effects", COL_ADR,
             "Tachycardia · Tremor · Hypokalemia (high dose) · Paradoxical bronchospasm · Headache · Tolerance with overuse"),
        ],
    },
    {
        "name": "Ipratropium",
        "class": "Short-acting Muscarinic Antagonist (SAMA)",
        "drug_type": "inhaler",
        "color": HexColor("#16A085"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Competitive muscarinic (M1/M3) receptor antagonist in bronchial smooth muscle → ↓ bronchoconstriction · ↓ mucus secretion · Does NOT cross BBB"),
            ("Contraindications", COL_CI,
             "Hypersensitivity to atropine/ipratropium · Caution in BPH (urinary retention) · Narrow-angle glaucoma (avoid eye contact with spray)"),
            ("Interactions", COL_INTERACT,
             "Additive anticholinergic effects with other antimuscarinics · Minimal systemic interactions due to poor absorption"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "Inhaled · Poor systemic absorption (<10%) · Onset 15–30 min, peak 1–2h, duration 4–8h · t½ 2h · Renal + biliary excretion"),
            ("Dose", COL_DOSE,
             "COPD maintenance: 17–34 mcg (1–2 puffs MDI) QID\nAcute asthma/COPD: 0.5 mg nebulised q20 min × 3 (combined with salbutamol)\nMax 12 puffs/day"),
            ("Indications", COL_INDIC,
             "COPD (preferred maintenance) · Acute severe asthma (adjunct to SABA) · Rhinorrhoea (nasal spray) · Perennial non-allergic rhinitis"),
            ("Side Effects", COL_ADR,
             "Dry mouth · Urinary retention (BPH) · Constipation · Blurred vision (if in eyes) · Tachycardia (rare) · Paradoxical bronchospasm"),
        ],
    },
    {
        "name": "Fluticasone",
        "class": "Inhaled Corticosteroid",
        "drug_type": "inhaler",
        "color": HexColor("#884EA0"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Glucocorticoid receptor agonist → ↑ anti-inflammatory lipocortin → ↓ phospholipase A2 → ↓ prostaglandins/leukotrienes · ↓ eosinophil activity · ↓ mucosal oedema"),
            ("Contraindications", COL_CI,
             "Active pulmonary TB · Not for acute bronchospasm (no immediate relief) · Status asthmaticus (systemic steroids needed)"),
            ("Interactions", COL_INTERACT,
             "CYP3A4 inhibitors (ritonavir, ketoconazole) → ↑ systemic fluticasone levels → iatrogenic Cushing's · Ritonavir: significant interaction"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "Inhaled · Low systemic bioavailability (<1% swallowed, ~26% inhaled fraction) · Hepatic CYP3A4 metabolism · t½ 7.8h"),
            ("Dose", COL_DOSE,
             "Mild asthma: 100 mcg BID\nModerate: 250 mcg BID\nSevere: 500 mcg BID\n(Doses as propionate; furoate is once-daily)"),
            ("Indications", COL_INDIC,
             "Persistent asthma (controller) · COPD (combined with LABA) · Allergic rhinitis (nasal spray) · Prevention of asthma exacerbations"),
            ("Side Effects", COL_ADR,
             "Oral candidiasis (rinse mouth after use) · Dysphonia · Adrenal suppression (high dose) · Growth retardation (children, high dose) · Osteoporosis (long-term)"),
        ],
    },

    # ══════════════════════════════════════════════════════
    # GI DRUGS
    # ══════════════════════════════════════════════════════
    {"_section": "GASTROINTESTINAL DRUGS"},
    {
        "name": "Omeprazole",
        "class": "Proton Pump Inhibitor (PPI)",
        "drug_type": "capsule",
        "color": HexColor("#E67E22"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Prodrug → activated in acid → irreversibly binds H⁺/K⁺-ATPase (proton pump) on parietal cells → profound ↓ gastric acid · Requires acid activation"),
            ("Contraindications", COL_CI,
             "Hypersensitivity · Concurrent atazanavir/nelfinavir · Hypomagnesaemia (pre-existing) · Caution long-term use in CKD (↑ CKD progression risk)"),
            ("Interactions", COL_INTERACT,
             "Clopidogrel ↓ activation (CYP2C19 competition) · Methotrexate ↑ levels · Ketoconazole/itraconazole ↓ absorption · Atazanavir ↓ absorption"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV · Enteric-coated (acid-labile) · Bioavailability 30–40% (↑ with repeat dosing) · t½ 1–2h but effect lasts 24–72h · CYP2C19/3A4 metabolism"),
            ("Dose", COL_DOSE,
             "GORD: 20 mg PO OD × 4–8 wks\nH. pylori: 20 mg BID + antibiotics × 7–14 days\nZollinger-Ellison: 60 mg OD (titrate)\nGI prophylaxis (NSAID): 20 mg OD"),
            ("Indications", COL_INDIC,
             "GORD / reflux oesophagitis · Peptic ulcer disease · H. pylori eradication · Zollinger-Ellison syndrome · NSAID-induced gastropathy prevention"),
            ("Side Effects", COL_ADR,
             "Hypomagnesaemia (long-term) · Vitamin B12 deficiency · C. diff risk ↑ · Osteoporosis (long-term) · Headache · GI upset · CKD risk (prolonged)"),
        ],
    },
    {
        "name": "Misoprostol",
        "class": "Prostaglandin E1 Analogue",
        "drug_type": "pill",
        "color": HexColor("#27AE60"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "PGE1 analogue → EP1/3 receptors on parietal cells → ↓ cAMP → ↓ acid secretion · EP2/4 → ↑ mucus + bicarbonate · Also: uterotonic via uterine EP receptors"),
            ("Contraindications", COL_CI,
             "Pregnancy (if used for GI purposes — teratogenic, uterotonic) · Allergy · Prior caesarean (relative, rupture risk in labour induction)"),
            ("Interactions", COL_INTERACT,
             "Antacids (Mg-containing) → ↑ GI side effects · Oxytocin → ↑ uterotonic effect (hyperstimulation risk) · NSAIDs (minor)"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / SL / vaginal / rectal · Bioavailability PO 88% (as misoprostol acid) · t½ 20–40 min · Hepatic metabolism · Renal excretion"),
            ("Dose", COL_DOSE,
             "Gastric ulcer prevention: 200 mcg QID PO\nMedical abortion: 800 mcg vaginally/SL (with mifepristone)\nLabour induction: 25–50 mcg PV q4–6h\nPPH: 600–1000 mcg rectal"),
            ("Indications", COL_INDIC,
             "NSAID-induced gastric ulcer prevention · Peptic ulcer (2nd line) · Medical abortion (with mifepristone) · Labour induction · Postpartum haemorrhage · Cervical ripening"),
            ("Side Effects", COL_ADR,
             "Diarrhoea (dose-dependent) · Abdominal cramps · Nausea · Fever/chills (obstetric doses) · Uterine hyperstimulation · Uterine rupture (rare, obstetric)"),
        ],
    },
    {
        "name": "Ondansetron",
        "class": "5-HT3 Antagonist (Antiemetic)",
        "drug_type": "pill",
        "color": HexColor("#1ABC9C"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Selective 5-HT3 (serotonin) receptor antagonist in CTZ + vagal afferents in GI tract → ↓ nausea and vomiting · No dopamine blockade (no EPS)"),
            ("Contraindications", COL_CI,
             "QTc prolongation / congenital long-QT · Concurrent apomorphine (severe hypotension) · Hypersensitivity"),
            ("Interactions", COL_INTERACT,
             "QT-prolonging drugs → additive (serotonin syndrome risk with SSRIs) · Apomorphine absolute contraindication · CYP3A4 inhibitors ↑ ondansetron"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV / ODT · Bioavailability PO 56–60% · t½ 3–6h · CYP3A4/1A2/2D6 hepatic · Renal excretion of metabolites"),
            ("Dose", COL_DOSE,
             "PONV: 4 mg IV at induction\nChemo-induced N/V: 8 mg IV/PO 30 min before chemo\nGastroenteritis: 4 mg PO/IV q8h\nPediatric: 0.1–0.15 mg/kg IV"),
            ("Indications", COL_INDIC,
             "Chemotherapy-induced nausea/vomiting (CINV) · Post-operative N/V · Radiotherapy-induced N/V · Gastroenteritis · Hyperemesis gravidarum"),
            ("Side Effects", COL_ADR,
             "Headache · Constipation · QTc prolongation (dose-dependent) · Serotonin syndrome (rare, with other serotonergic agents) · Flushing"),
        ],
    },

    # ══════════════════════════════════════════════════════
    # ENDOCRINE DRUGS
    # ══════════════════════════════════════════════════════
    {"_section": "ENDOCRINE DRUGS"},
    {
        "name": "Metformin",
        "class": "Biguanide (Antidiabetic)",
        "drug_type": "pill",
        "color": HexColor("#2980B9"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Activates AMPK → ↓ hepatic gluconeogenesis (main effect) · ↑ peripheral glucose uptake · ↓ intestinal glucose absorption · Does NOT cause insulin secretion → no hypoglycaemia"),
            ("Contraindications", COL_CI,
             "GFR <30 mL/min (lactic acidosis risk) · Iodinated contrast (hold 48h) · Hepatic failure · Acute alcohol abuse · Sepsis / haemodynamic instability"),
            ("Interactions", COL_INTERACT,
             "Alcohol → ↑ lactic acidosis risk · Iodinated contrast → hold before procedure · Cationic drugs (cimetidine) ↓ renal tubular secretion"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO · Bioavailability 50–60% (reduced with food, taken with meals) · t½ 5–6h · NOT hepatically metabolised · Renal tubular secretion (OCT2) · No protein binding"),
            ("Dose", COL_DOSE,
             "Start: 500 mg PO BID or 850 mg OD with meals\nMaintenance: 1000 mg PO BID\nMax: 2550 mg/day (IR), 2000 mg/day (XR)\nTitrate over 2–4 weeks"),
            ("Indications", COL_INDIC,
             "Type 2 diabetes (first-line) · Pre-diabetes / insulin resistance · PCOS (off-label) · Weight management in T2DM"),
            ("Side Effects", COL_ADR,
             "GI: diarrhoea, nausea, metallic taste (GI = most common, dose/titration-dependent) · Vitamin B12 deficiency (long-term) · Lactic acidosis (rare, <1/100,000)"),
        ],
    },
    {
        "name": "Insulin Glargine",
        "class": "Long-acting Insulin Analogue",
        "drug_type": "ampoule",
        "color": HexColor("#E74C3C"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Modified insulin (substitution at B30/A21) → microprecipitate at SC injection site → slow, peakless absorption · Activates insulin receptor → ↑ glucose uptake, ↓ gluconeogenesis, ↓ lipolysis"),
            ("Contraindications", COL_CI,
             "Hypoglycaemia (active) · Hypersensitivity to insulin/excipients · Do NOT dilute or mix with other insulins"),
            ("Interactions", COL_INTERACT,
             "Beta-blockers (mask hypoglycaemia symptoms) · Corticosteroids/thiazides ↑ glucose (antagonism) · Alcohol → ↑ hypoglycaemia risk · Salicylates ↑ insulin sensitivity"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "SC only · Onset 2–4h · Peakless (flat profile) · Duration 20–24h (once daily) · Precipitates at physiological pH → slow release · t½ ~12h"),
            ("Dose", COL_DOSE,
             "Type 1: ~0.2 U/kg/day SC (basal component, ~40–50% of total daily dose)\nType 2 (starting): 10 U/day SC OD; titrate 2 U q3 days\nElderly: start 6–8 U/day"),
            ("Indications", COL_INDIC,
             "Type 1 diabetes (basal insulin) · Type 2 diabetes (basal insulin when oral agents insufficient) · Gestational diabetes"),
            ("Side Effects", COL_ADR,
             "Hypoglycaemia · Weight gain · Injection site reactions (lipohypertrophy, lipoatrophy) · Oedema · Hypokalemia"),
        ],
    },
    {
        "name": "Levothyroxine",
        "class": "Thyroid Hormone (T4)",
        "drug_type": "pill",
        "color": HexColor("#E91E63"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Synthetic T4 → converted peripherally to active T3 (by deiodinases) → binds nuclear thyroid hormone receptors → regulates gene transcription · Controls BMR, growth, development"),
            ("Contraindications", COL_CI,
             "Uncorrected adrenal insufficiency (Addisonian crisis) · Acute MI · Thyrotoxicosis · Hypersensitivity to excipients"),
            ("Interactions", COL_INTERACT,
             "Ca²⁺/Mg²⁺/antacids/iron → ↓ absorption (separate by 4h) · Warfarin ↑ INR · Rifampin/phenytoin ↑ metabolism · Sevelamer ↓ absorption"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV · Bioavailability 40–80% (fasting PO best) · t½ 7 days (T4) · Hepatic metabolism + deiodination · Protein-bound (albumin/TBG) 99.97%"),
            ("Dose", COL_DOSE,
             "Hypothyroidism: 1.6 mcg/kg/day PO (start 25–50 mcg OD, titrate q6–8 wks)\nMyxoedema coma: 200–500 mcg IV stat\nElite: titrate to TSH 0.5–2.5 mIU/L"),
            ("Indications", COL_INDIC,
             "Hypothyroidism (all causes) · Myxoedema coma · TSH suppression (thyroid cancer) · Goitre · Congenital hypothyroidism"),
            ("Side Effects", COL_ADR,
             "Overdose/excess: tachycardia, tremor, palpitations, sweating, weight loss, insomnia, AF · Osteoporosis (long-term) · Adrenal crisis if AI uncorrected"),
        ],
    },

    # ══════════════════════════════════════════════════════
    # ANALGESICS
    # ══════════════════════════════════════════════════════
    {"_section": "ANALGESICS & PAIN MANAGEMENT"},
    {
        "name": "Morphine",
        "class": "Opioid Analgesic (Strong)",
        "drug_type": "ampoule",
        "color": HexColor("#7D3C98"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Full agonist at μ-opioid receptors (+ κ, δ) → ↓ cAMP → ↑ K⁺ efflux (hyperpolarisation) + ↓ Ca²⁺ influx → ↓ neurotransmitter release → analgesia, euphoria, sedation"),
            ("Contraindications", COL_CI,
             "Respiratory depression · Paralytic ileus · Raised ICP (caution: ↑ CO2 → vasodilation) · MAO inhibitors (serotonin syndrome) · Severe hepatic impairment"),
            ("Interactions", COL_INTERACT,
             "CNS depressants (benzodiazepines, alcohol) → ↑ respiratory depression · MAOIs → serotonin syndrome · Naloxone (reversal) · Cimetidine ↑ morphine levels"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / SC / IV / IM / epidural · PO bioavailability 20–40% (first-pass) · t½ 2–4h · Glucuronidation (M6G = active, M3G = neuroexcitatory) · Renal excretion · Accumulates in renal failure"),
            ("Dose", COL_DOSE,
             "Acute pain IV: 0.05–0.1 mg/kg q4h\nPO (immediate): 5–15 mg q4h\nPO (CR): 15–200 mg q12h\nPalliative SC: individualised\nReverse with naloxone 0.4–2 mg IV/IM"),
            ("Indications", COL_INDIC,
             "Severe acute pain · Cancer pain (WHO ladder step 3) · Dyspnoea in palliative care · Acute pulmonary oedema (↓ preload + anxiolysis) · Post-operative pain"),
            ("Side Effects", COL_ADR,
             "Respiratory depression (life-threatening) · Constipation (tolerant resistant) · Nausea/vomiting · Sedation · Physical dependence · Pruritis · Urinary retention · Miosis"),
        ],
    },
    {
        "name": "Paracetamol",
        "class": "Non-opioid Analgesic / Antipyretic",
        "drug_type": "pill",
        "color": HexColor("#27AE60"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Central inhibition of COX-3 (CNS isoform) · ↓ prostaglandin synthesis in CNS → analgesia + antipyresis · Minimal peripheral anti-inflammatory effect · Activates descending serotonergic pathways"),
            ("Contraindications", COL_CI,
             "Severe hepatic impairment · Alcohol abuse (depletes glutathione) · G6PD deficiency (rare, haemolysis with large doses)"),
            ("Interactions", COL_INTERACT,
             "Warfarin ↑ INR (>4 g/day) · Alcohol → hepatotoxicity risk ↑ · Rifampin/isoniazid ↑ toxic metabolite (NAPQI) formation · Cholestyramine ↓ absorption"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO / IV / rectal · Bioavailability PO 60–98% · t½ 2h · Hepatic glucuronidation/sulfation (safe) + small % to NAPQI (toxic) · Detoxified by glutathione · Renal excretion"),
            ("Dose", COL_DOSE,
             "Adult: 500 mg–1 g PO/IV q4–6h\nMax: 4 g/day (healthy); 2–3 g/day (liver risk)\nPediatric: 10–15 mg/kg q4–6h\nOD antidote: N-acetylcysteine (NAC)"),
            ("Indications", COL_INDIC,
             "Mild-moderate pain · Fever · Post-operative analgesia · Headache/migraine · Arthritis pain · Opioid-sparing adjunct"),
            ("Side Effects", COL_ADR,
             "Hepatotoxicity (OVERDOSE → NAPQI accumulation → acute liver failure) · Renal toxicity (chronic high dose) · Rare: rash, thrombocytopenia · Generally well-tolerated at therapeutic doses"),
        ],
    },
    {
        "name": "Ibuprofen",
        "class": "NSAID (Non-selective COX inhibitor)",
        "drug_type": "pill",
        "color": HexColor("#E74C3C"),
        "left": [
            ("Mechanism", COL_MECHANISM,
             "Reversible inhibition of COX-1 and COX-2 → ↓ prostaglandin + thromboxane synthesis → analgesia, anti-inflammatory, antipyretic, ↓ platelet aggregation (COX-1)"),
            ("Contraindications", COL_CI,
             "Active peptic ulcer · Severe renal/hepatic failure · 3rd trimester pregnancy (premature DA closure) · Hypersensitivity (aspirin-sensitive asthma) · Post-CABG"),
            ("Interactions", COL_INTERACT,
             "Warfarin ↑ bleeding · ACEi/ARBs → AKI (triple whammy with diuretics) · Aspirin ↓ antiplatelet effect (competition) · Methotrexate toxicity ↑"),
        ],
        "right": [
            ("Pharmacokinetics", COL_PK,
             "PO · Bioavailability 80–100% · t½ 1.8–2h (short) · Hepatic CYP2C9 metabolism · Renal excretion · Takes with food to ↓ GI upset"),
            ("Dose", COL_DOSE,
             "Pain/fever: 200–400 mg PO q4–6h\nAnti-inflammatory: 400–800 mg PO TID (max 2400 mg/day)\nJuvenile arthritis: 30–40 mg/kg/day\nDysmenorrhoea: 400 mg q4h PRN"),
            ("Indications", COL_INDIC,
             "Pain (mild-moderate) · Fever · Dysmenorrhoea · RA/OA · Gout (acute) · Inflammatory conditions · PDA closure (neonatal, IV ibuprofen/indomethacin)"),
            ("Side Effects", COL_ADR,
             "GI: dyspepsia, ulceration, bleeding (↓ PGE2 protective effect) · AKI (↓ renal prostaglandins) · Fluid retention · HTN · Cardiovascular risk (↑ with dose/duration) · Bronchoconstriction (sensitive patients)"),
        ],
    },
]


# ── Drawing helpers ────────────────────────────────────────────────────────────

def draw_badge(c, x, y, label, bg_color, width=None):
    """Draw a coloured rounded-rect badge with white text label."""
    style = ParagraphStyle(
        'badge', fontName='Helvetica-Bold', fontSize=6.5,
        textColor=white, alignment=TA_CENTER, leading=8
    )
    p = Paragraph(label.upper(), style)
    tw = width or (p.wrap(200, 20)[0] + 12)
    th = 12
    c.setFillColor(bg_color)
    c.roundRect(x, y - th + 2, tw, th, 3, fill=1, stroke=0)
    c.setFillColor(white)
    c.setFont('Helvetica-Bold', 6.5)
    c.drawCentredString(x + tw / 2, y - th + 5, label.upper())
    return tw, th


def wrap_text_in_box(c, text, x, y, max_width, font_name='Helvetica', font_size=7, line_height=9, fill_color=None):
    """Draw wrapped text and return final y position."""
    if fill_color:
        c.setFillColor(fill_color)
    c.setFont(font_name, font_size)
    words = text.split()
    line = ''
    cy = y
    for word in words:
        test = (line + ' ' + word).strip()
        if c.stringWidth(test, font_name, font_size) <= max_width:
            line = test
        else:
            if line:
                c.drawString(x, cy, line)
                cy -= line_height
            line = word
    if line:
        c.drawString(x, cy, line)
        cy -= line_height
    c.setFillColor(black)
    return cy


def draw_section_notes(c, sections, x, y_top, col_width, card_bottom):
    """Draw a column of labelled note sections."""
    cy = y_top
    padding = 4
    for (label, label_color, text) in sections:
        if cy < card_bottom + 30:
            break
        # Draw badge label
        badge_w, badge_h = draw_badge(c, x, cy, label, label_color, width=col_width - 4)
        cy -= badge_h + 1

        # Draw text lines
        c.setFont('Helvetica', 6.8)
        c.setFillColor(HexColor("#1A1A2E"))
        # Split on newlines first
        for segment in text.split('\n'):
            if cy < card_bottom + 8:
                break
            words = segment.split()
            line = ''
            for word in words:
                test = (line + ' ' + word).strip()
                if c.stringWidth(test, 'Helvetica', 6.8) <= col_width - 2:
                    line = test
                else:
                    if line:
                        c.drawString(x, cy, '• ' + line if not line.startswith('•') else line)
                        cy -= 8.5
                    line = word
            if line:
                c.drawString(x, cy, '• ' + line if not line.startswith('•') else line)
                cy -= 8.5
        cy -= padding
    c.setFillColor(black)
    return cy


def draw_drug_illustration(c, cx, cy, drug_type, accent_color, size=70):
    """Draw a simple drug illustration centred at cx, cy."""
    half = size / 2

    if drug_type == 'pill':
        # Classic oval pill
        c.setFillColor(white)
        c.setStrokeColor(accent_color)
        c.setLineWidth(2)
        c.ellipse(cx - half, cy - half * 0.45, cx + half, cy + half * 0.45, fill=1, stroke=1)
        # Dividing line
        c.setStrokeColor(accent_color)
        c.setLineWidth(1.5)
        c.line(cx, cy - half * 0.45, cx, cy + half * 0.45)
        # Left half colour fill
        c.setFillColor(accent_color)
        c.arc(cx - half, cy - half * 0.45, cx, cy + half * 0.45, 90, 180)
        # Pill left fill
        from reportlab.lib.colors import Color
        c.setFillColor(accent_color)
        r = half * 0.45
        c.ellipse(cx - half, cy - r, cx, cy + r, fill=1, stroke=0)
        # Highlight
        c.setFillColor(HexColor("#FFFFFF80") if False else white)
        c.setFillColorRGB(1, 1, 1, 0.3)
        c.ellipse(cx - half * 0.7, cy + r * 0.2, cx - half * 0.1, cy + r * 0.7, fill=1, stroke=0)

    elif drug_type == 'capsule':
        # Two-tone capsule
        c.setFillColor(accent_color)
        c.setStrokeColor(HexColor("#444444"))
        c.setLineWidth(1.5)
        c.ellipse(cx - half, cy - half * 0.38, cx, cy + half * 0.38, fill=1, stroke=0)
        c.setFillColor(white)
        c.ellipse(cx, cy - half * 0.38, cx + half, cy + half * 0.38, fill=1, stroke=0)
        c.setStrokeColor(HexColor("#444444"))
        c.ellipse(cx - half, cy - half * 0.38, cx + half, cy + half * 0.38, fill=0, stroke=1)
        # Sheen
        c.setFillColorRGB(1, 1, 1, 0.25)
        c.ellipse(cx - half * 0.6, cy + half * 0.1, cx - half * 0.1, cy + half * 0.3, fill=1, stroke=0)

    elif drug_type == 'ampoule':
        # Glass ampoule / vial
        neck_w = size * 0.12
        body_w = size * 0.38
        body_h = size * 0.75
        neck_h = size * 0.22
        # Body
        c.setFillColor(HexColor("#D6EAF8"))
        c.setStrokeColor(HexColor("#5D6D7E"))
        c.setLineWidth(1.5)
        c.roundRect(cx - body_w, cy - body_h / 2, body_w * 2, body_h, 8, fill=1, stroke=1)
        # Liquid fill
        liquid_h = body_h * 0.62
        c.setFillColor(accent_color)
        c.setFillColorRGB(
            accent_color.red, accent_color.green, accent_color.blue, 0.7
        )
        c.roundRect(cx - body_w + 2, cy - body_h / 2 + 2, (body_w - 2) * 2, liquid_h, 6, fill=1, stroke=0)
        # Neck
        c.setFillColor(HexColor("#D6EAF8"))
        c.setStrokeColor(HexColor("#5D6D7E"))
        c.setLineWidth(1.2)
        c.roundRect(cx - neck_w, cy + body_h / 2 - 2, neck_w * 2, neck_h, 3, fill=1, stroke=1)
        # Highlight
        c.setFillColorRGB(1, 1, 1, 0.3)
        c.roundRect(cx - body_w + 4, cy, body_w * 0.5, body_h * 0.3, 4, fill=1, stroke=0)

    elif drug_type == 'inhaler':
        # Simple MDI inhaler shape
        body_w = size * 0.22
        body_h = size * 0.8
        can_w = size * 0.18
        can_h = size * 0.55
        # Actuator body (L-shape approximation)
        c.setFillColor(HexColor("#ECF0F1"))
        c.setStrokeColor(HexColor("#7F8C8D"))
        c.setLineWidth(1.5)
        c.roundRect(cx - body_w, cy - body_h / 2, body_w * 2, body_h, 6, fill=1, stroke=1)
        # Canister
        c.setFillColor(accent_color)
        c.roundRect(cx - can_w, cy, can_w * 2, can_h, 5, fill=1, stroke=1)
        # Mouthpiece nozzle
        c.setFillColor(HexColor("#BDC3C7"))
        c.roundRect(cx - body_w * 0.5, cy - body_h / 2, body_w, body_h * 0.25, 3, fill=1, stroke=0)
        # Highlight
        c.setFillColorRGB(1, 1, 1, 0.25)
        c.roundRect(cx - can_w + 3, cy + can_h * 0.4, can_w * 0.5, can_h * 0.3, 3, fill=1, stroke=0)


def draw_section_divider(c, section_name):
    """Draw a full-page section divider."""
    # Background gradient-ish
    c.setFillColor(HEADER_BG)
    c.rect(0, 0, W, H, fill=1, stroke=0)

    # Accent stripe
    c.setFillColor(HexColor("#E74C3C"))
    c.rect(0, H / 2 - 35, W, 70, fill=1, stroke=0)

    # Decorative dots
    c.setFillColor(HexColor("#FFFFFF1A") if False else HexColor("#2C2C4E"))
    for i in range(8):
        for j in range(5):
            c.circle(30 + i * 75, 80 + j * 80, 20, fill=1, stroke=0)

    # Section title
    c.setFillColor(white)
    c.setFont('Helvetica-Bold', 32)
    c.drawCentredString(W / 2, H / 2 - 12, section_name)

    # Subtitle line
    c.setFillColor(CLASS_NAME)
    c.setFont('Helvetica', 14)
    c.drawCentredString(W / 2, H / 2 - 42, "Pharmacology Reference Notes")

    # Bottom label
    c.setFillColor(HexColor("#AAAAAA"))
    c.setFont('Helvetica', 10)
    c.drawCentredString(W / 2, 30, "Pharmacology Cards • Clinical Reference")


def draw_drug_card(c, drug):
    """Draw one complete drug card on the current page."""
    # ── Background ──
    c.setFillColor(BG)
    c.rect(0, 0, W, H, fill=1, stroke=0)

    # ── Subtle grid lines ──
    c.setStrokeColor(HexColor("#E8E0D0"))
    c.setLineWidth(0.3)
    for yy in range(int(CARD_AREA_BOTTOM), int(H - MARGIN), 20):
        c.line(MARGIN, yy, W - MARGIN, yy)

    # ── Header band ──
    header_top = H - MARGIN
    header_bot = H - MARGIN - HEADER_H
    c.setFillColor(HEADER_BG)
    c.roundRect(MARGIN - 4, header_bot, W - 2 * MARGIN + 8, HEADER_H, 8, fill=1, stroke=0)

    # Accent stripe on header left
    c.setFillColor(drug['color'])
    c.roundRect(MARGIN - 4, header_bot, 8, HEADER_H, 4, fill=1, stroke=0)

    # Drug name
    c.setFillColor(white)
    c.setFont('Helvetica-Bold', 26)
    c.drawString(MARGIN + 12, header_bot + HEADER_H - 28, drug['name'])

    # Drug class (gold subtitle)
    c.setFillColor(CLASS_NAME)
    c.setFont('Helvetica-Bold', 11)
    c.drawString(MARGIN + 14, header_bot + HEADER_H - 44, drug['class'])

    # Small drug-type badge in header
    c.setFillColor(drug['color'])
    c.roundRect(W - MARGIN - 70, header_bot + HEADER_H - 28, 66, 18, 6, fill=1, stroke=0)
    c.setFillColor(white)
    c.setFont('Helvetica-Bold', 8)
    c.drawCentredString(W - MARGIN - 37, header_bot + HEADER_H - 19, drug['drug_type'].upper())

    # ── Column separators ──
    c.setStrokeColor(HexColor("#C8B89A"))
    c.setLineWidth(0.8)
    # Left / center divider
    c.line(CENTER_X - 2, CARD_AREA_BOTTOM, CENTER_X - 2, header_bot - 4)
    # Center / right divider
    c.line(RIGHT_X + 2, CARD_AREA_BOTTOM, RIGHT_X + 2, header_bot - 4)

    # ── Center illustration ──
    illus_cx = CENTER_X + CENTER_W / 2
    illus_cy = CARD_AREA_BOTTOM + (header_bot - CARD_AREA_BOTTOM) / 2 + 10
    draw_drug_illustration(c, illus_cx, illus_cy, drug['drug_type'], drug['color'], size=90)

    # ── Drug name watermark in center (faint) ──
    c.saveState()
    c.setFillColor(HexColor("#E8E0D0"))
    c.setFont('Helvetica-Bold', 9)
    c.drawCentredString(illus_cx, illus_cy - 60, drug['name'])
    c.setFont('Helvetica', 7.5)
    c.setFillColor(HexColor("#B0A090"))
    c.drawCentredString(illus_cx, illus_cy - 72, drug['class'])
    c.restoreState()

    # Column label headers
    col_label_y = header_bot - 18
    c.setFillColor(HexColor("#2C2C4E"))
    c.setFont('Helvetica-Bold', 8)
    c.drawCentredString(LEFT_X + SIDE_W / 2, col_label_y, "◀  CLINICAL PROFILE")
    c.drawCentredString(CENTER_X + CENTER_W / 2, col_label_y, "")
    c.drawCentredString(RIGHT_X + SIDE_W / 2, col_label_y, "PHARMACOLOGY  ▶")

    # ── Left column notes ──
    left_top = col_label_y - 8
    draw_section_notes(
        c,
        drug['left'],
        LEFT_X,
        left_top,
        SIDE_W - 4,
        CARD_AREA_BOTTOM
    )

    # ── Right column notes ──
    right_top = col_label_y - 8
    draw_section_notes(
        c,
        drug['right'],
        RIGHT_X + 4,
        right_top,
        SIDE_W - 4,
        CARD_AREA_BOTTOM
    )

    # ── Footer ──
    c.setFillColor(HEADER_BG)
    c.rect(MARGIN - 4, MARGIN, W - 2 * MARGIN + 8, FOOTER_H - 2, fill=1, stroke=0)
    c.setFillColor(white)
    c.setFont('Helvetica', 7)
    c.drawString(MARGIN + 8, MARGIN + 4, "PHARMACOLOGY REFERENCE CARDS  •  Clinical Use Only")
    c.drawRightString(W - MARGIN - 4, MARGIN + 4, drug['name'].upper() + "  |  " + drug['class'].upper())


# ── Main PDF generation ────────────────────────────────────────────────────────

def generate_pdf(output_path):
    c = canvas.Canvas(output_path, pagesize=A4)
    c.setTitle("Pharmacology Reference Cards")
    c.setAuthor("Orris Medical AI")
    c.setSubject("Complete Pharmacology Notes — All Major Drug Classes")

    # Cover page
    c.setFillColor(HEADER_BG)
    c.rect(0, 0, W, H, fill=1, stroke=0)
    c.setFillColor(HexColor("#E74C3C"))
    c.rect(0, H * 0.38, W, H * 0.24, fill=1, stroke=0)
    c.setFillColor(white)
    c.setFont('Helvetica-Bold', 42)
    c.drawCentredString(W / 2, H * 0.62 - 10, "PHARMACOLOGY")
    c.setFont('Helvetica-Bold', 28)
    c.drawCentredString(W / 2, H * 0.62 - 46, "REFERENCE CARDS")
    c.setFillColor(CLASS_NAME)
    c.setFont('Helvetica', 15)
    c.drawCentredString(W / 2, H * 0.38 - 20, "Cardiovascular  •  CNS  •  Antibiotics  •  Respiratory  •  GI  •  Endocrine  •  Analgesics")
    c.setFillColor(HexColor("#AAAAAA"))
    c.setFont('Helvetica', 11)
    c.drawCentredString(W / 2, H * 0.38 - 42, "Mechanism  •  Pharmacokinetics  •  Dose  •  Indications  •  Side Effects  •  Interactions")
    c.setFillColor(white)
    c.setFont('Helvetica-Bold', 12)
    c.drawCentredString(W / 2, 50, "Clinical Reference  •  English  •  All Major Drug Classes")
    c.showPage()

    for drug in DRUG_DATA:
        if '_section' in drug:
            draw_section_divider(c, drug['_section'])
            c.showPage()
        else:
            draw_drug_card(c, drug)
            c.showPage()

    c.save()
    print(f"PDF saved to: {output_path}")


if __name__ == '__main__':
    output = '/home/daytona/workspace/pharmcards/Pharmacology_Reference_Cards.pdf'
    generate_pdf(output)
Running Command

cd /home/daytona/workspace/pharmcards && python generate_cards.py 2>&1

Your credits are exhausted. Your daily credits reset tomorrow, or you can purchase a top-up for more.

Why

Your credits are exhausted. Your daily credits reset tomorrow, or you can purchase a top-up for more.

Continue

Running Command

ls -lh /home/daytona/workspace/pharmcards/ && python3 -c "from pypdf import PdfReader; r = PdfReader('/home/daytona/workspace/pharmcards/Pharmacology_Reference_Cards.pdf'); print(f'Pages: {len(r.pages)}')"

Your PDF is ready! ✅ It was successfully generated yesterday — 44 pages covering all 7 major drug classes.

📄

Pharmacology Reference Cards

PDF Document · PDF


What's inside (44 pages):
SectionDrugs Covered
CardiovascularMetoprolol, Atenolol, Propranolol, Lisinopril, Enalapril, Losartan, Amlodipine, Verapamil
DiureticsFurosemide, Hydrochlorothiazide, Spironolactone
CNS / NeurologicalMidazolam, Diazepam, Phenytoin, Haloperidol, Levodopa/Carbidopa
AntibioticsAmoxicillin, Ciprofloxacin, Azithromycin, Vancomycin
RespiratorySalbutamol, Ipratropium, Fluticasone
GastrointestinalOmeprazole, Misoprostol, Ondansetron
EndocrineMetformin, Insulin Glargine, Levothyroxine
AnalgesicsMorphine, Paracetamol, Ibuprofen
Each card includes:
  • Drug name + class in a dark header banner
  • Drug illustration (pill/capsule/ampoule/inhaler) in the center
  • Left side: Mechanism, Contraindications, Interactions
  • Right side: Pharmacokinetics, Dose, Indications, Side Effects
  • Color-coded section badges matching the style from your reference photos
This is a shared conversation. Sign in to Orris to start your own chat.