/* Scoped to Rotinas. Existing Office tokens, typography and controls are preserved. */
.routines-workspace .routines-layout{display:grid;grid-template-columns:240px minmax(0,1fr);gap:24px;align-items:start}
.routines-workspace .routine-palette{position:sticky;top:100px;min-width:0}
.routines-workspace h2{font-family:var(--font);font-size:18px;letter-spacing:-.02em;line-height:1.3}
.routines-workspace .routine-palette-list{display:grid;gap:12px;margin-top:20px}
.routines-workspace .routine-robot-card{display:flex;align-items:center;gap:12px;width:100%;min-height:84px;padding:16px;background:var(--raised);border:1px solid var(--border);border-radius:10px;text-align:left;cursor:grab}
.routines-workspace .routine-robot-card:active{cursor:grabbing}
.routines-workspace .routine-robot-card:hover,.routines-workspace .routine-robot-card.is-selected{border-color:var(--lime)}
.routines-workspace .routine-robot-card.is-selected>svg{color:var(--lime)}
.routines-workspace .routine-robot-card>svg{flex:none;color:var(--muted)}
.routines-workspace .routine-robot-card>span{min-width:0}
.routines-workspace .routine-robot-card strong{display:block;font-size:14px;font-weight:600;overflow-wrap:anywhere}
.routines-workspace .routine-robot-card small{display:block;margin-top:4px;color:var(--muted);font-size:12px;font-weight:400}
.routines-workspace .routine-drag-mark{margin-left:auto;color:var(--soft);font-size:20px}
.routines-workspace .routine-main{display:grid;gap:20px;min-width:0}
.routines-workspace .routine-canvas{display:grid;grid-template-columns:minmax(0,1fr) 24px minmax(0,1fr) 24px minmax(0,1fr);align-items:center;gap:8px;padding:24px 0;margin-top:12px;border-block:1px solid var(--border);background-image:radial-gradient(var(--border) .6px,transparent .6px);background-size:18px 18px}
.routines-workspace .routine-canvas-node{min-width:0;min-height:164px;padding:16px;background:var(--surface);border:1px solid var(--border);border-radius:12px}
.routines-workspace .routine-canvas-node>small{display:block;margin-top:12px;color:var(--muted);font-size:10px;letter-spacing:.09em}
.routines-workspace .routine-canvas-node h3{margin:8px 0;font-family:var(--font);font-size:15px;font-weight:600;line-height:1.4;letter-spacing:0;overflow-wrap:anywhere}
.routines-workspace .routine-canvas-node p{color:var(--muted);font-size:12px;line-height:1.5}
.routines-workspace .routine-node-icon{display:inline-flex;color:var(--muted)}
.routines-workspace .routine-robot-drop{border-style:dashed}
.routines-workspace .routine-robot-drop.has-robot{border-color:var(--lime);border-style:solid}
.routines-workspace .routine-robot-drop.has-robot .routine-node-icon{color:var(--lime)}
.routines-workspace .routine-robot-drop[data-drag-over=true],.routines-workspace .routine-robot-drop.is-drag-over{outline:2px solid var(--lime);outline-offset:4px}
.routines-workspace .routine-canvas-node.has-results .routine-node-icon{color:var(--success)}
.routines-workspace .routine-connector{text-align:center;color:var(--muted);font-size:24px}
.routines-workspace .routine-setup{margin-top:24px;max-width:640px}
.routines-workspace .routine-setup>.form{margin-top:20px}
.routines-workspace .routine-credentials{margin-bottom:20px}
.routines-workspace .requires-connection .form button[type=submit]{color:#171b09;background:var(--lime);border-color:var(--lime)}
.routines-workspace details>summary{cursor:pointer;min-height:44px;align-content:center;font-size:13px;font-weight:600;line-height:1.5}
.routines-workspace details>.form,.routines-workspace details>.list{margin-top:16px}
.routines-workspace .routine-quantity{display:flex;align-items:end;gap:12px}
.routines-workspace .routine-quantity label{flex:0 1 160px;min-width:0}
.routines-workspace .routine-lead-options{display:grid;gap:4px;max-height:260px;overflow:auto;margin:8px 0 0;padding:0;border:0}
.routines-workspace .routine-lead-options label,.routines-workspace .routine-consent{display:flex;align-items:center;gap:10px;min-height:44px;font-size:13px;font-weight:400}
.routines-workspace .routine-lead-options input,.routines-workspace .routine-consent input{width:18px;min-height:18px;height:18px;flex:none;margin:0;accent-color:var(--lime)}
.routines-workspace .routine-lead-options label>span{overflow-wrap:anywhere}
.routines-workspace .routine-models{display:flex;gap:16px;flex-wrap:wrap;font-size:12px;color:var(--lime);margin:12px 0 20px}
.routines-workspace .routine-secondary{margin-top:20px;border-top:1px solid var(--border);padding-top:8px}
.routines-workspace .routine-results{margin-top:24px;min-width:0}
.routines-workspace .routine-results-scroll{max-width:100%;overflow:auto;border-top:1px solid var(--border)}
.routines-workspace .routine-results table{width:100%;min-width:620px;border-collapse:collapse;font-size:13px}
.routines-workspace .routine-results th,.routines-workspace .routine-results td{text-align:left;padding:16px 12px;border-bottom:1px solid var(--border);vertical-align:top;max-width:240px;overflow-wrap:anywhere}
.routines-workspace .routine-results th{color:var(--muted);font-size:12px;font-weight:500}
.routines-workspace .routine-results td:first-child{font-weight:600}
.routines-workspace .routine-results td:nth-child(2){font-variant-numeric:tabular-nums;white-space:nowrap}
.routines-workspace .routine-protocol{display:block;max-width:200px;overflow-wrap:anywhere;color:var(--muted);font-size:12px}
.routines-workspace .routine-tracking{display:flex;align-items:center;gap:16px;flex-wrap:wrap;margin-bottom:20px}
.routines-workspace .routine-tracking>div{flex:1;min-width:180px}
.routines-workspace .routine-tracking .note{margin-top:6px}
.routines-workspace .routine-advanced,.routines-workspace .routine-history{margin-top:16px}
.routines-workspace .routine-advanced .surface{border:0;padding-inline:0}
@media(max-width:1080px){.routines-workspace .routines-layout{grid-template-columns:1fr}.routines-workspace .routine-palette{position:static}.routines-workspace .routine-palette-list{grid-template-columns:repeat(2,minmax(0,1fr))}.routines-workspace .routine-robot-card{min-height:74px}.routines-workspace .routine-secondary{margin-top:12px}}
@media(max-width:680px){.routines-workspace .routine-canvas{grid-template-columns:1fr;gap:8px;padding:20px 0}.routines-workspace .routine-canvas-node{min-height:0;padding:16px;display:grid;grid-template-columns:28px minmax(0,1fr);column-gap:14px;align-items:center}.routines-workspace .routine-node-icon{grid-row:1 / 4;align-self:center}.routines-workspace .routine-canvas-node>small{margin:0}.routines-workspace .routine-canvas-node h3{margin:4px 0}.routines-workspace .routine-canvas-node p{grid-column:2}.routines-workspace .routine-connector{font-size:20px;line-height:24px;transform:rotate(90deg)}.routines-workspace .routine-robot-card{padding:12px;gap:8px}.routines-workspace .routine-robot-card strong{font-size:13px}.routines-workspace .routine-robot-card small{font-size:11px}.routines-workspace .routine-drag-mark{display:none}.routines-workspace .routine-quantity{align-items:stretch;flex-direction:column;gap:8px}.routines-workspace .routine-quantity label{flex:auto}.routines-workspace .routine-run-form input,.routines-workspace .routine-run-form select{font-size:16px}.routines-workspace .routine-results table{min-width:560px}.routines-workspace .routine-results th,.routines-workspace .routine-results td{padding:12px 10px}.routines-workspace .routine-tracking .button{width:100%}}
