/* ==========================================================================
   Observations page (Vetting Observations tab) — page-specific overrides
   layered on top of grid.css.
   ----------------------------------------------------------------------------
   Scoped via `body.page-observations`. Shared chrome comes from grid.css
   via the additional `body.page-grid` class.

   This page has no primary CTA (no Create New / Add New button on the grid)
   and its grid columns are DB-driven via the shared ~/DesktopModules/GridView.ascx
   wrapper reading tblGridColumn (GridName = 'Inspection Observations List').
   Column order/visibility is user-adjustable, so nth-child width locks are
   unreliable and intentionally omitted. If column widths ever need defaults,
   tailor to the page's default column set and re-apply after schema changes.

   NOTE: InspectionObservations.ascx has an inline <style> that sets
   .modV2 .modV2TitleContainer { min-width: 1100px }. That is out of this
   file's scope but worth knowing when debugging layout.
   ========================================================================== */

/* Edit-column header blank caption — the Edit column is server-pinned as
   the last column via `AlwaysLastColumn="edit"` on GridCustomColumns, so
   `:last-child` targets it robustly even though this grid is DB-driven
   and column order is otherwise user-adjustable. Mirrors the
   inspections.css approach (nth-child(10)) but survives reordering. */
body.page-observations td.dxgvHeader:last-child,
body.page-observations th.dxgvHeader:last-child,
body.page-observations td.dxgvHeader:last-child *,
body.page-observations th.dxgvHeader:last-child * {
    font-size: 0 !important;
    color: transparent !important;
}

/* ==========================================================================
   Edit Observation modal — iframe height (parent side)
   --------------------------------------------------------------------------
   InspectionObservationEdit.ascx's JS sizes the host iframe (#ifEditObs) to
   `90vh`, which — once the §9.10 modal chrome (header + 24/28 padding) and the
   `top` offset are added — pushes the modal card past the bottom of the
   viewport, cutting off the (sticky) footer. Cap the iframe to the viewport
   minus the modal chrome so the whole card stays on screen and the footer is
   visible. !important beats the inline `height:90vh` the ascx JS sets.
   The iframe is scrolling="no"; the iframe body (observations-edit.css §1) is
   the scroll container, so a shorter iframe just scrolls its content. */
body.page-observations .obs-edit-iframe,
.obs-edit-iframe {
    height: calc(100vh - 190px) !important;
    max-height: calc(100vh - 190px) !important;
    /* The ascx JS (OverrideObsEditModalStyle) sets the iframe to the FULL modal
       width (== modalWidth, e.g. 1040px), but the §9.10 modal card adds 28px
       padding each side, so the content area is ~56px narrower than the iframe
       — the iframe overflows the card and the modal grows a horizontal scroll.
       Pin the iframe to fill the content area instead (overrides the inline
       width:1040px the JS sets). */
    width: 100% !important;
    max-width: 100% !important;
}
