${tr('Each channel is a pair of optics, one per end. ZR+ optics plug straight into your routers. Transponders sit on a shelf.')}
`; for(const k of Object.keys(OPT)){const O=OPT[k],n=(l.ch||[]).filter(x=>x===k).length,why=chWhy(l,k); const md=optMode(k,l),cc=chCost(l,k),sp=spareN(k); - h+=`${tr('Unplugged optics go on the spares shelf and are used first next time.')}
`;if(st.length)h+=`${tr('Congested. Upgrade it or add a parallel path.')}
`:''} -${mates.length?trn('Shares a trench with {n} other link. One cut takes them all down.','Shares a trench with {n} other links. One cut takes them all down.',mates.length):sib.length?tr('Runs on its own route. A cut here leaves the other links up.'):tr('This is the only link between these cities. Add a parallel one, or a path through another city.')}
${sib.map(x=>`${tr('Waves are leased at a flat monthly rate. Bigger and longer costs more, and subsea is 1.8×. First month is due now.')}
${pop?`${tr('Includes a new POP in {city} ({price}{extra}).',{city:CITY[b].name,price:fmt$(popCost(b)),extra:ruCity(b)?', '+tr('government box included'):CITY[b].uae?', '+tr('free-zone license included'):CITY[b].saudi?', '+tr('local telecom licence included'):''})}
`:''}${route}${viaSeg(a,b)} -${esc(why)}
`:''}`;} function ownCabBody(a,b,pop){const why=ownCabWhy(a,b);if(why)return `${esc(why)}
${btn(tr('Back'),'dfSrc',{v:'lease'},'ghost sm')}`; - const km=ownCabKm(a,b),cost=ownCabCost(km),mo=ownCabMo(km),days=ownCabDays(km),w=Math.round(waveMo(km,true,4)*waveMarket(a,b,true).m),save=10*w-mo,pay=save>0?Math.ceil(cost/save):0; + const km=ownCabKm(a,b),cost=ownCabCost(km),mo=ownCabMo(km),days=ownCabDays(km),wt=subMaxTier(km),w=Math.round(waveMo(km,true,wt)*waveMarket(a,b,true).m),save=10*w*LT[4].g/LT[wt].g-mo,pay=save>0?Math.ceil(cost/save):0; return `${tr('Your very own subsea cable. A ship lays it across the seabed, you own every fiber pair in it, and nobody else’s waves share your glass. It costs a frankly rude amount of money and takes a long time.')}
${tr('A leased 1.6T wave on this route costs {price}/mo.',{price:fmt$(w)})} ${pay?tr('Replace ten of them and the cable pays for itself in about {n} months.',{n:pay}):''} ${tr('Cuts still happen, anchors and sharks included, but the repair ship is yours to call.')}
+${tr('A leased {wave} wave on this route costs {price}/mo.',{wave:LT[wt].n,price:fmt$(w)})} ${pay?tr('Replace 16 Tbps of them and the cable pays for itself in about {n} months.',{n:pay}):''} ${tr('Cuts still happen, anchors and sharks included, but the repair ship is yours to call.')}
${tr('Nobody sells dark fiber on a subsea cable here. Subsea capacity comes as leased waves.')}
`+ownCabTeaser(a,b); const sc=isSub(a,b)?subDfCable(a,b):null;if(sc)km=sc.km; - if(uaePair(a,b))return `${tr('No dark fiber inside the UAE. Only the two licensed operators may run fiber here, and they only sell waves.')}
`; - if(landX(a,b)&&cnCity(a)===cnCity(b))return `${tr('Nobody sells one fiber pair across a dozen borders. Between continents, overland capacity only comes as leased waves.')}
`; - if(!dfAllowed(a,b))return `${tr('Dark fiber across the Chinese border is not for sale. Buy a cross-border wave instead.')}
`; - if(lvl()<2)return `${tr('Dark fiber unlocks at customer level 2. You need the scale to justify buying your own optical gear.')}
`; + if(uaePair(a,b))return `${tr('No dark fiber inside the UAE. Only the two licensed operators may run fiber here, and they only sell waves.')}
`+sea; + if(landX(a,b)&&cnCity(a)===cnCity(b))return `${tr('Nobody sells one fiber pair across a dozen borders. Between continents, overland capacity only comes as leased waves.')}
`+sea; + if(!dfAllowed(a,b))return `${tr('Dark fiber across the Chinese border is not for sale. Buy a cross-border wave instead.')}
`+sea; + if(lvl()<2)return `${tr('Dark fiber unlocks at customer level 2. You need the scale to justify buying your own optical gear.')}
`+sea; const src=UI.dfSrc==='build'&&lvl()>=3&&!sc?'build':'lease',sys=DF_SYS[UI.dfSys]&&DF_SYS[UI.dfSys].lvl<=lvl()?UI.dfSys:'lite',amps=ampCount(km); const up=(src==='build'?dfBuildCost(km):0)+DF_SYS[sys].cost+amps*AMP_COST+pop,mo=(src==='build'?Math.round(km*0.15):dfLeaseMo(km))+amps*AMP_MO; const w=Math.round(waveMo(km,false,4)); return `${tr('A fiber pair of your own. The glass is cheap, the gear is not: you buy a line system with an amplifier every {km} km, then optics for each channel. Your gear can fail, and you fix it.',{km:AMP_EVERY})}
-${tr("A fiber pair on {cable}, {km} km. It shares the cable with everyone else's waves, anchors included.",{cable:esc(CAB[sc.cid].name),km:sc.km.toLocaleString()})}
`:''} +${tr("A fiber pair on {cable}, {km} km. It shares the cable with everyone else's waves, anchors included.",{cable:esc(CAB[sc.cid].name),km:sc.km.toLocaleString()})}
`:''} ${src==='build'?`${tr('Your own trench: almost no rent, but permits and digging take forever, and delays happen.')}
`:''}${esc(DF_SYS[sys].blurb)} ${trn('Plus {n} in-line amplifier ({price} each, {mo}/mo for hut rent and power).','Plus {n} in-line amplifiers ({price} each, {mo}/mo for hut rent and power).',amps,{price:fmt$(AMP_COST),mo:fmt$(AMP_MO)})}
${km>OPT.tp16.reach?`${km.toLocaleString()} km is longer than any optic reaches at full speed. Transponders will run in long-haul mode (800G or 400G per channel), or add regen sites along the way to get full speed back.
`:''} +${esc(DF_SYS[sys].blurb)} ${trn('Plus {n} in-line amplifier ({price} each, {mo}/mo for hut rent and power).','Plus {n} in-line amplifiers ({price} each, {mo}/mo for hut rent and power).',amps,{price:fmt$(AMP_COST),mo:fmt$(AMP_MO)})}
${km>reachOn(OPT.tp16.reach,!!sc)?`${tr('{km} km is longer than any optic reaches at full speed. Transponders will run in long-haul mode (1.2T, 800G or 400G per channel), or add regen sites along the way to get full speed back.',{km:km.toLocaleString()})}
`:''}${tr('For comparison, a leased 1.6T wave on this route is {price}/mo. Optics come next, from the link panel.',{price:fmt$(w)})}