/* Parity 10 (2026-10-17) — the vendored 360 viewer's canvas and
 * hint, and the Plans floor: the drawings group in the project's
 * Plans & Scans section and the drawing viewer (zoom/pan) its
 * image rows open. Pass styles live here rather than in
 * styles.css, which rides the per-file upload ceiling. */

/* ---- the 360 viewer (pano-viewer.js) ---- */
#pano-viewer { position: relative; }
.pano-canvas {
  position: absolute; inset: 0; width: 100%; height: 100%;
  display: block; cursor: grab; touch-action: none; background: #000;
}
.pano-canvas:active { cursor: grabbing; }
.pano-hint {
  position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%);
  background: rgba(10, 16, 26, .78); color: #e7edf6; font-size: 12.5px; font-weight: 600;
  padding: 6px 12px; border-radius: 20px; pointer-events: none; opacity: 0;
  white-space: nowrap; max-width: calc(100% - 32px); overflow: hidden; text-overflow: ellipsis;
}
.pano-hint-on { animation: pano-hint-fade 5s ease forwards; }
@keyframes pano-hint-fade {
  0% { opacity: 0; } 8% { opacity: 1; } 78% { opacity: 1; } 100% { opacity: 0; }
}

/* ---- Plan drawings (plans.js) ---- */
.pd-head { display: flex; align-items: center; gap: 10px; }
.pd-head .mod-h { margin-right: auto; }
.pd-thumb {
  width: 56px; height: 42px; object-fit: cover; border-radius: 6px;
  flex: none; background: #e8edf3;
}
.pd-kind { flex: none; }

/* ---- the drawing viewer: zoom/pan over one drawing ---- */
.planview-overlay {
  position: fixed; inset: 0; z-index: 130; background: #0b1220;
  display: flex; flex-direction: column;
}
.planview-bar {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; background: #101826; color: #fff;
}
.planview-title {
  font-weight: 700; font-size: 15px; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; margin-right: auto;
}
.planview-bar .btn-ghost {
  color: #dbe2ee; border-color: rgba(255, 255, 255, .35);
  background: rgba(255, 255, 255, .06);
}
.planview-bar .btn-ghost:hover { background: rgba(255, 255, 255, .14); }
.planview-pct {
  font-size: 12.5px; color: #b9c4d6; min-width: 44px; text-align: center;
  font-variant-numeric: tabular-nums;
}
.planview-x {
  background: rgba(255, 255, 255, .12); border: 0; color: #fff; font-size: 24px;
  width: 38px; height: 38px; border-radius: 50%; cursor: pointer; line-height: 1; flex: none;
}
.planview-stage {
  flex: 1; position: relative; overflow: hidden; touch-action: none;
  cursor: grab; min-height: 0;
}
.planview-stage:active { cursor: grabbing; }
.planview-img {
  position: absolute; left: 50%; top: 50%; max-width: none;
  transform-origin: center center; user-select: none; -webkit-user-drag: none;
  background: #fff;
}
.planview-msg {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  color: #b9c4d6; font-size: 14px; padding: 20px; text-align: center;
}

/* ======================================================================
 * DW2 P09 — photos, media, measures, timeline, 360. Structure rules are
 * plain (the Navy appearance needs them too); the light-skin look is
 * scoped body.skin-billdr.
 * ====================================================================== */

/* Lightbox manage row */
.lb-manage { display: flex; flex-wrap: wrap; gap: 8px; }
.lb-info .btn-ghost.lb-danger { color: #f3b4a9; border-color: rgba(243, 180, 169, .45); }

/* Library cell ⋯ chip (bottom-right; the download chip keeps top-right) */
.lib-menu-chip, .pano-menu-chip {
  position: absolute; right: 6px; bottom: 6px; z-index: 2;
  width: 30px; height: 30px; border-radius: 50%; border: 0;
  background: rgba(11, 34, 53, .85); color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .12s ease;
}
.ph:hover .lib-menu-chip, .lib-menu-chip:focus-visible,
.card:hover .pano-menu-chip, .pano-menu-chip:focus-visible { opacity: 1; }
@media (hover: none), (max-width: 760px) { .lib-menu-chip, .pano-menu-chip { opacity: .92; width: 40px; height: 40px; } }
.ph .ph-cap ~ .lib-menu-chip { bottom: 30px; }
.cover { position: relative; }
.photogrid .badge.lib-hidden-badge { left: auto; right: 44px; background: rgba(95, 99, 104, .92); color: #fff; }
.lib-hidden-toggle { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted, #66707c); cursor: pointer; }
.lib-hidden-toggle.hidden { display: none; }
.lib-doclist .lib-docmenu, .lib-line .lib-docmenu { padding: 0 6px; }

/* Plans & Scans */
.card.clickable { cursor: pointer; }
.card.clickable:focus-visible { outline: 2px solid var(--gold, #cca86a); outline-offset: 2px; }
.pd-menu { padding: 0 6px; }

/* Measurements tab */
.pm-menu { padding: 0 6px; }
.pm-lidar-note { margin: -4px 0 10px; font-size: 13px; max-width: 72ch; }
.pm-open-photo { white-space: nowrap; }

/* Quick Measures */
.qm-card { position: relative; }
.qm-card.qm-typed { cursor: pointer; }
.qm-card.qm-typed:focus-visible { outline: 2px solid var(--gold, #cca86a); outline-offset: 2px; }
.qm-menu-btn { position: absolute; top: 8px; right: 8px; padding: 0 6px; min-height: 30px; }
.qm-form-title { margin: 0 0 12px; font-weight: 700; font-size: 15px; }
.qm-cap { margin: -8px 0 14px; font-size: 13px; }
.qm-filterbar input[type="search"] { flex: 1 1 260px; max-width: 420px; }

/* Timeline extras */
.tl-date { display: inline-flex; align-items: center; gap: 6px; }
.tl-date input[type="date"] { font: inherit; font-size: 13.5px; padding: 6px 8px; border: 1px solid var(--line, #e3e7ee); border-radius: 8px; background: var(--card, #fff); }
.tl-check { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.tl-error { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 0 0 16px; padding: 10px 14px; border-radius: 10px; background: #fdf0ed; color: #8a2f1f; font-size: 13.5px; }
.tl-error p { margin: 0; }
.tl-error.hidden { display: none; }
.tl-cell .ph .flag-chip { top: 6px; left: 6px; }

/* 360 page: import row, overlay retry */
.pano-import { margin: 0 0 18px; }
.pano-import .actions-bar { display: flex; align-items: center; gap: 10px 14px; flex-wrap: wrap; }
.pano-import-pick { min-width: 200px; font: inherit; font-size: 14px; padding: 7px 10px; border: 1px solid var(--line, #e3e7ee); border-radius: 8px; background: var(--card, #fff); }
.pano-retry { margin-top: 12px; }
#pano-reset.hidden { display: none; }

/* Reports retry */
.rep-retry { margin-left: 6px; }

body.skin-billdr #app .lib-hidden-toggle { font-size: var(--ds-fs-sm); color: var(--ds-muted); }
body.skin-billdr #app .lib-hidden-toggle input, body.skin-billdr #app .tl-check input { accent-color: var(--ds-gold-strong); }
body.skin-billdr #app .tl-date { font-size: var(--ds-fs-sm); color: var(--ds-muted); font-weight: 500; text-transform: none; letter-spacing: 0; }
body.skin-billdr #app .tl-date input[type="date"] { min-height: var(--ds-ctl); border-color: var(--ds-line); border-radius: var(--ds-r-ctl); color: var(--ds-ink); font-size: var(--ds-fs-sm); }
body.skin-billdr #app .tl-check { font-size: var(--ds-fs-sm); color: var(--ds-ink); font-weight: 500; text-transform: none; letter-spacing: 0; }
body.skin-billdr #app .tl-error { background: var(--ds-bad-bg); color: var(--ds-bad-ink); border-radius: var(--ds-r-ctl); }
body.skin-billdr #app .qm-form-title { color: var(--ds-navy); font-size: var(--ds-fs-md); }
body.skin-billdr #app .qm-cap, body.skin-billdr #app .pm-lidar-note { color: var(--ds-muted); font-size: var(--ds-fs-sm); }
body.skin-billdr #app :is(.qm-menu-btn, .pm-menu, .pd-menu, .lib-docmenu) { background: none; border: 0; color: var(--ds-muted); min-height: var(--ds-ctl-sm); }
body.skin-billdr #app :is(.qm-menu-btn, .pm-menu, .pd-menu, .lib-docmenu):hover { color: var(--ds-navy); background: var(--ds-tint); }
body.skin-billdr #app .pano-import-pick { min-height: var(--ds-ctl); border-color: var(--ds-line); border-radius: var(--ds-r-ctl); font-size: var(--ds-fs-sm); }
body.skin-billdr #app .pm-open-photo, body.skin-billdr #app .rep-retry {
  min-height: var(--ds-ctl-sm); padding: 0 4px; background: none; border: 0; color: var(--ds-gold-ink); font-size: var(--ds-fs-sm); font-weight: 600;
}
.qm-card.qm-typed .body { padding-right: 44px; }
.qm-form .qm-delete { color: var(--danger, #b3402e); }
body.skin-billdr #app .qm-form .qm-delete { color: var(--ds-danger); }
body.skin-billdr #app .qm-menu-btn { color: var(--ds-ink); }
body.skin-billdr #app .lib-doclist > .row > .btn.btn-ghost.lib-docmenu,
body.skin-billdr #app :is(.pd-menu, .pm-menu) { color: var(--ds-ink); }
.lib-filterbar label.lib-hidden-toggle { flex-direction: row; align-items: center; gap: 6px; white-space: nowrap; }
.lib-filterbar label.lib-hidden-toggle.hidden { display: none; }
