/* Firmware and rollouts, and master data. */
.setup { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
.setup .phead > div:first-child { flex: 1 1 360px; }
.setup .table .main, .md-cols .table .sub { white-space: nowrap; }
.setup .table select.filter { min-height: 32px; }
.setup .table td.acts { width: 1%; }
.setup .table td .sub { margin-top: 2px; }
.setup fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.setup legend.eyebrow { padding: 0; margin-bottom: 10px; }

.fw-version { display: inline-flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.fw-upload form { display: flex; flex-direction: column; min-width: 0; }
.fw-upload .fields { grid-template-columns: minmax(0, 1fr); }
.fw-upload textarea { min-height: 64px; }
.fw-upload .field:has(> input[type="file"]) {
  padding: 16px; border: 1px dashed var(--field); border-radius: 8px; background: var(--bg);
}
.fw-file {
  padding: 12px 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg);
  font: 500 13px/18px var(--f-body); overflow-wrap: anywhere;
}
.fw-file:empty { display: none; }
.fw-checks { margin-top: 4px; }
.fw-checks > li { justify-content: flex-start; align-items: flex-start; }
.fw-checks .ic { color: var(--link); margin-top: 1px; }
.fw-checks li > span, .ro-left li > span:first-child, .ro-choice > label > span { display: flex; flex-direction: column; }
.fw-checks b, .ro-left b, .ro-choice b { font-weight: 600; }

.ro-choices { display: flex; flex-direction: column; gap: 10px; }
.ro-choice { padding: 14px 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); }
.ro-choice:has(input[name="rscope"]:checked) { background: var(--tint); border-color: var(--accent); }
.ro-choice > label { display: flex; align-items: center; gap: 14px; cursor: pointer; }
.ro-more { display: none; flex-direction: column; gap: 8px; margin: 12px 0 0 32px; }
.ro-choice:has(input[name="rscope"]:checked) .ro-more { display: flex; }
.ro-more .filterbar input { flex: 1; min-width: 0; }
.ro-window { display: flex; flex-direction: column; gap: 12px; }
.ro-windows { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.ro-custom { display: none; grid-template-columns: repeat(2, minmax(0, 180px)); gap: 12px; }
.ro-window:has(input[name="rwindow"][value="custom"]:checked) .ro-custom { display: grid; }
.ro-foot { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding-top: 16px; border-top: 1px solid var(--line); }
.ro-foot .grow { flex: 1; }
.ro-left .data { font-weight: 600; }

.ro-fill > svg { display: block; width: 100%; height: 100%; }
.ro-fill rect { fill: var(--accent); }
.ro-fill.ok rect { fill: var(--ok); }
.ro-bad { color: var(--bad-fg); }
.ro-version { font-weight: 600; }
.ro-detail { min-width: 9rem; }
.ro-stages { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 16px; }
.ro-stage { gap: 10px; padding: 16px; background: var(--bg); }
.ro-stage.now { border-color: var(--accent); }
.ro-stagehead { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.ro-stage h3 { font: 600 16px/24px var(--f-head); }
.ro-done { color: var(--ink-2); }
.ro-done .data { font: 600 20px/28px var(--f-data); color: var(--ink); margin-right: 2px; }
.ro-facts .kv { grid-template-columns: minmax(0, 1fr); }
.ro-facts .kv > div:last-child { border-bottom: 0; }
.ro-list { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }

.md-cols { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 24px; align-items: start; }
.md-nav { display: flex; flex-direction: column; gap: 2px; }
.md-nav > button {
  justify-content: space-between; width: 100%; min-height: 44px; padding: 0 12px; border: 0;
  background: transparent; color: var(--ink-2); font: 500 14px/20px var(--f-body); text-align: left;
}
.md-nav > button:hover { background: var(--hover); color: var(--ink); }
.md-nav > button[aria-current="true"] { background: var(--tint); color: var(--ink); font-weight: 600; }
.md-cols .card .form { margin: 0; padding: 0; background: none; border: 0; }

@media (max-width: 900px) {
  .fw-upload { order: -1; }
  .md-cols { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .md-nav { flex-direction: row; overflow-x: auto; border-bottom: 1px solid var(--line); scrollbar-width: none; }
  .md-nav > button { width: auto; flex: none; }
  .ro-more { margin-left: 0; }
}
