Classification of Muscles on the basis of Shape fiber and architecture

Reading File
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Reading File
Reading File
Reading File
Loading Image
Finding Sources
Reading File
Loading Image
Loading Image
Loading Image
I now have everything needed for a comprehensive, well-illustrated answer. Here is the full classification:

Classification of Muscles on the Basis of Shape, Fiber, and Architecture


1. Classification Based on Microscopic Appearance (Fiber Type by Striations)

Muscle tissue is classified according to the appearance of its contractile cells. Two principal types are recognized:

A. Striated Muscle

Cells exhibit cross-striations visible under the light microscope. The striations arise from the highly ordered, parallel arrangement of thick (myosin) and thin (actin) myofilaments.
Striated muscle is further subclassified by location:
SubtypeLocationControlKey Features
Skeletal MuscleAttached to bone (axial & appendicular skeleton); also tongue, pharynx, diaphragm, upper esophagusVoluntaryMultinucleated syncytium; peripheral nuclei; diameter 10-100 µm; used for posture, movement
Visceral (Striated) MuscleTongue, pharynx, upper esophagus, lumbar diaphragmVoluntaryMorphologically identical to skeletal; roles in speech, swallowing, breathing
Cardiac MuscleWall of heart; base of great veinsInvoluntaryBranched, mono/binucleated cells; intercalated discs; rhythmic contraction

B. Smooth Muscle

  • Cells lack cross-striations because myofilaments do not achieve the same ordered arrangement.
  • Myosin-containing myofilaments are highly labile.
  • Found in: viscera, vascular walls, arrector pili of skin, intrinsic eye muscles.
- Histology: A Text and Atlas with Correlated Cell and Molecular Biology

2. Classification Based on Fiber Type (Metabolic/Contractile Properties)

Skeletal muscle fibers are classified based on their metabolic profile, speed of contraction, and fatiguability:
PropertyType I (Slow-Twitch / Red)Type II (Fast-Twitch / White)
Also calledSlow oxidative (SO)Fast glycolytic (FG)
Myoglobin contentHigh (red)Low (white)
MitochondriaNumerousFewer
Energy sourceOxidative phosphorylationGlycogen, phosphocreatine
FatiguabilityFatigue-resistantEasily fatigable
Contraction speedSlowFast
Typical locationPostural muscles (e.g., soleus)Extremity muscles needing quick bursts (e.g., biceps)
- Imaging Anatomy: Text and Atlas, Volume 3 - Bones, Joints, Vessels and Nerves

3. Classification Based on Shape and Gross Architecture

Gross skeletal muscle architecture is defined as the number and orientation of muscle fibers within a muscle relative to the axis of force generation. Key parameters include fiber length (FL), muscle length (ML), pennation angle (θ), anatomical cross-sectional area (ACSA), and physiological cross-sectional area (PCSA).

A. Longitudinal / Parallel Fiber Architecture

Muscle fibers run parallel to the muscle's line of action (force-generating axis). Sarcomeres act in series, which favors:
  • Greater length changes
  • Higher velocity of shortening
  • Less force but more excursion
This architecture includes several shape subtypes:

i. Fusiform (Spindle-shaped)

  • Fibers parallel, tapering at both ends into tendons
  • Wide belly, narrow at attachments
  • Examples: biceps brachii, hamstrings, brachialis

ii. Strap (Straplike / Parallel-fibered)

  • Long, ribbon-like muscle with parallel fibers spanning the whole length
  • The longest muscles in the body; greatest excursion
  • Examples: sartorius, sternohyoid, gracilis, semitendinosus

iii. Circular (Sphincteric)

  • Fibers arranged in concentric rings around an opening
  • Contract to close the opening
  • Examples: orbicularis oculi, orbicularis oris

iv. Fan-shaped (Convergent / Triangular)

  • Broad origin converging to a narrow tendon
  • Fibers run at angles, allowing varied direction of pull
  • Example: pectoralis major (5 subsegments converging to a twisted tendon on proximal humerus)

v. Strap with Tendinous Intersections

  • Parallel muscle divided into distinct bellies by fibrous intersections
  • Example: rectus abdominis

B. Pennate Fiber Architecture

Fibers run obliquely to the muscle's line of action at a pennation angle (θ). Sarcomeres act in parallel, so their forces add - favoring:
  • Short-length contractions
  • High force production
  • Greater PCSA
The PCSA (sum of all fiber cross-sectional areas) better predicts force than ACSA in pennate muscles. Large mass + short fiber length = large PCSA.
Pennate architecture is subclassified as:

i. Unipennate

  • Fibers attach to one side of a central tendon, like a half-feather
  • Example: vastus lateralis, flexor pollicis longus, tibialis posterior

ii. Bipennate

  • Fibers attach to both sides of a central tendon, like a full feather (V-shaped pattern)
  • Example: gastrocnemius, dorsal foot interossei, rectus femoris

iii. Multipennate

  • Complex pattern with fibers oriented at multiple angles to the line of action
  • These muscles have exceptionally large PCSA for their size
  • Example: soleus (modest mass, very short fibers of ~4 cm → large PCSA), deltoid, trapezius, gluteus medius
  • The three strongest lower extremity muscles by PCSA: soleus, vastus lateralis, gluteus medius

iv. Circumpennate (special subtype)

  • Fibers surround a central tendon on all sides
  • Example: tibialis anterior

Here is a visual overview of these architectural types from Imaging Anatomy, Vol. 3:
Muscle architectural types: (a) biceps - fusiform/parallel, (b) gluteus maximus - parallel, (c) vastus lateralis/sartorius - unipennate/strap, (d) gluteus medius - multipennate, (e) deltoid - multipennate, (f) gastrocnemius/soleus - bipennate/multipennate
Fig 1.19 - Generalized muscle architectural types showing FL (fiber length) and ML (muscle length). Longitudinal in (a-b), unipennate in (c), multipennate in (d-f).
Rectus abdominis (strap with intersections), pectoralis major (fan/convergent), and bipennate/unipennate plantar foot muscles
Fig 1.20 - Additional architectural types: parallel with tendinous intersections (rectus abdominis), fan-shaped (pectoralis major), and V-shaped bipennate pattern.
And the connective tissue hierarchy of skeletal muscle:
Skeletal muscle organization showing epimysium, perimysium, endomysium, muscle fascicle, fiber, and myofibril
Fig 11.2 - Hierarchical organization: epimysium wraps the whole muscle, perimysium surrounds fascicles, endomysium surrounds individual fibers.

Summary Table

Classification BasisTypes
Striations (microscopic)Striated (skeletal, visceral, cardiac) / Smooth
Fiber metabolic typeType I (slow-twitch, oxidative) / Type II (fast-twitch, glycolytic)
Fiber orientation / ArchitectureLongitudinal/Parallel / Pennate
Shape (parallel subgroups)Fusiform, Strap, Circular, Fan-shaped, Strap with intersections
Pennate subgroupsUnipennate, Bipennate, Multipennate, Circumpennate

Key functional principle: Parallel-fiber muscles prioritize range and velocity of movement; pennate-fiber muscles prioritize force production. Most muscles in the body are a combination of these patterns, dominated by one.
Sources: Histology: A Text and Atlas with Correlated Cell and Molecular Biology | Imaging Anatomy: Text and Atlas, Volume 3 - Bones, Joints, Vessels and Nerves

Explain the Classification of Muscles on the basis of Shape fiber and architecture with diagrams

Finding Sources
Finding Sources
Reading File
Finding Sources
Loading Image
Loading Image
Loading Image
Loading Image
Finding Sources
Loading Image
I now have all the text content and diagrams needed. Here is the full, diagram-rich explanation:

Classification of Muscles on the Basis of Shape, Fiber, and Architecture


PART 1 - Classification by Microscopic Appearance (Striations)

Muscle tissue is classified by the appearance of its contractile cells at the light microscope level into two principal groups:

A. Striated Muscle

Cells show cross-striations produced by the highly ordered, alternating arrangement of thick (myosin) and thin (actin) myofilaments organized into sarcomeres. Each sarcomere runs from Z-line to Z-line and is 2-3 µm in length.
Striated muscle is further divided by location and function:
Skeletal MuscleVisceral Striated MuscleCardiac Muscle
LocationAttached to bone; also tongue, pharynx, upper esophagus, diaphragmSoft tissues only (tongue, pharynx, upper esophagus)Wall of heart; base of great veins
NucleiMultiple, peripheral (beneath sarcolemma)Multiple, peripheral1-2, central
ControlVoluntaryVoluntaryInvoluntary (autonomous)
Special featureMultinucleated syncytium; diameter 10-100 µmMorphologically identical to skeletalBranched cells; intercalated discs
FunctionMovement, postureSpeech, swallowing, breathingRhythmic cardiac contraction
Diagram comparing skeletal and cardiac striated muscle structure, showing cell arrangement, fibroblasts, satellite cells, intercalated disks, and the neuromuscular junction with sarcolemma, myofibrils, and sarcoplasmic reticulum
Fig 1.18 - Structure of striated muscles. Skeletal muscle (left): parallel multinucleated fibers with satellite cells. Cardiac muscle (right): branched cardiomyocytes connected by intercalated discs. Bottom: the neuromuscular junction showing synaptic cleft between presynaptic terminal and postsynaptic sarcolemma.

B. Smooth Muscle

  • No cross-striations - myofilaments are not arranged in the same ordered pattern
  • Myosin-containing filaments are highly labile
  • Cells are spindle-shaped with a single central nucleus
  • Location: viscera, blood vessel walls, arrector pili of skin, intrinsic eye muscles
  • Control: involuntary

PART 2 - Classification by Fiber Type (Metabolic/Contractile Properties)

Skeletal muscle fibers are classified into three phenotypes based on metabolic properties, contraction speed, and fatigue resistance:
PropertyType I (Slow-Twitch Oxidative)Type II (Fast-Twitch Oxidative/Glycolytic)Type III (Fast-Twitch Glycolytic)
ColorRedRedWhite
MyoglobinHighHighLow
MitochondriaNumerousMore than Type IFew
Energy sourceOxidative phosphorylationOxidative + glycolyticGlycogen, phosphocreatine
FatiguabilityFatigue-resistantFatigue-resistantEasily fatigable
Capillary densityDenseDenseSparse
Fiber diameterThinLarge-
Typical locationPostural muscles (e.g., soleus)Mixed musclesExtremity muscles - short bursts
Functional principle: Type I fibers dominate in muscles designed for sustained posture. Type II/III fibers dominate in muscles needing rapid, powerful, short-duration contractions.

PART 3 - Classification by Shape and Fiber Architecture

Architecture is defined as the number and orientation of fibers relative to the muscle's force-generating axis. Key parameters:
  • FL = Fiber Length
  • ML = Muscle Length
  • ACSA = Anatomical Cross-Sectional Area (largest single cross-section)
  • PCSA = Physiological Cross-Sectional Area (sum of all fiber cross-sections) - best predictor of maximal force

Connective Tissue Hierarchy (structural basis of architecture)

Skeletal muscle hierarchical organization: epimysium surrounds the whole muscle, perimysium surrounds fascicles, endomysium surrounds individual fibers. SEM on left shows endomysium; 3D diagram on right shows fascicle, fiber, and myofibril
Muscle organization: Epimysium (whole muscle) → Perimysium (fascicle) → Endomysium (individual fiber) → Myofibril

GROUP 1 - Longitudinal / Parallel Fiber Architecture

Fibers run parallel to the muscle's line of action. Sarcomeres act in series → forces are additive in terms of shortening.
Functional outcome: Greater range of motion, higher velocity of shortening, less force per unit cross-section.

1. Fusiform (Spindle-shaped)

  • Thick in the middle, tapering at both ends
  • Wide fleshy belly between two tendons
  • Examples: biceps brachii, brachialis, hamstrings
Muscle architecture types: (a) biceps brachii showing fusiform/parallel architecture with FL and ML labeled; (b) gluteus maximus showing large parallel architecture with ACSA shown; (c) vastus lateralis (unipennate) and sartorius (strap) side by side; (d) gluteus medius (multipennate); (e) deltoid (multipennate); (f) gastrocnemius and soleus (bipennate/multipennate)
Fig 1.19 - Muscle architectural types. (a) Biceps = fusiform/parallel; (b) Gluteus maximus = parallel; (c) Vastus lateralis = unipennate, Sartorius = strap; (d) Gluteus medius = multipennate; (e) Deltoid = multipennate; (f) Gastrocnemius + Soleus = bipennate/multipennate. FL = fiber length, ML = muscle length, ACSA = anatomical cross-sectional area.

2. Strap (Straplike / Parallel-fibered)

  • Long, flat, ribbon-like muscle
  • Fibers run the entire muscle length
  • Longest fibers in the body → greatest excursion
  • Examples: sartorius (longest muscle), gracilis, semitendinosus, sternohyoid

3. Circular (Sphincteric)

  • Fibers arranged in concentric rings around an orifice
  • Contraction closes the opening
  • Examples: orbicularis oculi, orbicularis oris

4. Strap with Tendinous Intersections

  • Parallel muscle divided into distinct bellies by transverse fibrous bands
  • Example: rectus abdominis (divided into 4 bellies by tendinous inscriptions)

5. Fan-shaped (Convergent / Triangular)

  • Broad origin, fibers converge to a narrow tendon
  • Allows pull from multiple directions depending on which portion contracts
  • Example: pectoralis major - 5 subsegments with a complex, twisted distal tendon inserting on the proximal humerus

GROUP 2 - Pennate Fiber Architecture

Fibers run obliquely to the force-generating axis at the pennation angle (θ), like a feather (penna = Latin for feather). Sarcomeres act in parallel → forces add directly.
Functional outcome: More fibers packed into the same muscle volume → larger PCSA → greater force production. Trade-off: shorter excursion and lower velocity.
The soleus muscle has a modest mass but very short fibers (~4 cm), giving it an exceptionally large PCSA. The vastus lateralis has 50% greater mass but much longer fibers (~10 cm), resulting in a smaller PCSA than soleus.
The three strongest muscles in the lower extremity (by PCSA): soleus > vastus lateralis > gluteus medius

1. Unipennate

  • Fibers attach to one side only of a central tendon (half-feather pattern)
  • Examples: vastus lateralis, flexor pollicis longus, tibialis posterior, extensor digitorum longus

2. Bipennate

  • Fibers attach to both sides of a central tendon (full feather / V-shape)
  • Examples: gastrocnemius, dorsal foot interossei, rectus femoris

3. Multipennate

  • Fibers oriented at multiple angles to the line of action - highly complex internal architecture
  • Examples: soleus, deltoid, trapezius, gluteus medius
  • These muscles have the greatest force-generating capacity relative to their size
Additional muscle architecture types: (a) rectus abdominis - strap with tendinous intersections (blue shows fasciae); (b) pectoralis major - fan/convergent shape with 5 subsegments converging; (c) bipennate (V-shaped) and unipennate patterns of plantar foot muscles
Fig 1.20 - (a) Rectus abdominis: strap muscle with tendinous intersections. (b) Pectoralis major: fan-shaped convergent architecture. (c) Bipennate (V-shaped, fibers converging on a central tendon from both sides) and unipennate plantar muscles.

4. Circumpennate

  • Fibers surround a central tendon on all sides (cylindrical pennation)
  • Example: tibialis anterior

Histological appearance of skeletal muscle fibers

Photomicrograph of skeletal muscle longitudinal section (H&E): (a) low magnification showing epimysium, fascicles arranged in parallel, and nerve; (b) high magnification showing cross-striations clearly, with peripheral nuclei immediately beneath the sarcolemma
H&E histology of skeletal muscle. (a) Low magnification: epimysium, fascicles. (b) High magnification: cross-striations and peripheral nuclei of individual muscle fibers.

Summary: All Classifications at a Glance

MUSCLE CLASSIFICATION
│
├── 1. BY MICROSCOPIC APPEARANCE
│   ├── Striated
│   │   ├── Skeletal (voluntary, multinucleated, peripheral nuclei)
│   │   ├── Visceral striated (tongue, pharynx, esophagus)
│   │   └── Cardiac (involuntary, branched, intercalated discs)
│   └── Smooth (no striations, viscera/vessels)
│
├── 2. BY FIBER METABOLIC TYPE
│   ├── Type I   → Slow-twitch, oxidative, red, fatigue-resistant
│   ├── Type II  → Fast-twitch, oxidative/glycolytic, red
│   └── Type III → Fast-twitch, glycolytic, white, fatigable
│
└── 3. BY SHAPE AND ARCHITECTURE
    ├── Parallel/Longitudinal (favor velocity & range)
    │   ├── Fusiform (biceps, brachialis)
    │   ├── Strap (sartorius, semitendinosus)
    │   ├── Circular/Sphincteric (orbicularis)
    │   ├── Fan-shaped/Convergent (pectoralis major)
    │   └── Strap with intersections (rectus abdominis)
    └── Pennate (favor force production)
        ├── Unipennate (vastus lateralis)
        ├── Bipennate (gastrocnemius, rectus femoris)
        ├── Multipennate (soleus, deltoid, trapezius)
        └── Circumpennate (tibialis anterior)
Core architectural principle: Parallel-fiber muscles maximize velocity and excursion. Pennate-fiber muscles maximize force production by packing more fibers per unit volume (larger PCSA). Most real muscles combine both patterns, with one dominating.

Sources: Imaging Anatomy: Text and Atlas, Volume 3 - Bones, Joints, Vessels and Nerves | Histology: A Text and Atlas with Correlated Cell and Molecular Biology

Create a detailed presentation comparing pennate vs. parallel muscle architecture

Reading File
Finding Sources
Reading File
Reading File
Reading File
Running Command

mkdir -p /home/daytona/workspace/muscle-architecture-pptx && ls /home/daytona/workspace/muscle-architecture-pptx

Running Command

node /home/daytona/skills/shared/scripts/fetch_images.js \ "https://cdn.orris.care/cdss_images/d14d493bc0a7371d41e1cc1598d1e0bf253209e5668f7f4b04fd9c17432ce24b.png" \ "https://cdn.orris.care/cdss_images/da329bcc58aa0f028ad26eb5a09730019bb717786718c0729d14458587edb0e7.png" \ "https://cdn.orris.care/cdss_images/cf8277db6bcc42a1d8a1f0da513111431c010ef4821bc0e9c71c9cea97ca3ac9.png" \ "https://cdn.orris.care/cdss_images/945252f74b4b6f7e9f0fd72c68578417e6cc4a47f623605619e0149a4a23056e.png" \ > /home/daytona/workspace/muscle-architecture-pptx/images.json 2>&1 echo "Exit: $?" head -c 200 /home/daytona/workspace/muscle-architecture-pptx/images.json

Writing File

~/muscle-architecture-pptx/build.js

const pptxgen = require("pptxgenjs");
const fs = require("fs");

// Load pre-fetched images
const images = JSON.parse(fs.readFileSync("/home/daytona/workspace/muscle-architecture-pptx/images.json"));
const imgArchTypes   = images[0].base64; // architecture types (biceps, gluteus, vastus...)
const imgAdditional  = images[1].base64; // rectus, pectoralis, bipennate foot
const imgStriated    = images[2].base64; // skeletal vs cardiac structure
const imgConnective  = images[3].base64; // epimysium/perimysium/endomysium

// ─── Color palette ───────────────────────────────────────────────────────────
const C = {
  darkBg:    "0D1B2A",   // deep navy - title/section slides
  midBg:     "162032",   // slightly lighter navy
  cardBg:    "FFFFFF",   // white cards
  parallel:  "1A9E74",   // teal-green  → parallel muscle
  pennate:   "E05C2A",   // burnt orange → pennate muscle
  accent:    "F2C94C",   // gold accent
  lightText: "F0F4F8",
  mutedText: "94A3B8",
  darkText:  "1E293B",
  white:     "FFFFFF",
  parallelLight: "D1F5EA",
  pennateLight:  "FDEBD5",
  divider:   "334155",
};

let pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.author  = "Orris Medical";
pres.title   = "Pennate vs Parallel Muscle Architecture";
pres.subject = "Anatomy – Muscle Architecture";

// ══════════════════════════════════════════════════════════════════════════════
// Helper: dark full-bleed background
function darkBg(slide, color) {
  slide.addShape(pres.shapes.RECTANGLE, {
    x: 0, y: 0, w: 10, h: 5.625,
    fill: { color: color || C.darkBg }, line: { color: color || C.darkBg }
  });
}

// Helper: accent bar at top
function topAccentBar(slide, color) {
  slide.addShape(pres.shapes.RECTANGLE, {
    x: 0, y: 0, w: 10, h: 0.06,
    fill: { color: color || C.accent }, line: { color: color || C.accent }
  });
}

// Helper: label pill/badge
function badge(slide, label, x, y, w, bgColor, textColor) {
  slide.addShape(pres.shapes.ROUNDED_RECTANGLE, {
    x, y, w, h: 0.34, fill: { color: bgColor }, line: { color: bgColor }, rectRadius: 0.05
  });
  slide.addText(label, {
    x, y, w, h: 0.34, fontSize: 10, bold: true, color: textColor,
    align: "center", valign: "middle", margin: 0
  });
}

// Helper: section heading label
function sectionLabel(slide, text, color) {
  slide.addText(text, {
    x: 0.5, y: 0.08, w: 9, h: 0.3,
    fontSize: 9, bold: true, color: color || C.accent,
    charSpacing: 3, align: "left", margin: 0
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 1 — Title
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, C.darkBg);

  // Diagonal color split
  s.addShape(pres.shapes.RECTANGLE, {
    x: 0, y: 0, w: 4.9, h: 5.625,
    fill: { color: "0F2A1E" }, line: { color: "0F2A1E" }
  });
  s.addShape(pres.shapes.RECTANGLE, {
    x: 5.1, y: 0, w: 4.9, h: 5.625,
    fill: { color: "2A1408" }, line: { color: "2A1408" }
  });

  // Thin vertical divider
  s.addShape(pres.shapes.RECTANGLE, {
    x: 4.92, y: 0.3, w: 0.06, h: 5.0,
    fill: { color: C.accent }, line: { color: C.accent }
  });

  // Left label
  badge(s, "PARALLEL  ARCHITECTURE", 0.5, 0.5, 4.1, C.parallel, C.white);
  // Right label
  badge(s, "PENNATE  ARCHITECTURE", 5.4, 0.5, 4.1, C.pennate, C.white);

  // Main title
  s.addText("PENNATE vs. PARALLEL", {
    x: 0.4, y: 1.2, w: 9.2, h: 0.9,
    fontSize: 38, bold: true, color: C.white,
    align: "center", charSpacing: 2
  });
  s.addText("Muscle Architecture", {
    x: 0.4, y: 2.0, w: 9.2, h: 0.65,
    fontSize: 26, bold: false, color: C.accent,
    align: "center", charSpacing: 1
  });

  // Subtitle
  s.addText("A Detailed Comparative Analysis", {
    x: 1, y: 2.75, w: 8, h: 0.4,
    fontSize: 14, color: C.mutedText, align: "center", italic: true
  });

  // Divider line
  s.addShape(pres.shapes.RECTANGLE, {
    x: 3.0, y: 3.22, w: 4.0, h: 0.03,
    fill: { color: C.divider }, line: { color: C.divider }
  });

  // Key topics
  const topics = ["Shape & Structure", "Fiber Orientation", "Force vs. Velocity", "PCSA & Mechanics", "Clinical Examples"];
  topics.forEach((t, i) => {
    s.addText("• " + t, {
      x: 1.0 + i * 1.62, y: 3.35, w: 1.5, h: 0.3,
      fontSize: 8.5, color: C.mutedText, align: "center"
    });
  });

  // Footer
  s.addText("Source: Imaging Anatomy Vol. 3 | Histology: A Text and Atlas", {
    x: 0.3, y: 5.2, w: 9.4, h: 0.25,
    fontSize: 8, color: C.divider, align: "center"
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 2 — Overview / Agenda
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, C.midBg);
  topAccentBar(s);
  sectionLabel(s, "OVERVIEW");

  s.addText("What We'll Cover", {
    x: 0.5, y: 0.5, w: 9, h: 0.55,
    fontSize: 26, bold: true, color: C.white, margin: 0
  });

  const items = [
    { n: "01", title: "Structural Classification", desc: "How muscles are grouped by fiber orientation and shape", color: C.parallel },
    { n: "02", title: "Parallel Architecture",     desc: "Fusiform, strap, circular, fan-shaped — structure, mechanics, examples", color: C.parallel },
    { n: "03", title: "Pennate Architecture",       desc: "Unipennate, bipennate, multipennate — fiber angle and force output", color: C.pennate },
    { n: "04", title: "Biomechanics: Force & Speed", desc: "PCSA, fiber length, pennation angle (θ), sarcomere logic", color: C.accent },
    { n: "05", title: "Head-to-Head Comparison",   desc: "Direct comparison table across 8 key parameters", color: C.mutedText },
    { n: "06", title: "Clinical Relevance",         desc: "Injury patterns, rehabilitation, surgical planning", color: "E879F9" },
  ];

  items.forEach((item, i) => {
    const col = i % 3;
    const row = Math.floor(i / 3);
    const x = 0.3 + col * 3.22;
    const y = 1.25 + row * 2.0;

    s.addShape(pres.shapes.RECTANGLE, {
      x, y, w: 3.05, h: 1.7,
      fill: { color: "1E2D3D" }, line: { color: item.color },
      shadow: { type: "outer", color: "000000", blur: 8, offset: 2, angle: 135, opacity: 0.25 }
    });
    // number
    s.addText(item.n, {
      x: x + 0.12, y: y + 0.1, w: 0.55, h: 0.45,
      fontSize: 20, bold: true, color: item.color, align: "left", margin: 0
    });
    // title
    s.addText(item.title, {
      x: x + 0.12, y: y + 0.52, w: 2.8, h: 0.4,
      fontSize: 11.5, bold: true, color: C.white, margin: 0
    });
    // desc
    s.addText(item.desc, {
      x: x + 0.12, y: y + 0.92, w: 2.8, h: 0.68,
      fontSize: 9, color: C.mutedText, margin: 0
    });
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 3 — Structural Classification (the two main groups)
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, C.darkBg);
  topAccentBar(s, C.parallel);
  sectionLabel(s, "STRUCTURAL CLASSIFICATION", C.parallel);

  s.addText("Two Major Architectural Groups", {
    x: 0.5, y: 0.45, w: 9, h: 0.55,
    fontSize: 24, bold: true, color: C.white, margin: 0
  });
  s.addText("Muscle architecture is defined as the number and orientation of fibers relative to the axis of force generation.", {
    x: 0.5, y: 0.97, w: 9, h: 0.35,
    fontSize: 11, color: C.mutedText, italic: true
  });

  // LEFT block — Parallel
  s.addShape(pres.shapes.RECTANGLE, {
    x: 0.25, y: 1.45, w: 4.55, h: 3.75,
    fill: { color: "0E2A1E" }, line: { color: C.parallel, pt: 2 }
  });
  s.addShape(pres.shapes.RECTANGLE, {
    x: 0.25, y: 1.45, w: 4.55, h: 0.44,
    fill: { color: C.parallel }, line: { color: C.parallel }
  });
  s.addText("PARALLEL / LONGITUDINAL", {
    x: 0.35, y: 1.45, w: 4.35, h: 0.44,
    fontSize: 11, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
  });

  const parallelItems = [
    ["Fiber orientation", "Parallel to line of action"],
    ["Sarcomere arrangement", "In series"],
    ["Functional advantage", "Greater velocity & range"],
    ["Key parameter", "Fiber length (FL)"],
    ["Shape subtypes", "Fusiform, Strap, Circular, Fan"],
    ["Best suited for", "Postural endurance & speed"],
  ];
  parallelItems.forEach(([k, v], i) => {
    s.addText(k + ":", { x: 0.4, y: 2.02 + i * 0.52, w: 2.0, h: 0.4, fontSize: 9.5, bold: true, color: C.parallel, margin: 0 });
    s.addText(v,       { x: 2.3, y: 2.02 + i * 0.52, w: 2.3, h: 0.4, fontSize: 9.5, color: C.lightText, margin: 0 });
  });

  // RIGHT block — Pennate
  s.addShape(pres.shapes.RECTANGLE, {
    x: 5.2, y: 1.45, w: 4.55, h: 3.75,
    fill: { color: "2A1108" }, line: { color: C.pennate, pt: 2 }
  });
  s.addShape(pres.shapes.RECTANGLE, {
    x: 5.2, y: 1.45, w: 4.55, h: 0.44,
    fill: { color: C.pennate }, line: { color: C.pennate }
  });
  s.addText("PENNATE", {
    x: 5.3, y: 1.45, w: 4.35, h: 0.44,
    fontSize: 11, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
  });

  const pennateItems = [
    ["Fiber orientation", "Oblique — at pennation angle (θ)"],
    ["Sarcomere arrangement", "In parallel"],
    ["Functional advantage", "Greater force production"],
    ["Key parameter", "PCSA (physiological CSA)"],
    ["Shape subtypes", "Uni-, Bi-, Multi-pennate"],
    ["Best suited for", "High-force, short contractions"],
  ];
  pennateItems.forEach(([k, v], i) => {
    s.addText(k + ":", { x: 5.35, y: 2.02 + i * 0.52, w: 2.0, h: 0.4, fontSize: 9.5, bold: true, color: C.pennate, margin: 0 });
    s.addText(v,       { x: 7.3,  y: 2.02 + i * 0.52, w: 2.3, h: 0.4, fontSize: 9.5, color: C.lightText, margin: 0 });
  });

  // Middle divider + "vs"
  s.addShape(pres.shapes.RECTANGLE, {
    x: 4.87, y: 1.5, w: 0.26, h: 3.65,
    fill: { color: C.divider }, line: { color: C.divider }
  });
  s.addShape(pres.shapes.ROUNDED_RECTANGLE, {
    x: 4.68, y: 3.1, w: 0.64, h: 0.44,
    fill: { color: C.accent }, line: { color: C.accent }, rectRadius: 0.05
  });
  s.addText("VS", {
    x: 4.68, y: 3.1, w: 0.64, h: 0.44,
    fontSize: 12, bold: true, color: C.darkText, align: "center", valign: "middle", margin: 0
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 4 — Parallel Architecture Subtypes
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, "0C1F14");
  topAccentBar(s, C.parallel);
  sectionLabel(s, "PARALLEL ARCHITECTURE — SUBTYPES", C.parallel);

  s.addText("Types of Parallel Muscle Architecture", {
    x: 0.5, y: 0.45, w: 9, h: 0.52,
    fontSize: 22, bold: true, color: C.white, margin: 0
  });

  const subtypes = [
    {
      name: "Fusiform",
      icon: "◆",
      desc: "Spindle-shaped with a wide fleshy belly tapering to tendons at both ends.",
      chars: "Fibers span full length | Parallel to force axis",
      examples: "Biceps brachii, brachialis, hamstrings",
      color: C.parallel
    },
    {
      name: "Strap",
      icon: "▬",
      desc: "Long, flat, ribbon-like muscle. Longest fiber lengths in the body.",
      chars: "Greatest excursion | Highest velocity",
      examples: "Sartorius (longest), gracilis, semitendinosus",
      color: "14B8A6"
    },
    {
      name: "Circular",
      icon: "○",
      desc: "Fibers arranged concentrically around an orifice. Contract to close opening.",
      chars: "Sphincteric action | Surrounds opening",
      examples: "Orbicularis oculi, orbicularis oris",
      color: "34D399"
    },
    {
      name: "Fan-shaped",
      icon: "◤",
      desc: "Broad origin converging to narrow tendon. Multiple pull directions possible.",
      chars: "Convergent | Selective fiber recruitment",
      examples: "Pectoralis major (5 subsegments)",
      color: "6EE7B7"
    },
    {
      name: "Strap + Intersections",
      icon: "≡",
      desc: "Parallel strap muscle divided into distinct bellies by tendinous bands.",
      chars: "Segmented contraction | Parallel bellies",
      examples: "Rectus abdominis (4 bellies)",
      color: "A7F3D0"
    },
  ];

  subtypes.forEach((sub, i) => {
    const x = 0.18 + i * 1.93;
    s.addShape(pres.shapes.RECTANGLE, {
      x, y: 1.1, w: 1.75, h: 4.1,
      fill: { color: "112B1D" }, line: { color: sub.color, pt: 1.5 }
    });
    // Color header
    s.addShape(pres.shapes.RECTANGLE, {
      x, y: 1.1, w: 1.75, h: 0.38,
      fill: { color: sub.color }, line: { color: sub.color }
    });
    s.addText(sub.name, {
      x, y: 1.1, w: 1.75, h: 0.38,
      fontSize: 10, bold: true, color: C.darkText,
      align: "center", valign: "middle", margin: 0
    });
    s.addText(sub.icon, {
      x, y: 1.56, w: 1.75, h: 0.5,
      fontSize: 28, color: sub.color, align: "center"
    });
    s.addText(sub.desc, {
      x: x + 0.08, y: 2.05, w: 1.6, h: 1.1,
      fontSize: 8.5, color: C.lightText
    });
    s.addShape(pres.shapes.RECTANGLE, {
      x: x + 0.08, y: 3.18, w: 1.6, h: 0.03,
      fill: { color: sub.color }, line: { color: sub.color }
    });
    s.addText(sub.chars, {
      x: x + 0.08, y: 3.24, w: 1.6, h: 0.55,
      fontSize: 7.5, color: C.mutedText, italic: true
    });
    s.addText("e.g. " + sub.examples, {
      x: x + 0.08, y: 3.82, w: 1.6, h: 0.68,
      fontSize: 8, color: sub.color, bold: true
    });
  });

  // Bottom note
  s.addText("⟳  Sarcomeres in series: favorable for high velocity and long excursion", {
    x: 0.3, y: 5.28, w: 9.4, h: 0.25,
    fontSize: 8.5, color: C.parallel, align: "center", bold: true
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 5 — Pennate Architecture Subtypes
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, "1F0D05");
  topAccentBar(s, C.pennate);
  sectionLabel(s, "PENNATE ARCHITECTURE — SUBTYPES", C.pennate);

  s.addText("Types of Pennate Muscle Architecture", {
    x: 0.5, y: 0.45, w: 9, h: 0.52,
    fontSize: 22, bold: true, color: C.white, margin: 0
  });
  s.addText("Penna (Latin) = feather  |  Fibers insert obliquely onto a central tendon at pennation angle θ", {
    x: 0.5, y: 0.94, w: 9, h: 0.3,
    fontSize: 10, color: C.mutedText, italic: true
  });

  const pennSubtypes = [
    {
      name: "Unipennate",
      symbol: "⟋",
      desc: "Fibers attach to one side of a central tendon only — like one half of a feather.",
      note: "FL < ML  |  Moderate PCSA",
      examples: "Vastus lateralis, flexor pollicis longus, tibialis posterior",
      color: C.pennate
    },
    {
      name: "Bipennate",
      symbol: "⟨⟩",
      desc: "Fibers attach to both sides of a central tendon — V-shaped pattern. Forces sum from both directions.",
      note: "Very high force  |  Short excursion",
      examples: "Gastrocnemius, rectus femoris, dorsal foot interossei",
      color: "F97316"
    },
    {
      name: "Multipennate",
      symbol: "⊞",
      desc: "Fibers oriented at multiple angles. Exceptionally large PCSA. Most complex internal architecture.",
      note: "Largest PCSA  |  Max force output",
      examples: "Soleus, deltoid, trapezius, gluteus medius",
      color: "FBBF24"
    },
    {
      name: "Circumpennate",
      symbol: "⊙",
      desc: "Fibers completely surround a central tendon on all sides — cylindrical pennation.",
      note: "Radial symmetry  |  Uniform force",
      examples: "Tibialis anterior",
      color: "FDE68A"
    },
  ];

  pennSubtypes.forEach((sub, i) => {
    const x = 0.2 + i * 2.4;
    s.addShape(pres.shapes.RECTANGLE, {
      x, y: 1.3, w: 2.22, h: 4.0,
      fill: { color: "2D1105" }, line: { color: sub.color, pt: 1.5 }
    });
    s.addShape(pres.shapes.RECTANGLE, {
      x, y: 1.3, w: 2.22, h: 0.4,
      fill: { color: sub.color }, line: { color: sub.color }
    });
    s.addText(sub.name, {
      x, y: 1.3, w: 2.22, h: 0.4,
      fontSize: 11, bold: true, color: C.darkBg,
      align: "center", valign: "middle", margin: 0
    });
    s.addText(sub.symbol, {
      x, y: 1.78, w: 2.22, h: 0.58,
      fontSize: 32, color: sub.color, align: "center"
    });
    s.addText(sub.desc, {
      x: x + 0.1, y: 2.4, w: 2.0, h: 1.1,
      fontSize: 9, color: C.lightText
    });
    s.addShape(pres.shapes.RECTANGLE, {
      x: x + 0.1, y: 3.52, w: 2.0, h: 0.03,
      fill: { color: sub.color }, line: { color: sub.color }
    });
    s.addText(sub.note, {
      x: x + 0.1, y: 3.58, w: 2.0, h: 0.45,
      fontSize: 8.5, color: sub.color, bold: true, italic: true
    });
    s.addText("e.g. " + sub.examples, {
      x: x + 0.1, y: 4.06, w: 2.0, h: 0.8,
      fontSize: 8, color: C.mutedText
    });
  });

  s.addText("⟳  Sarcomeres in parallel: forces ADD → higher force, shorter range", {
    x: 0.3, y: 5.28, w: 9.4, h: 0.25,
    fontSize: 8.5, color: C.pennate, align: "center", bold: true
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 6 — Textbook Architecture Diagram
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, C.darkBg);
  topAccentBar(s, C.accent);
  sectionLabel(s, "TEXTBOOK ILLUSTRATIONS", C.accent);

  s.addText("Muscle Architecture Types — Anatomical Imaging", {
    x: 0.5, y: 0.45, w: 9, h: 0.52,
    fontSize: 22, bold: true, color: C.white, margin: 0
  });

  // Main architecture image
  s.addImage({ data: imgArchTypes, x: 0.3, y: 1.05, w: 9.4, h: 3.0 });

  // Caption labels below
  const captions = [
    { label: "PARALLEL", sub: "Biceps brachii", x: 0.3, color: C.parallel },
    { label: "PARALLEL", sub: "Gluteus maximus", x: 1.85, color: C.parallel },
    { label: "UNIPENNATE", sub: "Vastus lateralis\n+ Sartorius (strap)", x: 3.4, color: C.pennate },
    { label: "MULTIPENNATE", sub: "Gluteus medius", x: 5.3, color: C.pennate },
    { label: "MULTIPENNATE", sub: "Deltoid", x: 7.0, color: C.pennate },
    { label: "BIPENNATE", sub: "Gastrocnemius\n+ Soleus (multi)", x: 8.45, color: C.pennate },
  ];
  captions.forEach(c => {
    s.addText(c.label, { x: c.x, y: 4.12, w: 1.5, h: 0.25, fontSize: 7, bold: true, color: c.color, align: "center", margin: 0 });
    s.addText(c.sub,   { x: c.x, y: 4.36, w: 1.5, h: 0.45, fontSize: 7, color: C.mutedText, align: "center", margin: 0 });
  });

  s.addText("FL = Fiber Length  |  ML = Muscle Length  |  ACSA = Anatomical Cross-Sectional Area", {
    x: 0.3, y: 5.28, w: 9.4, h: 0.22,
    fontSize: 7.5, color: C.mutedText, align: "center"
  });
  s.addText("Source: Imaging Anatomy Vol. 3, Bones, Joints, Vessels and Nerves", {
    x: 0.3, y: 5.44, w: 9.4, h: 0.2, fontSize: 7, color: C.divider, align: "center"
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 7 — Additional Architecture Diagram
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, C.darkBg);
  topAccentBar(s, C.accent);
  sectionLabel(s, "TEXTBOOK ILLUSTRATIONS — ADDITIONAL TYPES", C.accent);

  s.addText("Rectus Abdominis, Pectoralis Major & Bipennate Foot Muscles", {
    x: 0.4, y: 0.45, w: 9.2, h: 0.52,
    fontSize: 20, bold: true, color: C.white
  });

  s.addImage({ data: imgAdditional, x: 0.6, y: 1.08, w: 8.8, h: 3.7 });

  // Labels
  const labels3 = [
    { t: "Strap + Intersections", s: "Rectus abdominis\n(4 bellies)", x: 1.2, color: C.parallel },
    { t: "Fan-shaped", s: "Pectoralis major\n(5 subsegments, twisted tendon)", x: 4.1, color: C.parallel },
    { t: "Bi- & Unipennate", s: "Plantar foot muscles\nV-shape + half-feather", x: 7.2, color: C.pennate },
  ];
  labels3.forEach(l => {
    s.addText(l.t, { x: l.x, y: 4.86, w: 2.2, h: 0.28, fontSize: 8.5, bold: true, color: l.color, align: "center", margin: 0 });
    s.addText(l.s, { x: l.x, y: 5.14, w: 2.2, h: 0.45, fontSize: 7.5, color: C.mutedText, align: "center", margin: 0 });
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 8 — Biomechanics: PCSA, Fiber Length, Pennation Angle
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, C.midBg);
  topAccentBar(s, C.accent);
  sectionLabel(s, "BIOMECHANICS — KEY PARAMETERS");

  s.addText("The Physics of Architecture", {
    x: 0.5, y: 0.45, w: 9, h: 0.52,
    fontSize: 24, bold: true, color: C.white, margin: 0
  });

  // Three parameter boxes
  const params = [
    {
      title: "PCSA (Physiological CSA)",
      formula: "PCSA = Volume / Fiber Length",
      color: C.accent,
      points: [
        "Sum of ALL fiber cross-sections",
        "Best predictor of maximal force",
        "Larger in pennate muscles",
        "Soleus: modest mass, 4 cm fibers → huge PCSA",
        "Vastus lateralis: 50% more mass, 10 cm fibers → smaller PCSA",
        "Top 3 by PCSA: Soleus > Vastus lat. > Glut. medius",
      ]
    },
    {
      title: "Fiber Length & Velocity",
      formula: "Velocity ∝ Fiber Length",
      color: C.parallel,
      points: [
        "Longer fibers → greater shortening distance",
        "More sarcomeres in series = faster contraction",
        "Longest fibers: sartorius, gracilis, semitendinosus",
        "Parallel muscles maximize fiber length",
        "Pennate muscles sacrifice length for force",
        "Fiber length is key for excursion & speed",
      ]
    },
    {
      title: "Pennation Angle θ",
      formula: "Force = PCSA × cos(θ)",
      color: C.pennate,
      points: [
        "Angle between fiber and line of action",
        "Larger θ = more fibers packed in → more force",
        "But: effective force = F × cos(θ)",
        "Trade-off: packing vs. efficiency",
        "Typical θ = 0°–30° in most muscles",
        "Architecture altered by training, bed rest, DMD",
      ]
    },
  ];

  params.forEach((p, i) => {
    const x = 0.2 + i * 3.27;
    s.addShape(pres.shapes.RECTANGLE, {
      x, y: 1.15, w: 3.08, h: 4.15,
      fill: { color: "192435" }, line: { color: p.color, pt: 1.5 }
    });
    s.addShape(pres.shapes.RECTANGLE, {
      x, y: 1.15, w: 3.08, h: 0.46,
      fill: { color: p.color }, line: { color: p.color }
    });
    s.addText(p.title, {
      x: x + 0.08, y: 1.15, w: 2.92, h: 0.46,
      fontSize: 10, bold: true, color: C.darkBg,
      align: "center", valign: "middle", margin: 0
    });
    s.addText(p.formula, {
      x: x + 0.08, y: 1.68, w: 2.92, h: 0.36,
      fontSize: 11, bold: true, color: p.color, align: "center"
    });
    s.addShape(pres.shapes.RECTANGLE, {
      x: x + 0.08, y: 2.06, w: 2.92, h: 0.025,
      fill: { color: p.color }, line: { color: p.color }
    });
    p.points.forEach((pt, j) => {
      s.addText("• " + pt, {
        x: x + 0.12, y: 2.12 + j * 0.5, w: 2.84, h: 0.42,
        fontSize: 8.5, color: C.lightText, margin: 0
      });
    });
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 9 — Bar Chart: Force vs. Velocity trade-off
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, C.midBg);
  topAccentBar(s, C.accent);
  sectionLabel(s, "BIOMECHANICS — FORCE vs. VELOCITY TRADE-OFF");

  s.addText("Force vs. Velocity: Architecture Determines Function", {
    x: 0.5, y: 0.45, w: 9, h: 0.52,
    fontSize: 22, bold: true, color: C.white, margin: 0
  });

  // Chart — Relative Force
  s.addChart(pres.charts.BAR, [
    {
      name: "Relative Force (%)",
      labels: ["Soleus\n(multipennate)", "Gastrocnemius\n(bipennate)", "Vastus lat.\n(unipennate)", "Biceps\n(fusiform)", "Sartorius\n(strap)"],
      values: [100, 82, 75, 45, 28]
    }
  ], {
    x: 0.3, y: 1.1, w: 4.7, h: 3.8, barDir: "col",
    chartColors: [C.pennate, "F97316", "FBBF24", C.parallel, "34D399"],
    chartArea: { fill: { color: "192435" }, roundedCorners: false },
    catAxisLabelColor: C.mutedText, valAxisLabelColor: C.mutedText,
    valGridLine: { color: C.divider, size: 0.5 },
    catGridLine: { style: "none" },
    showValue: true, dataLabelColor: C.white, dataLabelFontSize: 9,
    catAxisLabelFontSize: 8, valAxisLabelFontSize: 8,
    showLegend: false,
    title: "Relative Force Output", titleColor: C.accent, titleFontSize: 10,
  });

  // Chart — Relative Velocity
  s.addChart(pres.charts.BAR, [
    {
      name: "Relative Velocity (%)",
      labels: ["Sartorius\n(strap)", "Biceps\n(fusiform)", "Semitendinosus\n(strap)", "Gastrocnemius\n(bipennate)", "Soleus\n(multipennate)"],
      values: [100, 85, 80, 42, 28]
    }
  ], {
    x: 5.2, y: 1.1, w: 4.5, h: 3.8, barDir: "col",
    chartColors: [C.parallel, "14B8A6", "34D399", "F97316", C.pennate],
    chartArea: { fill: { color: "192435" }, roundedCorners: false },
    catAxisLabelColor: C.mutedText, valAxisLabelColor: C.mutedText,
    valGridLine: { color: C.divider, size: 0.5 },
    catGridLine: { style: "none" },
    showValue: true, dataLabelColor: C.white, dataLabelFontSize: 9,
    catAxisLabelFontSize: 8, valAxisLabelFontSize: 8,
    showLegend: false,
    title: "Relative Shortening Velocity", titleColor: C.accent, titleFontSize: 10,
  });

  s.addText("← Pennate muscles dominate force  |  Parallel muscles dominate velocity →", {
    x: 0.3, y: 5.28, w: 9.4, h: 0.27,
    fontSize: 9, color: C.accent, align: "center", bold: true
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 10 — Head-to-Head Comparison Table
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, C.darkBg);
  topAccentBar(s);
  sectionLabel(s, "DIRECT COMPARISON");

  s.addText("Pennate vs. Parallel — Head-to-Head", {
    x: 0.5, y: 0.45, w: 9, h: 0.52,
    fontSize: 24, bold: true, color: C.white, margin: 0
  });

  // Table data
  const rows = [
    ["Parameter", "Parallel Architecture", "Pennate Architecture"],
    ["Fiber orientation",      "Parallel to force axis (0°)",           "Oblique to force axis (θ = 5°–30°)"],
    ["Sarcomere arrangement",  "In series",                              "In parallel"],
    ["Key metric",             "Fiber length (FL)",                      "Physiological CSA (PCSA)"],
    ["Force production",       "Moderate",                               "High to very high"],
    ["Shortening velocity",    "High",                                   "Low to moderate"],
    ["Excursion / Range",      "Large",                                  "Small"],
    ["No. of fibers",          "Fewer (limited by volume)",              "More (packed at angle)"],
    ["Fatigue resistance",     "Variable (depends on fiber type)",       "Variable (depends on fiber type)"],
    ["Best examples",          "Biceps, sartorius, orbicularis",         "Soleus, deltoid, gastrocnemius"],
    ["Injury pattern",         "Tears at myotendinous junction",         "More complex partial tears"],
    ["Rehab consideration",    "Focus on range & velocity",              "Focus on strength & PCSA"],
  ];

  rows.forEach((row, ri) => {
    const isHeader = ri === 0;
    const y = 1.1 + ri * 0.375;
    const h = isHeader ? 0.42 : 0.34;

    const colWidths = [2.4, 3.6, 3.6];
    const colX      = [0.2, 2.62, 6.24];

    row.forEach((cell, ci) => {
      const bg = isHeader
        ? (ci === 0 ? C.divider : ci === 1 ? C.parallel : C.pennate)
        : (ri % 2 === 0 ? "192435" : "1E2D3D");
      const textColor = isHeader ? C.white : (ci === 1 ? C.parallelLight : ci === 2 ? C.pennateLight : C.mutedText);

      s.addShape(pres.shapes.RECTANGLE, {
        x: colX[ci], y, w: colWidths[ci], h,
        fill: { color: bg }, line: { color: C.divider, pt: 0.5 }
      });
      s.addText(cell, {
        x: colX[ci] + 0.1, y, w: colWidths[ci] - 0.15, h,
        fontSize: isHeader ? 9.5 : 8.5,
        bold: isHeader || ci === 0,
        color: textColor,
        valign: "middle", margin: 0
      });
    });
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 11 — Connective Tissue & Structural Hierarchy
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, C.midBg);
  topAccentBar(s, C.parallel);
  sectionLabel(s, "STRUCTURAL HIERARCHY — CONNECTIVE TISSUE", C.parallel);

  s.addText("From Myofibril to Whole Muscle", {
    x: 0.5, y: 0.45, w: 6, h: 0.52,
    fontSize: 22, bold: true, color: C.white, margin: 0
  });

  // Connective tissue image
  s.addImage({ data: imgConnective, x: 0.25, y: 1.1, w: 5.5, h: 4.25 });

  // Hierarchy labels on right
  const levels = [
    { level: "Whole Muscle", wrap: "Epimysium", color: C.accent,   desc: "Dense CT sheath surrounding entire muscle" },
    { level: "Fascicle",     wrap: "Perimysium", color: C.parallel, desc: "Groups of ~10-100 muscle fibers" },
    { level: "Fiber (cell)", wrap: "Endomysium", color: "34D399",   desc: "Single multinucleated muscle cell (10-100 µm)" },
    { level: "Myofibril",    wrap: "—",          color: C.mutedText, desc: "Contractile unit of actin + myosin sarcomeres" },
  ];

  levels.forEach((l, i) => {
    const y = 1.15 + i * 1.08;
    s.addShape(pres.shapes.RECTANGLE, {
      x: 6.0, y, w: 3.75, h: 0.96,
      fill: { color: "192435" }, line: { color: l.color, pt: 1.5 }
    });
    s.addText(l.level, { x: 6.1, y: y + 0.05, w: 2.0, h: 0.32, fontSize: 11, bold: true, color: l.color, margin: 0 });
    s.addText("Wrapped by: " + l.wrap, { x: 6.1, y: y + 0.36, w: 3.5, h: 0.24, fontSize: 8.5, color: C.accent, italic: true, margin: 0 });
    s.addText(l.desc, { x: 6.1, y: y + 0.6, w: 3.5, h: 0.3, fontSize: 8, color: C.mutedText, margin: 0 });
  });

  s.addText("Architecture is determined at the fascicle level — how fascicles are oriented relative to the tendon defines parallel vs. pennate.", {
    x: 6.0, y: 5.22, w: 3.75, h: 0.37,
    fontSize: 7.5, color: C.mutedText, italic: true
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 12 — Muscle Fiber Types (Metabolic Classification)
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, C.darkBg);
  topAccentBar(s, "E879F9");
  sectionLabel(s, "FIBER METABOLIC TYPES", "E879F9");

  s.addText("Metabolic Classification of Muscle Fibers", {
    x: 0.5, y: 0.45, w: 9, h: 0.52,
    fontSize: 22, bold: true, color: C.white, margin: 0
  });

  const fiberTypes = [
    {
      type: "Type I",
      nick: "Slow-Twitch Oxidative",
      color: "DC2626",
      icon: "🔴",
      props: [
        ["Color", "Red (high myoglobin)"],
        ["Mitochondria", "Numerous"],
        ["Energy source", "Oxidative phosphorylation"],
        ["Glycogen", "Low"],
        ["Fatiguability", "Fatigue-resistant"],
        ["Contraction", "Slow"],
        ["Capillary density", "Dense"],
        ["Fiber diameter", "Thin"],
        ["Typical location", "Postural muscles (soleus)"],
      ]
    },
    {
      type: "Type II",
      nick: "Fast-Twitch Oxidative/Glycolytic",
      color: "D97706",
      icon: "🟠",
      props: [
        ["Color", "Red"],
        ["Mitochondria", "Many (more than Type I)"],
        ["Energy source", "Oxidative + Glycolytic"],
        ["Glycogen", "High"],
        ["Fatiguability", "Fatigue-resistant"],
        ["Contraction", "Fast"],
        ["Capillary density", "Dense"],
        ["Fiber diameter", "Large"],
        ["Typical location", "Mixed limb muscles"],
      ]
    },
    {
      type: "Type III",
      nick: "Fast-Twitch Glycolytic",
      color: "4B5563",
      icon: "⚪",
      props: [
        ["Color", "White (low myoglobin)"],
        ["Mitochondria", "Few"],
        ["Energy source", "Glycogen, phosphocreatine"],
        ["Glycogen", "High"],
        ["Fatiguability", "Easily fatigable"],
        ["Contraction", "Fast"],
        ["Capillary density", "Sparse"],
        ["Fiber diameter", "Variable"],
        ["Typical location", "Extremity muscles, rapid bursts"],
      ]
    },
  ];

  fiberTypes.forEach((ft, i) => {
    const x = 0.2 + i * 3.27;
    s.addShape(pres.shapes.RECTANGLE, {
      x, y: 1.1, w: 3.08, h: 4.2,
      fill: { color: "192435" }, line: { color: ft.color, pt: 2 }
    });
    s.addShape(pres.shapes.RECTANGLE, {
      x, y: 1.1, w: 3.08, h: 0.52,
      fill: { color: ft.color }, line: { color: ft.color }
    });
    s.addText(ft.type + " — " + ft.nick, {
      x: x + 0.1, y: 1.1, w: 2.88, h: 0.52,
      fontSize: 9.5, bold: true, color: C.white,
      valign: "middle", align: "center", margin: 0
    });
    ft.props.forEach(([k, v], j) => {
      const bg = j % 2 === 0 ? "1E2D3D" : "192435";
      s.addShape(pres.shapes.RECTANGLE, {
        x, y: 1.7 + j * 0.39, w: 3.08, h: 0.37,
        fill: { color: bg }, line: { color: bg }
      });
      s.addText(k, { x: x + 0.08, y: 1.7 + j * 0.39, w: 1.2, h: 0.37, fontSize: 8.5, bold: true, color: ft.color, valign: "middle", margin: 0 });
      s.addText(v, { x: x + 1.3,  y: 1.7 + j * 0.39, w: 1.7, h: 0.37, fontSize: 8.5, color: C.lightText, valign: "middle", margin: 0 });
    });
  });

  s.addText("Note: Pennate muscles often contain more Type I fibers (postural); parallel muscles more Type II/III (phasic movement)", {
    x: 0.3, y: 5.3, w: 9.4, h: 0.26,
    fontSize: 8.5, color: C.mutedText, italic: true, align: "center"
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 13 — Clinical Relevance
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, "0F1E2D");
  topAccentBar(s, "E879F9");
  sectionLabel(s, "CLINICAL RELEVANCE", "E879F9");

  s.addText("Why Architecture Matters Clinically", {
    x: 0.5, y: 0.45, w: 9, h: 0.52,
    fontSize: 22, bold: true, color: C.white, margin: 0
  });

  const clinCards = [
    {
      title: "Injury Patterns",
      color: "EF4444",
      icon: "⚡",
      body: [
        "Parallel muscles: tears typically at myotendinous junction where force concentration is highest",
        "Pennate muscles: partial intramuscular tears more common — complex architecture distributes stress",
        "Classic example: biceps (parallel) vs. gastrocnemius (bipennate) tears show different MRI patterns",
      ]
    },
    {
      title: "Rehabilitation",
      color: "3B82F6",
      icon: "🔄",
      body: [
        "Parallel muscle rehab: restore fiber length, excursion, and contraction velocity",
        "Pennate muscle rehab: rebuild PCSA and strength; hypertrophy increases force output",
        "Bed rest reduces pennation angle and PCSA; targeted loading reverses this",
        "Eccentric training increases fiber length in parallel muscles (hamstring injury prevention)",
      ]
    },
    {
      title: "Surgical Planning",
      color: C.parallel,
      icon: "✂",
      body: [
        "Flap design: pennate muscles (e.g. gracilis) preferred for free flaps — single pedicle, robust blood supply",
        "Tendon transfers: architecture determines expected force and range post-transfer",
        "Pennate muscles lose more function with partial denervation than parallel muscles",
        "DTI-based architecture mapping improves pre-operative planning",
      ]
    },
    {
      title: "Pathology & Genetics",
      color: C.pennate,
      icon: "🧬",
      body: [
        "Duchenne muscular dystrophy: architectural disorganization precedes fiber necrosis",
        "Infiltrative disease (lipoma, tumors): alters pennation angle detectable by ultrasound",
        "Architecture measurable by high-resolution ultrasound and MRI diffusion tensor imaging (DTI)",
        "Training induces architectural changes: pennation angle increases with hypertrophy",
      ]
    },
  ];

  clinCards.forEach((card, i) => {
    const col = i % 2;
    const row = Math.floor(i / 2);
    const x = 0.2 + col * 4.95;
    const y = 1.1 + row * 2.1;

    s.addShape(pres.shapes.RECTANGLE, {
      x, y, w: 4.7, h: 1.9,
      fill: { color: "162032" }, line: { color: card.color, pt: 1.5 }
    });
    s.addShape(pres.shapes.RECTANGLE, {
      x, y, w: 4.7, h: 0.38,
      fill: { color: card.color }, line: { color: card.color }
    });
    s.addText(card.icon + "  " + card.title, {
      x: x + 0.1, y, w: 4.5, h: 0.38,
      fontSize: 11, bold: true, color: C.white,
      valign: "middle", margin: 0
    });
    card.body.forEach((line, j) => {
      s.addText("• " + line, {
        x: x + 0.12, y: y + 0.42 + j * 0.36, w: 4.46, h: 0.34,
        fontSize: 8, color: C.lightText, margin: 0
      });
    });
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// SLIDE 14 — Summary / Key Takeaways
// ══════════════════════════════════════════════════════════════════════════════
{
  let s = pres.addSlide();
  darkBg(s, C.darkBg);
  topAccentBar(s, C.accent);

  // Bold title bar
  s.addShape(pres.shapes.RECTANGLE, {
    x: 0, y: 0, w: 10, h: 1.1,
    fill: { color: "192435" }, line: { color: "192435" }
  });
  s.addText("KEY TAKEAWAYS", {
    x: 0.5, y: 0.06, w: 9, h: 0.52,
    fontSize: 28, bold: true, color: C.accent, charSpacing: 4, align: "center"
  });
  s.addText("Pennate vs. Parallel Muscle Architecture", {
    x: 0.5, y: 0.58, w: 9, h: 0.38,
    fontSize: 14, color: C.mutedText, align: "center"
  });

  // Left column — Parallel
  s.addShape(pres.shapes.RECTANGLE, {
    x: 0.2, y: 1.18, w: 4.55, h: 4.1,
    fill: { color: "0E2A1E" }, line: { color: C.parallel, pt: 2 }
  });
  badge(s, "PARALLEL / LONGITUDINAL", 0.2, 1.18, 4.55, C.parallel, C.white);
  const parallelTakes = [
    "Fibers run parallel to force axis",
    "Sarcomeres in series → speed & range",
    "High velocity of shortening",
    "Large range of motion / excursion",
    "Key metric: fiber length (FL)",
    "Shapes: fusiform, strap, circular, fan",
    "Best examples: biceps, sartorius",
    "Dominant in limb phasic movement",
  ];
  parallelTakes.forEach((t, i) => {
    s.addText("✓  " + t, {
      x: 0.35, y: 1.62 + i * 0.44, w: 4.25, h: 0.38,
      fontSize: 9.5, color: C.lightText, margin: 0
    });
  });

  // Right column — Pennate
  s.addShape(pres.shapes.RECTANGLE, {
    x: 5.25, y: 1.18, w: 4.55, h: 4.1,
    fill: { color: "2A1108" }, line: { color: C.pennate, pt: 2 }
  });
  badge(s, "PENNATE", 5.25, 1.18, 4.55, C.pennate, C.white);
  const pennateTakes = [
    "Fibers oblique at pennation angle θ",
    "Sarcomeres in parallel → force",
    "High force production (large PCSA)",
    "Short range, high power output",
    "Key metric: PCSA (all fiber CSA summed)",
    "Subtypes: uni-, bi-, multipennate",
    "Best examples: soleus, deltoid",
    "Dominant in postural & power muscles",
  ];
  pennateTakes.forEach((t, i) => {
    s.addText("✓  " + t, {
      x: 5.4, y: 1.62 + i * 0.44, w: 4.25, h: 0.38,
      fontSize: 9.5, color: C.lightText, margin: 0
    });
  });

  // Central "vs"
  s.addShape(pres.shapes.ROUNDED_RECTANGLE, {
    x: 4.68, y: 3.0, w: 0.64, h: 0.5,
    fill: { color: C.accent }, line: { color: C.accent }, rectRadius: 0.05
  });
  s.addText("VS", {
    x: 4.68, y: 3.0, w: 0.64, h: 0.5,
    fontSize: 13, bold: true, color: C.darkText, align: "center", valign: "middle", margin: 0
  });

  // Bottom footer
  s.addShape(pres.shapes.RECTANGLE, {
    x: 0, y: 5.35, w: 10, h: 0.275,
    fill: { color: "192435" }, line: { color: "192435" }
  });
  s.addText("Most muscles combine both patterns, dominated by one. Architecture can be altered by training, injury, or disease.", {
    x: 0.3, y: 5.35, w: 9.4, h: 0.275,
    fontSize: 8.5, color: C.accent, align: "center", italic: true
  });
}

// ══════════════════════════════════════════════════════════════════════════════
// Write file
// ══════════════════════════════════════════════════════════════════════════════
pres.writeFile({ fileName: "/home/daytona/workspace/muscle-architecture-pptx/Pennate_vs_Parallel_Muscle_Architecture.pptx" })
  .then(() => console.log("SUCCESS"))
  .catch(e => { console.error("ERROR:", e); process.exit(1); });
Running Command

cd /home/daytona/workspace/muscle-architecture-pptx && node build.js 2>&1

Running Command

ls -lh /home/daytona/workspace/muscle-architecture-pptx/Pennate_vs_Parallel_Muscle_Architecture.pptx

Your presentation is ready (16 MB, generated successfully):

Pennate vs Parallel Muscle Architecture

Presentation · PPTX


Here is what's inside the 14-slide deck:
SlideContent
1Title slide - Bold split dark design (teal/orange palette) with key topics listed
2Agenda / Overview - 6 topic cards with numbered sections
3Structural Classification - Side-by-side parallel vs. pennate comparison blocks with 6 key properties each
4Parallel Architecture Subtypes - 5 column cards: Fusiform, Strap, Circular, Fan-shaped, Strap+Intersections
5Pennate Architecture Subtypes - 4 column cards: Unipennate, Bipennate, Multipennate, Circumpennate
6Textbook Anatomy Diagram - Full CT-based image of all architecture types (biceps, gluteus, vastus, deltoid, soleus, gastrocnemius) with labels
7Additional Diagrams - Rectus abdominis, pectoralis major fan, and bipennate foot muscles from imaging textbook
8Biomechanics - Three parameter boxes: PCSA formula, Fiber Length & Velocity, Pennation Angle θ
9Force vs. Velocity Charts - Two bar charts showing relative force and velocity rankings across muscle types
10Head-to-Head Table - 11-row comparison across fiber orientation, sarcomere arrangement, PCSA, force, velocity, excursion, injury pattern, rehab
11Connective Tissue Hierarchy - SEM/diagram image with 4-level hierarchy: epimysium → perimysium → endomysium → myofibril
12Metabolic Fiber Types - Type I / II / III comparison across 9 properties each
13Clinical Relevance - 4 cards: Injury Patterns, Rehabilitation, Surgical Planning, Pathology & Genetics
14Key Takeaways - Summary split panel with 8 bullet takeaways per architecture type
This is a shared conversation. Sign in to Orris to start your own chat.