/* obrazovky příběhu oboru Výroba (.sv-*), staví na třídách .ss-* ze site-screens.css */

/* přehled haly */
.sv-hall { display: grid; grid-template-columns: minmax(0, 1fr) 224px; gap: 10px; flex: 1; min-height: 0; }
.sv-mgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: repeat(4, minmax(0, 1fr)); gap: 8px; min-height: 0; }
.sv-m { display: flex; flex-direction: column; justify-content: center; gap: 3px; min-width: 0; padding: 6px 11px; background: #fff; border: 1px solid #e1e6e8; border-left: 3px solid #0a716f; border-radius: 10px; transition: border-color 160ms ease; }
.sv-m.is-wait { border-left-color: #c7ced2; } .sv-m.is-warn { border-left-color: #e07a3a; }
.sv-m__h { display: flex; justify-content: space-between; align-items: center; gap: 8px; } .sv-m__h b { font-size: 13.5px; font-weight: 600; }
.sv-m p { margin: 0; font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sv-st { padding: 1px 8px; border-radius: 99px; background: #d5ebea; color: #0a716f; font-size: 11px; font-weight: 500; }
.sv-st.is-wait { background: #eceff1; color: #5b6670; } .sv-st.is-warn { background: #fbe7d8; color: #a0470f; }
.sv-m__f { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: center; }
.sv-m__f em { display: block; height: 6px; background: #e6ebec; border-radius: 6px; overflow: hidden; }
.sv-m__f u { display: block; height: 100%; background: #0a716f; transform: scaleX(0); transform-origin: left; }
.sv-m.is-warn .sv-m__f u { background: #e07a3a; }
.sv-m__f small { font-size: 11.5px; font-weight: 500; font-variant-numeric: tabular-nums; }
.sv-orders { display: flex; flex-direction: column; } .sv-orders .ss-alert, .sv-orders .ss-result { margin-top: auto; }

/* kusovník */
.sv-bom { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 10px; flex: 1; min-height: 0; }
.sv-tr { display: grid; grid-template-columns: minmax(0, 1fr) 46px 132px; gap: 8px; align-items: center; padding: 6px 0; border-top: 1px solid #eef1f2; }
.sv-tr span { min-width: 0; font-size: 12.5px; } .sv-tr span b { display: block; font-size: 11px; font-weight: 600; color: var(--action); }
.sv-tr i { font-style: normal; font-variant-numeric: tabular-nums; } .sv-tr small { font-size: 11px; color: var(--muted); line-height: 1.25; }
.sv-tr.is-sub span { padding-left: 16px; position: relative; } .sv-tr.is-sub span::before { content: ""; position: absolute; left: 3px; top: -2px; width: 8px; height: 12px; border-left: 1.5px solid #c7ced2; border-bottom: 1.5px solid #c7ced2; border-bottom-left-radius: 3px; }
.sv-tr--h, .sv-mat--h { border-top: 0; padding: 0 0 3px; font-size: 11px; color: var(--muted); } .sv-tr--h span, .sv-tr--h i, .sv-tr--h small { font-size: 11px; color: var(--muted); }
.sv-sum { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 8px; }
.sv-sum p { margin: 0; padding: 7px 9px; background: #f5f7f8; border-radius: 8px; } .sv-sum small { display: block; font-size: 11px; color: var(--muted); } .sv-sum b { font: 600 18px/1.2 var(--font-display); font-variant-numeric: tabular-nums; }
.sv-matcard { display: flex; flex-direction: column; }
.sv-mat { display: grid; grid-template-columns: minmax(0, 1fr) 54px 98px; gap: 6px; align-items: center; padding: 7px 0; border-top: 1px solid #eef1f2; transition: opacity 160ms ease; }
.sv-mat span { font-size: 12px; } .sv-mat i { font-style: normal; font-size: 12px; text-align: right; font-variant-numeric: tabular-nums; }
.sv-mat b { font-size: 11.5px; font-weight: 500; text-align: right; color: var(--muted); } .sv-mat b.is-on { color: var(--action); } .sv-mat b.is-warn { color: #a0470f; }
.sv-matcard .ss-btn { margin-top: auto; } .sv-matcard .ss-result { margin-top: 6px; }

/* plán strojů */
.sv-gantt { flex: none; }
.sv-move { position: absolute; height: 48px; z-index: 2; transition: background-color 180ms ease, border-color 180ms ease; }
.sv-move.is-moving { box-shadow: 0 12px 20px -8px rgba(27, 42, 68, .45); }
.sv-gantt + .ss-three { flex: 1; min-height: 0; } .sv-gantt + .ss-three .ss-alert, .sv-gantt + .ss-three .ss-result { margin: 0; font-size: 12px; }

/* linka */
.sv-linecard { flex: none; padding: 8px 10px 4px; }
.sv-line { display: block; width: 100%; }
.sv-belt { stroke: #c9d1d5; stroke-width: 6; stroke-linecap: round; }
.sv-stn { fill: #fff; stroke: #0a716f; stroke-width: 2.5; transition: fill 160ms ease, stroke 160ms ease; }
.sv-stn__n { font-size: 14px; font-weight: 600; fill: var(--ink); text-anchor: middle; } .sv-stn__s { font-size: 12px; fill: #0a716f; text-anchor: middle; font-weight: 500; }
.sv-q rect { fill: #5e9c93; transition: opacity 120ms ease; } .sv-qn { font-size: 12px; font-weight: 600; fill: var(--muted); text-anchor: end; }
g.is-bad .sv-stn { fill: #fbe7d8; stroke: #e07a3a; } g.is-bad .sv-stn__s { fill: #a0470f; } g.is-bad .sv-q rect { fill: #e07a3a; } g.is-bad .sv-qn { fill: #a0470f; }
g.is-idle .sv-stn { stroke: #c7ced2; } g.is-idle .sv-stn__s { fill: #8a949c; }
.sv-linegrid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: 10px; flex: 1; min-height: 0; }
.sv-linegrid .ss-task { padding: 7px 0; grid-template-columns: 36px minmax(0, 1fr); }
.sv-linegrid .ss-kpis { margin: 4px 0 6px; }

/* údržba */
.sv-vib { display: flex; flex-direction: column; } .sv-vib svg { flex: 1; min-height: 0; width: 100%; }
.sv-vib__h { display: flex; justify-content: space-between; align-items: flex-start; } .sv-vib__h p { margin: 0; text-align: right; } .sv-vib__h small { display: block; font-size: 11px; color: var(--muted); } .sv-vib__h b { font: 600 20px/1.1 var(--font-display); font-variant-numeric: tabular-nums; }
.sv-grid { stroke: #eef1f2; stroke-width: 1.5; } .sv-ax { font-size: 11px; fill: var(--muted); text-anchor: end; }
.sv-limit { stroke: #e07a3a; stroke-width: 2; stroke-dasharray: 6 5; } .sv-limit__t { font-size: 12px; font-weight: 600; fill: #a0470f; text-anchor: end; }
.sv-vibline { fill: none; stroke: #0a716f; stroke-width: 3.5; stroke-linejoin: round; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; }
.sv-fc { fill: none; stroke: #e07a3a; stroke-width: 3; stroke-dasharray: 5 6; transition: opacity 160ms ease; } .sv-fcdot { fill: #e07a3a; stroke: #fff; stroke-width: 3; transition: opacity 160ms ease; }
.sv-fc__t { font-size: 13px; font-weight: 600; fill: #a0470f; text-anchor: end; transition: opacity 160ms ease; }
.sv-vib + .ss-card .ss-task { padding: 8px 0; grid-template-columns: 40px minmax(0, 1fr) auto; }

/* kvalita */
.sv-spc { display: flex; flex-direction: column; } .sv-spc svg { width: 100%; margin-bottom: 6px; background: #f5f7f8; border-radius: 8px; }
.sv-spc__ok { fill: #e8f3f2; } .sv-pt { fill: #0a716f; transition: opacity 120ms ease; } .sv-pt.is-warn { fill: #e07a3a; }
.sv-spc .ss-line b.is-warn, .sv-costcard b.is-warn { color: #a0470f; }
.sv-spc .ss-result { margin-top: auto; }

/* šarže */
.sv-tracecard { flex: none; padding-bottom: 6px; }
.sv-search { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; } .sv-search > span:first-child { font-size: 12px; color: var(--muted); }
.sv-search b { flex: 1; min-height: 30px; padding: 6px 10px; border: 1px solid #e1e6e8; border-radius: 8px; font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; }
.sv-cols { position: relative; height: 16px; font-size: 11px; color: var(--muted); } .sv-cols span { position: absolute; top: 0; }
.sv-trace { display: block; width: 100%; }
.sv-edge { fill: none; stroke: #c9d1d5; stroke-width: 2; transition: stroke 160ms ease, opacity 160ms ease; } .sv-edge.is-hit { stroke: #e07a3a; stroke-width: 3; } .sv-edge.is-off { opacity: .35; }
.sv-node rect { fill: #fff; stroke: #c9d1d5; stroke-width: 1.5; transition: fill 160ms ease, stroke 160ms ease; } .sv-node { transition: opacity 160ms ease; }
.sv-node__t { font-size: 12.5px; font-weight: 600; fill: var(--ink); } .sv-node__s { font-size: 11px; fill: var(--muted); }
.sv-node.is-hit rect { fill: #fbe7d8; stroke: #e07a3a; stroke-width: 2; } .sv-node.is-off { opacity: .4; }
.sv-k { display: block; font-size: 12px; color: var(--muted); } .sv-big { font: 600 22px/1.2 var(--font-display); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.sv-mt { margin-top: 6px; }

/* AI asistent */
.sv-dbars > div { grid-template-columns: 62px minmax(0, 1fr) 46px 128px; } .sv-dbars small { font-size: 11.5px; color: var(--muted); }

/* kalkulace */
.sv-costcard { flex: 1; min-height: 0; display: flex; flex-direction: column; justify-content: space-around; }
.sv-ct { display: grid; grid-template-columns: 150px minmax(0, 1fr) 86px 86px 128px; gap: 10px; align-items: center; padding: 8px 0; border-top: 1px solid #eef1f2; }
.sv-ct span { font-size: 12px; } .sv-ct span b { display: block; font-size: 12.5px; font-weight: 600; }
.sv-ct em { position: relative; display: block; height: 14px; background: #f1f3f4; border-radius: 4px; }
.sv-ct u { display: block; height: 100%; width: 0; background: #0a716f; border-radius: 4px; } .sv-ct u.is-over { background: #e07a3a; }
.sv-ct s { position: absolute; top: -3px; bottom: -3px; width: 0; border-left: 2px solid #1b2a44; text-decoration: none; }
.sv-ct i { font-style: normal; font-size: 12px; text-align: right; font-variant-numeric: tabular-nums; }
.sv-ct > b { font-size: 11.5px; font-weight: 500; color: var(--muted); } .sv-ct > b.is-on { color: var(--action); }
.sv-ct--h { border-top: 0; padding: 0 0 2px; } .sv-ct--h span, .sv-ct--h i, .sv-ct--h b { font-size: 11px; color: var(--muted); font-weight: 400; }
.sv-hud { font-size: 12px; fill: rgba(255, 255, 255, .6); } .sv-hud--b { font-size: 17px; font-weight: 600; fill: #fff; }
.sv-tracecard { flex: 1; min-height: 0; display: flex; flex-direction: column; } .sv-tracecard .sv-trace { margin: auto 0; }
.sv-tracecard + .ss-three { flex: none; }
.sv-late { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-bottom: 11px; }
.sv-late p { margin: 0; padding: 7px 9px; background: #fff; border-radius: 8px; font-size: 11.5px; color: var(--muted); transition: opacity 160ms ease; } .sv-late b { display: block; font-size: 12.5px; color: var(--ink); } .sv-late span { display: block; } .sv-late i { font-style: normal; color: #a0470f; font-weight: 500; }
