/* featureos:scheduled-reports-module@1.0.6 */
/* Scheduled reports. Uses the app's own tokens only; renders inside #view, with no shell, max-width or background of its own. */
.sr-count{margin:0 0 10px}
.sr-tabs{margin-bottom:16px}
.segmented{display:inline-flex;gap:2px;padding:3px;border:1px solid var(--line);border-radius:12px;background:var(--surface-2);max-width:100%;flex-wrap:wrap}
.segmented .seg{border:0;background:none;color:var(--ink-2);font:inherit;font-weight:600;padding:7px 14px;border-radius:9px;cursor:pointer;text-decoration:none;min-height:34px;display:inline-flex;align-items:center}
.segmented .seg:hover{color:var(--brand)}
.segmented .seg[aria-selected=true],.segmented .seg[aria-checked=true]{background:var(--surface);color:var(--brand);box-shadow:var(--shadow-1)}
.segmented .seg[disabled]{opacity:.55;cursor:not-allowed}
.sr-starts{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,230px),1fr));gap:12px;margin-top:6px}
.sr-start{display:flex;flex-direction:column;gap:4px;padding:14px;border:1px solid var(--line);border-radius:12px;background:var(--surface-2);color:var(--ink);text-decoration:none}
.sr-start:hover{border-color:var(--brand-line);background:var(--brand-soft)}.sr-start span{color:var(--mut);font-size:13px}

/* builder: two columns that collapse to one, nothing a fixed pixel width */
.sr-mode{display:none;margin-bottom:12px}
.sr-grid{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,1fr);gap:18px;align-items:start}
.sr-form{display:flex;flex-direction:column;gap:16px;min-width:0}
.sr-form .card{margin-bottom:0}
.sr-preview{position:sticky;top:76px;min-width:0;display:flex;flex-direction:column;gap:10px}
.sr-ptabs{align-self:flex-start}
.sr-frame{display:block;width:100%;height:min(640px,68vh);border:1px solid var(--line);border-radius:12px;background:var(--surface)}
.sr-wait{padding:36px 12px;text-align:center;border:1px dashed var(--line-strong);border-radius:12px}
.sr-sample{margin:0}
.sr-progress{display:flex;gap:8px;flex-wrap:wrap}
.sr-progress a{display:flex;align-items:center;gap:8px;padding:8px 12px;border:1px solid var(--line);border-radius:12px;background:var(--surface);color:var(--ink-2);text-decoration:none;font-weight:600;flex:1 1 150px;min-width:0}
.sr-progress small{display:block;font-weight:500;color:var(--mut);font-size:12px}
.sr-progress .dot{display:grid;place-items:center;width:24px;height:24px;border-radius:50%;background:var(--neutral-soft);color:var(--ink-2);font-size:12px;flex:none}.sr-progress .dot svg{width:13px;height:13px}
.sr-progress a.done .dot{background:var(--ok-soft);color:var(--ok)}.sr-progress a.done small{color:var(--ok)}
.sr-step h2{font-size:17px;margin-bottom:4px}.sr-step>p.muted{margin:0 0 14px}
.chipbox{display:flex;flex-wrap:wrap;gap:6px;padding:8px;border:1px solid var(--line-strong);border-radius:12px;background:var(--surface);min-height:46px}
.chipbox:focus-within{border-color:var(--brand);box-shadow:0 0 0 4px color-mix(in srgb,var(--brand) 18%,transparent)}
.chipbox input{border:0;box-shadow:none;flex:1 1 180px;min-width:140px;min-height:30px;padding:2px 6px;background:none}.chipbox input:focus{box-shadow:none}
.sr-chip{display:inline-flex;align-items:center;gap:4px;padding:2px 4px 2px 10px;border-radius:999px;background:var(--brand-soft);border:1px solid var(--brand-line);color:var(--side-active-ink);font-size:13px;font-weight:600;max-width:100%}
.sr-chip>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.sr-chip em{font-style:normal;font-weight:500;color:var(--mut)}
.sr-chip.is-stopped{background:var(--neutral-soft);border-color:var(--line-strong);color:var(--mut)}
.sr-chip button{border:0;background:none;color:inherit;width:22px;height:22px;border-radius:50%;cursor:pointer;font-size:16px;line-height:1}.sr-chip button:hover{background:color-mix(in srgb,currentColor 14%,transparent)}
.sr-suggest{margin-top:8px;display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.sr-err{margin:6px 0 0;padding:8px 12px;border-radius:10px;background:var(--bad-soft);color:var(--bad);font-weight:600;font-size:13.5px}
.sr-summary{padding:12px 14px;border-radius:12px;background:var(--bad-soft);color:var(--bad);border:1px solid color-mix(in srgb,var(--bad) 35%,transparent)}.sr-summary a{color:inherit;font-weight:700}.sr-summary[hidden]{display:none}
.days{display:flex;gap:6px;flex-wrap:wrap}.days .seg{border:1px solid var(--line-strong);background:var(--surface);border-radius:10px;min-width:48px;justify-content:center;padding:7px 10px;font:inherit;font-weight:600;cursor:pointer;color:var(--ink-2)}
.days .seg[aria-checked=true]{background:var(--brand);color:var(--brand-ink);border-color:var(--brand)}
.sr-time input{max-width:180px}
.sr-next{margin-top:14px;padding:12px 14px;border:1px solid var(--line);border-radius:12px;background:var(--surface-2)}
.sr-next p{margin:0 0 6px}.sr-next ol{margin:0;padding-left:20px;display:grid;gap:4px}.sr-next li span{display:block;font-size:12.5px}
.sr-group{border:1px solid var(--line);border-radius:12px;margin:0 0 12px;padding:6px 12px 8px}.sr-group legend{font-size:11px;letter-spacing:.08em;text-transform:uppercase;font-weight:700;color:var(--mut);padding:0 6px}
.sr-tick,.sr-check{display:flex;gap:10px;align-items:flex-start;padding:9px 4px;cursor:pointer;border-radius:10px}.sr-tick:hover,.sr-check:hover{background:var(--surface-2)}
.sr-tick small,.sr-check small{display:block;color:var(--ink-2);font-weight:400;font-size:13px;margin-top:2px}
.sr-lock{font-size:11px;font-weight:700;color:var(--warn);background:var(--warn-soft);border-radius:999px;padding:1px 8px;margin-left:6px;white-space:nowrap}
.sr-bd{margin-top:10px;padding-top:10px;border-top:1px dashed var(--line-strong)}
.xl-tag{font-size:11px;font-weight:700;color:var(--ok);background:var(--ok-soft);border-radius:999px;padding:1px 8px;margin-left:6px}
.sr-line{margin:12px 0 0;padding:10px 12px;border-radius:10px;background:var(--brand-soft);color:var(--side-active-ink);font-weight:600}.sr-line:empty{display:none}
fieldset.plain.sr-steps{display:flex;flex-direction:column;gap:16px;min-width:0}
fieldset.field{border:0;padding:0}.sr-steps legend.label{font-weight:600;font-size:13px;margin-bottom:6px;color:var(--ink-2);padding:0}

/* the save bar sits in the flow at the foot of the page and sticks to the bottom edge, so nothing is ever hidden behind it */
.sr-bar{position:sticky;bottom:0;z-index:30;display:flex;gap:12px;align-items:center;justify-content:space-between;flex-wrap:wrap;margin-top:18px;padding:12px 16px;border:1px solid var(--line);border-radius:14px;background:var(--surface);box-shadow:var(--shadow-2)}
.sr-status{display:flex;align-items:center;gap:8px;flex-wrap:wrap;min-width:0;font-weight:600}.sr-status small{font-weight:500}
.sr-dot{width:9px;height:9px;border-radius:50%;background:var(--warn)}
.sr-actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.sr-why{font-size:13px;color:var(--ink-2)}.sr-why:empty{display:none}

/* spreadsheet preview */
.sr-sheet{border:1px solid var(--line);border-radius:12px;overflow:hidden;background:var(--surface)}
.sr-grid-wrap{overflow-x:auto;overflow-y:visible} /* part 116: the page scrolls, the workbook does not; a table wider than the card still scrolls sideways inside itself */
#sr-preview{overflow-anchor:none} /* the browser never nudges the page when a sheet of another height replaces this one (part 113) */
.sr-sheettabs{scroll-behavior:auto;position:relative} /* position:relative makes the strip the offset parent, so a tab's offsetLeft is measured inside the strip (part 114) */
.sr-xl{border-collapse:collapse;font-size:12.5px;width:max-content;min-width:100%}
.sr-xl th,.sr-xl td{border:1px solid var(--line);padding:5px 9px;white-space:nowrap;max-width:320px;overflow:hidden;text-overflow:ellipsis;text-align:left}
.sr-xl thead th{position:sticky;top:0;background:var(--brand-soft);font-weight:700;color:var(--ink)}
.sr-xl .rn{background:var(--surface-2);color:var(--mut);text-align:center;width:36px;min-width:36px}
.sr-xl td.num{text-align:right;font-variant-numeric:tabular-nums}
.sr-sheettabs{display:flex;gap:2px;overflow-x:auto;padding:6px 8px 0;background:var(--surface-2);border-top:1px solid var(--line)}
.sr-sheettabs button{border:1px solid var(--line);border-bottom:0;background:var(--neutral-soft);color:var(--ink-2);font:inherit;font-size:12.5px;padding:5px 12px;border-radius:8px 8px 0 0;cursor:pointer;white-space:nowrap}
.sr-sheettabs button[aria-selected=true]{background:var(--surface);color:var(--ink);font-weight:700}

@media (max-width:1000px){.sr-grid{grid-template-columns:minmax(0,1fr)}.sr-preview{position:static}}
@media (max-width:640px){
  .sr-mode{display:inline-flex}.sr-grid[data-mode=form] .sr-preview{display:none}.sr-grid[data-mode=preview] .sr-form{display:none}
  .sr-status{display:none}.sr-bar{padding:10px}.sr-actions{width:100%}.sr-actions .btn.primary{flex:1}
}
@media (pointer:coarse){.sr-tick,.sr-check{min-height:44px}.sr-chip button{width:32px;height:32px}.days .seg,.segmented .seg{min-height:44px}}

.sr-see{margin:4px 0 0;font-size:13px;overflow-wrap:anywhere}.sr-see .sr-base{color:var(--ink)}.sr-see .sr-added{color:var(--brand);font-weight:600}.sr-cadnote{color:var(--brand)}.sr-board{height:640px}
