';
return '
'+(d.pre||'')+'0'+d.suf+'
'+d.lab+'
';
}).join('');
var nums=box.querySelectorAll('.num[data-i]');
reveal('rC3',function(){
nums.forEach(function(n){
var d=data[+n.getAttribute('data-i')],t0=null,dur=1300;
function step(ts){if(!t0)t0=ts;var pr=Math.min((ts-t0)/dur,1);n.textContent=(d.pre||'')+Math.round(pr*d.v)+d.suf;if(pr<1)requestAnimationFrame(step);}
requestAnimationFrame(step);
});
});
})();
/* CHART 4: MARGIN BARS */
(function(){
var svg=root.querySelector('#r4svg'),tip=root.querySelector('#r4tip');
var W=640,H=350,xL=55,yB=280,yT=30;
var bars=[
{n:'Digital / knowledge',v:70,note:'
~70%+ margin. Courses, software, productized expertise. A million in revenue can leave ~$700K \u2014 the model the 3.6% tend to pick.'},
{n:'Consulting',v:52,note:'
~52% margin (high end). Selling expertise directly. High margin, but capped by your hours \u2014 unless you productize it.'},
{n:'Services (avg)',v:31,note:'
~31% margin. The sole-proprietor average. Solid, but you need to move real volume to reach seven figures solo.'},
{n:'Physical / e-comm',v:14,note:'
~14% margin (low end). A million in revenue can leave ~$140K before taxes \u2014 and a huge operational load for one person.'}
];
var n=bars.length,slotW=(600-xL)/n,maxV=78;
svg.appendChild(el('line',{x1:xL,y1:yB,x2:600,y2:yB,stroke:'rgba(255,255,255,.15)','stroke-width':1.5}));
[20,40,60].forEach(function(g){var y=yB-(yB-yT)*(g/maxV);svg.appendChild(el('line',{x1:xL,y1:y,x2:600,y2:y,stroke:'rgba(255,255,255,.06)','stroke-width':1}));svg.appendChild(el('text',{x:xL-6,y:y+4,fill:'#a9b6d6','font-size':9.5,'text-anchor':'end'})).textContent=g+'%';});
bars.forEach(function(b,i){
var x=xL+slotW*i+slotW*0.14,bw=slotW*0.62,fh=(yB-yT)*(b.v/maxV);
var col=['#f75008','#f7a008','#3fd08a','#5b8def'][i];
var bar=el('rect',{x:x,y:yB,width:bw,height:0,rx:6,fill:col,opacity:.92,style:'cursor:pointer'});svg.appendChild(bar);
var vl=el('text',{x:x+bw/2,y:yB,fill:'#fff','font-size':14,'font-weight':900,'text-anchor':'middle',opacity:0});vl.textContent='~'+b.v+'%';svg.appendChild(vl);
var words=b.n.split(' '),l1=words.slice(0,Math.ceil(words.length/2)).join(' '),l2=words.slice(Math.ceil(words.length/2)).join(' ');
var t1=el('text',{x:x+bw/2,y:yB+16,fill:'#a9b6d6','font-size':9.5,'text-anchor':'middle'});t1.textContent=l1;svg.appendChild(t1);
if(l2){var t2=el('text',{x:x+bw/2,y:yB+28,fill:'#a9b6d6','font-size':9.5,'text-anchor':'middle'});t2.textContent=l2;svg.appendChild(t2);}
function show(){tip.innerHTML=b.note;tip.style.left=((x+bw/2)/W*100)+'%';tip.style.top=((yB-fh-12)/H*100)+'%';tip.style.opacity=1;tip.style.whiteSpace='normal';tip.style.maxWidth='240px';}
bar.addEventListener('mouseenter',show);bar.addEventListener('mousemove',show);
bar.addEventListener('mouseleave',function(){tip.style.opacity=0;});
bar.addEventListener('touchstart',function(e){e.preventDefault();show();},{passive:false});
b._bar=bar;b._vl=vl;b._fh=fh;
});
svg.appendChild(el('text',{x:(xL+600)/2,y:yT-4,fill:'#a9b6d6','font-size':11,'font-weight':700,'text-anchor':'middle'})).textContent='Net margin \u2014 higher = less revenue needed for the same take-home';
reveal('rC4',function(){
bars.forEach(function(b,i){setTimeout(function(){
b._bar.style.transition='height .8s cubic-bezier(.2,.7,.2,1),y .8s cubic-bezier(.2,.7,.2,1)';
b._bar.setAttribute('height',b._fh);b._bar.setAttribute('y',yB-b._fh);
b._vl.style.transition='opacity .4s .3s';b._vl.setAttribute('y',yB-b._fh-8);b._vl.setAttribute('opacity',1);
},i*150);});
});
})();
/* CHART 5: THE FIVE WALLS — sequential path with rising walls */
(function(){
var svg=root.querySelector('#r5svg'),tip=root.querySelector('#r5tip');
var W=640,H=320,xL=40,yB=250;
var walls=[
{n:'Time',pct:'41%',h:0.5,note:'
Wall 1 \u2014 Time. 41% name time management their #1 challenge. You\u2019re every department, competing for the same hours.'},
{n:'Marketing',pct:'34%',h:0.62,note:'
Wall 2 \u2014 Marketing. 34% cite customer acquisition. Building it is easier than getting anyone to notice it.'},
{n:'Cash flow',pct:'29%',h:0.74,note:'
Wall 3 \u2014 Cash flow. 29% struggle here. Feast-and-famine income meets fixed monthly bills.'},
{n:'Isolation',pct:'\u2014',h:0.86,note:'
Wall 4 \u2014 Isolation. The quiet one. Never on a P&L, but working alone erodes judgment and motivation \u2014 and eventually the numbers.'},
{n:'Growth ceiling',pct:'',h:1.0,note:'
Wall 5 \u2014 The ceiling. One person runs out of hours. Plateau, automate, or bring in help \u2014 the fork the whole solo model bends toward.'}
];
var n=walls.length,gap=(W-xL-30)/n;
// ground line
svg.appendChild(el('line',{x1:xL,y1:yB,x2:W-20,y2:yB,stroke:'rgba(255,255,255,.15)','stroke-width':1.5}));
walls.forEach(function(w,i){
var x=xL+gap*i+gap*0.2,bw=gap*0.5,fh=(yB-40)*w.h;
var col=i===n-1?'#f75008':(i===3?'#f7a008':'#5b8def');
var bar=el('rect',{x:x,y:yB,width:bw,height:0,rx:4,fill:col,opacity:0,style:'cursor:pointer'});svg.appendChild(bar);
var num=el('text',{x:x+bw/2,y:yB-fh-8,fill:'#fff','font-size':13,'font-weight':900,'text-anchor':'middle',opacity:0});num.textContent=(i+1);svg.appendChild(num);
var nm=el('text',{x:x+bw/2,y:yB+16,fill:'#eaf0ff','font-size':10,'font-weight':700,'text-anchor':'middle'});nm.textContent=w.n;svg.appendChild(nm);
if(w.pct&&w.pct!=='\u2014'&&w.pct!==''){var pc=el('text',{x:x+bw/2,y:yB+28,fill:'#f7a008','font-size':9.5,'font-weight':800,'text-anchor':'middle'});pc.textContent=w.pct;svg.appendChild(pc);}
function show(){tip.innerHTML=w.note;tip.style.left=((x+bw/2)/W*100)+'%';tip.style.top=((yB-fh-14)/H*100)+'%';tip.style.opacity=1;tip.style.whiteSpace='normal';tip.style.maxWidth='230px';}
bar.addEventListener('mouseenter',show);bar.addEventListener('mousemove',show);
bar.addEventListener('mouseleave',function(){tip.style.opacity=0;});
bar.addEventListener('touchstart',function(e){e.preventDefault();show();},{passive:false});
w._bar=bar;w._num=num;w._fh=fh;
});
svg.appendChild(el('text',{x:xL,y:22,fill:'#a9b6d6','font-size':11,'font-weight':700})).textContent='The walls arrive in order \u2014 each taller than the last';
reveal('rC5',function(){
walls.forEach(function(w,i){setTimeout(function(){
w._bar.style.transition='height .7s cubic-bezier(.2,.7,.2,1),y .7s cubic-bezier(.2,.7,.2,1),opacity .4s';
w._bar.setAttribute('opacity',.92);w._bar.setAttribute('height',w._fh);w._bar.setAttribute('y',yB-w._fh);
w._num.style.transition='opacity .4s .3s';w._num.setAttribute('opacity',1);
},i*170);});
});
})();
/* CHART 6: FREEDOM-INCOME SPECTRUM */
(function(){
var svg=root.querySelector('#r6svg'),tip=root.querySelector('#r6tip'),note=root.querySelector('#r6note');
var W=640,H=300,y=140,xL=60,xR=580;
// gradient track
var defs=el('defs',{});var lg=el('linearGradient',{id:'r6grad',x1:'0',y1:'0',x2:'1',y2:'0'});
[['0','#3fd08a'],['0.5','#f7a008'],['1','#f75008']].forEach(function(s){lg.appendChild(el('stop',{offset:s[0],'stop-color':s[1]}));});
defs.appendChild(lg);svg.appendChild(defs);
svg.appendChild(el('line',{x1:xL,y1:y,x2:xR,y2:y,stroke:'url(#r6grad)','stroke-width':8,'stroke-linecap':'round',opacity:0,id:'r6track'}));
var track=svg.querySelector('#r6track');
var pts=[
{n:'Max freedom',sub:'~$25\u201350K \u00b7 low stress',note:'
Freedom end. Modest, steady income, total time control, low stress. The life 47% of solopreneurs explicitly say they want. Not a failure \u2014 a choice.'},
{n:'Balanced',sub:'~$100K \u00b7 sustainable',note:'
The middle. A real income with real autonomy. High-margin model + light automation. Sustainable for most temperaments.'},
{n:'Growth mode',sub:'$250K\u2013$1M \u00b7 high focus',note:'
Pushing up. Serious income, rising demands. Requires margin discipline, systems, and tolerance for cash-flow swings.'},
{n:'Max income',sub:'$1M+ \u00b7 the 3.6%',note:'
Income end. The seven-figure solo business. Real, but demands relentless focus and a high tolerance for isolation. You trade freedom for the number.'}
];
var n=pts.length;
function X(i){return xL+(xR-xL)*i/(n-1);}
pts.forEach(function(p,i){
var c=el('circle',{cx:X(i),cy:y,r:12,fill:'#0f1a3a',stroke:'#fff','stroke-width':2.5,style:'cursor:pointer',opacity:0});svg.appendChild(c);
var num=el('text',{x:X(i),y:y+4,fill:'#fff','font-size':11,'font-weight':900,'text-anchor':'middle',opacity:0,style:'pointer-events:none'});num.textContent=(i+1);svg.appendChild(num);
var lab=el('text',{x:X(i),y:i%2?y+40:y-28,fill:'#fff','font-size':11,'font-weight':800,'text-anchor':'middle',opacity:0});lab.textContent=p.n;svg.appendChild(lab);
var sub=el('text',{x:X(i),y:i%2?y+54:y-14,fill:'#a9b6d6','font-size':9.5,'text-anchor':'middle',opacity:0});sub.textContent=p.sub;svg.appendChild(sub);
function pick(){note.innerHTML=p.note;tip.style.opacity=0;}
[c,num,lab,sub].forEach(function(nn){nn.addEventListener('click',pick);nn.addEventListener('mouseenter',pick);
nn.addEventListener('touchstart',function(e){e.preventDefault();pick();},{passive:false});});
p._els=[c,num,lab,sub];
});
svg.appendChild(el('text',{x:xL,y:y-64,fill:'#3fd08a','font-size':11,'font-weight':800})).textContent='FREEDOM';
svg.appendChild(el('text',{x:xR,y:y-64,fill:'#f75008','font-size':11,'font-weight':800,'text-anchor':'end'})).textContent='INCOME';
reveal('rC6',function(){
track.style.transition='opacity .8s';track.setAttribute('opacity',1);
pts.forEach(function(p,i){setTimeout(function(){p._els.forEach(function(e){e.style.transition='opacity .5s';e.setAttribute('opacity',1);});},i*160);});
});
})();
/* RELATED + FAQ */
root.querySelector('#relatedGrid').innerHTML=[
{k:'Trending',t:'The Million-Dollar One-Person Business',d:'The full data story on the 117,060 solo firms that crossed $1M.',u:'https://lonelyentrepreneur.com/million-dollar-one-person-business/'},
{k:'How-to',t:'Million-Dollar Companies With One Employee',d:'The AI stack and mechanics that make a solo seven figures possible.',u:'https://lonelyentrepreneur.com/million-dollar-companies-with-one-employee/'},
{k:'Scale',t:'The Founder Bottleneck',d:'What happens when one person becomes the ceiling on growth.',u:'https://lonelyentrepreneur.com/founder-bottleneck-2026/'},
{k:'Leadership',t:'The Loneliness Epidemic at the Top',d:'The isolation wall \u2014 the one a spreadsheet can\u2019t solve.',u:'https://lonelyentrepreneur.com/leadership-loneliness-epidemic-2026/'}
].map(function(r){return '
'+r.k+''+r.t+'
'+r.d+'
';}).join('');
root.querySelector('#tFaq').innerHTML=[
['Can one person really make a million dollars?','Yes \u2014 in 2023 the U.S. Census counted 117,060 one-person businesses grossing $1 million or more. But it\u2019s rare: only about 3.6% of solopreneurs earn over $1M, the average earns $39,273, and reaching seven figures alone requires $83,333 in revenue every month. It\u2019s achievable, but it\u2019s the far tail of the distribution, not the norm.'],
['What does a solopreneur actually earn on average?','The average U.S. solopreneur earns $39,273 a year, and 36% make under $25,000 from their business. Notably, solopreneurs say they\u2019d need to earn about $219,000 to feel successful \u2014 a large gap between expectation and reality. Only 41% rely on the business as their primary income; for many, it\u2019s a flexibility-first choice rather than a wealth play.'],
['Is a one-person business worth it?','It depends what you\u2019re optimizing for. 77% are profitable in year one and startup costs are low, but 68% have under six months of savings, 48% have gone a month without income, and 35% report high stress \u2014 higher than owners with employees. It\u2019s worth it if you value autonomy and choose your model and runway carefully; it\u2019s painful if you chase a seven-figure number you don\u2019t truly want.'],
['What business model is best for a solo million?','High-margin, low-overhead models. Sole-proprietor margins average ~31% but range 14\u201352% by industry, while digital and knowledge products (courses, software, productized expertise) can exceed 70%. Higher margin means you need far less revenue for the same take-home \u2014 which is why model choice matters more than raw effort for reaching seven figures alone.'],
['Why do most one-person businesses stall?','They hit predictable walls in order: time management (41% call it their #1 challenge), marketing and customer acquisition (34%), cash flow (29%), isolation, and finally the growth ceiling where one person runs out of hours. Over 60% admit they underestimated running every function alone. Knowing the sequence \u2014 and building support for the isolation wall especially \u2014 is a genuine edge.']
].map(function(f){return '
'+f[0]+'
'+f[1]+'
';}).join('');
})();