/* Blog infographics — pure HTML/CSS visual explainers (no tables). Shared by blog posts.
   Usage: <figure class="ig"> … <figcaption>…</figcaption></figure> with one of the components below. */
.ig { margin: 2.2rem 0; padding: 1.4rem 1.3rem 1.1rem; border-radius: 16px; background: #f7f8fa; border: 1px solid #e6e8ec; }
.ig-title { margin: 0 0 1rem; font-size: 1.05rem; font-weight: 700; color: #111; display: flex; align-items: center; gap: .5rem; }
.ig-title::before { content: ""; width: 6px; height: 1.1em; border-radius: 3px; background: var(--ig-accent, #0f766e); }
.ig figcaption { margin-top: .9rem; font-size: .85rem; color: #6b7280; text-align: center; line-height: 1.6; }
.ig { --ig-accent: #0f766e; --ig-2: #2a78d6; --ig-3: #eb6834; --ig-4: #6250d6; --ig-bad: #c53030; --ig-good: #12924a; }

/* 1. steps / flow: numbered boxes joined by arrows (wraps; vertical on phones) */
.ig-steps { list-style: none; margin: 0; padding: 0; display: flex; gap: .9rem; flex-wrap: wrap; counter-reset: igs; }
.ig-steps li { position: relative; flex: 1 1 160px; background: #fff; border: 1px solid #e6e8ec; border-radius: 12px; padding: 2.1rem .9rem .9rem; counter-increment: igs; line-height: 1.6; font-size: .95rem; }
.ig-steps li::before { content: counter(igs); position: absolute; top: .65rem; left: .9rem; width: 1.55rem; height: 1.55rem; border-radius: 50%; background: var(--ig-accent); color: #fff; font-size: .82rem; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.ig-steps li strong { display: block; color: #111; margin-bottom: .2rem; }
.ig-steps li:not(:last-child)::after { content: "→"; position: absolute; right: -.78rem; top: 50%; transform: translateY(-50%); color: #9aa1ab; font-weight: 700; z-index: 1; }

/* 2. cycle: items around a loop (a vicious or virtuous circle) */
.ig-cycle { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .8rem; position: relative; }
.ig-cycle > div { background: #fff; border: 1px solid #e6e8ec; border-radius: 999px; padding: .75rem 1rem; text-align: center; font-size: .93rem; line-height: 1.5; position: relative; }
.ig-cycle > div b { color: var(--ig-accent); }
.ig-cycle-note { grid-column: 1 / -1; text-align: center; font-size: .88rem; color: #6b7280; }
.ig-cycle-note::before { content: "↻ "; color: var(--ig-accent); font-weight: 700; }

/* 3. compare: two cards side by side (stacks on phones) — NOT a table */
.ig-compare { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.ig-side { background: #fff; border-radius: 14px; padding: 1rem 1.05rem; border: 1px solid #e6e8ec; border-top: 4px solid var(--ig-2); }
.ig-side.is-b { border-top-color: var(--ig-3); }
.ig-side h4 { margin: 0 0 .6rem; font-size: 1rem; color: #111; }
.ig-side ul { margin: 0; padding-left: 1.1rem; line-height: 1.75; font-size: .94rem; }
.ig-side ul li::marker { color: var(--ig-2); }
.ig-side.is-b ul li::marker { color: var(--ig-3); }

/* 4. cards: key points / pillars in a grid, each with an emoji or short icon */
.ig-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: .85rem; }
.ig-card { background: #fff; border: 1px solid #e6e8ec; border-radius: 14px; padding: 1rem; line-height: 1.6; font-size: .94rem; }
.ig-card .ig-ico { font-size: 1.6rem; line-height: 1; display: block; margin-bottom: .45rem; }
.ig-card strong { display: block; color: #111; margin-bottom: .2rem; }

/* 5. meter: horizontal bars for a qualitative scale (use words, not invented numbers) */
.ig-meter { display: flex; flex-direction: column; gap: .7rem; }
.ig-meter-row { display: grid; grid-template-columns: minmax(110px, 34%) 1fr; gap: .8rem; align-items: center; font-size: .93rem; }
.ig-meter-track { height: 14px; border-radius: 999px; background: #e9ecf0; overflow: hidden; }
.ig-meter-fill { display: block; height: 100%; border-radius: 999px; background: var(--ig-accent); }
.ig-meter-fill.is-2 { background: var(--ig-2); } .ig-meter-fill.is-3 { background: var(--ig-3); } .ig-meter-fill.is-bad { background: var(--ig-bad); }

/* 6. timeline: events in order */
.ig-timeline { list-style: none; margin: 0; padding: 0 0 0 1.4rem; border-left: 3px solid #dfe3e8; }
.ig-timeline li { position: relative; margin: 0 0 1rem; padding-left: .4rem; line-height: 1.65; font-size: .95rem; }
.ig-timeline li::before { content: ""; position: absolute; left: -1.95rem; top: .35rem; width: .9rem; height: .9rem; border-radius: 50%; background: #fff; border: 3px solid var(--ig-accent); }
.ig-timeline li b { display: block; color: #111; }

/* 7. quote highlight */
.ig-quote { margin: 2rem 0; padding: 1.2rem 1.4rem; border-left: 5px solid var(--ig-accent, #0f766e); background: #f0faf8; border-radius: 0 14px 14px 0; font-size: 1.1rem; line-height: 1.8; color: #1f2937; }
.ig-quote cite { display: block; margin-top: .5rem; font-size: .88rem; color: #6b7280; font-style: normal; }

@media (max-width: 640px) {
    .ig { padding: 1.1rem .9rem .9rem; }
    .ig-compare { grid-template-columns: 1fr; }
    .ig-steps { flex-direction: column; }
    .ig-steps li:not(:last-child)::after { content: "↓"; right: auto; left: 50%; top: auto; bottom: -1.05rem; transform: translateX(-50%); }
    .ig-meter-row { grid-template-columns: 1fr; gap: .3rem; }
}
@media (prefers-color-scheme: dark) {
    html.dark .ig, body.dark-mode .ig { background: #15171c; border-color: #262a31; }
}

/* 8. table — clean, readable, scrolls sideways on phones */
.ig-table-wrap { overflow-x: auto; border-radius: 12px; border: 1px solid #e6e8ec; background: #fff; }
.ig-table { width: 100%; border-collapse: collapse; font-size: .94rem; line-height: 1.6; min-width: 480px; }
.ig-table th { background: #0f766e; color: #fff; text-align: left; padding: .7rem .85rem; font-weight: 700; font-size: .9rem; }
.ig-table td { padding: .65rem .85rem; border-top: 1px solid #edf0f3; vertical-align: top; }
.ig-table tbody tr:nth-child(even) td { background: #f8fafb; }
.ig-table td:first-child { font-weight: 600; color: #111; }

/* 9. chart / graph — inline SVG with a legend; .ig-concept marks illustrative (not measured) charts */
.ig-chart svg, .ig-diagram svg { width: 100%; height: auto; display: block; }
.ig-chart svg text, .ig-diagram svg text { font-family: 'Anek Bangla', 'Segoe UI', sans-serif; }
.ig-legend { display: flex; flex-wrap: wrap; gap: .5rem 1.1rem; justify-content: center; margin-top: .7rem; font-size: .86rem; color: #4b5563; }
.ig-legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: .35rem; vertical-align: -1px; }
.ig-concept { display: inline-block; margin-left: .4rem; padding: .05rem .5rem; border-radius: 999px; background: #eef2ff; color: #4338ca; font-size: .72rem; font-weight: 600; vertical-align: middle; }

/* 10. big pull quote */
.ig-quote.is-big { font-size: 1.3rem; text-align: center; border-left: 0; border-top: 4px solid var(--ig-accent, #0f766e); border-radius: 0 0 14px 14px; padding: 1.5rem 1.4rem; }
.ig-quote.is-big::before { content: "“"; display: block; font-size: 3rem; line-height: .6; color: var(--ig-accent, #0f766e); margin-bottom: .4rem; }

/* phones: keep chart/diagram labels readable — the figure scrolls sideways instead of shrinking the text */
@media (max-width: 640px) {
    .ig-chart, .ig-diagram { overflow-x: auto; -webkit-overflow-scrolling: touch; }
    .ig-chart svg, .ig-diagram svg { min-width: 540px; }
    .ig-chart .ig-title, .ig-diagram .ig-title, .ig-chart figcaption, .ig-diagram figcaption, .ig-chart .ig-legend { position: sticky; left: 0; max-width: calc(100vw - 4rem); }
}

/* 11. grid tables: full row AND column lines (owner's request) */
.ig-table { border: 1px solid #cfd6de; }
.ig-table th, .ig-table td { border: 1px solid #cfd6de; }
.ig-table th { border-color: #0b5f58; }
.ig-table .ig-num { width: 3.2rem; text-align: center; font-weight: 700; color: #0f766e; }
.ig-table th.ig-num { color: #fff; }
.ig-table .ig-ico-sm { font-size: 1.1rem; }
.ig-rate { display: block; font-weight: 600; color: #111; margin-bottom: .3rem; }
.ig-mini { display: block; height: 8px; border-radius: 999px; background: #e9ecf0; overflow: hidden; }
.ig-mini span { display: block; height: 100%; border-radius: 999px; background: #2a78d6; }
.ig-mini span.is-b { background: #eb6834; }

/* 12. Bangla numerals in numbered steps and lists */
.ig-steps li::before { content: counter(igs, bengali); }
article ol { list-style-type: bengali; }
