:root{color-scheme:only light;font-family:Avenir Next,Segoe UI,sans-serif;--bg: #f4f1eb;--panel: #fffaf2;--text: #1f1c18;--muted: #645b51;--accent: #c44b1b;--ok: #2d7a4f;--warn: #a06a00;--late: #9a1d1d;--border: #e5dacb}*{box-sizing:border-box}body{margin:0;background:radial-gradient(circle at top right,#fde0bf 0%,var(--bg) 38%,#efe8db 100%);color:var(--text)}button,input,select{font:inherit}.kds-shell{min-height:100vh;padding:14px}.kds-header{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;padding:14px;border:1px solid var(--border);background:var(--panel);border-radius:16px}.kds-header h1{margin:0 0 4px;font-size:26px}.kds-header p{margin:2px 0;color:var(--muted);font-size:12px}.header-controls{display:flex;align-items:center;flex-wrap:wrap;gap:10px}.mode-switch,.profile-switch{display:flex;border:1px solid var(--border);border-radius:12px;overflow:hidden}.profile-switch button{min-width:88px;min-height:48px;border:0;background:#f2ebe0;color:var(--text);font-weight:700;text-transform:capitalize}.profile-switch button.active{background:#2b4b65;color:#fff}.profile-switch button:disabled{opacity:.55}.mode-switch button{min-width:122px;min-height:48px;border:0;background:#f2ebe0;color:var(--text);font-weight:700}.mode-switch button.active{background:var(--accent);color:#fff}.connection-badge{padding:8px 12px;border-radius:999px;text-transform:uppercase;font-size:12px;font-weight:800}.connection-badge.online{background:#def6e9;color:#0f6b3d}.connection-badge.degraded{background:#fff0d9;color:#825300}.connection-badge.offline{background:#ffe2e2;color:#9a1d1d}.resync-button{min-height:48px;border-radius:10px;border:0;background:#2b4b65;color:#fff;font-weight:700;padding:0 14px}.resync-button:disabled{opacity:.65}.resync-button-secondary{background:#465e73}.kds-toolbar{margin-top:12px;display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:10px;padding:12px;border:1px solid var(--border);border-radius:14px;background:var(--panel)}.station-summary{margin-top:12px;display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:10px}.throughput-summary{margin-top:10px;display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:10px}.summary-card{border:1px solid var(--border);border-radius:12px;background:var(--panel);padding:10px;display:flex;flex-direction:column;gap:2px}.summary-card strong{font-size:22px}.summary-card span{color:var(--muted);font-size:12px}.station-metrics{margin-top:12px;display:grid;gap:10px}.lane-section{border:1px solid var(--border);border-radius:14px;background:var(--panel);padding:10px;display:flex;flex-direction:column;gap:8px}.lane-section h3{margin:0}.lane-now{border-color:#cde6d8;background:#f4fff8}.lane-at-risk{border-color:#f0d4a6;background:#fff8ea}.lane-exceptions{border-color:#f0b7b7;background:#fff4f4}.lane-done{border-color:#d3d9e5;background:#f4f6fb}.lane-head-row{display:flex;align-items:center;justify-content:space-between;gap:8px}.lane-toggle{min-height:38px;border-radius:10px;border:1px solid var(--border);background:#fff;color:var(--text);font-weight:700;padding:0 12px}.station-metric-card{border:1px solid var(--border);border-radius:12px;background:var(--panel);padding:10px;display:flex;flex-direction:column;gap:4px}.station-metric-card>strong{text-transform:capitalize}.station-metric-card>span{color:var(--muted);font-size:12px}.kds-toolbar label{display:flex;flex-direction:column;gap:6px;font-size:12px;font-weight:700;color:var(--muted)}.kds-toolbar select,.kds-toolbar input{min-height:44px;border-radius:10px;border:1px solid var(--border);background:#fff;padding:0 10px;color:var(--text)}.counter-box{min-height:72px;border-radius:12px;background:linear-gradient(135deg,#ff9d6f,#c44b1b);color:#fff;display:flex;align-items:center;justify-content:center;flex-direction:column;text-align:center;font-size:12px}.counter-box strong{font-size:26px;line-height:1}.status-banner{margin-top:12px;padding:12px;border-radius:12px;border:1px solid #f3c685;background:#fff5e7;display:flex;flex-direction:column;gap:4px}.missing-source-banner{border-color:#f1b8b8;background:#fff1f1}.ready-board{margin-top:12px;border:1px solid var(--border);border-radius:14px;background:var(--panel);padding:12px}.ready-board h2{margin:0 0 10px}.ready-list{display:flex;gap:10px;overflow-x:auto}.ready-card{min-width:170px;border-radius:12px;border:1px solid #ccead8;background:#e7fff1;padding:10px;display:flex;flex-direction:column;justify-content:flex-start;align-items:flex-start;gap:6px}.handover-button{min-height:40px;border-radius:10px;border:0;background:#2d7a4f;color:#fff;font-weight:800;padding:0 12px}.ready-card .handover-button{width:100%}.handover-readonly{color:#245c3d;font-size:12px;font-weight:700}.ready-card small{color:#245c3d;font-weight:700}.ready-card div{display:flex;flex-direction:column;align-items:flex-start;gap:2px}.cards-list{margin-top:12px;display:flex;flex-direction:column;gap:10px}.ticket-card,.item-card{border:1px solid var(--border);border-radius:14px;background:var(--panel);padding:12px}.item-card.lane-at_risk{border-color:#f0d4a6;background:#fff8ea}.item-card.lane-exceptions{border-color:#f0b7b7;background:#fff4f4}.item-card.lane-done{border-color:#d3d9e5;background:#f4f6fb}.manager-console{margin-top:12px;border:1px solid var(--border);border-radius:14px;background:var(--panel);padding:12px;display:flex;flex-direction:column;gap:10px}.manager-console-head{display:flex;justify-content:space-between;align-items:center;gap:8px}.manager-console-head h2{margin:0}.manager-console-summary{margin:0;color:var(--muted);font-size:13px}.trust-badge{border-radius:999px;padding:6px 12px;text-transform:uppercase;font-size:11px;font-weight:800}.trust-badge.healthy{background:#def6e9;color:#0f6b3d}.trust-badge.watch{background:#fff0d9;color:#825300}.trust-badge.critical{background:#ffe2e2;color:#9a1d1d}.manager-kpis{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:10px}.manager-actions{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:8px}.manager-actions button{min-height:44px;border-radius:10px;border:1px solid var(--border);background:#fff;color:var(--text);font-weight:700}.manager-actions button:disabled{opacity:.6}.device-health-console{border:1px solid var(--border);border-radius:12px;background:#fff;padding:10px;display:flex;flex-direction:column;gap:8px}.device-health-head{display:flex;justify-content:space-between;align-items:center;gap:8px}.device-health-head h3{margin:0}.device-health-head button{min-height:36px;border-radius:10px;border:1px solid var(--border);background:#fff;font-weight:700;padding:0 10px}.device-health-note{margin:0;padding:8px;border-radius:10px;background:#f4f6fb;font-size:12px;color:var(--muted)}.device-health-note code{display:block;margin-top:6px;background:#e8edf6;border-radius:8px;padding:6px;color:#1f1c18;word-break:break-all}.device-health-card{border:1px solid var(--border);border-radius:12px;background:#fff;padding:10px;display:flex;flex-direction:column;gap:8px}.device-health-card.status-online{border-color:#cde6d8}.device-health-card.status-degraded{border-color:#f0d4a6;background:#fff9ef}.device-health-card.status-offline,.device-health-card.status-disabled{border-color:#f0b7b7;background:#fff4f4}.device-health-main{display:flex;flex-direction:column;gap:4px}.device-health-main small{color:var(--muted)}.device-health-actions{display:grid;grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:8px}.device-health-actions button{min-height:36px;border-radius:10px;border:1px solid var(--border);background:#fff;font-weight:700}.exception-inbox{border:1px solid var(--border);border-radius:12px;background:#fff;padding:10px;display:flex;flex-direction:column;gap:8px}.exception-inbox-head{display:flex;justify-content:space-between;align-items:center;gap:8px}.exception-inbox-head h3{margin:0}.exception-inbox-head button{min-height:36px;border-radius:10px;border:1px solid var(--border);background:#fff;font-weight:700;padding:0 10px}.exception-card{border-radius:12px;border:1px solid var(--border);background:#fff;padding:10px;display:flex;flex-direction:column;gap:6px}.exception-card.severity-watch{border-color:#f0d4a6;background:#fff9ef}.exception-card.severity-critical{border-color:#f0b7b7;background:#fff4f4}.exception-card p{margin:0;font-size:13px}.exception-card-head{display:flex;justify-content:space-between;align-items:center;gap:8px}.exception-severity{border-radius:999px;padding:4px 8px;text-transform:uppercase;font-size:10px;font-weight:800}.exception-severity.severity-watch{background:#fff0d9;color:#825300}.exception-severity.severity-critical{background:#ffe2e2;color:#9a1d1d}.exception-card-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.exception-card-actions button{min-height:40px;border-radius:10px;border:1px solid var(--border);background:#fff;color:var(--text);font-weight:700}.routing-diagnostics{border:1px solid var(--border);border-radius:12px;background:#fff;padding:10px;display:flex;flex-direction:column;gap:8px}.routing-diagnostics-head{display:flex;align-items:center;justify-content:space-between;gap:8px}.routing-diagnostics-head h3{margin:0}.routing-diagnostics-head span{font-size:12px;color:var(--muted)}.routing-issue-card{border:1px solid var(--border);border-radius:10px;background:#fff;padding:8px;display:flex;flex-direction:column;gap:4px}.routing-issue-card strong{font-size:13px}.routing-issue-card small{color:var(--muted);font-size:12px}.routing-issue-card.routing-weak{border-color:#f0d4a6;background:#fff9ef}.routing-issue-card.routing-unrouted{border-color:#f0b7b7;background:#fff4f4}.ticket-card header{display:flex;justify-content:space-between;gap:10px}.ticket-card h3{margin:0}.ticket-card p{margin:4px 0 0;color:var(--muted);font-size:13px}.timer-block{display:flex;flex-direction:column;align-items:flex-end;gap:4px}.timer-block>span{font-size:24px;font-weight:800}.sla-chip{border-radius:999px;padding:4px 8px;font-size:11px;font-weight:700}.sla-chip.ok{background:#def6e9;color:var(--ok)}.sla-chip.warning{background:#fff0d9;color:var(--warn)}.sla-chip.late{background:#ffe2e2;color:var(--late)}.item-list{margin-top:10px;display:flex;flex-direction:column;gap:10px}.item-row,.item-card-main{border:1px solid var(--border);border-radius:12px;padding:8px;display:flex;flex-direction:column;gap:8px;background:#fff}.item-main{border:0;background:#fff;text-align:left;display:flex;flex-direction:column;gap:4px;color:var(--text);padding:2px}.item-main small{color:var(--muted);font-size:12px}.item-actions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.item-actions button{min-height:46px;border-radius:10px;border:0;background:#f2ebe0;color:var(--text);font-weight:800}.item-actions button:disabled{opacity:.5}.item-actions button:nth-child(1){background:#e5f5ed;color:#0f6b3d}.item-actions button:nth-child(2){background:#ffecc2;color:#8a5700}.item-actions button:nth-child(3){background:#ffe2e2;color:#9a1d1d}.group-drilldown{margin-top:10px;border-top:1px solid var(--border);padding-top:10px;display:flex;flex-direction:column;gap:8px}.group-row{border:1px solid var(--border);border-radius:10px;padding:8px;background:#fff;display:flex;flex-direction:column;gap:8px}.group-assist{margin-top:8px;border:1px dashed var(--border);border-radius:10px;padding:8px;background:#fff;display:flex;flex-direction:column;gap:6px}.group-assist span{color:var(--muted);font-size:12px}.detail-drawer{position:fixed;top:0;right:0;width:min(460px,96vw);height:100vh;background:#fff;border-left:1px solid var(--border);box-shadow:-20px 0 40px #0000001f;padding:16px;overflow-y:auto;z-index:30}.detail-header{display:flex;justify-content:space-between;align-items:center;gap:10px}.detail-header h3{margin:0}.detail-header button{min-height:44px;min-width:94px;border-radius:10px;border:0;background:#f2ebe0;font-weight:700}.detail-content{margin-top:12px;display:flex;flex-direction:column;gap:10px}.detail-content img{width:100%;border-radius:12px;border:1px solid var(--border);object-fit:cover;max-height:220px}.detail-content p{margin:0;line-height:1.35}.empty-state{color:var(--muted);margin:0}.error-panel{margin-top:12px;border-radius:12px;border:1px solid #f7c4c4;background:#fff0f0;padding:12px}@media(max-width:820px){.kds-shell{padding:10px}.kds-header{flex-direction:column}.header-controls{width:100%;justify-content:space-between}.mode-switch{width:100%}.mode-switch button{flex:1}.profile-switch{width:100%}.profile-switch button{flex:1;min-width:0}.item-actions button{min-height:52px}}
