/* STRUCTURAL SURVEY — on site and on a PC (Reports phase B2, 28/10/2026; designs SvSetup,
   SvRoomTab, SvRoomPhone, SvCamera, SvMatrix). Its own sheet, loaded by the survey views
   only, on the shared tokens (tokens/*.css) so light and dark follow the theme. The
   camera is black in both themes, as a viewfinder is. */

.svy-shell { position: fixed; inset: 0; z-index: 900; background: var(--ground); color: var(--ink); font-family: var(--font-sans);
  display: flex; flex-direction: column; overflow: hidden; -webkit-text-size-adjust: 100%; }
.svy-shell * { box-sizing: border-box; }
.svy-shell button { font: inherit; }
.svy-head { flex: 0 0 auto; display: flex; align-items: center; gap: 14px; padding: calc(10px + env(safe-area-inset-top, 0px)) 20px 10px;
  border-bottom: 1px solid var(--hair); background: var(--surface); }
.svy-back { appearance: none; border: 0; background: none; color: var(--link); cursor: pointer; display: inline-flex; align-items: center; gap: 4px;
  font-size: 15px; min-height: 44px; padding: 0 6px 0 0; white-space: nowrap; }
.svy-titles { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.svy-title { font-size: 17px; font-weight: var(--weight-medium); letter-spacing: -0.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.svy-sub { font-size: 12.5px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* P6 (phone review 29/10/2026): sync is quiet. Saved, waiting and uploading are grey;
   only a paused upload that needs a tap, or a Google connection, is in the attention colour. */
.svy-sync { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--ink-3, var(--m-ink3)); white-space: nowrap; }
.svy-sync.wait { color: var(--ink-3, var(--m-ink3)); }
.svy-sync.err { color: var(--status-error); }
.svy-sync-retry { font-weight: 500; }
.svy-sync button { appearance: none; border: 0; background: none; color: var(--link); cursor: pointer; font-size: 13px; padding: 0; min-height: 32px; }
.svy-btn { appearance: none; border: 1px solid var(--hair-strong); background: var(--surface); color: var(--ink); border-radius: 12px; min-height: 44px;
  padding: 0 16px; font-size: 14.5px; font-weight: var(--weight-medium); cursor: pointer; white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.svy-btn:hover { background: var(--nav-hover); }
.svy-btn.primary { background: var(--ink-fill); border-color: var(--ink-fill); color: var(--ink-fill-ink); }
.svy-btn.primary:hover { opacity: 0.92; }
.svy-btn[disabled] { opacity: 0.45; cursor: default; }
.svy-link { appearance: none; border: 0; background: none; color: var(--link); cursor: pointer; padding: 0; font-size: 13.5px; min-height: 32px; }
.svy-caps { font-size: 11.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-3); font-weight: var(--weight-medium); }
.svy-muted { color: var(--ink-2); }
.svy-small { font-size: 12.5px; color: var(--ink-2); line-height: 1.45; }

/* ── Segmented controls and chips ── */
.svy-seg { display: inline-flex; gap: 2px; padding: 3px; border-radius: 12px; background: var(--surface-sunk); flex-wrap: nowrap; max-width: 100%; }
.svy-seg button { appearance: none; border: 0; background: transparent; border-radius: 9px; min-height: 38px; padding: 0 14px; font-size: 14px; cursor: pointer;
  color: var(--ink-2); white-space: nowrap; }
.svy-seg button.on { background: var(--surface); color: var(--ink); font-weight: var(--weight-medium); box-shadow: 0 1px 2px rgba(12,17,57,0.12); }
.svy-seg.status button.on.defect { color: var(--status-overdue-ink); }
.svy-seg.status button.on.ok { color: var(--status-ok-ui); }
.svy-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.svy-chip { appearance: none; border: 1px solid var(--hair-strong); background: var(--surface); border-radius: 999px; min-height: 40px; padding: 0 14px;
  font-size: 14px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; color: var(--ink); }
.svy-chip.on { background: var(--ink-fill); border-color: var(--ink-fill); color: var(--ink-fill-ink); }
.svy-chip.add { border-style: dashed; color: var(--link); }
.svy-chip .x { opacity: 0.7; font-size: 15px; }
.svy-select { appearance: none; border: 1px solid var(--hair-strong); background: var(--surface); color: var(--ink); border-radius: 10px; min-height: 38px;
  padding: 0 28px 0 10px; font-size: 13.5px; background-image: linear-gradient(45deg, transparent 50%, var(--ink-2) 50%), linear-gradient(135deg, var(--ink-2) 50%, transparent 50%);
  background-position: calc(100% - 15px) 50%, calc(100% - 10px) 50%; background-size: 5px 5px; background-repeat: no-repeat; }
.svy-input, .svy-text { width: 100%; border: 1px solid var(--hair-strong); background: var(--surface); color: var(--ink); border-radius: 10px; font: inherit; font-size: 15px; padding: 10px 12px; }
.svy-text { min-height: 72px; resize: vertical; line-height: 1.45; }
.svy-input:focus-visible, .svy-text:focus-visible, .svy-select:focus-visible { border-color: var(--link); }

/* ── SvSetup ── */
.svy-setup { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(300px, 372px) minmax(0, 1fr); }
.svy-setup-left { border-right: 1px solid var(--hair); background: var(--surface-tint); padding: 20px 22px 40px; overflow-y: auto; display: flex; flex-direction: column; gap: 20px; }
.svy-setup-right { padding: 20px 22px 60px; overflow-y: auto; }
.svy-field { display: flex; flex-direction: column; gap: 10px; }
.svy-field-label { font-size: 13.5px; color: var(--ink-2); }
.svy-pair { display: flex; gap: 22px; flex-wrap: wrap; }
.svy-writes { border-top: 1px solid var(--hair); padding-top: 14px; font-size: 13px; line-height: 1.5; color: var(--ink-2); }
.svy-writes textarea { margin-top: 8px; font-size: 13.5px; }
.svy-walk-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.svy-walk-head b { font-weight: var(--weight-medium); font-size: 14.5px; }
.svy-group-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 0 6px; border-bottom: 1px solid var(--hair); }
.svy-rows { list-style: none; margin: 0; padding: 0; }
.svy-row { display: flex; align-items: center; gap: 10px; min-height: 46px; border-bottom: 1px solid var(--hair-soft); background: var(--ground); }
.svy-row.dragging { opacity: 0.6; background: var(--blue-tint); }
.svy-handle { appearance: none; border: 0; background: none; color: var(--ink-3); cursor: grab; width: 28px; min-height: 44px; font-size: 14px; touch-action: none; }
.svy-num { width: 22px; text-align: right; font-size: 13px; color: var(--ink-3); flex: 0 0 22px; }
.svy-row-main { flex: 1; min-width: 0; display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; }
.svy-name { border: 0; background: transparent; color: var(--ink); font: inherit; font-size: 15px; padding: 4px 0; min-width: 6ch; max-width: 100%; field-sizing: content; }
.svy-name:focus-visible { background: var(--surface); box-shadow: inset 0 -1px 0 var(--link); }
.svy-row-sub { font-size: 12.5px; color: var(--ink-2); }
.svy-x { appearance: none; border: 0; background: none; color: var(--ink-3); cursor: pointer; width: 36px; min-height: 44px; font-size: 16px; }
.svy-add-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding-top: 16px; }
.svy-brief { border: 1px solid var(--hair); border-radius: 14px; padding: 14px 16px; background: var(--surface); display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
.svy-brief label { display: flex; align-items: center; gap: 10px; min-height: 36px; font-size: 14.5px; }
.svy-empty { border: 1px dashed var(--hair-strong); border-radius: 14px; padding: 22px; display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }

/* ── The area list (SvRoomTab left, the phone's drawer) ── */
.svy-walk { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(250px, 280px) minmax(0, 1fr); }
.svy-list { border-right: 1px solid var(--hair); background: var(--surface-tint); overflow-y: auto; padding: 8px 0 30px; }
.svy-list-group { display: flex; justify-content: space-between; padding: 14px 18px 6px; }
.svy-li { appearance: none; border: 0; background: transparent; width: 100%; text-align: left; cursor: pointer; display: flex; align-items: center; gap: 12px;
  min-height: 44px; padding: 0 18px; font-size: 14.5px; color: var(--ink); border-left: 3px solid transparent; }
.svy-li:hover { background: var(--nav-hover); }
.svy-li.on { background: var(--surface); border-left-color: var(--ink-fill); font-weight: var(--weight-medium); }
.svy-li-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.svy-li-n { font-size: 12.5px; color: var(--ink-3); }
.svy-dot { flex: 0 0 18px; width: 18px; height: 18px; border-radius: 999px; border: 1.5px solid var(--hair-strong); display: inline-flex; align-items: center; justify-content: center; color: var(--surface); font-size: 11px; }
.svy-dot.done { background: var(--status-ok-ui); border-color: var(--status-ok-ui); }
.svy-dot.defect { background: var(--status-overdue-ink); border-color: var(--status-overdue-ink); }
.svy-dot.partial { border-color: var(--status-overdue-ink); }
.svy-dot.notSeen { border-color: var(--ink-3); background: repeating-linear-gradient(135deg, var(--ink-3) 0 1.5px, transparent 1.5px 4px); }
.svy-dot.here { border: 5px solid var(--ink-fill); background: var(--surface); }

/* ── An area, element by element ── */
.svy-area { min-height: 0; display: flex; flex-direction: column; }
.svy-area-scroll { flex: 1; min-height: 0; overflow-y: auto; padding: 18px 22px 24px; display: flex; flex-direction: column; gap: 12px; }
.svy-area-top { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.svy-crumb { font-size: 12.5px; color: var(--ink-2); }
.svy-area-title { margin: 2px 0 0; font-size: var(--text-h2); font-weight: var(--weight-medium); letter-spacing: -0.02em; }
.svy-prevnext { display: flex; gap: 8px; }
.svy-el { border: 1px solid var(--hair); border-radius: 14px; background: var(--surface); padding: 14px; display: grid; grid-template-columns: minmax(130px, 150px) minmax(0, 1fr); gap: 8px 14px; }
.svy-el.current { border-color: var(--line-blue); box-shadow: 0 0 0 1px var(--line-blue); }
.svy-el-label { font-size: 16px; font-weight: var(--weight-medium); }
.svy-el-desc { border: 0; background: transparent; color: var(--ink-2); font: inherit; font-size: 12.5px; padding: 2px 0; width: 100%; }
.svy-el-right { min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.svy-el-line { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.svy-el-words { font-size: 14px; color: var(--ink-2); flex: 1; min-width: 12ch; }
.svy-note { border: 1px solid var(--hair); border-radius: 12px; padding: 10px 12px; background: var(--ground); display: flex; flex-direction: column; gap: 4px; }
.svy-note textarea { border: 0; background: transparent; color: var(--ink); font: inherit; font-size: 15px; line-height: 1.45; resize: none; min-height: 46px; padding: 0; width: 100%; }
.svy-note-src { font-size: 12px; color: var(--ink-3); display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.svy-suggest { border-left: 3px solid var(--line-blue); padding: 6px 10px; font-size: 14px; display: flex; flex-direction: column; gap: 6px; }
.svy-meas { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.svy-meas .svy-chip { min-height: 32px; font-size: 13px; }
.svy-meas input { flex: 1; min-width: 14ch; border: 0; border-bottom: 1px dashed var(--hair-strong); background: transparent; color: var(--ink); font: inherit; font-size: 13.5px; padding: 6px 2px; }
.svy-photos { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.svy-thumb { position: relative; width: 60px; height: 60px; border-radius: 8px; overflow: hidden; background: var(--surface-sunk); flex: 0 0 60px; }
.svy-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.svy-thumb .fig { position: absolute; left: 3px; bottom: 3px; min-width: 16px; height: 16px; border-radius: 4px; background: rgba(12,17,57,0.78); color: #F5F5F5;
  font-size: 10.5px; display: flex; align-items: center; justify-content: center; padding: 0 3px; }
.svy-thumb .up { position: absolute; right: 3px; top: 3px; width: 8px; height: 8px; border-radius: 999px; background: var(--attn-ink); box-shadow: 0 0 0 2px var(--surface); }
.svy-addph { appearance: none; width: 60px; height: 60px; border-radius: 8px; border: 1.5px dashed var(--hair-strong); background: transparent; color: var(--ink-2); cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center; }
.svy-mic { appearance: none; border: 1px solid var(--hair-strong); background: var(--surface); color: var(--ink); border-radius: 999px; min-height: 36px; padding: 0 12px;
  display: inline-flex; align-items: center; gap: 6px; font-size: 13px; cursor: pointer; touch-action: none; user-select: none; -webkit-user-select: none; }
.svy-mic.on { background: var(--attn-ink); border-color: var(--attn-ink); color: #FFFFFF; }
.svy-foot { flex: 0 0 auto; display: flex; align-items: center; gap: 12px; padding: 12px 22px calc(12px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--hair); background: var(--surface); flex-wrap: wrap; }
.svy-photo-btn { appearance: none; border: 0; background: var(--ink-fill); color: var(--ink-fill-ink); border-radius: 999px; min-height: 48px; padding: 6px 20px 6px 16px;
  display: inline-flex; align-items: center; gap: 12px; cursor: pointer; text-align: left; }
.svy-photo-btn small { display: block; font-size: 11.5px; opacity: 0.8; }
.svy-foot-note { flex: 1; min-width: 14ch; font-size: 12.5px; color: var(--ink-2); }
.svy-whole { border: 1px dashed var(--hair-strong); border-radius: 14px; padding: 14px; display: flex; flex-direction: column; gap: 10px; }

/* ── Phone (SvRoomPhone) ── */
.svy-shell.phone .svy-head { padding-left: 16px; padding-right: 16px; }
.svy-shell.phone .svy-setup { display: block; overflow-y: auto; }
.svy-shell.phone .svy-setup-left { border-right: 0; border-bottom: 1px solid var(--hair); overflow: visible; padding: 16px; }
.svy-shell.phone .svy-setup-right { overflow: visible; padding: 16px 16px 120px; }
.svy-shell.phone .svy-walk { display: block; position: relative; }
.svy-shell.phone .svy-list { position: fixed; inset: 0 22% 0 0; z-index: 3; transform: translateX(-102%); transition: transform var(--dur-fast) var(--ease-out);
  box-shadow: 0 0 40px rgba(12,17,57,0.25); padding-top: calc(12px + env(safe-area-inset-top, 0px)); }
.svy-shell.phone .svy-list.open { transform: none; }
.svy-scrim { position: fixed; inset: 0; z-index: 2; background: rgba(12,17,57,0.32); }
.svy-shell.phone .svy-area { height: 100%; }
.svy-shell.phone .svy-area-scroll { padding: 12px 16px 120px; }
.svy-shell.phone .svy-el { grid-template-columns: 1fr; padding: 12px; }
.svy-shell.phone .svy-seg { width: 100%; }
.svy-shell.phone .svy-seg button { flex: 1; padding: 0 6px; font-size: 13.5px; }
.svy-phead { display: flex; align-items: center; gap: 10px; }
.svy-round { appearance: none; width: 44px; height: 44px; border-radius: 999px; border: 1px solid var(--hair); background: var(--surface); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; flex: 0 0 44px; font-size: 18px; color: var(--ink); }
.svy-dashes { display: flex; gap: 3px; margin-top: 8px; }
.svy-dashes span { flex: 1; height: 3px; border-radius: 2px; background: var(--hair); }
.svy-dashes span.done { background: var(--status-ok-ui); }
.svy-dashes span.defect { background: var(--status-overdue-ink); }
.svy-dashes span.notSeen { background: var(--ink-3); }
.svy-dashes span.here { background: var(--ink-fill); }
.svy-collapsed { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 52px; padding: 0 14px; border: 1px solid var(--hair); border-radius: 14px; background: var(--surface);
  appearance: none; width: 100%; text-align: left; cursor: pointer; font-size: 15px; color: var(--ink); }
.svy-pill { font-size: 12.5px; border-radius: 999px; padding: 4px 10px; background: var(--ok-tint); color: var(--status-ok-ui); }
.svy-pill.defect { background: var(--status-overdue-bg); color: var(--status-overdue-ink); }
.svy-pill.notSeen { background: var(--surface-sunk); color: var(--ink-2); }
.svy-fab { position: fixed; right: 18px; bottom: calc(92px + env(safe-area-inset-bottom, 0px)); width: 60px; height: 60px; border-radius: 999px; border: 0; z-index: 2;
  background: var(--ink-fill); color: var(--ink-fill-ink); box-shadow: 0 6px 20px rgba(12,17,57,0.3); cursor: pointer; display: flex; align-items: center; justify-content: center; }
.svy-shell.phone .svy-foot { position: fixed; left: 0; right: 0; bottom: 0; padding: 10px 16px calc(14px + env(safe-area-inset-bottom, 0px)); flex-wrap: nowrap; }
.svy-shell.phone .svy-foot .svy-btn { flex: 1; }

/* ── The camera (SvCamera) — black in both themes ── */
.svy-cam { position: fixed; inset: 0; z-index: 950; background: #000; color: #F5F5F5; display: flex; flex-direction: column; }
.svy-cam-top { padding: calc(10px + env(safe-area-inset-top, 0px)) 16px 8px; display: flex; flex-direction: column; gap: 10px; background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0)); position: absolute; left: 0; right: 0; top: 0; z-index: 2; }
.svy-cam-row { display: flex; align-items: center; gap: 8px; }
.svy-cam-row .svy-back { color: #F5F5F5; }
.svy-cam-chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
.svy-cam-chip { appearance: none; border: 0; border-radius: 999px; min-height: 36px; padding: 0 14px; font-size: 13.5px; white-space: nowrap; cursor: pointer;
  background: rgba(255,255,255,0.22); color: #F5F5F5; }
.svy-cam-chip.on { background: #FFFFFF; color: #0C1139; font-weight: var(--weight-medium); }
.svy-cam-view { flex: 1; min-height: 0; position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.svy-cam-view video { width: 100%; height: 100%; object-fit: cover; }
.svy-cam-hint { position: absolute; left: 16px; right: 16px; bottom: 16px; background: rgba(12,17,57,0.72); border-radius: 12px; padding: 10px 14px; font-size: 13.5px; line-height: 1.4; }
.svy-cam-said { position: absolute; left: 16px; right: 16px; bottom: 16px; background: rgba(255,80,1,0.92); border-radius: 12px; padding: 10px 14px; font-size: 14.5px; line-height: 1.4; }
.svy-cam-bar { flex: 0 0 auto; display: flex; align-items: center; justify-content: space-between; padding: 16px 28px calc(20px + env(safe-area-inset-bottom, 0px)); }
.svy-cam-last { position: relative; width: 52px; height: 52px; border-radius: 10px; overflow: hidden; background: #222; border: 2px solid #F5F5F5; }
.svy-cam-last img { width: 100%; height: 100%; object-fit: cover; }
.svy-cam-last b { position: absolute; top: -2px; right: -2px; min-width: 20px; height: 20px; border-radius: 999px; background: #FF5001; color: #FFF; font-size: 11.5px; display: flex; align-items: center; justify-content: center; font-weight: 500; }
.svy-shutter { appearance: none; width: 74px; height: 74px; border-radius: 999px; border: 4px solid #F5F5F5; background: #FFFFFF; box-shadow: inset 0 0 0 4px #000; cursor: pointer; }
.svy-cam-mic { appearance: none; width: 52px; height: 52px; border-radius: 999px; border: 0; background: rgba(255,255,255,0.18); color: #F5F5F5; cursor: pointer; display: flex; align-items: center; justify-content: center; touch-action: none; user-select: none; -webkit-user-select: none; }
.svy-cam-mic.on { background: #FF5001; }
.svy-cam-file { appearance: none; border: 2px solid #F5F5F5; background: transparent; color: #F5F5F5; border-radius: 14px; min-height: 52px; padding: 0 22px; font-size: 16px; cursor: pointer; }

/* ── Sheets (compile, area not seen) ── */
.svy-sheet-scrim { position: fixed; inset: 0; z-index: 960; background: rgba(12,17,57,0.4); display: flex; align-items: flex-end; justify-content: center; }
.svy-sheet { width: min(560px, 100%); max-height: 88vh; overflow-y: auto; background: var(--surface); color: var(--ink); border-radius: 18px 18px 0 0; padding: 20px 20px calc(20px + env(safe-area-inset-bottom, 0px));
  display: flex; flex-direction: column; gap: 12px; }
.svy-sheet h2 { margin: 0; font-size: 19px; font-weight: var(--weight-medium); letter-spacing: -0.01em; }
.svy-check { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; border-bottom: 1px solid var(--hair-soft); font-size: 14px; }
.svy-check i { flex: 0 0 10px; height: 10px; border-radius: 999px; margin-top: 5px; background: var(--status-ok-ui); }
.svy-check.warn i { background: var(--attn-ink); }
.svy-check.block i { background: var(--status-error); }
.svy-check small { display: block; color: var(--ink-2); font-size: 12.5px; }
.svy-toast { position: fixed; left: 50%; bottom: calc(100px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 990; background: var(--ink-fill); color: var(--ink-fill-ink);
  border-radius: 12px; padding: 10px 16px; font-size: 14px; max-width: calc(100% - 32px); }
@media (min-width: 900px) { .svy-sheet-scrim { align-items: center; } .svy-sheet { border-radius: 18px; } }

/* ── SvMatrix (PC) ── */
.svm-page { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.svm-crumb { font-size: 12.5px; color: var(--link); }
.svm-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.svm-h1 { margin: 0; font-size: var(--text-h1); font-weight: var(--weight-medium); letter-spacing: -0.02em; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.svm-h1 .no { color: var(--link); }
.svm-badge { font-size: 12px; border: 1px solid var(--hair-strong); border-radius: 999px; padding: 2px 9px; color: var(--ink-2); font-weight: var(--weight-regular); letter-spacing: 0; }
.svm-sub { font-size: 13.5px; color: var(--ink-2); margin-top: 4px; }
.svm-sub b { color: var(--ink); font-weight: var(--weight-medium); }
.svm-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.svm-tabs { display: flex; gap: 22px; border-bottom: 1px solid var(--hair); overflow-x: auto; }
.svm-tab { appearance: none; border: 0; background: none; color: var(--ink-2); font: inherit; font-size: 14.5px; padding: 10px 0; min-height: 44px; cursor: pointer; border-bottom: 2px solid transparent; white-space: nowrap; }
.svm-tab.on { color: var(--ink); border-bottom-color: var(--ink-fill); font-weight: var(--weight-medium); }
.svm-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 340px); gap: 22px; align-items: start; }
.svm-grid-wrap { overflow-x: auto; min-width: 0; }
.svm-grid { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 760px; }
.svm-grid th { text-align: left; font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); font-weight: var(--weight-medium); padding: 8px 6px; border-bottom: 1px solid var(--hair); }
.svm-grid td { padding: 6px; border-bottom: 1px solid var(--hair-soft); vertical-align: middle; }
.svm-grid tr.grp td { font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); padding-top: 16px; font-weight: var(--weight-medium); }
.svm-area { font-size: 13.5px; color: var(--ink); }
.svm-area small { display: block; font-size: 11.5px; color: var(--ink-3); }
.svm-cell { appearance: none; border: 1.5px solid transparent; background: transparent; border-radius: 8px; min-height: 34px; padding: 0 8px; font-size: 12.5px; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px; color: var(--ink-2); max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.svm-cell:hover { border-color: var(--hair-strong); }
.svm-cell i { flex: 0 0 7px; width: 7px; height: 7px; border-radius: 999px; background: var(--status-ok-ui); }
.svm-cell.defect { background: var(--status-overdue-bg); color: var(--status-overdue-ink); }
.svm-cell.defect i { background: var(--status-overdue-ink); }
.svm-cell.notSeen { background: repeating-linear-gradient(135deg, var(--surface-sunk) 0 4px, transparent 4px 8px); color: var(--ink-3); }
.svm-cell.notSeen i, .svm-cell.todo i { display: none; }
.svm-cell.todo { color: var(--ink-3); }
.svm-cell.sel { border-color: var(--link); }
.svm-cell.desk::after { content: '•'; color: var(--link); margin-left: 2px; }
.svm-dash { color: var(--ink-3); padding-left: 10px; }
.svm-ph { display: flex; gap: 4px; }
.svm-ph img, .svm-ph span { width: 30px; height: 30px; border-radius: 5px; object-fit: cover; background: var(--surface-sunk); display: block; }
.svm-panel { border: 1px solid var(--hair); border-radius: 16px; background: var(--surface); padding: 16px; display: flex; flex-direction: column; gap: 12px; position: sticky; top: 12px; }
.svm-panel-head { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.svm-panel-head b { font-size: 15px; font-weight: var(--weight-medium); }
.svm-words { border: 1px solid var(--hair); border-radius: 12px; padding: 10px 12px; font-size: 14px; line-height: 1.5; }
.svm-words .n { color: var(--ink-3); margin-right: 6px; }
.svm-words textarea { width: 100%; border: 0; background: transparent; color: var(--ink); font: inherit; resize: vertical; min-height: 60px; padding: 0; }
.svm-site { font-size: 12.5px; color: var(--ink-2); line-height: 1.45; }
.svm-site s { color: var(--ink-3); }
.svm-photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 6px; }
.svm-photos img, .svm-photos span { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 8px; background: var(--surface-sunk); display: block; }
.svm-doc { max-width: 104ch; display: flex; flex-direction: column; gap: 6px; font-size: 14px; line-height: 1.55; }
.svm-doc h3 { margin: 18px 0 4px; font-size: 12.5px; letter-spacing: 0.12em; text-transform: uppercase; font-weight: var(--weight-medium); color: var(--ink); }
.svm-doc .p { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 10px; }
.svm-doc .p .n { color: var(--ink-3); }
.svm-doc .p.area { font-weight: var(--weight-medium); margin-top: 8px; }
.svm-doc .ref { color: var(--link); }
.svm-doc .hl { background: var(--blue-tint); border-radius: 6px; }
.svm-figs { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.svm-fig { display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; }
.svm-fig img, .svm-fig span.ph { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 10px; background: var(--surface-sunk); display: block; }
.svm-note { border: 1px dashed var(--hair-strong); border-radius: 14px; padding: 18px; max-width: 72ch; font-size: 14px; line-height: 1.5; color: var(--ink-2); display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
@media (max-width: 1100px) { .svm-body { grid-template-columns: minmax(0, 1fr); } .svm-panel { position: static; } }
@media (max-width: 760px) { .svm-h1 { font-size: var(--text-h1-phone); } }

/* ── The phone, one step at a time (v4.23.6; phone-steps.js) ──
   ≤ 760 px or the phone app. Release D (docs/phone-release-d/BRIEF.md §5.E, boards
   Survey-*) draws the steps with the phone's own components: the layer wears .m-app
   .svy-ios and its classes live in v4/phone.css (.p4-*, §5.E .p4-rp-*), so the
   Release C flow classes (.svy-f-*, .svy-opt, .svy-fl-*, .svy-room) are gone. */
