:root{--colorBackground:#fff;--colorSurface:#f7f8fa;--colorText:#2b2f33;--colorTextMuted:#626a73;--colorLine:#3a3f45;--colorBorder:#d6d9dd;--colorAccent:#1f6feb;--colorAccentDark:#1858c4;--colorAccentSoft:#e8f0fe;--colorBusy:#1f6feb;--colorStarved:#c9ced4;--colorBlocked:#f08c00;--colorDown:#d62828;--colorOk:#2b8a3e;--colorOkSoft:#ebf6ee;--colorWarn:#b35c00;--colorWarnSoft:#fff4e5;--colorError:#d62828;--colorErrorSoft:#fdecec;--radius:6px;--fontBase:system-ui, -apple-system, "Segoe UI", Roboto, sans-serif}*{box-sizing:border-box}body{background:var(--colorBackground);color:var(--colorText);font-family:var(--fontBase);margin:0;font-size:14px;line-height:1.45}h1,h2{color:var(--colorText);margin:0}h1{font-size:20px}h2{font-size:16px}button,input,select{font:inherit;color:inherit}.visuallyHidden{clip:rect(0 0 0 0);white-space:nowrap;width:1px;height:1px;position:absolute;overflow:hidden}.appHeader{border-bottom:1px solid var(--colorLine);flex-direction:column;gap:12px;padding:14px 24px;display:flex}.appSubtitle{color:var(--colorTextMuted);margin:2px 0 0;font-size:13px}.settingsRow{flex-wrap:wrap;align-items:flex-start;gap:12px;display:flex}.settingsRow>.field{width:110px}.settingsRow>.field:has(select){width:150px}.appMain{flex-direction:column;gap:20px;padding:20px 24px 40px;display:flex}.panel{border:1px solid var(--colorBorder);border-radius:var(--radius);padding:16px}.panelHeader{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:8px 16px;margin-bottom:12px;display:flex}.panelNote{color:var(--colorTextMuted);font-size:13px}.field{flex-direction:column;gap:3px;min-width:0;display:flex}.field label{color:var(--colorTextMuted);font-size:12px;font-weight:600}.fieldUnit{font-weight:400}.field input,.distribution select,.field select{border:1px solid var(--colorBorder);background:var(--colorBackground);border-radius:4px;width:100%;height:32px;padding:4px 8px}.field input:focus,.field select:focus,.distribution select:focus{outline:2px solid var(--colorAccent);outline-offset:-1px;border-color:var(--colorAccent)}.field input.inputInvalid{border-color:var(--colorError);outline-color:var(--colorError);background:var(--colorErrorSoft)}.fieldError{color:var(--colorError);font-size:12px}.fieldCompact input{height:28px;padding:2px 6px}.fieldPair{grid-template-columns:1fr 1fr;gap:8px;display:grid}.distribution{border:0;flex-direction:column;gap:6px;min-width:0;margin:0;padding:0;display:flex}.distribution legend{color:var(--colorTextMuted);margin-bottom:3px;padding:0;font-size:12px;font-weight:600}.distributionParams{grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;display:grid}.distributionBody{flex-direction:column;gap:6px;display:flex}.settingsRow .distributionBody{flex-direction:row;align-items:flex-start}.settingsRow .distributionBody select{width:130px;margin-top:19px}.settingsRow .distributionParams{grid-template-columns:repeat(3,70px)}.settingsRow .distributionParams .fieldCompact input{height:32px}.button{border:1px solid var(--colorLine);background:var(--colorBackground);cursor:pointer;border-radius:4px;height:32px;padding:0 14px}.button:hover:not(:disabled){background:var(--colorSurface)}.buttonPrimary{border-color:var(--colorAccent);background:var(--colorAccent);color:#fff;height:38px;padding:0 22px;font-weight:600}.buttonPrimary:hover:not(:disabled){background:var(--colorAccentDark)}button:disabled{opacity:.45;cursor:default}button:focus-visible{outline:2px solid var(--colorAccent);outline-offset:2px}.iconButton{border:1px solid var(--colorBorder);background:var(--colorBackground);cursor:pointer;border-radius:4px;width:26px;height:26px;padding:0;line-height:1}.iconButton:hover:not(:disabled){border-color:var(--colorLine)}.iconButtonDanger:hover:not(:disabled){border-color:var(--colorError);color:var(--colorError)}.lineRow{align-items:stretch;gap:8px;padding-bottom:6px;display:flex;overflow-x:auto}.lineEnd{writing-mode:vertical-rl;border:1px dashed var(--colorBorder);border-radius:var(--radius);color:var(--colorTextMuted);align-items:center;padding:8px 4px;font-size:12px;display:flex;transform:rotate(180deg)}.card{border:1px solid var(--colorLine);border-radius:var(--radius);background:var(--colorBackground);flex:none}.stationCard{border-top:3px solid var(--colorAccent);flex-direction:column;gap:10px;width:230px;padding:10px 12px 8px;display:flex}.cardHeader{justify-content:space-between;align-items:center;display:flex}.stationNumber{background:var(--colorAccentSoft);width:24px;height:24px;color:var(--colorAccent);border-radius:50%;justify-content:center;align-items:center;font-size:13px;font-weight:700;display:inline-flex}.cardActions{gap:4px;display:flex}.cardHint{color:var(--colorTextMuted);margin:0;font-size:12px}.bufferCard{border-style:dashed;border-color:var(--colorBorder);background:var(--colorSurface);text-align:center;flex-direction:column;justify-content:center;align-items:center;gap:6px;width:92px;padding:8px;display:flex}.bufferArrow{color:var(--colorTextMuted);font-size:16px}.runPanel{flex-wrap:wrap;align-items:center;gap:16px;display:flex}.progress{color:var(--colorTextMuted);align-items:center;gap:10px;display:flex}.progressBar{background:var(--colorSurface);border:1px solid var(--colorBorder);border-radius:5px;width:240px;height:10px;overflow:hidden}.progressFill{background:var(--colorAccent);height:100%;transition:width .1s linear}.errorMessage{border-left:3px solid var(--colorError);background:var(--colorErrorSoft);color:var(--colorError);margin:0;padding:6px 10px}.kpiRow{grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;display:grid}.kpi{border:1px solid var(--colorBorder);border-radius:var(--radius);flex-direction:column;padding:10px 14px;display:flex}.kpiLabel{color:var(--colorTextMuted);font-size:12px;font-weight:600}.kpiValue{overflow-wrap:anywhere;font-size:22px;font-weight:700}.kpiUnit{color:var(--colorTextMuted);font-size:12px}.notice{border-left:3px solid;margin:0;padding:8px 12px;font-size:13px}.noticeWarn{border-color:var(--colorBlocked);background:var(--colorWarnSoft)}.panel .noticeWarn{margin-bottom:12px}.dataTable{border-collapse:collapse;width:100%;margin-top:16px;font-size:13px}.dataTable caption{text-align:left;margin-bottom:6px;font-weight:600}.dataTable th,.dataTable td{border-bottom:1px solid var(--colorBorder);text-align:right;padding:5px 8px}.dataTable th:first-child{text-align:left;font-weight:400}.dataTable thead th{border-bottom-color:var(--colorLine);color:var(--colorTextMuted);font-size:12px;font-weight:600}.littleCheck{border-left:3px solid;margin-top:12px;padding:8px 12px;font-size:13px}.littleOk{border-color:var(--colorOk);background:var(--colorOkSoft)}.littleWarn{border-color:var(--colorWarn);background:var(--colorWarnSoft)}.chartGrid{grid-template-columns:repeat(auto-fit,minmax(420px,1fr));gap:20px;margin-top:16px;display:grid}.chart{min-width:0;margin:0}.chart figcaption{margin-bottom:6px;font-weight:600}.chartSvg{width:100%;height:auto;display:block}.chartLabel,.axisText{fill:var(--colorText);font-size:13px}.axisText{fill:var(--colorTextMuted);font-size:12px}.chartNote{color:var(--colorTextMuted);margin:4px 0 0;font-size:12px}.legend{flex-wrap:wrap;gap:4px 14px;margin:0 0 6px;padding:0;font-size:12px;list-style:none;display:flex}.legend li{align-items:center;gap:5px;display:flex}.legendSwatch{border-radius:2px;width:12px;height:12px;display:inline-block}.gridLine{stroke:var(--colorBorder);stroke-width:1px}.axisLine{stroke:var(--colorLine);stroke-width:1px}.dataLine{fill:none;stroke:var(--colorAccent);stroke-width:1.8px}.averageLine{stroke:var(--colorLine);stroke-width:1px;stroke-dasharray:5 4}.segmentText{pointer-events:none;font-size:12px;font-weight:600}rect.stateBusy,.legendSwatch.stateBusy{fill:var(--colorBusy);background:var(--colorBusy)}rect.stateStarved,.legendSwatch.stateStarved{fill:var(--colorStarved);background:var(--colorStarved)}rect.stateBlocked,.legendSwatch.stateBlocked{fill:var(--colorBlocked);background:var(--colorBlocked)}rect.stateDown,.legendSwatch.stateDown{fill:var(--colorDown);background:var(--colorDown)}rect.stateBusy,rect.stateStarved,rect.stateBlocked,rect.stateDown{stroke:var(--colorBackground);stroke-width:1px}.stateBusyText,.stateDownText{fill:#fff}.stateStarvedText,.stateBlockedText{fill:var(--colorText)}.animationControls{flex-wrap:wrap;align-items:center;gap:8px;display:flex}.buttonAccent{border-color:var(--colorAccent);color:var(--colorAccent);font-weight:600}.segmented{border:1px solid var(--colorLine);border-radius:4px;display:inline-flex;overflow:hidden}.segmented button{border:0;border-left:1px solid var(--colorBorder);background:var(--colorBackground);cursor:pointer;height:30px;padding:0 10px}.segmented button:first-child{border-left:0}.segmented button.segmentActive{background:var(--colorAccent);color:#fff;font-weight:600}.counterRow{flex-wrap:wrap;align-items:flex-end;gap:12px 32px;margin-bottom:8px;display:flex}.counter{flex-direction:column;display:flex}.counterValue{font-variant-numeric:tabular-nums;font-size:20px;font-weight:700}.lineViewScroll{overflow-x:auto}.lineView{width:100%;height:auto;margin:0 auto;display:block}.lineView .flowLine{stroke:var(--colorBorder);stroke-width:2px}.lineView .endBox,.lineView .bufferBox{fill:var(--colorSurface);stroke:var(--colorBorder);stroke-dasharray:4 3}.lineView rect.stationBox{stroke:var(--colorLine);stroke-width:1.5px}.lineView .viewLabel{fill:var(--colorText);font-size:13px;font-weight:600}.lineView .viewSmall{fill:var(--colorTextMuted);font-size:12px}.lineView .viewSmall.stateBusyText,.lineView .viewSmall.stateDownText{fill:#fff;font-weight:600}.lineView .viewSmall.stateStarvedText,.lineView .viewSmall.stateBlockedText{fill:var(--colorText);font-weight:600}.lineView .viewLarge{fill:var(--colorText);font-size:20px;font-weight:700}.partSquare{fill:var(--colorLine);stroke:#fff;stroke-width:1px;transition:transform var(--glide,0s) ease-out}.legendSwatch.legendPart{background:var(--colorLine);width:10px;height:10px}@media (prefers-reduced-motion:reduce){.partSquare{transition:none}}.headerTop{flex-wrap:wrap;justify-content:space-between;align-items:flex-start;gap:12px 24px;display:flex}.fileToolbar{flex-direction:column;align-items:flex-end;gap:6px;max-width:640px;display:flex}.toolbarButtons{flex-wrap:wrap;gap:6px;display:flex}.linkButton{color:inherit;cursor:pointer;background:0 0;border:0;padding:0;text-decoration:underline}.confidenceValue{align-items:center;gap:6px;display:inline-flex}.infoTip{display:inline-flex;position:relative}.infoButton{border:1px solid var(--colorTextMuted);background:var(--colorBackground);width:18px;height:18px;color:var(--colorTextMuted);cursor:help;border-radius:50%;padding:0;font-size:11px;font-style:italic;font-weight:700;line-height:1}.tipText{z-index:10;background:var(--colorText);color:#fff;visibility:hidden;opacity:0;border-radius:4px;width:280px;padding:8px 10px;font-size:12px;font-weight:400;line-height:1.4;transition:opacity .1s;position:absolute;top:calc(100% + 6px);left:50%;transform:translate(-50%)}.infoTip:hover .tipText,.infoTip:focus-within .tipText{visibility:visible;opacity:1}.scenarioForm{gap:6px;display:flex}.scenarioForm input{border:1px solid var(--colorBorder);border-radius:4px;width:200px;height:32px;padding:4px 8px}.tableScroll{overflow-x:auto}.comparisonTable{margin-top:0}.comparisonTable thead th{white-space:nowrap}.comparisonTable thead th .iconButton{width:22px;height:22px;margin-left:6px;font-size:11px}.scenarioName{color:var(--colorText);font-size:13px}
