Twin pregnancy case presentation - MS obgyn long case with viva questions - with summary -20marks

Reading File
Reading File
Finding Sources
Finding Sources
Searching PubMed

"twin pregnancy"[MeSH Terms] AND "delivery"

Searching the Web

twin pregnancy guideline timing of delivery dichorionic monochorionic ACOG RCOG NICE aspirin surveillance

Reading File
Reading File
Reading File
Searching Images

lambda sign T sign ultrasound chorionicity twin pregnancy

Twin Pregnancy: MS Obstetrics and Gynaecology Long Case (20 marks)

Structure: history, examination, summary, diagnosis, investigations, management, viva. The patient details are a model case, so replace them with your own patient's findings.

PART A: CASE PRESENTATION

1. Patient details

  • Name, age 28 y, Mrs. X, para/gravida, religion, occupation, address, socioeconomic status, date of admission, registration number.
  • Booked or unbooked, and whether she is referred from a peripheral centre.

2. Chief complaints

  • Amenorrhoea for 8 months (34 weeks by LMP).
  • Excessive abdominal distension for the gestational age for 1 month.
  • Breathlessness and swelling of both feet for 2 weeks.

3. History of present illness

  • Present pregnancy
    • Was it spontaneous or conceived by ovulation induction, IUI or IVF? ART is a key risk factor and raises the chance of dizygotic twins.
    • Was it a planned pregnancy? Any family history of twins on the maternal side?
  • First trimester
    • Excessive vomiting (hyperemesis is more common in twins).
    • Bleeding per vaginum.
    • Dating or NT scan: gestational age, chorionicity and amnionicity. Ask whether she has the report. Chorionicity is the most important fact in the case.
  • Second trimester
    • Anomaly scan at 18-20 weeks.
    • Cervical length scan.
    • Fetal movements felt (quickening).
    • OGTT at 24-28 weeks.
  • Third trimester
    • Rapid increase in abdominal girth, which suggests polyhydramnios or TTTS.
    • Pain abdomen or tightening, which suggests preterm labour.
    • Leaking or bleeding per vaginum.
    • Reduced fetal movements.
    • Headache, blurred vision, epigastric pain, which suggest pre-eclampsia.
    • Dyspnoea, palpitations, oedema, which suggest anaemia, cardiac strain or pre-eclampsia.
    • Itching, which suggests cholestasis.
    • Polyuria and polydipsia, which suggest GDM.
  • Antenatal care
    • Number of visits, iron/folic acid/calcium intake, tetanus toxoid, aspirin, steroids, ultrasound reports.
    • Ask about any course of antenatal corticosteroids.

4. Menstrual history

  • Cycle length (regular or irregular), LMP, EDD by Naegele's rule, and EDD corrected by the first-trimester CRL scan.
  • Dating in twins uses the CRL of the larger twin, but use the first-trimester scan if the LMP is unreliable.

5. Obstetric history

  • G_P_L_A_, with year, mode of delivery, outcome, and birth weight of each child.
  • Previous twins, previous preterm birth, previous PPH, previous pre-eclampsia or caesarean (bears on mode of delivery).

6. Past, personal, family and medical history

  • Hypertension, diabetes, thyroid disease, renal or cardiac disease, previous uterine surgery (myomectomy, septum resection), cone biopsy or LEEP (risk of cervical insufficiency).
  • Diet and anaemia. Smoking, alcohol, drugs.
  • Family history of twins (maternal side for dizygotic), diabetes and hypertension.
  • Marital history and contraception.

PART B: EXAMINATION

General examination

  • Built, nutrition, height, weight, BMI. Weight gain should be higher in twins.
  • Pallor (anaemia is common), icterus, oedema, pulse, BP, temperature, respiratory rate.
  • Thyroid, breasts, spine, varicose veins.
  • Systemic examination: CVS, RS, CNS, abdomen.

Obstetric examination (inspection, palpation, auscultation)

Inspection
  • The abdomen is larger than expected for dates, ovoid or broad, with a wide transverse diameter.
  • Tense skin, striae, a prominent linea nigra, and visible fetal movements in two areas.
Palpation
  • Fundal height exceeds the period of gestation by more than 4 cm (for example 38 cm at 34 weeks).
  • Abdominal girth is increased.
  • Fundal grip: two poles, for example a breech in the fundus.
  • Lateral grip: many small parts, and three or more fetal poles palpable.
  • Pelvic grips: the lie of the lower twin and its engagement. The leading twin determines the mode of onset of labour.
  • A groove can sometimes be felt between the two fetal bodies.
  • Look for polyhydramnios (fluid thrill).
  • The commonest presentations are cephalic-cephalic (about 40%), cephalic-breech (about 35 to 40%) and breech-breech.
Auscultation
  • Two fetal heart sounds with a silent zone of at least 10 beats per minute difference in rate between them, heard at different sites. A silent area lies between the two.
  • Record the rate for each twin.
Per speculum and per vaginum (only if bleeding is excluded or placenta praevia is ruled out)
  • Cervix (effacement, dilatation), membranes, pelvis assessment.

Provisional diagnosis (model)

G2P1L1, 34 weeks, twin pregnancy (dichorionic diamniotic), cephalic-breech presentation, with/without complication (mild anaemia, GDM, pre-eclampsia, etc.).

PART C: SUMMARY (the part examiners read most)

A 28-year-old G2P1L1 woman, 34 weeks by LMP and confirmed by an early scan, presented with excess abdominal distension for gestational age and breathlessness. This is a spontaneous (or IVF) pregnancy. A first-trimester scan showed a dichorionic diamniotic twin pregnancy (lambda sign). The antenatal course was complicated by mild anaemia. On examination, she was pale (Hb 9.5 g/dL), BP 124/80 mmHg, with no oedema. The abdomen was larger than for dates, with a fundal height of 38 cm. Three or more fetal poles were palpable. Twin A is cephalic and Twin B is breech. Two fetal heart sounds were heard at 140 and 148 bpm, with a silent zone between them. The cervix is closed and uneffaced. Diagnosis: G2P1L1 with 34 weeks of DCDA twin pregnancy, Twin A cephalic, Twin B breech, with mild anaemia. Plan: iron, fetal surveillance with growth scans every 2 to 4 weeks, steroid cover if preterm delivery is expected, planned delivery at 37 weeks by the mode of delivery indicated by presentation.

PART D: DIFFERENTIAL DIAGNOSIS

Large for dates uterus:
  1. Wrong dates.
  2. Polyhydramnios.
  3. Macrosomia (diabetes).
  4. Twin pregnancy.
  5. Fibroid with pregnancy.
  6. Hydatidiform mole (early gestation).
Findings that favour twins: three fetal poles palpable, two FHS with a silent zone, and a fundal height greater than the gestational age by more than 4 cm.

PART E: INVESTIGATIONS

InvestigationPurpose
Ultrasound (first trimester, 11-14 weeks)Confirm viability. Determine chorionicity and amnionicity (the most important scan). Lambda sign (twin peak) = dichorionic. T sign = monochorionic. Membrane thickness and number of placental masses help. NT screening. Date by CRL of the larger twin.
Anomaly scan 18-20 weeksStructural anomalies (about twice as common, especially in monochorionic twins). Fetal echo in MCDA.
Cervical length (18-24 weeks)Prediction of preterm birth (cervical length less than 25 mm).
Growth scansDCDA: every 4 weeks from 20 weeks. MCDA: every 2 weeks from 16 weeks (fluid, bladder, Doppler).
Doppler (umbilical artery, MCA)In growth restriction or MC twins (MCA-PSV for TAPS and anaemia).
Haemoglobin, peripheral smear, ferritinAnaemia is more common (increased plasma volume).
OGTT 24-28 weeksGDM risk is higher.
Urine routine and cultureAsymptomatic bacteriuria.
BP and urine albumin at every visitPre-eclampsia is 2 to 3 times as common.
Blood group, Rh, HIV, HBsAg, VDRL, TSHRoutine antenatal screen.
Fibronectin (optional)Preterm labour prediction.
Liver function and bile acidsIf itching (cholestasis).
NST / BPPThird trimester if complicated.

PART F: MANAGEMENT

I. Antenatal

  1. Early determination of chorionicity, preferably in the first trimester, since later it is less reliable.
  2. Nutrition: an extra 300 kcal/day beyond singleton, protein supplementation, iron 60 mg elemental (or more, as needed), folic acid 4 mg (some give higher dose), calcium, vitamin D.
  3. Rest in the left lateral position. Prophylactic bed rest is not proven useful.
  4. Aspirin 75-150 mg from 12 weeks until delivery if two or more risk factors are present, as in NICE. The ACOG advises low-dose aspirin 81 mg for all twins in some guidance. Guidelines differ here.
  5. More frequent visits: every 2 weeks from 20 weeks, weekly in the last month.
  6. Surveillance:
    • DCDA: scan every 4 weeks from 20 weeks.
    • MCDA: fortnightly scan from 16 weeks to look for TTTS, selective growth restriction and TAPS.
    • MCMA: close monitoring, with birth at 32+0 to 33+6 weeks.
  7. Screen for complications: pre-eclampsia, GDM, cholestasis, preterm labour, anaemia.
  8. Steroids (betamethasone 12 mg IM, 2 doses 24 h apart) if preterm birth is expected before 34 to 35 weeks. Consider magnesium sulphate for neuroprotection if delivery is expected before 30 to 32 weeks.
  9. Cervical cerclage or pessary. Routine cerclage is not recommended in twins with a normal cervix. Vaginal progesterone has no clear proven benefit in unselected twins.
  10. Counselling about warning signs and the risks, and counselling and birth planning in the third trimester.

II. Timing of delivery (guideline differences are a favourite viva question)

TypeNICE NG137 (UK)ACOG (USA)
Uncomplicated DCDAOffer birth from 37+0 weeks (a NICE guideline summary: do not continue beyond 37+6)38+0 to 38+6 weeks
Uncomplicated MCDA36+0 weeks (steroids considered)34+0 to 37+6 weeks
Uncomplicated MCMA32+0 to 33+6 weeks (steroid cover)32+0 to 34+0 weeks
Complicated twinsIndividualiseIndividualise
A 2023 review of national guidelines found most recommend delivery at 37 to 38 weeks for DCDA twins, so quote the guideline that you follow in the exam.

III. Intrapartum management and mode of delivery

Mode of delivery
PresentationPlan
Twin A cephalic (about 75% of cases, regardless of Twin B)Planned vaginal delivery is appropriate if no other contraindication. Twin B may be cephalic, breech or transverse. Planned caesarean section is not superior (Twin Birth Study, 2013).
Twin A non-cephalic (breech or transverse)Caesarean section
Monoamniotic twinsCaesarean section (cord entanglement)
Other obstetric indicationsPlacenta praevia, previous classical caesarean, conjoined twins, fetal compromise, high-order multiples
Previous one LSCSTOLAC is possible with experienced staff, but counsel on higher rupture risk
Labour precautions
  • Deliver in a unit with capability for emergency caesarean section, a neonatal intensive care unit, an experienced obstetrician and an anaesthetist.
  • Two ultrasound machines and two paediatric teams should be available for the birth.
  • Establish IV access, cross-match blood, keep the epidural available (preferred, since it helps if intrapartum manipulation is needed).
  • Continuous CTG for both twins, using a fetal scalp electrode on Twin A, if needed.
  • Active management of the third stage.
Delivery of Twin B
  • Aim for an interval of less than 30 minutes, though the exact time is not rigid if the fetal heart is normal.
  • After delivery of Twin A, clamp the cord and check the presentation of Twin B by abdominal and vaginal examination, and ultrasound if available.
  • If the lie is longitudinal: wait for contractions, or start oxytocin, and rupture the membranes when the presenting part is engaged.
  • If the lie is transverse: external cephalic version, or internal podalic version with breech extraction.
  • If Twin B's heart rate is abnormal or there is a cord prolapse, proceed to emergency delivery.
Complications of delivery
  • Locked twins (rare; breech A and cephalic B).
  • Cord prolapse, placental abruption after delivery of Twin A.
  • Postpartum haemorrhage (higher risk because of uterine overdistension, with a meta-analysis confirming the association), so use oxytocin, ergometrine (if not hypertensive) and carboprost, and have tranexamic acid ready.

IV. Postnatal

  • Examine placentas and send for chorionicity confirmation.
  • Breastfeeding support, iron therapy, contraception counselling.
  • Neonatal care: low birth weight, prematurity.

PART G: VIVA QUESTIONS AND MODEL ANSWERS

1. How do twins form? Classify.
  • Dizygotic (about two thirds of twins): two ova fertilised by two sperm. They are always dichorionic diamniotic. The rate varies with race, maternal age, parity, and ART. The incidence is about 1 in 80 pregnancies worldwide.
  • Monozygotic: one ovum splits. The incidence is constant at about 3 to 4 per 1000. The timing of the split decides the chorionicity.
Day of division after fertilisationType
0-3 (before morula)Dichorionic diamniotic (30%)
4-8 (blastocyst)Monochorionic diamniotic (about 70%)
8-13Monochorionic monoamniotic (1 to 2%)
After day 13Conjoined twins
2. Why is chorionicity important? Monochorionic twins are about 20% of twins but have the highest complication rate because of shared placental vascular anastomoses. Chorionicity is best determined by ultrasound in the first trimester (Creasy & Resnik's Maternal-Fetal Medicine, Complicated Monochorionic Twin Pregnancies). Perinatal mortality is about 12% in monochorionic twins against 2 to 5% in dichorionic twins (Creasy & Resnik's Maternal-Fetal Medicine, p. 110).
3. How do you determine chorionicity on ultrasound?
  • First trimester: lambda (twin-peak) sign = dichorionic, T sign = monochorionic. Also count placental masses and look at membrane thickness.
  • Later, the sex of the twins (different sexes means dizygotic and dichorionic), thick membrane, and two separate placentas.
  • Accuracy falls after 14 weeks.
4. What are the maternal complications of twin pregnancy? Hyperemesis, anaemia, pre-eclampsia, GDM, polyhydramnios, preterm labour, cholestasis, antepartum haemorrhage (abruption, previa), operative delivery, PPH, thromboembolism, and postpartum depression. Physiological stress: compression, breathlessness, heartburn, varicose veins, backache.
5. Fetal complications? Preterm birth (about 50% before 37 weeks), IUGR and discordant growth, congenital anomalies, cord accidents, perinatal death, TTTS (monochorionic), cerebral palsy, malpresentation, intrauterine death of one twin.
6. Define and describe TTTS.
  • Occurs in about 10 to 15% of monochorionic pregnancies (Creasy & Resnik's Maternal-Fetal Medicine, p. 852).
  • Unbalanced blood flow through placental vascular anastomoses (deep arteriovenous) overperfuses the recipient and underperfuses the donor.
  • Donor: hypovolaemia, oliguria, oligohydramnios (stuck twin), growth restriction.
  • Recipient: hypervolaemia, polyuria, polyhydramnios, cardiac strain, hydrops.
  • Diagnosis: monochorionic twins with oligohydramnios (deepest vertical pocket less than 2 cm) in one sac, and polyhydramnios (more than 8 cm; more than 10 cm after 20 weeks) in the other.
  • Quintero staging:
    • I: oligo/poly only, bladder visible in the donor.
    • II: donor bladder not visible.
    • III: abnormal Doppler.
    • IV: hydrops.
    • V: fetal death.
  • Treatment: fetoscopic laser coagulation of the anastomoses (Stage II and above, 16 to 26 weeks), amnioreduction, selective feticide. Laser improves survival and reduces short-term disability (Creasy & Resnik's Maternal-Fetal Medicine, p. 3296).
7. What are TAPS, TRAP, sFGR?
  • TAPS: twin anaemia-polycythaemia sequence, caused by tiny anastomoses; MCA-PSV discordance without liquor discordance.
  • TRAP: twin reversed arterial perfusion; an acardiac twin is perfused by the pump twin.
  • sFGR: selective fetal growth restriction (EFW of one twin below the 10th centile, or discordance above 25%). Classified I to III by umbilical artery Doppler.
8. What happens if one twin dies in utero?
  • In dichorionic twins, the risk to the surviving twin is mainly preterm birth.
  • In monochorionic twins, the risk is acute exsanguination from the survivor into the dead twin, causing death or neurological injury (brain disruption such as cystic encephalomalacia) (Creasy & Resnik's Maternal-Fetal Medicine, p. 110).
  • Management: assess for anaemia (MCA-PSV), MRI at 4 weeks, individualised delivery (consider 34 to 36+6 weeks per RCOG advice), steroids before delivery. Emergency delivery of the survivor does not prevent injury because it has already happened.
  • Maternal DIC is rare, but check coagulation if the fetus has been dead for more than 3 to 4 weeks.
9. What are the signs of twins on examination? Uterus larger than dates, multiple fetal parts, two FHS with 10 bpm difference, a groove, and ultrasound confirmation.
10. How does a twin differ from a singleton physiologically? Plasma volume rises about 50 to 60% (against 40-50% in singleton), cardiac output is higher, the uterus is overdistended, and the placental mass is larger. The risk of supine hypotension, aortocaval compression and anaemia is higher.
11. Why is the iron requirement high? Fetal and placental iron needs are doubled and red cell mass expansion is larger. The requirement is about 1000 mg for the pregnancy plus an extra amount for the second fetus.
12. How do you manage preterm labour in twins? Admission, tocolysis (nifedipine or atosiban) for 48 hours, corticosteroids, magnesium sulphate for neuroprotection under 32 weeks, antibiotics if PPROM, transfer to a tertiary centre, no beta-agonists because of the risk of pulmonary oedema (higher plasma volume).
13. Role of cerclage, pessary and progesterone? No benefit proven in unselected twins. Cerclage may be considered if the cervix is short (below 15 mm) and the woman has a history of cervical insufficiency. Pessary or progesterone may help selected women with a short cervix, but the data are inconsistent.
14. What is the role of fetal reduction? Multifetal pregnancy reduction in higher-order multiples (three or more) to twins, and selective termination of an anomalous fetus. Counselling must be careful. Risks include pregnancy loss and prematurity (Creasy & Resnik's Maternal-Fetal Medicine, p. 3367 and 3387).
15. What is the Twin Birth Study? A large randomised trial of 2800 women at 32-38 weeks with Twin A cephalic that found no difference in perinatal mortality or serious neonatal morbidity between planned caesarean and planned vaginal delivery. This is why vaginal delivery is offered when Twin A is cephalic.
16. How do you manage the third stage? Active management with oxytocin 10 IU IM or 5 IU IV slowly after the delivery of the second twin (or after the delivery of the anterior shoulder of Twin B). Have a PPH drill ready.
17. What is a vanishing twin? Spontaneous demise of one embryo or fetus in early pregnancy, often reabsorbed. It may be associated with some bleeding. It is seen in up to 20% of ART twin conceptions.
18. What is a conjoined twin? Incomplete fission after day 13. Types are thoracopagus (most common), omphalopagus, pygopagus, craniopagus, ischiopagus. Delivery by caesarean section, and a plan for separation after counselling.
19. What is the recent evidence on mode and timing of delivery? A 2025 meta-analysis examined maternal and infant outcomes by planned mode of delivery in twins, and a 2024 meta-analysis of preterm twins (under 32 weeks or under 1500 g) compared modes of delivery. I have only read the titles of these, not the full text, so check the conclusions before quoting them in an exam.

PART H: KEY POINTS FOR RAPID REVISION (high-yield)

  • Twins are monozygotic (one third) and dizygotic (two thirds). The timing of the split decides chorionicity.
  • Chorionicity is determined in the first trimester (lambda vs T sign).
  • A uterus more than 4 cm larger than dates, three or more fetal poles, and two FHS with a silent zone are the clinical signs.
  • DCDA surveillance: 4-weekly from 20 weeks. MCDA: 2-weekly from 16 weeks.
  • Timing: DCDA at 37-38 weeks, MCDA at 36-37 weeks, MCMA at 32-34 weeks (depends on the guideline).
  • Mode: Twin A cephalic means a trial of vaginal delivery. Twin A non-cephalic means caesarean section.
  • Prevent PPH. Prepare blood, oxytocin and tranexamic acid.
  • Aspirin for pre-eclampsia prevention in at-risk women.

Notes and cautions

  • Hospital protocols in India often follow FOGSI or local MFM practice, so use your institution's targets if they differ from NICE and ACOG.
  • The textbook references above are from Creasy & Resnik's Maternal-Fetal Medicine. Page numbers are as indexed in the library.
  • The textbook reads for this answer were limited to the monochorionic sections. Dosing and the Twin Birth Study details are from my background knowledge and standard guidelines, so verify them against your department's textbook before the exam.
  • Recent evidence: my quick search of the last two years found no systematic review that contradicts the above (PMIDs 41130902, 39367324, 38066342). I did not read their full text.

Make a presentation on twin pregnancy for case discussion

Reading File
Reading File
Searching Images

twin pregnancy ultrasound lambda sign dichorionic T sign monochorionic

Searching Images

twin-twin transfusion syndrome donor recipient placenta

Running Command

ls -la /tmp/workspace/

query_images_db
Running Command

mkdir -p /tmp/workspace/twin-pregnancy-ppt/assets /tmp/workspace/twin-pregnancy-ppt/output && cd /tmp/workspace/twin-pregnancy-ppt && python /tmp/skills/shared/scripts/fetch_images.py "https://cdn.orris.care/cdss_images/pmc_clinical_VQA_6244aac6a613372d14a4a43dea3b03c661ad41b5b5ce30ba10aa4f99bab0c1a6.jpg" "https://cdn.orris.care/cdss_images/pmc_clinical_VQA_165f7cd3fb506601baff2f5d5cf1175b6d8a319309e9d6a02e0b080935e27997.jpg" "https://cdn.orris.care/cdss_images/4978d159a0b34dc7cd56d1543cfb92bad578d2769073453a474e4fc68e1451f8.png" "https://cdn.orris.care/cdss_images/Pathology_1760057611064_b2ab85e5-95a1-402a-8137-658009e93591.jpg" > assets/imgs.json; python - <<'E' import json,base64 d=json.load(open('/tmp/workspace/twin-pregnancy-ppt/assets/imgs.json')) names=['zygosity','anastomoses','ttts','dcda_placenta'] from PIL import Image from io import BytesIO for n,i in zip(names,d): if i['base64']: raw=base64.b64decode(i['base64'].split(',',1)[1] if ',' in i['base64'] else i['base64'].split(';',1)[1].replace('base64,','')) im=Image.open(BytesIO(raw)).convert('RGB'); im.save(f'/tmp/workspace/twin-pregnancy-ppt/assets/{n}.jpg'); print(n,im.size) else: print(n,i['error']) E

Writing File

~/twin-pregnancy-ppt/build.py

from pptx import Presentation
from pptx.util import Inches, Pt
from pptx.dml.color import RGBColor
from pptx.enum.text import PP_ALIGN, MSO_ANCHOR
from pptx.enum.shapes import MSO_SHAPE
from pptx.oxml.ns import qn
from lxml import etree

A = "/tmp/workspace/twin-pregnancy-ppt/assets/"
NAVY = RGBColor(0x12, 0x2B, 0x4A)
TEAL = RGBColor(0x0F, 0x8B, 0x8D)
CORAL = RGBColor(0xE0, 0x5A, 0x47)
GOLD = RGBColor(0xF2, 0xA9, 0x00)
LIGHT = RGBColor(0xF4, 0xF7, 0xFA)
WHITE = RGBColor(0xFF, 0xFF, 0xFF)
DARK = RGBColor(0x23, 0x2F, 0x3E)
GREY = RGBColor(0x6B, 0x77, 0x85)
PALE_TEAL = RGBColor(0xE1, 0xF2, 0xF2)
PALE_CORAL = RGBColor(0xFB, 0xE7, 0xE3)
FONT = "Calibri"

prs = Presentation()
prs.slide_width = Inches(13.333)
prs.slide_height = Inches(7.5)
BLANK = prs.slide_layouts[6]
state = {"n": 0}


def rect(s, x, y, w, h, fill, line=None, shape=MSO_SHAPE.RECTANGLE):
    r = s.shapes.add_shape(shape, Inches(x), Inches(y), Inches(w), Inches(h))
    r.fill.solid()
    r.fill.fore_color.rgb = fill
    if line is None:
        r.line.fill.background()
    else:
        r.line.color.rgb = line
        r.line.width = Pt(1)
    r.shadow.inherit = False
    return r


def text(s, x, y, w, h, t, size=18, bold=False, color=DARK, align=PP_ALIGN.LEFT,
         anchor=MSO_ANCHOR.TOP, italic=False):
    tb = s.shapes.add_textbox(Inches(x), Inches(y), Inches(w), Inches(h))
    tf = tb.text_frame
    tf.word_wrap = True
    tf.vertical_anchor = anchor
    tf.margin_left = tf.margin_right = Inches(0.05)
    tf.margin_top = tf.margin_bottom = Inches(0.03)
    p = tf.paragraphs[0]
    p.alignment = align
    r = p.add_run()
    r.text = t
    r.font.size = Pt(size)
    r.font.bold = bold
    r.font.italic = italic
    r.font.name = FONT
    r.font.color.rgb = color
    return tb


def set_bullet(p, char="\u2022", indent=0.22, level_off=0.0, color=None):
    pPr = p._p.get_or_add_pPr()
    pPr.set("marL", str(int(Inches(indent + level_off))))
    pPr.set("indent", str(-int(Inches(indent))))
    for tag in ("a:buNone", "a:buChar", "a:buClr"):
        for e in pPr.findall(qn(tag)):
            pPr.remove(e)
    if color is not None:
        bc = etree.SubElement(pPr, qn("a:buClr"))
        c = etree.SubElement(bc, qn("a:srgbClr"))
        c.set("val", "%02X%02X%02X" % (color[0], color[1], color[2]))
    bu = etree.SubElement(pPr, qn("a:buChar"))
    bu.set("char", char)


def bullets(s, x, y, w, h, items, size=18, color=DARK, gap=6, bcolor=TEAL):
    """items: str | (lead, rest) | ('-', str) for sub-bullet"""
    tb = s.shapes.add_textbox(Inches(x), Inches(y), Inches(w), Inches(h))
    tf = tb.text_frame
    tf.word_wrap = True
    tf.margin_left = tf.margin_right = Inches(0.05)
    first = True
    for it in items:
        p = tf.paragraphs[0] if first else tf.add_paragraph()
        first = False
        p.space_after = Pt(gap)
        sub = False
        if isinstance(it, tuple) and it[0] == "-":
            sub = True
            it = it[1]
        if isinstance(it, tuple):
            lead, rest = it
            r1 = p.add_run()
            r1.text = lead + " "
            r1.font.bold = True
            r1.font.size = Pt(size)
            r1.font.name = FONT
            r1.font.color.rgb = NAVY
            r2 = p.add_run()
            r2.text = rest
            r2.font.size = Pt(size)
            r2.font.name = FONT
            r2.font.color.rgb = color
        else:
            r = p.add_run()
            r.text = it
            r.font.size = Pt(size - 2 if sub else size)
            r.font.name = FONT
            r.font.color.rgb = color
        set_bullet(p, "\u2013" if sub else "\u2022", level_off=0.3 if sub else 0.0,
                   color=bcolor)
    return tb


def new_slide(title, kicker=None, notes=None):
    s = prs.slides.add_slide(BLANK)
    state["n"] += 1
    rect(s, 0, 0, 13.333, 7.5, WHITE)
    rect(s, 0, 0, 13.333, 1.15, NAVY)
    rect(s, 0, 1.15, 13.333, 0.06, TEAL)
    text(s, 0.55, 0.12, 11.6, 0.9, title, size=30, bold=True, color=WHITE,
         anchor=MSO_ANCHOR.MIDDLE)
    if kicker:
        text(s, 9.3, 0.08, 3.7, 0.3, kicker.upper(), size=12, bold=True, color=GOLD,
             align=PP_ALIGN.RIGHT)
    text(s, 0.55, 7.08, 8, 0.3, "Twin Pregnancy | Case Discussion | MS Obstetrics & Gynaecology",
         size=11, color=GREY)
    text(s, 12.0, 7.08, 0.8, 0.3, str(state["n"]), size=11, color=GREY, align=PP_ALIGN.RIGHT)
    if notes:
        s.notes_slide.notes_text_frame.text = notes
    return s


def card(s, x, y, w, h, head, items, hc=TEAL, fill=LIGHT, size=16, gap=4):
    rect(s, x, y, w, h, fill)
    rect(s, x, y, w, 0.5, hc)
    text(s, x + 0.1, y, w - 0.2, 0.5, head, size=17, bold=True, color=WHITE,
         anchor=MSO_ANCHOR.MIDDLE)
    bullets(s, x + 0.1, y + 0.6, w - 0.2, h - 0.65, items, size=size, gap=gap, bcolor=hc)


def table(s, x, y, w, data, colw, rowh=0.5, size=15, head=NAVY, zebra=True, first_bold=True):
    rows, cols = len(data), len(data[0])
    gt = s.shapes.add_table(rows, cols, Inches(x), Inches(y), Inches(w), Inches(rowh * rows))
    t = gt.table
    tblPr = t._tbl.tblPr
    sid = tblPr.find(qn("a:tableStyleId"))
    if sid is not None:
        sid.text = "{5940675A-B579-460E-94D1-54222C63F5DA}"  # no style, table grid
    for i, cw in enumerate(colw):
        t.columns[i].width = Inches(cw)
    for r in range(rows):
        t.rows[r].height = Inches(rowh)
        for c in range(cols):
            cell = t.cell(r, c)
            cell.margin_left = cell.margin_right = Inches(0.08)
            cell.margin_top = cell.margin_bottom = Inches(0.04)
            cell.vertical_anchor = MSO_ANCHOR.MIDDLE
            cell.fill.solid()
            if r == 0:
                cell.fill.fore_color.rgb = head
            else:
                cell.fill.fore_color.rgb = LIGHT if (r % 2 == 1 or not zebra) else WHITE
            tf = cell.text_frame
            tf.word_wrap = True
            p = tf.paragraphs[0]
            run = p.add_run()
            run.text = data[r][c]
            run.font.size = Pt(size)
            run.font.name = FONT
            if r == 0:
                run.font.bold = True
                run.font.color.rgb = WHITE
            else:
                run.font.color.rgb = DARK
                run.font.bold = (c == 0 and first_bold)
    return t


def pic(s, name, x, y, w=None, h=None):
    kw = {}
    if w:
        kw["width"] = Inches(w)
    if h:
        kw["height"] = Inches(h)
    return s.shapes.add_picture(A + name, Inches(x), Inches(y), **kw)


def caption(s, x, y, w, t):
    text(s, x, y, w, 0.5, t, size=12, italic=True, color=GREY)


# ---------------- 1. Title ----------------
s = prs.slides.add_slide(BLANK)
state["n"] += 1
rect(s, 0, 0, 13.333, 7.5, NAVY)
rect(s, 0, 5.2, 13.333, 0.08, TEAL)
rect(s, 0.8, 1.55, 0.12, 2.35, GOLD)
text(s, 1.1, 1.4, 11, 1.2, "Twin Pregnancy", size=60, bold=True, color=WHITE)
text(s, 1.1, 2.65, 11, 0.9, "A Case Discussion: from chorionicity to delivery", size=28, color=RGBColor(0xBF, 0xD9, 0xE6))
text(s, 1.1, 3.4, 11, 0.5, "MS Obstetrics & Gynaecology | Long case with viva points", size=18, color=GOLD, bold=True)
text(s, 1.1, 5.5, 11, 0.5, "Presenter: ____________    Unit: ____________    Date: ____________", size=16,
     color=RGBColor(0xBF, 0xD9, 0xE6))
text(s, 1.1, 6.1, 11, 0.5, "Model case: replace bracketed details with your own patient's findings", size=14, italic=True,
     color=RGBColor(0x8F, 0xA9, 0xBE))
s.notes_slide.notes_text_frame.text = ("Model case. Every patient-specific value (age, Hb, BP, scan results) is an example "
                                       "and must be replaced with your own patient's data before presenting.")

# ---------------- 2. Outline ----------------
s = new_slide("Presentation outline", "Roadmap")
items = [("1", "Case history", TEAL), ("2", "Examination & summary", TEAL), ("3", "Diagnosis & differentials", TEAL),
         ("4", "Embryology & chorionicity", NAVY), ("5", "Complications", NAVY), ("6", "Investigations & surveillance", NAVY),
         ("7", "Antenatal management", CORAL), ("8", "Timing & mode of delivery", CORAL), ("9", "Intrapartum & PPH", CORAL),
         ("10", "Viva points & take-home", GOLD)]
for i, (n, t, c) in enumerate(items):
    col, row = i // 5, i % 5
    x, y = 0.8 + col * 6.1, 1.65 + row * 1.04
    rect(s, x, y, 0.8, 0.8, c, shape=MSO_SHAPE.OVAL)
    text(s, x, y, 0.8, 0.8, n, size=22, bold=True, color=WHITE, align=PP_ALIGN.CENTER, anchor=MSO_ANCHOR.MIDDLE)
    text(s, x + 1.0, y, 4.8, 0.8, t, size=22, color=DARK, anchor=MSO_ANCHOR.MIDDLE)

# ---------------- 3. History ----------------
s = new_slide("Case history", "Part 1",
              "Present the patient as a model case. Stress chorionicity, mode of conception, and symptoms of complications.")
card(s, 0.5, 1.5, 4.0, 5.4, "Patient & complaints", [
    ("Patient:", "Mrs. X, 28 y, G2P1L1, booked"),
    ("Complaints:", "Amenorrhoea 8 months (34 weeks by LMP)"),
    "Abdominal distension more than expected for dates, 1 month",
    "Breathlessness and pedal oedema, 2 weeks",
], size=16)
card(s, 4.7, 1.5, 4.0, 5.4, "Present pregnancy", [
    ("Conception:", "spontaneous [or ART: ovulation induction / IUI / IVF]"),
    ("Dating:", "LMP confirmed by first-trimester CRL scan"),
    ("1st trimester scan:", "DCDA twins, lambda sign"),
    ("Anomaly scan:", "normal; cervical length normal"),
    ("Symptoms:", "no bleeding, leaking or contractions; fetal movements present"),
], hc=NAVY, size=16)
card(s, 8.9, 1.5, 3.95, 5.4, "Risk-factor review", [
    "Hyperemesis, anaemia, pre-eclampsia symptoms",
    "Polyuria or polydipsia (GDM), itching (cholestasis)",
    ("Past:", "no HTN, DM, thyroid, uterine surgery, cone biopsy"),
    ("Family:", "twins on maternal side"),
    ("Obstetric:", "one term vaginal birth, no PPH"),
], hc=CORAL, size=16)

# ---------------- 4. Examination ----------------
s = new_slide("Examination findings", "Part 2",
              "Typical clinical signs: uterus larger than dates (more than 4 cm), 3 or more fetal poles, two FHS with a silent zone.")
card(s, 0.5, 1.5, 4.0, 5.4, "General", [
    "Built moderate, weight gain 14 kg",
    ("Pallor:", "present, Hb 9.5 g/dL"),
    ("BP:", "124/80 mmHg, pulse 92/min"),
    "Oedema: mild pedal; no icterus",
    "CVS, RS: normal",
], size=16)
card(s, 4.7, 1.5, 4.0, 5.4, "Obstetric palpation", [
    ("Inspection:", "ovoid, wide abdomen, tense skin"),
    ("Fundal height:", "38 cm (expected about 34)"),
    ("Girth:", "increased"),
    ("Fundal grip:", "breech"),
    ("Lateral grip:", "many small parts, 3 or more poles"),
    ("Pelvic grip:", "Twin A cephalic, engaged 3/5"),
], hc=NAVY, size=16)
card(s, 8.9, 1.5, 3.95, 5.4, "Auscultation & PV", [
    ("FHS:", "two sounds, 140 and 148 bpm, silent zone between"),
    ("Lie:", "Twin A cephalic, Twin B breech"),
    ("PS/PV:", "cervix closed, uneffaced; membranes intact"),
    ("Pelvis:", "adequate"),
], hc=CORAL, size=16)

# ---------------- 5. Summary & diagnosis ----------------
s = new_slide("Summary and diagnosis", "Part 3",
              "Read the summary aloud in under a minute. This is the part the examiner remembers.")
rect(s, 0.5, 1.5, 12.3, 3.15, PALE_TEAL)
rect(s, 0.5, 1.5, 0.12, 3.15, TEAL)
text(s, 0.8, 1.55, 11.9, 3.05,
     "28-year-old G2P1L1, 34 weeks by LMP, confirmed by early scan, presented with abdominal distension "
     "large for dates and breathlessness. Spontaneous conception. First-trimester scan showed a dichorionic "
     "diamniotic twin pregnancy. On examination: pale (Hb 9.5 g/dL), BP 124/80, fundal height 38 cm, 3 or more "
     "fetal poles, two FHS (140 and 148 bpm) with a silent zone. Twin A cephalic, Twin B breech. Cervix closed.",
     size=18, color=DARK, anchor=MSO_ANCHOR.MIDDLE)
rect(s, 0.5, 4.85, 6.0, 2.05, NAVY)
text(s, 0.7, 4.9, 5.6, 0.4, "DIAGNOSIS", size=14, bold=True, color=GOLD)
text(s, 0.7, 5.25, 5.6, 1.6, "G2P1L1 at 34 weeks, DCDA twin pregnancy, Twin A cephalic and Twin B breech, "
     "with mild anaemia", size=19, bold=True, color=WHITE)
rect(s, 6.8, 4.85, 6.0, 2.05, LIGHT)
text(s, 7.0, 4.9, 5.6, 0.4, "PLAN IN ONE LINE", size=14, bold=True, color=CORAL)
text(s, 7.0, 5.25, 5.6, 1.6, "Treat anaemia, growth scans every 4 weeks, steroid cover if preterm birth "
     "is likely, planned birth at 37 to 38 weeks (vaginal trial since Twin A is cephalic)",
     size=17, color=DARK)

# ---------------- 6. Differential ----------------
s = new_slide("Large-for-dates uterus: differential diagnosis", "Part 3",
              "Always give the differential for a large-for-dates uterus.")
table(s, 0.5, 1.55, 12.3, [
    ["Cause", "Features", "How to separate from twins"],
    ["Wrong dates", "LMP uncertain, normal fetal number", "Early CRL scan"],
    ["Polyhydramnios", "Tense uterus, fluid thrill, hard to feel parts", "Single fetus; AFI above 25 cm"],
    ["Macrosomia / GDM", "One large fetus, maternal diabetes", "Single FHS, EFW above 90th centile"],
    ["Fibroid with pregnancy", "Irregular firm mass separate from fetus", "Ultrasound"],
    ["Molar pregnancy (early)", "Bleeding, high hCG, no fetal parts", "Snowstorm pattern on scan"],
    ["Twin pregnancy", "3 or more poles, 2 FHS, silent zone", "Two sacs and two fetuses on scan"],
], [3.0, 5.0, 4.3], rowh=0.62, size=16)
text(s, 0.5, 6.1, 12.3, 0.8,
     "Clinical clues for twins: fundal height more than 4 cm above gestational age, 3 or more fetal poles, "
     "two FHS with a 10 bpm difference, and a groove between the fetal bodies.",
     size=16, bold=True, color=TEAL)

# ---------------- 7. Embryology ----------------
s = new_slide("Types of twins: zygosity and chorionicity", "Part 4",
              "Timing of division of the monozygotic zygote decides chorionicity and amnionicity. Dizygotic twins are always DCDA.")
pic(s, "zygosity.jpg", 0.5, 1.5, w=6.3)
caption(s, 0.5, 5.35, 6.3, "Dizygotic (a) and monozygotic (b) twinning by timing of division (source: image library).")
table(s, 7.0, 1.55, 5.85, [
    ["Division after fertilisation", "Type"],
    ["Day 0 to 3", "DCDA (about 30%)"],
    ["Day 4 to 8", "MCDA (about 70%)"],
    ["Day 8 to 13", "MCMA (1 to 2%)"],
    ["After day 13", "Conjoined twins"],
], [3.2, 2.65], rowh=0.55, size=16)
bullets(s, 7.0, 4.5, 5.85, 2.4, [
    ("Dizygotic:", "about two thirds; two ova, always DCDA; rises with ART, age and parity"),
    ("Monozygotic:", "about one third; rate constant at 3 to 4 per 1000"),
], size=16)

# ---------------- 8. Chorionicity ----------------
s = new_slide("Why chorionicity matters", "Part 4",
              "Source: Creasy & Resnik's Maternal-Fetal Medicine. Perinatal mortality about 12% MC vs 2 to 5% DC.")
card(s, 0.5, 1.5, 6.0, 3.35, "Monochorionic twins", [
    "About 20% of twin pregnancies but the highest complication rate, due to shared placental anastomoses",
    "Perinatal mortality about 12% vs 2 to 5% in dichorionic twins",
    "Risks: TTTS, TAPS, TRAP, sFGR, co-twin death effects",
], hc=CORAL, size=16)
card(s, 6.8, 1.5, 6.0, 3.35, "Dichorionic twins", [
    "Separate placentas and circulations",
    "Main risks: preterm birth, growth discordance, pre-eclampsia",
    "Surveillance can be less intensive (4-weekly growth scans)",
], hc=TEAL, size=16)
table(s, 0.5, 5.05, 12.3, [
    ["Ultrasound sign (11 to 14 weeks)", "Lambda (twin-peak) sign", "T sign"],
    ["Chorionicity", "Dichorionic", "Monochorionic"],
], [4.5, 4.4, 3.4], rowh=0.55, size=16)
text(s, 0.5, 6.25, 12.3, 0.7,
     "Determine chorionicity in the first trimester. Accuracy falls after 14 weeks. Also count placental masses, "
     "check membrane thickness and fetal sex.", size=15, color=GREY)

# ---------------- 9. Complications ----------------
s = new_slide("Complications of twin pregnancy", "Part 5",
              "Maternal physiology: plasma volume up about 50 to 60%, higher cardiac output, uterine overdistension.")
card(s, 0.5, 1.5, 4.0, 5.4, "Maternal", [
    "Hyperemesis, anaemia",
    "Pre-eclampsia (2 to 3 times)",
    "Gestational diabetes",
    "Polyhydramnios",
    "Cholestasis of pregnancy",
    "Preterm labour, abruption, previa",
    "Operative delivery, PPH",
    "Thromboembolism, postnatal depression",
], size=16)
card(s, 4.7, 1.5, 4.0, 5.4, "Fetal / neonatal", [
    "Preterm birth (about 50% before 37 weeks)",
    "Growth restriction and discordance",
    "Congenital anomalies (about twice as common)",
    "Malpresentation, cord accidents",
    "Perinatal death, cerebral palsy",
    "Single intrauterine fetal death",
], hc=NAVY, size=16)
card(s, 8.9, 1.5, 3.95, 5.4, "Monochorionic only", [
    "TTTS (10 to 15%)",
    "TAPS",
    "TRAP sequence",
    "Selective growth restriction",
    "Co-twin injury after IUFD",
    "Cord entanglement (MCMA)",
], hc=CORAL, size=16)

# ---------------- 10. Investigations ----------------
s = new_slide("Investigations and surveillance schedule", "Part 6",
              "MCDA scanning every 2 weeks from 16 weeks follows RCOG/NICE advice. DCDA every 4 weeks from 20 weeks.")
table(s, 0.5, 1.5, 12.3, [
    ["Time", "DCDA", "MCDA"],
    ["11 to 14 weeks", "Dating by CRL (larger twin), chorionicity, NT", "Same; label twins A and B"],
    ["16 weeks", "Routine antenatal care", "Start 2-weekly scan: liquor, bladder, growth"],
    ["18 to 20 weeks", "Anomaly scan, cervical length", "Anomaly scan, fetal echo, cervical length"],
    ["From 20 to 22 weeks", "Growth scan every 4 weeks", "Growth, liquor, MCA Doppler every 2 weeks"],
    ["24 to 28 weeks", "OGTT, Hb, ferritin", "OGTT, Hb, ferritin"],
], [2.4, 5.0, 4.9], rowh=0.62, size=15)
text(s, 0.5, 5.4, 12.3, 0.4, "Other tests", size=17, bold=True, color=TEAL)
bullets(s, 0.5, 5.8, 12.3, 1.2, [
    "BP and urine protein every visit; urine culture; blood group and Rh; HIV, HBsAg, VDRL, TSH",
    "Third trimester: NST or biophysical profile and Doppler if growth restriction or other complications",
], size=15, gap=3)

# ---------------- 11. Antenatal management ----------------
s = new_slide("Antenatal management", "Part 7",
              "Aspirin guidance differs: NICE says 2 or more risk factors, ACOG says all twins in some guidance.")
card(s, 0.5, 1.5, 6.0, 5.4, "Supportive care", [
    ("Visits:", "every 2 weeks from 20 weeks; weekly in last month"),
    ("Nutrition:", "extra about 300 kcal/day and protein"),
    ("Iron:", "60 mg elemental or more; treat Hb below 11 g/dL"),
    ("Folic acid:", "4 mg; calcium and vitamin D"),
    ("Aspirin:", "75 to 150 mg from 12 weeks if risk factors"),
    ("Rest:", "left lateral position; prophylactic bed rest not proven"),
], size=16)
card(s, 6.8, 1.5, 6.0, 5.4, "Preterm birth preparedness", [
    ("Steroids:", "betamethasone 12 mg IM x 2, 24 h apart, if birth expected before 34 to 35 weeks"),
    ("Magnesium sulphate:", "neuroprotection if birth before 30 to 32 weeks"),
    ("Cerclage:", "not routine; consider in short cervix or past cervical insufficiency"),
    ("Progesterone / pessary:", "no clear benefit in unselected twins"),
    ("Tocolysis:", "nifedipine or atosiban; avoid beta-agonists"),
    ("Counsel:", "warning signs and birth plan"),
], hc=CORAL, size=16)

# ---------------- 12. TTTS ----------------
s = new_slide("Twin-twin transfusion syndrome", "Part 5",
              "Source: Creasy & Resnik's Maternal-Fetal Medicine. TTTS affects 10 to 15% of monochorionic pregnancies. "
              "Laser coagulation improves survival and short-term disability.")
pic(s, "ttts.jpg", 0.5, 1.45, h=5.5)
caption(s, 3.95, 5.8, 2.6, "TTTS at 22 weeks: plethoric recipient and pale donor (Creasy & Resnik).")
bullets(s, 6.7, 1.5, 6.2, 2.6, [
    ("Cause:", "net flow through deep arteriovenous anastomoses in a shared placenta"),
    ("Donor:", "hypovolaemia, oliguria, oligohydramnios, growth restriction"),
    ("Recipient:", "hypervolaemia, polyuria, polyhydramnios, cardiac strain, hydrops"),
    ("Diagnosis:", "MC twins; DVP below 2 cm in one sac and above 8 cm (above 10 cm after 20 weeks) in the other"),
], size=15, gap=4)
table(s, 6.7, 4.35, 6.2, [
    ["Quintero stage", "Feature"],
    ["I", "Oligo/polyhydramnios; donor bladder visible"],
    ["II", "Donor bladder not visible"],
    ["III", "Abnormal Doppler (UA, DV, UV)"],
    ["IV", "Hydrops"],
    ["V", "Death of one or both twins"],
], [1.6, 4.6], rowh=0.42, size=13)
text(s, 6.7, 6.9 - 0.05, 6.2, 0.1, "", size=2)

# ---------------- 13. Other MC complications ----------------
s = new_slide("Other monochorionic complications", "Part 5",
              "Anastomoses image from the image library (placental injection study).")
pic(s, "anastomoses.jpg", 0.5, 1.5, h=4.2)
caption(s, 0.5, 5.75, 4.2, "Dye injection of a shared placenta showing vascular communications.")
table(s, 5.0, 1.5, 7.85, [
    ["Condition", "Key point"],
    ["TAPS", "Tiny anastomoses; Hb discordance, MCA-PSV difference, no liquor discordance"],
    ["TRAP", "Acardiac twin perfused by the pump twin; treat by cord coagulation or ablation"],
    ["sFGR", "EFW of one twin below 10th centile; types I to III by umbilical artery Doppler"],
    ["Single IUFD", "Acute exsanguination of the survivor into the dead twin; brain injury risk"],
    ["MCMA", "Cord entanglement; caesarean at 32 to 34 weeks"],
], [1.9, 5.95], rowh=0.78, size=14)
text(s, 0.5, 6.2, 12.3, 0.7,
     "After single IUFD in MC twins: check MCA-PSV for anaemia, MRI after about 4 weeks, individualise timing, "
     "give steroids. Emergency delivery of the survivor does not undo injury already done.",
     size=14, bold=True, color=CORAL)

# ---------------- 14. Timing of delivery ----------------
s = new_slide("Timing of delivery (uncomplicated twins)", "Part 8",
              "Guidelines differ. Most guidelines advise DCDA birth at 37 to 38 weeks. Quote the guideline your unit follows. "
              "NICE NG137 and ACOG Practice Bulletin 231 are the two usually quoted.")
table(s, 0.5, 1.6, 12.3, [
    ["Type", "NICE NG137 (UK)", "ACOG (USA)"],
    ["DCDA", "Offer birth from 37+0; do not go beyond 37+6", "38+0 to 38+6 weeks"],
    ["MCDA", "36+0 weeks (consider steroids)", "34+0 to 37+6 weeks"],
    ["MCMA", "32+0 to 33+6 weeks with steroid cover", "32+0 to 34+0 weeks"],
    ["Complicated twins", "Individual assessment", "Individualise"],
], [2.6, 5.4, 4.3], rowh=0.75, size=17)
rect(s, 0.5, 5.6, 12.3, 1.2, PALE_CORAL)
text(s, 0.7, 5.65, 11.9, 1.1,
     "Why earlier for MC twins? Fetal death rates are consistently higher in monochorionic than dichorionic twins at all "
     "gestational ages, including in uncomplicated pregnancies.", size=17, color=DARK, anchor=MSO_ANCHOR.MIDDLE)

# ---------------- 15. Mode of delivery ----------------
s = new_slide("Mode of delivery", "Part 8",
              "Twin Birth Study (Barrett 2013): 2800 women, 32 to 38+6 weeks, Twin A cephalic; no difference in perinatal "
              "mortality or serious neonatal morbidity between planned CS and planned vaginal birth.")
table(s, 0.5, 1.55, 12.3, [
    ["Presentation / situation", "Plan"],
    ["Twin A cephalic (any Twin B)", "Planned vaginal birth is appropriate"],
    ["Twin A breech or transverse", "Caesarean section"],
    ["Monoamniotic twins", "Caesarean section (cord entanglement)"],
    ["Placenta previa, classical scar, conjoined twins", "Caesarean section"],
    ["One previous LSCS", "TOLAC possible with counselling; higher rupture risk"],
], [5.6, 6.7], rowh=0.68, size=17)
text(s, 0.5, 5.85, 12.3, 1.0,
     "For our patient: Twin A cephalic, so offer a trial of vaginal birth at 37 to 38 weeks with epidural, "
     "continuous CTG for both twins and readiness for emergency CS.",
     size=18, bold=True, color=TEAL)

# ---------------- 16. Intrapartum ----------------
s = new_slide("Intrapartum care and PPH prevention", "Part 9",
              "A 2024 systematic review confirms an increased risk of PPH in twin pregnancy (PMID 39367324).")
card(s, 0.5, 1.5, 4.0, 5.4, "Preparation", [
    "Unit with theatre, NICU, senior obstetrician and anaesthetist",
    "IV access, blood cross-matched",
    "Epidural early",
    "Continuous CTG for both twins",
    "Ultrasound machine in the room",
    "Two paediatric teams",
], size=15)
card(s, 4.7, 1.5, 4.0, 5.4, "Delivery of Twin B", [
    "Clamp cord of Twin A; check lie by abdomen, PV and scan",
    "Longitudinal lie: wait for contractions or start oxytocin; rupture membranes when engaged",
    "Transverse lie: ECV or internal podalic version with breech extraction",
    "Aim for a short interval; fetal heart rate is the guide",
    "Abnormal CTG or cord prolapse: expedite delivery",
], hc=NAVY, size=15)
card(s, 8.9, 1.5, 3.95, 5.4, "Third stage and PPH", [
    "Oxytocin 10 IU IM or 5 IU IV slowly after Twin B",
    "Ergometrine if not hypertensive; carboprost available",
    "Tranexamic acid ready",
    "Send placentas for chorionicity",
    "Rare: locked twins, abruption after Twin A",
], hc=CORAL, size=15)

# ---------------- 17. Viva ----------------
s = new_slide("High-yield viva questions", "Part 10",
              "Rehearse short answers: each should fit in 30 seconds.")
qa = [
    ("How are twins classified?", "By zygosity, then chorionicity and amnionicity (timing of division)."),
    ("Best time to determine chorionicity?", "11 to 14 weeks: lambda sign (DC), T sign (MC)."),
    ("Which twins need 2-weekly scans?", "Monochorionic, from 16 weeks, for TTTS, sFGR and TAPS."),
    ("When to deliver uncomplicated DCDA / MCDA?", "37 to 38 weeks / 36 to 37 weeks (guideline dependent)."),
    ("Twin A cephalic: mode?", "Planned vaginal birth is appropriate."),
    ("Why avoid beta-agonists in preterm labour?", "Higher plasma volume; risk of pulmonary oedema."),
    ("Treatment of TTTS stage II to IV?", "Fetoscopic laser coagulation (16 to 26 weeks)."),
]
for i, (q, a) in enumerate(qa):
    y = 1.5 + i * 0.77
    rect(s, 0.5, y, 0.45, 0.65, TEAL if i % 2 == 0 else NAVY)
    text(s, 0.5, y, 0.45, 0.65, str(i + 1), size=16, bold=True, color=WHITE, align=PP_ALIGN.CENTER, anchor=MSO_ANCHOR.MIDDLE)
    rect(s, 0.95, y, 11.85, 0.65, LIGHT)
    text(s, 1.1, y, 4.9, 0.65, q, size=15, bold=True, color=NAVY, anchor=MSO_ANCHOR.MIDDLE)
    text(s, 6.1, y, 6.6, 0.65, a, size=15, color=DARK, anchor=MSO_ANCHOR.MIDDLE)

# ---------------- 18. Take home ----------------
s = new_slide("Take-home messages", "Summary")
msgs = [
    ("1", "Chorionicity first", "Confirm it in the first trimester; it drives surveillance and timing."),
    ("2", "Think of the complications", "Anaemia, pre-eclampsia, GDM, preterm birth, growth discordance."),
    ("3", "Monochorionic means closer watch", "2-weekly scans from 16 weeks; know TTTS, TAPS, sFGR."),
    ("4", "Plan delivery early", "Timing by chorionicity; mode by Twin A presentation."),
    ("5", "Be ready for PPH", "Overdistended uterus: active management, blood and tranexamic acid ready."),
]
for i, (n, h, d) in enumerate(msgs):
    y = 1.5 + i * 1.08
    rect(s, 0.5, y, 12.3, 0.95, LIGHT)
    rect(s, 0.5, y, 0.95, 0.95, [TEAL, NAVY, CORAL, TEAL, NAVY][i])
    text(s, 0.5, y, 0.95, 0.95, n, size=28, bold=True, color=WHITE, align=PP_ALIGN.CENTER, anchor=MSO_ANCHOR.MIDDLE)
    text(s, 1.65, y, 4.3, 0.95, h, size=20, bold=True, color=NAVY, anchor=MSO_ANCHOR.MIDDLE)
    text(s, 6.0, y, 6.7, 0.95, d, size=16, color=DARK, anchor=MSO_ANCHOR.MIDDLE)

# ---------------- 19. References ----------------
s = new_slide("References", "Sources")
bullets(s, 0.6, 1.6, 12.1, 5.3, [
    "Creasy & Resnik's Maternal-Fetal Medicine: Principles and Practice. Chapters on multiple pregnancy, "
    "monochorionic twins and TTTS (pp. 110, 852, 3292 to 3296).",
    "NICE Guideline NG137. Twin and triplet pregnancy (2019, updated).",
    "ACOG Practice Bulletin No. 231. Multifetal gestations (2021).",
    "RCOG Green-top Guideline No. 51. Management of monochorionic twin pregnancy (2016).",
    "Fox NS et al. Twin pregnancy guidelines review. Am J Obstet Gynecol 2023.",
    "Abdulsalam FAM et al. Twin pregnancy and postpartum haemorrhage: systematic review and meta-analysis. "
    "BMC Pregnancy Childbirth 2024 (PMID 39367324).",
    "Barrett JFR et al. Twin Birth Study. N Engl J Med 2013.",
], size=16, gap=8)

prs.save("/tmp/workspace/twin-pregnancy-ppt/output/Twin_Pregnancy_Case_Discussion.pptx")
print("saved", state["n"])
Running Command

cd /tmp/workspace/twin-pregnancy-ppt && python build.py

Reading File
Running Command

cd /tmp/workspace/twin-pregnancy-ppt && python - <<'E' p='build.py' s=open(p).read() s=s.replace('pic(s, "ttts.jpg", 0.5, 1.45, h=5.5)\ncaption(s, 3.95, 5.8, 2.6, "TTTS at 22 weeks: plethoric recipient and pale donor (Creasy & Resnik).")', 'pic(s, "ttts.jpg", 0.5, 1.45, h=4.9)\ncaption(s, 0.5, 6.4, 4.2, "TTTS at 22 weeks: plethoric recipient (left), pale donor (right). Creasy & Resnik.")') s=s.replace('bullets(s, 6.7, 1.5, 6.2, 2.6, [\n ("Cause:"','bullets(s, 4.5, 1.5, 8.35, 2.7, [\n ("Cause:"') s=s.replace('table(s, 6.7, 4.35, 6.2, [\n ["Quintero stage", "Feature"],','table(s, 4.5, 4.35, 8.35, [\n ["Quintero stage", "Feature"],') s=s.replace('], [1.6, 4.6], rowh=0.42, size=13)\ntext(s, 6.7, 6.9 - 0.05, 6.2, 0.1, "", size=2)','], [1.8, 6.55], rowh=0.42, size=14)') open(p,'w').write(s) E python build.py && python - <<'E' from pptx import Presentation from pptx.util import Emu p=Presentation('/tmp/workspace/twin-pregnancy-ppt/output/Twin_Pregnancy_Case_Discussion.pptx') for i,sl in enumerate(p.slides,1): for sh in sl.shapes: if sh.left+sh.width>p.slide_width+10 or sh.top+sh.height>p.slide_height+10: print('OOB',i,sh.shape_type,sh.name) print(len(p.slides)) E

I've built the 19-slide deck:

Twin Pregnancy Case Discussion

Presentation · PPTX

I couldn't render the slides here, so I haven't seen them. A script check found no shapes running off the slide, but please click through for text overflow before presenting.
#Slide
1-2Title, outline
3-4Case history and examination (model patient)
5One-slide summary, diagnosis and plan
6Differential diagnosis of a large-for-dates uterus
7Zygosity and chorionicity (library diagram)
8Why chorionicity matters, lambda sign versus T sign
9Maternal, fetal and monochorionic-only complications
10Investigations and a DCDA versus MCDA scan schedule
11Antenatal management
12Twin-twin transfusion syndrome, with the Creasy & Resnik photograph and Quintero staging
13Other monochorionic complications (TAPS, TRAP, selective growth restriction, single fetal death, MCMA), with a placental anastomosis image
14Timing of delivery, NICE versus ACOG
15Mode of delivery
16Intrapartum care, delivery of Twin B, postpartum haemorrhage prevention
17Seven high-yield viva questions with short answers
18-19Take-home messages, references
Speaker notes are on most slides.
  • Patient details: the patient (28 years, G2P1L1, 34 weeks, DCDA, Twin A cephalic, Twin B breech, Hb 9.5) is a model case. Replace the history, examination and summary on slides 3-5 with your own patient's findings. The title slide has blanks for presenter, unit and date.
  • Images: the lambda and T sign ultrasound search returned nothing, so slide 8 uses a table instead. If you have your own scan images, add them there.
  • Guidelines: the delivery timings on slide 14 and the surveillance schedule on slide 10 follow NICE, ACOG and RCOG. Use your unit's protocol if it differs.
  • Unchecked from memory: the Twin Birth Study details, the Quintero stages and the drug doses come from my own knowledge, not from a source I checked. Please verify them before an exam or case conference.
  • Broken link in my earlier answer: the Creasy & Resnik link in viva Q2 was malformed. That chapter is the Creasy & Resnik's Maternal-Fetal Medicine section on complicated monochorionic twin pregnancies, and it is correctly cited in the deck.
This is a shared conversation. Sign in to Orris to start your own chat.