:root{
  color-scheme:dark;
  font-family:"Inter", "Avenir Next", -apple-system, BlinkMacSystemFont,"Segoe UI", sans-serif;
  --bg:#101716;--bar:#151e1c;--card:#18231f;--line:#2c3b33;--line-strong:#405348;
  --text:#eff2e7;--muted:#a2b1a5;--dim:#84968a;--lime:#ddf780;--lime-d:#b6d958;
  --mono:"SFMono-Regular",Consolas,"Liberation Mono",monospace;
  font-size:16px;
}
*,*::before,*::after{box-sizing:border-box}
body{background:var(--bg);color:var(--text);margin:0}
button,input,textarea,select{font:inherit}
button{cursor:pointer;white-space:nowrap;color:inherit}
button:disabled{opacity:.4;cursor:default}
button:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible{outline:2px solid var(--lime);outline-offset:3px}
button:not(:disabled){transition:background .15s,border-color .15s,color .15s}
h1,h2,p{margin:0}
h1{font-size:clamp(2rem,4vw,3rem);line-height:1.09;letter-spacing:-.055em;font-weight:680}
h2{font-size:1.05rem;font-weight:650;letter-spacing:-.022em}
[hidden]{display:none!important}
.site-header{border-bottom:1px solid #2b3930;background:#131b18}
.header-inner{max-width:1510px;margin:auto;padding:0 3.1%;height:64px;display:flex;align-items:center;justify-content:space-between;gap:.75rem}
.brand{display:flex;align-items:center;gap:11px;font-size:1.05rem;line-height:1;font-weight:760;letter-spacing:.105em}
.brand small{display:block;color:#aebeaf;font-family:var(--mono);font-weight:500;font-size:.62rem;letter-spacing:.13em;margin-top:5px}
.brand-mark{width:34px;height:34px;border-radius:8px;background:var(--lime);display:flex;align-items:center;justify-content:center;gap:3px;overflow:hidden;flex-shrink:0}
.brand-mark i{width:4px;height:11px;border-radius:5px;background:#293628;transform:skewX(-27deg)}
.brand-mark i:nth-child(2){height:20px}.brand-mark i:nth-child(3){height:14px}
.header-tools{display:flex;gap:1rem;align-items:center}
.header-link{display:inline-flex;align-items:center;text-decoration:none;white-space:nowrap}
.header-link:focus-visible{outline:2px solid var(--lime);outline-offset:3px}
.local{display:inline-flex;align-items:center;gap:7px;color:var(--muted);font-size:.82rem}
.local i,#run-state i{display:inline-block;width:7px;height:7px;background:var(--lime-d);border-radius:100%;box-shadow:0 0 0 3px #badb6424}
main{max-width:1510px;margin:auto;padding:0 3.1%}
.intro{display:flex;align-items:flex-end;justify-content:space-between;gap:1rem;padding:25px 0 22px}
.intro p{color:var(--muted);margin-top:8px;font-size:.99rem;letter-spacing:-.01em}
.launch{border-left:1px solid var(--line-strong);padding-left:17px;min-width:122px}
.launch span,.detail-title>span{color:var(--dim);font:600 .67rem var(--mono);letter-spacing:.10em}
.launch strong{display:block;margin-top:5px;font:600 1.39rem var(--mono);color:var(--lime)}
.launch small{font-size:.79rem;color:var(--muted);font-weight:500}
#launch-setup{display:block;margin-top:5px;white-space:nowrap}
.deck{display:grid;grid-template-columns:minmax(0,1fr) clamp(285px,24.2vw,343px);gap:16px;align-items:start}
.card{background:var(--card);border:1px solid var(--line);border-radius:13px}
.ride-panel{overflow:hidden}
.viewport{position:relative;height:clamp(325px,34vw,476px);isolation:isolate;background:#54634d}
#world{display:block;width:100%;height:100%;cursor:grab;touch-action:none}
#world.dragging{cursor:grabbing}
.viewport::after{content:"";position:absolute;inset:0;pointer-events:none;background:linear-gradient(#0a1c1440 0%,transparent 23%,transparent 77%,#12201865 100%);z-index:0}
.viewport-head,.viewport-foot{position:absolute;z-index:1;display:flex;justify-content:space-between;align-items:flex-start;gap:.5rem;left:14px;right:14px;pointer-events:none}
.viewport-head{top:13px}.viewport-foot{bottom:13px;align-items:flex-end}
.view-tag,.camera-switch{background:#14211ce8;border:1px solid #dce8c940;min-height:32px;border-radius:7px;color:#f0f3e8;display:inline-flex;align-items:center;padding:0 10px;gap:8px;font-size:.77rem;font-weight:570;backdrop-filter:blur(6px)}
.view-tag i{width:7px;height:7px;border-radius:50%;background:var(--lime);display:inline-block}
.view-tag b{color:#d1ddc7}.view-help{color:#d8e2d6;font-size:.735rem}
.camera-switch{padding:3px;gap:2px;pointer-events:auto}
.camera-switch button{border:0;background:none;border-radius:4px;padding:4px 9px;font-size:.77rem;color:#d9e2d6}
.camera-switch button:hover,.camera-switch button[aria-pressed="true"]{background:#d7ee932d;color:#f4ffd6}
#forces{pointer-events:auto}
#forces i{background:none;border:1px solid #c2d1bf}
#forces[aria-pressed="true"]{color:var(--lime)}
#forces[aria-pressed="true"] i{background:var(--lime);border-color:var(--lime)}
.view-error{position:absolute;inset:20% 12%;background:#15211fe8;display:grid;place-items:center;padding:1rem;text-align:center;z-index:2;border-radius:13px;border:1px solid #647266}
.course-strip{background:#16201c;padding:10px 15px 9px;border-bottom:1px solid var(--line)}
.course-header{display:flex;justify-content:space-between;align-items:center;font-size:.77rem;line-height:1.13}
#run-state{display:flex;align-items:center;gap:8px;color:#e2eadb;font-weight:600}
#run-state[data-state="playing"] i{background:#dcf762}
#run-state[data-state="ended"] i{background:#f5ad68;box-shadow:0 0 0 3px #f5ad6826}
#run-position{font-family:var(--mono);color:#bccdbb}#run-position b{margin:0 3px}
#course-profile{width:100%;height:38px;display:block;margin-top:3px}
.sectors{display:flex;gap:8px;flex-wrap:wrap;margin-top:4px}
.sectors button{display:inline-flex;gap:5px;align-items:center;border:0;background:none;padding:1px 6px 1px 0;color:#b8c6b6;font-size:.72rem}
.sectors button b{font:700 .59rem var(--mono);border:1px solid #596348;color:#d4e79e;border-radius:3px;width:15px;height:14px;display:grid;place-items:center}
.sectors button:hover,.sectors button[aria-current="step"]{color:var(--lime)}
.transport{display:flex;align-items:center;justify-content:space-between;gap:13px;padding:12px 15px 9px}
.transport-buttons,.speed-control,.compare-buttons{display:flex;align-items:center;gap:8px}
.primary,.outline{min-height:34px;border-radius:7px;padding:0 12px;font-size:.833rem;font-weight:620}
.outline{background:#1c2923;color:#e9f1df;border:1px solid #415247}
.outline:hover:not(:disabled){background:#2a3a2e;border-color:#718361}
.primary{color:#1b2617;background:var(--lime);border:1px solid var(--lime)}
.primary:hover:not(:disabled){background:#edffa5;border-color:#edffa5}
#play{min-width:87px;display:inline-flex;justify-content:center;gap:8px;align-items:center}
.play-icon{width:0;height:0;border-left:8px solid #293520;border-top:5px solid transparent;border-bottom:5px solid transparent}
#play[data-playing="true"] .play-icon{width:8px;height:10px;border:0;border-left:3px solid #293520;border-right:3px solid #293520}
.brake[aria-pressed="true"]{color:#ffd2bc;border-color:#e58765;background:#4c3028}
kbd{background:#121e18;border:1px solid #39473d;color:#a8bbab;font:500 .67rem var(--mono);padding:0 3px;border-radius:3px;margin-left:4px}
.speed-control{flex:0 1 226px;min-width:145px;color:var(--muted);font-size:.76rem}
.speed-control input{min-width:40px;width:100%;margin:0 2px;accent-color:var(--lime)}
.speed-control output{font:600 .79rem var(--mono);color:var(--lime);min-width:37px;text-align:right;white-space:nowrap}
.run-options{display:flex;align-items:center;gap:13px;flex-wrap:wrap;padding:1px 15px 10px}
.run-options label,.run-options button{font-size:.74rem;color:var(--muted)}
.run-options label{display:flex;align-items:center;gap:5px;white-space:nowrap;cursor:pointer}
input[type="checkbox"]{margin:0;accent-color:#cce772;width:13px;height:13px}
.link-button{border:0;background:transparent;padding:0;color:#deefab;font-size:.76rem;text-decoration:underline;text-underline-offset:3px;text-decoration-color:#a3bd7678}
.link-button:hover{color:var(--lime);text-decoration-color:var(--lime)}
.run-options .link-button:first-of-type{margin-left:auto}
.steering{display:flex;align-items:center;gap:11px;padding:2px 15px 12px;color:var(--muted);font-size:.76rem}
.steering input{width:clamp(70px,33%,240px);margin:0;accent-color:var(--lime)}
.steering output{font:600 .78rem var(--mono);color:var(--lime);min-width:35px;text-align:right}
.steering .link-button{margin-left:3px}
.bike-panel{padding:13px;overflow:hidden}
.panel-title{display:flex;align-items:center;justify-content:space-between;margin:1px 1px 10px}
.panel-title span,.section-heading>span{color:var(--dim);font:500 .71rem var(--mono)}
.bikes{display:grid;gap:6px}
.bike-choice{width:100%;min-height:41px;color:#e9f0e4;display:flex;justify-content:space-between;align-items:center;gap:6px;background:#1d2a24;border:1px solid #304139;border-radius:7px;padding:5px 9px;text-align:left;font-size:.865rem}
.bike-choice:hover,.bike-choice[aria-pressed="true"]{background:#26372a;border-color:#637849}
.bike-choice[aria-pressed="true"]{box-shadow:inset 2px 0 var(--lime)}
.bike-choice strong{display:flex;align-items:center;gap:8px;font-weight:610;min-width:0;white-space:normal}
.bike-choice i{display:inline-block;width:10px;height:10px;flex:0 0 10px;border-radius:50%;background:var(--paint);box-shadow:0 0 0 3px color-mix(in srgb,var(--paint),transparent 84%)}
.bike-choice span{font:500 .74rem var(--mono);color:#a9baaa;white-space:nowrap}
.bike-choice[aria-pressed="true"] span{color:var(--lime)}
.bike-detail{margin:12px 1px 0;padding-top:10px;border-top:1px solid var(--line)}
.detail-title,.curve-title,.curve-footer{display:flex;justify-content:space-between;align-items:center;gap:5px}
.bike-detail p{color:#c1cdbf;font-size:.815rem;line-height:1.36;margin:6px 0 8px;min-height:34px}
.bike-detail .head-angle{display:flex;align-items:center;justify-content:space-between;margin:8px 0 1px;color:var(--muted);font-size:.74rem}
.head-angle span{display:flex;align-items:center;gap:5px}
.head-angle input{width:65px;padding:3px 5px;background:#17241d;color:var(--text);border:1px solid #4a5e4c;border-radius:5px;font:600 .74rem var(--mono)}
#mount-control{display:flex;justify-content:space-between;gap:5px;align-items:center;color:var(--muted);font-size:.75rem;margin:0 0 8px}
#mount{background:#222e26;color:#edf3df;border:1px solid #4a5e4c;border-radius:5px;padding:2px 5px;font-size:.74rem}
.curve-title{font-size:.72rem;color:var(--muted)}
.curve-title strong{color:#cde583;font:600 .75rem var(--mono)}
#leverage-chart{display:block;width:100%;height:61px;margin:3px 0}
.curve-footer{font-size:.66rem;color:var(--dim);white-space:nowrap}
#shock-spec{font:600 .68rem var(--mono);color:#c3d3bd}
.telemetry{margin-top:17px}
.section-heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}
.metrics{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:9px}
.metric{padding:11px 11px 10px;min-height:86px;display:flex;flex-direction:column;gap:6px;overflow:hidden}
.metric>span{color:var(--muted);font-size:.78rem;white-space:nowrap}
.metric strong{font:600 clamp(.94rem,1.42vw,1.32rem) var(--mono);color:#edf3df;white-space:nowrap;letter-spacing:-.055em}
.metric strong small{color:#b9c9b5;font-size:.65rem;font-weight:520;letter-spacing:0}
.metric em{font:500 .67rem var(--mono);font-style:normal;color:#a2b39f;white-space:nowrap}
progress{width:100%;height:4px;border:0;border-radius:4px;background:#304037;accent-color:var(--lime-d);margin:5px 0 2px;display:block}
progress::-webkit-progress-bar{border-radius:4px;background:#304037}
progress::-webkit-progress-value{border-radius:4px;background:var(--lime-d)}
.comparison{margin-top:15px;padding:13px}
.setup-panel,.results-panel{margin-top:15px;padding:15px;scroll-margin-top:14px}
.setup-panel .section-heading p,.results-panel .section-heading p{font-size:.79rem;color:var(--muted);margin-top:4px}
.setup-fields{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:13px 0}
.setup-fields label{display:grid;gap:5px;font-size:.78rem;color:var(--muted);min-width:0}
.setup-fields label span{display:flex;align-items:center;gap:6px;min-width:0;padding-right:8px;background:#111d18;border:1px solid #405348;border-radius:7px}
.setup-fields input{min-width:0;width:100%;padding:8px 0 8px 9px;border:0;border-radius:6px;color:var(--text);background:transparent;font:600 .84rem var(--mono)}
.setup-fields b{font-size:.68rem;white-space:nowrap;font-weight:500}
.setup-actions{display:flex;gap:8px;align-items:center}
.setup-actions p{flex:1;margin:0;color:var(--muted);font-size:.76rem;line-height:1.4}
.results-panel table{width:100%;border-collapse:collapse;font-variant-numeric:tabular-nums;margin-top:10px}
.results-panel th,.results-panel td{padding:9px 9px;border-bottom:1px solid var(--line);text-align:right;font-size:.79rem}
.results-panel th{text-align:right;color:var(--muted);font-size:.73rem;font-weight:600}
.results-panel th:first-child,.results-panel td:first-child{text-align:left}
.results-panel td:not(:first-child){font-family:var(--mono)}
.results-panel td:first-child{font-weight:600}
.results-panel tr[data-selected="true"] td{background:#d5f17a0d}
.results-panel tbody tr:last-child td{border-bottom:0}
.results-panel .bench-time{color:var(--lime);font-weight:700}
.results-panel .bench-status{min-height:1.2em;color:var(--muted);font-size:.76rem;margin-top:7px}
.results-panel .result-dot{display:inline-block;width:8px;height:8px;border-radius:50%;margin-right:7px;background:var(--paint)}
.results-panel .result-reason{display:block;color:var(--muted);font-size:.7rem;font-weight:400;margin-left:15px}
.comparison-head{display:flex;justify-content:space-between;gap:12px;align-items:center}
.comparison-head p{font-size:.79rem;color:var(--muted);margin-top:4px}
.compare-slots{display:grid;grid-template-columns:1fr 1fr;gap:9px;margin-top:10px}
.compare-slots>div{min-height:45px;border:1px solid var(--line);border-radius:7px;padding:8px 9px;display:flex;gap:9px;align-items:flex-start;color:#b7c9b7;font-size:.78rem}
.compare-slots b{color:var(--lime);font:700 .78rem var(--mono);border:1px solid #576a47;padding:3px 5px;border-radius:4px}
.compare-slots p{padding-top:2px;line-height:1.45}
.compare-slots strong{color:var(--text);font-weight:650}
.compare-slots small{display:block;color:var(--muted);font-size:.70rem}
footer{display:flex;justify-content:space-between;gap:10px;padding:16px 0 19px;color:var(--dim);font-size:.72rem}
footer:has(#analytics-settings:not([hidden])){align-items:center;flex-wrap:wrap}
footer #analytics-settings{font-size:inherit;padding:0}
.analytics-choice{position:fixed;z-index:5;right:16px;bottom:16px;width:min(356px,calc(100% - 32px));padding:14px;background:#192720;border:1px solid #70806b;border-radius:10px;box-shadow:0 10px 30px #040c08b0}
.analytics-choice h2{font-size:.95rem}
.analytics-choice p{margin:6px 0 12px;color:#cfdbcd;font-size:.81rem;line-height:1.4}
.analytics-actions{display:flex;justify-content:flex-end;gap:8px}
dialog{width:min(640px,calc(100vw - 24px));color:var(--text);background:#192720;border:1px solid #70806b;border-radius:13px;padding:19px;box-shadow:0 18px 70px #040c08c0}
dialog::backdrop{background:#050b08a8;backdrop-filter:blur(3px)}
.dialog-head,.dialog-actions{display:flex;align-items:center;justify-content:space-between;gap:10px}
dialog h2{font-size:1.35rem}
dialog p{color:#cfdbcd;font-size:.91rem;line-height:1.47;margin:12px 0}
dialog textarea{width:100%;height:min(50vh,430px);resize:vertical;background:#102018;color:#ddefd5;border:1px solid #536c55;border-radius:6px;padding:8px;font:500 .78rem/1.35 var(--mono)}
.dialog-actions{margin-top:11px}
.form-error{color:#ffc1a6!important;font-size:.79rem;padding:4px 15px 10px}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
@media(max-width:890px){
  .deck{grid-template-columns:minmax(0,1fr) 260px;gap:11px}
  .metrics{grid-template-columns:repeat(3,minmax(0,1fr))}
  .metric strong{font-size:1.12rem}
}
@media(max-width:670px){
  .header-inner,main{padding-left:12px;padding-right:12px}
  .header-tools .local{display:none}
  .intro{padding:17px 0 15px;align-items:center}.intro p{font-size:.84rem}
  .launch{min-width:0;padding-left:9px}.launch span{white-space:nowrap;font-size:.54rem}.launch strong{font-size:1.11rem}
  .deck{display:flex;flex-direction:column}
  .ride-panel,.bike-panel{width:100%}
  .viewport{height:clamp(260px,68vw,390px)}
  .bikes{grid-template-columns:1fr 1fr}
  .bike-choice{min-width:0;font-size:.78rem}
  .bike-choice span{font-size:.66rem}
  .section-heading{margin-top:2px}
  .metric{padding:8px;min-height:75px}
  .metric>span{font-size:.72rem}.metric strong{font-size:.91rem}
  .comparison-head{align-items:flex-start}
  .setup-fields{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:420px){
  .viewport-head,.viewport-foot{left:7px;right:7px}
  .camera-switch button{padding:4px 6px}.view-tag{padding:0 6px;font-size:.68rem}
  .transport{padding-left:8px;padding-right:8px;gap:6px}
  .transport-buttons{gap:4px}.transport .primary,.transport .outline{padding:0 6px;font-size:.75rem}#play{min-width:64px}
  .speed-control{min-width:105px;gap:3px}.speed-control label{font-size:.65rem}
  #brake kbd{display:none}
  .header-tools{gap:5px}.header-tools .outline{font-size:.72rem;padding-inline:7px}
  .setup-actions{flex-wrap:wrap}.setup-actions p{flex-basis:100%}
  .results-panel th,.results-panel td{padding-inline:4px}
  footer{font-size:.61rem}
}
