:root{color-scheme:light;--ink:#202a38;--muted:#586476;--blue:#24549c;--border:#dce3ec;--paper:#fff;--soft:#f5f7fb}
*{box-sizing:border-box}html{scroll-behavior:smooth;scroll-padding-top:2rem}body{margin:0;background:var(--paper);color:var(--ink);font:1.075rem/1.75 Georgia,'Times New Roman',serif}a{color:var(--blue);text-decoration-thickness:1px;text-underline-offset:3px}a:hover{color:#122f65}a:focus-visible,button:focus-visible,input:focus-visible,summary:focus-visible{outline:3px solid #6d9edd;outline-offset:4px}.skip-link{position:fixed;top:-100px;left:1rem;z-index:10;background:white;padding:1rem}.skip-link:focus{top:1rem}
nav{position:fixed;left:0;top:0;width:240px;height:100vh;overflow:auto;padding:2.5rem 1.35rem;border-right:1px solid var(--border);font-family:system-ui,sans-serif;font-size:.875rem;background:var(--soft)}.nav-course{margin:0;font-weight:600;line-height:1.6;color:var(--muted)}.nav-lecture{font-size:1.25rem;font-weight:650;margin:.6rem 0 1.6rem}nav ol{list-style:none;padding:0;margin:0}nav li{margin:.7rem 0;line-height:1.5}nav a{text-decoration:none;display:block}nav .nav-level-1{font-weight:650;margin-top:1.4rem}.nav-level-2{padding-left:.85rem}nav .header-section-number{color:var(--muted);margin-right:.25rem}
main{max-width:1090px;margin-left:240px;padding:3.2rem clamp(1.25rem,4vw,4rem) 5rem}.lecture-title{padding-bottom:2.2rem;border-bottom:2px solid var(--ink);margin-bottom:2.8rem;font-family:system-ui,sans-serif}.lecture-title>p:first-child{font-size:.9rem;color:var(--muted);margin:0 0 .8rem}.lecture-title h1{font-size:2.6rem;line-height:1.2;letter-spacing:-.04em;margin:0}.lecture-title .subtitle{font-size:1.35rem;line-height:1.5;margin:.6rem 0}.lecture-title .author{font-size:1rem;margin:.8rem 0 0;color:var(--muted)}
h1,h2,h3,h4,h5{font-family:system-ui,sans-serif;line-height:1.4}main>h1{font-size:1.85rem;margin:3.5rem 0 1.25rem;padding-bottom:.6rem;border-bottom:1px solid var(--border)}main>h2{font-size:1.4rem;margin:2.6rem 0 1rem}h3{font-size:1.1rem;margin:2rem 0 .7rem}h5{font-size:1rem;margin:0 0 .3rem;font-weight:650}.header-section-number{color:var(--blue);margin-right:.35rem}p{margin:.8rem 0 1.05rem}li{padding-left:.15rem}li>p{margin:.6rem 0}.math.display{display:block;max-width:100%;overflow-x:auto;padding:.45rem .1rem;margin:.8rem 0;overscroll-behavior-x:contain}mjx-container[display=true]{margin:.6em 0!important}mjx-container[jax=SVG]{max-width:100%}.theorem,.proposition,.definition,.lemma,.assumption,.corollary,.example{background:var(--soft);border-left:3px solid #8197b8;padding:.65rem 1.2rem;margin:1.6rem 0;break-inside:avoid}.example{background:white;border-left-color:#c3ccd8}.theorem>p:first-of-type,.proposition>p:first-of-type,.definition>p:first-of-type,.example>p:first-of-type{font-family:system-ui,sans-serif;font-size:1rem;margin:.3rem 0 .65rem}.proof{margin:1rem 0 1.8rem}.proof>p:first-child>em:first-child{font-weight:600}div[id],span[id],figure[id]{scroll-margin-top:1.5rem}
figure{margin:2rem 0;padding:1.3rem 1rem 1rem;border:1px solid var(--border);border-radius:4px;break-inside:avoid;max-width:100%;font-size:.94rem}figcaption{margin:.9rem .25rem 0;line-height:1.6;color:var(--muted)}.plot-grid{display:grid;grid-template-columns:1fr 1fr;gap:1rem}.plot-panel{min-width:0}.plot-panel h5{padding-left:.2rem}.plot-panel canvas{display:block;width:100%;aspect-ratio:1.45;background:white;touch-action:none}.plot-readout{min-height:3rem;line-height:1.5;font: .875rem/1.5 system-ui,sans-serif;margin:.4rem .2rem;color:var(--muted)}.figure-controls{display:flex;flex-wrap:wrap;gap:1rem 1.4rem;align-items:end;border-top:1px solid var(--border);padding:.9rem .2rem .1rem;margin-top:.6rem;font-family:system-ui,sans-serif;font-size:.875rem}.figure-controls label{display:block;flex:1 1 155px;line-height:1.5;min-width:0}.figure-controls output{float:right;margin-left:.65rem;color:var(--blue);font-variant-numeric:tabular-nums}.figure-controls input{width:100%;display:block;margin:.7rem 0 .15rem;accent-color:var(--blue);cursor:pointer;min-height:24px}.figure-controls button{font:inherit;color:var(--ink);background:white;border:1px solid #9cacc0;border-radius:3px;padding:.45rem .8rem;cursor:pointer;min-height:40px}.figure-controls button:hover{background:var(--soft)}.figure-hint{font: .875rem/1.6 system-ui,sans-serif;color:var(--muted);margin:.8rem .2rem}.subcaptions{display:grid;grid-template-columns:1fr 1fr;gap:1rem;font-size:.9rem}.subcaptions p{margin:.6rem .2rem}.historical-figure{border:none;padding:.5rem 0;text-align:center}.historical-figure img{max-width:100%;width:min(100%,580px);height:auto}.historical-figure figcaption{color:var(--ink)}.references{font-size:.95rem;line-height:1.6}.csl-entry{margin:.85rem 0}.footnotes{border-top:1px solid var(--border);font-size:.95rem}.footnotes hr{display:none}
@media(max-width:900px){nav{position:static;width:100%;height:auto;padding:1rem 1.2rem;border-right:none;border-bottom:1px solid var(--border)}.nav-course{display:none}.nav-lecture{font-size:1rem;margin:0 0 .4rem}nav ol{display:flex;gap:1.4rem;overflow-x:auto;padding:.3rem 0 .6rem}nav li,nav .nav-level-1{flex:0 0 auto;max-width:240px;margin:0;white-space:normal}.nav-level-2{padding-left:0}main{margin:0;max-width:960px;padding:2rem 1.3rem 4rem}.lecture-title h1{font-size:2.25rem}}
@media(max-width:620px){body{font-size:1rem}main{padding:1.8rem 1rem 3rem}.plot-grid,.subcaptions{grid-template-columns:1fr}.plot-panel canvas{aspect-ratio:1.55}.plot-readout{min-height:1.5rem}figure{padding:.9rem .7rem}.figure-controls{gap:.8rem}.figure-controls label{flex-basis:135px}.theorem,.proposition,.definition,.example{padding:.5rem .8rem}main>h1{font-size:1.6rem}.lecture-title .subtitle{font-size:1.2rem}}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}}
@media print{nav,.skip-link,.figure-controls,.figure-hint{display:none}main{margin:0;padding:0;max-width:none}body{font-size:10pt}.lecture-title{margin-bottom:1rem;padding-bottom:1rem}a{color:inherit;text-decoration:none}.math.display{overflow:visible}figure{padding:.5rem}main>h1{margin:1.5rem 0 1rem}.plot-readout{font-size:9pt}}
figure[data-dynamic="cone"] .plot-panel{max-width:520px;margin:auto}
figure[data-dynamic="cone"] canvas,figure[data-dynamic="ols"] canvas{aspect-ratio:1}

/* Lecture 3 figures and algorithms */
#rt-fig canvas{display:block;width:100%;max-width:700px}#rt-fig input{font:inherit;max-width:9em}#rt-fig #rt-msg{color:#a32f2f;min-height:1.2em}#rt-fig>div:first-child{font: .9rem/1.5 system-ui,sans-serif}#rt-fig p{font-size:.9rem}.static-figure{text-align:center}.static-figure img{display:block;width:100%;max-height:360px;margin:auto}#cg-fig{font-size:.95rem;text-align:left}.algorithm{background:var(--soft);border-left:3px solid #8197b8;padding:.65rem 1.2rem;margin:1.6rem 0;overflow-x:auto}.algorithm-title{font-family:system-ui,sans-serif;margin:.2rem 0 .7rem}.algorithm-line{margin:.25rem 0}.algorithm-nest{margin:.2rem 0 .45rem 1.2rem;padding-left:.9rem;border-left:1px solid var(--border)}.remark{background:var(--soft);border-left:3px solid #c3ccd8;padding:.65rem 1.2rem;margin:1.6rem 0}
#cg-fig{margin:1.8rem 0;}
#cg-fig .cg-top{display:flex;flex-wrap:wrap;gap:.9rem;align-items:flex-start;}
#cg-fig textarea{font-family:"SF Mono",ui-monospace,Menlo,Consolas,monospace;font-size:.82rem;line-height:1.45;width:16rem;max-width:100%;min-height:6.4rem;border:1px solid var(--rule,#ddd8c8);border-radius:4px;padding:.5rem;background:#fffffb;color:var(--ink,#1a1a17);resize:vertical;}
#cg-fig .cg-side{flex:1;min-width:12rem;font-size:.85rem;}
#cg-fig .cg-inputs{display:flex;flex-wrap:wrap;gap:.55rem;margin-bottom:.5rem;}
#cg-fig .cg-inputs label{color:var(--muted,#5c5c54);font-style:italic;}
#cg-fig .cg-inputs input{width:3.4rem;font:inherit;border:none;border-bottom:1px solid var(--rule,#bbb);background:transparent;text-align:center;color:inherit;}
#cg-fig .cg-btns{display:flex;flex-wrap:wrap;gap:.4rem;margin-top:.3rem;}
#cg-fig button{font:inherit;font-size:.8rem;padding:.25rem .65rem;border:1px solid var(--rule,#cfc9ba);border-radius:4px;background:#fbfaf3;color:var(--ink,#222);cursor:pointer;}
#cg-fig button:hover:not(:disabled){border-color:var(--accent,#7d2b2b);color:var(--accent,#7d2b2b);}
#cg-fig button:disabled{opacity:.4;cursor:default;}
#cg-fig .cg-topo{font-size:.84rem;color:var(--muted,#5c5c54);margin:.9rem 0 .1rem;}
#cg-fig .cg-topo b{color:var(--ink,#222);font-variant:small-caps;letter-spacing:.03em;font-weight:600;}
#cg-fig .cg-topo .cur{color:var(--accent,#7d2b2b);font-weight:700;}
#cg-fig svg{width:100%;height:auto;display:block;}
#cg-fig .cg-msg{color:#9b2c2c;font-size:.8rem;min-height:1.1em;}
#cg-fig .cg-explain{font-size:.85rem;color:var(--ink,#222);min-height:2.6em;background:#fbfaf3;border-left:3px solid var(--rule,#ddd8c8);padding:.45rem .65rem;margin:.4rem 0 .2rem;border-radius:0 4px 4px 0;line-height:1.4;}
#cg-fig .cg-legend{font-size:.78rem;color:var(--muted,#5c5c54);}
@media(max-width:640px){#cg-fig textarea{width:100%;}}
