/* The part page's Overview (build/part_overview.py, static/part-overview.js). Colours are data-ui's --data-* tokens,
   so light and dark follow the kit and the site. */
.ov-root { display: block; }
.ov-main { display: grid; gap: 16px; margin: 8px 0 24px; }
.ov-dash { display: block; min-width: 0; }
.ov-hero { display: grid; gap: 12px; min-width: 0; }
.ov-four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.ov-pane { margin: 0; border: 1px solid var(--data-border, #e5e7eb); border-radius: var(--data-radius, 8px); background: var(--data-bg, #fff);
  display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
.ov-pane > figcaption { font-weight: 600; font-size: 13px; padding: 6px 10px; border-bottom: 1px solid var(--data-border, #e5e7eb); }
.ov-pane > img, .ov-pane > div { flex: 1; display: flex; align-items: center; justify-content: center; padding: 8px; min-height: 150px; }
.ov-pane > img { object-fit: contain; max-height: 220px; width: 100%; background: #fff; }
.ov-pane .drawing svg, .ov-pane .pic svg { max-width: 100%; max-height: 200px; height: auto; }
.ov-pane .drawing { display: flex; gap: 6px; align-items: center; justify-content: center; }
.ov-pane .drawing svg:nth-child(2) { display: none; }
.ov-pane > small { color: var(--data-muted, #6b7280); font-size: 12px; padding: 4px 10px 8px; }
.ov-pane ul { list-style: none; margin: 0; padding: 8px 10px; align-self: stretch; display: block; }
.ov-pane li { margin: 0 0 6px; font-size: 13px; }
.ov-pane li a { font-weight: 600; margin-right: 6px; }
.ov-files > ul, .ov-files > div { display: block; }
.ov-empty { color: var(--data-muted, #6b7280); font-size: 13px; }
/* the CAD & sim pane's 3D preview (part_overview.cad_preview): the poster, then data-ui's <data-mesh> over the same box.
   WHY a fixed shape and absolute: data-mesh is height 100%, and the box must not move when the viewer goes live */
.ov-files > .ov-cad { position: relative; flex: none; aspect-ratio: 4 / 3; min-height: 0; padding: 0; }
.ov-cad data-mesh { position: absolute; inset: 0; width: 100%; height: 100%; }
.ov-cad data-mesh > img { display: block; width: 100%; height: 100%; object-fit: contain; }
.alias { display: block; height: 0; }
/* the view cards (build/part_views.py, PEP 0004 §11): one card per view the part has, under the picture panes */
.ov-views { min-width: 0; }
.ov-views-h { font-size: 15px; font-weight: 600; margin: 0 0 6px; }
.ov-views data-views { display: block; min-width: 0; }
/* read at a glance and opened by a click: link mode's select boxes have no bulk action here (as on the dashboard) */
.ov-views .dv-open-check { display: none; }

@media (max-width: 900px) {
  .ov-four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  /* WHY two up, not stacked: four full-width pictures put ~1,400 px of images before the first number on a phone */
  .ov-four { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .ov-pane > img, .ov-pane > div { min-height: 110px; padding: 4px; }
  .ov-pane > img { max-height: 130px; }
  .ov-pane .drawing svg, .ov-pane .pic svg { max-height: 120px; }
  .ov-pane .pic { min-height: 110px; }
  .ov-pane > small { font-size: 11px; padding: 2px 6px 6px; }
  /* WHY content height on a phone: one column stacks the panels, and a desktop row height left the headline cards
     (six since the freshness KPI) in a 240 px inner scroller that showed two of them */
  .ov-dash .dd-panel { height: auto; }
  .ov-dash .dv-view-kpi { height: auto; overflow: visible; }
}

/* the isometric envelope needs a box before static/site.js's lazy observer will draw into it */
.ov-pane .pic { display: block; width: 100%; min-height: 170px; }
/* KPI cards here are the record's own values; the kit's "the producer's number" footer says nothing to a reader */
.ov-dash .dv-kpi-from { display: none; }
/* the dashboard's four tables as the server writes them (build/part_overview.py static_tables): read without
   JavaScript, replaced by the dashboard's first draw; laid out as its panels are (offers; views beside key specs; headline) */
.ov-static { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 12px; }
.ov-s { grid-column: span 12; min-width: 0; border: 1px solid var(--data-border, #e5e7eb); border-radius: var(--data-radius, 8px); padding: 8px 12px; }
.ov-s[data-panel="views"] { grid-column: span 7; }
.ov-s[data-panel="keyspecs"] { grid-column: span 5; align-self: start; }
.ov-s > h3 { font-size: 14px; margin: 4px 0 8px; }
.ov-t { width: 100%; border-collapse: collapse; font-size: 13px; }
.ov-t th, .ov-t td { text-align: left; padding: 4px 8px; border-bottom: 1px solid var(--data-border, #e5e7eb); vertical-align: top; }
.ov-t .ov-grp th { font-weight: 600; background: var(--data-bg-soft, transparent); }
@media (max-width: 900px) { .ov-s[data-panel="views"], .ov-s[data-panel="keyspecs"] { grid-column: span 12; } }
/* a read-only summary: no row counts, and no select boxes on the directory's links */
.ov-dash .dv-status, .ov-dash .dv-open-check { display: none; }
