/* Source-grounded diagrams use native text and respond to their reading column. */
.bahigo-visual{--bv-forest:var(--forest,#102a2d);--bv-green:var(--emerald,#126b5a);--bv-citron:var(--citron,#d6ff62);--bv-paper:var(--ivory,#f4f3ed);--bv-line:var(--line,#d4ddd5);--bv-muted:#52665c;container-type:inline-size;margin:36px 0 40px;padding:28px;background:#f9fbf5;border:1px solid var(--bv-line);border-radius:3px;color:var(--bv-forest);font-family:var(--sans,'Segoe UI',Arial,sans-serif);font-size:16px;line-height:1.65;min-width:0;max-width:100%;isolation:isolate}
.bahigo-visual *{box-sizing:border-box}.bahigo-visual .bv-heading{display:grid;grid-template-columns:35px minmax(0,1fr);align-items:start;gap:16px;margin-bottom:27px}.bahigo-visual .bv-heading>div{min-width:0}.bahigo-visual .bv-kind-mark{display:grid;place-items:center;width:35px;height:35px;border:1px solid #a4beb0;background:#e7efe2;border-radius:50%;color:var(--bv-green);font:23px/1 var(--sans,'Segoe UI',Arial,sans-serif)}
.bahigo-visual .bv-title{font-family:var(--serif,Georgia,'Times New Roman',serif);font-size:clamp(24px,3.3cqi,30px);font-weight:400;line-height:1.22;letter-spacing:-.025em;margin:0;color:var(--bv-forest);hyphens:auto;overflow-wrap:break-word;text-wrap:balance}.bahigo-visual .bv-subtitle{font-size:16px;line-height:1.65;font-weight:400;color:var(--bv-muted);margin:12px 0 0;max-width:70ch;hyphens:auto;overflow-wrap:break-word}
.bahigo-visual .bv-label{font-family:var(--sans,'Segoe UI',Arial,sans-serif);font-size:16px;line-height:1.5;font-weight:650;letter-spacing:0;color:var(--bv-green);margin:0 0 10px;hyphens:auto;overflow-wrap:break-word}.bahigo-visual .bv-value{font-family:var(--serif,Georgia,'Times New Roman',serif);font-size:clamp(22px,3.1cqi,28px);font-weight:400;line-height:1.24;letter-spacing:-.025em;color:var(--bv-forest);margin:0 0 12px;max-width:none;hyphens:auto;overflow-wrap:anywhere}.bahigo-visual .bv-note{font-size:16px;font-weight:400;line-height:1.7;color:var(--bv-muted);margin:0;max-width:65ch;hyphens:auto;overflow-wrap:break-word}.bahigo-visual .bv-caption{font-family:var(--sans,'Segoe UI',Arial,sans-serif);font-size:16px;line-height:1.65;color:var(--bv-muted);border-top:1px solid var(--bv-line);padding:16px 0 0;margin:24px 0 0}

/* A process is an ordered path: vertical in a narrow column, horizontal when roomy. */
.bahigo-visual .bv-process{display:grid;grid-template-columns:minmax(0,1fr);list-style:none;padding:0;margin:0;gap:27px;counter-reset:none}.bahigo-visual .bv-process-item{position:relative;display:grid;grid-template-columns:40px minmax(0,1fr);align-items:start;gap:17px;min-width:0;margin:0;padding:0}.bahigo-visual .bv-step-marker{position:relative;align-self:stretch;min-width:0;min-height:40px}.bahigo-visual .bv-step-number{display:grid;place-items:center;width:40px;height:40px;border:1px solid var(--bv-green);background:var(--bv-paper);color:var(--bv-green);border-radius:50%;font-size:16px;font-weight:600;line-height:1}.bahigo-visual .bv-step-connector{position:absolute;left:20px;top:48px;bottom:-19px;display:block;border-left:1px solid #9ab5a5}.bahigo-visual .bv-step-connector::after{content:'';position:absolute;bottom:-1px;left:-3px;width:6px;height:6px;border-right:1px solid #71927e;border-bottom:1px solid #71927e;transform:rotate(45deg)}.bahigo-visual .bv-process-item:last-child .bv-step-connector{display:none}.bahigo-visual .bv-step-copy{min-width:0;padding-top:2px}.bahigo-visual .bv-step-copy .bv-label{margin-bottom:9px}

/* A decision keeps the observed condition and its limited conclusion together. */
.bahigo-visual--decision{background:#f4f7ef}.bahigo-visual--decision .bv-kind-mark{border-radius:3px;transform:rotate(45deg);font-size:0;background:var(--bv-forest);border-color:var(--bv-forest);width:23px;height:23px;margin:6px}.bahigo-visual--decision .bv-heading{margin-bottom:6px}.bahigo-visual .bv-decision-root{height:25px;position:relative;padding-left:17px}.bahigo-visual .bv-decision-root>span{display:block;width:1px;height:100%;background:#9ab5a5}.bahigo-visual .bv-decision-branches{list-style:none;margin:0 0 0 17px;padding:0 0 0 22px;border-left:1px solid #9ab5a5;display:grid;gap:18px}.bahigo-visual .bv-decision-branch{position:relative;display:grid;grid-template-columns:minmax(0,1fr);gap:12px;border:1px solid #c4d3c4;background:#fbfcf7;margin:0;padding:20px;min-width:0}.bahigo-visual .bv-decision-branch::before{content:'';position:absolute;left:-23px;top:30px;width:22px;border-top:1px solid #9ab5a5}.bahigo-visual .bv-branch-condition{min-width:0;position:relative;padding-left:20px}.bahigo-visual .bv-branch-point{position:absolute;left:0;top:8px;display:block;width:8px;height:8px;background:var(--bv-green);transform:rotate(45deg)}.bahigo-visual .bv-branch-condition .bv-label{margin:0}.bahigo-visual .bv-branch-outcome{min-width:0}.bahigo-visual .bv-branch-outcome .bv-value{font-family:var(--sans,'Segoe UI',Arial,sans-serif);font-size:21px;font-weight:650;letter-spacing:-.025em;line-height:1.4;margin-bottom:9px}.bahigo-visual .bv-decision-branch:last-child::after{content:'';position:absolute;left:-24px;top:31px;bottom:-2px;border-left:3px solid #f4f7ef}

/* Comparisons are paired fields, with an unboxed third scope below the pair. */
.bahigo-visual .bv-comparison{display:grid;grid-template-columns:minmax(0,1fr);margin:0;padding:0;border:1px solid #bccfbe;gap:0}.bahigo-visual .bv-comparison-panel{min-width:0;padding:23px;background:#fcfdf9;border-bottom:1px solid #bccfbe}.bahigo-visual .bv-comparison-panel:nth-child(even){background:#e4eddf}.bahigo-visual .bv-comparison-panel:last-child{border-bottom:0}.bahigo-visual .bv-comparison-content{margin:0;min-width:0}.bahigo-visual .bv-comparison .bv-label{border-bottom:1px solid #b9ccba;padding-bottom:13px;margin-bottom:19px}.bahigo-visual .bv-comparison .bv-value{font-size:clamp(24px,3.5cqi,32px);margin-bottom:14px}.bahigo-visual[data-panel-count='3'] .bv-comparison-panel:last-child{background:transparent}

/* Calculations distinguish the literal expression from its emphasized answer. */
.bahigo-visual--calculation{background:#edf2e8;border-top:3px solid var(--bv-forest)}.bahigo-visual--calculation .bv-kind-mark{background:var(--bv-forest);border-color:var(--bv-forest);color:var(--bv-citron);font-size:24px}.bahigo-visual .bv-calculation{list-style:none;margin:0;padding:0;display:grid;gap:0;border-top:1px solid #b7cbb9}.bahigo-visual .bv-calculation-item{display:grid;grid-template-columns:27px minmax(0,1fr);gap:14px;border-bottom:1px solid #b7cbb9;margin:0;padding:23px 0;min-width:0}.bahigo-visual .bv-calculation-index{font-family:var(--sans,'Segoe UI',Arial,sans-serif);font-size:16px;font-weight:500;color:#637d69;line-height:1.5;padding-top:1px}.bahigo-visual .bv-calculation-copy{min-width:0}.bahigo-visual .bv-calculation-item .bv-label{margin-bottom:11px;font-weight:550}.bahigo-visual .bv-equation{display:flex;align-items:baseline;flex-wrap:wrap;gap:4px 14px;max-width:none;font-family:var(--sans,'Segoe UI',Arial,sans-serif);font-size:21px;line-height:1.4;color:var(--bv-forest);margin:0 0 14px;min-width:0;overflow-wrap:anywhere;hyphens:auto}.bahigo-visual .bv-equation-expression{font-size:20px;font-weight:400;line-height:1.5;min-width:0;max-width:100%}.bahigo-visual .bv-equals{white-space:pre-wrap}.bahigo-visual .bv-equation-answer{font-family:var(--serif,Georgia,'Times New Roman',serif);font-size:clamp(29px,4.2cqi,39px);font-weight:400;line-height:1.2;letter-spacing:-.025em;min-width:0;max-width:100%;overflow-wrap:anywhere}.bahigo-visual .bv-equation-answer--plain{font-size:clamp(25px,3.5cqi,32px)}.bahigo-visual .bv-calculation-item--explanation{background:#e0eada;margin:0 -13px;padding-inline:13px}.bahigo-visual .bv-calculation-item--explanation .bv-equation-answer{font-family:var(--sans,'Segoe UI',Arial,sans-serif);font-size:21px;font-weight:600;line-height:1.5;letter-spacing:-.015em}

@container(min-width:520px){.bahigo-visual .bv-comparison{grid-template-columns:repeat(2,minmax(0,1fr))}.bahigo-visual .bv-comparison-panel{border-bottom:0}.bahigo-visual .bv-comparison-panel:nth-child(odd){border-right:1px solid #bccfbe}.bahigo-visual .bv-comparison-panel:nth-child(n+3){border-top:1px solid #bccfbe}.bahigo-visual[data-panel-count='3'] .bv-comparison-panel:last-child{grid-column:1/-1;border-right:0;display:grid;grid-template-columns:minmax(0,.75fr) minmax(0,1.25fr);gap:22px}.bahigo-visual[data-panel-count='3'] .bv-comparison-panel:last-child .bv-label{border-bottom:0;padding:0;margin:0}.bahigo-visual[data-panel-count='3'] .bv-comparison-panel:last-child .bv-value{font-family:var(--sans,'Segoe UI',Arial,sans-serif);font-size:21px;font-weight:600;line-height:1.4;letter-spacing:-.015em}.bahigo-visual .bv-decision-branch{grid-template-columns:minmax(0,.72fr) minmax(0,1.28fr);gap:22px}.bahigo-visual .bv-branch-condition{padding-top:2px}}
@container(min-width:640px){.bahigo-visual .bv-process{grid-template-columns:repeat(var(--visual-panel-count),minmax(0,1fr));gap:22px}.bahigo-visual .bv-process-item{display:block}.bahigo-visual .bv-step-marker{height:40px;margin-bottom:24px}.bahigo-visual .bv-step-connector{top:20px;bottom:auto;left:49px;right:-12px;height:1px;border-left:0;border-top:1px solid #9ab5a5}.bahigo-visual .bv-step-connector::after{bottom:auto;left:auto;top:-3px;right:0;transform:rotate(-45deg)}.bahigo-visual .bv-step-copy{padding:0}.bahigo-visual .bv-step-copy .bv-value{font-size:24px}.bahigo-visual .bv-step-copy .bv-label{min-height:48px}}
@media(max-width:560px){.bahigo-visual{padding:22px 18px;margin:29px 0 32px}.bahigo-visual .bv-heading{grid-template-columns:28px minmax(0,1fr);gap:12px;margin-bottom:24px}.bahigo-visual .bv-kind-mark{width:28px;height:28px;font-size:21px}.bahigo-visual .bv-title{font-size:25px;line-height:1.25;letter-spacing:-.025em}.bahigo-visual .bv-subtitle{font-size:16px;line-height:1.7;margin-top:13px}.bahigo-visual .bv-note,.bahigo-visual .bv-label,.bahigo-visual .bv-caption{font-size:16px;line-height:1.7}.bahigo-visual .bv-process-item{grid-template-columns:34px minmax(0,1fr);gap:13px}.bahigo-visual .bv-step-number{width:34px;height:34px;font-size:16px}.bahigo-visual .bv-step-connector{left:17px;top:42px}.bahigo-visual .bv-step-copy .bv-value{font-size:23px}.bahigo-visual .bv-step-copy{padding:0}.bahigo-visual--decision .bv-kind-mark{width:19px;height:19px;margin:4px;font-size:0}.bahigo-visual--decision .bv-heading{margin-bottom:5px}.bahigo-visual .bv-decision-root{padding-left:13px}.bahigo-visual .bv-decision-branches{margin-left:13px;padding-left:16px;gap:16px}.bahigo-visual .bv-decision-branch{padding:17px 15px;gap:11px}.bahigo-visual .bv-decision-branch::before{left:-17px;width:16px;top:29px}.bahigo-visual .bv-decision-branch:last-child::after{left:-18px;top:30px}.bahigo-visual .bv-branch-outcome .bv-value{font-size:21px;line-height:1.45}.bahigo-visual .bv-branch-condition{padding-left:17px}.bahigo-visual .bv-branch-point{width:6px;height:6px;top:10px}.bahigo-visual .bv-comparison-panel{padding:21px 18px}.bahigo-visual .bv-comparison .bv-value{font-size:25px}.bahigo-visual .bv-calculation-item{grid-template-columns:22px minmax(0,1fr);gap:11px;padding-block:22px}.bahigo-visual .bv-calculation-index{font-size:16px}.bahigo-visual .bv-equation{gap:5px 10px}.bahigo-visual .bv-equation-expression{font-size:20px}.bahigo-visual .bv-equation-answer{font-size:30px;line-height:1.25}.bahigo-visual .bv-equation-answer--plain{font-size:25px;line-height:1.35}.bahigo-visual .bv-caption{padding-top:16px;margin-top:23px}}
@media(max-width:360px){.bahigo-visual{padding:20px 15px}.bahigo-visual .bv-heading{display:block}.bahigo-visual .bv-kind-mark{margin-bottom:15px}.bahigo-visual .bv-title{font-size:24px}.bahigo-visual .bv-process-item{grid-template-columns:30px minmax(0,1fr);gap:12px}.bahigo-visual .bv-step-number{width:30px;height:30px}.bahigo-visual .bv-step-connector{left:15px;top:38px}.bahigo-visual .bv-step-copy .bv-value{font-size:22px}.bahigo-visual .bv-decision-branch{padding-inline:13px}.bahigo-visual .bv-calculation-item{grid-template-columns:minmax(0,1fr);gap:8px}.bahigo-visual .bv-calculation-index{font-size:16px;line-height:1.3}.bahigo-visual .bv-equation-answer{font-size:28px}.bahigo-visual .bv-equation-answer--plain{font-size:25px}.bahigo-visual .bv-comparison-panel{padding-inline:16px}}

/* Panel count stays in CSS to respect the strict local preview CSP. */
.bahigo-visual[data-panel-count='3']{--visual-panel-count:3}
.bahigo-visual[data-panel-count='4']{--visual-panel-count:4}

/* V5 internal figures keep their four layouts and adopt the Arctic palette. */
.guide-page .bahigo-visual{--bv-forest:#061014;--bv-green:#006b75;--bv-citron:#00eff2;--bv-paper:#fff;--bv-line:#c5d8dc;--bv-muted:#4e6870;background:#f4fafb}
.guide-page .bahigo-visual .bv-kind-mark{background:#e6f2f5;border-color:#8aafb8}
.guide-page .bahigo-visual .bv-step-connector,.guide-page .bahigo-visual .bv-step-connector::after{border-color:#64838c}
.guide-page .bahigo-visual--decision{background:#f0f7f9}
.guide-page .bahigo-visual--decision .bv-kind-mark{background:#061014;border-color:#061014}
.guide-page .bahigo-visual .bv-decision-root>span{background:#64838c}
.guide-page .bahigo-visual .bv-decision-branches{border-left-color:#64838c}
.guide-page .bahigo-visual .bv-decision-branch{border-color:#b3cdd3;background:#fcfefe}
.guide-page .bahigo-visual .bv-decision-branch::before{border-top-color:#64838c}
.guide-page .bahigo-visual .bv-decision-branch:last-child::after{border-left-color:#f0f7f9}
.guide-page .bahigo-visual .bv-comparison,.guide-page .bahigo-visual .bv-comparison-panel{border-color:#bdd2d8}
.guide-page .bahigo-visual .bv-comparison-panel{background:#fff}
.guide-page .bahigo-visual .bv-comparison-panel:nth-child(even){background:#e1f3f6}
.guide-page .bahigo-visual[data-panel-count='3'] .bv-comparison-panel:last-child{background:transparent}
.guide-page .bahigo-visual .bv-comparison .bv-label{border-bottom-color:#b6d0d6}
.guide-page .bahigo-visual--calculation{background:#eaf5f7}
.guide-page .bahigo-visual--calculation .bv-kind-mark{background:#061014;border-color:#061014;color:#00eff2}
.guide-page .bahigo-visual .bv-calculation,.guide-page .bahigo-visual .bv-calculation-item{border-color:#b3cdd3}
.guide-page .bahigo-visual .bv-calculation-index{color:#4e6870}
.guide-page .bahigo-visual .bv-calculation-item--explanation{background:#dceef2}
